diff configure.in @ 261:405dd6d1825b r20-5b29

Import from CVS: tag r20-5b29
author cvs
date Mon, 13 Aug 2007 10:23:51 +0200
parents 11cf20601dec
children 727739f917cb
line wrap: on
line diff
--- a/configure.in	Mon Aug 13 10:23:05 2007 +0200
+++ b/configure.in	Mon Aug 13 10:23:51 2007 +0200
@@ -354,6 +354,7 @@
 with_minimal_tagbits='no'
 rel_alloc='default'
 with_system_malloc='default'
+with_dlmalloc='default'
 native_sound_lib=''
 dnl use-assertions should be 'yes' by default.  Too many people in this
 dnl world have core dumps turned off by default or \"cannot find where the
@@ -533,6 +534,7 @@
 
 	dnl Options that take "yes", "no", or "default" values
 	rel_alloc | \
+	with_dlmalloc | \
 	with_debug_malloc  | use_debug_malloc | \
 	with_system_malloc | use_system_malloc )
 	  case "$val" in
@@ -1453,10 +1455,11 @@
   XE_ADD_OBJS(filelock.o)
 fi
 
-if test "$with_shlib" = "yes"; then
-  AC_DEFINE(HAVE_SHLIB)
-  XE_ADD_OBJS(dlopen.o)
-fi
+dnl Autodetected below
+dnl if test "$with_shlib" = "yes"; then
+dnl   AC_DEFINE(HAVE_SHLIB)
+dnl   XE_ADD_OBJS(dlopen.o)
+dnl fi
 
 dnl Choose a compiler from (in order)
 dnl --compiler, env var CC, with_gcc=no && ${NON_GNU_CC:-cc}, AC_PROG_CC
@@ -1922,7 +1925,11 @@
 dnl Do the opsystem or machine files prohibit the use of the GNU malloc?
 dnl Assume not, until told otherwise.
 GNU_MALLOC=yes
-doug_lea_malloc=yes
+if test "$with_dlmalloc" != "no"; then
+	doug_lea_malloc=yes
+else
+	doug_lea_malloc=no
+fi
 after_morecore_hook_exists=yes
 AC_CHECK_FUNC(malloc_get_state, ,doug_lea_malloc=no)
 AC_CHECK_FUNC(malloc_set_state, ,doug_lea_malloc=no)
@@ -2421,10 +2428,10 @@
   AC_DEFINE(HAVE_NS_LDAP)
   XE_PREPEND(-lldap10, LIBS)
   XE_ADD_OBJS(eldap.o)
-dnl else
-dnl   AC_DEFINE(HAVE_LDAP)
-dnl   XE_PREPEND(-lldap, LIBS)
-dnl   XE_ADD_OBJS(eldap.o)
+elif test "$with_ldap" = "yes" ; then
+  AC_DEFINE(HAVE_LDAP)
+  XE_PREPEND(-lldap, LIBS)
+  XE_ADD_OBJS(eldap.o)
 fi
 
 dnl ----------------------
@@ -3215,6 +3222,23 @@
   XE_PREPEND(-Bstatic -lut -Bdynamic, LIBS)
 fi
 
+dnl autodetect dll support
+test -z "$with_shlib" && { AC_CHECK_HEADER(dlfcn.h, ,with_shlib=no) }
+test -z "$with_shlib" && { AC_CHECK_LIB(dl, dlopen,[:],with_shlib=no) }
+test -z "$with_shlib" && with_shlib=yes
+if test "$with_shlib" = "yes"; then
+  AC_DEFINE(HAVE_SHLIB)
+  XE_ADD_OBJS(dlopen.o)
+  XE_PREPEND(-ldl, LIBS)
+fi
+
+dnl Process support (hardcoded)
+dnl every system that supports this runs configure, the others don't
+
+dnl We're not ready for this yet.
+dnl AC_DEFINE(HAVE_UNIX_PROCESSES)
+dnl XE_ADD_OBJS(process-unix.o)
+
 dnl --------------------------------
 dnl Compute SUBST-itutable variables
 dnl --------------------------------
@@ -3413,13 +3437,16 @@
 fi
 echo ""
 echo "$0 $quoted_arguments"
-) >> Installation
+) > Installation
+
+xemacs_betaname=""
+test ! -z "${emacs_beta_version}" && xemacs_betaname="-b${emacs_beta_version}"
 
 dnl Start stdout redirection to '| tee -a Installation'
 (
 echo "
 
-Configured for \`$canonical'.
+XEmacs ${emacs_major_version}.${emacs_minor_version}${xemacs_betaname} \"$xemacs_codename\" configured for \`$canonical'.
 
   Where should the build process find the source code?    $srcdir
   What installation prefix should install use?		  $prefix
@@ -3521,6 +3548,7 @@
   athena   ) echo "  Using Athena dialog boxes."    ;;
   athena3d ) echo "  Using Athena-3d dialog boxes." ;;
 esac
+test "$with_shlib" = "yes" && echo "  Compiling in DLL 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."
@@ -3546,9 +3574,14 @@
 fi
 echo ""
 ) | tee -a Installation
-echo "The above configure report is appended to \"Installation\" file."
+dnl echo "The above configure report is appended to \"Installation\" file."
 echo ""
 
+dnl Generate Installation.el
+echo '(setq Installation-string "' > Installation.el
+sed 's/"/\\"/g' Installation >> Installation.el
+echo '")' >> Installation.el
+
 dnl -----------------------------------
 dnl Now generate config.h and Makefiles
 dnl -----------------------------------