corosync_3.1.6.bb 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. SUMMARY = "The Corosync Cluster Engine and Application Programming Interfaces"
  2. DESCRIPTION = "This package contains the Corosync Cluster Engine Executive, several default \
  3. APIs and libraries, default configuration files, and an init script."
  4. HOMEPAGE = "http://corosync.github.io/corosync/"
  5. SECTION = "base"
  6. inherit autotools pkgconfig systemd
  7. SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/v${PV}/${BP}.tar.gz \
  8. file://corosync.conf \
  9. "
  10. SRC_URI[sha256sum] = "ca6ed32b4d7f33ed614afce8760fe58d0de92c68b575d4969ebacd892f3d1e27"
  11. UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.(?!99)\d+(\.\d+)+)"
  12. LICENSE = "BSD-3-Clause"
  13. LIC_FILES_CHKSUM = "file://LICENSE;md5=a85eb4ce24033adb6088dd1d6ffc5e5d"
  14. DEPENDS = "groff-native nss libqb kronosnet"
  15. SYSTEMD_SERVICE:${PN} = "corosync.service corosync-notifyd.service"
  16. SYSTEMD_AUTO_ENABLE = "disable"
  17. INITSCRIPT_NAME = "corosync-daemon"
  18. PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
  19. dbus snmp \
  20. "
  21. PACKAGECONFIG[dbus] = "--enable-dbus,--disable-dbus,dbus"
  22. PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp,net-snmp"
  23. PACKAGECONFIG[systemd] = "--enable-systemd --with-systemddir=${systemd_system_unitdir},--disable-systemd --without-systemddir,systemd"
  24. EXTRA_OECONF = "ac_cv_path_BASHPATH=${base_bindir}/bash ap_cv_cc_pie=no"
  25. EXTRA_OEMAKE = "tmpfilesdir_DATA="
  26. #do_configure:prepend() {
  27. # ( cd ${S}
  28. # ${S}/autogen.sh )
  29. #}
  30. do_install:append() {
  31. install -D -m 0644 ${UNPACKDIR}/corosync.conf ${D}${sysconfdir}/corosync/corosync.conf.example
  32. install -d ${D}${sysconfdir}/sysconfig/
  33. install -m 0644 ${S}/init/corosync.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync
  34. install -m 0644 ${S}/tools/corosync-notifyd.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync-notifyd
  35. rmdir ${D}${localstatedir}/log/cluster ${D}${localstatedir}/log
  36. rmdir --ignore-fail-on-non-empty ${D}${localstatedir}
  37. install -d ${D}${sysconfdir}/default/volatiles
  38. echo "d root root 0755 ${localstatedir}/log/cluster none" > ${D}${sysconfdir}/default/volatiles/05_corosync
  39. if [ ${@bb.utils.filter('DISTRO_FEATURES','systemd',d)} ]; then
  40. install -d ${D}${sysconfdir}/tmpfiles.d
  41. echo "d ${localstatedir}/log/cluster - - - -" > ${D}${sysconfdir}/tmpfiles.d/corosync.conf
  42. fi
  43. }
  44. RDEPENDS:${PN} += "bash ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}"
  45. FILES:${PN}-dbg += "${libexecdir}/lcrso/.debug"
  46. FILES:${PN}-doc += "${datadir}/snmp/mibs/COROSYNC-MIB.txt"