summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorTed Alff2017-09-04 11:46:14 -0400
committerTed Alff2017-09-04 11:46:14 -0400
commit342c7cdbf30515c97f1a8c7f2d40a4c1f49e820d (patch)
tree46a052653b343e1e132ad6e29060ed93ff846dfe
downloadaur-342c7cdbf30515c97f1a8c7f2d40a4c1f49e820d.tar.gz
Initial upload
-rw-r--r--.SRCINFO22
-rw-r--r--PKGBUILD43
-rw-r--r--fix_version_lib_dir.patch21
3 files changed, 86 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..8d193f136779
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,22 @@
+# Generated by mksrcinfo v8
+# Mon Sep 4 15:45:54 UTC 2017
+pkgbase = openr2-git
+ pkgdesc = Library that implements the MFC/R2 and DTMF/R2 signalling over E1 lines
+ pkgver = r281.a0bf085
+ pkgrel = 1
+ url = http://www.libopenr2.org/
+ arch = i686
+ arch = x86_64
+ license = GPL
+ license = LGPL
+ makedepends = cmake
+ depends = glibc
+ provides = openr2
+ conflicts = openr2
+ source = openr2::git+https://github.com/moises-silva/openr2
+ source = fix_version_lib_dir.patch
+ sha256sums = SKIP
+ sha256sums = 402468b8877bff575c307f2f5c16ea3330a4d416b1f2e1ac42c341b7b8df4b5a
+
+pkgname = openr2-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..434f0c6ed959
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,43 @@
+# Maintainer: twa022 <twa022 at gmail dot com>
+
+_pkgname=openr2
+pkgname=${_pkgname}-git
+pkgver=r281.a0bf085
+pkgrel=1
+pkgdesc='Library that implements the MFC/R2 and DTMF/R2 signalling over E1 lines'
+arch=('i686' 'x86_64')
+url='http://www.libopenr2.org/'
+license=('GPL' 'LGPL')
+depends=('glibc') #dahdi only used for r2test (needs zaptel driver)
+makedepends=('cmake')
+provides=("${_pkgname}")
+conflicts=("${_pkgname}")
+source=("${_pkgname}::git+https://github.com/moises-silva/openr2"
+ 'fix_version_lib_dir.patch')
+sha256sums=('SKIP'
+ '402468b8877bff575c307f2f5c16ea3330a4d416b1f2e1ac42c341b7b8df4b5a')
+
+pkgver() {
+ cd "${srcdir}/${_pkgname}"
+ echo r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)
+}
+
+prepare() {
+ cd "${srcdir}/${_pkgname}"
+ patch -uNp2 -r- -i ../fix_version_lib_dir.patch
+}
+
+build() {
+ cd "${srcdir}/${_pkgname}"
+ [ -d build ] && rm -fr build
+ mkdir build
+ cd build
+ export CFLAGS="-Wno-unused-const-variable"
+ cmake .. -DCMAKE_INSTALL_PREFIX=/usr
+ make
+}
+
+package() {
+ cd "${srcdir}/${_pkgname}"/build
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/fix_version_lib_dir.patch b/fix_version_lib_dir.patch
new file mode 100644
index 000000000000..6be7231cf1db
--- /dev/null
+++ b/fix_version_lib_dir.patch
@@ -0,0 +1,21 @@
+diff -Naur ./openr2.orig/CMakeLists.txt ./openr2/CMakeLists.txt
+--- ./openr2.orig/CMakeLists.txt 2017-09-04 11:33:01.936526250 -0400
++++ ./openr2/CMakeLists.txt 2017-09-04 11:33:36.779858541 -0400
+@@ -3,7 +3,7 @@
+ CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
+ PROJECT(openr2)
+
+-SET(VERSION "1.3.0")
++SET(VERSION "1.3.2")
+ SET(PACKAGE "openr2")
+ SET(PACKAGE_BUGREPORT "")
+ SET(PACKAGE_NAME "OpenR2")
+@@ -19,7 +19,7 @@
+ SET(MY_LIB_PATH lib)
+ ELSE(DEFINED WIN32)
+ IF(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
+- SET(MY_LIB_PATH lib64)
++ SET(MY_LIB_PATH lib)
+ ELSE()
+ SET(MY_LIB_PATH lib)
+ ENDIF()