00001 #!/bin/sh 00002 00003 # runConfigureICU: This script will run the "configure" script for the appropriate platform 00004 # Only supported platforms are recognized 00005 00006 usage() 00007 { 00008 echo "runConfigure: Helper script to run \"configure\" for one of the supported platforms" 00009 echo "Usage: runConfigure \"<platform_name>\" [ args .. ] " 00010 echo " where <platform is the platform you want" 00011 echo " valid choices are :" 00012 echo " 1. 'AIX4.1.5xlC' if you are using xlC on AIX4.1.5" 00013 echo " 2. 'SOLARISCC' if you are using native CC compiler on Solaris" 00014 echo " 3. 'SOLARISGCC' if you are using GNU C++ compiler on Solaris" 00015 echo " 4. 'LinuxRedHat5.2 or LinuxRedHat6.0' if you are using GNU C++ compiler on Linux" 00016 echo " 5. 'HP/UX10.2CC' if you are using native C++ compiler on HP-UX10.2" 00017 echo " 6. 'HP/UX10.2ACC' if you are using Advanced C++ compiler on HP-UX10.2" 00018 echo " 7. 'HP/UX11CC' if you are using native C++ compiler on HP-UX11" 00019 echo " 8. 'HP/UX11ACC' if you are using Advanced C++ compiler on HP-UX11" 00020 echo " 9. 'AIX4.3xlC' if you are using xlC on AIX4.3" 00021 echo " 10. 'SOL2.7CC'if you are using native CC compiler on Solaris" 00022 echo " 11. 'PTX' if you are using c++ on Dynix/PTX v4.5" 00023 echo " 12. 'SOLARISX86' if you are using the native CC compiler on Solarisx86" 00024 echo " 13. 'AIX4.3VA' if you are using VA compiler on AIX4.3" 00025 echo 00026 echo "Any other options will be passed on to configure. (see 'configure --help')" 00027 00028 } 00029 00030 if test ${1}o = "o"; then 00031 usage 00032 exit 0 00033 fi 00034 00035 if test $1 = "-h"; then 00036 usage 00037 exit 0 00038 fi 00039 00040 platform=${1}; 00041 00042 shift 00043 00044 rm -f config.cache 00045 rm -f config.log 00046 rm -f config.status 00047 00048 if test x$configure = x 00049 then 00050 if test -f ./configure 00051 then 00052 configuredir=. 00053 else 00054 configuredir=`echo $0 | sed 's,[^/]*$,,'` 00055 if test x$configuredir = x$0 00056 then 00057 configuredir=. 00058 fi 00059 fi 00060 00061 if test x$configuredir = x 00062 then 00063 configuredir=. 00064 fi 00065 00066 configure=$configuredir/configure 00067 fi 00068 00069 case $platform in 00070 AIX4.1.5xlC) 00071 echo Running configure "$@" for AIX using xlC compiler ... 00072 CC=/usr/lpp/xlC/bin/xlc; export CC 00073 CXX=/usr/lpp/xlC/bin/xlC_r; export CXX 00074 #CPPFLAGS=-I/usr/lpp/xlC/include; export CPPFLAGS 00075 #LDFLAGS=-L/usr/lpp/xlC/lib; export LDFLAGS 00076 $configure "$@" ;; 00077 AIX4.3xlC) 00078 echo Running configure "$@" for AIX using xlC compiler ... 00079 CC=/usr/ibmcxx/bin/xlc; export CC 00080 CXX=/usr/ibmcxx/bin/xlC_r; export CXX 00081 #CPPFLAGS=-I/usr/lpp/xlC/include; export CPPFLAGS 00082 #LDFLAGS=-L/usr/lpp/xlC/lib; export LDFLAGS 00083 $configure "$@" ;; 00084 AIX4.3VA) 00085 echo Running configure "$@" for AIX using xlC compiler ... 00086 CC=/usr/vacpp/bin/xlc; export CC 00087 CXX=/usr/vacpp/bin/xlC_r; export CXX 00088 #CPPFLAGS=-I/usr/lpp/xlC/include; export CPPFLAGS 00089 #LDFLAGS=-L/usr/lpp/xlC/lib; export LDFLAGS 00090 $configure "$@" ;; 00091 SOLARISCC) 00092 echo Running configure "$@" for SOLARIS using native CC compiler ... 00093 CC=/usr/local/SUNWspro/bin/cc; export CC 00094 CXX=/usr/local/SUNWspro/bin/CC; export CXX 00095 $configure "$@" ;; 00096 SOLARISGCC) 00097 echo Running configure "$@" for Solaris using gcc compiler ... 00098 CXXFLAGS=-I/usr/local/include/g++; export CXXFLAGS 00099 LDFLAGS=-R/usr/local/lib; export LDFLAGS 00100 $configure "$@" ;; 00101 SOL2.7CC) 00102 echo Running configure "$@" for SOLARIS2.7cc using native CC compiler 00103 CC=/usr/local/SUNWspro/bin/cc; export CC 00104 CXX=/usr/local/SUNWspro/bin/CC; export CXX 00105 $configure "$@" ;; 00106 00107 SOLARISX86) 00108 echo Running configure "$@" for SOLARISX86 using native CC compiler 00109 CC=cc; export CC 00110 CXX=CC; export CXX 00111 CXX_FLAGS="-w -O";export CXX_FLAGS 00112 C_FLAGS="-w -O";export C_FLAGS 00113 LDFLAGS="-L -lCrun";export LDFLAGS 00114 $configure "$@" ;; 00115 00116 LinuxRedHat*) 00117 echo Running configure "$@" for Linux using gcc compiler ... 00118 CXX=g++; export CXX 00119 CC=gcc; export CC 00120 CXXFLAGS=-g; export CXXFLAGS 00121 CFLAGS=-g; export CFLAGS 00122 $configure "$@" ;; 00123 HP/UX10.2CC) 00124 echo Running configure "$@" for HP10.2 using native CC compiler ... 00125 CC=cc; export CC 00126 CXX=CC; export CXX 00127 $configure "$@" ;; 00128 HP/UX10.2ACC) 00129 echo Running configure "$@" for HP10.2 using aCC compiler ... 00130 CC=cc; export CC 00131 CXX=aCC; export CXX 00132 $configure "$@" ;; 00133 HP/UX11CC) 00134 echo Running configure "$@" for HP11 using native CC compiler ... 00135 CC=cc; export CC 00136 CXX=/opt/CC/bin/CC; export CXX 00137 $configure "$@" ;; 00138 HP/UX11ACC) 00139 echo Running configure "$@" for HP11 using aCC compiler ... 00140 CC=cc; export CC 00141 CXX=/opt/aCC/bin/aCC; export CXX 00142 $configure "$@" ;; 00143 PTX) 00144 echo Running configure "$@" for PTX using c++ compiler ... 00145 CC=cc; export CC 00146 CXX=c++; export CXX 00147 if test ${XMLINSTALL}o = "o"; then 00148 XMLINSTALL=/usr/local; export XMLINSTALL 00149 fi 00150 $configure --prefix=$XMLINSTALL "$@" ;; 00151 *) 00152 echo I do not recognize the option \"$platform\". Please type ${0} -h for help. 00153 exit 0;; 00154 esac 00155 00156 echo 00157 echo If the result of the above commands look OK to you, go to the directory 00158 echo $icu/source and type \"make\" to make the icu.