diff options
author | Kyle Keen | 2015-06-13 00:19:58 -0400 |
---|---|---|
committer | Kyle Keen | 2015-06-13 00:19:58 -0400 |
commit | c4afba1377e5ed42d233c2cb9eee8c86f3f33a8b (patch) | |
tree | 388b63b2d885703a4e7dd125940f9ce03c599f6f | |
download | aur-c4afba1377e5ed42d233c2cb9eee8c86f3f33a8b.tar.gz |
Initial import
-rw-r--r-- | .AURINFO | 21 | ||||
-rw-r--r-- | .SRCINFO | 23 | ||||
-rw-r--r-- | PKGBUILD | 58 | ||||
-rw-r--r-- | openhantek.install | 10 |
4 files changed, 112 insertions, 0 deletions
diff --git a/.AURINFO b/.AURINFO new file mode 100644 index 000000000000..fe8c65b528ab --- /dev/null +++ b/.AURINFO @@ -0,0 +1,21 @@ +pkgbase = openhantek + pkgdesc = Qt4 UI for Hantek DSO-2090/2150/2250/5200/5200A oscilloscopes. Includes firmware + pkgver = 0.2.0 + pkgrel = 6 + url = http://www.openhantek.org/ + install = openhantek.install + arch = i686 + arch = x86_64 + license = GPL + makedepends = binutils + makedepends = unzip + depends = qt4 + depends = libusb + depends = fftw + depends = libgl + depends = fxload + source = http://downloads.sourceforge.net/project/openhantek/openhantek/openhantek-0.2.0.tar.bz2 + source = http://downloads.sourceforge.net/project/openhantek/openhantek-extractfw/openhantek-extractfw-0.7.0.tar.bz2 + +pkgname = openhantek + diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..b3aee2b6883b --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,23 @@ +pkgbase = openhantek + pkgdesc = Qt4 UI for Hantek DSO-2090/2150/2250/5200/5200A oscilloscopes. Includes firmware + pkgver = 0.2.0 + pkgrel = 6 + url = http://www.openhantek.org/ + install = openhantek.install + arch = i686 + arch = x86_64 + license = GPL + makedepends = binutils + makedepends = unzip + depends = qt4 + depends = libusb + depends = fftw + depends = libgl + depends = fxload + source = http://downloads.sourceforge.net/project/openhantek/openhantek/openhantek-0.2.0.tar.bz2 + source = http://downloads.sourceforge.net/project/openhantek/openhantek-extractfw/openhantek-extractfw-0.7.0.tar.bz2 + md5sums = 57732229f063f582bfaa3c3cc942dae2 + md5sums = 9346d8e842cf1ea3eb378f21220e74b9 + +pkgname = openhantek + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..dbea3ff3dd6f --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,58 @@ +# Maintainer: Kyle Keen <keenerd@gmail.com> +pkgname=openhantek +pkgver=0.2.0 +_fwpkgver=0.7.0 +pkgrel=6 +pkgdesc="Qt4 UI for Hantek DSO-2090/2150/2250/5200/5200A oscilloscopes. Includes firmware" +arch=('i686' 'x86_64') +url="http://www.openhantek.org/" +license=('GPL') +depends=('qt4' 'libusb' 'fftw' 'libgl' 'fxload') +makedepends=('binutils' 'unzip') +install=openhantek.install +source=(http://downloads.sourceforge.net/project/$pkgname/$pkgname/$pkgname-$pkgver.tar.bz2 \ +http://downloads.sourceforge.net/project/$pkgname/$pkgname-extractfw/$pkgname-extractfw-0.7.0.tar.bz2) +md5sums=('57732229f063f582bfaa3c3cc942dae2' + '9346d8e842cf1ea3eb378f21220e74b9') + +# todo: handle groups, source firmware + +build() { + cd "$srcdir/$pkgname" + qmake-qt4 PREFIX="/usr" # Hah, if only. + sed -i 's|/local/|/|g' Makefile + sed -i 's|/local||g' OpenHantek.pro + # fix crashiness on Catalyst, makes display slightly uglier + #sed -i 's|GL_SMOOTH|GL_FLAT|' src/glscope.cpp + make + #sed -i 's|local/\(share/apps/openhantek/translations\)|\1\x00\x00\x00\x00\x00\x00|' bin/openhantek + + cd "$srcdir/$pkgname-extractfw" + ./configure --prefix=/usr + sed -i 's|/local/|/|g' Makefile + sed -i 's/-lbfd/& -ldl -liberty -lz/' Makefile + make + + # hantek changed their site, get these tweaks merged upstream + sed -i 's|"http.*"$|"http://www.hantek.com/Product/DSO2000"|' fwget.sh + sed -i 's|wget -O "$ARCHIVE"|wget -nc|' fwget.sh + sed -i 's|$MODEL/$ARCHIVE|DSO${MODEL}_Driver.zip|' fwget.sh + sed -i 's|unrar .*$|unzip -j "DSO${MODEL}_Driver.zip" "*861.sys" -d "$TARGETDIR"|' fwget.sh + ./fwget.sh + + sed -i 's|/local/|/|g' 90-hantek.rules + sed -i 's/SYSFS/ATTRS/g' 90-hantek.rules + sed -i 's/520A/520a/g' 90-hantek.rules +} + +package() { + cd "$srcdir/$pkgname" + make INSTALL_ROOT="$pkgdir" install + + cd "$srcdir/$pkgname-extractfw" + make DESTDIR="$pkgdir" install + for h in firmware/*.hex; do + install -Dm644 "$h" "$pkgdir/usr/share/hantek/${h/x86/}" + done + install -Dm644 90-hantek.rules "$pkgdir/usr/lib/udev/rules.d/90-hantek.rules" +} diff --git a/openhantek.install b/openhantek.install new file mode 100644 index 000000000000..4c6de0d00555 --- /dev/null +++ b/openhantek.install @@ -0,0 +1,10 @@ +post_install() { + echo "Please add your user to the plugdev group." + echo "# groupadd plugdev" + echo "# usermod -a -G plugdev USER" + echo "log out and back in again" +} + +post_upgrade() { + post_install $1 +} |