]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Some versions of tr (noticed on a special Solaris8 version) fail to accept
authorMartin Kraemer <martin@apache.org>
Thu, 10 Oct 2002 16:36:21 +0000 (16:36 +0000)
committerMartin Kraemer <martin@apache.org>
Thu, 10 Oct 2002 16:36:21 +0000 (16:36 +0000)
the "tr '[a-z]' '[A-Z]'" syntax.  Fall back to some heuristics to create
a workable ap_config_auto.h anyway.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@97174 13f79535-47bb-0310-9956-ffa450edef68

src/Configure

index 71be31ff522175b19415cf2227460d1ccc7e265e..7b01132b58c9fd024fdc406e0f4efdf9acacc761 100755 (executable)
@@ -1005,6 +1005,13 @@ echo "" >>$AP_CONFIG_AUTO_H
 echo "#ifndef AP_CONFIG_AUTO_H" >>$AP_CONFIG_AUTO_H
 echo "#define AP_CONFIG_AUTO_H" >>$AP_CONFIG_AUTO_H
 
+for uppercase in "tr [a-z] [A-Z]" "tr [:lower:] [:upper:]" "sed y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/"
+do
+  case `echo Apache | $uppercase` in
+    APACHE) break;;
+  esac
+done
+echo " + using \"$uppercase\" to uppercase"
 echo " + checking for system header files"
 CHECK_FOR_HEADERS="dlfcn.h dl.h bstring.h crypt.h unistd.h sys/resource.h sys/select.h sys/processor.h sys/param.h"
 (
@@ -1012,7 +1019,7 @@ export CPP
 for header in $CHECK_FOR_HEADERS; do
     echo "" >>$AP_CONFIG_AUTO_H
     echo "/* check: #include <$header> */" >>$AP_CONFIG_AUTO_H
-    name="`echo $header | sed -e 's:/:_:g' -e 's:\.:_:g' | tr '[a-z]' '[A-Z]'`"
+    name="`echo $header | sed -e 's:/:_:g' -e 's:\.:_:g' | $uppercase`"
     ./helpers/checkheader.sh $header
     if [ $? -eq 0 ]; then
        echo "#ifndef HAVE_${name}" >>$AP_CONFIG_AUTO_H