aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorSören Tempel <soeren+git@soeren-tempel.net>2016-02-10 11:13:47 +0100
committerSören Tempel <soeren+git@soeren-tempel.net>2016-02-10 11:27:03 +0100
commit300b30ecd312a69d5617c50a4399fbd0c80e6973 (patch)
treed6e98e19a370033cb5037ba567fae31256572075 /main
parentd97f040cb7356cc38f9581ebbdf460060d88999e (diff)
downloadaports-300b30ecd312a69d5617c50a4399fbd0c80e6973.tar.bz2
aports-300b30ecd312a69d5617c50a4399fbd0c80e6973.tar.xz
main/unrar: upgrade to 5.3.11
Also patch the makefile to make it respect our CXXFLAGS and LDFLAGS environment variables.
Diffstat (limited to 'main')
-rw-r--r--main/unrar/APKBUILD42
-rw-r--r--main/unrar/makefile.patch26
2 files changed, 53 insertions, 15 deletions
diff --git a/main/unrar/APKBUILD b/main/unrar/APKBUILD
index ba32b237d8..1936205f90 100644
--- a/main/unrar/APKBUILD
+++ b/main/unrar/APKBUILD
@@ -1,34 +1,46 @@
+# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=unrar
-pkgver=5.3.4
+pkgver=5.3.11
pkgrel=0
pkgdesc="The RAR uncompression program"
url="http://www.rarlab.com"
arch="all"
license="custom"
-depends=
-makedepends=
+depends=""
+makedepends=""
subpackages="$pkgname-doc"
-source="http://www.rarlab.com/rar/unrarsrc-$pkgver.tar.gz"
+source="http://www.rarlab.com/rar/unrarsrc-$pkgver.tar.gz
+ makefile.patch"
+_builddir="$srcdir"/$pkgname
prepare() {
- cd "$srcdir/$pkgname"
- sed -i 's/-O2/-Os/g' makefile
+ local i
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
}
build() {
- cd "$srcdir/$pkgname"
- make -f makefile || return 1
+ cd "$_builddir"
+ make CXX="${CXX:-g++}" CXXFLAGS="$CXXFLAGS" \
+ LDFLAGS="$LDFLAGS" STRIP=: -f makefile || return 1
}
package() {
- cd "$srcdir/$pkgname"
- install -Dm755 unrar "$pkgdir"/usr/bin/unrar
- install -Dm644 license.txt "$pkgdir/usr/share/licenses/$pkgname/license.txt"
-
+ cd "$_builddir"
+ install -Dm755 unrar "$pkgdir"/usr/bin/unrar || return 1
+ install -Dm644 license.txt \
+ "$pkgdir/usr/share/licenses/$pkgname/license.txt" || return 1
}
-md5sums="60afbc74a97eff512a6c42425ec43bbf unrarsrc-5.3.4.tar.gz"
-sha256sums="ce4767b8532f0866c609ec99a0b4d21a2f6cb8a786b15092ddf608ec4904b874 unrarsrc-5.3.4.tar.gz"
-sha512sums="8f1dab09aa51c2aa877165526838edf0a62fe460d334381aca6eee01a04e46b0093694f4eb75ecf0c0cf5de96cc97339e6dbe0a188aba1e8d2782605d48a6ca7 unrarsrc-5.3.4.tar.gz"
+md5sums="4a29cc1b47ced82db11e06090a95ed51 unrarsrc-5.3.11.tar.gz
+b36d660b20005b83987ce81614b8a600 makefile.patch"
+sha256sums="77b87af4b2976ef7c6b0c79e071284c2c1b035a9543273ec925f9d92f73b8763 unrarsrc-5.3.11.tar.gz
+fdebc5aee7399925d615421807d97d2663c61e7f894518877c0cb938bb4e1c24 makefile.patch"
+sha512sums="14ea833fe4c2d81718df25794d2e795a255f92c68a5533d6a7d2cbfc072db3ce07bba7ba1fd5555aad1a17fbaf4980eb217a7d9f6158461fa917e1a17590569b unrarsrc-5.3.11.tar.gz
+ba81ae03423f5843e3b3b3503829a067b4925b31b5a7348f6c1244a2c1663ed63f8b1fe8a80daa376c51ac128eb74aa7475bf3e53aa8fc9aac09929127b20e83 makefile.patch"
diff --git a/main/unrar/makefile.patch b/main/unrar/makefile.patch
new file mode 100644
index 0000000000..37505f4e98
--- /dev/null
+++ b/main/unrar/makefile.patch
@@ -0,0 +1,26 @@
+diff -upr unrar.orig/makefile unrar/makefile
+--- unrar.orig/makefile 2016-02-10 11:07:37.891117505 +0100
++++ unrar/makefile 2016-02-10 11:08:35.014309799 +0100
+@@ -3,11 +3,11 @@
+
+ # Linux using GCC
+ CXX=g++
+-CXXFLAGS=-O2
++CXXFLAGS?=-O2
+ LIBFLAGS=-fPIC
+ DEFINES=-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DRAR_SMP
+ STRIP=strip
+-LDFLAGS=-pthread
++LDFLAGS+=-pthread
+ DESTDIR=/usr
+
+ # Linux using LCC
+@@ -118,7 +118,7 @@ uninstall: uninstall-unrar
+ clean:
+ @rm -f *.o *.bak *~
+
+-unrar: clean $(OBJECTS) $(UNRAR_OBJ)
++unrar: $(OBJECTS) $(UNRAR_OBJ)
+ @rm -f unrar
+ $(LINK) -o unrar $(LDFLAGS) $(OBJECTS) $(UNRAR_OBJ) $(LIBS)
+ $(STRIP) unrar