blob: 7e00f150d32683a2cd664b27ffd78b4ec3f2b3aa [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001SUMMARY = "Small Footprint CIM Broker"
2DESCRIPTION = "\
3Small Footprint CIM Broker (sfcb) is a CIM server conforming to the CIM \
4Operations over HTTP protocol. It is robust, with low resource consumption \
5and therefore specifically suited for embedded and resource constrained \
6environments. sfcb supports providers written against the Common \
7Manageability Programming Interface (CMPI)."
8HOMEPAGE = "http://www.sblim.org"
9SECTION = "Applications/System"
10LICENSE = "EPL-1.0"
11LIC_FILES_CHKSUM = "file://COPYING;md5=f300afd598546add034364cd0a533261"
12DEPENDS = "curl libpam openssl sblim-sfc-common unzip-native"
13
Brad Bishop8410d612019-11-25 09:40:59 -050014inherit features_check
Brad Bishop316dfdd2018-06-25 12:45:53 -040015REQUIRED_DISTRO_FEATURES = "pam"
16
Patrick Williamsb48b7b42016-08-17 15:04:38 -050017SRC_URI = "http://downloads.sourceforge.net/sblim/${BP}.tar.bz2 \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050018 file://sfcb.service \
Patrick Williamsb48b7b42016-08-17 15:04:38 -050019 file://sblim-sfcb-1.3.9-sfcbrepos-schema-location.patch \
20 file://sblim-sfcb-1.3.15-fix-provider-debugging.patch \
21 file://sblim-sfcb-1.3.16-maxMsgLen.patch \
22 file://sblim-sfcb-1.4.5-service.patch \
23 file://sblim-sfcb-1.3.16-multilib-man-cfg.patch \
24 file://sblim-sfcb-1.4.8-default-ecdh-curve-name.patch \
25 file://sblim-sfcb-1.4.9-fix-ftbfs.patch \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050026 file://0001-include-stdint.h-system-header-for-UINT16_MAX.patch \
27 file://0001-Replace-need-for-error.h-when-it-does-not-exist.patch \
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080028 file://sblim-sfcb-1.4.9-fix-sfcbinst2mof.patch \
Andrew Geisslerbffdb3e2020-08-21 16:13:29 -050029 file://0001-Avoid-variable-definition-in-header-files.patch \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050030"
Patrick Williamsddad1a12017-02-23 20:36:32 -060031
Patrick Williamsb48b7b42016-08-17 15:04:38 -050032SRC_URI[md5sum] = "28021cdabc73690a94f4f9d57254ce30"
33SRC_URI[sha256sum] = "634a67b2f7ac3b386a79160eb44413d618e33e4e7fc74ae68b0240484af149dd"
34
35inherit autotools
Brad Bishop316dfdd2018-06-25 12:45:53 -040036inherit systemd
Patrick Williamsb48b7b42016-08-17 15:04:38 -050037
38SYSTEMD_PACKAGES = "${PN}"
Patrick Williams213cb262021-08-07 19:21:33 -050039SYSTEMD_SERVICE:${PN} = "sblim-sfcb.service"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050040SYSTEMD_AUTO_ENABLE = "enable"
41
Patrick Williams213cb262021-08-07 19:21:33 -050042LDFLAGS:append = "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', ' -fuse-ld=bfd ', '', d)}"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050043
44EXTRA_OECONF = '--enable-debug \
45 --enable-ssl \
46 --enable-pam \
47 --enable-ipv6 \
48 CFLAGS="${CFLAGS} -D_GNU_SOURCE"'
49
50# make all with -j option is unsafe.
51PARALLEL_MAKE = ""
52
Patrick Williams213cb262021-08-07 19:21:33 -050053INSANE_SKIP:${PN} = "dev-so"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050054CONFIG_SITE = "${WORKDIR}/config-site.${P}"
55
56do_install() {
57 cp -f ${S}/sfcb.cfg.pre.in ${S}/sfcb.cfg
58
59 oe_runmake DESTDIR=${D} install
60
Brad Bishop316dfdd2018-06-25 12:45:53 -040061 install -d ${D}${systemd_unitdir}/system
62 install -m 0644 ${WORKDIR}/sfcb.service ${D}${systemd_unitdir}/system/sblim-sfcb.service
Patrick Williamsb48b7b42016-08-17 15:04:38 -050063
64 install -d ${D}${sysconfdir}/init.d
65 mv ${D}${sysconfdir}/init.d/sfcb ${D}${sysconfdir}/init.d/sblim-sfcb
66 sed -i -e 's/\/var\/lock\/subsys\/sfcb/\/var\/lock\/subsys\/sblim-sfcb/g' ${D}${sysconfdir}/init.d/sblim-sfcb
Patrick Williamsddad1a12017-02-23 20:36:32 -060067
Patrick Williamsb48b7b42016-08-17 15:04:38 -050068 rm -rf ${D}${libdir}/sfcb/*.la
69}
70
Patrick Williams213cb262021-08-07 19:21:33 -050071pkg_postinst:${PN} () {
Andrew Geisslerd688a012020-09-18 13:36:00 -050072 $INTERCEPT_DIR/postinst_intercept delay_to_first_boot ${PKG} mlprefix=${MLPREFIX}
73}
Patrick Williamsb48b7b42016-08-17 15:04:38 -050074
Patrick Williams213cb262021-08-07 19:21:33 -050075pkg_postinst_ontarget:${PN} () {
Patrick Williamsb48b7b42016-08-17 15:04:38 -050076 ${datadir}/sfcb/genSslCert.sh ${sysconfdir}/sfcb
77 ${bindir}/sfcbrepos -f
78}
79
Patrick Williams213cb262021-08-07 19:21:33 -050080FILES:${PN} += "${libdir}/sfcb ${datadir}/sfcb"
81FILES:${PN}-dbg += "${libdir}/sfcb/.debug"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050082
Patrick Williams213cb262021-08-07 19:21:33 -050083RDEPENDS:${PN} = "perl bash"