📄 configure
字号:
$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \|| { echo "configure: error: libtool configure failed" 1>&2; exit 1; }autoconf_compflags=$CFLAGSCFLAGS=$oCFLAGS# Make sure we can run config.sub.if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }fiecho $ac_n "checking host system type""... $ac_c" 1>&6echo "configure:1350: checking host system type" >&5host_alias=$hostcase "$host_alias" inNONE) case $nonopt in NONE) if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } fi ;; *) host_alias=$nonopt ;; esac ;;esachost=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`echo "$ac_t""$host" 1>&6if test x$prerelease != x; then PRERELEASE_TRUE= PRERELEASE_FALSE='#'else PRERELEASE_TRUE='#' PRERELEASE_FALSE=fi#known keywords for --enable/disable-foo(=yes/no)?KNOWN_KEYWORDS="shared|static|debug|warnings|diagnostic|profiling|linting|libwrap|preload"for keyword in `set | egrep '^enable_' | sed -e 's/^enable_\(.*\)=.*/\1/'`;do echo $keyword | egrep "^(${KNOWN_KEYWORDS})$" > /dev/null if test $? -ne 0; then echo "configure: warning: unknown option '$keyword'" 1>&2 sleep 10; fidone#solaris 2.5.1 is broken in many placescase $host in *-*-solaris2.5.1) echo "configure: warning: the server might not work properly on solaris 2.5.1" 1>&2 cat >> confdefs.h <<\EOF#define HAVE_SOLARIS_2_5_1 1EOF ;;esac#disable acceptlock#XXX add proper test for this?case $host in *-*-*bsd*) no_acceptlock=t ;; alpha-dec-osf*) no_acceptlock=t ;; *-*-solaris2.6) no_acceptlock=t ;; *-*-solaris2.7) no_acceptlock=t ;;esaccase $host in alpha-dec-osf*) cat >> confdefs.h <<\EOF#define HAVE_DEC_PROTO 1EOF cat >> confdefs.h <<\EOF#define HAVE_EXTRA_OSF_SYMBOLS 1EOF PRELOAD="RLD" CPPFLAGS="${CPPFLAGS} -D_XOPEN_SOURCE_EXTENDED -DBYTE_ORDER=LITTLE_ENDIAN -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_OSF_SOURCE" ;; *-*-hpux*) #hpux needs _PROTOTYPES to include prototypes #for configure (at least when cc is used) CPPFLAGS="${CPPFLAGS} -D_PROTOTYPES" ;; *-*-sunos4*) #XXX hardcode library path (find better way to do this?) cat >> confdefs.h <<\EOF#define LIBRARY_PATH "/usr/lib/"EOF base_library_path="/usr/lib/" echo "configure: warning: "notice: hardcoding /usr/lib for dlopen"" 1>&2 #nonstandard libfunction workaround #XXX proper test cat >> confdefs.h <<\EOF#define HAVE_BROKEN_VSPRINTF 1EOF #link problems with libresolv, hardcode domainname if test -s /etc/resolv.conf; then domainname_hardcoded=`grep domain /etc/resolv.conf | awk '{ print $2 }'` fi no_res_init=t cat >> confdefs.h <<\EOF#define HAVE_NO_RESOLVESTUFF 1EOF ;; *-*-solaris*) cat >> confdefs.h <<\EOF#define HAVE_SENDMSG_DEADLOCK 1EOF cat >> confdefs.h <<\EOF#define HAVE_SOLARIS_BUGS 1EOF cat >> confdefs.h <<\EOF#define BSD_COMP 1EOF ;; *-*-linux-*) # XXX This might only concern 2.0.x kernels (add test?) cat >> confdefs.h <<\EOF#define HAVE_DEFECT_RECVMSG 1EOF cat >> confdefs.h <<\EOF#define HAVE_LINUX_BUGS 1EOF cat >> confdefs.h <<\EOF#define SPT_PADCHAR '\0'EOF ;; *-*-openbsd*) #static sockd when profiling is enabled no_dynamic_profiled_sockd=t ;; *-*-irix*) PRELOAD="RLD" ;;esaccase $PRELOAD in RLD) PRELOAD_SEPERATOR=":" PRELOAD_VARIABLE="_RLD_LIST" PRELOAD_POSTFIX="DEFAULT" ;; *) PRELOAD_SEPERATOR=" " PRELOAD_VARIABLE="LD_PRELOAD" PRELOAD_POSTFIX="" ;;esac#define hosttypecat >> confdefs.h <<EOF#define HAVE_HOST_TYPE "$host"EOF#XXX add proper test for this?if test x$no_acceptlock != xt; then cat >> confdefs.h <<\EOF#define NEED_ACCEPTLOCK 1EOFfiecho $ac_n "checking for compiler flags""... $ac_c" 1>&6echo "configure:1540: checking for compiler flags" >&5case $host in #XXX check for compiler type, not architecture *-*-solaris*) if test "x$GCC" = x; then #-xs provides allows easier debugging with gdb comp_flags="-Xt -xs" #XXX -Xt needed to compile? #XXX due to some problems with sockaddr alignment #XXX sun cc needs -misalign comp_flags="$comp_flags -misalign -xO0" echo "$ac_t""$comp_flags" 1>&6 echo "configure: warning: there might currenly be some performance problems with suncc - it needs -misalign" 1>&2 $CC 2>&1 | grep ucbcc > /dev/null if test $? -eq 0; then #XXX ucbcc uses includes from /usr/ucbinclude, but these are #not complete. add /usr/include to include path to get #all prototypes (read/write are missing) #XXX host_cc="solaris-ucbcc" CPPFLAGS="-I/usr/include $CPPFLAGS${CPPFLAGS:+ } " fi fi# AC_MSG_RESULT($comp_flags) ;; alpha-dec-osf*) #XXX is it possible to get it to work with -newc? if test "x$GCC" = x; then comp_flags="-std1 -oldc" fi echo "$ac_t""$comp_flags" 1>&6 ;; *) echo "$ac_t""none" 1>&6 ;; #XXX make sure compiling with compiler options worksesacecho $ac_n "checking for support for -pipe compiler flag""... $ac_c" 1>&6echo "configure:1580: checking for support for -pipe compiler flag" >&5oCFLAGS=$CFLAGSCFLAGS="$CFLAGS -pipe"if test "$cross_compiling" = yes; then { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }else cat > conftest.$ac_ext <<EOF#line 1587 "configure"#include "confdefs.h"int main(){ return 0;}EOFif { (eval echo configure:1595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/nullthen echo "$ac_t""yes" 1>&6 comp_flags="${comp_flags} -pipe"else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -fr conftest* echo "$ac_t""no" 1>&6firm -fr conftest*fiCFLAGS="$oCFLAGS"echo $ac_n "checking for compilation with debugging""... $ac_c" 1>&6echo "configure:1612: checking for compilation with debugging" >&5# Check whether --enable-debug or --disable-debug was given.if test "${enable_debug+set}" = set; then enableval="$enable_debug" debug_enabled=telse if test x$prerelease != x; then debug_enabled=t fifiif test x$debug_enabled = xt; then #no optimalization wanted if test $ac_cv_prog_cc_g = yes; then CFLAGS="$CFLAGS -g" fi CPPFLAGS="-DDEBUG $CPPFLAGS" echo "$ac_t""yes" 1>&6else echo "$ac_t""no" 1>&6 #autoconf_compflags is set to "-g -O2" with GCC CFLAGS="$CFLAGS $autoconf_compflags"fi#-Wall ?echo $ac_n "checking for warning flags""... $ac_c" 1>&6echo "configure:1639: checking for warning flags" >&5# Check whether --enable-warnings or --disable-warnings was given.if test "${enable_warnings+set}" = set; then enableval="$enable_warnings" enable_warnings=telse if test x$prerelease != x; then enable_warnings=t fifi#construct warning flags in $warnif test x$enable_warnings != x; then #try to enable compiler specific warning flags if test "x$GCC" = x; then case $host in *sunos4*) #sunos cc# warn="" true ;; alpha-dec-osf*) #osf cc# warn="-w0 -check -portable -warnprotos" true ;; *-*-solaris*) warn="-v" #XXX sun cc won't link with -vc defined true ;; *-*-irix*) #sgi cc warn="-fullwarn" ;; *) #try -Wall (gcc) warn="-Wall" ;; esac else #gcc warnings warn="-Wall -W -Wnested-externs -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wcast-align -Wcast-qual -Wbad-function-cast -Wpointer-arith -Wundef" #warn="$warn -Wold-style-cast -Winline -Waggregate-return -Wconversion -Wwrite-strings -Wtraditional -Wshadow" fi oCFLAGS=$CFLAGS CFLAGS="$CFLAGS $warn" #make sure compilation is still possible cat > conftest.$ac_ext <<EOF#line 1690 "configure"#include "confdefs.h"int main() {; return 0; }EOFif { (eval echo configure:1697: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""$warn" 1>&6else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* echo "$ac_t""none" 1>&6 unset warnfirm -f conftest* CFLAGS=$oCFLAGSelse echo "$ac_t""none" 1>&6fi#NOTE: set warnings at the bottom; might interfere with testsCFLAGS="$CFLAGS $comp_flags"#-DDIAGNOSTICS?echo $ac_n "checking for compliation with DIAGNOSTIC""... $ac_c" 1>&6echo "configure:1718: checking for compliation with DIAGNOSTIC" >&5# Check whether --enable-diagnostic or --disable-diagnostic was given.if test "${enable_diagnostic+set}" = set; then enableval="$enable_diagnostic" cat >> confdefs.h <<\EOF#define DIAGNOSTIC 1EOF echo "$ac_t""yes" 1>&6else if test x$prerelease != x; then cat >> confdefs.h <<\EOF#define DIAGNOSTIC 1EOF echo "$ac_t""yes" 1>&6 else echo "$ac_t""no" 1>&6 fifi# Check whether --enable-profiling or --disable-profiling was given.if test "${enable_profiling+set}" = set; then enableval="$enable_profiling" cat >> confdefs.h <<\EOF#define HAVE_PROFILING 1EOF s_profiling=tfiif test x$s_profiling = xt; then SPROFIL_TRUE= SPROFIL_FALSE='#'else SPROFIL_TRUE='#' SPROFIL_FALSE=fi#static or dynamic sockd?if test x$no_dynamic_profiled_sockd = xt; then STATIC_SOCKD_TRUE= STATIC_SOCKD_FALSE='#'else STATIC_SOCKD_TRUE='#' STATIC_SOCKD_FALSE=fiif test x$no_dynamic_profiled_sockd = xt; then echo "configure: warning: sockd is built static when profiling is enabled" 1>&2fi# Check whether --enable-linting or --disable-linting was given.if test "${enable_linting+set}" = set; then enableval="$enable_linting" s_linting=tfi
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -