source: trunk/third/librep/configure.in @ 15767

Revision 15767, 17.5 KB checked in by ghudson, 23 years ago (diff)
Merge with librep 0.13.4.
Line 
1dnl  Process this file with autoconf to produce a configure script.
2dnl  Copyright (C) 1998 John Harper <john@dcs.warwick.ac.uk>
3dnl  $Id: configure.in,v 1.3 2001-03-13 17:05:56 ghudson Exp $
4dnl
5dnl  This file is part of librep.
6dnl
7dnl  librep is free software; you can redistribute it and/or modify it
8dnl  under the terms of the GNU General Public License as published by
9dnl  the Free Software Foundation; either version 2, or (at your option)
10dnl  any later version.
11dnl
12dnl  librep is distributed in the hope that it will be useful, but
13dnl  WITHOUT ANY WARRANTY; without even the implied warranty of
14dnl  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15dnl  GNU General Public License for more details.
16dnl
17dnl  You should have received a copy of the GNU General Public License
18dnl  along with librep; see the file COPYING.  If not, write to
19dnl  the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
20
21AC_REVISION($Revision: 1.3 $)
22
23AC_INIT(src/rep_subrs.h)
24AC_CONFIG_HEADER(config.h src/rep_config.h)
25
26dnl Release versioning info
27version="0.13.4"
28
29dnl libtool versioning info: `CURRENT:REVISION:AGE'. CURRENT is the
30dnl current interface id, REVISION is the version number of this
31dnl implementation, AGE defines the first interface id also supported
32dnl (i.e. all interfaces between CURRENT-AGE and CURRENT are supported)
33libcurrent=10
34librevision=3
35libage=1
36libversion="$libcurrent:$librevision:$libage"
37
38makefile_template="Makefile.in:Makedefs.in"
39output_files="src/Makefile:Makedefs.in:src/Makefile.in\
40 lisp/Makefile:Makedefs.in:lisp/Makefile.in\
41 Makefile:Makedefs.in:Makefile.in\
42 man/Makefile:Makedefs.in:man/Makefile.in\
43 intl/Makefile librep.spec"
44
45dnl Find the system type
46AC_CANONICAL_HOST
47
48dnl Remove trailing slash in $prefix if necessary
49case "${prefix}" in
50  */)
51    prefix=`echo ${prefix} | sed -e 's/^\(.*\)\/$/\1/'`
52    ;;
53esac
54
55repdir='${datadir}/rep'
56replispdir='${repdir}/lisp'
57repexecdir='${libexecdir}/rep'
58repcommonexecdir='${libexecdir}/rep'
59repdocfile='${repexecdir}/DOC'
60
61EXTRA_LIBOBJS=""
62AC_SUBST(EXTRA_LIBOBJS)
63
64dnl Checks for programs.
65AC_PROG_CC
66AC_ISC_POSIX
67AC_PROG_CPP
68AC_PROG_INSTALL
69AC_PROG_LN_S
70AC_PROG_MAKE_SET
71AC_PROG_GCC_TRADITIONAL
72
73AC_DISABLE_STATIC
74AM_PROG_LIBTOOL
75
76dnl Abort if shared libraries aren't enabled
77if test "${enable_shared}" != "yes"; then
78  AC_MSG_ERROR([Need shared libraries enabled])
79fi
80
81dnl Checks for libraries.
82AC_CHECK_FUNC(gethostent, , AC_CHECK_LIB(nsl, gethostent))
83AC_CHECK_FUNC(setsockopt, , AC_CHECK_LIB(socket, setsockopt))
84AC_CHECK_FUNC(dlopen, , AC_CHECK_LIB(dl, dlopen))
85
86dnl Checks for header files.
87AC_HEADER_DIRENT
88AC_HEADER_STDC
89AC_HEADER_SYS_WAIT
90AC_HEADER_TIME
91AC_CHECK_HEADERS(fcntl.h sys/ioctl.h sys/time.h sys/utsname.h unistd.h siginfo.h memory.h stropts.h termios.h string.h limits.h argz.h locale.h nl_types.h malloc.h sys/param.h)
92
93dnl Check for GNU MP library and header files
94AC_ARG_WITH(gmp,
95 [  --without-gmp                 Don't use GMP for bignum/rational numbers],
96 [], [with_gmp=maybe])
97
98GMP_LIBS="-lm"
99if test "$with_gmp" != "no"; then
100  AC_ARG_WITH(gmp-prefix, [  --with-gmp-prefix=DIR   path to GMP],
101   [if test "$withval" != "no"; then
102      CPPFLAGS="${CPPFLAGS} -I$withval/include"
103      LDFLAGS="${LDFLAGS} -L$withval/lib"
104    fi],
105   dnl debian brain-damage
106   [if test -d /usr/include/gmp2; then
107      CPPFLAGS="${CPPFLAGS} -I/usr/include/gmp2"
108    fi])
109
110  found_gmp=no
111  AC_CHECK_HEADER(gmp.h,
112    [AC_CHECK_LIB(gmp, mpz_init,
113       [GMP_LIBS="-lgmp -lm"; found_gmp=yes],
114       [AC_CHECK_LIB(gmp, __gmpz_init,
115          [GMP_LIBS="-lgmp -lm"; found_gmp=yes])])])
116
117  if test "$found_gmp" = "yes"; then
118    AC_DEFINE(HAVE_GMP)
119  elif test "$with_gmp" != "no"; then
120    AC_MSG_ERROR([Can't find GMP (--without-gmp for cut-down non-GMP build)])
121  fi
122fi
123AC_SUBST(GMP_LIBS)
124
125dnl Check for GNU DBM library and header files
126AC_ARG_WITH(gdbm-prefix,
127[  --with-gdbm-prefix=DIR  path to GDBM],[
128  if test "$withval" != "no"; then
129    CPPFLAGS="${CPPFLAGS} -I$withval/include"
130    LDFLAGS="${LDFLAGS} -L$withval/lib"
131  fi
132])
133AC_CHECK_HEADER(gdbm.h,
134    AC_CHECK_LIB(gdbm, gdbm_open, GDBM_LIBS="-lgdbm",
135        AC_MSG_ERROR(Cannot find GDBM library)),
136    AC_MSG_ERROR(Cannot find GDBM header))
137AC_SUBST(GDBM_LIBS)
138
139dnl Check for Doug Lea's malloc in libc, otherwise compile dlmalloc.c
140doug_lea_malloc=yes
141AC_CHECK_FUNC(malloc_get_state, , doug_lea_malloc=no)
142AC_CHECK_FUNC(malloc_set_state, , doug_lea_malloc=no)
143if test "$doug_lea_malloc" = "no"; then
144  case ${host} in
145    *-dec-osf*)
146      dnl dlmalloc is broken on Tru64
147      AC_DEFINE(LIBC_MALLOC)
148      ;;
149    *)
150      EXTRA_LIBOBJS="${EXTRA_LIBOBJS} dlmalloc.o"
151      AC_DEFINE(DOUG_LEA_MALLOC)
152      ;;
153  esac
154else
155  AC_DEFINE(DOUG_LEA_MALLOC)
156  AC_DEFINE(LIBC_MALLOC)
157fi
158
159dnl Check for readline
160AC_ARG_WITH(readline,
161 [  --with-readline         support fancy command input editing
162  --without-readline      Don't use readline], [], [with_readline=maybe])
163
164if test "$with_readline" != "no"; then
165  AC_ARG_WITH(readline-prefix,
166  [  --with-readline-prefix=DIR path to readline],
167  [ if test "$withval" != "no" -a "$withval" != "yes"; then
168    # Save in case test with directory specified fails
169    _cppflags=${CPPFLAGS}
170    _ldflags=${LDFLAGS}
171
172    CPPFLAGS="${CPPFLAGS} -I$withval/include"
173    LDFLAGS="${LDFLAGS} -L$withval/lib"
174  fi ])
175
176  dnl check for terminal library
177  dnl this is a very cool solution from octave's configure.in
178  unset tcap
179  for termlib in ncurses curses termcap terminfo termlib; do
180    AC_CHECK_LIB(${termlib}, tputs, [tcap="$tcap -l$termlib"])
181    case "$tcap" in
182      *-l${termlib}*)
183        break
184      ;;
185    esac
186  done
187
188  AC_CHECK_HEADER(readline/readline.h,
189    AC_CHECK_LIB(readline, readline,[
190      READLINE_LIBS="-lreadline $tcap"
191      AC_DEFINE(HAVE_LIBREADLINE)], , $tcap))
192
193  if test -z "$READLINE_LIBS"; then
194    if test "$with_readline_prefix" = "yes"; then
195      AC_MSG_ERROR([Can't find readline libraries])
196    else
197      CPPFLAGS=${_cppflags}
198      LDFLAGS=${_ldflags}
199    fi
200  fi
201fi
202AC_SUBST(READLINE_LIBS)
203
204dnl Check for dynamic loading
205AC_CHECK_HEADER(dlfcn.h, [AC_DEFINE(HAVE_DLFCN_H)])
206AC_CHECK_HEADER(dl.h, [AC_DEFINE(HAVE_DL_H)])
207dl_ok=no
208AC_CHECK_FUNC(dlopen, [AC_DEFINE(HAVE_DLOPEN) dl_ok=dl],
209    AC_CHECK_LIB(dl, dlopen, [AC_DEFINE(HAVE_DLOPEN) dl_ok=dl]))
210AC_CHECK_FUNC(shl_load, [AC_DEFINE(HAVE_SHL_LOAD) dl_ok=shl],
211    AC_CHECK_LIB(dld, shl_load, [AC_DEFINE(HAVE_DLOPEN) dl_ok=shl]))
212
213if test $dl_ok = dl; then
214  AC_MSG_CHECKING([for preceding underscore in symbols])
215  dnl copied from glib configure.in
216  AC_TRY_RUN([#ifdef HAVE_DLFCN_H
217              # include <dlfcn.h>
218              #endif
219              int glib_underscore_test (void) { return 42; }
220              int main() {
221                void *f1 = (void*)0, *f2 = (void*)0, *handle;
222                handle = dlopen ((void*)0, 0);
223                if (handle) {
224                  f1 = dlsym (handle, "glib_underscore_test");
225                  f2 = dlsym (handle, "_glib_underscore_test");
226                } return (!f2 || f1);
227              }],
228              [AC_DEFINE(DLSYM_NEED_USCORE)
229               AC_MSG_RESULT(yes)],
230              [AC_MSG_RESULT(no)])
231
232  dnl RTLD_GLOBAL is broken for Tru64 UNIX V5.0 and V5.0A, such that
233  dnl   xh = dlopen("libx.so", RTLD_GLOBAL|RTLD_LAZY); /* provides func */
234  dnl   yh = dlopen("liby.so", RTLD_GLOBAL|RTLD_LAZY); /* provides func */
235  dnl   yf = dlsym(yh, "func"); /* Error: returns func from libx.so */
236  dnl It's hard to test for this apart from the version string, so
237  dnl that's what we use.
238  case ${host} in
239    *-dec-osf5*)
240      AC_MSG_CHECKING([for broken RTLD_GLOBAL on Tru64])
241      if /usr/sbin/sizer -v | grep -E -q -e 'UNIX [[TVX]]5\.0A?(-[[[:digit:]]]+)? '; then
242          AC_DEFINE(BROKEN_RTLD_GLOBAL)
243          AC_MSG_RESULT(yes)
244      else
245          AC_MSG_RESULT(no)
246      fi
247      ;;
248  esac
249fi
250
251if test $dl_ok != no; then
252  AC_DEFINE(HAVE_DYNAMIC_LOADING)
253else
254  AC_MSG_ERROR([can't figure out how to do dynamic loading])
255fi
256
257dnl Checks for typedefs, structures, and compiler characteristics.
258AC_C_CONST
259AC_C_INLINE
260AC_TYPE_OFF_T
261AC_TYPE_PID_T
262AC_TYPE_SIZE_T
263AC_TYPE_SIGNAL
264
265dnl Checks for library functions.
266AC_FUNC_ALLOCA
267AC_FUNC_MMAP
268AC_FUNC_MEMCMP
269AC_FUNC_VPRINTF
270AC_CHECK_FUNCS(getcwd gethostname select socket strcspn strerror strstr stpcpy strtol psignal strsignal snprintf grantpt lrand48 getpagesize setitimer dladdr dlerror munmap putenv setenv setlocale strchr strcasecmp strncasecmp strdup __argz_count __argz_stringify __argz_next siginterrupt gettimeofday strtoll strtoq)
271AC_REPLACE_FUNCS(realpath)
272
273dnl Custom tests
274
275dnl How do we get dependency lines in the Makefile?
276if test "x${GCC}" = "xyes"; then
277  MAKEDEP='$(CC) -MM'
278else
279  case ${host} in
280    *-dec-osf*)
281      dnl works on Tru64
282      MAKEDEP='$(CC) -M'
283      ;;
284    *-sun-solaris*)
285      dnl works on Solaris
286      MAKEDEP='/usr/lib/cpp -M'
287      ;;
288    *)
289      dnl disable dependences?
290      MAKEDEP='true'
291      ;;
292  esac
293fi
294AC_SUBST(MAKEDEP)
295
296dnl If using GCC and it doesn't look as though the cflags have been
297dnl set explicitly, add some warning options.
298if test "x${GCC}" = "xyes" -a "x$CFLAGS" = "x-g -O2"; then
299  CFLAGS="${CFLAGS} -Wall -Wpointer-arith -Wmissing-prototypes"
300  case ${host} in
301    *-sun-solaris*)
302      dnl Turn off implicit-int warnings since the X11 includes
303      dnl on Solaris generate a lot of these
304      CFLAGS="${CFLAGS} -Wno-implicit-int"
305      ;;
306  esac
307fi
308
309AC_ARG_WITH(extra-cflags,
310  [  --with-extra-cflags=FLAGS Extra flags to pass to C compiler],
311  CFLAGS="${CFLAGS} $with_extra_cflags")
312
313dnl Does <unistd.h> declare char **environ?
314AC_CACHE_CHECK([whether unistd.h declares environ], jade_cv_decl_environ,
315 AC_TRY_COMPILE([#include <unistd.h>], [char **foo = environ;],
316  [jade_cv_decl_environ=yes],
317  [jade_cv_decl_environ=no]))
318if test ${jade_cv_decl_environ} = no; then
319  AC_DEFINE(ENVIRON_UNDECLARED)
320fi
321
322dnl Are ptys available, and if so, how?
323AC_MSG_CHECKING([whether /dev/ptmx exists])
324if test -r /dev/ptmx; then
325  AC_MSG_RESULT([yes])
326  AC_DEFINE(HAVE_PTYS)
327  AC_DEFINE(HAVE_DEV_PTMX)
328else
329  AC_MSG_RESULT([no])
330fi
331
332dnl Look for old-style /dev/ptyXN devices
333AC_CACHE_CHECK([whether /dev/ptyXN devices exist], jade_cv_sys_dev_pty,
334 jade_cv_sys_dev_pty=no
335 for c in p q r s t u v w x y z a b c d e f g h i j k l m n o; do
336   if test -r "/dev/pty${c}0"; then
337     jade_cv_sys_dev_pty=${c}
338     break
339   fi
340 done)
341if test ${jade_cv_sys_dev_pty} != no; then
342  AC_DEFINE(HAVE_PTYS)
343  AC_DEFINE_UNQUOTED(FIRST_PTY_LETTER, '${jade_cv_sys_dev_pty}')
344fi
345
346dnl Try to find the aclocal directory for installation
347aclocaldir=none
348AC_ARG_WITH(aclocaldir,
349  [  --with-aclocaldir=DIR   Directory in which to install autoconf macros],
350  aclocaldir=$withval)
351AC_MSG_CHECKING([for aclocal directory])
352if test "$aclocaldir" = none; then
353  aclocaldir="`aclocal --print-ac-dir 2>/dev/null`"
354  if test "x${aclocaldir}" = "x"; then
355    aclocaldir='${datadir}/aclocal'
356  fi
357fi
358AC_MSG_RESULT([${aclocaldir}])
359AC_SUBST(aclocaldir)
360
361AC_ARG_ENABLE(continuations,
362 [  --disable-continuations Don't include support for continuations
363                           or multi-threading],
364 [if test "$enableval" != "no"; then AC_DEFINE(WITH_CONTINUATIONS) fi],
365 [AC_DEFINE(WITH_CONTINUATIONS)])
366
367AC_ARG_ENABLE(dballoc,
368 [  --enable-dballoc      Trace all memory allocations],
369 [if test "$enableval" != "no"; then AC_DEFINE(DEBUG_SYS_ALLOC) fi])
370
371AC_ARG_ENABLE(dbsyms,
372 [  --disable-dbsyms      When writing debug output, don't translate
373                           addresses to symbol names],
374 [if test "$enableval" != "no"; then AC_DEFINE(DB_RESOLVE_SYMBOLS) fi],
375 [AC_DEFINE(DB_RESOLVE_SYMBOLS)])
376
377AC_ARG_ENABLE(gprof,
378 [  --enable-gprof        Build for gprof (needs --enable-static)],
379 [CFLAGS="${CFLAGS} -pg"; LDFLAGS="${LDFLAGS} -pg"])
380
381AC_ARG_ENABLE(full-name-terminator,
382 [  --enable-full-name-terminator=C Full name in gecos field of passwd
383                           file is terminated by first C character],
384 [if test "$enableval" != "no"; then
385   enableval="'$enableval'"
386   AC_DEFINE_UNQUOTED(FULL_NAME_TERMINATOR, $enableval)
387  fi])
388
389dnl Assumption for now
390HAVE_UNIX=1
391AC_DEFINE(rep_HAVE_UNIX, 1)
392
393dnl We need to find an integer type that's big enough to store any pointer
394AC_MSG_CHECKING([for data type to store Lisp values])
395AC_ARG_WITH(value-type,
396 [  --with-value-type=TYPE  Implicitly signed integer type, at least as wide
397                           as a pointer. [TYPE=<probed>] (see README)], [],
398 [with_value_type="undef"])
399if test "${with_value_type}" = "undef"; then
400  AC_TRY_RUN([main () { exit (!(sizeof (int) >= sizeof (void *)));}],
401             [with_value_type=int])
402fi
403if test "${with_value_type}" = "undef"; then
404  AC_TRY_RUN([main () { exit (!(sizeof (long int) >= sizeof (void *)));}],
405             [with_value_type="long int"])
406fi
407if test "${with_value_type}" = "undef"; then
408  AC_TRY_RUN([main () { exit (!(sizeof (long long int) >= sizeof (void *)));}],
409             [with_value_type="long long int"])
410fi
411if test "${with_value_type}" = "undef"; then
412  AC_MSG_ERROR([can't find Lisp value type; set --with-value-type (see README)])
413fi
414AC_MSG_RESULT([${with_value_type}])
415AC_DEFINE_UNQUOTED(rep_PTR_SIZED_INT, ${with_value_type})
416
417dnl Find the size (in bits) of the chosen value type
418AC_MSG_CHECKING([for size of Lisp value type])
419AC_ARG_WITH(value-sizeof,
420 [  --with-value-sizeof=N   Size (in bytes) of value type. [N=<probed>]], [],
421 [with_value_sizeof="undef"])
422if test "${with_value_sizeof}" = "undef"; then
423  dnl the following fragment is inspired by AC_CHECK_SIZEOF
424  AC_TRY_RUN([#include <stdio.h>
425              main () {
426                FILE *f = fopen ("conftestval", "w");
427                if (!f) exit (1);
428                fprintf (f, "%d\n", sizeof (${with_value_type}));
429                exit (0);
430              }],
431              [ with_value_sizeof=`cat conftestval`; rm -f conftestval])
432fi
433AC_MSG_RESULT([${with_value_sizeof} bytes])
434AC_DEFINE_UNQUOTED(rep_PTR_SIZED_INT_SIZEOF, ${with_value_sizeof})
435
436dnl What's the suffix to get an integer constant of the above size?
437AC_MSG_CHECKING([for value type constant suffix])
438case "${with_value_type}" in
439  "long long int"|"long long")
440    rep_value_suffix=LL
441    ;;
442  *)
443    dnl We should be okay to default to longs..
444    rep_value_suffix=L
445    ;;
446esac
447AC_MSG_RESULT([${rep_value_suffix}])
448AC_DEFINE_UNQUOTED(rep_PTR_SIZED_INT_SUFFIX, ${rep_value_suffix})
449
450dnl What's the printf integer conversion for this type?
451AC_MSG_CHECKING([for value type printf conversion])
452case "${with_value_type}" in
453  "long long int"|"long long")
454    dnl other options would be L or q!?
455    rep_value_conv=ll
456    ;;
457  long|"long int")
458    rep_value_conv=l
459    ;;
460  *)
461    rep_value_conv=
462    ;;
463esac
464AC_MSG_RESULT([${rep_value_conv}])
465AC_DEFINE_UNQUOTED(rep_PTR_SIZED_INT_CONV, "${rep_value_conv}")
466
467dnl Check for size of long
468AC_CHECK_SIZEOF(long)
469
470dnl Check if `long long int' is available, also check it's size, if not
471dnl available, then set it's size to the same as long
472AC_MSG_CHECKING([for long long int])
473AC_TRY_COMPILE([],[long long int foo = 42;],
474               [AC_MSG_RESULT(yes)
475                AC_DEFINE(rep_HAVE_LONG_LONG,1)
476                AC_CHECK_SIZEOF(long long)],
477               [AC_MSG_RESULT(no)
478                AC_DEFINE(SIZEOF_LONG_LONG,SIZEOF_LONG)])
479
480
481dnl This is the malloc granularity. It's unlikely that anything has
482dnl less alignment than the default value of the number of bytes in
483dnl the value type
484AC_ARG_WITH(malloc-alignment,
485 [  --with-malloc-alignment=BYTES Must be less than or equal to the alignment
486                           returned by the malloc function. [BYTES=N]], [],
487 [with_malloc_alignment=${with_value_sizeof}])
488AC_DEFINE_UNQUOTED(rep_MALLOC_ALIGNMENT, ${with_malloc_alignment})
489
490dnl Check for gcc crashes on alpha (seems to be fixed in new snapshots, but
491dnl just to make it compile on all machines)
492if test "x${GCC}" = "xyes"; then
493  AC_MSG_CHECKING([for broken alpha gcc])
494  AC_TRY_COMPILE([],[__builtin_return_address(1);],
495                 [AC_MSG_RESULT(no)],
496                 [AC_DEFINE(BROKEN_ALPHA_GCC,1)
497                  AC_MSG_RESULT(yes)
498                  AC_MSG_WARN([Backtrace support will not be compiled])])
499fi
500
501AC_MSG_CHECKING([for stack growth direction])
502AC_ARG_WITH(stack-direction,
503 [  --with-stack-direction=DIR Stack growth direction. -1 for downwards,
504                           +1 for upwards.],
505 [AC_MSG_RESULT(${with_stack_direction})],
506 [with_stack_direction=unknown])
507if test "${with_stack_direction}" = unknown; then
508  case ${host_cpu} in
509    sparc|i?86)
510      AC_MSG_RESULT([assuming downwards])
511      with_stack_direction="-1"
512      ;;
513    dnl any other known stack directions..?
514  esac
515fi
516if test "${with_stack_direction}" = unknown; then
517  AC_TRY_RUN([ void inner (char *foo) { char bar; exit (!(foo >= &bar)); }
518               void main () { char foo; inner (&foo); } ],
519   [AC_MSG_RESULT([downwards])
520    with_stack_direction=-1],
521   [AC_MSG_RESULT([upwards])
522    with_stack_direction=+1])
523fi
524if test "${with_stack_direction}" != unknown; then
525  AC_DEFINE_UNQUOTED(STACK_DIRECTION, ${with_stack_direction})
526fi
527
528dnl Nonstandard exported symbols
529AC_SUBST(version)
530AC_SUBST(libversion)
531AC_SUBST(repdir)
532AC_SUBST(repexecdir)
533AC_SUBST(repcommonexecdir)
534AC_SUBST(replispdir)
535AC_SUBST(repdocfile)
536AC_SUBST(HAVE_UNIX)
537AC_SUBST(HAVE_X11)
538AC_SUBST(LIBOBJS)
539
540AC_DEFINE_UNQUOTED(rep_VERSION, "${version}")
541AC_DEFINE_UNQUOTED(rep_INTERFACE, ${libcurrent})
542
543dnl Hacks for libintl
544AM_LC_MESSAGES
545VERSION="$version"
546PACKAGE="librep"
547DATADIRNAME="share"
548MKINSTALLDIRS='${top_srcdir}/mkinstalldirs'
549INTLOBJS="\$(GETTOBJS)"
550GT_YES='#'
551GT_NO=''
552l=l
553AC_SUBST(VERSION)
554AC_SUBST(PACKAGE)
555AC_SUBST(DATADIRNAME)
556AC_SUBST(MKINSTALLDIRS)
557AC_SUBST(INTLOBJS)
558AC_SUBST(GT_YES)
559AC_SUBST(GT_NO)
560AC_SUBST(l)
561
562dnl If it looks like GNU gettext is in libc, don't compile a local copy
563USE_INCLUDED_LIBINTL=yes
564AC_SUBST(USE_INCLUDED_LIBINTL)
565AC_CHECK_FUNC(_nl_msg_cat_cntr,
566 [AC_DEFINE(LIBC_GETTEXT)
567  AC_CHECK_HEADERS(libintl.h)
568  USE_INCLUDED_LIBINTL=no])
569
570dnl Build all files
571AC_OUTPUT(${output_files})
572
573dnl If it doesn't look like GNU Make is being used, give a friendly warning
574tem=`make --version -f /dev/null 2>&1 | grep GNU`
575if test "x$tem" = "x"; then
576  AC_MSG_WARN([You need to use GNU Make when compiling])
577fi
578
579dnl Local variables:
580dnl major-mode: sh-mode
581dnl End:
Note: See TracBrowser for help on using the repository browser.