diff options
author | Bruce Korb <korbb@gcc.gnu.org> | 1999-03-10 07:49:54 +0000 |
---|---|---|
committer | Bruce Korb <korbb@gcc.gnu.org> | 1999-03-10 07:49:54 +0000 |
commit | 03affdf59a5c1b1d45a11caf0deaf2be4d57fe25 (patch) | |
tree | b9475e6582e92adf77a1ef81aba5a96b9a9f98d6 /gcc/fixinc/fixinc.svr4 | |
parent | 47898a19f0e80dd31bc9386a346ac7780bfe55a7 (diff) | |
download | gcc-03affdf59a5c1b1d45a11caf0deaf2be4d57fe25.zip gcc-03affdf59a5c1b1d45a11caf0deaf2be4d57fe25.tar.gz gcc-03affdf59a5c1b1d45a11caf0deaf2be4d57fe25.tar.bz2 |
Patches from superior directory
From-SVN: r25664
Diffstat (limited to 'gcc/fixinc/fixinc.svr4')
-rwxr-xr-x | gcc/fixinc/fixinc.svr4 | 36 |
1 files changed, 35 insertions, 1 deletions
diff --git a/gcc/fixinc/fixinc.svr4 b/gcc/fixinc/fixinc.svr4 index 46dec85..840a7d4 100755 --- a/gcc/fixinc/fixinc.svr4 +++ b/gcc/fixinc/fixinc.svr4 @@ -1,7 +1,7 @@ #! /bin/sh # Install modified versions of certain ANSI-incompatible # native System V Release 4 system include files. -# Copyright (C) 1994, 1996, 1997 Free Software Foundation, Inc. +# Copyright (C) 1994, 1996, 1997, 1998 Free Software Foundation, Inc. # Contributed by Ron Guilmette (rfg@monkeys.com). # # This file is part of GNU CC. @@ -1536,6 +1536,40 @@ if [ \! -z "$file_to_fix" ]; then rm -f /tmp/$base fi +# Similarly for struct queue in sys/stream.h. +file=sys/stream.h +base=`basename $file` +if [ -r ${LIB}/$file ]; then + file_to_fix=${LIB}/$file +else + if [ -r ${INPUT}/$file ]; then + file_to_fix=${INPUT}/$file + else + file_to_fix="" + fi +fi +if [ \! -z "$file_to_fix" ]; then + echo Checking $file_to_fix + sed -e '/struct[ ]*queue/i\ +#ifdef __cplusplus\ +#define queue __stream_queue\ +#endif'\ + -e '/struct[ ]*queue/a\ +#ifdef __cplusplus\ +#undef queue\ +#endif' $file_to_fix > /tmp/$base + if cmp $file_to_fix /tmp/$base >/dev/null 2>&1; then \ + true + else + echo Fixed $file_to_fix + mkdir -p $LIB/`dirname $file` + rm -f ${LIB}/$file + cp /tmp/$base ${LIB}/$file + chmod a+r ${LIB}/$file + fi + rm -f /tmp/$base +fi + echo 'Removing unneeded directories:' cd $LIB files=`find . -type d -print | sort -r` |