summaryrefslogtreecommitdiffstats
path: root/main/usb-modeswitch/APKBUILD
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2012-04-19 09:27:28 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2012-04-19 09:27:28 +0000
commitf76368c508ff676a1f534df1ac139759dda338a3 (patch)
tree66a6e57f8bf3d1f0bddec32a76fc4b9e0a9fbce8 /main/usb-modeswitch/APKBUILD
parenta39a024c32e9f0cc0d2cccc945bd9d96eeb11c2d (diff)
downloadaports-f76368c508ff676a1f534df1ac139759dda338a3.tar.bz2
aports-f76368c508ff676a1f534df1ac139759dda338a3.tar.xz
testing/usb-modeswitch: move to main
Diffstat (limited to 'main/usb-modeswitch/APKBUILD')
-rw-r--r--main/usb-modeswitch/APKBUILD54
1 files changed, 54 insertions, 0 deletions
diff --git a/main/usb-modeswitch/APKBUILD b/main/usb-modeswitch/APKBUILD
new file mode 100644
index 000000000..e5e86a513
--- /dev/null
+++ b/main/usb-modeswitch/APKBUILD
@@ -0,0 +1,54 @@
+# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
+pkgname=usb-modeswitch
+pkgver=1.2.3
+pkgrel=0
+_pkgdata=20120120
+pkgdesc="A mode switching tool for controlling flip flop (multiple device) USB gear"
+url="http://www.draisberghof.de/usb_modeswitch/"
+arch="all"
+license="GPL"
+depends="tcl"
+makedepends="libusb-compat-dev coreutils"
+install=
+subpackages="$pkgname-doc"
+source="http://www.draisberghof.de/usb_modeswitch/${pkgname}-${pkgver}.tar.bz2
+ http://www.draisberghof.de/usb_modeswitch/${pkgname}-data-${_pkgdata}.tar.bz2
+ usb_modeswitch.setup"
+
+_builddir="$srcdir"/$pkgname-$pkgver
+
+prepare() {
+ cd "$_builddir"
+ make clean || return 1
+ sed -i -e 's/--mode=/-m/' Makefile || return 1
+
+ cd ../${pkgname}-data-${_pkgdata}
+# sed -i -e 's%install -m644 -t $(PREFIX)/share/usb_modeswitch ./usb_modeswitch.d/*%cp -R $(PREFIX)/share/usb_modeswitch/* ./usb_modeswitch.d/%' Makefile || return 1
+ sed -i -e 's/--mode=/-m/' Makefile || return 1
+}
+
+build() {
+ cd "$_builddir"
+ make || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make DESTDIR="$pkgdir" install
+ # adjusting the tcl script location
+ # mv ${pkgdir}/lib/udev/usb_modeswitch/usb_modeswitch.tcl \
+ # ${pkgdir}/lib/udev/usb_modeswitch.tcl || return 1
+ # rmdir ${pkgdir}/lib/udev/usb_modeswitch || return 1
+ # mv ${pkgdir}/lib/udev/usb_modeswitch.tcl \
+ # ${pkgdir}/lib/udev/usb_modeswitch || return 1
+
+ # installing data
+ cd $srcdir/usb-modeswitch-data-${_pkgdata} || return 1
+ make DESTDIR=$pkgdir install || return 1
+ # installing config
+ cp $srcdir/usb_modeswitch.setup $pkgdir/etc/ || return 1
+}
+
+md5sums="9b29e8b0d93d7604a9e5efc4696d37a3 usb-modeswitch-1.2.3.tar.bz2
+c899cc9c71bb35f3ec600b7cd1455c65 usb-modeswitch-data-20120120.tar.bz2
+9a25756669937ac86774bb55733f09cd usb_modeswitch.setup"