1SUMMARY = "netcf" 2DESCRIPTION = "netcf is a cross-platform network configuration library." 3HOMEPAGE = "https://pagure.io/netcf" 4SECTION = "libs" 5LICENSE = "LGPLv2.1" 6 7LIC_FILES_CHKSUM = "file://COPYING;md5=fb919cc88dbe06ec0b0bd50e001ccf1f" 8 9SRCREV = "2c5d4255857531bc09d91dcd02e86545f29004d4" 10PV .= "+git${SRCPV}" 11 12SRC_URI = "git://pagure.io/netcf.git;protocol=https \ 13" 14 15UPSTREAM_CHECK_GITTAGREGEX = "release-(?P<pver>(\d+(\.\d+)+))" 16 17DEPENDS += "augeas libnl libxslt libxml2" 18 19do_configure[depends] += "${MLPREFIX}gnulib:do_populate_sysroot" 20 21S = "${WORKDIR}/git" 22 23inherit gettext autotools perlnative pkgconfig systemd 24 25EXTRA_OECONF:append:class-target = " --with-driver=redhat" 26 27PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" 28PACKAGECONFIG[systemd] = "--with-sysinit=systemd,--with-sysinit=initscripts," 29 30EXTRA_AUTORECONF += "-I ${S}/gnulib/m4" 31 32do_configure:prepend() { 33 currdir=`pwd` 34 cd ${S} 35 36 # avoid bootstrap cloning gnulib on every configure 37 # the dir starts out empty from the pkg, but unconditionally blow it 38 # away so if we reconfigure due to gnulib sysroot sig changes, we will 39 # get the newer gnulib content into the build here. 40 rm -rf ${S}/.gnulib 41 cp -rf ${STAGING_DATADIR}/gnulib ${S}/.gnulib 42 43 # --force to avoid errors on reconfigure e.g if recipes changed we depend on 44 # | bootstrap: running: libtoolize --quiet 45 # | libtoolize: error: 'libltdl/COPYING.LIB' exists: use '--force' to overwrite 46 # | ... 47 ./bootstrap --force --no-git --gnulib-srcdir=.gnulib 48 49 cd $currdir 50} 51 52do_install:append() { 53 if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then 54 install -d ${D}${systemd_unitdir}/system 55 if [ -d "${D}${libdir}/systemd/system" ]; then 56 if [ "${systemd_unitdir}" != "${libdir}/systemd" ] ; then 57 mv ${D}${libdir}/systemd/system/* ${D}${systemd_unitdir}/system/ 58 rm -rf ${D}${libdir}/systemd/ 59 fi 60 elif [ "${systemd_unitdir}" != "${nonarch_libdir}/systemd" ] ; then 61 mv ${D}${nonarch_libdir}/systemd/system/* ${D}${systemd_unitdir}/system/ 62 rm -rf ${D}${nonarch_libdir}/systemd/ 63 fi 64 else 65 mv ${D}${sysconfdir}/rc.d/init.d/ ${D}${sysconfdir} 66 rm -rf ${D}${sysconfdir}/rc.d/ 67 fi 68} 69 70FILES:${PN} += " \ 71 ${libdir} \ 72 ${nonarch_libdir} \ 73 " 74 75SYSTEMD_SERVICE:${PN} = "netcf-transaction.service" 76