forked from pool/ocfs2-tools
26c5ae23aa
OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/ocfs2-tools?expand=0&rev=143
166 lines
3.8 KiB
Diff
166 lines
3.8 KiB
Diff
From c89760fc41f466a7a2be99ed2f648875c2d64e7a Mon Sep 17 00:00:00 2001
|
|
From: Eric Ren <zren@suse.com>
|
|
Date: Thu, 23 Jul 2015 17:13:39 +0800
|
|
Subject: [PATCH 2/3] vendor: Add vendor files for sles12
|
|
|
|
Add vendor files for sles12, and enable systemd support for o2cb
|
|
based on the patch named "add systemd support" from "Junxiao Bi"
|
|
<junxiao.bi@oracle.com>.
|
|
|
|
Signed-off-by: Eric Ren <zren@suse.com>
|
|
---
|
|
vendor/Makefile | 2 +-
|
|
vendor/sles12/Makefile | 10 +++++++
|
|
vendor/sles12/Vendor.make | 11 +++++++
|
|
vendor/sles12/rpmarch.guess | 70 +++++++++++++++++++++++++++++++++++++++++++++
|
|
vendor/sles12/vendor.guess | 13 +++++++++
|
|
5 files changed, 105 insertions(+), 1 deletion(-)
|
|
create mode 100644 vendor/sles12/Makefile
|
|
create mode 100644 vendor/sles12/Vendor.make
|
|
create mode 100755 vendor/sles12/rpmarch.guess
|
|
create mode 100755 vendor/sles12/vendor.guess
|
|
|
|
diff --git a/vendor/Makefile b/vendor/Makefile
|
|
index 58ac84d..022d030 100644
|
|
--- a/vendor/Makefile
|
|
+++ b/vendor/Makefile
|
|
@@ -2,6 +2,6 @@ TOPDIR = ..
|
|
|
|
include $(TOPDIR)/Preamble.make
|
|
|
|
-SUBDIRS = common rhel7 rhel6 rhel5 sles10 rhel4 sles9 fc7 fc8 fc9
|
|
+SUBDIRS = common sles12 rhel7 rhel6 rhel5 sles10 rhel4 sles9 fc7 fc8 fc9
|
|
|
|
include $(TOPDIR)/Postamble.make
|
|
diff --git a/vendor/sles12/Makefile b/vendor/sles12/Makefile
|
|
new file mode 100644
|
|
index 0000000..89c16a7
|
|
--- /dev/null
|
|
+++ b/vendor/sles12/Makefile
|
|
@@ -0,0 +1,10 @@
|
|
+TOPDIR = ../..
|
|
+
|
|
+include $(TOPDIR)/Preamble.make
|
|
+
|
|
+DIST_FILES = \
|
|
+ rpmarch.guess \
|
|
+ Vendor.make \
|
|
+ vendor.guess
|
|
+
|
|
+include $(TOPDIR)/Postamble.make
|
|
diff --git a/vendor/sles12/Vendor.make b/vendor/sles12/Vendor.make
|
|
new file mode 100644
|
|
index 0000000..b186054
|
|
--- /dev/null
|
|
+++ b/vendor/sles12/Vendor.make
|
|
@@ -0,0 +1,11 @@
|
|
+#
|
|
+# SLES 12
|
|
+#
|
|
+
|
|
+TOOLSARCH = $(shell $(TOPDIR)/vendor/sles12/rpmarch.guess tools $(TOPDIR))
|
|
+VENDOR_EXTENSION = SLE12
|
|
+SYSTEMD_ENABLED = 1
|
|
+
|
|
+include $(TOPDIR)/vendor/common/Vendor.make
|
|
+
|
|
+packages: rpm
|
|
diff --git a/vendor/sles12/rpmarch.guess b/vendor/sles12/rpmarch.guess
|
|
new file mode 100755
|
|
index 0000000..3514627
|
|
--- /dev/null
|
|
+++ b/vendor/sles12/rpmarch.guess
|
|
@@ -0,0 +1,70 @@
|
|
+#! /bin/sh
|
|
+
|
|
+mode="$1"
|
|
+srcdir="$2"
|
|
+
|
|
+host_cpu=
|
|
+
|
|
+QUERYFILE=/etc/SuSE-release
|
|
+
|
|
+if test -n "$QUERYFILE"; then
|
|
+ host_cpu="`rpm -qf $QUERYFILE --queryformat \"%{ARCH}\"`"
|
|
+fi
|
|
+
|
|
+if test -z "$host_cpu" -o "$host_cpu" = "noarch" ; then
|
|
+ host_alias=`$srcdir/config.guess`
|
|
+ host=`$srcdir/config.sub $host_alias`
|
|
+ host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
|
|
+fi
|
|
+
|
|
+case "$host_cpu" in
|
|
+ x86_64|ia64|s390x)
|
|
+ TOOLSARCH="$host_cpu"
|
|
+ ;;
|
|
+ i386|i486|i586|i686|i786|k6|k7)
|
|
+ TOOLSARCH="i386"
|
|
+ ;;
|
|
+ ppc|ppc64|ppciseries|ppcpseries|ppc64iseries|ppc64pseries|powerpc|powerpc64)
|
|
+ TOOLSARCH="ppc"
|
|
+ ;;
|
|
+ *)
|
|
+ echo "rpmarch.guess: Warning: unknown RPM CPU architecture: $host_cpu" >&2
|
|
+ TOOLSARCH=""
|
|
+ ;;
|
|
+esac
|
|
+
|
|
+# Only a few of these need to be overwritten from RPM's default
|
|
+case "$host_cpu" in
|
|
+ i586)
|
|
+ MODULEARCH="$host_cpu"
|
|
+ ;;
|
|
+ i386|i686)
|
|
+ MODULEARCH="i586"
|
|
+ ;;
|
|
+ ppc|ppc64|ppciseries|ppcpseries|ppc64iseries|ppc64pseries|powerpc|powerpc64)
|
|
+ MODULEARCH="ppc64"
|
|
+ ;;
|
|
+ *)
|
|
+ MODULEARCH=""
|
|
+ ;;
|
|
+esac
|
|
+
|
|
+case "$mode" in
|
|
+ module)
|
|
+ if [ -n "$MODULEARCH" ] ; then
|
|
+ echo "--target $MODULEARCH"
|
|
+ fi
|
|
+ ;;
|
|
+ tools)
|
|
+ if [ -n "$TOOLSARCH" ] ; then
|
|
+ echo "--target $TOOLSARCH"
|
|
+ fi
|
|
+ ;;
|
|
+ *)
|
|
+ echo "rpmarch.guess: Invalid mode: $mode" >&2
|
|
+ echo "error"
|
|
+ exit 1
|
|
+ ;;
|
|
+esac
|
|
+
|
|
+exit 0
|
|
diff --git a/vendor/sles12/vendor.guess b/vendor/sles12/vendor.guess
|
|
new file mode 100755
|
|
index 0000000..83ce085
|
|
--- /dev/null
|
|
+++ b/vendor/sles12/vendor.guess
|
|
@@ -0,0 +1,13 @@
|
|
+#!/bin/sh
|
|
+
|
|
+if [ ! -f /etc/SuSE-release ]
|
|
+then
|
|
+ exit 1
|
|
+fi
|
|
+
|
|
+if [ "`rpm -qf /etc/SuSE-release --qf '%{VERSION}' 2>/dev/null`" != "12" ]
|
|
+then
|
|
+ exit 1
|
|
+fi
|
|
+
|
|
+exit 0
|
|
--
|
|
2.1.4
|
|
|