aboutsummaryrefslogtreecommitdiffstats
path: root/main/pjproject
diff options
context:
space:
mode:
authorprspkt <prspkt@protonmail.com>2018-06-01 16:35:29 +0000
committerTimo Teräs <timo.teras@iki.fi>2018-07-19 09:54:06 +0300
commit62bd7fbdc69c22c4b0311bdb8b1a1fa77e395498 (patch)
tree64d6155c3e476db4f161bd27d8c89f3d4a131aab /main/pjproject
parent1e50faaa26bb67d85f7a036b751ef12f94f8f25c (diff)
downloadaports-62bd7fbdc69c22c4b0311bdb8b1a1fa77e395498.tar.bz2
aports-62bd7fbdc69c22c4b0311bdb8b1a1fa77e395498.tar.xz
main/pjproject: clarify license, modernize
Diffstat (limited to 'main/pjproject')
-rw-r--r--main/pjproject/APKBUILD30
1 files changed, 12 insertions, 18 deletions
diff --git a/main/pjproject/APKBUILD b/main/pjproject/APKBUILD
index 63084a25ef..0aa6f39552 100644
--- a/main/pjproject/APKBUILD
+++ b/main/pjproject/APKBUILD
@@ -6,7 +6,7 @@ pkgrel=4
pkgdesc="CLI Softphone"
url="http://www.pjsip.org/pjsua.htm"
arch="all"
-license="GPL"
+license="GPL-2.0-or-later"
depends=
depends_dev="libressl-dev alsa-lib-dev gsm-dev speex-dev speexdsp-dev
portaudio-dev libsrtp-dev libsamplerate-dev"
@@ -18,21 +18,16 @@ source="http://www.pjsip.org/release/$pkgver/$pkgname-$pkgver.tar.bz2
pjproject_no_third_party.patch
"
-_builddir="$srcdir/$pkgname-$pkgver"
+builddir="$srcdir/$pkgname-$pkgver"
prepare() {
- cd "$_builddir"
- for i in $source; do
- case $i in
- *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
- esac
- done
- update_config_sub || return 1
+ default_prepare
+ update_config_sub
# Remove target name from lib names
sed -i -e 's/-$(TARGET_NAME)//g' \
-e 's/= $(TARGET_NAME).a/= .a/g' \
-e 's/-$(LIB_SUFFIX)/$(LIB_SUFFIX)/g' \
- $(find . -name '*.mak*' -o -name Makefile) || return 1
+ $(find . -name '*.mak*' -o -name Makefile)
# Fix hardcoded prefix and flags
sed -i \
@@ -41,7 +36,7 @@ prepare() {
-e '/PJLIB_CFLAGS/ s/(_CFLAGS)/(_CFLAGS) -fPIC/g' \
-e '/PJLIB_UTIL_CFLAGS/ s/(_CFLAGS)/(_CFLAGS) -fPIC/g' \
Makefile \
- build.mak.in || return 1
+ build.mak.in
# Use libsamplerate instead of bundled resample
sed -i -e "s/resample//" third_party/build/Makefile
@@ -49,7 +44,7 @@ prepare() {
}
build() {
- cd "$_builddir"
+ cd "$builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -62,24 +57,23 @@ build() {
--with-external-speex \
--with-external-gsm \
--with-external-srtp \
- --with-external-pa \
- || return 1
+ --with-external-pa
# TODO: make it build with only shared libs from system
# rm -r third_party
- make dep || return 1
- make -j1 all || return 1
+ make dep
+ make -j1 all
}
package() {
- cd "$_builddir"
+ cd "$builddir"
install -d "$pkgdir"/usr/lib
make -j1 DESTDIR="$pkgdir" prefix=/usr install
}
pjsua() {
pkgdesc="pjsua is an open source command line SIP user agent (softphone)"
- cd "$_builddir"/pjsip-apps/bin/
+ cd "$builddir"/pjsip-apps/bin/
install -D -m755 pjsua "$subpkgdir"/usr/bin/pjsua
}