libgcrypt: restore BBCLASSEXTEND
[openembedded.git] / recipes / sdr / hamlib_1.2.10.bb
1 DESCRIPTION = "The Ham Radio Control Libraries, Hamlib for short, is a development effort to provide a consistent interface for programmers wanting to incorporate radio control in their programs"
2 LICENSE = "GPLv2"
3
4 DEPENDS = "swig-native perl python virtual/libusb0 tcl gnuradio"
5
6 SRC_URI = "${SOURCEFORGE_MIRROR}/hamlib/hamlib-${PV}.tar.gz"
7
8 inherit autotools
9
10 EXTRA_OECONF = "--with-perl-inc=${STAGING_LIBDIR}/perl/5.8.8/CORE"
11 # This is a hack, someone with some more time should fix the autofoo
12 do_configure() {
13         oe_runconf
14 }
15
16 PARALLEL_MAKE = ""
17
18 do_compile_prepend() {
19         for i in $(find ${S} -name "Makefile") ; do
20                 sed -i -e 's:${STAGING_LIBDIR_NATIVE}:${STAGING_LIBDIR}:g' \
21                        -e s:-L/usr/local/lib::g \
22                            -e 's:\"$(CC)\":\"${CC}\" LD=\"${LD}\" LDFLAGS=\"${LDFLAGS}\":g' \
23                        -e s:${STAGING_INCDIR_NATIVE}/python2.6:${STAGING_INCDIR}/python2.6:g $i 
24         done
25 }
26
27 # There's one perl module that doesn't honour CFLAGS :(
28 INSANE_SKIP_${PN} = True
29 FILES_${PN} = "${bindir} ${sbindir} ${libdir}/hamlib*.so ${libdir}/p*/ ${libdir}/tcl"
30 FILES_${PN}-dbg += "${libdir}/perl/*/auto/Hamlib/.debug/"
31
32 python populate_packages_prepend () {
33         hamlib_libdir = bb.data.expand('${libdir}', d)
34         hamlib_libdir_dbg = bb.data.expand('${libdir}/.debug', d)
35         do_split_packages(d, hamlib_libdir, '^lib(.*)\.so$', 'lib%s-dev', 'hamlib %s development package', extra_depends='${PN}-dev', allow_links=True)
36         do_split_packages(d, hamlib_libdir, '^lib(.*)\.la$', 'lib%s-dev', 'hamlib %s development package', extra_depends='${PN}-dev')
37         do_split_packages(d, hamlib_libdir, '^lib(.*)\.a$', 'lib%s-dev', 'hamlib %s development package', extra_depends='${PN}-dev')
38         do_split_packages(d, hamlib_libdir, '^lib(.*)\.so\.*', 'lib%s', 'hamlib %s library', extra_depends='', allow_links=True)
39 }
40
41 AUTOTOOLS_STAGE_PKGCONFIG = "1"
42
43