Mercurial > hg > xemacs-beta
diff configure @ 430:a5df635868b2 r21-2-23
Import from CVS: tag r21-2-23
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:29:08 +0200 |
parents | 43177a4f3daf |
children | 3a7e78e1142d |
line wrap: on
line diff
--- a/configure Mon Aug 13 11:28:16 2007 +0200 +++ b/configure Mon Aug 13 11:29:08 2007 +0200 @@ -7766,7 +7766,7 @@ lwlib_objs="$lwlib_objs lwlib-Xaw.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"lwlib-Xaw.o\" to \$lwlib_objs"; fi if test "$have_xaw3d"; then - libs_x="-lXaw3d $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXaw3d\" to \$libs_x"; fi + libs_x="-lXaw3d $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXaw3d\" to \$libs_x"; fi else libs_x="-lXaw $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXaw\" to \$libs_x"; fi fi ;; @@ -11842,19 +11842,21 @@ LIBS="-Bstatic -lut -Bdynamic $LIBS" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-Bstatic -lut -Bdynamic\" to \$LIBS"; fi fi -for ac_hdr in dlfcn.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:11850: checking for $ac_hdr" >&5 - -cat > conftest.$ac_ext <<EOF -#line 11853 "configure" -#include "confdefs.h" -#include <$ac_hdr> +if test "$with_modules" != "no"; then + echo "checking for module support" 1>&6 +echo "configure:11848: checking for module support" >&5 + + ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6 +echo "configure:11852: checking for dlfcn.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 11855 "configure" +#include "confdefs.h" +#include <dlfcn.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11858: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:11860: \"$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* @@ -11869,36 +11871,15 @@ rm -f conftest* if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - { test "$extra_verbose" = "yes" && cat << EOF - Defining $ac_tr_hdr -EOF -cat >> confdefs.h <<EOF -#define $ac_tr_hdr 1 -EOF -} - have_dlfcn=yes - { test "$extra_verbose" = "yes" && cat << \EOF - Defining HAVE_DLFCN_H -EOF -cat >> confdefs.h <<\EOF -#define HAVE_DLFCN_H 1 -EOF -} - -else - echo "$ac_t""no" 1>&6 -fi -done - -test -z "$with_modules" && test ! -z "$have_dlfcn" && { + + echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:11897: checking for dlopen in -ldl" >&5 +echo "configure:11878: checking for dlopen in -ldl" >&5 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -ldl " cat > conftest.$ac_ext <<EOF -#line 11902 "configure" +#line 11883 "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 @@ -11909,7 +11890,7 @@ dlopen() ; return 0; } EOF -if { (eval echo configure:11913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11894: \"$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 @@ -11923,38 +11904,28 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then echo "$ac_t""yes" 1>&6 - { test "$extra_verbose" = "yes" && cat << \EOF - Defining HAVE_DLOPEN -EOF -cat >> confdefs.h <<\EOF -#define HAVE_DLOPEN 1 -EOF -} - DLL_LIB=dl; with_modules=yes -else - echo "$ac_t""no" 1>&6 -fi - - } -test -z "$with_modules" && test ! -z "$have_dlfcn" && { -echo $ac_n "checking for _dlopen in -lc""... $ac_c" 1>&6 -echo "configure:11942: checking for _dlopen in -lc" >&5 -ac_lib_var=`echo c'_'_dlopen | sed 'y%./+-%__p_%'` + have_dl=yes libdl=dl +else + echo "$ac_t""no" 1>&6 + +echo $ac_n "checking for dlopen in -lc""... $ac_c" 1>&6 +echo "configure:11913: checking for dlopen in -lc" >&5 +ac_lib_var=`echo c'_'dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <<EOF -#line 11947 "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 _dlopen(); - -int main() { -_dlopen() -; return 0; } -EOF -if { (eval echo configure:11958: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +#line 11918 "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 dlopen(); + +int main() { +dlopen() +; return 0; } +EOF +if { (eval echo configure:11929: \"$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 @@ -11968,38 +11939,48 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then echo "$ac_t""yes" 1>&6 - { test "$extra_verbose" = "yes" && cat << \EOF + have_dl=yes +else + echo "$ac_t""no" 1>&6 +fi + + +fi + + +else + echo "$ac_t""no" 1>&6 +fi + + if test -n "$have_dl"; then + { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_DLOPEN EOF cat >> confdefs.h <<\EOF #define HAVE_DLOPEN 1 EOF } - DLL_LIB=; with_modules=yes -else - echo "$ac_t""no" 1>&6 -fi - - } -test -z "$with_modules" && test ! -z "$have_dlfcn" && { -echo $ac_n "checking for dlopen in -lc""... $ac_c" 1>&6 -echo "configure:11987: checking for dlopen in -lc" >&5 -ac_lib_var=`echo c'_'dlopen | sed 'y%./+-%__p_%'` - -xe_check_libs=" -lc " -cat > conftest.$ac_ext <<EOF -#line 11992 "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 dlopen(); - -int main() { -dlopen() -; return 0; } -EOF -if { (eval echo configure:12003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + + else + +echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 +echo "configure:11968: checking for shl_load in -ldld" >&5 +ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` + +xe_check_libs=" -ldld " +cat > conftest.$ac_ext <<EOF +#line 11973 "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 shl_load(); + +int main() { +shl_load() +; return 0; } +EOF +if { (eval echo configure:11984: \"$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 @@ -12013,38 +11994,36 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then echo "$ac_t""yes" 1>&6 - { test "$extra_verbose" = "yes" && cat << \EOF - Defining HAVE_DLOPEN -EOF -cat >> confdefs.h <<\EOF -#define HAVE_DLOPEN 1 -EOF -} - DLL_LIB=; with_modules=yes -else - echo "$ac_t""no" 1>&6 -fi - - } -test -z "$with_modules" && { -echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "configure:12032: checking for shl_load in -ldld" >&5 -ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` + libdl=dld have_dl=yes; + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_SHL_LOAD +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SHL_LOAD 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 + +echo $ac_n "checking for dld_init in -ldld""... $ac_c" 1>&6 +echo "configure:12011: checking for dld_init in -ldld" >&5 +ac_lib_var=`echo dld'_'dld_init | sed 'y%./+-%__p_%'` xe_check_libs=" -ldld " cat > conftest.$ac_ext <<EOF -#line 12037 "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 shl_load(); - -int main() { -shl_load() -; return 0; } -EOF -if { (eval echo configure:12048: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +#line 12016 "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 dld_init(); + +int main() { +dld_init() +; return 0; } +EOF +if { (eval echo configure:12027: \"$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 @@ -12058,66 +12037,27 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then echo "$ac_t""yes" 1>&6 - { test "$extra_verbose" = "yes" && cat << \EOF - Defining HAVE_SHL_LOAD -EOF -cat >> confdefs.h <<\EOF -#define HAVE_SHL_LOAD 1 -EOF -} - DLL_LIB=dld; with_modules=yes -else - echo "$ac_t""no" 1>&6 -fi - - } -test -z "$with_modules" && { -echo $ac_n "checking for dld_init in -ldld""... $ac_c" 1>&6 -echo "configure:12077: checking for dld_init in -ldld" >&5 -ac_lib_var=`echo dld'_'dld_init | sed 'y%./+-%__p_%'` - -xe_check_libs=" -ldld " -cat > conftest.$ac_ext <<EOF -#line 12082 "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 dld_init(); - -int main() { -dld_init() -; return 0; } -EOF -if { (eval echo configure:12093: \"$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" -fi -rm -f conftest* -xe_check_libs="" - -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then - echo "$ac_t""yes" 1>&6 - { test "$extra_verbose" = "yes" && cat << \EOF + libdl=dld have_dl=yes; + { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_DLD_INIT EOF cat >> confdefs.h <<\EOF #define HAVE_DLD_INIT 1 EOF } - DLL_LIB=dld; with_modules=yes -else - echo "$ac_t""no" 1>&6 -fi - - } -if test "$with_modules" = "yes"; then - + +else + echo "$ac_t""no" 1>&6 +fi + + +fi + + + fi + + if test -n "$have_dl"; then + dll_ld= dll_ldflags= dll_cflags= @@ -12128,7 +12068,7 @@ xealias=$internal_configuration echo "checking how to build dynamic libraries for ${xehost}" 1>&6 -echo "configure:12132: checking how to build dynamic libraries for ${xehost}" >&5 +echo "configure:12072: checking how to build dynamic libraries for ${xehost}" >&5 # Transform *-*-linux* to *-*-linux-gnu*, to support old configure scripts. case "$xehost" in *-*-linux-gnu*) ;; @@ -12156,9 +12096,9 @@ XEGCC=yes else echo $ac_n "checking checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:12160: checking checking whether we are using GNU C" >&5 +echo "configure:12100: checking checking whether we are using GNU C" >&5 cat > conftest.$ac_ext <<EOF -#line 12162 "configure" +#line 12102 "configure" #include "confdefs.h" #ifdef __GNUC__ @@ -12180,7 +12120,7 @@ fi echo $ac_n "checking how to produce PIC code""... $ac_c" 1>&6 -echo "configure:12184: checking how to produce PIC code" >&5 +echo "configure:12124: checking how to produce PIC code" >&5 wl= can_build_shared=yes @@ -12208,7 +12148,7 @@ else # PORTME Check for PIC flags for the system compiler. case "$xehost_os" in - hpux9* | hpux10*) + hpux9* | hpux1[0-9]*) # Is there a better link_static_flag that works with the bundled CC? wl='-Wl,' dll_cflags='+Z' @@ -12273,18 +12213,18 @@ # Check to make sure the dll_cflags actually works. echo $ac_n "checking if PIC flag ${dll_cflags} really works""... $ac_c" 1>&6 -echo "configure:12277: checking if PIC flag ${dll_cflags} really works" >&5 +echo "configure:12217: checking if PIC flag ${dll_cflags} really works" >&5 save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $dll_cflags -DPIC" cat > conftest.$ac_ext <<EOF -#line 12281 "configure" +#line 12221 "configure" #include "confdefs.h" int main() { int x=0; ; return 0; } EOF -if { (eval echo configure:12288: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:12228: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # On HP-UX, the stripped-down bundled CC doesn't accept +Z, but also @@ -12315,7 +12255,7 @@ xldf= xcldf= echo $ac_n "checking if C compiler can produce shared libraries""... $ac_c" 1>&6 -echo "configure:12319: checking if C compiler can produce shared libraries" >&5 +echo "configure:12259: checking if C compiler can produce shared libraries" >&5 if test "$XEGCC" = yes; then xcldf="-shared" xldf="-shared" @@ -12366,14 +12306,14 @@ xe_libs= ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cat > conftest.$ac_ext <<EOF -#line 12370 "configure" +#line 12310 "configure" #include "confdefs.h" int main() { int x=0; ; return 0; } EOF -if { (eval echo configure:12377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:12317: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* cc_produces_so=yes else @@ -12398,7 +12338,7 @@ if test "$XEGCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6 -echo "configure:12402: checking for ld used by GCC" >&5 +echo "configure:12342: checking for ld used by GCC" >&5 ac_prog=`($CC -print-prog-name=ld) 2>&5` case "$ac_prog" in # Accept absolute paths. @@ -12423,7 +12363,7 @@ esac else echo $ac_n "checking for GNU ld""... $ac_c" 1>&6 -echo "configure:12427: checking for GNU ld" >&5 +echo "configure:12367: checking for GNU ld" >&5 fi if test -z "$LTLD"; then @@ -12461,7 +12401,7 @@ # Check to see if it really is or isn't GNU ld. echo $ac_n "checking if the linker is GNU ld""... $ac_c" 1>&6 -echo "configure:12465: checking if the linker is GNU ld" >&5 +echo "configure:12405: checking if the linker is GNU ld" >&5 # I'd rather use --version here, but apparently some GNU ld's only accept -v. if $LTLD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then xe_gnu_ld=yes @@ -12488,7 +12428,7 @@ # OK - only NOW do we futz about with ld. # See if the linker supports building shared libraries. echo $ac_n "checking whether the linker supports shared libraries""... $ac_c" 1>&6 -echo "configure:12492: checking whether the linker supports shared libraries" >&5 +echo "configure:12432: checking whether the linker supports shared libraries" >&5 dll_ld=$CC dll_ldflags=$LDFLAGS ld_shlibs=yes @@ -12684,6 +12624,8 @@ + fi + if test "$can_build_shared" = "yes"; then { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_SHLIB @@ -12693,21 +12635,18 @@ EOF } - extra_objs="$extra_objs sysdll.o" && if test "$extra_verbose" = "yes"; then - echo " xemacs will be linked with \"sysdll.o\"" - fi - extra_objs="$extra_objs emodules.o" && if test "$extra_verbose" = "yes"; then - echo " xemacs will be linked with \"emodules.o\"" + extra_objs="$extra_objs sysdll.o emodules.o" && if test "$extra_verbose" = "yes"; then + echo " xemacs will be linked with \"sysdll.o emodules.o\"" fi INSTALL_ARCH_DEP_SUBDIR="$INSTALL_ARCH_DEP_SUBDIR src" && if test "$extra_verbose" = "yes"; then echo " Appending \"src\" to \$INSTALL_ARCH_DEP_SUBDIR"; fi - test ! -z "$DLL_LIB" && LIBS="-l${DLL_LIB} $LIBS" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-l${DLL_LIB}\" to \$LIBS"; fi + test -n "$libdl" && LIBS="-l${libdl} $LIBS" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-l${libdl}\" to \$LIBS"; fi for ac_func in dlerror _dlerror do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:12708: checking for $ac_func" >&5 - -cat > conftest.$ac_ext <<EOF -#line 12711 "configure" +echo "configure:12647: checking for $ac_func" >&5 + +cat > conftest.$ac_ext <<EOF +#line 12650 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -12730,7 +12669,7 @@ ; return 0; } EOF -if { (eval echo configure:12734: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:12673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -12757,18 +12696,23 @@ fi done + with_modules=yes else - echo "configure: warning: disabling shared library support" 1>&2 + if test "$with_modules" = "yes"; then + { echo "Error:" "Required module support cannot be provided." >&2; exit 1; } + else + echo "configure: warning: "Module support cannot be provided."" 1>&2 + fi with_modules=no fi fi cat > conftest.$ac_ext <<EOF -#line 12768 "configure" +#line 12712 "configure" #include "confdefs.h" int main(int c,char *v[]){return 0;} EOF -if { (eval echo configure:12772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:12716: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -13365,7 +13309,7 @@ xemacs_betaname="-b${emacs_beta_version}" fi else - xemacs_betaname="" + xemacs_betaname="" fi ( @@ -13435,7 +13379,7 @@ test "$with_tiff" = yes && echo " Compiling in support for TIFF image handling." test "$with_xface" = yes && echo " Compiling in support for X-Face message headers." test "$with_native_sound" = yes && echo " Compiling in native sound support." -test "$with_nas_sound" = yes && echo " Compiling in network sound (NAS) support." +test "$with_nas_sound" = yes && echo " Compiling in network sound (NAS) support." test "$old_nas" = yes && echo " nas library lacks error trapping, will play synchronously." test "$with_esd" = yes && echo " Compiling in support for Enlightened Sound Daemon." @@ -13502,7 +13446,7 @@ athena3d ) echo " Using Athena-3d dialog boxes." ;; msw ) echo " Using MS-Windows dialog boxes." ;; esac -test "$with_modules" = "yes" && echo " Compiling in DSO module support." +test "$with_modules" = "yes" && echo " Compiling in dynamic shared object module support." test "$with_clash_detection" = yes && \ echo " Clash detection will use \"$lockdir\" for locking files." echo " movemail will use \"$mail_locking\" for locking mail spool files." @@ -13536,12 +13480,10 @@ for file in $internal_makefile_list; do test "$file" = src/Makefile.in && \ file="src/Makefile.in:src/Makefile.in.in:src/depend" - ac_output_files="${ac_output_files+$ac_output_files }$file" + ac_output_files="$ac_output_files $file" && if test "$extra_verbose" = "yes"; then echo " Appending \"$file\" to \$ac_output_files"; fi done ac_output_files="$ac_output_files src/paths.h lib-src/config.values" -if test "$with_modules" = "yes"; then - ac_output_files="$ac_output_files lib-src/ellcc.h" -fi +test "$with_modules" = "yes" && ac_output_files="$ac_output_files lib-src/ellcc.h" && if test "$extra_verbose" = "yes"; then echo " Appending \"lib-src/ellcc.h\" to \$ac_output_files"; fi trap '' 1 2 15