From 67cd47880b0bbbcbaec54b61cac6ab00afeb7c0e Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 15 Sep 2017 15:58:26 -0700 Subject: opensaf: Upgrade to 5.17.07 Signed-off-by: Khem Raj Signed-off-by: Martin Jansa Signed-off-by: Joe MacDonald --- .../opensaf/0001-Remove-unused-variables.patch | 43 -------- ..._dump.cc-Use-sys-wait.h-instead-of-wait.h.patch | 34 ++++++ ...sing-header-limits.h-for-_POSIX_HOST_NAME.patch | 122 +++++++++++++++++++++ .../recipes-daemons/opensaf/opensaf_5.17.07.bb | 67 +++++++++++ .../recipes-daemons/opensaf/opensaf_5.2.0.bb | 66 ----------- 5 files changed, 223 insertions(+), 109 deletions(-) delete mode 100644 meta-networking/recipes-daemons/opensaf/opensaf/0001-Remove-unused-variables.patch create mode 100644 meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch create mode 100644 meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch create mode 100644 meta-networking/recipes-daemons/opensaf/opensaf_5.17.07.bb delete mode 100644 meta-networking/recipes-daemons/opensaf/opensaf_5.2.0.bb (limited to 'meta-networking') diff --git a/meta-networking/recipes-daemons/opensaf/opensaf/0001-Remove-unused-variables.patch b/meta-networking/recipes-daemons/opensaf/opensaf/0001-Remove-unused-variables.patch deleted file mode 100644 index 1c88b81cd6..0000000000 --- a/meta-networking/recipes-daemons/opensaf/opensaf/0001-Remove-unused-variables.patch +++ /dev/null @@ -1,43 +0,0 @@ -From a441a75fbb8451268a8a57616c7158cddc1823aa Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Sat, 22 Apr 2017 12:40:19 -0700 -Subject: [PATCH] Remove unused variables - -Fixes build errors with gcc7 e.g. - -../opensaf-5.2.0/src/amf/amfd/imm.cc: In member function 'bool ImmObjCreate::immobj_update_required()': -../opensaf-5.2.0/src/amf/amfd/imm.cc:2174:28: error: unused variable 'pos' [-Werror=unused-variable] - std::string::size_type pos; - ^~~ -../opensaf-5.2.0/src/amf/amfd/imm.cc:2215:28: error: unused variable 'pos' [-Werror=unused-variable] - std::string::size_type pos; - ^~~ - -Signed-off-by: Khem Raj ---- - src/amf/amfd/imm.cc | 2 -- - 1 file changed, 2 deletions(-) - -diff --git a/src/amf/amfd/imm.cc b/src/amf/amfd/imm.cc -index 7932364..4f47b65 100644 ---- a/src/amf/amfd/imm.cc -+++ b/src/amf/amfd/imm.cc -@@ -2171,7 +2171,6 @@ bool ImmObjCreate::immobj_update_required() { - if (class_type == AVSV_SA_AMF_SI_ASSIGNMENT) { - std::string su_name; - std::string sisu_name; -- std::string::size_type pos; - while ((attribute = attrValues_[i++]) != nullptr) { - if (!strcmp(attribute->attrName, "safSISU")) { - sisu_name = Amf::to_string( -@@ -2212,7 +2211,6 @@ bool ImmObjCreate::immobj_update_required() { - } else if (class_type == AVSV_SA_AMF_CSI_ASSIGNMENT) { - std::string comp_name; - std::string csicomp_name; -- std::string::size_type pos; - AVD_CSI *csi = nullptr; - AVD_COMP *comp = nullptr; - AVD_COMP_CSI_REL *compcsi = nullptr; --- -2.12.2 - diff --git a/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch b/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch new file mode 100644 index 0000000000..76c47c6584 --- /dev/null +++ b/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch @@ -0,0 +1,34 @@ +From 508ea7c0d67243feb1684eaa83569cb687561d64 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 15 Sep 2017 10:09:03 -0700 +Subject: [PATCH] immpbe_dump.cc: Use sys/wait.h instead of wait.h + +Fixes +redirecting incorrect #include to + +Signed-off-by: Khem Raj +--- + src/imm/common/immpbe_dump.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/imm/common/immpbe_dump.cc b/src/imm/common/immpbe_dump.cc +index 100222f37..33e47ce3c 100644 +--- a/src/imm/common/immpbe_dump.cc ++++ b/src/imm/common/immpbe_dump.cc +@@ -26,12 +26,12 @@ + #include + #include + #include +-#include + #include + #include + #include + #include + #include ++#include + #include + + #include +-- +2.14.1 + diff --git a/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch b/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch new file mode 100644 index 0000000000..4a2a825f99 --- /dev/null +++ b/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch @@ -0,0 +1,122 @@ +From 6442b57a855e273aa5a3d93e8596783cea128073 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 15 Sep 2017 09:39:40 -0700 +Subject: [PATCH] src: Add missing header limits.h for _POSIX_HOST_NAME_MAX + +Use _GNU_SOURCE instead of libc internal __USE_GNU +Do not use the deprecated headers under include/sys + +Signed-off-by: Khem Raj +--- + src/base/os_defs.h | 5 +++-- + src/mds/mds_dt_tcp.c | 1 - + src/mds/mds_dt_tcp_disc.h | 2 +- + src/mds/mds_dt_tipc.c | 1 - + src/mds/mds_dt_tipc.h | 2 +- + src/mds/mds_dt_trans.c | 1 - + src/ntf/ntfd/NtfLogger.cc | 2 +- + 7 files changed, 6 insertions(+), 8 deletions(-) + +diff --git a/src/base/os_defs.h b/src/base/os_defs.h +index 50a9bf5fc..af6842863 100644 +--- a/src/base/os_defs.h ++++ b/src/base/os_defs.h +@@ -47,17 +47,18 @@ + #include + #include /* Added for message-queues : PM : 28/10/03 */ + #include +-#ifndef __USE_GNU ++#include ++#ifndef _GNU_SOURCE + struct msgbuf { + long int mtype; + char mtext[1]; + }; + #endif /* else defined in */ + #include +-#include + #include + #include + ++#include + #include + #include + +diff --git a/src/mds/mds_dt_tcp.c b/src/mds/mds_dt_tcp.c +index 1407eb1ab..a87c22faa 100644 +--- a/src/mds/mds_dt_tcp.c ++++ b/src/mds/mds_dt_tcp.c +@@ -27,7 +27,6 @@ + + #include + #include +-#include + #include + #include + #include +diff --git a/src/mds/mds_dt_tcp_disc.h b/src/mds/mds_dt_tcp_disc.h +index a6249d73e..574f52681 100644 +--- a/src/mds/mds_dt_tcp_disc.h ++++ b/src/mds/mds_dt_tcp_disc.h +@@ -24,7 +24,7 @@ + #include "base/ncssysf_tsk.h" + #include "base/ncssysf_mem.h" + #include "mds_dt_tcp_disc.h" +-#include "sys/poll.h" ++#include + + /* mds_indentifire + mds_version + msg_type + scope_type + server_type + + server_instance_lower + server_instance_upper + sub_ref_val + sub_ref_val + +diff --git a/src/mds/mds_dt_tipc.c b/src/mds/mds_dt_tipc.c +index 37745e7f0..9b3255567 100644 +--- a/src/mds/mds_dt_tipc.c ++++ b/src/mds/mds_dt_tipc.c +@@ -35,7 +35,6 @@ + #include + #include + #include +-#include + #include + #include + #include +diff --git a/src/mds/mds_dt_tipc.h b/src/mds/mds_dt_tipc.h +index e73a11b09..401d208c2 100644 +--- a/src/mds/mds_dt_tipc.h ++++ b/src/mds/mds_dt_tipc.h +@@ -32,7 +32,7 @@ + #include + #include + #include +-#include ++#include + #include + #include + #include +diff --git a/src/mds/mds_dt_trans.c b/src/mds/mds_dt_trans.c +index 6f621e04e..5aacbd33e 100644 +--- a/src/mds/mds_dt_trans.c ++++ b/src/mds/mds_dt_trans.c +@@ -26,7 +26,6 @@ + #include "mds_core.h" + #include "base/osaf_utility.h" + +-#include + #include + + #define MDS_PROT_TCP 0xA0 +diff --git a/src/ntf/ntfd/NtfLogger.cc b/src/ntf/ntfd/NtfLogger.cc +index 84014b578..31b1ccc6c 100644 +--- a/src/ntf/ntfd/NtfLogger.cc ++++ b/src/ntf/ntfd/NtfLogger.cc +@@ -20,7 +20,7 @@ + * INCLUDE FILES + * ======================================================================== + */ +-#include ++#include + + #include "base/osaf_utility.h" + #include +-- +2.14.1 + diff --git a/meta-networking/recipes-daemons/opensaf/opensaf_5.17.07.bb b/meta-networking/recipes-daemons/opensaf/opensaf_5.17.07.bb new file mode 100644 index 0000000000..74483d7786 --- /dev/null +++ b/meta-networking/recipes-daemons/opensaf/opensaf_5.17.07.bb @@ -0,0 +1,67 @@ +SUMMARY = "OpenSAF is an open source implementation of the SAF AIS specification" +DESCRIPTION = "OpenSAF is an open source project established to develop a base platform \ +middleware consistent with Service Availability Forum (SA Forum) \ +specifications, under the LGPLv2.1 license. The OpenSAF Foundation was \ +established by leading Communications and Enterprise Computing Companies to \ +facilitate the OpenSAF Project and to accelerate the adoption of the OpenSAF \ +code base in commercial products. \ +The OpenSAF project was launched in mid 2007 and has been under development by \ +an informal group of supporters of the OpenSAF initiative. The OpenSAF \ +Foundation was founded on January 22nd 2008 with Emerson Network Power, \ +Ericsson, Nokia Siemens Networks, HP and Sun Microsystems as founding members." +HOMEPAGE = "http://www.opensaf.org" +SECTION = "admin" +LICENSE = "LGPLv2.1" +LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7" + +DEPENDS = "libxml2 python" +TOOLCHAIN = "gcc" + +SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}" + +SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/releases/${BPN}-${PV}.tar.gz \ + file://0001-configure-Pass-linker-specific-options-with-Wl.patch \ + file://0001-configure-Disable-format-overflow-if-supported-by-gc.patch \ + file://0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch \ + file://0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch \ +" +SRC_URI[md5sum] = "125bcd9aabd7412aedcbfbf73f4e6196" +SRC_URI[sha256sum] = "3fb2239bb2c9328c8b45368ff8d8de979ea286a27edc9871d218200e88bb91cc" + +inherit autotools useradd systemd pkgconfig + +USERADD_PACKAGES = "${PN}" +GROUPADD_PARAM_${PN} = "-f -r opensaf" +USERADD_PARAM_${PN} = "-r -g opensaf -d ${datadir}/opensaf/ -s ${sbindir}/nologin -c \"OpenSAF\" opensaf" + +SYSTEMD_SERVICE_${PN} += "opensafd.service" +SYSTEMD_AUTO_ENABLE = "disable" + +PACKAGECONFIG[systemd] = ",,systemd" +PACKAGECONFIG[openhpi] = "--with-hpi-interface=B03 --enable-ais-plm,,openhpi" + +PACKAGECONFIG_append = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)}" + +PKGLIBDIR="${libdir}" + +LDFLAGS += "-Wl,--as-needed -latomic -Wl,--no-as-needed" + +do_install_append() { + cp -av --no-preserve=ownership ${B}/lib/.libs/*.so* ${D}${libdir} + rm -fr "${D}${localstatedir}/lock" + rm -fr "${D}${localstatedir}/run" + rmdir --ignore-fail-on-non-empty "${D}${localstatedir}" + rmdir --ignore-fail-on-non-empty "${D}${datadir}/java" + if [ ! -d "${D}${sysconfdir}/init.d" ]; then + install -d ${D}${sysconfdir}/init.d + install -m 0755 ${B}/osaf/services/infrastructure/nid/scripts/opensafd ${D}${sysconfdir}/init.d/ + fi +} + +FILES_${PN} += "${systemd_unitdir}/system/*.service" +FILES_${PN}-staticdev += "${PKGLIBDIR}/*.a" + +INSANE_SKIP_${PN} = "dev-so" + +RDEPENDS_${PN} += "bash python" + diff --git a/meta-networking/recipes-daemons/opensaf/opensaf_5.2.0.bb b/meta-networking/recipes-daemons/opensaf/opensaf_5.2.0.bb deleted file mode 100644 index be79ba8cb0..0000000000 --- a/meta-networking/recipes-daemons/opensaf/opensaf_5.2.0.bb +++ /dev/null @@ -1,66 +0,0 @@ -SUMMARY = "OpenSAF is an open source implementation of the SAF AIS specification" -DESCRIPTION = "OpenSAF is an open source project established to develop a base platform \ -middleware consistent with Service Availability Forum (SA Forum) \ -specifications, under the LGPLv2.1 license. The OpenSAF Foundation was \ -established by leading Communications and Enterprise Computing Companies to \ -facilitate the OpenSAF Project and to accelerate the adoption of the OpenSAF \ -code base in commercial products. \ -The OpenSAF project was launched in mid 2007 and has been under development by \ -an informal group of supporters of the OpenSAF initiative. The OpenSAF \ -Foundation was founded on January 22nd 2008 with Emerson Network Power, \ -Ericsson, Nokia Siemens Networks, HP and Sun Microsystems as founding members." -HOMEPAGE = "http://www.opensaf.org" -SECTION = "admin" -LICENSE = "LGPLv2.1" -LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7" - -DEPENDS = "libxml2 python" -TOOLCHAIN = "gcc" - -SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}" - -SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/releases/${BPN}-${PV}.tar.gz \ - file://0001-configure-Pass-linker-specific-options-with-Wl.patch \ - file://0001-configure-Disable-format-overflow-if-supported-by-gc.patch \ - file://0001-Remove-unused-variables.patch \ -" -SRC_URI[md5sum] = "08991fd467ae9dcea3c8747be8e3981e" -SRC_URI[sha256sum] = "903478244afe37e329be93050f1d48fa18c84ea17862134c4217b920e267a04a" - -inherit autotools useradd systemd pkgconfig - -USERADD_PACKAGES = "${PN}" -GROUPADD_PARAM_${PN} = "-f -r opensaf" -USERADD_PARAM_${PN} = "-r -g opensaf -d ${datadir}/opensaf/ -s ${sbindir}/nologin -c \"OpenSAF\" opensaf" - -SYSTEMD_SERVICE_${PN} += "opensafd.service" -SYSTEMD_AUTO_ENABLE = "disable" - -PACKAGECONFIG[systemd] = ",,systemd" -PACKAGECONFIG[openhpi] = "--with-hpi-interface=B03 --enable-ais-plm,,openhpi" - -PACKAGECONFIG_append = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)}" - -PKGLIBDIR="${libdir}" - -LDFLAGS += "-Wl,--as-needed -latomic -Wl,--no-as-needed" - -do_install_append() { - cp -av --no-preserve=ownership ${B}/lib/.libs/*.so* ${D}${libdir} - rm -fr "${D}${localstatedir}/lock" - rm -fr "${D}${localstatedir}/run" - rmdir --ignore-fail-on-non-empty "${D}${localstatedir}" - rmdir --ignore-fail-on-non-empty "${D}${datadir}/java" - if [ ! -d "${D}${sysconfdir}/init.d" ]; then - install -d ${D}${sysconfdir}/init.d - install -m 0755 ${B}/osaf/services/infrastructure/nid/scripts/opensafd ${D}${sysconfdir}/init.d/ - fi -} - -FILES_${PN} += "${systemd_unitdir}/system/*.service" -FILES_${PN}-staticdev += "${PKGLIBDIR}/*.a" - -INSANE_SKIP_${PN} = "dev-so" - -RDEPENDS_${PN} += "bash python" - -- cgit v1.2.3-54-g00ecf