# $Id: PKGBUILD 266875 2017-11-15 14:29:11Z foutrelis $
# Maintainer (AUR): Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer (AUR): Vesa Kaihlavirta <vegai@iki.fi>
# Contributor (AUR): Sebastian Sareyko <public@nooms.de>

# parabola changes and rationale:
#  no changes.

pkgname=gnustep-back
pkgver=0.26.2
pkgrel=1
pkgdesc="The GNUstep GUI Backend"
arch=('x86_64' 'i686' 'armv7h')
url="http://www.gnustep.org/"
license=('LGPL')
depends=(libgl libxmu gcc-libs freetype2 cairo)
makedepends=('gnustep-make' 'gnustep-base' 'gnustep-gui' 'libffi' 'gcc-objc')
conflicts=('gnustep-back-svn')
groups=('gnustep-core')
source=(https://github.com/gnustep/libs-back/releases/download/back-${pkgver//./_}/gnustep-back-$pkgver.tar.gz)
#{,.sig}) # Upstream Signature wasn't correctly created
sha256sums=('1807306b47f3cdb9f30743b5706d0e618621459ddf6347fad8c838867ed23322')
#            'SKIP')
#validpgpkeys=('83AAE47CE829A4146EF83420CA868D4C99149679')

build() {
  cd "$srcdir"/$pkgname-$pkgver
  . /usr/share/GNUstep/Makefiles/GNUstep.sh
  ./configure --prefix=/usr --sysconfdir=/etc/GNUstep
  make
}

package() {
  cd "$srcdir"/$pkgname-$pkgver
  . /usr/share/GNUstep/Makefiles/GNUstep.sh
  make DESTDIR="$pkgdir" install
  mkdir -p "$pkgdir"/etc/ld.so.conf.d
  cat >"$pkgdir"/etc/ld.so.conf.d/gnustep.conf <<EOF
/opt/GNUstep/System/Library/Libraries
/usr/lib/GNUstep/Libraries
EOF
}
