summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJared Baldridge2017-05-21 17:22:29 -0700
committerJared Baldridge2017-05-21 17:22:29 -0700
commitef165b46584eb6aa8c08344c345674876eba344e (patch)
tree7d11086382474ada8e4d7b2c59fbe3da3670e011
downloadaur-ef165b46584eb6aa8c08344c345674876eba344e.tar.gz
Initial Packaging of umbim
-rw-r--r--.SRCINFO24
-rw-r--r--001-sbin-fix.patch10
-rw-r--r--PKGBUILD39
3 files changed, 73 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..844b7f904d47
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,24 @@
+pkgbase = umbim-git
+ pkgdesc = OpenWrt MBIM modem utility
+ pkgver = r17.29aaf43
+ pkgrel = 1
+ url = https://git.openwrt.org/project/umbim.git
+ arch = i686
+ arch = x86_64
+ license = GPL2
+ makedepends = git
+ makedepends = cmake
+ makedepends = gcc
+ makedepends = make
+ makedepends = patch
+ makedepends = pkg-config
+ depends = libubox
+ provides = umbim
+ conflicts = umbim
+ source = git://git.openwrt.org/project/umbim.git
+ source = 001-sbin-fix.patch
+ sha256sums = SKIP
+ sha256sums = a37c0e353e4cac3c148689fc0ed8a737ba8f4555a7969f5b507df8f00fee3b6b
+
+pkgname = umbim-git
+
diff --git a/001-sbin-fix.patch b/001-sbin-fix.patch
new file mode 100644
index 000000000000..ef4bf828fec1
--- /dev/null
+++ b/001-sbin-fix.patch
@@ -0,0 +1,10 @@
+diff -ura a/CMakeLists.txt b/CMakeLists.txt
+--- a/CMakeLists.txt 2017-05-21 17:04:54.989927392 -0700
++++ b/CMakeLists.txt 2017-05-21 17:07:42.506842792 -0700
+@@ -18,5 +18,5 @@
+ TARGET_LINK_LIBRARIES(umbim ${LIBS})
+
+ INSTALL(TARGETS umbim
+- RUNTIME DESTINATION sbin
++ RUNTIME DESTINATION bin
+ )
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..c80b78f8790c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,39 @@
+# Maintainer: Jared Baldridge <jrb@expunge.us>
+
+pkgname=umbim-git
+_gitname=umbim
+pkgver=r17.29aaf43
+pkgrel=1
+pkgdesc='OpenWrt MBIM modem utility'
+url='https://git.openwrt.org/project/umbim.git'
+arch=('i686' 'x86_64')
+license=('GPL2')
+depends=('libubox')
+makedepends=('git' 'cmake' 'gcc' 'make' 'patch' 'pkg-config')
+conflicts=('umbim')
+provides=('umbim')
+source=('git://git.openwrt.org/project/umbim.git' '001-sbin-fix.patch')
+sha256sums=('SKIP' 'a37c0e353e4cac3c148689fc0ed8a737ba8f4555a7969f5b507df8f00fee3b6b')
+
+pkgver() {
+ cd "$srcdir/$_gitname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "$srcdir/$_gitname"
+ patch -p1 -i "$srcdir/001-sbin-fix.patch"
+}
+
+
+build() {
+ cd "$srcdir/$_gitname"
+ cmake CMakeLists.txt \
+ -DCMAKE_INSTALL_PREFIX=/usr
+ make
+}
+
+package() {
+ cd "$srcdir/$_gitname"
+ make DESTDIR="$pkgdir" install
+}