summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoman I Khimov <khimov@altell.ru>2010-03-29 21:10:31 +0400
committerRoman I Khimov <khimov@altell.ru>2010-03-29 21:10:31 +0400
commit43ef9ce201c851db5df63b55bc5471b405312a47 (patch)
tree41138335df5f0efa62c6dac8ac909dd7f3cd6cdd
parent21c2b8d91037076aa40279dd8285d00a977c7e53 (diff)
parentb064810bbb62b6dab5a88cba539258eff9a4e603 (diff)
Merge branch 'pacemaker' into org.openembedded.dev
-rw-r--r--recipes/corosync/corosync_1.2.0.bb35
-rw-r--r--recipes/corosync/files/corosync.conf52
-rw-r--r--recipes/corosync/files/fix-lcrso-linkage.patch43
-rw-r--r--recipes/corosync/files/init152
-rw-r--r--recipes/corosync/files/volatiles2
-rw-r--r--recipes/glib-2.0/glib-2.0-2.23.6/gatomic-proper-pointer-get-cast.patch13
-rw-r--r--recipes/glib-2.0/glib-2.0_2.23.6.bb3
-rw-r--r--recipes/linux-ha/cluster-glue/glue-remove-getpid-check.patch33
-rw-r--r--recipes/linux-ha/cluster-glue/volatiles6
-rw-r--r--recipes/linux-ha/cluster-glue_1.0.3.bb88
-rw-r--r--recipes/linux-ha/cluster-resource-agents_1.0.2.bb70
-rw-r--r--recipes/openais/files/fix-lcrso-linkage.patch21
-rw-r--r--recipes/openais/openais_1.1.2.bb14
-rw-r--r--recipes/pacemaker/files/volatiles7
-rw-r--r--recipes/pacemaker/pacemaker-1.0.8/pacemaker-dont-use-help2man.patch16
-rw-r--r--recipes/pacemaker/pacemaker-1.0.8/pacemaker-remove-native-includes.patch22
-rw-r--r--recipes/pacemaker/pacemaker_1.0.8.bb73
17 files changed, 649 insertions, 1 deletions
diff --git a/recipes/corosync/corosync_1.2.0.bb b/recipes/corosync/corosync_1.2.0.bb
new file mode 100644
index 0000000000..758f45577d
--- /dev/null
+++ b/recipes/corosync/corosync_1.2.0.bb
@@ -0,0 +1,35 @@
+DESCRIPTION = "OSI Certified implementation of a complete cluster engine"
+LICENSE = "BSD"
+
+SRC_URI = " \
+ ftp://ftp@corosync.org/downloads/corosync-${PV}/corosync-${PV}.tar.gz;name=tar \
+ file://fix-lcrso-linkage.patch;patch=1 \
+ file://init \
+ file://corosync.conf \
+ file://volatiles \
+ "
+SRC_URI[tar.md5sum] = "789bea831a97977e56900477c3022cc1"
+SRC_URI[tar.sha256sum] = "3cee3be9f747c7031da9eafdffa5e3009513f4ac93ce021a49574e3de1fd93f0"
+
+inherit autotools_stage update-rc.d
+
+INITSCRIPT_NAME = "corosync-daemon"
+
+EXTRA_OECONF = "--disable-nss"
+
+FILES_${PN}-dbg += "${libexecdir}/lcrso/.debug"
+
+do_install_append() {
+ install -d ${D}/${sysconfdir}/init.d
+ install -d ${D}${sysconfdir}/default/volatiles
+ install -m 0755 ${WORKDIR}/init ${D}/${sysconfdir}/init.d/corosync-daemon
+ install -m 0644 ${WORKDIR}/corosync.conf ${D}/${sysconfdir}/corosync/corosync.conf.example
+ install -m 0644 ${WORKDIR}/volatiles ${D}${sysconfdir}/default/volatiles/05_corosync
+}
+
+pkg_postinst_${PN} () {
+ set -e
+ grep haclient /etc/group || addgroup haclient
+ grep hacluster /etc/passwd || adduser --disabled-password --home=/var/lib/heartbeat --ingroup haclient -g "HA cluster" hacluster
+ /etc/init.d/populate-volatile.sh update
+}
diff --git a/recipes/corosync/files/corosync.conf b/recipes/corosync/files/corosync.conf
new file mode 100644
index 0000000000..4caea969ec
--- /dev/null
+++ b/recipes/corosync/files/corosync.conf
@@ -0,0 +1,52 @@
+# Starting point for cluster with pacemaker/openais
+compatibility: none
+
+corosync {
+ user: root
+ group: root
+}
+
+aisexec {
+ with Pacemaker
+ user: root
+ group: root
+}
+
+service {
+ name: pacemaker
+ ver: 0
+}
+
+totem {
+ version: 2
+ secauth: off
+ threads: 0
+ interface {
+ ringnumber: 0
+ # Cluster network address
+ bindnetaddr: 192.168.10.0
+ # Should be fine in most cases, don't forget to allow
+ # packets for this address/port in netfilter if there
+ # is restrictive policy set for cluster network
+ mcastaddr: 226.94.1.1
+ mcastport: 5405
+ }
+}
+
+logging {
+ fileline: off
+ to_stderr: yes
+ to_logfile: yes
+ to_syslog: yes
+ logfile: /var/log/corosync.log
+ debug: off
+ timestamp: on
+ logger_subsys {
+ subsys: AMF
+ debug: off
+ }
+}
+
+amf {
+ mode: disabled
+}
diff --git a/recipes/corosync/files/fix-lcrso-linkage.patch b/recipes/corosync/files/fix-lcrso-linkage.patch
new file mode 100644
index 0000000000..18334a9554
--- /dev/null
+++ b/recipes/corosync/files/fix-lcrso-linkage.patch
@@ -0,0 +1,43 @@
+Index: corosync-1.2.0/exec/Makefile.am
+===================================================================
+--- corosync-1.2.0.orig/exec/Makefile.am 2010-03-22 22:25:00.000000000 +0300
++++ corosync-1.2.0/exec/Makefile.am 2010-03-22 22:25:40.000000000 +0300
+@@ -122,7 +122,7 @@
+ else
+
+ %.lcrso: %.o
+- $(CC) $(CFLAGS) -shared -Wl,-soname=$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ $^ -o $@
+
+ libtotem_pg.so.$(SONAME): $(TOTEM_OBJS)
+ $(CC) -shared -o $@ \
+Index: corosync-1.2.0/lcr/Makefile.am
+===================================================================
+--- corosync-1.2.0.orig/lcr/Makefile.am 2010-03-22 22:25:10.000000000 +0300
++++ corosync-1.2.0/lcr/Makefile.am 2010-03-22 22:26:02.000000000 +0300
+@@ -62,7 +62,7 @@
+ else
+
+ %.lcrso: %.o
+- $(CC) $(CFLAGS) -shared -Wl,-soname,$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname,$@ $^ -o $@
+
+ endif
+
+Index: corosync-1.2.0/services/Makefile.am
+===================================================================
+--- corosync-1.2.0.orig/services/Makefile.am 2010-03-22 22:25:15.000000000 +0300
++++ corosync-1.2.0/services/Makefile.am 2010-03-22 22:26:32.000000000 +0300
+@@ -68,10 +68,10 @@
+
+ else
+ quorum_%.lcrso: %.o
+- $(CC) $(CFLAGS) -shared -Wl,-soname=$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ $^ -o $@
+
+ service_%.lcrso: %.o
+- $(CC) $(CFLAGS) -shared -Wl,-soname=$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ $^ -o $@
+ endif
+
+ endif
diff --git a/recipes/corosync/files/init b/recipes/corosync/files/init
new file mode 100644
index 0000000000..fc45f433a4
--- /dev/null
+++ b/recipes/corosync/files/init
@@ -0,0 +1,152 @@
+#!/bin/sh
+#
+# corosync Start the Corosync Cluster Engine
+#
+# Author: Andrew Beekhof <abeekhof@suse.de>
+# License: Revised BSD
+#
+# chkconfig: - 20 20
+# processname: corosync
+# description: Corosync Cluster Engine
+#
+### BEGIN INIT INFO
+# Description: corosync....
+#
+# Short-Description: Corosync Cluster Engine.
+# Provides: corosync
+# Required-Start: $network
+# Should-Start: $syslog
+# Required-Stop: $network
+# Default-Start: 3 5
+# Default-Stop: 0 6
+### END INIT INFO
+
+do_force=0
+prog="corosync"
+lockfile="/var/lock/subsys/$prog"
+configfile="/etc/corosync/corosync.conf"
+
+if [ ! -f "$configfile" ]; then
+ echo "Error: corosync is not configured ($configfile missing)"
+ exit 1
+fi
+
+internal_status() {
+ killall -0 corosync > /dev/null 2>&1
+ return $?
+}
+
+status() {
+ if
+ ! internal_status
+ then
+ echo "Stopped"
+ return 7
+ fi
+
+ echo "Running"
+ return 0
+}
+
+start() {
+ echo -n $"Starting Corosync Cluster Engine ($prog): "
+ if
+ ! internal_status
+ then
+ echo -n "starting... "
+ $prog 2>&1 > /dev/null 2>&1
+ echo -n "rc=$?: "
+ fi
+
+ sleep 2 # give it time to fail... $? isn't definitive
+
+ if
+ internal_status
+ then
+ echo "OK"
+ return 0
+ fi
+
+ echo "Failed"
+ return 1
+}
+
+do_force=1
+do_forever=0
+
+stop() {
+ echo -n $"Stopping Corosync Cluster Engine ($prog): "
+
+ killall -QUIT corosync
+
+ if [ $do_forever = 0 ]; then
+ for i in 1 2 3 4 5 6 7 8 9 10 12 13 14 15 16 17 18 19 20; do
+ if
+ internal_status
+ then
+ sleep 2
+ echo -n "."
+ else
+ rm -f "$lockfile"
+ echo "OK"
+ return 0
+ fi
+ done
+
+ if [ $do_force = 1 ]; then
+ echo -n "Escalating... "
+ killall -KILL corosync
+ ps | grep /usr/lib/heartbeat | sed "s,^ *,," | cut -f 1 -d ' ' | xargs kill -9
+ sleep 5
+
+ if
+ ! internal_status
+ then
+ rm -f "$lockfile"
+ echo "OK"
+ return 0
+ fi
+ fi
+
+ echo "Failed"
+ return 1
+ fi
+
+ while
+ internal_status
+ do
+ sleep 1
+ echo -n "."
+ done
+
+ rm -f "$lockfile"
+ echo "OK"
+ return 0
+}
+
+restart() {
+ stop
+ start
+}
+
+case "$1" in
+ start|stop|restart)
+ $1
+ ;;
+ force-stop)
+ do_force=1
+ stop
+ ;;
+ reload|force-reload)
+ restart
+ ;;
+ condrestart|try-restart)
+ [ ! -f "$lockfile" ] || restart
+ ;;
+ status)
+ status $prog
+ ;;
+ *)
+ echo $"Usage: $0 {start|stop|restart|try-restart|condrestart|reload|force-reload|force-stop|status}"
+ exit 2
+esac
diff --git a/recipes/corosync/files/volatiles b/recipes/corosync/files/volatiles
new file mode 100644
index 0000000000..d778fe10c9
--- /dev/null
+++ b/recipes/corosync/files/volatiles
@@ -0,0 +1,2 @@
+d hacluster haclient 0755 /var/lib/corosync none
+
diff --git a/recipes/glib-2.0/glib-2.0-2.23.6/gatomic-proper-pointer-get-cast.patch b/recipes/glib-2.0/glib-2.0-2.23.6/gatomic-proper-pointer-get-cast.patch
new file mode 100644
index 0000000000..5e8f836cb2
--- /dev/null
+++ b/recipes/glib-2.0/glib-2.0-2.23.6/gatomic-proper-pointer-get-cast.patch
@@ -0,0 +1,13 @@
+Index: glib-2.23.6/glib/gatomic.h
+===================================================================
+--- glib-2.23.6.orig/glib/gatomic.h 2010-03-29 13:01:28.000000000 +0400
++++ glib-2.23.6/glib/gatomic.h 2010-03-29 13:01:35.000000000 +0400
+@@ -70,7 +70,7 @@
+ (g_atomic_int_set) ((volatile gint G_GNUC_MAY_ALIAS *) (void *) (atomic), (newval)))
+ # define g_atomic_pointer_get(atomic) \
+ ((void) sizeof (gchar [sizeof (*(atomic)) == sizeof (gpointer) ? 1 : -1]), \
+- (g_atomic_pointer_get) ((volatile gpointer G_GNUC_MAY_ALIAS *) (void *) (atomic)))
++ (g_atomic_pointer_get) ((volatile gpointer G_GNUC_MAY_ALIAS *) (volatile void G_GNUC_MAY_ALIAS *) (atomic)))
+ # define g_atomic_pointer_set(atomic, newval) \
+ ((void) sizeof (gchar [sizeof (*(atomic)) == sizeof (gpointer) ? 1 : -1]), \
+ (g_atomic_pointer_set) ((volatile gpointer G_GNUC_MAY_ALIAS *) (void *) (atomic), (newval)))
diff --git a/recipes/glib-2.0/glib-2.0_2.23.6.bb b/recipes/glib-2.0/glib-2.0_2.23.6.bb
index 68d401ad1a..dfbda5cd30 100644
--- a/recipes/glib-2.0/glib-2.0_2.23.6.bb
+++ b/recipes/glib-2.0/glib-2.0_2.23.6.bb
@@ -7,13 +7,14 @@ LICENSE = "LGPL"
SECTION = "libs"
PRIORITY = "optional"
DEPENDS = "glib-2.0-native gtk-doc virtual/libiconv virtual/libintl zlib"
-PR = "r1"
+PR = "r2"
SRC_URI = "\
http://ftp.gnome.org/pub/GNOME/sources/glib/2.23/glib-${PV}.tar.bz2;name=archive \
file://glibconfig-sysdefs.h \
file://configure-libtool.patch;patch=1 \
file://g_once_init_enter.patch;patch=1 \
+ file://gatomic-proper-pointer-get-cast.patch;patch=1 \
"
SRC_URI[archive.md5sum] = "72e6eadc16d7022376ecef12c6fe905e"
SRC_URI[archive.sha256sum] = "f91840e27ad4cd48e655a6babed7e2024f86814f94961da88ca2adba447c6e77"
diff --git a/recipes/linux-ha/cluster-glue/glue-remove-getpid-check.patch b/recipes/linux-ha/cluster-glue/glue-remove-getpid-check.patch
new file mode 100644
index 0000000000..b202ecc719
--- /dev/null
+++ b/recipes/linux-ha/cluster-glue/glue-remove-getpid-check.patch
@@ -0,0 +1,33 @@
+Index: Reusable-Cluster-Components-glue-1.0/configure.ac
+===================================================================
+--- Reusable-Cluster-Components-glue-1.0.orig/configure.ac 2009-10-20 17:16:25.000000000 +0400
++++ Reusable-Cluster-Components-glue-1.0/configure.ac 2009-10-20 17:25:00.000000000 +0400
+@@ -428,25 +428,9 @@
+ AC_MSG_RESULT($BUILD_VERSION)
+ AC_SUBST(BUILD_VERSION)
+
+-
+-dnl check if there are getpid() inconsistency
+-dnl Note: reduce LIBS; in particular, ltdl can cause confusion.
+-dnl Possibly better: move 'LIBS="$LIBS -lltdl"' from above to beyond here.
+-dnl
+-AC_MSG_CHECKING(for getpid() consistency in multi-process/threads program)
+-ac_save_LIBS=$LIBS
+-LIBS="-lpthread"
+-AC_TRY_RUN(`cat $srcdir/config/pidtest.c`,
+-AC_MSG_RESULT(ok),
+-[AC_MSG_RESULT(fail); AC_DEFINE(GETPID_INCONSISTENT, 1 , [pid inconsistent])],)
+-LIBS=$ac_save_LIBS
+-
+-dnl check byte order
+-AC_MSG_CHECKING(for byteorder)
+-AC_TRY_RUN(`cat $srcdir/config/byteorder_test.c`,
+-[AC_MSG_RESULT(little-endian); AC_DEFINE(CONFIG_LITTLE_ENDIAN, 1, [little-endian])],
+-[AC_MSG_RESULT(big-endian); AC_DEFINE(CONFIG_BIG_ENDIAN, 1, [big-endian])],)
+-
++AC_C_BIGENDIAN(
++ [AC_DEFINE(CONFIG_BIG_ENDIAN, 1, [big])],
++ [AC_DEFINE(CONFIG_LITTLE_ENDIAN, 1, [little])])
+
+ dnl ===============================================
+ dnl Program Paths
diff --git a/recipes/linux-ha/cluster-glue/volatiles b/recipes/linux-ha/cluster-glue/volatiles
new file mode 100644
index 0000000000..892db1b7c8
--- /dev/null
+++ b/recipes/linux-ha/cluster-glue/volatiles
@@ -0,0 +1,6 @@
+d root root 0755 /var/lib/heartbeat none
+d hacluster haclient 0750 /var/lib/heartbeat/pengine none
+d hacluster haclient 0755 /var/lib/heartbeat/cores none
+d hacluster haclient 0700 /var/lib/heartbeat/cores/hacluster none
+d root root 0700 /var/lib/heartbeat/cores/root none
+d nobody nogroup 0700 /var/lib/heartbeat/cores/nobody none \ No newline at end of file
diff --git a/recipes/linux-ha/cluster-glue_1.0.3.bb b/recipes/linux-ha/cluster-glue_1.0.3.bb
new file mode 100644
index 0000000000..774b83c09e
--- /dev/null
+++ b/recipes/linux-ha/cluster-glue_1.0.3.bb
@@ -0,0 +1,88 @@
+DESCRIPTION = "Cluster Glue is a set of libraries, tools and utilities suitable for \
+the Heartbeat/Pacemaker cluster stack. In essence, Glue is everything that \
+is not the cluster messaging layer (Heartbeat), nor the cluster resource manager \
+(Pacemaker), nor a Resource Agent."
+
+LICENSE = "GPL"
+DEPENDS = "libxml2 libtool glib-2.0 bzip2 util-linux-ng"
+
+SRC_URI = " \
+ http://hg.linux-ha.org/glue/archive/glue-${PV}.tar.bz2;name=tar \
+ file://glue-remove-getpid-check.patch;patch=1 \
+ file://volatiles \
+ "
+SRC_URI[tar.md5sum] = "f13746a8f3e8db1fa9c682d9db892573"
+SRC_URI[tar.sha256sum] = "fb1e4b75779849daf0f2c2c93668dd2a33d304307554f3d617b07f1957c61c9f"
+
+inherit autotools_stage
+
+S = "${WORKDIR}/Reusable-Cluster-Components-glue-${PV}"
+
+EXTRA_OECONF = "--with-daemon-user=hacluster --with-daemon-group=haclient"
+
+do_install_append() {
+ install -d ${D}${sysconfdir}/default/volatiles
+ install -m 0644 ${WORKDIR}/volatiles ${D}${sysconfdir}/default/volatiles/04_cluster-glue
+}
+
+pkg_postinst_${PN} () {
+ set -e
+ grep haclient /etc/group || addgroup haclient
+ grep hacluster /etc/passwd || adduser --disabled-password --home=${localstatedir}/lib/heartbeat --ingroup haclient -g "HA cluster" hacluster
+ /etc/init.d/populate-volatile.sh update
+}
+
+PACKAGES += "\
+ ${PN}-plugin-test \
+ ${PN}-plugin-test-dbg \
+ ${PN}-plugin-test-dev \
+ ${PN}-plugin-stonith2 \
+ ${PN}-plugin-stonith2-dbg \
+ ${PN}-plugin-stonith2-dev \
+ ${PN}-plugin-stonith2-ribcl \
+ ${PN}-plugin-stonith-external \
+ ${PN}-plugin-raexec \
+ ${PN}-plugin-raexec-dbg \
+ ${PN}-plugin-raexec-dev \
+ ${PN}-plugin-interfacemgr \
+ ${PN}-plugin-interfacemgr-dbg \
+ ${PN}-plugin-interfacemgr-dev \
+ ${PN}-lrmtest \
+ "
+
+FILES_${PN} += " \
+ /usr/lib/heartbeat/transient-test.sh \
+ /usr/lib/heartbeat/logtest \
+ /usr/lib/heartbeat/ipctransientserver \
+ /usr/lib/heartbeat/base64_md5_test \
+ /usr/lib/heartbeat/ipctest \
+ /usr/lib/heartbeat/ipctransientclient \
+ /usr/lib/heartbeat/ha_logd \
+ /usr/lib/heartbeat/lrmd \
+ "
+
+FILES_${PN}-dbg += "/usr/lib/heartbeat/.debug/"
+
+FILES_${PN}-plugin-test = "/usr/lib/heartbeat/plugins/test/test.so"
+FILES_${PN}-plugin-test-dev = "/usr/lib/heartbeat/plugins/test/test.*a"
+FILES_${PN}-plugin-test-dbg = "/usr/lib/heartbeat/plugins/test/.debug/"
+FILES_${PN}-plugin-stonith2 = " \
+ /usr/lib/stonith/plugins/xen0-ha-dom0-stonith-helper \
+ /usr/lib/stonith/plugins/stonith2/*.so \
+ "
+FILES_${PN}-plugin-stonith2-ribcl = "/usr/lib/stonith/plugins/stonith2/ribcl.py"
+RDEPENDS_${PN}-plugin-stonith2-ribcl += "python"
+
+FILES_${PN}-plugin-stonith2-dbg = "/usr/lib/stonith/plugins/stonith2/.debug/"
+FILES_${PN}-plugin-stonith2-dev = "/usr/lib/stonith/plugins/stonith2/*.*a"
+
+FILES_${PN}-plugin-stonith-external = "/usr/lib/stonith/plugins/external/"
+FILES_${PN}-plugin-raexec = "/usr/lib/heartbeat/plugins/RAExec/*.so"
+FILES_${PN}-plugin-raexec-dev = "/usr/lib/heartbeat/plugins/RAExec/*.*a"
+FILES_${PN}-plugin-raexec-dbg = "/usr/lib/heartbeat/plugins/RAExec/.debug/"
+
+FILES_${PN}-plugin-interfacemgr = "/usr/lib/heartbeat/plugins/InterfaceMgr/generic.so"
+FILES_${PN}-plugin-interfacemgr-dev = "/usr/lib/heartbeat/plugins/InterfaceMgr/generic.*a"
+FILES_${PN}-plugin-interfacemgr-dbg = "/usr/lib/heartbeat/plugins/InterfaceMgr/.debug/"
+
+FILES_${PN}-lrmtest = "/usr/share/glue/lrmtest/"
diff --git a/recipes/linux-ha/cluster-resource-agents_1.0.2.bb b/recipes/linux-ha/cluster-resource-agents_1.0.2.bb
new file mode 100644
index 0000000000..cdc81659de
--- /dev/null
+++ b/recipes/linux-ha/cluster-resource-agents_1.0.2.bb
@@ -0,0 +1,70 @@
+DESCRIPTION = "OCF resource agents for use by compatible cluster managers"
+LICENSE = "GPL"
+DEPENDS = "cluster-glue"
+
+SRC_URI = "http://hg.linux-ha.org/agents/archive/agents-${PV}.tar.bz2;name=tar"
+SRC_URI[tar.md5sum] = "b536dea1b1f642bdc3607cb85ea0b89d"
+SRC_URI[tar.sha256sum] = "c5a1ea9a83c578672cd475ab4af5c2e40736669bae0eb70bb9bb6124074e5e5e"
+
+inherit autotools_stage
+
+S = "${WORKDIR}/Cluster-Resource-Agents-agents-${PV}"
+
+# ARM build fails on send_arp.linux.c with
+#
+# cc1: warnings being treated as errors
+# send_arp.linux.c: In function 'send_pack':
+# send_arp.linux.c:106: error: cast increases required alignment of target type
+# send_arp.linux.c: In function 'recv_pack':
+# send_arp.linux.c:207: error: cast increases required alignment of target type
+#
+# The code itself doesn't look that bad, so just disable -Werror
+EXTRA_OECONF_arm += "--disable-fatal-warnings"
+
+PACKAGES =+ "ldirectord ldirectord-doc"
+
+FILES_ldirectord = " \
+ ${sbindir}/ldirectord \
+ ${sysconfdir}/ha.d/resource.d/ldirectord \
+ ${sysconfdir}/init.d/ldirectord \
+ ${sysconfdir}/logrotate.d/ldirectord \
+ ${libdir}/ocf/resource.d/heartbeat/ldirectord \
+ "
+FILES_ldirectord-doc = "${mandir}/man8/ldirectord.8*"
+
+# Missing:
+# Authen::Radius
+# Net::LDAP
+# Net::IMAP::Simple::SSL
+# Net::IMAP::Simple
+RDEPENDS_ldirectord += " \
+ libdbi-perl \
+ libmailtools-perl \
+ libnet-dns-perl \
+ libsocket6-perl \
+ libwww-perl \
+ perl \
+ perl-module-getopt-long \
+ perl-module-net-ftp \
+ perl-module-net-smtp \
+ perl-module-pod-usage \
+ perl-module-posix \
+ perl-module-socket \
+ perl-module-strict \
+ perl-module-sys-hostname \
+ perl-module-sys-syslog \
+ perl-module-vars \
+ "
+
+FILES_${PN} += " \
+ /usr/lib/heartbeat/findif \
+ /usr/lib/heartbeat/ocf-returncodes \
+ /usr/lib/heartbeat/ocf-shellfuncs \
+ /usr/lib/heartbeat/send_arp \
+ /usr/lib/heartbeat/sfex_daemon \
+ /usr/lib/heartbeat/tickle_tcp \
+ /usr/lib/ocf/resource.d/heartbeat/ \
+ /usr/share/resource-agents/ra-api-1.dtd \
+ "
+
+FILES_${PN}-dbg += "/usr/lib/heartbeat/.debug/"
diff --git a/recipes/openais/files/fix-lcrso-linkage.patch b/recipes/openais/files/fix-lcrso-linkage.patch
new file mode 100644
index 0000000000..9acfc20266
--- /dev/null
+++ b/recipes/openais/files/fix-lcrso-linkage.patch
@@ -0,0 +1,21 @@
+Index: openais-1.1.2/services/Makefile.am
+===================================================================
+--- openais-1.1.2.orig/services/Makefile.am 2010-03-22 23:00:09.000000000 +0300
++++ openais-1.1.2/services/Makefile.am 2010-03-22 22:59:51.000000000 +0300
+@@ -78,13 +78,13 @@
+
+ else
+ service_amf.lcrso: $(AMF_OBJECTS)
+- $(CC) $(CFLAGS) -shared -Wl,-soname=$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ $^ -o $@
+
+ service_%.lcrso: %.o
+- $(CC) $(CFLAGS) -shared -Wl,-soname=$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ $^ -o $@
+
+ %.lcrso: %.o
+- $(CC) $(CFLAGS) -shared -Wl,-soname=$@ $^ -o $@
++ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ $^ -o $@
+ endif
+
+ %.o: %.c
diff --git a/recipes/openais/openais_1.1.2.bb b/recipes/openais/openais_1.1.2.bb
new file mode 100644
index 0000000000..c4c602d9c1
--- /dev/null
+++ b/recipes/openais/openais_1.1.2.bb
@@ -0,0 +1,14 @@
+DESCRIPTION = "Implementation of the Service Availability Forum Application Interface Specification (AIS)"
+LICENSE = "BSD"
+DEPENDS = "cluster-glue corosync"
+
+SRC_URI = " \
+ ftp://ftp@openais.org/downloads/openais-${PV}/openais-${PV}.tar.gz;name=tar \
+ file://fix-lcrso-linkage.patch;patch=1 \
+ "
+SRC_URI[tar.md5sum] = "f94ccb867358ac54ab24bc54def27335"
+SRC_URI[tar.sha256sum] = "7ba87dc480a9dd224fe3a3732c966d6fdf6ec5f192bb184d586afa3703f808f2"
+
+inherit autotools_stage
+
+FILES_${PN}-dbg += "${libexecdir}/lcrso/.debug" \ No newline at end of file
diff --git a/recipes/pacemaker/files/volatiles b/recipes/pacemaker/files/volatiles
new file mode 100644
index 0000000000..50a55be8f4
--- /dev/null
+++ b/recipes/pacemaker/files/volatiles
@@ -0,0 +1,7 @@
+d hacluster haclient 0750 /var/lib/heartbeat/crm none
+d hacluster haclient 0755 /var/lib/pengine none
+d hacluster haclient 0755 /var/run/heartbeat none
+d hacluster haclient 0755 /var/run/heartbeat/rsctmp none
+d hacluster haclient 0755 /var/run/crm none
+
+
diff --git a/recipes/pacemaker/pacemaker-1.0.8/pacemaker-dont-use-help2man.patch b/recipes/pacemaker/pacemaker-1.0.8/pacemaker-dont-use-help2man.patch
new file mode 100644
index 0000000000..da970d5079
--- /dev/null
+++ b/recipes/pacemaker/pacemaker-1.0.8/pacemaker-dont-use-help2man.patch
@@ -0,0 +1,16 @@
+Index: Pacemaker-1-0-Pacemaker-1.0.8/configure.ac
+===================================================================
+--- Pacemaker-1-0-Pacemaker-1.0.8.orig/configure.ac 2010-03-23 12:03:29.000000000 +0300
++++ Pacemaker-1-0-Pacemaker-1.0.8/configure.ac 2010-03-23 12:06:43.000000000 +0300
+@@ -504,10 +504,7 @@
+ AC_MSG_ERROR(You need (g)make installed in order to build ${PACKAGE})
+ fi
+
+-AM_CONDITIONAL(BUILD_HELP, test x"${HELP2MAN}" != x"")
+-if test x"${HELP2MAN}" != x""; then
+- PKG_FEATURES="$PKG_FEATURES manpages"
+-fi
++AM_CONDITIONAL(BUILD_HELP, test x"" != x"")
+
+ AM_CONDITIONAL(BUILD_ASCIIDOC, test x"${ASCIIDOC}" != x"")
+ if test x"${ASCIIDOC}" != x""; then
diff --git a/recipes/pacemaker/pacemaker-1.0.8/pacemaker-remove-native-includes.patch b/recipes/pacemaker/pacemaker-1.0.8/pacemaker-remove-native-includes.patch
new file mode 100644
index 0000000000..a16854024c
--- /dev/null
+++ b/recipes/pacemaker/pacemaker-1.0.8/pacemaker-remove-native-includes.patch
@@ -0,0 +1,22 @@
+Index: Pacemaker-1-0-Pacemaker-1.0.8/configure.ac
+===================================================================
+--- Pacemaker-1-0-Pacemaker-1.0.8.orig/configure.ac 2010-03-16 22:46:38.000000000 +0300
++++ Pacemaker-1-0-Pacemaker-1.0.8/configure.ac 2010-03-23 00:06:28.000000000 +0300
+@@ -325,7 +325,6 @@
+ ;;
+ *linux*)
+ AC_DEFINE_UNQUOTED(ON_LINUX, 1, Compiling for Linux platform)
+- CFLAGS="$CFLAGS -I${prefix}/include"
+ ;;
+ darwin*)
+ AC_DEFINE_UNQUOTED(ON_DARWIN, 1, Compiling for Darwin platform)
+@@ -334,9 +333,6 @@
+ ;;
+ esac
+
+-dnl Eventually remove this
+-CFLAGS="$CFLAGS -I${prefix}/include/heartbeat"
+-
+ AC_SUBST(INIT_EXT)
+ AC_DEFINE_UNQUOTED(HA_LOG_FACILITY, LOG_DAEMON, Default logging facility)
+
diff --git a/recipes/pacemaker/pacemaker_1.0.8.bb b/recipes/pacemaker/pacemaker_1.0.8.bb
new file mode 100644
index 0000000000..265ea30a60
--- /dev/null
+++ b/recipes/pacemaker/pacemaker_1.0.8.bb
@@ -0,0 +1,73 @@
+DESCRIPTION = "Scalable High-Availability cluster resource manager"
+LICENSE = "GPL"
+DEPENDS = " \
+ bzip2 \
+ cluster-glue \
+ cluster-resource-agents \
+ glib-2.0 \
+ gnutls \
+ libxml2 \
+ libxslt \
+ ncurses \
+ openais \
+ python-native \
+ util-linux-ng \
+ zlib \
+ "
+RDEPENDS_${PN} += "openais"
+
+SRC_URI = " \
+ http://hg.clusterlabs.org/pacemaker/stable-1.0/archive/Pacemaker-${PV}.tar.bz2;name=tar \
+ file://pacemaker-remove-native-includes.patch;patch=1 \
+ file://pacemaker-dont-use-help2man.patch;patch=1 \
+ file://volatiles \
+ "
+SRC_URI[tar.md5sum] = "088569ca893fe9f2239b68abe2856132"
+SRC_URI[tar.sha256sum] = "07e2e5559720890603baac96aa7635ff02f0b33ead592977554e661c6afe7b55"
+inherit autotools_stage python-dir
+
+S = "${WORKDIR}/Pacemaker-1-0-Pacemaker-${PV}"
+
+EXTRA_OECONF = "--with-ais --without-heartbeat --disable-fatal-warnings --disable-pretty"
+
+CFLAGS += "-I${STAGING_INCDIR}/heartbeat"
+
+do_install_append() {
+ install -d ${D}${sysconfdir}/default/volatiles
+ install -m 0644 ${WORKDIR}/volatiles ${D}${sysconfdir}/default/volatiles/06_pacemaker
+ find ${D} -name "*.pyo" -exec rm {} \;
+ find ${D} -name "*.pyc" -exec rm {} \;
+ find ${D} -name "*.py" | xargs sed -i -e "s:${STAGING_BINDIR_NATIVE}:${bindir}:g"
+}
+
+pkg_postinst_${PN} () {
+ set -e
+ grep haclient /etc/group || addgroup haclient
+ grep hacluster /etc/passwd || adduser --disabled-password --home=${localstatedir}/lib/heartbeat --ingroup haclient -g "HA cluster" hacluster
+ /etc/init.d/populate-volatile.sh update
+}
+
+FILES_${PN} += " \
+ ${libdir}/service_crm.so \
+ ${libdir}/ocf/resource.d/pacemaker \
+ ${libdir}/heartbeat/a* \
+ ${libdir}/heartbeat/c* \
+ ${libdir}/heartbeat/pengine \
+ ${libdir}/heartbeat/pingd \
+ ${libdir}/heartbeat/plugins/RAExec/stonith.so \
+ ${libdir}/heartbeat/s* \
+ "
+FILES_${PN}-dbg += "${libdir}/heartbeat/.debug ${libdir}/heartbeat/plugins/RAExec/.debug/ ${libdir}/heartbeat/stonithdtest/.debug/ ${libexecdir}/lcrso/.debug"
+FILES_${PN}-dev += "${libdir}/heartbeat/plugins/RAExec/*.la"
+FILES_${PN}-static += "${libdir}/heartbeat/plugins/RAExec/*.a"
+
+PACKAGES =+ "${PN}-crm ${PN}-hb2openais ${PN}-haresources2cib ${PN}-tests ${PN}-snmp"
+FILES_${PN}-crm = "${sbindir}/crm ${PYTHON_SITEPACKAGES_DIR} ${libdir}/heartbeat/crm_primitive.py "
+RDEPENDS_${PN}-crm += "python-core"
+FILES_${PN}-hb2openais = "${libdir}/heartbeat/hb2openais.sh ${libdir}/heartbeat/hb2openais-helper.py"
+RDEPENDS_${PN}-hb2openais += "python-core"
+FILES_${PN}-haresources2cib = "${libdir}/heartbeat/haresources2cib.py"
+RDEPENDS_${PN}-haresources2cib += "python-core"
+FILES_${PN}-tests = "${datadir}/pacemaker/tests"
+RDEPENDS_${PN}-test += "python-core"
+FILES_${PN}-snmp = "${datadir}/snmp/mibs/PCMK-MIB.txt"