xref: /OK3568_Linux_fs/yocto/poky/meta/recipes-support/gdbm/gdbm_1.23.bb (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunSUMMARY = "Key/value database library with extensible hashing"
2*4882a593SmuzhiyunDESCRIPTION = "Library of database functions that use extensible hashing \
3*4882a593Smuzhiyunand work similar to the standard UNIX dbm. These routines are provided \
4*4882a593Smuzhiyunto a programmer needing to create and manipulate a hashed database."
5*4882a593SmuzhiyunHOMEPAGE = "http://www.gnu.org/software/gdbm/"
6*4882a593SmuzhiyunSECTION = "libs"
7*4882a593SmuzhiyunLICENSE = "GPL-3.0-only"
8*4882a593SmuzhiyunLIC_FILES_CHKSUM = "file://COPYING;md5=241da1b9fe42e642cbb2c24d5e0c4d24"
9*4882a593Smuzhiyun
10*4882a593Smuzhiyun
11*4882a593SmuzhiyunSRC_URI = "${GNU_MIRROR}/gdbm/gdbm-${PV}.tar.gz \
12*4882a593Smuzhiyun           file://run-ptest \
13*4882a593Smuzhiyun           file://ptest.patch \
14*4882a593Smuzhiyun          "
15*4882a593Smuzhiyun
16*4882a593SmuzhiyunSRC_URI[sha256sum] = "74b1081d21fff13ae4bd7c16e5d6e504a4c26f7cde1dca0d963a484174bbcacd"
17*4882a593Smuzhiyun
18*4882a593Smuzhiyuninherit autotools gettext texinfo lib_package ptest
19*4882a593Smuzhiyun
20*4882a593Smuzhiyun# Needed for dbm python module
21*4882a593SmuzhiyunEXTRA_OECONF = "--enable-libgdbm-compat --without-readline"
22*4882a593Smuzhiyun
23*4882a593Smuzhiyun# Stop presence of dbm/nbdm on the host contaminating builds
24*4882a593SmuzhiyunCACHED_CONFIGUREVARS += "ac_cv_lib_ndbm_main=no ac_cv_lib_dbm_main=no"
25*4882a593Smuzhiyun
26*4882a593SmuzhiyunBBCLASSEXTEND = "native nativesdk"
27*4882a593Smuzhiyun
28*4882a593Smuzhiyundo_install:append () {
29*4882a593Smuzhiyun    # Create a symlink to ndbm.h and gdbm.h in include/gdbm to let other packages to find
30*4882a593Smuzhiyun    # these headers
31*4882a593Smuzhiyun    install -d ${D}${includedir}/gdbm
32*4882a593Smuzhiyun    ln -sf ../ndbm.h ${D}/${includedir}/gdbm/ndbm.h
33*4882a593Smuzhiyun    ln -sf ../gdbm.h ${D}/${includedir}/gdbm/gdbm.h
34*4882a593Smuzhiyun}
35*4882a593Smuzhiyun
36*4882a593SmuzhiyunRDEPENDS:${PN}-ptest += "diffutils ${PN}-bin"
37*4882a593Smuzhiyun
38*4882a593Smuzhiyundo_compile_ptest() {
39*4882a593Smuzhiyun    oe_runmake -C tests buildtests
40*4882a593Smuzhiyun}
41*4882a593Smuzhiyun
42*4882a593SmuzhiyunPACKAGES =+ "${PN}-compat \
43*4882a593Smuzhiyun            "
44*4882a593SmuzhiyunFILES:${PN}-compat = "${libdir}/libgdbm_compat${SOLIBS} \
45*4882a593Smuzhiyun                     "
46