diff options
author | Robert Yang <liezhi.yang@windriver.com> | 2014-09-07 19:05:52 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-04-17 22:50:24 +0100 |
commit | fafa6b8f4444da3c0fc911d3a11eef2cd6ed825c (patch) | |
tree | 85144cb83a74dd8493b0ad2fa8f0107c56841adf /meta/recipes-extended | |
parent | b0973437f3205e30c010cd9d9f66d857511b9a69 (diff) | |
download | openembedded-core-fafa6b8f4444da3c0fc911d3a11eef2cd6ed825c.tar.gz openembedded-core-fafa6b8f4444da3c0fc911d3a11eef2cd6ed825c.tar.bz2 openembedded-core-fafa6b8f4444da3c0fc911d3a11eef2cd6ed825c.zip |
cracklib: add python support back
It had been disabled because of installed-vs-shipped:
WARNING: /usr/lib/python2.7
WARNING: /usr/lib/python2.7/site-packages
Now we fix it and add cracklib-python back.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Diffstat (limited to 'meta/recipes-extended')
-rw-r--r-- | meta/recipes-extended/cracklib/cracklib_2.9.2.bb | 28 |
1 files changed, 24 insertions, 4 deletions
diff --git a/meta/recipes-extended/cracklib/cracklib_2.9.2.bb b/meta/recipes-extended/cracklib/cracklib_2.9.2.bb index 177ab27a2b..fceca5445e 100644 --- a/meta/recipes-extended/cracklib/cracklib_2.9.2.bb +++ b/meta/recipes-extended/cracklib/cracklib_2.9.2.bb @@ -4,10 +4,12 @@ HOMEPAGE = "http://sourceforge.net/projects/cracklib" LICENSE = "LGPLv2.1+" LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=e3eda01d9815f8d24aae2dbd89b68b06" -DEPENDS = "cracklib-native zlib" -DEPENDS_class-native = "zlib-native" +DEPENDS = "cracklib-native zlib python" +RDEPEND_${PN}-python += "python" -EXTRA_OECONF = "--without-python --libdir=${base_libdir}" +PACKAGES += "${PN}-python" + +EXTRA_OECONF = "--with-python --libdir=${base_libdir}" SRC_URI = "${SOURCEFORGE_MIRROR}/cracklib/cracklib-${PV}.tar.gz \ file://0001-packlib.c-support-dictionary-byte-order-dependent.patch \ @@ -18,10 +20,28 @@ SRC_URI[sha256sum] = "c1c899291d443e99d1aecfbc879e4ac9c0cbc265574f47b487842da11e PR = "r1" -inherit autotools gettext +inherit autotools gettext pythonnative python-dir do_install_append_class-target() { create-cracklib-dict -o ${D}${datadir}/cracklib/pw_dict ${D}${datadir}/cracklib/cracklib-small } +do_install_append() { + src_dir="${D}${base_libdir}/${PYTHON_DIR}/site-packages" + rm -f $src_dir/*.pyo + rm -f $src_dir/test_cracklib.py + # Move python files from ${base_libdir} to ${libdir} since used --libdir=${base_libdir} + install -d -m 0755 ${D}${PYTHON_SITEPACKAGES_DIR}/ + mv $src_dir/* ${D}${PYTHON_SITEPACKAGES_DIR} + rm -fr ${D}${base_libdir}/${PYTHON_DIR} +} + BBCLASSEXTEND = "native nativesdk" + +FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}/cracklib.py \ + ${PYTHON_SITEPACKAGES_DIR}/_cracklib.so \ + " +FILES_${PN}-dbg += "${PYTHON_SITEPACKAGES_DIR}/.debug/_cracklib.so" +FILES_${PN}-staticdev += "${PYTHON_SITEPACKAGES_DIR}/_cracklib.a \ + ${PYTHON_SITEPACKAGES_DIR}/_cracklib.la \ + " |