diff options
Diffstat (limited to 'pcr/cluster-glue/PKGBUILD')
-rw-r--r-- | pcr/cluster-glue/PKGBUILD | 242 |
1 files changed, 0 insertions, 242 deletions
diff --git a/pcr/cluster-glue/PKGBUILD b/pcr/cluster-glue/PKGBUILD deleted file mode 100644 index 684efe7c2..000000000 --- a/pcr/cluster-glue/PKGBUILD +++ /dev/null @@ -1,242 +0,0 @@ -# Maintainer: Márcio Silva <coadde@lavabit.com> - -pkgname=cluster-glue -_pkgname1=${pkgname::7} -_pkgname2=${pkgname:8} -_pkgname=${_pkgname1^}_${_pkgname2^} -pkgver=1.0.11 -pkgrel=11 -pkgdesc='Set of libraries, tools and utilities suitable for the Heartbeat/Pacemaker cluster stack (Linux-HA)' -arch=( - i686 - x86_64 - mips64el -) -group=linux-ha -url=http://$group.org/wiki/$_pkgname -license=( - GPL2 - LGPL2.1 -) -depends=( - curl - dbus-glib - glib2 - libaio - libesmtp - libltdl - libnet - libxml2 - net-snmp - openhpi - openipmi - openssh - python - util-linux - #vacm !!Is VA-Cluster Manager abandonware? - http://vacm.sourceforge.net/ - ver 2.0.5a - 2001/10/03!! -) -optdepends=net-tools -makedepends=( - help2man - libxslt - lynx - net-tools - openssh - valgrind - w3m -) -options=(!libtool) -provides=(ha-$_pkgname2) -conflicts=ha-$_pkgname2 -replaces=ha-$_pkgname2 -install=$pkgname.install -source=http://hg.$group.org/$_pkgname2/archive/$_pkgname2-$pkgver.tar.bz2 -sha512sums=35ac8ac555c39f24c11e3a768cc50eba051fe617edf4cdc0429dac73f45a472f144cfe6ec5faff575606f2b04ff76a2f732556d848b61410c2683d93ba928413 - -prepare() { - export _CLUSTER_USER=hacluster - export _CLUSTER_GROUP=haclient - _DGID=666 - _DUID=666 - - #verify the cluster user and group - if ! getent group $_CLUSTER_GROUP >/dev/null;then - msg 'BEFORE COMPILE THIS SOFTWARE YOU MUST CREATE A CLUSTER GROUP, EXECUTE AS ROOT:' - echo -e "# groupadd -r -g $_DGID $_CLUSTER_GROUP\n" - _EXITCODE=1 - fi - if ! getent passwd $_CLUSTER_USER >/dev/null;then - msg 'BEFORE COMPILE THIS SOFTWARE YOU MUST CREATE A CLUSTER USER, EXECUTE AS ROOT:' - echo -e "# useradd -r -g $_CLUSTER_GROUP -u $_DUID -d /var/lib/heartbeat/cores/$_CLUSTER_USER -s /sbin/nologin -c \"cluster user\" $_CLUSTER_USER\n" - _EXITCODE=1 - fi - if [[ $_EXITCODE -eq 1 ]] ;then - return 1 - fi - - cd $srcdir/Reusable-${_pkgname1^}-Components-$_pkgname2--$_pkgname2-$pkgver - sed -i 's|AM_CONFIG_HEADER|AC_CONFIG_HEADERS|; - s| -O0||; - s|AM_INIT_AUTOMAKE($PACKAGE_NAME, $PACKAGE_VERSION)|AM_INIT_AUTOMAKE|; - s|${localstatedir}/lock ${localstatedir}/spool/lock ${localstatedir}/spool/locks ${localstatedir}/lock|/run/lock|; - s|/sbin:/usr/sbin:/usr/local/sbin:/usr/local/bin|/usr/bin|; - ' configure.ac - sed -i 's|INCLUDES|AM_CPPFLAGS|; - ' $(grep -rl INCLUDES | grep Makefile.am) - - # fixing path - sed -i 's|bin/sh|usr/bin/bash|; - ' $(grep -rl bin/sh) - sed -i 's| /bin| /usr/bin|; - ' $(grep -rl ' /bin') - sed -i 's| /sbin| /usr/bin|; - ' $(grep -rl ' /sbin') - sed -i 's|usr/sbin|usr/bin|; - ' $(grep -rl usr/sbin) - #sed -i 's|/lib64|/lib|; - # ' $(grep -rl /lib64) - #sed -i 's|usr/libexec|usr/lib|; - # ' $(grep -rl usr/libexec) - sed -i 's|var/lock|run/lock|; - ' $(grep -rl var/lock) - sed -i 's|var/run|run|; - ' $(grep -rl var/run) - - # remove Open Source term - sed -i 's|Open Source / ||; - s|open source / ||; - s|Open Source|Free Software|; - s|open source|free software|; - s|Free Software Development Lab|Open Source Development Lab|; - ' $(grep -ril 'open source') - sed -i 's|OpenSource / ||; - s|opensource / ||; - s|OpenSource|FreeSoftware|; - s|opensource|freesoftware|; - s|freesoftware.org|opensource.org|; - s|http://www.opensource.org/|http://www.gnu.org/philosophy/free-sw.html|; - s|http://www.gnu.org/philosophy/free-sw.htmllicenses/osl-|http://opensource.org/licenses/osl-|; - s|http://www.gnu.org/philosophy/free-sw.htmlosd|http://opensource.org/osd|; - ' $(grep -ril opensource) - - # remove Linux term - sed -i 's|Linux,|GNU/Linux,|; - s|Linux and|GNU/Linux and|; - s|Linux distro|GNU/Linux distro|; - s|Linux distribution|GNU/Linux distribution|; - s|Linux machine|GNU/Linux machine|; - s|Linux Only|GNU/Linux Only|; - s|Linux only|GNU/Linux only|; - s|Linux operating|GNU/Linux operating|; - s|Linux OS|GNU/Linux OS|; - s|Linux platform|GNU/Linux platform|; - s|Linux software|GNU/Linux software|; - s|Linux specific|GNU/Linux specific|; - s|Linux system|GNU/Linux system|; - s|Linux will|GNU/Linux will|; - s|# Linux$|# GNU/Linux|; - s|# Linux.$|# GNU/Linux.|; - s|* Linux$|* GNU/Linux|; - s|* Linux.$|* GNU/Linux.|; - s|// Linux$|// GNU/Linux|; - s|// Linux.$|// GNU/Linux.|; - s|, Linux|, GNU/Linux|; - s|As Linux|As GNU/Linux|; - s|as Linux|as GNU/Linux|; - s|And Linux|And GNU/Linux|; - s|and Linux|and GNU/Linux|; - s|Be Linux|Be GNU/Linux|; - s|be Linux|be GNU/Linux|; - s|Because Linux|Because GNU/Linux|; - s|because Linux|because GNU/Linux|; - s|e.g. Linux|e.g. GNU/Linux|; - s|For Linux|For GNU/Linux|; - s|for Linux|for GNU/Linux|; - s|In Linux|In GNU/Linux|; - s|in Linux|in GNU/Linux|; - s|Like Linux|Like GNU/Linux|; - s|like Linux|like GNU/Linux|; - s|non-Linux|non GNU/Linux|; - s|Of Linux|Of GNU/Linux|; - s|of Linux|of GNU/Linux|; - s|On Linux|On GNU/Linux|; - s|on Linux|on GNU/Linux|; - s|OS type: Linux|OS type: GNU/Linux|; - s|Other Linux|Other GNU/Linux|; - s|other Linux|other GNU/Linux|; - s|The Linux|The GNU/Linux|; - s|the Linux|the GNU/Linux|; - s|Typically Linux|Typically GNU/Linux|; - s|typically Linux|typically GNU/Linux|; - s|To Linux|To GNU/Linux|; - s|to Linux|to GNU/Linux|; - s|Under Linux|Under GNU/Linux|; - s|under Linux|under GNU/Linux|; - s|ArchGNU/Linux|ArchLinux|; - s|e2fsprogs, typically GNU/Linux|e2fsprogs, typically Linux|; - s|GNU/GNU|GNU|; - s|GNU/Linux device|Linux device|; - s|GNU/Linux Director Daemon|Linux Director Daemon|; - s|GNU/Linux is a registered trademark of Linus Torvalds|Linux is a registered trademark of Linus Torvalds|; - s|GNU/Linux kernel|Linux kernel|; - s|GNU/Linux specific kernel|Linux specific kernel|; - s|GNU/Linux Standard Base|Linux Standard Base|; - s|GNU/Linux sysfs|Linux sysfs|; - s|GNU/Linux Virtual Server|Linux Virtual Server|; - s|GNU/Linux Watchdog|Linux Watchdog|; - s|GNU/Linux watchdog|Linux watchdog|; - s|GNU/LinuxHA|LinuxHA|; - s|GNU/Linux-HA|Linux-HA|; - s|GNU/LinuxSCSI|LinuxSCSI|; - s|HA GNU/Linux|HA Linux|; - s|High-Availability GNU/Linux|High-Availability Linux|; - s|MkGNU/Linux|MkLinux|; - s|SEGNU/Linux|SELinux|; - s|VA GNU/Linux Cluster|VA Linux Cluster|; - ' $(grep -rl Linux) -} - -build() { - cd $srcdir/Reusable-${_pkgname1^}-Components-$_pkgname2--$_pkgname2-$pkgver - setarch $CARCH ./autogen.sh - setarch $CARCH ./configure --prefix=/usr\ - --disable-ansi\ - --disable-fatal-warnings\ - --disable-static\ - --enable-doc\ - --enable-libnet\ - --enable-upstart\ - --libdir=/usr/lib\ - --localstatedir=/var\ - --sbindir=/usr/bin\ - --sysconfdir=/etc\ - --with-daemon-group=haclient\ - --with-daemon-user=hacluster\ - --with-ocf-root=/usr/lib/ocf - setarch $CARCH make -} - -package() { - cd $srcdir/Reusable-${_pkgname1^}-Components-$_pkgname2--$_pkgname2-$pkgver - setarch $CARCH make DESTDIR=$pkgdir install - - rm $pkgdir/etc/rc.d/logd && rmdir $pkgdir/etc{/rc.d,} - - install -d $pkgdir/usr/lib/systemd/system - echo '[Unit]' > $pkgdir/usr/lib/systemd/system/ha_log.service - echo 'Description=Startup script logd service' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo 'Requires=network.target remote-fs.target' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo '' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo '[Service]' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo 'Type=forking' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo 'ExecStart=/usr/lib/heartbeat/ha_logd' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo '' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo '[Install]' >> $pkgdir/usr/lib/systemd/system/ha_log.service - echo 'WantedBy=multi-user.target' >> $pkgdir/usr/lib/systemd/system/ha_log.service - - msg 'AFTER COMPILE THIS SOFTWARE YOU MUST DELETE A CLUSTER USER AND A CLUSTER GROUP, EXECUTE AS ROOT:' - echo -e "# userdel $_CLUSTER_USER" - echo -e "# groupdel $_CLUSTER_GROUP" -} - -# vim:set ts=2 sw=2 et: |