aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2018-01-02 14:22:03 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2018-01-02 14:28:36 +0000
commitb5ffa723e1c742ecb99283db034d041f95279d58 (patch)
treee2a689120392e120b0f3299bb2fbf2c94f9d3e75
parent02b38ef8a4abb0abc41a202a359c6d0aa2a925e7 (diff)
downloadaports-b5ffa723e1c742ecb99283db034d041f95279d58.tar.gz
aports-b5ffa723e1c742ecb99283db034d041f95279d58.tar.bz2
aports-b5ffa723e1c742ecb99283db034d041f95279d58.tar.xz
main/usb-modeswitch: upgrade to 2.5.2, modernize APKBUILD
-rw-r--r--main/usb-modeswitch/APKBUILD45
1 files changed, 22 insertions, 23 deletions
diff --git a/main/usb-modeswitch/APKBUILD b/main/usb-modeswitch/APKBUILD
index 1cd917c95e..8769455e00 100644
--- a/main/usb-modeswitch/APKBUILD
+++ b/main/usb-modeswitch/APKBUILD
@@ -1,62 +1,61 @@
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=usb-modeswitch
-pkgver=2.5.1
+pkgver=2.5.2
pkgrel=0
-_pkgdata=20140529
+_pkgdata=20170806
pkgdesc="A mode switching tool for controlling flip flop (multiple device) USB gear"
url="http://www.draisberghof.de/usb_modeswitch/"
arch="all"
license="GPL-2.0-or-later"
-depends=""
makedepends="libusb-compat-dev coreutils tcl"
-install=
subpackages="$pkgname-doc $pkgname-udev"
+options="!check" # no testsuite
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
+builddir="$srcdir"/$pkgname-$pkgver
prepare() {
- cd "$_builddir"
- make clean || return 1
- sed -i -e 's/--mode=/-m/' Makefile || return 1
+ cd "$builddir"
+ make clean
+ sed -i -e 's/--mode=/-m/' Makefile
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
+ # sed -i -e 's%install -m644 -t $(PREFIX)/share/usb_modeswitch ./usb_modeswitch.d/*%cp -R $(PREFIX)/share/usb_modeswitch/* ./usb_modeswitch.d/%' Makefile
+ sed -i -e 's/--mode=/-m/' Makefile
}
build() {
- cd "$_builddir"
- make || return 1
+ cd "$builddir"
+ make
}
package() {
- cd "$_builddir"
- make DESTDIR="$pkgdir" install || return 1
+ 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
+ # ${pkgdir}/lib/udev/usb_modeswitch.tcl
+ # rmdir ${pkgdir}/lib/udev/usb_modeswitch
# mv ${pkgdir}/lib/udev/usb_modeswitch.tcl \
- # ${pkgdir}/lib/udev/usb_modeswitch || return 1
+ # ${pkgdir}/lib/udev/usb_modeswitch
# installing data
- cd $srcdir/usb-modeswitch-data-${_pkgdata} || return 1
- make DESTDIR=$pkgdir install || return 1
+ cd $srcdir/usb-modeswitch-data-${_pkgdata}
+ make DESTDIR=$pkgdir install
# installing config
- cp $srcdir/usb_modeswitch.setup $pkgdir/etc/ || return 1
+ cp $srcdir/usb_modeswitch.setup $pkgdir/etc/
}
udev() {
pkgdesc="udev support for usb-modeswitch"
depends="tcl eudev $pkgname=$pkgver-r$pkgrel"
mkdir -p "$subpkgdir"/usr/sbin
- mv "$pkgdir"/lib "$subpkgdir"/ || return 1
+ mv "$pkgdir"/lib "$subpkgdir"/
mv "$pkgdir"/usr/sbin/usb_modeswitch_dispatcher \
"$subpkgdir"/usr/sbin/
}
-sha512sums="23f1866cbb5882280369362f6d3e01d991136f322284d3f343da132520569f9e303cd9c4368a71893a3d959bae6bde2d4325f6dc175a1cb2d4dd5faa61add6ab usb-modeswitch-2.5.1.tar.bz2
-e0ac311ae09dcf41b45e9434bf43e7964ec0a32ac68024216ddfb6d6fd9d3b484cbe663ec081841e11a4af80e50fce12f1a06e0249aa229558085886c0f25809 usb-modeswitch-data-20140529.tar.bz2
+sha512sums="ad2a7e5134379664fca83b85803e52ec8e3fe3c2d6c633eb5af3c291c43b15ca4a67198612864de01d146a029ee5c475c8c7dc71d16e3a475b532837c5dd34ea usb-modeswitch-2.5.2.tar.bz2
+818bc9f3d9b75df245bb25f959075041667607e7681bdbca7006ec036613130a0fa5e41da9e939ca510e524a78a7a76aef82ecfbbe19611887b3735987b951cc usb-modeswitch-data-20170806.tar.bz2
48bc921849c529059c35f00e9cb10e92fee32622d63291bbd7184039bbe4c4324591b4011b24cf9b6c4ed2a7ad90fe0d5287a58631de5114b36f70d4f6f3c250 usb_modeswitch.setup"