[arch-commits] CVS update of extra/games/gweled (PKGBUILD gweled.install)

Jan de Groot jgc at archlinux.org
Sun Apr 22 16:28:23 EDT 2007


    Date: Sunday, April 22, 2007 @ 16:28:23
  Author: jgc
    Path: /home/cvs-extra/extra/games/gweled

Modified: PKGBUILD (1.11 -> 1.12) gweled.install (1.2 -> 1.3)

upgpkg: gweled 0.7-4
Move to /usr, use new games group


----------------+
 PKGBUILD       |   16 +++++++++-------
 gweled.install |   29 +++++++++++------------------
 2 files changed, 20 insertions(+), 25 deletions(-)


Index: extra/games/gweled/PKGBUILD
diff -u extra/games/gweled/PKGBUILD:1.11 extra/games/gweled/PKGBUILD:1.12
--- extra/games/gweled/PKGBUILD:1.11	Wed Jul 19 16:45:13 2006
+++ extra/games/gweled/PKGBUILD	Sun Apr 22 16:28:23 2007
@@ -1,14 +1,15 @@
-# $Id: PKGBUILD,v 1.11 2006/07/19 20:45:13 andyrtr Exp $
+# $Id: PKGBUILD,v 1.12 2007/04/22 20:28:23 jgc Exp $
 # Contributor: Ben <contrasutra at myrealbox.com>
-# Maintainer: Arjan Timmerman <arjan at archlinux.org>
+# Maintainer: Jan de Groot <jgc at archlinux.org>
 
 pkgname=gweled
 pkgver=0.7
-pkgrel=3
+pkgrel=4
 pkgdesc="Bejewled Game (aka Diamond Mine)"
 arch=(i686 x86_64)
+license=('GPL')
 url="http://sebdelestaing.free.fr/gweled/"
-depends=('libgnomeui' 'librsvg' 'libmikmod')
+depends=('libgnomeui>=2.18.1-2' 'librsvg>=2.16' 'libmikmod' 'filesystem>=0.8-3')
 install=gweled.install
 source=(http://sebdelestaing.free.fr/gweled/Release/${pkgname}-${pkgver}.tar.gz
         invalid_free.patch)
@@ -17,11 +18,12 @@
 build() {
   cd ${startdir}/src/${pkgname}-${pkgver}
   patch -Np0 -i ${startdir}/src/invalid_free.patch || return 1
-  ./configure --prefix=/opt/gnome
-  make LDFLAGS+=-Wl,--export-dynamic scoredir=/opt/gnome/var/games || return 1
+  ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
+              --with-scores-user=root --with-scores-group=games
+  make LDFLAGS+=-Wl,--export-dynamic || return 1
   make DESTDIR=${startdir}/pkg install
 
   #We generate these files on postinstall to prevent score resets on upgrade
-  rm -r ${startdir}/pkg/opt/gnome/var
+#  rm -rf ${startdir}/pkg/var
 }
 
Index: extra/games/gweled/gweled.install
diff -u extra/games/gweled/gweled.install:1.2 extra/games/gweled/gweled.install:1.3
--- extra/games/gweled/gweled.install:1.2	Sat Nov 19 13:27:02 2005
+++ extra/games/gweled/gweled.install	Sun Apr 22 16:28:23 2007
@@ -1,22 +1,20 @@
 scores=(
-  'opt/gnome/var/games/gweled.easy.scores'
-  'opt/gnome/var/games/gweled.timed.scores'
+  'gweled.easy.scores'
+  'gweled.timed.scores'
 )
 
 post_install() {
-  update-desktop-database -q
-  if [ ! -d opt/gnome/var/games ]; then
-    mkdir -p opt/gnome/var/games
-  fi
-
   for score in "${scores[@]}" ; do
-    if [ -e "$score" ]; then
-      chmod 664 "$score"
+    if [ -e "var/games/${score}" ]; then
       continue
     fi
-    touch "$score"
-    chown root:users "$score"
-    chmod 664 "$score"
+    if [ -e "opt/gnome/var/games/${score}" ]; then
+      mv "opt/gnome/var/games/${score}" var/games/
+    else
+      touch "var/games/${score}"
+    fi
+    chown root:games "var/games/${score}"
+    chmod 664 "var/games/${score}"
   done
 }
 
@@ -25,14 +23,9 @@
 }
 
 post_remove() {
-  update-desktop-database -q
-
   for score in "${scores[@]}" ; do
-    rm -f "$score"
+    rm -f "var/games/$score"
   done
-  if [ -d opt/gnome/var/games ]; then
-    rmdir --ignore-fail-on-non-empty opt/gnome/var/games
-  fi
 }
 
 op=$1




More information about the arch-commits mailing list