summaryrefslogtreecommitdiff
path: root/pcr/luadbi/PKGBUILD
blob: f82bbe0a8a148048e28a417244a1df543dd6aa67 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# Maintainer: Lee T. Starnes <lstarnes1024@gmail.com>
# Maintainer (Parabola): fauno <fauno@parabola.nu>
pkgname=luadbi
pkgver=0.5
pkgrel=3
pkgdesc="Database interface library for Lua"
arch=('i686' 'x86_64' 'armv6h')
url="http://code.google.com/p/luadbi/"
license=('custom:MIT')
depends=('lua51')
makedepends=('lua51' 'sqlite3' 'libmariadbclient' 'postgresql' 'postgresql-libs')
optdepends=(
  'sqlite3: sqlite backend support'
  'libmariadbclient: MariaDB (or MySQL) backend support'
  'postgresql-libs: PostgreSQL backend support'
)
source=("http://luadbi.googlecode.com/files/$pkgname.$pkgver.tar.gz" "Makefile.diff")

prepare() {
  cd "$srcdir"
  patch -p1 < Makefile.diff
}

build() {
  cd "$srcdir"
  make free
}

package() {
  cd "$srcdir"

  install -Dm644 DBI.lua $pkgdir/usr/share/lua/5.1/DBI.lua
  install -Dm644 COPYING $pkgdir/usr/share/licenses/luadbi/LICENSE

  for i in *.so ; do
    install -Dm755 "$i" $pkgdir/usr/lib/lua/5.1/"${i##*/}"
  done
}

sha512sums=('4ed641e113e90acc8a4f6b3b2d0f5d5044c0fbbef3b2fdfb84d15e17115e45c553a33b19bfb165e5af11a2adce501d66859963e3363d3ab1c6a39b0b2ae92e62'
            '2ff656844f6714bfcbe66fc0b2ada232b5ffe2281ba530648d0faa0c051d6b10100487d6915b9664116e1cce07cb931feb1a19883a30f4ce26e5d08e3a067574')