16
16
You have another version of autoconf. If you want to use that,
17
17
you should regenerate the build system entirely.], [63])])
19
# Configure paths for GLIB
22
dnl AM_PATH_GLIB([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]])
23
dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if "gmodule" or
24
dnl gthread is specified in MODULES, pass to glib-config
26
AC_DEFUN([AM_PATH_GLIB],
28
dnl Get the cflags and libraries from the glib-config script
30
AC_ARG_WITH(glib-prefix,[ --with-glib-prefix=PFX Prefix where GLIB is installed (optional)],
31
glib_config_prefix="$withval", glib_config_prefix="")
32
AC_ARG_WITH(glib-exec-prefix,[ --with-glib-exec-prefix=PFX Exec prefix where GLIB is installed (optional)],
33
glib_config_exec_prefix="$withval", glib_config_exec_prefix="")
34
AC_ARG_ENABLE(glibtest, [ --disable-glibtest Do not try to compile and run a test GLIB program],
35
, enable_glibtest=yes)
37
if test x$glib_config_exec_prefix != x ; then
38
glib_config_args="$glib_config_args --exec-prefix=$glib_config_exec_prefix"
39
if test x${GLIB_CONFIG+set} != xset ; then
40
GLIB_CONFIG=$glib_config_exec_prefix/bin/glib-config
43
if test x$glib_config_prefix != x ; then
44
glib_config_args="$glib_config_args --prefix=$glib_config_prefix"
45
if test x${GLIB_CONFIG+set} != xset ; then
46
GLIB_CONFIG=$glib_config_prefix/bin/glib-config
54
glib_config_args="$glib_config_args gmodule"
57
glib_config_args="$glib_config_args gthread"
62
AC_PATH_PROG(GLIB_CONFIG, glib-config, no)
63
min_glib_version=ifelse([$1], ,0.99.7,$1)
64
AC_MSG_CHECKING(for GLIB - version >= $min_glib_version)
66
if test "$GLIB_CONFIG" = "no" ; then
69
GLIB_CFLAGS=`$GLIB_CONFIG $glib_config_args --cflags`
70
GLIB_LIBS=`$GLIB_CONFIG $glib_config_args --libs`
71
glib_config_major_version=`$GLIB_CONFIG $glib_config_args --version | \
72
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
73
glib_config_minor_version=`$GLIB_CONFIG $glib_config_args --version | \
74
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
75
glib_config_micro_version=`$GLIB_CONFIG $glib_config_args --version | \
76
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
77
if test "x$enable_glibtest" = "xyes" ; then
78
ac_save_CFLAGS="$CFLAGS"
80
CFLAGS="$CFLAGS $GLIB_CFLAGS"
81
LIBS="$GLIB_LIBS $LIBS"
83
dnl Now check if the installed GLIB is sufficiently new. (Also sanity
84
dnl checks the results of glib-config to some extent
95
int major, minor, micro;
98
system ("touch conf.glibtest");
100
/* HP/UX 9 (%@#!) writes to sscanf strings */
101
tmp_version = g_strdup("$min_glib_version");
102
if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) {
103
printf("%s, bad version string\n", "$min_glib_version");
107
if ((glib_major_version != $glib_config_major_version) ||
108
(glib_minor_version != $glib_config_minor_version) ||
109
(glib_micro_version != $glib_config_micro_version))
111
printf("\n*** 'glib-config --version' returned %d.%d.%d, but GLIB (%d.%d.%d)\n",
112
$glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version,
113
glib_major_version, glib_minor_version, glib_micro_version);
114
printf ("*** was found! If glib-config was correct, then it is best\n");
115
printf ("*** to remove the old version of GLIB. You may also be able to fix the error\n");
116
printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
117
printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
118
printf("*** required on your system.\n");
119
printf("*** If glib-config was wrong, set the environment variable GLIB_CONFIG\n");
120
printf("*** to point to the correct copy of glib-config, and remove the file config.cache\n");
121
printf("*** before re-running configure\n");
123
else if ((glib_major_version != GLIB_MAJOR_VERSION) ||
124
(glib_minor_version != GLIB_MINOR_VERSION) ||
125
(glib_micro_version != GLIB_MICRO_VERSION))
127
printf("*** GLIB header files (version %d.%d.%d) do not match\n",
128
GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION);
129
printf("*** library (version %d.%d.%d)\n",
130
glib_major_version, glib_minor_version, glib_micro_version);
134
if ((glib_major_version > major) ||
135
((glib_major_version == major) && (glib_minor_version > minor)) ||
136
((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro)))
142
printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n",
143
glib_major_version, glib_minor_version, glib_micro_version);
144
printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n",
145
major, minor, micro);
146
printf("*** GLIB is always available from ftp://ftp.gtk.org.\n");
148
printf("*** If you have already installed a sufficiently new version, this error\n");
149
printf("*** probably means that the wrong copy of the glib-config shell script is\n");
150
printf("*** being found. The easiest way to fix this is to remove the old version\n");
151
printf("*** of GLIB, but you can also set the GLIB_CONFIG environment to point to the\n");
152
printf("*** correct copy of glib-config. (In this case, you will have to\n");
153
printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
154
printf("*** so that the correct libraries are found at run-time))\n");
159
],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
160
CFLAGS="$ac_save_CFLAGS"
164
if test "x$no_glib" = x ; then
166
ifelse([$2], , :, [$2])
169
if test "$GLIB_CONFIG" = "no" ; then
170
echo "*** The glib-config script installed by GLIB could not be found"
171
echo "*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in"
172
echo "*** your path, or set the GLIB_CONFIG environment variable to the"
173
echo "*** full path to glib-config."
175
if test -f conf.glibtest ; then
178
echo "*** Could not run GLIB test program, checking why..."
179
CFLAGS="$CFLAGS $GLIB_CFLAGS"
180
LIBS="$LIBS $GLIB_LIBS"
184
], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ],
185
[ echo "*** The test program compiled, but did not run. This usually means"
186
echo "*** that the run-time linker is not finding GLIB or finding the wrong"
187
echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your"
188
echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
189
echo "*** to the installed location Also, make sure you have run ldconfig if that"
190
echo "*** is required on your system"
192
echo "*** If you have an old version installed, it is best to remove it, although"
193
echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
195
echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that"
196
echo "*** came with the system with the command"
198
echo "*** rpm --erase --nodeps gtk gtk-devel" ],
199
[ echo "*** The test program failed to compile or link. See the file config.log for the"
200
echo "*** exact error that occured. This usually means GLIB was incorrectly installed"
201
echo "*** or that you have moved GLIB since it was installed. In the latter case, you"
202
echo "*** may want to edit the glib-config script: $GLIB_CONFIG" ])
203
CFLAGS="$ac_save_CFLAGS"
209
ifelse([$3], , :, [$3])
211
AC_SUBST(GLIB_CFLAGS)
216
19
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
218
# serial 48 AC_PROG_LIBTOOL
21
# serial 50 AC_PROG_LIBTOOL
221
24
# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
1450
1274
version_type=none
1451
1275
dynamic_linker="$host_os ld.so"
1452
1276
sys_lib_dlsearch_path_spec="/lib /usr/lib"
1453
1278
if test "$GCC" = yes; then
1454
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1455
if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
1280
darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
1281
*) lt_awk_arg="/^libraries:/" ;;
1283
lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1284
if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
1456
1285
# if the path contains ";" then we assume it to be the separator
1457
1286
# otherwise default to the standard path separator (i.e. ":") - it is
1458
1287
# assumed that no part of a normal pathname contains ";" but that should
1459
1288
# okay in the real world where ";" in dirpaths is itself problematic.
1460
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1289
lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
1462
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1291
lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1293
# Ok, now we have the path, separated by spaces, we can step through it
1294
# and add multilib dir if necessary.
1295
lt_tmp_lt_search_path_spec=
1296
lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
1297
for lt_sys_path in $lt_search_path_spec; do
1298
if test -d "$lt_sys_path/$lt_multi_os_dir"; then
1299
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
1301
test -d "$lt_sys_path" && \
1302
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
1305
lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
1306
BEGIN {RS=" "; FS="/|\n";} {
1309
for (lt_i = NF; lt_i > 0; lt_i--) {
1310
if ($lt_i != "" && $lt_i != ".") {
1311
if ($lt_i == "..") {
1314
if (lt_count == 0) {
1315
lt_foo="/" $lt_i lt_foo;
1322
if (lt_foo != "") { lt_freq[[lt_foo]]++; }
1323
if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
1325
sys_lib_search_path_spec=`echo $lt_search_path_spec`
1465
1327
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1467
1329
need_lib_prefix=unknown
1468
1330
hardcode_into_libs=no
7430
7385
rm -f confinc confmf
7388
# Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005
7389
# Free Software Foundation, Inc.
7391
# This file is free software; the Free Software Foundation
7392
# gives unlimited permission to copy and/or distribute it,
7393
# with or without modifications, as long as this notice is preserved.
7399
# Like AC_PROG_CC_C_O, but changed for automake.
7400
AC_DEFUN([AM_PROG_CC_C_O],
7401
[AC_REQUIRE([AC_PROG_CC_C_O])dnl
7402
AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
7403
AC_REQUIRE_AUX_FILE([compile])dnl
7404
# FIXME: we rely on the cache variable name because
7405
# there is no other way.
7407
ac_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']`
7408
if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" != yes"; then
7409
# Losing compiler, so override with the script.
7410
# FIXME: It is wrong to rewrite CC.
7411
# But if we don't then we get into trouble of one sort or another.
7412
# A longer-term fix would be to have automake use am__CC in this case,
7413
# and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
7414
CC="$am_aux_dir/compile $CC"
7416
dnl Make sure AC_PROG_CC is never called again, or it will override our
7418
m4_define([AC_PROG_CC],
7419
[m4_fatal([AC_PROG_CC cannot be called after AM_PROG_CC_C_O])])
7433
7422
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
7435
7424
# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005