summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD10
-rw-r--r--glibc-2.16-rpcgen-cpp-path.patch68
3 files changed, 79 insertions, 3 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 7e814dad6bd7..36dd0fd2441e 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = libx32-glibc
pkgdesc = GNU C Library for X32 ABI
pkgver = 2.16.0
- pkgrel = 2.1
+ pkgrel = 3.1
url = http://www.gnu.org/software/libc
arch = x86_64
license = GPL
@@ -14,11 +14,13 @@ pkgbase = libx32-glibc
source = http://ftp.gnu.org/gnu/libc/glibc-2.16.0.tar.xz.sig
source = glibc-2.15-fix-res_query-assert.patch
source = glibc-2.15-revert-c5a0802a.patch
+ source = glibc-2.16-rpcgen-cpp-path.patch
source = libx32-glibc.conf
md5sums = 80b181b02ab249524ec92822c0174cf7
md5sums = 2a1221a15575820751c325ef4d2fbb90
md5sums = 31f415b41197d85d3bbee3d1eecd06a3
md5sums = 0a0383d50d63f1c02919fe9943b82014
+ md5sums = ea6a43915474e8276e9361eed6a01280
md5sums = 34a4169d2bdc5a3eb83676a0831aae57
pkgname = libx32-glibc
diff --git a/PKGBUILD b/PKGBUILD
index 180c75897228..0eb5b0294e8c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 73695 2012-07-14 13:05:07Z allan $
+# $Id: PKGBUILD 75203 2012-08-16 01:54:21Z allan $
# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Jan de Groot <jgc@archlinux.org>
# Contributor: Allan McRae <allan@archlinux.org>
@@ -9,7 +9,7 @@
_pkgbasename=glibc
pkgname=libx32-$_pkgbasename
pkgver=2.16.0
-pkgrel=2.1
+pkgrel=3.1
pkgdesc="GNU C Library for X32 ABI"
arch=('x86_64')
url="http://www.gnu.org/software/libc"
@@ -20,11 +20,13 @@ options=('!strip' '!emptydirs')
source=(http://ftp.gnu.org/gnu/libc/${_pkgbasename}-${pkgver}.tar.xz{,.sig}
glibc-2.15-fix-res_query-assert.patch
glibc-2.15-revert-c5a0802a.patch
+ glibc-2.16-rpcgen-cpp-path.patch
libx32-glibc.conf)
md5sums=('80b181b02ab249524ec92822c0174cf7'
'2a1221a15575820751c325ef4d2fbb90'
'31f415b41197d85d3bbee3d1eecd06a3'
'0a0383d50d63f1c02919fe9943b82014'
+ 'ea6a43915474e8276e9361eed6a01280'
'34a4169d2bdc5a3eb83676a0831aae57')
build() {
@@ -38,6 +40,10 @@ build() {
# https://bugzilla.redhat.com/show_bug.cgi?id=552960
patch -p1 -i ${srcdir}/glibc-2.15-revert-c5a0802a.patch
+ # prevent need for /lib/cpp symlink
+ # http://sourceware.org/git/?p=glibc.git;a=commit;h=bf9b740a
+ patch -p1 -i ${srcdir}/glibc-2.16-rpcgen-cpp-path.patch
+
cd ${srcdir}
mkdir glibc-build
cd glibc-build
diff --git a/glibc-2.16-rpcgen-cpp-path.patch b/glibc-2.16-rpcgen-cpp-path.patch
new file mode 100644
index 000000000000..822b57294b3a
--- /dev/null
+++ b/glibc-2.16-rpcgen-cpp-path.patch
@@ -0,0 +1,68 @@
+diff --git a/sunrpc/rpc_main.c b/sunrpc/rpc_main.c
+index 06d951a..2103b10 100644
+--- a/sunrpc/rpc_main.c
++++ b/sunrpc/rpc_main.c
+@@ -75,12 +75,9 @@ struct commandline
+
+ static const char *cmdname;
+
+-#define SVR4_CPP "/usr/ccs/lib/cpp"
+-#define SUNOS_CPP "/lib/cpp"
+-
+ static const char *svcclosetime = "120";
+ static int cppDefined; /* explicit path for C preprocessor */
+-static const char *CPP = SUNOS_CPP;
++static const char *CPP = "/lib/cpp";
+ static const char CPPFLAGS[] = "-C";
+ static char *pathbuf;
+ static int cpp_pid;
+@@ -327,23 +324,17 @@ find_cpp (void)
+ {
+ struct stat buf;
+
+- if (stat (CPP, &buf) < 0)
+- { /* /lib/cpp or explicit cpp does not exist */
+- if (cppDefined)
+- {
+- fprintf (stderr, _ ("cannot find C preprocessor: %s \n"), CPP);
+- crash ();
+- }
+- else
+- { /* try the other one */
+- CPP = SVR4_CPP;
+- if (stat (CPP, &buf) < 0)
+- { /* can't find any cpp */
+- fputs (_ ("cannot find any C preprocessor (cpp)\n"), stdout);
+- crash ();
+- }
+- }
++ if (stat (CPP, &buf) == 0)
++ return;
++
++ if (cppDefined) /* user specified cpp but it does not exist */
++ {
++ fprintf (stderr, _ ("cannot find C preprocessor: %s\n"), CPP);
++ crash ();
+ }
++
++ /* fall back to system CPP */
++ CPP = "cpp";
+ }
+
+ /*
+@@ -374,8 +365,13 @@ open_input (const char *infile, const char *define)
+ close (1);
+ dup2 (pd[1], 1);
+ close (pd[0]);
+- execv (arglist[0], (char **) arglist);
+- perror ("execv");
++ execvp (arglist[0], (char **) arglist);
++ if (errno == ENOENT)
++ {
++ fprintf (stderr, _ ("cannot find C preprocessor: %s\n"), CPP);
++ exit (1);
++ }
++ perror ("execvp");
+ exit (1);
+ case -1:
+ perror ("fork");