⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 configure

📁 siproxd is a proxy/masquerading for the SIP protocal.
💻
📖 第 1 页 / 共 5 页
字号:
# -pthreads: Solaris/gcc# -mthreads: Mingw32/gcc, Lynx/gcc# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it#      doesn't hurt to check since this sometimes defines pthreads too;#      also defines -D_REENTRANT)# pthread: Linux, etcetera# --thread-safe: KAI C++case "${host_cpu}-${host_os}" in        *solaris*)        # On Solaris (at least, for some versions), libc contains stubbed        # (non-functional) versions of the pthreads routines, so link-based        # tests will erroneously succeed.  (We need to link with -pthread or        # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather        # a function called by this macro, so we could check for that, but        # who knows whether they'll stub that too in a future libc.)  So,        # we'll just look for -pthreads and -lpthread first:        acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"        ;;esacif test x"$acx_pthread_ok" = xno; thenfor flag in $acx_pthread_flags; do        case $flag in                none)                echo $ac_n "checking whether pthreads work without any flags""... $ac_c" 1>&6echo "configure:1675: checking whether pthreads work without any flags" >&5                ;;                -*)                echo $ac_n "checking whether pthreads work with $flag""... $ac_c" 1>&6echo "configure:1680: checking whether pthreads work with $flag" >&5                PTHREAD_CFLAGS="$flag"                ;;                *)                echo $ac_n "checking for the pthreads library -l$flag""... $ac_c" 1>&6echo "configure:1686: checking for the pthreads library -l$flag" >&5                PTHREAD_LIBS="-l$flag"                ;;        esac        save_LIBS="$LIBS"        save_CFLAGS="$CFLAGS"        LIBS="$PTHREAD_LIBS $LIBS"        CFLAGS="$CFLAGS $PTHREAD_CFLAGS"        # Check for various functions.  We must include pthread.h,        # since some functions may be macros.  (On the Sequent, we        # need a special flag -Kthread to make this header compile.)        # We check for pthread_join because it is in -lpthread on IRIX        # while pthread_create is in libc.  We check for pthread_attr_init        # due to DEC craziness with -lpthreads.  We check for        # pthread_cleanup_push because it is one of the few pthread        # functions on Solaris that doesn't have a non-functional libc stub.        # We try pthread_create on general principles.        cat > conftest.$ac_ext <<EOF#line 1706 "configure"#include "confdefs.h"#include <pthread.h>int main() {pthread_t th; pthread_join(th, 0);                     pthread_attr_init(0); pthread_cleanup_push(0, 0);                     pthread_create(0,0,0,0); pthread_cleanup_pop(0); ; return 0; }EOFif { (eval echo configure:1715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then  rm -rf conftest*  acx_pthread_ok=yeselse  echo "configure: failed program was:" >&5  cat conftest.$ac_ext >&5firm -f conftest*        LIBS="$save_LIBS"        CFLAGS="$save_CFLAGS"        echo "$ac_t""$acx_pthread_ok" 1>&6        if test "x$acx_pthread_ok" = xyes; then                break;        fi        PTHREAD_LIBS=""        PTHREAD_CFLAGS=""donefi# Various other checks:if test "x$acx_pthread_ok" = xyes; then        save_LIBS="$LIBS"        LIBS="$PTHREAD_LIBS $LIBS"        save_CFLAGS="$CFLAGS"        CFLAGS="$CFLAGS $PTHREAD_CFLAGS"        # Detect AIX lossage: threads are created detached by default        # and the JOINABLE attribute has a nonstandard name (UNDETACHED).        echo $ac_n "checking for joinable pthread attribute""... $ac_c" 1>&6echo "configure:1747: checking for joinable pthread attribute" >&5        cat > conftest.$ac_ext <<EOF#line 1749 "configure"#include "confdefs.h"#include <pthread.h>int main() {int attr=PTHREAD_CREATE_JOINABLE;; return 0; }EOFif { (eval echo configure:1756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then  rm -rf conftest*  ok=PTHREAD_CREATE_JOINABLEelse  echo "configure: failed program was:" >&5  cat conftest.$ac_ext >&5  rm -rf conftest*  ok=unknownfirm -f conftest*        if test x"$ok" = xunknown; then                cat > conftest.$ac_ext <<EOF#line 1768 "configure"#include "confdefs.h"#include <pthread.h>int main() {int attr=PTHREAD_CREATE_UNDETACHED;; return 0; }EOFif { (eval echo configure:1775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then  rm -rf conftest*  ok=PTHREAD_CREATE_UNDETACHEDelse  echo "configure: failed program was:" >&5  cat conftest.$ac_ext >&5  rm -rf conftest*  ok=unknownfirm -f conftest*        fi        if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then                cat >> confdefs.h <<\EOF#define PTHREAD_CREATE_JOINABLE $okEOF        fi        echo "$ac_t""${ok}" 1>&6        if test x"$ok" = xunknown; then                echo "configure: warning: we do not know how to create joinable pthreads" 1>&2        fi        echo $ac_n "checking if more special flags are required for pthreads""... $ac_c" 1>&6echo "configure:1798: checking if more special flags are required for pthreads" >&5        flag=no        case "${host_cpu}-${host_os}" in                *-aix* | *-freebsd*)     flag="-D_THREAD_SAFE";;                *solaris* | alpha*-osf*) flag="-D_REENTRANT";;        esac        echo "$ac_t""${flag}" 1>&6        if test "x$flag" != xno; then                PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"        fi        LIBS="$save_LIBS"        CFLAGS="$save_CFLAGS"        # More AIX lossage: must compile with cc_r        # Extract the first word of "cc_r", so it can be a program name with args.set dummy cc_r; ac_word=$2echo $ac_n "checking for $ac_word""... $ac_c" 1>&6echo "configure:1816: checking for $ac_word" >&5if eval "test \"`echo '$''{'ac_cv_prog_PTHREAD_CC'+set}'`\" = set"; then  echo $ac_n "(cached) $ac_c" 1>&6else  if test -n "$PTHREAD_CC"; then  ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.else  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"  ac_dummy="$PATH"  for ac_dir in $ac_dummy; do    test -z "$ac_dir" && ac_dir=.    if test -f $ac_dir/$ac_word; then      ac_cv_prog_PTHREAD_CC="cc_r"      break    fi  done  IFS="$ac_save_ifs"  test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"fifiPTHREAD_CC="$ac_cv_prog_PTHREAD_CC"if test -n "$PTHREAD_CC"; then  echo "$ac_t""$PTHREAD_CC" 1>&6else  echo "$ac_t""no" 1>&6fielse        PTHREAD_CC="$CC"fi# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:if test x"$acx_pthread_ok" = xyes; then        cat >> confdefs.h <<\EOF#define HAVE_PTHREAD 1EOF        :else        acx_pthread_ok=no        echo "*** ERROR: pthreads is required!"; exit 1;fiif test "x$build_static_pthread" = "xno"; then      LIBS="$PTHREAD_LIBS $LIBS"   CFLAGS="$CFLAGS $PTHREAD_CFLAGS"   CC="$PTHREAD_CC"else         echo $ac_n "checking "where I can find static threads library"""... $ac_c" 1>&6echo "configure:1870: checking "where I can find static threads library"" >&5   libpthreads_static=`find $extra_libs /lib /usr/lib /usr/local/lib \                       -name 'lib*thread*.a' 2>/dev/null| \                       egrep 'libp?threads?.a' |head -1`   if test "x$libpthreads_static" != "x"; then      LIBS="$libpthreads_static $LIBS"      echo "$ac_t""$libpthreads_static" 1>&6   else      echo "*** ERROR: a static threads library is required!";exit 1;   fi   CC="$PTHREAD_CC"filibosip_prefix_dir=""# Check whether --with-libosip-prefix or --without-libosip-prefix was given.if test "${with_libosip_prefix+set}" = set; then  withval="$with_libosip_prefix"  if test x$withval != x ; then libosip_prefix_dir="$withval"; fifiif test x$libosip_prefix_dir != x; then   LIBS="-L$libosip_prefix_dir/lib $LIBS"   CPPFLAGS="$CPPFLAGS -I$libosip_prefix_dir/include"fiif test "x$build_static_libosip" = "xno"; then      echo $ac_n "checking for osip_init in -losip2""... $ac_c" 1>&6echo "configure:1900: checking for osip_init in -losip2" >&5ac_lib_var=`echo osip2'_'osip_init | sed 'y%./+-%__p_%'`if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then  echo $ac_n "(cached) $ac_c" 1>&6else  ac_save_LIBS="$LIBS"LIBS="-losip2 -losipparser2 $LIBS"cat > conftest.$ac_ext <<EOF#line 1908 "configure"#include "confdefs.h"/* Override any gcc2 internal prototype to avoid an error.  *//* We use char because int might match the return type of a gcc2    builtin and then its argument prototype would still apply.  */char osip_init();int main() {osip_init(); return 0; }EOFif { (eval echo configure:1919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then  rm -rf conftest*  eval "ac_cv_lib_$ac_lib_var=yes"else  echo "configure: failed program was:" >&5  cat conftest.$ac_ext >&5  rm -rf conftest*  eval "ac_cv_lib_$ac_lib_var=no"firm -f conftest*LIBS="$ac_save_LIBS"fiif eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then  echo "$ac_t""yes" 1>&6    ac_tr_lib=HAVE_LIB`echo osip2 | sed -e 's/[^a-zA-Z0-9_]/_/g' \    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`  cat >> confdefs.h <<EOF#define $ac_tr_lib 1EOF  LIBS="-losip2 $LIBS"else  echo "$ac_t""no" 1>&6echo "*** ERROR: libosip2 is required!  "\            "Maybe you need to use --with-libosip-prefix ?"; exit 1;fi   echo $ac_n "checking for parser_init in -losipparser2""... $ac_c" 1>&6echo "configure:1949: checking for parser_init in -losipparser2" >&5ac_lib_var=`echo osipparser2'_'parser_init | sed 'y%./+-%__p_%'`if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then  echo $ac_n "(cached) $ac_c" 1>&6else  ac_save_LIBS="$LIBS"LIBS="-losipparser2  $LIBS"cat > conftest.$ac_ext <<EOF#line 1957 "configure"#include "confdefs.h"/* Override any gcc2 internal prototype to avoid an error.  *//* We use char because int might match the return type of a gcc2    builtin and then its argument prototype would still apply.  */char parser_init();int main() {parser_init(); return 0; }EOFif { (eval echo configure:1968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then  rm -rf conftest*  eval "ac_cv_lib_$ac_lib_var=yes"else  echo "configure: failed program was:" >&5  cat conftest.$ac_ext >&5  rm -rf conftest*  eval "ac_cv_lib_$ac_lib_var=no"firm -f conftest*LIBS="$ac_save_LIBS"fiif eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then  echo "$ac_t""yes" 1>&6    ac_tr_lib=HAVE_LIB`echo osipparser2 | sed -e 's/[^a-zA-Z0-9_]/_/g' \    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`  cat >> confdefs.h <<EOF#define $ac_tr_lib 1EOF  LIBS="-losipparser2 $LIBS"else  echo "$ac_t""no" 1>&6echo "*** ERROR: libosipparser2 is required!";exit 1;fielse         echo $ac_n "checking "where I can find libosip2.a"""... $ac_c" 1>&6echo "configure:1998: checking "where I can find libosip2.a"" >&5   libosip_static=`find $extra_libs /lib /usr/lib /usr/local/lib \                   -name libosip2.a 2>/dev/null|head -1`   if test "x$libosip_static" != "x"; then      LIBS="$libosip_static $LIBS"      echo "$ac_t""$libosip_static" 1>&6   else      echo "*** ERROR: a static libosip library is required!";exit 1;   fi   echo $ac_n "checking "where I can find libosipparser2.a"""... $ac_c" 1>&6echo "configure:2008: checking "where I can find libosipparser2.a"" >&5   libosip_static=`find $extra_libs /lib /usr/lib /usr/local/lib \                   -name libosipparser2.a 2>/dev/null|head -1`   if test "x$libosip_static" != "x"; then      LIBS="$libosip_static $LIBS"      echo "$ac_t""$libosip_static" 1>&6   else      echo "*** ERROR: a static libosip library is required!";exit 1;   fifiecho $ac_n "checking for ANSI C header files""... $ac_c" 1>&6echo "configure:2021: checking for ANSI C header files" >&5if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then  echo $ac_n "(cached) $ac_c" 1>&6else  cat > conftest.$ac_ext <<EOF#line 2026 "configure"#include "confdefs.h"#include <stdlib.h>#include <stdarg.h>#include <string.h>#include <float.h>EOFac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"{ (eval echo configure:2034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`if test -z "$ac_err"; then  rm -rf conftest*  ac_cv_header_stdc=yeselse  echo "$ac_err" >&5  echo "configure: failed program was:" >&5  cat conftest.$ac_ext >&5  rm -rf conftest*  ac_cv_header_stdc=nofirm -f conftest*if test $ac_cv_header_stdc = yes; then  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.cat > conftest.$ac_ext <<EOF#line 2051 "configure"#include "confdefs.h"#include <string.h>EOFif (eval "$ac_cpp conftest.$ac_ext") 2>&5 |  egrep "

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -