aboutsummaryrefslogtreecommitdiffstats
path: root/main/dhcpcd-ui
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2014-09-18 08:27:15 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2014-09-18 08:27:28 +0000
commite5e8b6436aa316124c7ba1f6146cd67119afcf71 (patch)
treea83ef81242432ab68dc4396c8a92a982fd55474a /main/dhcpcd-ui
parentf5edf3be6fda2e25ce8a47eba346c266351fb30f (diff)
downloadaports-e5e8b6436aa316124c7ba1f6146cd67119afcf71.tar.bz2
aports-e5e8b6436aa316124c7ba1f6146cd67119afcf71.tar.xz
main/dhcpcd-ui: upgrade to 0.7.1
Diffstat (limited to 'main/dhcpcd-ui')
-rw-r--r--main/dhcpcd-ui/APKBUILD27
-rw-r--r--main/dhcpcd-ui/strverscmp.patch56
2 files changed, 78 insertions, 5 deletions
diff --git a/main/dhcpcd-ui/APKBUILD b/main/dhcpcd-ui/APKBUILD
index d2017c12f0..08199c80cf 100644
--- a/main/dhcpcd-ui/APKBUILD
+++ b/main/dhcpcd-ui/APKBUILD
@@ -1,6 +1,6 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=dhcpcd-ui
-pkgver=0.6.0
+pkgver=0.7.1
pkgrel=0
pkgdesc="A GTK+ monitor and configuration GUI for dhcpcd"
url="http://roy.marples.name/projects/dhcpcd-ui"
@@ -10,10 +10,22 @@ depends="dhcpcd-dbus hicolor-icon-theme"
makedepends="glib-dev gtk+-dev dbus-dev libnotify-dev pkgconfig"
install=
subpackages="$pkgname-doc"
-source="http://roy.marples.name/downloads/dhcpcd/$pkgname-$pkgver.tar.bz2"
+source="http://roy.marples.name/downloads/dhcpcd/$pkgname-$pkgver.tar.bz2
+ strverscmp.patch
+ "
+
+_builddir="$srcdir"/dhcpcd-ui-$pkgver
+prepare() {
+ 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-$pkgver
+ cd "$_builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -23,8 +35,13 @@ build() {
}
package() {
- cd "$srcdir"/$pkgname-$pkgver
+ cd "$_builddir"
make DESTDIR="$pkgdir" AUTOSTARTDIR=/etc/xdg/autostart install
}
-md5sums="9c603d7cffbdaa62453f7620191c7286 dhcpcd-ui-0.6.0.tar.bz2"
+md5sums="6182f24077be3b5fec30caa812f457cb dhcpcd-ui-0.7.1.tar.bz2
+143644499e5b4d0681e1e45f8b9689ef strverscmp.patch"
+sha256sums="cc15a073c1678a28c2cb95848e333dfb94edb864e4937ea989682ae085a1a8c8 dhcpcd-ui-0.7.1.tar.bz2
+76420de0f9d306c1ae07bfd7534a0af0fc19bbd6582b9790271af91680574e52 strverscmp.patch"
+sha512sums="ffe5efeb00639961e4f5e964c4634a97cbb53a8c40f240e22098526772f1ddb19b4a487bc7ff7f3f9fb8f5edb66b00efc8d6c6ffe01973384e5e0515e5076f7b dhcpcd-ui-0.7.1.tar.bz2
+52538f697c227dbbd9f706fe0b09e3a6e716b1396065031e453b03c9add5bc03a19e48bacc5684d5db7d133734a51323f11306164f2061423fa66880e64e6520 strverscmp.patch"
diff --git a/main/dhcpcd-ui/strverscmp.patch b/main/dhcpcd-ui/strverscmp.patch
new file mode 100644
index 0000000000..0542a05706
--- /dev/null
+++ b/main/dhcpcd-ui/strverscmp.patch
@@ -0,0 +1,56 @@
+Index: configure
+==================================================================
+--- a/configure
++++ b/configure
+@@ -296,10 +296,32 @@
+ if [ "$STRLCPY" = no ]; then
+ echo "#define strlcpy(dst, src, n) " \
+ "((size_t)snprintf(dst, n, \"%s\", src))" \
+ >>$CONFIG_H
+ fi
++
++if [ -z "$STRVERSCMP" ]; then
++ printf "Testing for strverscmp ... "
++ cat <<EOF >_strverscmp.c
++#define _GNU_SOURCE
++#include <string.h>
++int main(void) {
++ strverscmp(NULL, NULL);
++ return 0;
++}
++EOF
++ if $XCC _strverscmp.c -o _strverscmp 2>/dev/null; then
++ STRVERSCMP=yes
++ else
++ STRVERSCMP=no
++ fi
++ echo "$STRVERSCMP"
++ rm -f _strverscmp.c _strverscmp
++fi
++if [ "$STRVERSCMP" = yes ]; then
++ echo "#define HAVE_STRVERSCMP" >>$CONFIG_H
++fi
+
+ if [ -z "$LIBDIR" ]; then
+ printf "lib directory name ... "
+ case `readlink /lib` in
+ "") LIBNAME="lib";;
+
+Index: src/libdhcpcd/dhcpcd.c
+==================================================================
+--- a/src/libdhcpcd/dhcpcd.c
++++ b/src/libdhcpcd/dhcpcd.c
+@@ -607,11 +607,11 @@
+
+ assert(con);
+ return con->progname;
+ }
+
+-#ifndef __GLIBC__
++#ifndef HAVE_STRVERSCMP
+ /* Good enough for our needs */
+ static int
+ strverscmp(const char *s1, const char *s2)
+ {
+ int s1maj, s1min, s1part;
+