blob: f11df49f8638bf082a92ef037788e8f5bf40e1b2 [file] [log] [blame]
Brad Bishopc342db32019-05-15 21:57:59 -04001SUMMARY = "OpenSAF is an open source implementation of the SAF AIS specification"
2DESCRIPTION = "OpenSAF is an open source project established to develop a base platform \
3middleware consistent with Service Availability Forum (SA Forum) \
4specifications, under the LGPLv2.1 license. The OpenSAF Foundation was \
5established by leading Communications and Enterprise Computing Companies to \
6facilitate the OpenSAF Project and to accelerate the adoption of the OpenSAF \
7code base in commercial products. \
8The OpenSAF project was launched in mid 2007 and has been under development by \
9an informal group of supporters of the OpenSAF initiative. The OpenSAF \
10Foundation was founded on January 22nd 2008 with Emerson Network Power, \
11Ericsson, Nokia Siemens Networks, HP and Sun Microsystems as founding members."
12HOMEPAGE = "http://www.opensaf.org"
13SECTION = "admin"
14LICENSE = "LGPLv2.1"
15LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7"
16
Andrew Geissler82c905d2020-04-13 13:39:40 -050017DEPENDS = "libxml2 python3"
Brad Bishopc342db32019-05-15 21:57:59 -040018TOOLCHAIN = "gcc"
19
20SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
21
22SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/releases/${BPN}-${PV}.tar.gz \
23 file://0001-configure-Pass-linker-specific-options-with-Wl.patch \
24 file://0001-configure-Disable-format-overflow-if-supported-by-gc.patch \
25 file://0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch \
26 file://0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch \
Brad Bishop26bdd442019-08-16 17:08:17 -040027 file://0001-Add-configure-time-check-for-gettid-API.patch \
Brad Bishop36a3e3e2019-10-02 13:29:27 -040028 file://0001-create_empty_library-Use-CC-variable-intead-of-hardc.patch \
Andrew Geissler82c905d2020-04-13 13:39:40 -050029 file://0001-immom_python-convert-to-python3.patch \
Brad Bishopc342db32019-05-15 21:57:59 -040030 "
Andrew Geissler89770b02020-06-13 10:40:47 -050031SRC_URI[md5sum] = "d56bacf4c234c134e60e9b25f6f26671"
32SRC_URI[sha256sum] = "2478e298c0bce3b2cfdeb20875022cc11d7d3b53ecd3255422d22eb64c04953b"
Brad Bishopc342db32019-05-15 21:57:59 -040033
Andrew Geissler82c905d2020-04-13 13:39:40 -050034UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/opensaf/files/releases"
35
Brad Bishopc342db32019-05-15 21:57:59 -040036inherit autotools useradd systemd pkgconfig
37
38USERADD_PACKAGES = "${PN}"
39GROUPADD_PARAM_${PN} = "-f -r opensaf"
40USERADD_PARAM_${PN} = "-r -g opensaf -d ${datadir}/opensaf/ -s ${sbindir}/nologin -c \"OpenSAF\" opensaf"
41
42SYSTEMD_SERVICE_${PN} += "opensafd.service"
43SYSTEMD_AUTO_ENABLE = "disable"
44
45PACKAGECONFIG[systemd] = ",,systemd"
46PACKAGECONFIG[openhpi] = "--with-hpi-interface=B03,,openhpi"
47PACKAGECONFIG[plm] = "--enable-ais-plm,--disable-ais-plm,libvirt openhpi"
48
49PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)}"
50
Brad Bishopc342db32019-05-15 21:57:59 -040051CPPFLAGS += "-Wno-error=stringop-overflow= -Wno-error=stringop-truncation"
52CXXFLAGS += "-Wno-error=stringop-overflow= -Wno-error=stringop-truncation -Wno-error=format-truncation="
53LDFLAGS += "-Wl,--as-needed -latomic -Wl,--no-as-needed"
54
55do_install_append() {
Brad Bishopc342db32019-05-15 21:57:59 -040056 rm -fr "${D}${localstatedir}/lock"
57 rm -fr "${D}${localstatedir}/run"
58 rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
59 rmdir --ignore-fail-on-non-empty "${D}${datadir}/java"
60 if [ ! -d "${D}${sysconfdir}/init.d" ]; then
61 install -d ${D}${sysconfdir}/init.d
62 install -m 0755 ${B}/osaf/services/infrastructure/nid/scripts/opensafd ${D}${sysconfdir}/init.d/
63 fi
64}
65
Brad Bishop36a3e3e2019-10-02 13:29:27 -040066FILES_${PN} += "${libdir}/libSa*.so ${systemd_unitdir}/system/*.service"
67FILES_${PN}-dev += "${libdir}/libopensaf_core.so"
Brad Bishopc342db32019-05-15 21:57:59 -040068FILES_${PN}-staticdev += "${PKGLIBDIR}/*.a"
69
70INSANE_SKIP_${PN} = "dev-so"
71
Andrew Geissler82c905d2020-04-13 13:39:40 -050072RDEPENDS_${PN} += "bash python3-core"
Brad Bishopc342db32019-05-15 21:57:59 -040073
74# http://errors.yoctoproject.org/Errors/Details/186970/
Brad Bishop0f291cc2019-09-01 15:16:57 -040075COMPATIBLE_HOST_libc-musl = 'null'
Brad Bishop36a3e3e2019-10-02 13:29:27 -040076
77FILES_SOLIBSDEV = ""