From 8f186ca09b4ff2e507f07fb34a46702ab3f6dbac Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Tue, 11 Feb 2014 15:41:48 +0000 Subject: main/procps: upgrade to 3.3.9 and fix musl build --- main/procps/APKBUILD | 22 ++++++---- main/procps/fix-musl.patch | 102 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 117 insertions(+), 7 deletions(-) create mode 100644 main/procps/fix-musl.patch (limited to 'main/procps') diff --git a/main/procps/APKBUILD b/main/procps/APKBUILD index 1eaa2ef86..1b8b57cca 100644 --- a/main/procps/APKBUILD +++ b/main/procps/APKBUILD @@ -1,6 +1,6 @@ # Maintainer: Natanael Copa pkgname=procps -pkgver=3.3.8 +pkgver=3.3.9 pkgrel=0 pkgdesc="Utilities for monitoring your system and processes on your system" url="https://sourceforge.net/projects/procps-ng/" @@ -9,13 +9,18 @@ license="GPL LGPL" depends= makedepends="ncurses-dev autoconf automake" subpackages="$pkgname-dev $pkgname-doc libproc" -source="http://downloads.sourceforge.net/procps-ng/procps-ng-$pkgver.tar.xz" +source="http://downloads.sourceforge.net/procps-ng/procps-ng-$pkgver.tar.xz + fix-musl.patch" _builddir="$srcdir"/procps-ng-$pkgver prepare() { cd "$_builddir" - update_config_sub || return 1 - aclocal && autoconf && automake --add-missing + for i in $source; do + case $i in + *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; + esac + done + aclocal && autoconf && autoheader && automake --add-missing } build() { @@ -55,6 +60,9 @@ libproc() { mv "$pkgdir"/lib "$subpkgdir"/ } -md5sums="aecbeeda2ab308f8d09dddcb4cb9a572 procps-ng-3.3.8.tar.xz" -sha256sums="a4109cfb6fe3bcfb5a0efb37efe04d0c8ce858bff3820d48cc258bad41bed46b procps-ng-3.3.8.tar.xz" -sha512sums="63ba13f9ef0f4558748c6b2d1b0719a1173bd87e38279e3b052a10e207e1b808626d031f16dd65b05c55708366df7350cb0a64da8dc20e7f9f1fdc1cd2417c71 procps-ng-3.3.8.tar.xz" +md5sums="0980646fa25e0be58f7afb6b98f79d74 procps-ng-3.3.9.tar.xz +0d01ae50c41bb5f08edc146d08111897 fix-musl.patch" +sha256sums="00f0cb0fadf968ddf605b0ef119846af07386629244d4f3da711a2cecf4e8663 procps-ng-3.3.9.tar.xz +b1563d732e9364081cefe90d220caa7405609e1c45483af767dbeda6027b2323 fix-musl.patch" +sha512sums="62c7270aa48b4346a3198f306d1cb8474f64650bfb67e8cc6c4d41923e50c31c95b3a0367a464823fb50a6137ec0c6352006292ac85b50caf730ec8ec35eb553 procps-ng-3.3.9.tar.xz +7dd9554deaf2868e43b2566f96c13d6854c50a580fc497c5c25b3893746b8feec40f0d879fc9554517e54fd96f2311dbb0c60367773e75234e0e049cf5f45ecf fix-musl.patch" diff --git a/main/procps/fix-musl.patch b/main/procps/fix-musl.patch new file mode 100644 index 000000000..d6924b9a3 --- /dev/null +++ b/main/procps/fix-musl.patch @@ -0,0 +1,102 @@ +diff --git a/configure.ac b/configure.ac +index f08867c..a0150f0 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -45,7 +45,7 @@ AC_PROG_RANLIB + + # Checks for header files. + AC_HEADER_MAJOR +-AC_CHECK_HEADERS([arpa/inet.h fcntl.h langinfo.h libintl.h limits.h locale.h netinet/in.h stdint.h stdio_ext.h stdlib.h string.h sys/file.h sys/ioctl.h sys/param.h sys/time.h termios.h unistd.h utmp.h values.h wchar.h wctype.h]) ++AC_CHECK_HEADERS([arpa/inet.h fcntl.h langinfo.h libintl.h limits.h locale.h netinet/in.h stdint.h stdio_ext.h stdlib.h string.h sys/file.h sys/ioctl.h sys/param.h sys/time.h termios.h unistd.h utmp.h values.h wchar.h wctype.h error.h]) + + # Checks for typedefs, structures, and compiler characteristics. + AC_CHECK_HEADER_STDBOOL +@@ -235,7 +235,9 @@ if test "x$enable_numa" = xno; then + else + AC_SEARCH_LIBS([dlopen], [dl], [], + [AC_MSG_ERROR([dynamic linking unavailable, circumvent with --disable-numa])]) +- DL_LIB="$ac_cv_search_dlopen" ++ if test "x$ac_cv_search_dlopen" != "xnone required"; then ++ DL_LIB="$ac_cv_search_dlopen" ++ fi + fi + AC_SUBST([DL_LIB]) + +diff --git a/lib/nsutils.c b/lib/nsutils.c +index b97f446..a166a74 100644 +--- a/lib/nsutils.c ++++ b/lib/nsutils.c +@@ -1,5 +1,4 @@ + #include +-#include + #include + #include + #include +diff --git a/ps/display.c b/ps/display.c +index c20285d..b8d8fd5 100644 +--- a/ps/display.c ++++ b/ps/display.c +@@ -25,7 +25,9 @@ + #include + #include + #include ++#ifdef HAVE_ERROR_H + #include ++#endif + + #include + #include +@@ -63,7 +65,12 @@ static void signal_handler(int signo){ + case SIGUSR2: + exit(EXIT_FAILURE); + default: ++#ifdef HAVE_ERROR_H + error_at_line(0, 0, __FILE__, __LINE__, "%s", _("please report this bug")); ++#else ++ fflush(stdout); ++ fprintf(stderr, "%s:%u: %s\n", __FILE__, __LINE__, _("please report this bug")); ++#endif + signal(signo, SIG_DFL); /* allow core file creation */ + kill(getpid(), signo); + } +diff --git a/ps/global.c b/ps/global.c +index b75f728..d4d36a8 100644 +--- a/ps/global.c ++++ b/ps/global.c +@@ -25,7 +25,9 @@ + #include + #include + #include ++#ifdef HAVE_ERROR_H + #include ++#endif + + #include + #include +@@ -522,6 +524,11 @@ catastrophic_failure(const char *filename, + unsigned int linenum, + const char *message) + { ++#ifdef HAVE_ERROR_H + error_at_line(0, 0, filename, linenum, "%s", message); ++#else ++ fflush(stdout); ++ fprintf(stderr, "%s:%u: %s\n", filename, linenum, message); ++#endif + exit(EXIT_FAILURE); + } +diff --git a/sysctl.c b/sysctl.c +index bb3e6b7..8afd487 100644 +--- a/sysctl.c ++++ b/sysctl.c +@@ -48,6 +48,10 @@ + #include "proc/procps.h" + #include "proc/version.h" + ++#ifndef GLOB_TILDE ++#define GLOB_TILDE 0 ++#endif ++ + /* + * Globals... + */ -- cgit v1.2.3