Mercurial > hg > xemacs-beta
comparison configure.in @ 426:43177a4f3daf r21-2-21
Import from CVS: tag r21-2-21
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:27:01 +0200 |
parents | 11054d720c21 |
children | a5df635868b2 |
comparison
equal
deleted
inserted
replaced
425:22157a68eca2 | 426:43177a4f3daf |
---|---|
580 | 580 |
581 dnl Has the user requested database support? | 581 dnl Has the user requested database support? |
582 "with_database" ) | 582 "with_database" ) |
583 with_database_berkdb=no | 583 with_database_berkdb=no |
584 with_database_dbm=no | 584 with_database_dbm=no |
585 with_database_gnudbm=no | 585 with_database_gdbm=no |
586 for x in `echo "$val" | sed -e 's/,/ /g'` ; do | 586 for x in `echo "$val" | sed -e 's/,/ /g'` ; do |
587 case "$x" in | 587 case "$x" in |
588 no ) ;; | 588 no ) ;; |
589 b | be | ber | berk | berkd | berkdb ) with_database_berkdb=yes ;; | 589 b | be | ber | berk | berkd | berkdb ) with_database_berkdb=yes ;; |
590 d | db | dbm ) with_database_dbm=yes ;; | 590 d | db | dbm ) with_database_dbm=yes ;; |
591 g | gn | gnu | gnud | gnudb | gnudbm ) with_database_gnudbm=yes ;; | 591 g | gn | gnu | gnud | gnudb | gnudbm | gdbm) with_database_gdbm=yes ;; |
592 * ) USAGE_ERROR(["The \`--$optname' option value | 592 * ) USAGE_ERROR(["The \`--$optname' option value |
593 must be either \`no' or a comma-separated list | 593 must be either \`no' or a comma-separated list |
594 of one or more of \`berkdb' and either \`dbm' or \`gnudbm'."]) ;; | 594 of one or more of \`berkdb' and either \`dbm' or \`gnudbm'."]) ;; |
595 esac | 595 esac |
596 done | 596 done |
597 if test "$with_database_dbm" = "yes" -a \ | 597 if test "$with_database_dbm" = "yes" -a \ |
598 "$with_database_gnudbm" = "yes"; then | 598 "$with_database_gdbm" = "yes"; then |
599 USAGE_ERROR("Only one of \`dbm' and \`gnudbm' may be specified | 599 USAGE_ERROR("Only one of \`dbm' and \`gnudbm' may be specified |
600 with the \`--$optname' option.") | 600 with the \`--$optname' option.") |
601 fi | 601 fi |
602 ;; | 602 ;; |
603 | 603 |
604 dnl Has the user requested sound support? | 604 dnl Has the user requested sound support? |
605 "with_sound" ) | 605 "with_sound" ) |
606 dnl value can be native, nas or both. yes is allowed | 606 dnl values is a subset of all,native,nas,esd |
607 dnl as a backwards compatible synonym for native | 607 dnl or their negatives: none,nonative,nonas,noesd |
608 case "$val" in | 608 for x in `echo "$val" | sed -e 's/,/ /g'` ; do |
609 y | ye | yes ) val=native ;; | 609 case "$x" in |
610 n | no | non | none ) val=no;; | 610 dnl all and none are only permitted as the first in the list. |
611 na | nat | nati | nativ | native ) val=native ;; | 611 n | no | non | none ) new_sdefault=no ;; |
612 ne | net | neta | netau | netaud | netaudi | netaudio | nas ) val=nas ;; | 612 a | al | all | both ) new_sdefault=yes ;; |
613 b | bo | bot | both ) val=both;; | 613 |
614 * ) USAGE_ERROR(["The \`--$optname' option must have one of these values: | 614 native ) with_native_sound=yes ;; |
615 \`native', \`nas', \`both', or \`none'."]) ;; | 615 nonative ) with_native_sound=no ;; |
616 esac | 616 |
617 eval "$opt=\"$val\"" | 617 nas ) with_nas_sound=yes ;; |
618 nonas ) with_nas_sound=no ;; | |
619 | |
620 esd ) with_esd=yes ;; | |
621 noesd ) with_esh=no ;; | |
622 | |
623 * ) bogus_sound=yes ;; | |
624 esac | |
625 if test "$bogus_sound" -o \ | |
626 \( -n "$new_sdefault" -a -n "$sound_notfirst" \) ; then | |
627 types="\`all', \`none', \`(no)native', \`no(nas)', \`(no)esd'." | |
628 USAGE_ERROR(["Valid types for the \`--$optname' option are: | |
629 $types. | |
630 The default is native,esd."]) | |
631 elif test -n "$new_sdefault" ; then | |
632 with_native_sound=$new_sdefault | |
633 with_nas_sound=$new_sdefault | |
634 with_esd=$new_sdefault | |
635 new_sdefault= # reset this | |
636 fi | |
637 sound_notfirst=true | |
638 done | |
618 ;; | 639 ;; |
619 | 640 |
620 dnl Has the user requested XIM support? | 641 dnl Has the user requested XIM support? |
621 "with_xim" ) | 642 "with_xim" ) |
622 case "$val" in | 643 case "$val" in |
2156 AC_TYPE_SIZE_T | 2177 AC_TYPE_SIZE_T |
2157 AC_TYPE_PID_T | 2178 AC_TYPE_PID_T |
2158 AC_TYPE_UID_T | 2179 AC_TYPE_UID_T |
2159 AC_TYPE_MODE_T | 2180 AC_TYPE_MODE_T |
2160 AC_TYPE_OFF_T | 2181 AC_TYPE_OFF_T |
2182 AC_CHECK_TYPE(ssize_t, int) | |
2161 | 2183 |
2162 AC_MSG_CHECKING(for struct timeval) | 2184 AC_MSG_CHECKING(for struct timeval) |
2163 AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME | 2185 AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME |
2164 #include <sys/time.h> | 2186 #include <sys/time.h> |
2165 #include <time.h> | 2187 #include <time.h> |
2985 test "$with_scrollbars" != "no" && XE_ADD_OBJS(scrollbar-x.o) | 3007 test "$with_scrollbars" != "no" && XE_ADD_OBJS(scrollbar-x.o) |
2986 test "$with_dialogs" != "no" && XE_ADD_OBJS(dialog-x.o) | 3008 test "$with_dialogs" != "no" && XE_ADD_OBJS(dialog-x.o) |
2987 test "$with_toolbars" != "no" && XE_ADD_OBJS(toolbar-x.o) | 3009 test "$with_toolbars" != "no" && XE_ADD_OBJS(toolbar-x.o) |
2988 test "$all_widgets" != "no no no no no" && XE_ADD_OBJS(gui-x.o) | 3010 test "$all_widgets" != "no no no no no" && XE_ADD_OBJS(gui-x.o) |
2989 else | 3011 else |
2990 if test \( "$with_sound" = "nas" \) -o \( "$with_sound" = "both" \); then | 3012 if test "$with_nas_sound" = "nas"; then |
2991 echo "Attempt to Build NAS sound without X" | 3013 echo "Attempt to Build NAS sound without X" |
2992 echo "Please remove NAS configuration or build with X" | 3014 echo "Please remove NAS configuration or build with X" |
2993 exit 1 | 3015 exit 1 |
2994 fi | 3016 fi |
2995 fi | 3017 fi |
3374 | 3396 |
3375 dnl Check for sound of various sorts. | 3397 dnl Check for sound of various sorts. |
3376 | 3398 |
3377 dnl Autodetect native sound | 3399 dnl Autodetect native sound |
3378 AC_CHECKING("for sound support") | 3400 AC_CHECKING("for sound support") |
3379 case "$with_sound" in | |
3380 native | both ) with_native_sound=yes;; | |
3381 nas | no ) with_native_sound=no;; | |
3382 esac | |
3383 test -z "$with_native_sound" -a -n "$native_sound_lib" && with_native_sound=yes | 3401 test -z "$with_native_sound" -a -n "$native_sound_lib" && with_native_sound=yes |
3384 | 3402 |
3385 if test "$with_native_sound" != "no"; then | 3403 if test "$with_native_sound" != "no"; then |
3386 dnl Maybe sound is already on include path... | 3404 dnl Maybe sound is already on include path... |
3387 if test -n "$native_sound_lib"; then | 3405 if test -n "$native_sound_lib"; then |
3435 dnl Check for Linux/BSD native sound | 3453 dnl Check for Linux/BSD native sound |
3436 if test -z "$sound_found"; then | 3454 if test -z "$sound_found"; then |
3437 for dir in "machine" "sys" "linux"; do | 3455 for dir in "machine" "sys" "linux"; do |
3438 AC_CHECK_HEADER(${dir}/soundcard.h, | 3456 AC_CHECK_HEADER(${dir}/soundcard.h, |
3439 sound_found=yes | 3457 sound_found=yes |
3458 need_miscplay=yes | |
3440 XE_ADD_OBJS(linuxplay.o) | 3459 XE_ADD_OBJS(linuxplay.o) |
3441 [AC_DEFINE_UNQUOTED(SOUNDCARD_H_PATH, "${dir}/soundcard.h")] | 3460 [AC_DEFINE_UNQUOTED(SOUNDCARD_H_PATH, "${dir}/soundcard.h")] |
3442 break) | 3461 break) |
3443 done | 3462 done |
3444 fi | 3463 fi |
3445 | 3464 |
3446 test "$sound_found" = "yes" && with_native_sound=yes | 3465 test "$sound_found" = "yes" && with_native_sound=yes |
3447 fi | 3466 fi |
3448 | 3467 |
3449 if test -z "$with_sound"; then | |
3450 if test "$with_native_sound" = "yes" -o -n "$native_sound_lib"; then | |
3451 with_sound=native | |
3452 fi | |
3453 fi | |
3454 | |
3455 if test "$with_native_sound" = "yes"; then | 3468 if test "$with_native_sound" = "yes"; then |
3456 AC_DEFINE(HAVE_NATIVE_SOUND) | 3469 AC_DEFINE(HAVE_NATIVE_SOUND) |
3457 test -n "$native_sound_lib" && XE_PREPEND($native_sound_lib, LIBS) | 3470 test -n "$native_sound_lib" && XE_PREPEND($native_sound_lib, LIBS) |
3458 fi | 3471 fi |
3459 | 3472 |
3460 case "$with_sound" in both | nas ) | 3473 if test "$with_nas_sound" = "yes"; then |
3461 AC_DEFINE(HAVE_NAS_SOUND) | 3474 AC_DEFINE(HAVE_NAS_SOUND) |
3462 XE_ADD_OBJS(nas.o) | 3475 XE_ADD_OBJS(nas.o) |
3463 XE_PREPEND(-laudio, libs_x) | 3476 XE_PREPEND(-laudio, libs_x) |
3464 dnl If the nas library does not contain the error jump point, | 3477 dnl If the nas library does not contain the error jump point, |
3465 dnl then we force safer behavior. | 3478 dnl then we force safer behavior. |
3466 AC_EGREP_HEADER(AuXtErrorJump,audio/Xtutil.h,,[AC_DEFINE(NAS_NO_ERROR_JUMP)]) | 3479 AC_EGREP_HEADER(AuXtErrorJump,audio/Xtutil.h,,[AC_DEFINE(NAS_NO_ERROR_JUMP)]) |
3467 esac | 3480 fi |
3481 | |
3482 AC_CHECK_PROG(have_esd_config, esd-config, yes, no) | |
3483 if test -z "$with_esd"; then | |
3484 with_esd=$have_esd_config | |
3485 fi | |
3486 | |
3487 if test "$with_esd" = "yes"; then | |
3488 if test "$have_esd_config" = "no"; then | |
3489 echo "*** esd-config was not found in your PATH. Disabling esd support." | |
3490 with_esd=no | |
3491 else | |
3492 AC_DEFINE(HAVE_ESD_SOUND) | |
3493 need_miscplay=yes | |
3494 XE_ADD_OBJS(esd.o) | |
3495 XE_PREPEND(`esd-config --libs`, libs_x) | |
3496 fi | |
3497 fi | |
3498 | |
3499 if test "$need_miscplay" = "yes"; then | |
3500 XE_ADD_OBJS(miscplay.o) | |
3501 fi | |
3468 | 3502 |
3469 dnl --------------------- | 3503 dnl --------------------- |
3470 dnl TTY-dependent options | 3504 dnl TTY-dependent options |
3471 dnl --------------------- | 3505 dnl --------------------- |
3472 | 3506 |
3553 dnl Database support | 3587 dnl Database support |
3554 dnl We do not necessarily have to have libdb/lib(g)dbm for DB/(G)DBM support. | 3588 dnl We do not necessarily have to have libdb/lib(g)dbm for DB/(G)DBM support. |
3555 dnl On FreeBSD, both DB and DBM are part of libc. | 3589 dnl On FreeBSD, both DB and DBM are part of libc. |
3556 dnl By default, we check for DBM support in libgdbm, then libc, then libdbm. | 3590 dnl By default, we check for DBM support in libgdbm, then libc, then libdbm. |
3557 | 3591 |
3558 test "$with_database_gnudbm $with_database_dbm $with_database_berkdb" \ | 3592 test "$with_database_gdbm $with_database_dbm $with_database_berkdb" \ |
3559 != "no no no" && AC_CHECKING(for database support) | 3593 != "no no no" && AC_CHECKING(for database support) |
3560 | 3594 |
3561 dnl Check for ndbm.h, required for either kind of DBM support. | 3595 dnl Check for ndbm.h, required for either kind of DBM support. |
3562 if test "$with_database_gnudbm $with_database_dbm" != "no no"; then | 3596 if test "$with_database_gdbm $with_database_dbm" != "no no"; then |
3563 AC_CHECK_HEADER(ndbm.h, [:], [ | 3597 AC_CHECK_HEADER(ndbm.h, [:], [ |
3564 test "$with_database_gnudbm" = "yes" -o \ | 3598 test "$with_database_gdbm" = "yes" -o \ |
3565 "$with_database_dbm" = "yes" && \ | 3599 "$with_database_dbm" = "yes" && \ |
3566 XE_DIE("Required DBM support cannot be provided.") | 3600 XE_DIE("Required DBM support cannot be provided.") |
3567 with_database_gnudbm=no with_database_dbm=no]) | 3601 with_database_gdbm=no with_database_dbm=no]) |
3568 fi | 3602 fi |
3569 | 3603 |
3570 dnl Check for DBM support in libgdbm. | 3604 dnl Check for DBM support in libgdbm. |
3571 if test "$with_database_gnudbm" != "no"; then | 3605 if test "$with_database_gdbm" != "no"; then |
3572 AC_CHECK_LIB(gdbm, dbm_open, [ | 3606 AC_CHECK_LIB(gdbm, dbm_open, [ |
3573 with_database_gnudbm=yes with_database_dbm=no libdbm=-lgdbm], [ | 3607 with_database_gdbm=yes with_database_dbm=no libdbm=-lgdbm], [ |
3574 if test "$with_database_gnudbm" = "yes"; then | 3608 if test "$with_database_gdbm" = "yes"; then |
3575 XE_DIE("Required GNU DBM support cannot be provided.") | 3609 XE_DIE("Required GNU DBM support cannot be provided.") |
3576 fi | 3610 fi |
3577 with_database_gnudbm=no]) | 3611 with_database_gdbm=no]) |
3578 fi | 3612 fi |
3579 | 3613 |
3580 dnl Check for DBM support in libc and libdbm. | 3614 dnl Check for DBM support in libc and libdbm. |
3581 if test "$with_database_dbm" != "no"; then | 3615 if test "$with_database_dbm" != "no"; then |
3582 AC_CHECK_FUNC(dbm_open, [with_database_dbm=yes libdbm=], [ | 3616 AC_CHECK_FUNC(dbm_open, [with_database_dbm=yes libdbm=], [ |
3586 with_database_dbm=no])]) | 3620 with_database_dbm=no])]) |
3587 fi | 3621 fi |
3588 | 3622 |
3589 dnl Tell make about the DBM support we detected. | 3623 dnl Tell make about the DBM support we detected. |
3590 test -n "$libdbm" && XE_PREPEND("$libdbm", LIBS) | 3624 test -n "$libdbm" && XE_PREPEND("$libdbm", LIBS) |
3591 test "$with_database_gnudbm" = "yes" -o \ | 3625 test "$with_database_gdbm" = "yes" -o \ |
3592 "$with_database_dbm" = "yes" && \ | 3626 "$with_database_dbm" = "yes" && \ |
3593 AC_DEFINE(HAVE_DBM) | 3627 AC_DEFINE(HAVE_DBM) |
3594 | 3628 |
3595 dnl Check for Berkeley DB. | 3629 dnl Check for Berkeley DB. |
3596 if test "$with_database_berkdb" != "no"; then | 3630 if test "$with_database_berkdb" != "no"; then |
3597 AC_MSG_CHECKING(for Berkeley db.h) | 3631 AC_MSG_CHECKING(for Berkeley db.h) |
3632 test "$need_libdb" = "yes" && XE_PREPEND(-ldb, LIBS) | 3666 test "$need_libdb" = "yes" && XE_PREPEND(-ldb, LIBS) |
3633 else with_database_berkdb=no | 3667 else with_database_berkdb=no |
3634 fi | 3668 fi |
3635 fi | 3669 fi |
3636 | 3670 |
3637 if test "$with_database_gnudbm $with_database_dbm $with_database_berkdb" \ | 3671 if test "$with_database_gdbm $with_database_dbm $with_database_berkdb" \ |
3638 != "no no no"; then | 3672 != "no no no"; then |
3639 AC_DEFINE(HAVE_DATABASE) | 3673 AC_DEFINE(HAVE_DATABASE) |
3640 XE_ADD_OBJS(database.o) | 3674 XE_ADD_OBJS(database.o) |
3641 fi | 3675 fi |
3642 | 3676 |
4121 fi | 4155 fi |
4122 test "$with_gif" = yes && echo " Compiling in support for (builtin) GIF image handling." | 4156 test "$with_gif" = yes && echo " Compiling in support for (builtin) GIF image handling." |
4123 test "$with_jpeg" = yes && echo " Compiling in support for JPEG image handling." | 4157 test "$with_jpeg" = yes && echo " Compiling in support for JPEG image handling." |
4124 test "$with_tiff" = yes && echo " Compiling in support for TIFF image handling." | 4158 test "$with_tiff" = yes && echo " Compiling in support for TIFF image handling." |
4125 test "$with_xface" = yes && echo " Compiling in support for X-Face message headers." | 4159 test "$with_xface" = yes && echo " Compiling in support for X-Face message headers." |
4126 case "$with_sound" in | 4160 test "$with_native_sound" = yes && echo " Compiling in native sound support." |
4127 nas ) echo " Compiling in network sound (NAS) support." ;; | 4161 test "$with_nas_sound" = yes && echo " Compiling in network sound (NAS) support." |
4128 native ) echo " Compiling in native sound support." ;; | |
4129 both ) echo " Compiling in both network and native sound support." ;; | |
4130 esac | |
4131 test "$old_nas" = yes && echo " nas library lacks error trapping, will play synchronously." | 4162 test "$old_nas" = yes && echo " nas library lacks error trapping, will play synchronously." |
4163 test "$with_esd" = yes && echo " Compiling in support for Enlightened Sound Daemon." | |
4132 | 4164 |
4133 test "$with_database_berkdb" = yes && echo " Compiling in support for Berkeley DB." | 4165 test "$with_database_berkdb" = yes && echo " Compiling in support for Berkeley DB." |
4134 test "$with_database_dbm" = yes && echo " Compiling in support for DBM." | 4166 test "$with_database_dbm" = yes && echo " Compiling in support for DBM." |
4135 test "$with_database_gnudbm" = yes && echo " Compiling in support for GNU DBM." | 4167 test "$with_database_gdbm" = yes && echo " Compiling in support for GNU DBM." |
4136 | 4168 |
4137 test "$with_ldap" = yes && echo " Compiling in support for LDAP." | 4169 test "$with_ldap" = yes && echo " Compiling in support for LDAP." |
4138 | 4170 |
4139 test "$with_ncurses" = yes && echo " Compiling in support for ncurses." | 4171 test "$with_ncurses" = yes && echo " Compiling in support for ncurses." |
4140 test "$with_gpm" = yes && echo " Compiling in support for GPM (General Purpose Mouse)." | 4172 test "$with_gpm" = yes && echo " Compiling in support for GPM (General Purpose Mouse)." |