diff options
author | Richard Stallman <rms@gnu.org> | 1992-07-25 08:34:46 +0000 |
---|---|---|
committer | Richard Stallman <rms@gnu.org> | 1992-07-25 08:34:46 +0000 |
commit | 3a6aca8e65b3096c59bef64888ef6f54a94606e3 (patch) | |
tree | 24655d64cf5873a4b8231cd8fa3052b67a825ef1 /gcc | |
parent | 63ea33ce94b20832f590b30b780dcde3c2bb6139 (diff) | |
download | gcc-3a6aca8e65b3096c59bef64888ef6f54a94606e3.zip gcc-3a6aca8e65b3096c59bef64888ef6f54a94606e3.tar.gz gcc-3a6aca8e65b3096c59bef64888ef6f54a94606e3.tar.bz2 |
(X11/Xmu/Xmu.h): Fix this or X11/Xmu.h, whichever exists.
From-SVN: r1686
Diffstat (limited to 'gcc')
-rwxr-xr-x | gcc/fixincludes | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/gcc/fixincludes b/gcc/fixincludes index efab8c2..eecc3dd 100755 --- a/gcc/fixincludes +++ b/gcc/fixincludes @@ -420,6 +420,31 @@ EOF fi fi +# Incorrect sprintf declaration in X11/Xmu/Xmu.h +# (It's not clear whether the right file name is this or X11/Xmu.h.) +file=X11/Xmu/Xmu.h +if [ -r $file ] && [ ! -r ${LIB}/$file ]; then + mkdir ${LIB}/X11/Xmu 2>/dev/null + cp $file ${LIB}/$file >/dev/null 2>&1 || echo "Can't copy $file" + chmod +w ${LIB}/$file 2>/dev/null +fi + +if [ -r ${LIB}/$file ]; then + echo Fixing $file sprintf declaration + ex ${LIB}/$file <<EOF + /^extern char \* sprintf();$/c +#ifndef __STDC__ +extern char * sprintf(); +#endif /* !defined __STDC__ */ +. + wq +EOF + if cmp $file ${LIB}/$file >/dev/null 2>&1; then + echo Deleting ${LIB}/$file\; no fixes were needed. + rm ${LIB}/$file + fi +fi + # Check for missing ';' in struct file=netinet/ip.h if [ -r $file ] && [ ! -r ${LIB}/$file ]; then |