updated on Thu Jan 12 08:01:00 UTC 2012
[aur-mirror.git] / librxtx-arduino / PKGBUILD
blob2b50cd93101292d14e81c9832956b90743954c27
1 # Maintainer: PyroPeter <com . googlemail @ abi1789>
2 # Contributor: Vitaliy Berdinskikh ur6lad[at]i.ua
4 pkgname=librxtx-arduino
5 pkgver=2.2pre2
6 pkgrel=2
7 pkgdesc="Java Library for Serial IO"
8 arch=('i686' 'x86_64')
9 url="http://rxtx.qbang.org"
10 depends=('glibc' 'java-runtime')
11 makedepends=('kernel26-headers' 'gcc' 'java-environment' 'unzip' 'patch')
12 license=('LGPL')
13 provides=(rxtx 'librxtx=2.2pre2')
14 source=(http://rxtx.qbang.org/pub/rxtx/rxtx-${pkgver}.zip utsrelease.patch ttyACM_port.patch)
15 md5sums=('7eedb18e3f33a427e2b0e9be8ce3f94c' '60e427aaecd29839a5a817f13172be5d' '903a3fe0067d0682dd5f64483c741df6')
17 build() {
18         _kernel=`uname -r`
19         CFLAGS=-I/usr/src/linux-${_kernel}/include
20         _jhome=$pkgdir/usr/share/java/rxtx
21         _rxtx_path=$pkgdir/usr/lib
22         mkdir -p ${_jhome} ${_rxtx_path}
24         cd $srcdir
25         patch -p1 < utsrelease.patch
26         cd rxtx-${pkgver}
27         
28         patch -p1 < ${srcdir}/ttyACM_port.patch
29         
30         ./configure --prefix=/usr || return 1
31         make || return 1
32         make JHOME=${_jhome} RXTX_PATH=${_rxtx_path} install || return 1
34         chmod -x ${_jhome}/RXTXcomm.jar
35         # slay libtool
36         find $pkgdir -name '*.la' -exec rm {} \;