summaryrefslogtreecommitdiff
path: root/community/openocd/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/openocd/PKGBUILD')
-rw-r--r--community/openocd/PKGBUILD15
1 files changed, 12 insertions, 3 deletions
diff --git a/community/openocd/PKGBUILD b/community/openocd/PKGBUILD
index 210f2c82e..18803f55d 100644
--- a/community/openocd/PKGBUILD
+++ b/community/openocd/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 100265 2013-11-02 08:45:37Z spupykin $
+# $Id: PKGBUILD 102001 2013-12-03 16:51:56Z eric $
# Maintainer: Bartłomiej Piotrowski <barthalion@gmail.com>
# Contributor: Matthias Bauch <matthias.bauch@gmail.com>
# Contributor: Laszlo Papp <djszapi2 at gmail com>
@@ -6,12 +6,12 @@
pkgname=openocd
pkgver=0.7.0
-pkgrel=2
+pkgrel=3
pkgdesc='Debugging, in-system programming and boundary-scan testing for embedded target devices'
arch=('i686' 'x86_64')
url='http://openocd.berlios.de'
license=('GPL')
-depends=('libftdi')
+depends=('libftdi' 'libusb-compat')
options=(!strip)
install=openocd.install
source=(http://downloads.sourceforge.net/sourceforge/$pkgname/$pkgname-$pkgver.tar.bz2)
@@ -19,8 +19,17 @@ sha256sums=('52237b786530c8460b221556c26fa4779f668b7dcb83ff14b8c5eb2050f38e63')
_features=(amtjtagaccel arm-jtag-ew at91rm9200 buspirate ep93xx ft2232_libftdi ftdi gw16012 jlink oocd_trace opendous osbdm parport presto_libftdi remote-bitbang rlink stlink ti-icdi ulink usbprog vsllink)
+# FIXME: needs /dev/bus/usb and cannot be compiled in chroot
+prepare() {
+ cd $pkgname-$pkgver
+ sed -i 's|$CC -E|$CC -O2 -E|g' configure
+ sed -i 's|\${CC} -E|$CC -O2 -E|g' configure
+ sed -i 's|-lftdi -lusb|-lftdi1 -lusb-1.0|g' configure src/Makefile*
+}
+
build() {
cd $pkgname-$pkgver
+ export CFLAGS="-I/usr/include/libftdi1"
./configure --prefix=/usr ${_features[@]/#/--enable-} --disable-werror
make
}