# Contributor: Robert Boisvert <rdboisvert@gmail.com>
# Maintainer: Robert Boisvert <rdboisvert@gmail.com>
pkgname=sqliteodbc
pkgver=0.9995
pkgrel=0
pkgdesc="SQLite ODBC driver"
url="http://www.ch-werner.de/sqliteodbc"
arch="all"
license="BSD"
makedepends="libtool sqlite-dev unixodbc-dev"
source="http://www.ch-werner.de/sqliteodbc/$pkgname-$pkgver.tar.gz"

builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	cd "$builddir"
	update_config_sub
}

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr
	make
}

package() {
	cd "$builddir"
	mkdir -p "$pkgdir/usr/lib"
	make DESTDIR="$pkgdir" install
	rm $pkgdir/usr/lib/*.la $pkgdir/usr/lib/*.a
}

sha512sums="21a9b1ae7f5b607de6d22478befdfaf55e1248f7e1e9984c9dea039bcdec2b69ade9ec92e31fcae2007652d6764b74a9a1cebae199fdc52afeca06a226de85d9  sqliteodbc-0.9995.tar.gz"
