summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Andres2019-10-06 12:56:00 +0200
committerThomas Andres2019-10-06 12:56:00 +0200
commit4c11e4a5f6a9a87ee11bc8750577e621ea9c16e3 (patch)
tree3a5aaff4a09d00f37caafb357b2302c8251a08b3
downloadaur-4c11e4a5f6a9a87ee11bc8750577e621ea9c16e3.tar.gz
Initial commit
-rw-r--r--.SRCINFO24
-rw-r--r--PKGBUILD56
2 files changed, 80 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..37b19a43937
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,24 @@
+pkgbase = openhantek6022-git
+ pkgdesc = A DSO software for Hantek USB digital signal oscilloscopes 6022BE / BL.
+ pkgver = v2.15
+ pkgrel = 1
+ url = https://github.com/OpenHantek/OpenHantek6022
+ arch = i686
+ arch = x86_64
+ license = GPL3
+ makedepends = git
+ makedepends = cmake
+ makedepends = make
+ makedepends = sed
+ makedepends = binutils
+ makedepends = gcc
+ makedepends = gendesk
+ depends = fftw
+ depends = qt5-base
+ provides = openhantek6022
+ conflicts = openhantek6022
+ source = git+https://github.com/OpenHantek/OpenHantek6022.git
+ md5sums = SKIP
+
+pkgname = openhantek6022-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..f98da2e075e
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,56 @@
+# Maintainer: Thomas Andres <thomas at andres dot in>
+pkgname=openhantek6022-git
+_gitname=OpenHantek6022
+pkgver=v2.15
+pkgrel=1
+pkgdesc="A DSO software for Hantek USB digital signal oscilloscopes 6022BE / BL."
+arch=('i686' 'x86_64')
+url=https://github.com/OpenHantek/OpenHantek6022
+license=('GPL3')
+depends=('fftw' 'qt5-base')
+makedepends=('git' 'cmake' 'make' 'sed' 'binutils' 'gcc' 'gendesk')
+conflicts=(openhantek6022)
+provides=(openhantek6022)
+source=('git+https://github.com/OpenHantek/OpenHantek6022.git')
+md5sums=('SKIP')
+
+prepare() {
+ gendesk -f -n \
+ --pkgname "$_gitname" \
+ --pkgdesc "$pkgdesc" \
+ --name "OpenHantek6022" \
+ --exec /usr/bin/OpenHantek \
+ --icon "$_gitname" \
+ --categories "Development;Science"
+
+ cd $_gitname
+ # change the udev directory to match arch defaults
+ sed -i 's/\/lib\/udev\/rules.d\//\/usr\/lib\/udev\/rules.d\//g' CMakeLists.txt
+}
+
+pkgver() {
+ cd $_gitname
+ git describe --tags $(git rev-list --tags --max-count=1)
+}
+
+build() {
+ cd $_gitname
+ git checkout $pkgver -q
+ [[ ! -d build ]] && mkdir -p build
+ cd build
+ cmake \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ ../
+ make -j$(nproc)
+}
+
+package() {
+ cd $_gitname/build
+ make DESTDIR=$pkgdir install
+
+ cd $srcdir
+ install -Dm644 "$_gitname.desktop" "$pkgdir/usr/share/applications/$_gitname.desktop"
+
+ cd $_gitname/openhantek/res/images
+ install -Dm644 OpenHantek6022.svg "$pkgdir/usr/share/pixmaps/$_gitname.svg"
+} \ No newline at end of file