summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-fs/cvmfs/files/cvmfs-2.1.10-openrc.patch')
-rw-r--r--net-fs/cvmfs/files/cvmfs-2.1.10-openrc.patch55
1 files changed, 55 insertions, 0 deletions
diff --git a/net-fs/cvmfs/files/cvmfs-2.1.10-openrc.patch b/net-fs/cvmfs/files/cvmfs-2.1.10-openrc.patch
new file mode 100644
index 000000000000..eb5a3f4b08a4
--- /dev/null
+++ b/net-fs/cvmfs/files/cvmfs-2.1.10-openrc.patch
@@ -0,0 +1,55 @@
+simple patch to adapt cvmfs scripts for openrc
+bicatali@gentoo.org 06/2013
+
+--- cvmfs/cvmfs_config.orig 2013-06-17 15:42:57.011022876 -0700
++++ cvmfs/cvmfs_config 2013-06-17 15:46:22.395157110 -0700
+@@ -14,20 +14,23 @@
+ Linux )
+ if [ -x /sbin/service ]; then
+ service="/sbin/service"
+- else
++ elif [ -x /usr/sbin/service ]; then
+ # Ubuntu
+ service="/usr/sbin/service"
++ elif [ -x /sbin/rc-service ]; then
++ # OpenRC
++ service="/sbin/rc-service"
+ fi
+ if [ -x /sbin/pidof ]; then
+ pidof="/sbin/pidof"
+ else
+- # Ubuntu
++ # Ubuntu, Gentoo
+ pidof="/bin/pidof"
+ fi
+ if [ -x /sbin/fuser ]; then
+ fuser="/sbin/fuser" # RHEL
+ else
+- fuser="/bin/fuser" # Ubuntu, SuSE
++ fuser="/bin/fuser" # Ubuntu, SuSE, Gentoo
+ fi
+ if [ ! -x /usr/bin/attr ]; then
+ # Fedora
+--- cvmfs/cvmfs_server.orig 2013-06-17 15:42:51.426992247 -0700
++++ cvmfs/cvmfs_server 2013-06-17 15:44:02.092381590 -0700
+@@ -38,7 +38,7 @@
+ if which httpd2 >/dev/null 2>&1; then #SLES/OpenSuSE
+ APACHE_SERVICE="apache2"
+ APACHE_CONF=${APACHE_SERVICE}
+-elif which apache2 >/dev/null 2>&1; then # Debian based
++elif which apache2 >/dev/null 2>&1; then # Debian, Gentoo based
+ APACHE_SERVICE="apache2"
+ APACHE_CONF=${APACHE_SERVICE}
+ else
+@@ -49,8 +49,10 @@
+ # Find the service binary
+ if [ -x /sbin/service ]; then
+ SERVICE_BIN="/sbin/service"
+-else
++elif [ -x /usr/sbin/service ]; then
+ SERVICE_BIN="/usr/sbin/service" # Ubuntu
++elif [ -x /sbin/rc-service ]; then
++ SERVICE_BIN="/sbin/rc-service" # OpenRC
+ fi
+ [ -z "$SERVICE_BIN" ] && die "Could not locate 'service' utility"
+