This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
[Urs Thuermann <urs@isnogud.escape.de>] 2.2.5 compile problem. fixincluded
- From: Andreas Jaeger <aj at suse dot de>
- To: libc-alpha at sources dot redhat dot com
- Cc: Urs Thuermann <urs at isnogud dot escape dot de>
- Date: Sun, 03 Mar 2002 14:55:54 +0100
- Subject: [Urs Thuermann <urs@isnogud.escape.de>] 2.2.5 compile problem. fixincluded
I've found this patch on another list. Uli, what do you think?
Andreas
--- Begin Message ---
Topics:
2.2.5 compile problem. fix included
--- End Message ---
--- Begin Message ---
- From: Urs Thuermann <urs at isnogud dot escape dot de>
- To: glibc-linux at ricardo dot ecn dot wfu dot edu
- Date: 01 Mar 2002 09:30:58 +0100
- Subject: 2.2.5 compile problem. fix included
When compiling glibc-2.2.5 the C preprocessor is not found when
calling glibc-2.2.5/scripts/cpp. This is because the return code of a
shell pipe is the return code of its last command, so that the shell
script does not notice when `type cpp` fails.
The following patch fixes the problem:
diff -ru glibc-2.2.5/scripts/cpp glibc/scripts/cpp
--- glibc-2.2.5/scripts/cpp Fri Nov 2 02:07:18 2001
+++ glibc/scripts/cpp Fri Mar 1 06:51:44 2002
@@ -1,8 +1,10 @@
#! /bin/sh
cpp=`which cpp 2>/dev/null`
if test $? -ne 0; then
- cpp=`type cpp 2>/dev/null | awk '{ print $NF }'`
- if test $? -ne 0; then
+ cpp=`type cpp 2>/dev/null`
+ if test $? -eq 0; then
+ cpp=`echo $cpp | awk '{ print $NF }'`
+ else
cpp=`gcc -print-file-name=cpp 2>/dev/null`
if test $? -ne 0; then
if test -x /lib/cpp; then
urs
--- End Message ---
--
Andreas Jaeger
SuSE Labs aj@suse.de
private aj@arthur.inka.de
http://www.suse.de/~aj