From f108a62e5936ae36c5238f8a1236594b68493f88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20B=C4=9Blka?= Date: Fri, 30 Aug 2019 02:23:31 +0200 Subject: [PATCH] New package: corosync-3.0.2 --- common/shlibs | 7 ++++ srcpkgs/corosync/INSTALL.msg | 6 +++ srcpkgs/corosync/files/corosync.conf | 24 ++++++++++++ srcpkgs/corosync/files/corosync/run | 3 ++ srcpkgs/corosync/template | 57 ++++++++++++++++++++++++++++ srcpkgs/corosynclib | 1 + srcpkgs/corosynclib-devel | 1 + 7 files changed, 99 insertions(+) create mode 100644 srcpkgs/corosync/INSTALL.msg create mode 100644 srcpkgs/corosync/files/corosync.conf create mode 100644 srcpkgs/corosync/files/corosync/run create mode 100644 srcpkgs/corosync/template create mode 120000 srcpkgs/corosynclib create mode 120000 srcpkgs/corosynclib-devel diff --git a/common/shlibs b/common/shlibs index 655134c53e5..f3df361eedd 100644 --- a/common/shlibs +++ b/common/shlibs @@ -3502,3 +3502,10 @@ liblog4c.so.3 log4c-1.2.4_1 libqb.so.0 libqb-1.0.5_1 libusbguard.so.0 usbguard-0.7.5_1 libknet.so.1 libknet1-1.11_1 +libsam.so.4 corosynclib-3.0.2_1 +libcfg.so.7 corosynclib-3.0.2_1 +libcpg.so.4 corosynclib-3.0.2_1 +libcmap.so.4 corosynclib-3.0.2_1 +libvotequorum.so.8 corosynclib-3.0.2_1 +libquorum.so.5 corosynclib-3.0.2_1 +libcorosync_common.so.4 corosynclib-3.0.2_1 diff --git a/srcpkgs/corosync/INSTALL.msg b/srcpkgs/corosync/INSTALL.msg new file mode 100644 index 00000000000..16b45796e7b --- /dev/null +++ b/srcpkgs/corosync/INSTALL.msg @@ -0,0 +1,6 @@ +An example configuration file was placed into /etc/corosync/ for test purpose, +with this configuration Corosync runs a 'voidlinux' cluster only locally. + +For real multi-node setup, Corosync uses UDP transport between ports 5404, 5405 +and 5406 for communication. If you are running a firewall, ensure that +communication on those ports are allowed between the servers. diff --git a/srcpkgs/corosync/files/corosync.conf b/srcpkgs/corosync/files/corosync.conf new file mode 100644 index 00000000000..2eaed8ba7ef --- /dev/null +++ b/srcpkgs/corosync/files/corosync.conf @@ -0,0 +1,24 @@ +# Please read the corosync.conf.5 manual page +totem { + version: 2 + cluster_name: voidlinux + +} + +logging { + to_stderr: yes + to_logfile: yes + logfile: /var/log/corosync/corosync.log +} + +quorum { + provider: corosync_votequorum +} + +nodelist { + node { + name: node1 + nodeid: 1 + ring0_addr: 127.0.0.1 + } +} diff --git a/srcpkgs/corosync/files/corosync/run b/srcpkgs/corosync/files/corosync/run new file mode 100644 index 00000000000..5b597145ee4 --- /dev/null +++ b/srcpkgs/corosync/files/corosync/run @@ -0,0 +1,3 @@ +#!/bin/sh +[ -r conf ] && . ./conf +exec /usr/bin/corosync -f ${OPTS:-} diff --git a/srcpkgs/corosync/template b/srcpkgs/corosync/template new file mode 100644 index 00000000000..8df9e202c46 --- /dev/null +++ b/srcpkgs/corosync/template @@ -0,0 +1,57 @@ +# Template file for 'corosync' +pkgname=corosync +version=3.0.2 +revision=1 +build_style=gnu-configure +configure_args="--disable-static --enable-monitoring --enable-snmp + --enable-xmlconf --with-logdir=/var/log/corosync" +make_dirs="/etc/corosync/uidgid.d 0755 root root + /etc/corosync/service.d 0755 root root + /var/log/corosync 0755 root root + /var/lib/corosync 0755 root root" +hostmakedepends="autoconf automake libtool pkg-config" +makedepends="libqb-devel libstatgrab-devel libtool net-snmp-devel nss-devel" +short_desc="Cluster engine daemon and utilities" +maintainer="Jiří Bělka " +license="BSD-2-Clause" +homepage="http://corosync.github.io/corosync" +distfiles="https://github.com/${pkgname}/${pkgname}/releases/download/v${version}/${pkgname}-${version}.tar.gz" +checksum=f237e3ddac41ec583cac9610a9ba9191592f09d3ed70bc687db7b60e3d2e26f5 + +# libknet1 is default transport but does not work with musl now +case "$XBPS_TARGET_MACHINE" in + *-musl) :;; + *) makedepends+=" libknet1-devel";; +esac + +pre_configure() { + autoreconf -vi +} + +post_install() { + rm -f ${DESTDIR}/etc/corosync/corosync.conf.example + rm -rf ${DESTDIR}/etc/init.d + rm -rf ${DESTDIR}/usr/lib/corosync/*.la + vinstall ${FILESDIR}/corosync.conf 644 etc/corosync + vlicense LICENSE + vsv corosync +} + +corosynclib_package() { + short_desc="Corosync libraries" + pkg_install() { + vmove "usr/lib/*.so*" + vlicense LICENSE + } +} + +corosynclib-devel_package() { + depends="corosynclib>=${version}_${revision}" + short_desc="Corosync libraries (development files)" + pkg_install() { + vmove usr/include/corosync + vmove "usr/lib/*.so" + vmove "usr/lib/pkgconfig" + vmove usr/share/man/man3 + } +} diff --git a/srcpkgs/corosynclib b/srcpkgs/corosynclib new file mode 120000 index 00000000000..f52d533f823 --- /dev/null +++ b/srcpkgs/corosynclib @@ -0,0 +1 @@ +corosync \ No newline at end of file diff --git a/srcpkgs/corosynclib-devel b/srcpkgs/corosynclib-devel new file mode 120000 index 00000000000..f52d533f823 --- /dev/null +++ b/srcpkgs/corosynclib-devel @@ -0,0 +1 @@ +corosync \ No newline at end of file