diff options
author | Ross Burton <ross.burton@intel.com> | 2017-11-01 00:28:34 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-12-04 17:23:57 +0000 |
commit | c76a25b6ac36b043530fab4bb35c1b62f26c545f (patch) | |
tree | 5dd2ff6e570d8afd2a93e1bcceb7e891aa30d306 /meta/recipes-devtools/python/python_2.7.13.bb | |
parent | 1002359e5e5cd191911ea90d5d820f995a4199be (diff) | |
download | poky-c76a25b6ac36b043530fab4bb35c1b62f26c545f.tar.gz |
python: add PACKAGECONFIG for Berkeley DB module
The bsddb module is deprecated and requires an old version of Berkeley DB that
some may be unhappy with even shipping, so expose a way to disable the module.
(From OE-Core rev: 25460ccdebaa6ff29ec051a0489a51b19c34e79c)
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Armin Kuster <akuster@mvista.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/python/python_2.7.13.bb')
-rw-r--r-- | meta/recipes-devtools/python/python_2.7.13.bb | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/meta/recipes-devtools/python/python_2.7.13.bb b/meta/recipes-devtools/python/python_2.7.13.bb index 877069943e..754c029097 100644 --- a/meta/recipes-devtools/python/python_2.7.13.bb +++ b/meta/recipes-devtools/python/python_2.7.13.bb | |||
@@ -1,5 +1,5 @@ | |||
1 | require python.inc | 1 | require python.inc |
2 | DEPENDS = "python-native libffi bzip2 db gdbm openssl readline sqlite3 zlib" | 2 | DEPENDS = "python-native libffi bzip2 gdbm openssl readline sqlite3 zlib" |
3 | PR = "${INC_PR}" | 3 | PR = "${INC_PR}" |
4 | 4 | ||
5 | DISTRO_SRC_URI ?= "file://sitecustomize.py" | 5 | DISTRO_SRC_URI ?= "file://sitecustomize.py" |
@@ -39,6 +39,9 @@ CONFIGUREOPTS += " --with-system-ffi " | |||
39 | 39 | ||
40 | EXTRA_OECONF += "ac_cv_file__dev_ptmx=yes ac_cv_file__dev_ptc=no" | 40 | EXTRA_OECONF += "ac_cv_file__dev_ptmx=yes ac_cv_file__dev_ptc=no" |
41 | 41 | ||
42 | PACKAGECONFIG ??= "bdb" | ||
43 | PACKAGECONFIG[bdb] = ",,db" | ||
44 | |||
42 | do_configure_append() { | 45 | do_configure_append() { |
43 | rm -f ${S}/Makefile.orig | 46 | rm -f ${S}/Makefile.orig |
44 | autoreconf -Wcross --verbose --install --force --exclude=autopoint ../Python-${PV}/Modules/_ctypes/libffi | 47 | autoreconf -Wcross --verbose --install --force --exclude=autopoint ../Python-${PV}/Modules/_ctypes/libffi |
@@ -118,6 +121,10 @@ do_install() { | |||
118 | fi | 121 | fi |
119 | 122 | ||
120 | oe_multilib_header python${PYTHON_MAJMIN}/pyconfig.h | 123 | oe_multilib_header python${PYTHON_MAJMIN}/pyconfig.h |
124 | |||
125 | if [ -z "${@bb.utils.filter('PACKAGECONFIG', 'bdb', d)}" ]; then | ||
126 | rm -rf ${D}/${libdir}/python${PYTHON_MAJMIN}/bsddb | ||
127 | fi | ||
121 | } | 128 | } |
122 | 129 | ||
123 | do_install_append_class-nativesdk () { | 130 | do_install_append_class-nativesdk () { |
@@ -154,6 +161,8 @@ FILES_lib${BPN}2 = "${libdir}/libpython*.so.*" | |||
154 | PACKAGES += "${PN}-misc" | 161 | PACKAGES += "${PN}-misc" |
155 | FILES_${PN}-misc = "${libdir}/python${PYTHON_MAJMIN}" | 162 | FILES_${PN}-misc = "${libdir}/python${PYTHON_MAJMIN}" |
156 | RDEPENDS_${PN}-modules += "${PN}-misc" | 163 | RDEPENDS_${PN}-modules += "${PN}-misc" |
164 | |||
165 | # ptest | ||
157 | RDEPENDS_${PN}-ptest = "${PN}-modules ${PN}-tests" | 166 | RDEPENDS_${PN}-ptest = "${PN}-modules ${PN}-tests" |
158 | #inherit ptest after "require python-${PYTHON_MAJMIN}-manifest.inc" so PACKAGES doesn't get overwritten | 167 | #inherit ptest after "require python-${PYTHON_MAJMIN}-manifest.inc" so PACKAGES doesn't get overwritten |
159 | inherit ptest | 168 | inherit ptest |
@@ -180,4 +189,7 @@ do_install_ptest() { | |||
180 | PACKAGES += "${PN}-man" | 189 | PACKAGES += "${PN}-man" |
181 | FILES_${PN}-man = "${datadir}/man" | 190 | FILES_${PN}-man = "${datadir}/man" |
182 | 191 | ||
192 | # Nasty but if bdb isn't enabled the package won't be generated | ||
193 | RDEPENDS_${PN}-modules_remove = "${@bb.utils.contains('PACKAGECONFIG', 'bdb', '', '${PN}-bsddb', d)}" | ||
194 | |||
183 | BBCLASSEXTEND = "nativesdk" | 195 | BBCLASSEXTEND = "nativesdk" |