configure.in 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607
  1. dnl configuration script for Guile
  2. dnl Process this file with autoconf to produce configure.
  3. dnl
  4. dnl Copyright (C) 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
  5. dnl
  6. dnl This file is part of GUILE
  7. dnl
  8. dnl GUILE is free software; you can redistribute it and/or modify it
  9. dnl under the terms of the GNU General Public License as published by
  10. dnl the Free Software Foundation; either version 2, or (at your
  11. dnl option) any later version.
  12. dnl
  13. dnl GUILE is distributed in the hope that it will be useful, but
  14. dnl WITHOUT ANY WARRANTY; without even the implied warranty of
  15. dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  16. dnl General Public License for more details.
  17. dnl
  18. dnl You should have received a copy of the GNU General Public License
  19. dnl along with GUILE; see the file COPYING. If not, write to the
  20. dnl Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  21. dnl Boston, MA 02111-1307, USA.
  22. AC_PREREQ(2.53)
  23. AC_INIT
  24. AC_CONFIG_SRCDIR([Makefile.in])
  25. . $srcdir/GUILE-VERSION
  26. AM_INIT_AUTOMAKE($PACKAGE, $VERSION, no-define)
  27. AM_MAINTAINER_MODE
  28. AM_CONFIG_HEADER(libguile/scmconfig.h)
  29. #--------------------------------------------------------------------
  30. #
  31. # Independent Subdirectories
  32. #
  33. #--------------------------------------------------------------------
  34. AC_CONFIG_SUBDIRS(guile-readline)
  35. #--------------------------------------------------------------------
  36. #
  37. # User options
  38. #
  39. #--------------------------------------------------------------------
  40. AC_ARG_ENABLE(debug-freelist,
  41. [ --enable-debug-freelist include garbage collector freelist debugging code],
  42. if test "$enable_debug_freelist" = y || test "$enable_debug_freelist" = yes; then
  43. AC_DEFINE(GUILE_DEBUG_FREELIST, 1,
  44. [Define this if you want to debug the free list (helps w/ GC bugs).])
  45. fi)
  46. AC_ARG_ENABLE(debug-malloc,
  47. [ --enable-debug-malloc include malloc debugging code],
  48. if test "$enable_debug_malloc" = y || test "$enable_debug_malloc" = yes; then
  49. AC_DEFINE(GUILE_DEBUG_MALLOC, 1,
  50. [Define this if you want to debug scm_must_malloc/realloc/free calls.])
  51. fi)
  52. AC_ARG_ENABLE(guile-debug,
  53. [ --enable-guile-debug include internal debugging functions],
  54. if test "$enable_guile_debug" = y || test "$enable_guile_debug" = yes; then
  55. AC_DEFINE(GUILE_DEBUG, 1,
  56. [Define this to include various undocumented functions used to debug.])
  57. fi)
  58. AC_ARG_ENABLE(arrays,
  59. [ --disable-arrays omit array and uniform array support],,
  60. enable_arrays=yes)
  61. AC_ARG_ENABLE(posix,
  62. [ --disable-posix omit posix interfaces],,
  63. enable_posix=yes)
  64. AC_ARG_ENABLE(networking,
  65. [ --disable-networking omit networking interfaces],,
  66. enable_networking=yes)
  67. AC_ARG_ENABLE(regex,
  68. [ --disable-regex omit regular expression interfaces],,
  69. enable_regex=yes)
  70. dnl The --disable-debug used to control these two. But now they are
  71. dnl a required part of the distribution.
  72. AC_DEFINE(DEBUG_EXTENSIONS, 1,
  73. [Define if you want support for debugging Scheme programs.])
  74. AC_DEFINE(READER_EXTENSIONS, 1,
  75. [Define if you want support for debugging Scheme programs.])
  76. dnl files which are destined for separate modules.
  77. if test "$enable_arrays" = yes; then
  78. AC_LIBOBJ([ramap])
  79. AC_LIBOBJ([unif])
  80. AC_DEFINE(HAVE_ARRAYS, 1,
  81. [Define this if you want support for arrays and uniform arrays.])
  82. fi
  83. if test "$enable_posix" = yes; then
  84. AC_LIBOBJ([filesys])
  85. AC_LIBOBJ([posix])
  86. AC_DEFINE(HAVE_POSIX, 1,
  87. [Define this if you want support for POSIX system calls in Guile.])
  88. fi
  89. if test "$enable_networking" = yes; then
  90. AC_LIBOBJ([net_db])
  91. AC_LIBOBJ([socket])
  92. AC_DEFINE(HAVE_NETWORKING, 1,
  93. [Define this if you want support for networking in Guile.])
  94. fi
  95. if test "$enable_debug_malloc" = yes; then
  96. AC_LIBOBJ([debug-malloc])
  97. fi
  98. #--------------------------------------------------------------------
  99. AC_LIBLTDL_INSTALLABLE
  100. AC_CONFIG_SUBDIRS(libltdl)
  101. AC_PROG_CC
  102. AC_PROG_CPP
  103. AC_LIBTOOL_DLOPEN
  104. AC_AIX
  105. AC_ISC_POSIX
  106. AC_MINIX
  107. AM_PROG_CC_STDC
  108. AM_PROG_LIBTOOL
  109. AC_C_CONST
  110. AC_C_INLINE
  111. AC_CHECK_SIZEOF(int)
  112. AC_CHECK_SIZEOF(long)
  113. AC_CACHE_CHECK([for long longs], scm_cv_long_longs,
  114. AC_TRY_COMPILE(,
  115. [long long a],
  116. scm_cv_long_longs=yes,
  117. scm_cv_long_longs=no))
  118. if test "$scm_cv_long_longs" = yes; then
  119. AC_DEFINE(HAVE_LONG_LONGS, 1, [Define if the compiler supports long longs.])
  120. fi
  121. AC_HEADER_STDC
  122. AC_HEADER_DIRENT
  123. AC_HEADER_TIME
  124. AC_HEADER_SYS_WAIT
  125. AC_CHECK_HEADERS(io.h libc.h limits.h malloc.h memory.h string.h regex.h rxposix.h rx/rxposix.h sys/ioctl.h sys/select.h sys/time.h sys/timeb.h sys/times.h sys/types.h sys/utime.h time.h unistd.h utime.h)
  126. GUILE_HEADER_LIBC_WITH_UNISTD
  127. AC_TYPE_GETGROUPS
  128. AC_TYPE_SIGNAL
  129. AC_TYPE_MODE_T
  130. AC_CHECK_LIB(m, main)
  131. AC_CHECK_FUNCS(gethostbyname)
  132. if test $ac_cv_func_gethostbyname = no; then
  133. AC_CHECK_LIB(nsl, gethostbyname)
  134. fi
  135. AC_CHECK_FUNCS(connect)
  136. if test $ac_cv_func_connect = no; then
  137. AC_CHECK_LIB(socket, connect)
  138. fi
  139. # Check for dynamic linking
  140. use_modules=yes
  141. AC_ARG_WITH(modules,
  142. [ --with-modules[=FILES] Add support for dynamic modules],
  143. use_modules="$withval")
  144. test -z "$use_modules" && use_modules=yes
  145. DLPREOPEN=
  146. if test "$use_modules" != no; then
  147. AC_DEFINE(DYNAMIC_LINKING, 1,
  148. [Define if you want support for dynamic linking.])
  149. if test "$use_modules" = yes; then
  150. DLPREOPEN="-dlpreopen force"
  151. else
  152. DLPREOPEN="-export-dynamic"
  153. for module in $use_modules; do
  154. DLPREOPEN="$DLPREOPEN -dlopen $module"
  155. done
  156. fi
  157. fi
  158. AC_SUBST(INCLTDL)
  159. AC_SUBST(LIBLTDL)
  160. AC_SUBST(DLPREOPEN)
  161. AC_CHECK_FUNCS(ctermid ftime fchown getcwd geteuid gettimeofday lstat mkdir mknod nice readlink rename rmdir select setegid seteuid setlocale setpgid setsid sigaction siginterrupt strftime strptime symlink sync tcgetpgrp tcsetpgrp times uname waitpid bzero strdup system usleep atexit on_exit)
  162. ### Some systems don't declare some functions. On such systems, we
  163. ### need to at least provide our own K&R-style declarations.
  164. ### GUILE_FUNC_DECLARED(function, headerfile)
  165. ### Check for a declaration of FUNCTION in HEADERFILE; if it is
  166. ### not there, #define MISSING_FUNCTION_DECL.
  167. AC_DEFUN(GUILE_FUNC_DECLARED, [
  168. AC_CACHE_CHECK(for $1 declaration, guile_cv_func_$1_declared,
  169. AC_EGREP_HEADER($1, $2,
  170. guile_cv_func_$1_declared=yes,
  171. guile_cv_func_$1_declared=no))
  172. if test [x$guile_cv_func_]$1[_declared] = xno; then
  173. AC_DEFINE([MISSING_]translit($1, [a-z], [A-Z])[_DECL], 1,
  174. [Define if the operating system supplies $1 without declaring it.])
  175. fi
  176. ])
  177. GUILE_FUNC_DECLARED(strptime, time.h)
  178. GUILE_FUNC_DECLARED(bzero, string.h)
  179. GUILE_FUNC_DECLARED(sleep, unistd.h)
  180. GUILE_FUNC_DECLARED(usleep, unistd.h)
  181. ### On some systems usleep has no return value. If it does have one,
  182. ### we'd like to return it; otherwise, we'll fake it.
  183. AC_CACHE_CHECK([return type of usleep], guile_cv_func_usleep_return_type,
  184. [AC_EGREP_HEADER(changequote(<, >)<void[ ]+usleep>changequote([, ]),
  185. /usr/include/unistd.h,
  186. [guile_cv_func_usleep_return_type=void],
  187. [guile_cv_func_usleep_return_type=int])])
  188. case "$guile_cv_func_usleep_return_type" in
  189. "void" )
  190. AC_DEFINE(USLEEP_RETURNS_VOID, 1,
  191. [Define if the system headers declare usleep to return void.])
  192. ;;
  193. esac
  194. dnl <GNU-WIN32 hacks>
  195. AC_CHECK_HEADER(sys/un.h, have_sys_un_h=1)
  196. if test -n "$have_sys_un_h" ; then
  197. AC_DEFINE(HAVE_UNIX_DOMAIN_SOCKETS, 1,
  198. [Define if the system supports Unix-domain (file-domain) sockets.])
  199. fi
  200. AC_CHECK_FUNCS(socketpair getgroups setpwent pause tzset)
  201. dnl I don't know what this prefixing of cygwin32_ is for.
  202. dnl scmconfig.h wasn't updated with the test results.
  203. dnl so use AC_CHECK_FUNCS for now.
  204. dnl how about:
  205. dnl save confdefs.h
  206. dnl if test $ac_cv_cigwin = yes; then
  207. dnl modify confdefs.h
  208. dnl fi
  209. dnl AC_CHECK_FUNCS...
  210. dnl restore confdefs.h
  211. dnl cp confdefs.h confdefs.h.bak
  212. dnl for func in gethostent sethostent endhostent getnetent setnetent endnetent getprotoent setprotoent endprotoent getservent setservent endservent getnetbyaddr getnetbyname inet_lnaof inet_makeaddr inet_netof hstrerror; do
  213. dnl cp confdefs.h.bak confdefs.h
  214. dnl cat >> confdefs.h << EOF
  215. dnl #ifdef __CYGWIN32__
  216. dnl #define $func cygwin32_$func
  217. dnl #endif
  218. dnl EOF
  219. dnl AC_CHECK_FUNC($func)
  220. dnl done
  221. dnl cp confdefs.h.bak confdefs.h
  222. AC_CHECK_FUNCS(sethostent gethostent endhostent dnl
  223. setnetent getnetent endnetent dnl
  224. setprotoent getprotoent endprotoent dnl
  225. setservent getservent endservent dnl
  226. getnetbyaddr getnetbyname dnl
  227. inet_lnaof inet_makeaddr inet_netof hstrerror)
  228. dnl </GNU-WIN32 hacks>
  229. AC_MSG_CHECKING(whether localtime caches TZ)
  230. AC_CACHE_VAL(guile_cv_localtime_cache,
  231. [if test x$ac_cv_func_tzset = xyes; then
  232. AC_TRY_RUN([#include <time.h>
  233. #if STDC_HEADERS
  234. # include <stdlib.h>
  235. #endif
  236. extern char **environ;
  237. unset_TZ ()
  238. {
  239. char **from, **to;
  240. for (to = from = environ; (*to = *from); from++)
  241. if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
  242. to++;
  243. }
  244. char TZ_GMT0[] = "TZ=GMT0";
  245. char TZ_PST8[] = "TZ=PST8";
  246. main()
  247. {
  248. time_t now = time ((time_t *) 0);
  249. int hour_GMT0, hour_unset;
  250. if (putenv (TZ_GMT0) != 0)
  251. exit (1);
  252. hour_GMT0 = localtime (&now)->tm_hour;
  253. unset_TZ ();
  254. hour_unset = localtime (&now)->tm_hour;
  255. if (putenv (TZ_PST8) != 0)
  256. exit (1);
  257. if (localtime (&now)->tm_hour == hour_GMT0)
  258. exit (1);
  259. unset_TZ ();
  260. if (localtime (&now)->tm_hour != hour_unset)
  261. exit (1);
  262. exit (0);
  263. }], guile_cv_localtime_cache=no, guile_cv_localtime_cache=yes,
  264. [# If we have tzset, assume the worst when cross-compiling.
  265. guile_cv_localtime_cache=yes])
  266. else
  267. # If we lack tzset, report that localtime does not cache TZ,
  268. # since we can't invalidate the cache if we don't have tzset.
  269. guile_cv_localtime_cache=no
  270. fi])dnl
  271. AC_MSG_RESULT($guile_cv_localtime_cache)
  272. if test $guile_cv_localtime_cache = yes; then
  273. AC_DEFINE(LOCALTIME_CACHE, 1, [Define if localtime caches the TZ setting.])
  274. fi
  275. dnl Test whether system calls are restartable by default on the
  276. dnl current system. If they are not, we put a loop around every system
  277. dnl call to check for EINTR (see SCM_SYSCALL) and do not attempt to
  278. dnl change from the default behaviour. On the other hand, if signals
  279. dnl are restartable then the loop is not installed and when libguile
  280. dnl initialises it also resets the behaviour of each signal to cause a
  281. dnl restart (in case a different runtime had a different default
  282. dnl behaviour for some reason: e.g., different versions of linux seem
  283. dnl to behave differently.)
  284. AC_SYS_RESTARTABLE_SYSCALLS
  285. if test "$enable_regex" = yes; then
  286. if test "$ac_cv_header_regex_h" = yes ||
  287. test "$ac_cv_header_rxposix_h" = yes ||
  288. test "$ac_cv_header_rx_rxposix_h" = yes; then
  289. GUILE_NAMED_CHECK_FUNC(regcomp, norx, [AC_LIBOBJ([regex-posix])],
  290. [AC_CHECK_LIB(rx, main)
  291. GUILE_NAMED_CHECK_FUNC(regcomp, rx, [AC_LIBOBJ([regex-posix])],
  292. [AC_CHECK_LIB(regex, main)
  293. GUILE_NAMED_CHECK_FUNC(regcomp, regex, [AC_LIBOBJ([regex-posix])])])]
  294. )
  295. dnl The following should not be necessary, but for some reason
  296. dnl autoheader misses it if we don't include it!
  297. if test "$ac_cv_func_regcomp_norx" = yes ||
  298. test "$ac_cv_func_regcomp_regex" = yes ||
  299. test "$ac_cv_func_regcomp_rx" = yes; then
  300. AC_DEFINE(HAVE_REGCOMP, 1,
  301. [This is included as part of a workaround for a autoheader bug.])
  302. fi
  303. fi
  304. fi
  305. AC_REPLACE_FUNCS(inet_aton putenv strerror memmove)
  306. # When testing for the presence of alloca, we need to add alloca.o
  307. # explicitly to LIBOBJS to make sure that it is translated to
  308. # `alloca.lo' for libtool later on. This can and should be done more cleanly.
  309. AC_FUNC_ALLOCA
  310. if test "$ALLOCA" = "alloca.o"; then AC_LIBOBJ([alloca]); fi
  311. AC_CHECK_MEMBERS([struct stat.st_rdev])
  312. AC_CHECK_MEMBERS([struct stat.st_blksize])
  313. AC_STRUCT_ST_BLOCKS
  314. AC_CACHE_CHECK([for S_ISLNK in sys/stat.h], ac_cv_macro_S_ISLNK,
  315. [AC_TRY_CPP([#include <sys/stat.h>
  316. #ifndef S_ISLNK
  317. #error no S_ISLNK
  318. #endif],
  319. ac_cv_macro_S_ISLNK=yes,
  320. ac_cv_macro_S_ISLNK=no)])
  321. if test $ac_cv_macro_S_ISLNK = yes; then
  322. AC_DEFINE(HAVE_S_ISLNK, 1,
  323. [Define this if your system defines S_ISLNK in sys/stat.h.])
  324. fi
  325. AC_STRUCT_TIMEZONE
  326. GUILE_STRUCT_UTIMBUF
  327. #--------------------------------------------------------------------
  328. #
  329. # Which way does the stack grow?
  330. #
  331. #--------------------------------------------------------------------
  332. AC_TRY_RUN(aux (l) unsigned long l;
  333. { int x; exit (l >= ((unsigned long)&x)); }
  334. main () { int q; aux((unsigned long)&q); },
  335. [AC_DEFINE([SCM_STACK_GROWS_UP], 1,
  336. [Define this if a callee's stack frame has a higher address
  337. than the caller's stack frame. On most machines, this is
  338. not the case.])],
  339. [],
  340. [AC_MSG_WARN(Guessing that stack grows down -- see scmconfig.h.in)])
  341. AH_TEMPLATE([SCM_SINGLES],
  342. [Define this if floats are the same size as longs.])
  343. AC_CACHE_CHECK([whether floats fit in longs], guile_cv_type_float_fits_long,
  344. [AC_TRY_RUN([main () { exit (sizeof(float) > sizeof(long)); }],
  345. [guile_cv_type_float_fits_long=yes],
  346. [guile_cv_type_float_fits_long=no],
  347. [guile_cv_type_float_fits_long=guess-yes])])
  348. case $guile_cv_type_float_fits_long in
  349. "yes" )
  350. AC_DEFINE(SCM_SINGLES)
  351. ;;
  352. "guess-yes" )
  353. AC_DEFINE(SCM_SINGLES)
  354. AC_MSG_WARN([guessing that sizeof(long) == sizeof(float)])
  355. AC_MSG_WARN([see SCM_SINGLES in scmconfig.h.in])
  356. ;;
  357. esac
  358. AC_MSG_CHECKING(for struct linger)
  359. AC_CACHE_VAL(scm_cv_struct_linger,
  360. AC_TRY_COMPILE([
  361. #include <sys/types.h>
  362. #include <sys/socket.h>],
  363. [struct linger lgr; lgr.l_linger = 100],
  364. scm_cv_struct_linger="yes",
  365. scm_cv_struct_linger="no"))
  366. AC_MSG_RESULT($scm_cv_struct_linger)
  367. if test $scm_cv_struct_linger = yes; then
  368. AC_DEFINE(HAVE_STRUCT_LINGER, 1,
  369. [Define this if your system defines struct linger, for use with the
  370. getsockopt and setsockopt system calls.])
  371. fi
  372. AC_MSG_CHECKING(for struct timespec)
  373. AC_CACHE_VAL(scm_cv_struct_timespec,
  374. AC_TRY_COMPILE([
  375. #include <time.h>],
  376. [struct timespec t; t.tv_nsec = 100],
  377. scm_cv_struct_timespec="yes",
  378. scm_cv_struct_timespec="no"))
  379. AC_MSG_RESULT($scm_cv_struct_timespec)
  380. if test $scm_cv_struct_timespec = yes; then
  381. AC_DEFINE(HAVE_STRUCT_TIMESPEC, 1,
  382. [Define this if your system defines struct timespec via <time.h>.])
  383. fi
  384. #--------------------------------------------------------------------
  385. #
  386. # Flags for thread support
  387. #
  388. #--------------------------------------------------------------------
  389. ### What thread package has the user asked for?
  390. AC_ARG_WITH(threads, [ --with-threads thread interface],
  391. , with_threads=no)
  392. ### Turn $with_threads into either the name of a threads package, like
  393. ### `qt', or `no', meaning that threads should not be supported.
  394. AC_MSG_CHECKING(whether to support threads)
  395. case "$with_threads" in
  396. "yes" | "qt" | "coop" | "")
  397. with_threads=qt
  398. ;;
  399. "no" )
  400. ;;
  401. * )
  402. AC_MSG_ERROR(invalid value for --with-threads: $with_threads)
  403. ;;
  404. esac
  405. AC_MSG_RESULT($with_threads)
  406. ## Make sure the threads package we've chosen is actually supported on
  407. ## the present platform.
  408. case "${with_threads}" in
  409. "qt" )
  410. ## This configures the QuickThreads package, and sets or clears
  411. ## the THREAD_PACKAGE variable if qthreads don't configure
  412. ## correctly.
  413. QTHREADS_CONFIGURE
  414. ;;
  415. esac
  416. ## If we're using threads, bring in some other parts of Guile which
  417. ## work with them.
  418. if test "${THREAD_PACKAGE}" != "" ; then
  419. AC_DEFINE(USE_THREADS, 1, [Define if using any sort of threads.])
  420. ## Include the Guile thread interface in the library...
  421. AC_LIBOBJ([threads])
  422. EXTRA_DOT_DOC_FILES="$EXTRA_DOT_DOC_FILES threads.doc"
  423. ## ... and tell it which package to talk to.
  424. case "${THREAD_PACKAGE}" in
  425. "QT" )
  426. AC_DEFINE(USE_COOP_THREADS, 1,
  427. [Define if using cooperative multithreading.])
  428. ;;
  429. * )
  430. AC_MSG_ERROR(invalid value for THREAD_PACKAGE: ${THREAD_PACKAGE})
  431. ;;
  432. esac
  433. ## Bring in scm_internal_select, if appropriate.
  434. if test $ac_cv_func_gettimeofday = yes &&
  435. test $ac_cv_func_select = yes; then
  436. AC_DEFINE(GUILE_ISELECT, 1, [Define to implement scm_internal_select.])
  437. fi
  438. ## Workaround for linuxthreads (currently disabled)
  439. if test $host_os = linux-gnu; then
  440. AC_DEFINE(GUILE_PTHREAD_COMPAT, 1,
  441. [Define to enable workaround for COOP-linuxthreads compatibility.])
  442. AC_CHECK_LIB(pthread, main)
  443. fi
  444. fi
  445. ## If we're using GCC, ask for aggressive warnings.
  446. case "$GCC" in
  447. yes )
  448. ## We had -Wstrict-prototypes in here for a bit, but Guile does too
  449. ## much stuff with generic function pointers for that to really be
  450. ## less than exasperating.
  451. ## -Wpointer-arith was here too, but something changed in gcc/glibc
  452. ## and it became equally exasperating (gcc 2.95 and/or glibc 2.1.2).
  453. CFLAGS="$CFLAGS -Wall -Wmissing-prototypes" ;;
  454. esac
  455. AC_PROG_AWK
  456. ## If we're creating a shared library (using libtool!), then we'll
  457. ## need to generate a list of .lo files corresponding to the .o files
  458. ## given in LIBOBJS. We'll call it LIBLOBJS.
  459. LIBLOBJS="`echo ${LIB@&t@OBJS} | sed 's,\.[[^.]]* ,.lo ,g;s,\.[[^.]]*$,.lo,'`"
  460. ## We also need to create corresponding .doc files
  461. EXTRA_DOT_DOC_FILES="`echo ${LIB@&t@OBJS} | sed 's,\.[[^.]]* ,.doc ,g;s,\.[[^.]]*$,.doc,'`"
  462. AC_SUBST(GUILE_MAJOR_VERSION)
  463. AC_SUBST(GUILE_MINOR_VERSION)
  464. AC_SUBST(GUILE_VERSION)
  465. #######################################################################
  466. # library versioning
  467. AC_SUBST(LIBQTHREADS_INTERFACE_CURRENT)
  468. AC_SUBST(LIBQTHREADS_INTERFACE_REVISION)
  469. AC_SUBST(LIBQTHREADS_INTERFACE_AGE)
  470. AC_SUBST(LIBQTHREADS_INTERFACE)
  471. AC_SUBST(LIBGUILE_INTERFACE_CURRENT)
  472. AC_SUBST(LIBGUILE_INTERFACE_REVISION)
  473. AC_SUBST(LIBGUILE_INTERFACE_AGE)
  474. AC_SUBST(LIBGUILE_INTERFACE)
  475. #######################################################################
  476. dnl Tell guile-config what flags guile users should link against.
  477. GUILE_LIBS="$LDFLAGS $THREAD_LIBS_INSTALLED $LIBS"
  478. AC_SUBST(GUILE_LIBS)
  479. AC_SUBST(AWK)
  480. AC_SUBST(LIBLOBJS)
  481. AC_SUBST(EXTRA_DOT_DOC_FILES)
  482. dnl See also top_builddir in info node: (libtool)AC_PROG_LIBTOOL
  483. top_builddir_absolute=`pwd`
  484. AC_SUBST(top_builddir_absolute)
  485. top_srcdir_absolute=`(cd $srcdir ; pwd)`
  486. AC_SUBST(top_srcdir_absolute)
  487. AC_CONFIG_FILES([
  488. Makefile
  489. am/Makefile
  490. libguile/Makefile
  491. libguile/guile-snarf
  492. libguile/guile-doc-snarf
  493. libguile/guile-func-name-check
  494. libguile/guile-snarf.awk
  495. libguile/versiondat.h
  496. ice-9/Makefile
  497. qt/Makefile
  498. qt/qt.h
  499. qt/md/Makefile
  500. qt/time/Makefile
  501. guile-config/Makefile
  502. doc/Makefile
  503. test-suite/Makefile
  504. check-guile
  505. pre-inst-guile
  506. ])
  507. AC_CONFIG_COMMANDS(default,[
  508. chmod +x libguile/guile-snarf \
  509. libguile/guile-doc-snarf \
  510. libguile/guile-func-name-check \
  511. check-guile \
  512. pre-inst-guile
  513. ])
  514. AC_OUTPUT
  515. dnl Local Variables:
  516. dnl comment-start: "dnl "
  517. dnl comment-end: ""
  518. dnl comment-start-skip: "\\bdnl\\b\\s *"
  519. dnl End: