fi
fi
-# Fix getopt declarations in stdio.h and stdlib.h on Alpha OSF/1.
+# Fix getopt declarations in stdio.h and stdlib.h on Alpha OSF/1 and AIX.
for file in stdio.h stdlib.h; do
if [ -r $file ] && [ ! -r ${LIB}/$file ]; then
cp $file ${LIB}/$file >/dev/null 2>&1 || echo "Can't copy $file"
if [ -r ${LIB}/$file ]; then
echo Fixing $file, getopt declaration
- sed -e 's/getopt(int, char \*\[\],char \*)/getopt(int, char *const[], const char *)/' \
+ sed -e 's/getopt(int, char \*\[\],[ ]*char \*)/getopt(int, char *const[], const char *)/' \
${LIB}/$file > ${LIB}/${file}.sed
rm -f ${LIB}/$file; mv ${LIB}/${file}.sed ${LIB}/$file
if cmp $file ${LIB}/$file >/dev/null 2>&1; then