X-Git-Url: http://git.chise.org/gitweb/?p=chise%2Fxemacs-chise.git.1;a=blobdiff_plain;f=configure.in;h=bdfc9108fed471c994ea906ce2e285336a4dd142;hp=f5b12f88efaa6e438643e08e4df3721384cb5b82;hb=4325dbbcdcdb80daba5f060ef4bb5c19a6beafe3;hpb=d8654f7c5ad0c04060008c6fbbd90add1f4537e3 diff --git a/configure.in b/configure.in index f5b12f8..bdfc910 100644 --- a/configure.in +++ b/configure.in @@ -375,7 +375,8 @@ with_toolbars="" with_tty="" use_union_type="no" with_dnet="" -pdump="no" +dnl pdump now defaults by opsys +pdump='' dnl dragndrop is still experimental. When it is stable, comment out the following line: with_dragndrop="no" dnl Too annoying, even if mandated by IPv6 (and I'm not even sure of that) @@ -491,6 +492,9 @@ while test $# != 0; do with_xfs | \ with_i18n3 | \ with_mule | \ + with_utf_2000 | \ + with_chise | \ + with_text_coding| \ with_file_coding| \ with_canna | \ with_wnn | \ @@ -1218,7 +1222,6 @@ case "$canonical" in *-*-darwin*) opsys=darwin RANLIB="ranlib -c" dnl Avoids a link error with lwlib-config.c - pdump=yes dnl No "native" working dumper available ;; dnl Data General AViiON Machines @@ -1573,6 +1576,17 @@ else echo "Using configure-time autodetection only." fi +dnl -------------------------------------------------------------- +dnl $opsys detection complete; defaults depending on $opsys follow +dnl -------------------------------------------------------------- + +if test -z "$pdump"; then + case "$opsys" in + linux* ) pdump=yes ;; dnl glibc 2.3.1 seems to hose unexec + *-*-darwin* ) pdump=yes ;; dnl No "native" working dumper available + *) pdump=no ;; + esac +fi if test -z "$dynamic"; then case "$opsys" in @@ -2002,6 +2016,21 @@ esac AC_MSG_RESULT(no) fi +dnl GNU ld now defaults to combreloc, which screws up unexec, but not pdump. +dnl Note that it's OK if the GNU style long option causes non-GNU ld to barf +dnl a usage message, that's often good enough. Please report it, though. +dnl #### Should make this Solaris-friendly. +dnl Link with -z nocombreloc for now. +if test "$pdump" != "yes"; then + AC_MSG_CHECKING(for \"-z nocombreloc\" linker flag) + case "`ld --help 2>&1`" in + *-z\ nocombreloc* ) AC_MSG_RESULT(yes) + XE_PREPEND(-z nocombreloc, ld_switch_site) ;; + *) AC_MSG_RESULT(no) ;; + esac +fi + + dnl Inform compiler that certain flags are meant for the linker dnl XE_PROTECT_LINKER_FLAGS(shell_var) define([XE_PROTECT_LINKER_FLAGS], [ @@ -2019,6 +2048,7 @@ if test "$GCC" = "yes"; then fi])dnl XE_PROTECT_LINKER_FLAGS(ld_switch_system) XE_PROTECT_LINKER_FLAGS(ld_switch_machine) +XE_PROTECT_LINKER_FLAGS(ld_switch_site) XE_PROTECT_LINKER_FLAGS(LDFLAGS) XE_PROTECT_LINKER_FLAGS(ld_call_shared) @@ -2403,10 +2433,12 @@ AC_CHECK_TYPE(ssize_t, int) dnl check for Unix98 socklen_t AC_MSG_CHECKING(for socklen_t) -AC_TRY_COMPILE([#include +AC_TRY_COMPILE([#include +#include socklen_t x; ],[],[AC_MSG_RESULT(yes)],[ -AC_TRY_COMPILE([#include +AC_TRY_COMPILE([#include +#include int accept (int, struct sockaddr *, size_t *); ],[],[ AC_MSG_RESULT(size_t) @@ -2529,20 +2561,6 @@ if test "$opsys" = "sol2"; then fi fi -dnl GNU ld now defaults to combreloc, which screws up unexec, but not pdump. -dnl Note that it's OK if the GNU style long option causes non-GNU ld to barf -dnl a usage message, that's often good enough. Please report it, though. -dnl #### Should make this Solaris-friendly. -dnl Link with -z nocombreloc for now. -if test "$pdump" != "yes"; then - AC_MSG_CHECKING(for \"-z nocombreloc\" linker flag) - case "`ld --help 2>&1`" in - *-z\ nocombreloc* ) AC_MSG_RESULT(yes) - XE_PREPEND(-z nocombreloc, ld_switch_site) ;; - *) AC_MSG_RESULT(no) ;; - esac -fi - dnl ---------------------- dnl Choose a window system dnl ---------------------- @@ -2921,7 +2939,7 @@ if test "$with_msw" != "no"; then fi install_pp="$blddir/lib-src/installexe.sh" - XE_APPEND(-lshell32 -lgdi32 -luser32 -lcomdlg32 -lcomctl32 -lwinspool, libs_system) + XE_APPEND(-lshell32 -lgdi32 -luser32 -lcomdlg32 -lcomctl32 -lkernel32 -lwinspool, libs_system) test "$with_dragndrop" != no && XE_APPEND(msw, dragndrop_proto) if test "$window_system" != x11; then window_system=msw @@ -3676,16 +3694,59 @@ if test "$with_file_coding" = "yes" && test "$with_mule" = "no"; then XE_ADD_OBJS(file-coding.o) fi +test -z "$with_chise" && with_chise=yes +if test "$with_chise" = "yes"; then + with_mule=yes + with_utf_2000=yes + with_text_coding=yes +fi + if test "$with_mule" = "yes" ; then AC_CHECKING(for Mule-related features) AC_DEFINE(MULE) - AC_DEFINE(FILE_CODING) - XE_ADD_OBJS(mule.o mule-ccl.o mule-charset.o file-coding.o) + dnl Autodetect chise + chise_includes_found=no + if test "$with_chise" != "no"; then + AC_CHECK_HEADER(chise.h, ,with_chise=no) + fi + if test "$chise_includes_found" = "no" -a "$with_chise" != "no" -a \ + -d "/usr/local/chise/include"; then + save_c_switch_site="$c_switch_site" + c_switch_site="$c_switch_site -I/usr/local/chise/include" + AC_CHECK_HEADER(chise.h,chise_includes_found=yes) + if test "$chise_includes_found" != "yes"; then + c_switch_site="$save_c_switch_site" + with_chise="no" + fi + fi + + test -z "$with_chise" && with_chise=yes + if test "$with_chise" = "yes"; then + AC_DEFINE(HAVE_CHISE) + AC_DEFINE(HAVE_LIBCHISE) + XE_PREPEND(-lchise, libs_x) + fi + + AC_DEFINE(FILE_CODING) + XE_ADD_OBJS(mule.o mule-ccl.o mule-charset.o) + if test "$with_utf_2000" = "yes" && test "$with_text_coding" = "yes"; then + AC_DEFINE(TEXT_CODING) + XE_ADD_OBJS(text-coding.o) + else + XE_ADD_OBJS(file-coding.o) + fi dnl Use -lintl to get internationalized strerror for Mule AC_CHECK_HEADERS(libintl.h) AC_CHECK_LIB(intl, strerror) + if test "$with_utf_2000" = "yes" ; then + AC_DEFINE(CHAR_IS_UCS4) + AC_DEFINE(UTF2000) + with_wnn=no + with_wnn6=no + fi + AC_CHECKING(for Mule input methods) dnl Do we have the XmIm* routines? And if so, do we want to use them? dnl XIM seems to be flaky except on Solaris... @@ -3798,8 +3859,22 @@ if test "$need_motif" = "yes" ; then XE_COMPUTE_RUNPATH() fi +dnl ---------------------------------------------------------------- +dnl Check for POSIX functions. +dnl ---------------------------------------------------------------- + AC_CHECK_FUNCS(cbrt closedir dup2 eaccess fmod fpathconf frexp ftime getaddrinfo gethostname getnameinfo getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf stpcpy strerror tzset ulimit usleep waitpid vsnprintf fsync ftruncate umask) +dnl getaddrinfo() is borked under hpux11 +if test "$ac_cv_func_getaddrinfo" != "no" ; then + case "$opsys" in + hpux11* ) + AC_MSG_WARN([Use of getaddrinfo is disabled for HP-UX 11.XX.]) + ac_cv_func_getaddrinfo=no + ;; + esac +fi + dnl ---------------------------------------------------------------- dnl Check for PTY support functions. dnl ---------------------------------------------------------------- @@ -4250,7 +4325,14 @@ if test "$with_tty" = "yes" ; then done fi else dnl "$have_terminfo" = "no" && "with_ncurses" = "no" - XE_ADD_OBJS(tparam.o) + if test -n "$libs_termcap" -a "$opsys" = "openbsd"; then + dnl We need to check if tgoto does not exist in termcap yet + dnl because on OpenBSD libtermcap is another name for libcurses + dnl which provides the same tgoto as ncurses + AC_CHECK_LIB(termcap, tgoto, , XE_ADD_OBJS(tparam.o)) + else + XE_ADD_OBJS(tparam.o) + fi dnl The HP-UX curses library seems to have a badly broken version of select(2) dnl that makes "poll: interrupted system call" messages to appear and dnl Emacs subprocesses to hang (e.g. TeX compilation w/ AUCTeX) */ @@ -4389,6 +4471,9 @@ if test "$with_database_gdbm $with_database_dbm $with_database_berkdb" \ != "no no no"; then AC_DEFINE(HAVE_DATABASE) XE_ADD_OBJS(database.o) + if test "$with_utf_2000" = "yes" -a "$with_chise" != "yes" ; then + AC_DEFINE(HAVE_CHISE) + fi fi dnl Socks support @@ -4463,19 +4548,25 @@ dnl executables to fail to run. Also any tests using AC_TRY_RUN will dnl have reported incorrect results. AC_TRY_RUN([int main(int c,char *v[]){return 0;}],[:],[ echo "" - echo "*** PANIC *** The C compiler can no longer build working executables." - echo "*** PANIC *** Please examine the tail of config.log for runtime errors." - echo "*** PANIC *** The most likely reason for this problem is that configure" - echo "*** PANIC *** links with shared libraries, but those libraries cannot be" - echo "*** PANIC *** found at run time." - echo "*** PANIC ***" - echo "*** PANIC *** On a Linux system, edit /etc/ld.so.conf and re-run ldconfig." - echo "*** PANIC *** On other systems, try telling configure where to find the" - echo "*** PANIC *** shared libraries using the --site-runtime-libraries option" - echo "*** PANIC ***" - echo "*** PANIC *** Another way to shoot yourself in the foot is to specify" - echo "*** PANIC *** --with-FEATURE when FEATURE is not actually installed" - echo "*** PANIC *** on your system. Don't do that." + echo "*** PANIC *** configure forgot how to build working executables!" + echo "" + echo "*** This is most commonly due to an unforeseen environment, causing" + echo "*** configure to incorrectly compute the sequence of libraries to link." + echo "*** Please examine the tail of config.log for runtime errors." + echo "*** Pay special attention to the -l flags, and perhaps -I and -L." + echo "*** Often adding or removing explicit options in the configure" + echo "*** invocation can work around this kind of problem. If so, please" + echo "*** report it as a bug to xemacs-beta@xemacs.org." + echo "***" + echo "*** Other possible causes are inability to write to the file system" + echo "*** (bogus permissions or disk full) or a misconfiguration of the dynamic" + echo "*** linker. On Linux, check /etc/ld.conf and rerun ldconfig if" + echo "*** necessary. On other systems, try telling configure where to find" + echo "*** the shared libraries using the --site-runtime-libraries option." + echo "***" + echo "*** Another way to shoot yourself in the foot is to specify" + echo "*** --with-FEATURE when FEATURE is not actually installed on your" + echo "*** system. Don't do that." exit 1]) dnl Process support @@ -5004,8 +5095,11 @@ if test "$with_postgresql" = yes; then fi echo " -Internationalization:" +Multiscriptization / Multilingualization / Internationalization:" test "$with_mule" = yes && echo " Compiling in support for Mule (multi-lingual Emacs)." +test "$with_chise" = yes && echo " Using CHISE (CHaracter Information Service Environment) support." +test "$with_utf_2000" = yes && echo " Using UTF-2000 (UTF-8) buffer/string representation." +test "$with_text_coding" = yes && echo " Compiling in support for text coding." test "$with_file_coding" = yes && echo " Compiling in support for file coding." test "$with_xim" != no && echo " Compiling in support for XIM (X11R5+ I18N input method)." test "$with_xim" = motif && echo " - Using Motif to provide XIM support." @@ -5033,7 +5127,13 @@ test "$with_workshop" = yes && echo " Compiling in support for Sun WorkShop." test "$with_socks" = yes && echo " Compiling in support for SOCKS." test "$with_dnet" = yes && echo " Compiling in support for DNET." test "$with_modules" = "yes" && echo " Compiling in support for dynamic shared object modules." -test "$use_union_type" = yes && echo " Using the union type for Lisp_Objects." +if test "$use_union_type" = yes; then + echo " WARNING: ---------------------------------------------------------" + echo " Using the union type for Lisp_Objects." + echo " Union type has been implicated in hard-to-debug runtime crashes." + echo " Do NOT use this build of XEmacs for ordinary work. See PROBLEMS." + echo " WARNING: ---------------------------------------------------------" +fi test "$pdump" = yes && echo " Using the new portable dumper." test "$debug" = yes && echo " Compiling in support for extra debugging code." test "$usage_tracking" = yes && echo " Compiling in support for active usage tracking (Sun internal)."