/firebird-superserver/PKGBUILD

https://bitbucket.org/axil42/aur-mirror · #! · 70 lines · 56 code · 14 blank · 0 comment · 0 complexity · 55321501b46a793cf894719b4f30d4ae MD5 · raw file

  1. # Maintainer: Benjamin Bukowski <benjamin.bukowski@googlemail.com>
  2. pkgname=firebird-superserver
  3. _pkgver=2.5.1.26351
  4. _buildver=0
  5. pkgver=${_pkgver}_${_buildver}
  6. pkgrel=5
  7. pkgdesc="A open source SQL relational database management system (RDMS)"
  8. arch=(i686 x86_64)
  9. url="http://www.firebirdsql.org/"
  10. license=('IPL IDPL')
  11. provides=("libfbclient=${_pkgver}")
  12. depends=()
  13. conflicts=('firebird-classicserver' 'libfbclient')
  14. install=firebird-superserver.install
  15. _arch=i686
  16. [[ "$CARCH" == x86_64 ]] && _arch=amd64
  17. _filename="FirebirdSS-${_pkgver}-${_buildver}.${_arch}"
  18. source=("http://downloads.sourceforge.net/firebird/${_filename}.tar.gz"
  19. 'firebird-sysv.rc'
  20. 'firebird-tmpfiles.conf'
  21. 'firebird-systemd.service')
  22. md5sums=('84911d9e9a04f7edd26109abeb92038d'
  23. '19e24e34c773826860958d4938396b05'
  24. '98eff99fd8d195a45c251610d67bd473'
  25. 'ee9068e9bfdfa01e9dc79c72d1bfcdd8')
  26. [[ "$CARCH" == x86_64 ]] && md5sums[0]='337d00c6887941bcd1943dec94270fff'
  27. package() {
  28. cd "$srcdir/${_filename}"
  29. msg "Extracting firebird"
  30. tar -xzof buildroot.tar.gz -C $pkgdir
  31. [[ "$CARCH" == x86_64 ]] && mv $pkgdir/usr/lib64/ $pkgdir/usr/lib/
  32. install -Dm755 $srcdir/firebird-sysv.rc $pkgdir/etc/rc.d/firebird
  33. install -Dm644 $srcdir/firebird-systemd.service $pkgdir/usr/lib/systemd/system/firebird.service
  34. install -Dm644 $srcdir/firebird-tmpfiles.conf $pkgdir/usr/lib/tmpfiles.d/firebird.conf
  35. touch $pkgdir/opt/firebird/{fb_guard,firebird.log}
  36. chmod u=rw,go= $pkgdir/opt/firebird/{fb_guard,firebird.log,security2.fdb,examples/empbuild/*.fdb}
  37. cat << EOT > $pkgdir/opt/firebird/SYSDBA.password
  38. # This is the default password
  39. # You should change this password at the earliest oportunity
  40. # Your password can be changed to a more suitable one using the
  41. # /opt/firebird/bin/gsec utility
  42. ISC_USER=sysdba
  43. ISC_PASSWD=masterkey
  44. EOT
  45. chmod u=r,go= $pkgdir/opt/firebird/SYSDBA.password
  46. if [ -x $pkgdir/opt/firebird/bin/fbmgr.bin ]; then
  47. cat > $pkgdir/opt/firebird/bin/fbmgr << EOT
  48. #!/bin/sh
  49. FIREBIRD=/opt/firebird
  50. export FIREBIRD
  51. exec /opt/firebird/bin/fbmgr.bin \$@
  52. EOT
  53. fi
  54. chmod ugo+x $pkgdir/opt/firebird/bin/fbmgr
  55. }
  56. # vim:set ts=2 sw=2 et: