aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCarlo Landmeter <clandmeter@gmail.com>2015-03-31 22:57:23 +0000
committerCarlo Landmeter <clandmeter@gmail.com>2015-03-31 22:58:09 +0000
commitb2c2cc4568702a523eb4b3ee82e1acd408b3d3f2 (patch)
treec7dbb239f89282fb089aadd68607368bc8fa50cc
parent2771f3523169f7a13536e3edf3669c44d13ffa3d (diff)
downloadaports-b2c2cc4568702a523eb4b3ee82e1acd408b3d3f2.tar.bz2
aports-b2c2cc4568702a523eb4b3ee82e1acd408b3d3f2.tar.xz
testing/libavl: new aport
-rw-r--r--testing/libavl/APKBUILD44
-rw-r--r--testing/libavl/libavl_0.3.5-3.patch39
2 files changed, 83 insertions, 0 deletions
diff --git a/testing/libavl/APKBUILD b/testing/libavl/APKBUILD
new file mode 100644
index 0000000000..f3b7214baa
--- /dev/null
+++ b/testing/libavl/APKBUILD
@@ -0,0 +1,44 @@
+# Contributor: Carlo Landmeter <clandmeter@gmail.com>
+# Maintainer:
+pkgname=libavl
+pkgver=0.3.5
+pkgrel=0
+pkgdesc="AVLTree is a small implementation of AVL trees"
+url="http://ftp.debian.org/debian/pool/main/liba/libavl"
+arch="all"
+license="LGPL"
+depends=""
+depends_dev=""
+makedepends="$depends_dev"
+install=""
+subpackages="$pkgname-dev"
+source="http://libavl.sourcearchive.com/downloads/0.3.5-3/libavl_$pkgver.orig.tar.gz
+ libavl_0.3.5-3.patch"
+_builddir="$srcdir/avl-$pkgver"
+
+prepare() {
+ 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 "$_builddir"
+ make || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make prefix="$pkgdir" install || return 1
+ rm -f "$pkgdir"/usr/lib/*.la
+}
+md5sums="882c68ea7f71876ca110f3b84d7ab12d libavl_0.3.5.orig.tar.gz
+71a9af7a70f37b1ac17a010872a47712 libavl_0.3.5-3.patch"
+sha256sums="4497b9e22cdd61ae2fa893b9d5fd6213dc306726d7c4be08c29e173622dca8a0 libavl_0.3.5.orig.tar.gz
+2784d360e5afae8b46104755f72d59317d997ac638b51bcffd1a2b70bf6894e9 libavl_0.3.5-3.patch"
+sha512sums="6a409025eb4560961c35bf0d80deb592ada9b448c497955ec7662a478fc4cebfdd46b9f33db0c913af773614752444563d29cea4418f896eb2761a233ee64b6d libavl_0.3.5.orig.tar.gz
+dd08c0bed82eefe304355f102d6b0c3a088cd199fcf3ca456a3c747d5da9059bc8621fab72db730d7fe67c52a51c01e7a0835107ef624db4e79a1c2a2e4c899d libavl_0.3.5-3.patch"
diff --git a/testing/libavl/libavl_0.3.5-3.patch b/testing/libavl/libavl_0.3.5-3.patch
new file mode 100644
index 0000000000..17107a9ca2
--- /dev/null
+++ b/testing/libavl/libavl_0.3.5-3.patch
@@ -0,0 +1,39 @@
+--- libavl-0.3.5.orig/GNUmakefile
++++ libavl-0.3.5/GNUmakefile
+@@ -6,7 +6,8 @@
+ LDCONFIG ?= /sbin/ldconfig
+
+ # Some suggestions: (-mcpu= generates i386 compatible code)
+-CFLAGS ?= -O2 -fomit-frame-pointer -pipe -mcpu=i686 -w
++CFLAGS ?= -O2 -pipe -Wall -Werror
++CFLAGS += -fPIC
+ #CFLAGS = -O2 -fomit-frame-pointer -pipe -march=i586 -Wall -g
+ #CFLAGS = -O6 -fomit-frame-pointer -pipe -march=i586 -Wall -ansi -pedantic
+ #CFLAGS = -O6 -fomit-frame-pointer -pipe -march=i686 -Wall -ansi -pedantic
+@@ -34,20 +35,21 @@
+ $(CC) $(LDFLAGS) $^ -o $@ $(LIBS)
+
+ $(LIBRARY): avl.o
+- $(CC) -nostdlib -shared -Wl,-soname,libavl.so.1 $^ -o $@ -lc
++ $(CC) -shared -Wl,-soname,libavl.so.1 $^ -o $@ -lc
+
+ clean:
+ $(RM) *.o $(PROGRAMS) libavl.*
+
+ install: all
+ $(INSTALL) -d $(DESTDIR)$(libdir)
+- $(INSTALL) avl.h $(DESTDIR)$(includedir)
+- $(INSTALL) $(LIBRARIES) $(DESTDIR)$(libdir)
+- for i in $(LIBRARIES); do\
++ $(INSTALL) -d $(DESTDIR)$(includedir)
++ $(INSTALL) -m 755 avl.h $(DESTDIR)$(includedir)
++ $(INSTALL) -m 755 $(LIBRARY) $(DESTDIR)$(libdir)
++ for i in $(LIBRARY); do\
+ $(LN) -sf $$i $(DESTDIR)$(libdir)/$${i%.*};\
+ $(LN) -sf $${i%.*} $(DESTDIR)$(libdir)/$${i%.*.*};\
+ done
+- -$(LDCONFIG)
++ #-$(LDCONFIG)
+
+ .PHONY: clean install all
+ .PRECIOUS: %.h %.c