From 7472f9034f3460c9f16068e3e79f6a5c2e414ed2 Mon Sep 17 00:00:00 2001 From: Jeff Law Date: Tue, 7 Feb 2012 12:03:30 -0700 Subject: [PATCH] Find cpp in /usr/bin too (#767662) --- glibc-rh787662.patch | 32 ++++++++++++++++++++++++++++++++ glibc.spec | 11 +++++++++-- 2 files changed, 41 insertions(+), 2 deletions(-) create mode 100644 glibc-rh787662.patch diff --git a/glibc-rh787662.patch b/glibc-rh787662.patch new file mode 100644 index 0000000..a252253 --- /dev/null +++ b/glibc-rh787662.patch @@ -0,0 +1,32 @@ +diff -rup a/sunrpc/rpc_main.c b/sunrpc/rpc_main.c +--- a/sunrpc/rpc_main.c 2012-01-01 05:16:32.000000000 -0700 ++++ b/sunrpc/rpc_main.c 2012-02-07 11:06:16.479796121 -0700 +@@ -77,6 +77,7 @@ static const char *cmdname; + + #define SVR4_CPP "/usr/ccs/lib/cpp" + #define SUNOS_CPP "/lib/cpp" ++#define USR_LIB_CPP "/usr/bin/cpp" + + static const char *svcclosetime = "120"; + static int cppDefined; /* explicit path for C preprocessor */ +@@ -343,12 +344,16 @@ find_cpp (void) + crash (); + } + else +- { /* try the other one */ ++ { /* try the other ones */ + CPP = SVR4_CPP; + if (stat (CPP, &buf) < 0) +- { /* can't find any cpp */ +- fputs (_ ("cannot find any C preprocessor (cpp)\n"), stdout); +- crash (); ++ { ++ CPP = USR_LIB_CPP; ++ if (stat (CPP, &buf) < 0) ++ { /* can't find any cpp */ ++ fputs (_ ("cannot find any C preprocessor (cpp)\n"), stdout); ++ crash (); ++ } + } + } + } diff --git a/glibc.spec b/glibc.spec index 462bdaa..5978117 100644 --- a/glibc.spec +++ b/glibc.spec @@ -2,7 +2,7 @@ %define glibcversion 2.15 %define glibcportsdir glibc-ports-2.15-ad8ae7d ### glibc.spec.in follows: -%define run_glibc_tests 0 +%define run_glibc_tests 1 %define auxarches athlon alphaev6 %define xenarches i686 athlon %ifarch %{xenarches} @@ -28,7 +28,7 @@ Summary: The GNU libc libraries Name: glibc Version: %{glibcversion} -Release: 13%{?dist} +Release: 14%{?dist} # GPLv2+ is used in a bunch of programs, LGPLv2+ is used for libraries. # Things that are linked directly into dynamically linked programs # and shared libraries (e.g. crt files, lib*_nonshared.a) have an additional @@ -78,6 +78,9 @@ Patch21: %{name}-rh770869.patch Patch22: %{name}-rh691912.patch # Not necessary to send upstream Patch23: %{name}-rh688948.patch +# Given the upstream attitude towards rpc stuff, this will +# almost certainly be rejected. +Patch24: %{name}-rh787662.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -320,6 +323,7 @@ rm -rf %{glibcportsdir} %patch21 -p1 %patch22 -p1 %patch23 -p1 +%patch24 -p1 # A lot of programs still misuse memcpy when they have to use # memmove. The memcpy implementation below is not tolerant at @@ -1172,6 +1176,9 @@ rm -f *.filelist* %endif %changelog +* Tue Feb 7 2012 Jeff Law - 2.15-14 + - Find cpp in /usr/bin too (#767662) + * Mon Feb 6 2012 Jeff Law - 2.15-13 - More accurately detect if we're in a chroot (#688948)