# Contributor: Jeff Bilyk <jbilyk at gmail>
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=perl-dbd-odbc
_realpkgname=DBD-ODBC
pkgver=1.56
pkgrel=1
pkgdesc="Perl CPAN DBD::ODBC module"
url="http://search.cpan.org/dist/DBD-ODBC/"
arch="all"
license="GPL PerlArtistic"
depends="perl perl-dbi"
makedepends="perl perl-dev unixodbc-dev"
subpackages="$pkgname-doc"
source="http://search.cpan.org/CPAN/authors/id/M/MJ/MJEVANS/DBD-ODBC-$pkgver.tar.gz"

_builddir="$srcdir"/${_realpkgname}-$pkgver

prepare() {
       return 0
}

build() {
       cd "$_builddir"
       PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor || return 1
       make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install
	find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete
}

md5sums="fdbe7a1fada61bc7c9a1ddaeff21b7ed  DBD-ODBC-1.56.tar.gz"
sha256sums="d20a899881b2cf033052af4055cda1f5e9ab2720999cf2832518509ac6869cdc  DBD-ODBC-1.56.tar.gz"
sha512sums="374bf0f87bbb84128f5999670aee228185d6741a2364745a6dd268068ea53b73f6c8756da60052ae86ec74a335b583d0ae93c449f620c467f1d1fba84fcfa805  DBD-ODBC-1.56.tar.gz"
