Mercurial > emacs
changeset 25038:740d12d42387
(--with-png, HAVE_PNG): New.
(toplevel): Add checks for machine/soundcard.h and sys/soundcard.h.
(USE_TOOLKIT_SCROLL_BARS): New.
(HAVE_XAW3D): New.
(--with-tiff, HAVE_TIFF): Added.
(HAVE_JPEG, --with-jpeg): Added.
(--with-xpm, HAVE_XPM): New.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Wed, 21 Jul 1999 21:43:52 +0000 |
parents | 6293957eeb5c |
children | 7a53fe8294bf |
files | configure.in |
diffstat | 1 files changed, 127 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/configure.in Wed Jul 21 21:43:52 1999 +0000 +++ b/configure.in Wed Jul 21 21:43:52 1999 +0000 @@ -66,6 +66,18 @@ esac with_x_toolkit=$val ]) +AC_ARG_WITH(xpm, +[ --with-xpm use -lXpm for displaying XPM images]) +AC_ARG_WITH(jpeg, +[ --with-jpeg use -ljpeg for displaying JPEG images]) +AC_ARG_WITH(tiff, +[ --with-tiff use -ltiff34 for displaying TIFF images]) +AC_ARG_WITH(gif, +[ --with-gif use -lungif for displaying GIF images]) +AC_ARG_WITH(png, +[ --with-png use -lpng for displaying PNG images]) +AC_ARG_WITH(sound, +[ --with-sound native sound support for GNU/Linux and free BSDs]) #### Make srcdir absolute, if it isn't already. It's important to #### avoid running the path through pwd unnecessary, since pwd can @@ -773,7 +785,7 @@ ;; ## Suns - sparc-*-linux-gnu* | sparc64-*-linux-gnu* ) + sparc-*-linux-gnu* ) machine=sparc opsys=gnu-linux ;; @@ -1094,6 +1106,14 @@ dnl checks for Unix variants AC_AIX +# Sound support for GNU/Linux and the free BSDs. +if test "${with_sound}" = ""; then + with_sound=no +fi +if test "${with_sound}" != "no"; then + AC_CHECK_HEADERS(machine/soundcard.h sys/soundcard.h) +fi + dnl checks for header files AC_CHECK_HEADERS(sys/select.h sys/timeb.h sys/time.h unistd.h utime.h linux/version.h sys/systeminfo.h termios.h limits.h string.h) AC_HEADER_STDC @@ -1226,6 +1246,94 @@ yes ) HAVE_MENUS=yes ;; esac +### Is -lXaw3d available? +HAVE_XAW3D=no +if test "${HAVE_X11}" = "yes"; then + old_c_flags="${CFLAGS}" + CFLAGS="${LD_SWITCH_X_SITE}" + AC_CHECK_LIB(Xaw3d, XawScrollbarSetThumb, HAVE_XAW3D=yes, , -lX11) + CFLAGS="${old_c_flags}" + + if test "${HAVE_XAW3D}" = "yes"; then + AC_DEFINE(HAVE_XAW3D) + fi +fi + +### Use -lXpm if available, unless `--with-xpm=no'. +HAVE_XPM=no +if test "${HAVE_X11}" = "yes"; then + if test "${with_xpm}" != "no"; then + old_c_flags="${CFLAGS}" + CFLAGS="${LD_SWITCH_X_SITE}" + AC_CHECK_LIB(Xpm, XpmReadFileToPixmap, HAVE_XPM=yes, , -lX11) + CFLAGS="${old_c_flags}" + fi + + if test "${HAVE_XPM}" = "yes"; then + AC_DEFINE(HAVE_XPM) + fi +fi + +### Use -ljpeg if available, unless `--with-jpeg=no'. +HAVE_JPEG=no +if test "${HAVE_X11}" = "yes"; then + if test "${with_jpeg}" != "no"; then + old_c_flags="${CFLAGS}" + CFLAGS="${LD_SWITCH_X_SITE} ${CFLAGS}" + AC_CHECK_LIB(jpeg, jpeg_destroy_compress, HAVE_JPEG=yes, , -lX11) + CFLAGS="${old_c_flags}" + fi + + if test "${HAVE_JPEG}" = "yes"; then + AC_DEFINE(HAVE_JPEG) + fi +fi + +### Use -lpng if available, unless `--with-png=no'. +HAVE_PNG=no +if test "${HAVE_X11}" = "yes"; then + if test "${with_png}" != "no"; then + old_c_flags="${CFLAGS}" + CFLAGS="${LD_SWITCH_X_SITE} ${CFLAGS}" + AC_CHECK_LIB(png, png_set_expand, HAVE_PNG=yes, , -lX11 -lz -lm) + CFLAGS="${old_c_flags}" + fi + + if test "${HAVE_PNG}" = "yes"; then + AC_DEFINE(HAVE_PNG) + fi +fi + +### Use -ltiff34 if available, unless `--with-tiff=no'. +HAVE_TIFF=no +if test "${HAVE_X11}" = "yes"; then + if test "${with_tiff}" != "no"; then + old_c_flags="${CFLAGS}" + CFLAGS="${LD_SWITCH_X_SITE} ${CFLAGS}" + AC_CHECK_LIB(tiff34, TIFFGetVersion, HAVE_TIFF=yes, , -lX11) + CFLAGS="${old_c_flags}" + fi + + if test "${HAVE_TIFF}" = "yes"; then + AC_DEFINE(HAVE_TIFF) + fi +fi + +### Use -lgif if available, unless `--with-gif=no'. +HAVE_GIF=no +if test "${HAVE_X11}" = "yes"; then + if test "${with_gif}" != "no"; then + old_c_flags="${CFLAGS}" + CFLAGS="${LD_SWITCH_X_SITE} ${CFLAGS}" + AC_CHECK_LIB(ungif, DGifOpenFileName, HAVE_GIF=yes, , -lX11) + CFLAGS="${old_c_flags}" + fi + + if test "${HAVE_GIF}" = "yes"; then + AC_DEFINE(HAVE_GIF) + fi +fi + if test "${opsys}" = "hpux9"; then case "${x_libraries}" in *X11R4* ) @@ -1553,6 +1661,18 @@ X_TOOLKIT_TYPE=$USE_X_TOOLKIT +dnl Use toolkit scroll bars if configured for X toolkit and either +dnl using Motif or Xaw3d is available. + +if test "${USE_X_TOOLKIT}" != "none"; then + if test "${USE_X_TOOLKIT}" = "MOTIF"; then + AC_DEFINE(USE_TOOLKIT_SCROLL_BARS) + HAVE_XAW3D=no + elif test "${HAVE_XAW3D}" = "yes"; then + AC_DEFINE(USE_TOOLKIT_SCROLL_BARS) + fi +fi + if test "${USE_X_TOOLKIT}" != "none"; then AC_MSG_CHECKING(X11 toolkit version) AC_CACHE_VAL(emacs_cv_x11_toolkit_version_6, @@ -1828,6 +1948,12 @@ echo " Where do we find X Windows libraries? Standard dirs" fi +echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}" +echo " Does Emacs use -lXpm? ${HAVE_XPM}" +echo " Does Emacs use -ljpeg? ${HAVE_JPEG}" +echo " Does Emacs use -ltiff34? ${HAVE_TIFF}" +echo " Does Emacs use -lungif? ${HAVE_GIF}" +echo " Does Emacs use -lpng? ${HAVE_PNG}" echo # Remove any trailing slashes in these variables.