diff options
author | Fernando Ortiz | 2015-09-07 00:20:27 -0500 |
---|---|---|
committer | Fernando Ortiz | 2015-09-07 00:20:50 -0500 |
commit | 1691a4239ee688a81d0a7760d794bd5619f83b64 (patch) | |
tree | f0266ef07bd43710d21f098bb569549ded821258 | |
parent | 7db3ab90bc353b3f01bcd46866d0e74316068970 (diff) | |
download | aur-1691a4239ee688a81d0a7760d794bd5619f83b64.tar.gz |
mdl improvements
Hi,
I've attached a patch for the gale-git package which changes it to use
the normal Arch git fetching procedures, and also fixes an issue where
the package wouldn't install (it would error out because the package
would contain usr/sbin, and usr/sbin is just a link to usr/bin these
days).
Other changes I made; you can remove them if you want:
* added an install file to automatically create a user for gale
* changed the config directory to /etc instead of the default of
/usr/etc (this will break existing users' setups if they don't make
the proper adjustments afterwards, obviously)
Cheers,
Mark Laws
-rw-r--r-- | .SRCINFO | 10 | ||||
-rw-r--r-- | PKGBUILD | 54 | ||||
-rw-r--r-- | gale.install | 19 |
3 files changed, 57 insertions, 26 deletions
@@ -1,8 +1,10 @@ pkgbase = gale-git - pkgdesc = Gale is instant messaging software - pkgver = 20130622 + pkgdesc = A distributed, real-time instant messaging system + pkgver = 1.1.r17.ge012127 pkgrel = 1 - url = http://www.gale.org + epoch = 1 + url = http://gale.org + install = gale.install arch = i686 arch = x86_64 license = GPL2 @@ -11,6 +13,8 @@ pkgbase = gale-git depends = gc depends = openssl depends = adns + source = gale::git+https://github.com/grawity/gale.git + sha1sums = SKIP pkgname = gale-git @@ -1,40 +1,48 @@ -# Maintainer: nandub <dev@nandub.info> +# Maintainer: Fernando Ortiz <nandub+arch [at] nandub.info> +# Contributor: Mark Laws <mdl [at] 60hz.org> + +_pkgname=gale pkgname=gale-git -pkgver=20130622 +epoch=1 +pkgver=1.1.r17.ge012127 pkgrel=1 -pkgdesc="Gale is instant messaging software" +pkgdesc="A distributed, real-time instant messaging system" arch=('i686' 'x86_64') -url="http://www.gale.org" +url="http://gale.org" license=('GPL2') depends=('bash' 'gc' 'openssl' 'adns') makedepends=('git') +install="${_pkgname}.install" +source=("${_pkgname}::git+https://github.com/grawity/${_pkgname}.git") +sha1sums=('SKIP') -_gitroot=https://github.com/grawity/gale.git -_gitname=gale +pkgver() { + cd "$srcdir/$_pkgname" + git describe --tags | sed 's/^v//; s/-/.r/; s/-/./g' +} -build() { - cd "$srcdir" - msg "Connecting to GIT server...." - - if [[ -d "$_gitname" ]]; then - cd "$_gitname" && git pull origin - msg "The local files are updated." - else - git clone --depth=1 "$_gitroot" "$_gitname" - fi +prepare() { + cd "$srcdir/$_pkgname" - msg "GIT checkout done or server timeout" - msg "Starting build..." + if [[ ! -f configure ]]; then + ./bootstrap + fi +} - cd "$srcdir/$_gitname" +build() { + cd "$srcdir/$_pkgname" - ./bootstrap && ./configure --prefix=/usr || exit 1 - make + ./configure --prefix=/usr --sysconfdir=/etc + make -j1 # parallel builds seem to be broken } package() { - cd "$srcdir/$_gitname" + cd "$srcdir/$_pkgname" + make DESTDIR="$pkgdir" install + # install fails if sbindir = bindir + mv -f "$pkgdir/usr/sbin/gksign" "$pkgdir/usr/bin/" + rmdir "$pkgdir/usr/sbin" } -# vim:set ts=2 sw=2 et: +# vim: set ts=2 sw=2 et: diff --git a/gale.install b/gale.install new file mode 100644 index 000000000000..7a778407b383 --- /dev/null +++ b/gale.install @@ -0,0 +1,19 @@ +# -*- shell-script -*- +post_install() { + if ! getent passwd gale &> /dev/null; then + useradd -r -g daemon -d /var/lib/gale -m -s /sbin/nologin gale + fi + chown -R gale:daemon /etc/gale +} + +post_remove() { + # don't try to remove a non-local account + if getent -s files passwd gale 2> /dev/null; then + userdel gale + fi +} + +# Local Variables: +# sh-basic-offset: 2 +# sh-indentation: 2 +# End: |