From patchwork Wed Apr 11 14:18:03 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [1/1] gdbm: Activate -enable-libgdbm-compat and add symlinks to headers in include/gdbm Date: Wed, 11 Apr 2012 14:18:03 -0000 From: Andrei Gherzan X-Patchwork-Id: 25595 Message-Id: <615f8201f2fb18a7e3e0e0c07febd57f788005ad.1334153781.git.andrei@gherzan.ro> To: openembedded-core@lists.openembedded.org ndbm.h is needed by python for dbm module. This is why -enable-libgdbm-compat was added to configure. The second change is because python is looking for the gdbm headers in include/gdbm. The easiest way to solve this issue is to add symlinks in include/gdbm. In order to avoid breaking packages which depend on old package name libgdbm4 (>= 1.10), compat libs are packaged into a separate package named gdbm-compat. [YOCTO #1937] Signed-off-by: Andrei Gherzan --- meta/recipes-support/gdbm/gdbm_1.10.bb | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-) diff --git a/meta/recipes-support/gdbm/gdbm_1.10.bb b/meta/recipes-support/gdbm/gdbm_1.10.bb index 9b2fde4..40bdd86 100644 --- a/meta/recipes-support/gdbm/gdbm_1.10.bb +++ b/meta/recipes-support/gdbm/gdbm_1.10.bb @@ -4,7 +4,7 @@ SECTION = "libs" LICENSE = "GPLv3" LIC_FILES_CHKSUM = "file://COPYING;md5=241da1b9fe42e642cbb2c24d5e0c4d24" -PR = "r1" +PR = "r2" SRC_URI = "${GNU_MIRROR}/gdbm/gdbm-${PV}.tar.gz" @@ -13,4 +13,20 @@ SRC_URI[sha256sum] = "23f8134c5b94bbfb06d756a6b78f074fba6e6028cf2fe01341d40b26db inherit autotools gettext lib_package +# Needed for dbm python module +EXTRA_OECONF = "-enable-libgdbm-compat" + BBCLASSEXTEND = "native nativesdk" + +do_install_append () { + # Create a symlink to ndbm.h and gdbm.h in include/gdbm to let other packages to find + # these headers + install -d ${D}${includedir}/gdbm + ln -sf ../ndbm.h ${D}/${includedir}/gdbm/ndbm.h + ln -sf ../gdbm.h ${D}/${includedir}/gdbm/gdbm.h +} + +PACKAGES =+ "${PN}-compat \ + " +FILES_${PN}-compat = "${libdir}/libgdbm_compat${SOLIBS} \ + "