[arch-commits] Commit in kdebase-workspace/trunk (PKGBUILD kdm)

Pierre Schmitz pierre at archlinux.org
Tue Jul 29 09:46:41 EDT 2008


    Date: Tuesday, July 29, 2008 @ 09:46:41
  Author: pierre
Revision: 7294

moving kdm rc.d script from kde-common to kdebase-workspace (FS#11029)

Added:
  kdebase-workspace/trunk/kdm
Modified:
  kdebase-workspace/trunk/PKGBUILD

----------+
 PKGBUILD |   10 +++++++---
 kdm      |   37 +++++++++++++++++++++++++++++++++++++
 2 files changed, 44 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2008-07-29 03:32:18 UTC (rev 7293)
+++ PKGBUILD	2008-07-29 13:46:41 UTC (rev 7294)
@@ -13,12 +13,15 @@
 	 'libusb' 'libxss' 'lm_sensors' 'libxinerama' 'libxklavier' 'qimageblitz')
 makedepends=('pkgconfig' 'cmake' 'automoc4' 'networkmanager' 'kdemultimedia')
 optdepends=('kdemultimedia')
-replaces=('kdmtheme')
+replaces=('kdmtheme' 'kde-common')
+conflicts=('kde-common')
 options=('docs')
 backup=('usr/share/config/kdm/kdmrc')
 source=("ftp://ftp.archlinux.org/other/kde/${pkgname}-${pkgver}.tar.bz2"
-        'kdm-zsh-profile.patch')
-md5sums=('d8dbe16f5807536a429bbf9fd33e82a5' '40f5556820d52a14e9d9722a5a8a491e')
+        'kdm-zsh-profile.patch' 'kdm')
+md5sums=('d8dbe16f5807536a429bbf9fd33e82a5'
+         '40f5556820d52a14e9d9722a5a8a491e'
+         '5d80164932e0d44d8b802d3929a004ab')
 
 build() {
 	cd $srcdir/${pkgname}-${pkgver}
@@ -32,4 +35,5 @@
 		-DWITH_Xmms=OFF
 	make
 	make DESTDIR=$pkgdir install
+	install -D -m755 ${srcdir}/kdm ${pkgdir}/etc/rc.d/kdm
 }

Added: kdm
===================================================================
--- kdm	                        (rev 0)
+++ kdm	2008-07-29 13:46:41 UTC (rev 7294)
@@ -0,0 +1,37 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+PID=`pidof -o %PPID /usr/bin/kdm`
+case "$1" in
+  start)
+    stat_busy "Starting KDE Desktop Manager"
+    [ -z "$PID" ] && /usr/bin/kdm &>/dev/null
+    if [ $? -gt 0 ]; then
+      stat_fail
+    else
+      echo $PID > /var/run/kdm.pid
+      add_daemon kdm
+      stat_done
+    fi
+    ;;
+  stop)
+    stat_busy "Stopping KDE Desktop Manager"
+    [ ! -z "$PID" ]  && kill $PID &> /dev/null
+    if [ $? -gt 0 ]; then
+      stat_fail
+    else
+      rm_daemon kdm
+      stat_done
+    fi
+    ;;
+  restart)
+    $0 stop
+    sleep 3
+    $0 start
+    ;;
+  *)
+    echo "usage: $0 {start|stop|restart}"  
+esac
+exit 0





More information about the arch-commits mailing list