~ubuntu-branches/ubuntu/precise/gnome-bluetooth/precise-updates

1.1.14 by Sebastien Bacher
Import upstream version 2.29.91
1
# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
2
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4
# 2005, 2006, 2007, 2008, 2009  Free Software Foundation, Inc.
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
5
# This file is free software; the Free Software Foundation
6
# gives unlimited permission to copy and/or distribute it,
7
# with or without modifications, as long as this notice is preserved.
1 by Daniel Holbach
Import upstream version 0.5.1
8
9
# This program is distributed in the hope that it will be useful,
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
10
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12
# PARTICULAR PURPOSE.
13
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
14
m4_ifndef([AC_AUTOCONF_VERSION],
15
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
16
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],,
17
[m4_warning([this file was generated for autoconf 2.68.
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
18
You have another version of autoconf.  It may work, but is not guaranteed to.
19
If you have problems, you may need to regenerate the build system entirely.
20
To do so, use the procedure documented by the package, typically `autoreconf'.])])
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
21
1.1.24 by Chris Coulson
Import upstream version 3.1.4
22
# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
23
#
24
# This file is free software; the Free Software Foundation
25
# gives unlimited permission to copy and/or distribute it,
26
# with or without modifications, as long as this notice is preserved.
27
28
# AM_AUTOMAKE_VERSION(VERSION)
29
# ----------------------------
30
# Automake X.Y traces this macro to ensure aclocal.m4 has been
31
# generated from the m4 files accompanying Automake X.Y.
32
# (This private macro should not be called outside this file.)
33
AC_DEFUN([AM_AUTOMAKE_VERSION],
34
[am__api_version='1.11'
35
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
36
dnl require some minimum version.  Point them to the right macro.
37
m4_if([$1], [1.11.1], [],
38
      [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
39
])
40
41
# _AM_AUTOCONF_VERSION(VERSION)
42
# -----------------------------
43
# aclocal traces this macro to find the Autoconf version.
44
# This is a private macro too.  Using m4_define simplifies
45
# the logic in aclocal, which can simply ignore this definition.
46
m4_define([_AM_AUTOCONF_VERSION], [])
47
48
# AM_SET_CURRENT_AUTOMAKE_VERSION
49
# -------------------------------
50
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
51
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
52
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
53
[AM_AUTOMAKE_VERSION([1.11.1])dnl
54
m4_ifndef([AC_AUTOCONF_VERSION],
55
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
56
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
57
58
# AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
59
60
# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
61
#
62
# This file is free software; the Free Software Foundation
63
# gives unlimited permission to copy and/or distribute it,
64
# with or without modifications, as long as this notice is preserved.
65
66
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
67
# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
68
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
69
#
70
# Of course, Automake must honor this variable whenever it calls a
71
# tool from the auxiliary directory.  The problem is that $srcdir (and
72
# therefore $ac_aux_dir as well) can be either absolute or relative,
73
# depending on how configure is run.  This is pretty annoying, since
74
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
75
# source directory, any form will work fine, but in subdirectories a
76
# relative path needs to be adjusted first.
77
#
78
# $ac_aux_dir/missing
79
#    fails when called from a subdirectory if $ac_aux_dir is relative
80
# $top_srcdir/$ac_aux_dir/missing
81
#    fails if $ac_aux_dir is absolute,
82
#    fails when called from a subdirectory in a VPATH build with
83
#          a relative $ac_aux_dir
84
#
85
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
86
# are both prefixed by $srcdir.  In an in-source build this is usually
87
# harmless because $srcdir is `.', but things will broke when you
88
# start a VPATH build or use an absolute $srcdir.
89
#
90
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
91
# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
92
#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
93
# and then we would define $MISSING as
94
#   MISSING="\${SHELL} $am_aux_dir/missing"
95
# This will work as long as MISSING is not called from configure, because
96
# unfortunately $(top_srcdir) has no meaning in configure.
97
# However there are other variables, like CC, which are often used in
98
# configure, and could therefore not use this "fixed" $ac_aux_dir.
99
#
100
# Another solution, used here, is to always expand $ac_aux_dir to an
101
# absolute PATH.  The drawback is that using absolute paths prevent a
102
# configured tree to be moved without reconfiguration.
103
104
AC_DEFUN([AM_AUX_DIR_EXPAND],
105
[dnl Rely on autoconf to set up CDPATH properly.
106
AC_PREREQ([2.50])dnl
107
# expand $ac_aux_dir to an absolute path
108
am_aux_dir=`cd $ac_aux_dir && pwd`
109
])
110
111
# AM_CONDITIONAL                                            -*- Autoconf -*-
112
113
# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
114
# Free Software Foundation, Inc.
115
#
116
# This file is free software; the Free Software Foundation
117
# gives unlimited permission to copy and/or distribute it,
118
# with or without modifications, as long as this notice is preserved.
119
120
# serial 9
121
122
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
123
# -------------------------------------
124
# Define a conditional.
125
AC_DEFUN([AM_CONDITIONAL],
126
[AC_PREREQ(2.52)dnl
127
 ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
128
	[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
129
AC_SUBST([$1_TRUE])dnl
130
AC_SUBST([$1_FALSE])dnl
131
_AM_SUBST_NOTMAKE([$1_TRUE])dnl
132
_AM_SUBST_NOTMAKE([$1_FALSE])dnl
133
m4_define([_AM_COND_VALUE_$1], [$2])dnl
134
if $2; then
135
  $1_TRUE=
136
  $1_FALSE='#'
137
else
138
  $1_TRUE='#'
139
  $1_FALSE=
140
fi
141
AC_CONFIG_COMMANDS_PRE(
142
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
143
  AC_MSG_ERROR([[conditional "$1" was never defined.
144
Usually this means the macro was only invoked conditionally.]])
145
fi])])
146
147
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
148
# Free Software Foundation, Inc.
149
#
150
# This file is free software; the Free Software Foundation
151
# gives unlimited permission to copy and/or distribute it,
152
# with or without modifications, as long as this notice is preserved.
153
154
# serial 10
155
156
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
157
# written in clear, in which case automake, when reading aclocal.m4,
158
# will think it sees a *use*, and therefore will trigger all it's
159
# C support machinery.  Also note that it means that autoscan, seeing
160
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
161
162
163
# _AM_DEPENDENCIES(NAME)
164
# ----------------------
165
# See how the compiler implements dependency checking.
166
# NAME is "CC", "CXX", "GCJ", or "OBJC".
167
# We try a few techniques and use that to set a single cache variable.
168
#
169
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
170
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
171
# dependency, and given that the user is not expected to run this macro,
172
# just rely on AC_PROG_CC.
173
AC_DEFUN([_AM_DEPENDENCIES],
174
[AC_REQUIRE([AM_SET_DEPDIR])dnl
175
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
176
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
177
AC_REQUIRE([AM_DEP_TRACK])dnl
178
179
ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
180
       [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
181
       [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
182
       [$1], UPC,  [depcc="$UPC"  am_compiler_list=],
183
       [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
184
                   [depcc="$$1"   am_compiler_list=])
185
186
AC_CACHE_CHECK([dependency style of $depcc],
187
               [am_cv_$1_dependencies_compiler_type],
188
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
189
  # We make a subdir and do the tests there.  Otherwise we can end up
190
  # making bogus files that we don't know about and never remove.  For
191
  # instance it was reported that on HP-UX the gcc test will end up
192
  # making a dummy file named `D' -- because `-MD' means `put the output
193
  # in D'.
194
  mkdir conftest.dir
195
  # Copy depcomp to subdir because otherwise we won't find it if we're
196
  # using a relative directory.
197
  cp "$am_depcomp" conftest.dir
198
  cd conftest.dir
199
  # We will build objects and dependencies in a subdirectory because
200
  # it helps to detect inapplicable dependency modes.  For instance
201
  # both Tru64's cc and ICC support -MD to output dependencies as a
202
  # side effect of compilation, but ICC will put the dependencies in
203
  # the current directory while Tru64 will put them in the object
204
  # directory.
205
  mkdir sub
206
207
  am_cv_$1_dependencies_compiler_type=none
208
  if test "$am_compiler_list" = ""; then
209
     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
210
  fi
211
  am__universal=false
212
  m4_case([$1], [CC],
213
    [case " $depcc " in #(
214
     *\ -arch\ *\ -arch\ *) am__universal=true ;;
215
     esac],
216
    [CXX],
217
    [case " $depcc " in #(
218
     *\ -arch\ *\ -arch\ *) am__universal=true ;;
219
     esac])
220
221
  for depmode in $am_compiler_list; do
222
    # Setup a source with many dependencies, because some compilers
223
    # like to wrap large dependency lists on column 80 (with \), and
224
    # we should not choose a depcomp mode which is confused by this.
225
    #
226
    # We need to recreate these files for each test, as the compiler may
227
    # overwrite some of them when testing with obscure command lines.
228
    # This happens at least with the AIX C compiler.
229
    : > sub/conftest.c
230
    for i in 1 2 3 4 5 6; do
231
      echo '#include "conftst'$i'.h"' >> sub/conftest.c
232
      # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
233
      # Solaris 8's {/usr,}/bin/sh.
234
      touch sub/conftst$i.h
235
    done
236
    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
237
238
    # We check with `-c' and `-o' for the sake of the "dashmstdout"
239
    # mode.  It turns out that the SunPro C++ compiler does not properly
240
    # handle `-M -o', and we need to detect this.  Also, some Intel
241
    # versions had trouble with output in subdirs
242
    am__obj=sub/conftest.${OBJEXT-o}
243
    am__minus_obj="-o $am__obj"
244
    case $depmode in
245
    gcc)
246
      # This depmode causes a compiler race in universal mode.
247
      test "$am__universal" = false || continue
248
      ;;
249
    nosideeffect)
250
      # after this tag, mechanisms are not by side-effect, so they'll
251
      # only be used when explicitly requested
252
      if test "x$enable_dependency_tracking" = xyes; then
253
	continue
254
      else
255
	break
256
      fi
257
      ;;
258
    msvisualcpp | msvcmsys)
259
      # This compiler won't grok `-c -o', but also, the minuso test has
260
      # not run yet.  These depmodes are late enough in the game, and
261
      # so weak that their functioning should not be impacted.
262
      am__obj=conftest.${OBJEXT-o}
263
      am__minus_obj=
264
      ;;
265
    none) break ;;
266
    esac
267
    if depmode=$depmode \
268
       source=sub/conftest.c object=$am__obj \
269
       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
270
       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
271
         >/dev/null 2>conftest.err &&
272
       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
273
       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
274
       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
275
       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
276
      # icc doesn't choke on unknown options, it will just issue warnings
277
      # or remarks (even with -Werror).  So we grep stderr for any message
278
      # that says an option was ignored or not supported.
279
      # When given -MP, icc 7.0 and 7.1 complain thusly:
280
      #   icc: Command line warning: ignoring option '-M'; no argument required
281
      # The diagnosis changed in icc 8.0:
282
      #   icc: Command line remark: option '-MP' not supported
283
      if (grep 'ignoring option' conftest.err ||
284
          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
285
        am_cv_$1_dependencies_compiler_type=$depmode
286
        break
287
      fi
288
    fi
289
  done
290
291
  cd ..
292
  rm -rf conftest.dir
293
else
294
  am_cv_$1_dependencies_compiler_type=none
295
fi
296
])
297
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
298
AM_CONDITIONAL([am__fastdep$1], [
299
  test "x$enable_dependency_tracking" != xno \
300
  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
301
])
302
303
304
# AM_SET_DEPDIR
305
# -------------
306
# Choose a directory name for dependency files.
307
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
308
AC_DEFUN([AM_SET_DEPDIR],
309
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
310
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
311
])
312
313
314
# AM_DEP_TRACK
315
# ------------
316
AC_DEFUN([AM_DEP_TRACK],
317
[AC_ARG_ENABLE(dependency-tracking,
318
[  --disable-dependency-tracking  speeds up one-time build
319
  --enable-dependency-tracking   do not reject slow dependency extractors])
320
if test "x$enable_dependency_tracking" != xno; then
321
  am_depcomp="$ac_aux_dir/depcomp"
322
  AMDEPBACKSLASH='\'
323
fi
324
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
325
AC_SUBST([AMDEPBACKSLASH])dnl
326
_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
327
])
328
329
# Generate code to set up dependency tracking.              -*- Autoconf -*-
330
331
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
332
# Free Software Foundation, Inc.
333
#
334
# This file is free software; the Free Software Foundation
335
# gives unlimited permission to copy and/or distribute it,
336
# with or without modifications, as long as this notice is preserved.
337
338
#serial 5
339
340
# _AM_OUTPUT_DEPENDENCY_COMMANDS
341
# ------------------------------
342
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
343
[{
344
  # Autoconf 2.62 quotes --file arguments for eval, but not when files
345
  # are listed without --file.  Let's play safe and only enable the eval
346
  # if we detect the quoting.
347
  case $CONFIG_FILES in
348
  *\'*) eval set x "$CONFIG_FILES" ;;
349
  *)   set x $CONFIG_FILES ;;
350
  esac
351
  shift
352
  for mf
353
  do
354
    # Strip MF so we end up with the name of the file.
355
    mf=`echo "$mf" | sed -e 's/:.*$//'`
356
    # Check whether this is an Automake generated Makefile or not.
357
    # We used to match only the files named `Makefile.in', but
358
    # some people rename them; so instead we look at the file content.
359
    # Grep'ing the first line is not enough: some people post-process
360
    # each Makefile.in and add a new line on top of each file to say so.
361
    # Grep'ing the whole file is not good either: AIX grep has a line
362
    # limit of 2048, but all sed's we know have understand at least 4000.
363
    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
364
      dirpart=`AS_DIRNAME("$mf")`
365
    else
366
      continue
367
    fi
368
    # Extract the definition of DEPDIR, am__include, and am__quote
369
    # from the Makefile without running `make'.
370
    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
371
    test -z "$DEPDIR" && continue
372
    am__include=`sed -n 's/^am__include = //p' < "$mf"`
373
    test -z "am__include" && continue
374
    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
375
    # When using ansi2knr, U may be empty or an underscore; expand it
376
    U=`sed -n 's/^U = //p' < "$mf"`
377
    # Find all dependency output files, they are included files with
378
    # $(DEPDIR) in their names.  We invoke sed twice because it is the
379
    # simplest approach to changing $(DEPDIR) to its actual value in the
380
    # expansion.
381
    for file in `sed -n "
382
      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
383
	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
384
      # Make sure the directory exists.
385
      test -f "$dirpart/$file" && continue
386
      fdir=`AS_DIRNAME(["$file"])`
387
      AS_MKDIR_P([$dirpart/$fdir])
388
      # echo "creating $dirpart/$file"
389
      echo '# dummy' > "$dirpart/$file"
390
    done
391
  done
392
}
393
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
394
395
396
# AM_OUTPUT_DEPENDENCY_COMMANDS
397
# -----------------------------
398
# This macro should only be invoked once -- use via AC_REQUIRE.
399
#
400
# This code is only required when automatic dependency tracking
401
# is enabled.  FIXME.  This creates each `.P' file that we will
402
# need in order to bootstrap the dependency handling code.
403
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
404
[AC_CONFIG_COMMANDS([depfiles],
405
     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
406
     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
407
])
408
409
# Do all the work for Automake.                             -*- Autoconf -*-
410
411
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
412
# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
413
#
414
# This file is free software; the Free Software Foundation
415
# gives unlimited permission to copy and/or distribute it,
416
# with or without modifications, as long as this notice is preserved.
417
418
# serial 16
419
420
# This macro actually does too much.  Some checks are only needed if
421
# your package does certain things.  But this isn't really a big deal.
422
423
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
424
# AM_INIT_AUTOMAKE([OPTIONS])
425
# -----------------------------------------------
426
# The call with PACKAGE and VERSION arguments is the old style
427
# call (pre autoconf-2.50), which is being phased out.  PACKAGE
428
# and VERSION should now be passed to AC_INIT and removed from
429
# the call to AM_INIT_AUTOMAKE.
430
# We support both call styles for the transition.  After
431
# the next Automake release, Autoconf can make the AC_INIT
432
# arguments mandatory, and then we can depend on a new Autoconf
433
# release and drop the old call support.
434
AC_DEFUN([AM_INIT_AUTOMAKE],
435
[AC_PREREQ([2.62])dnl
436
dnl Autoconf wants to disallow AM_ names.  We explicitly allow
437
dnl the ones we care about.
438
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
439
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
440
AC_REQUIRE([AC_PROG_INSTALL])dnl
441
if test "`cd $srcdir && pwd`" != "`pwd`"; then
442
  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
443
  # is not polluted with repeated "-I."
444
  AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
445
  # test to see if srcdir already configured
446
  if test -f $srcdir/config.status; then
447
    AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
448
  fi
449
fi
450
451
# test whether we have cygpath
452
if test -z "$CYGPATH_W"; then
453
  if (cygpath --version) >/dev/null 2>/dev/null; then
454
    CYGPATH_W='cygpath -w'
455
  else
456
    CYGPATH_W=echo
457
  fi
458
fi
459
AC_SUBST([CYGPATH_W])
460
461
# Define the identity of the package.
462
dnl Distinguish between old-style and new-style calls.
463
m4_ifval([$2],
464
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
465
 AC_SUBST([PACKAGE], [$1])dnl
466
 AC_SUBST([VERSION], [$2])],
467
[_AM_SET_OPTIONS([$1])dnl
468
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
469
m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
470
  [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
471
 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
472
 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
473
474
_AM_IF_OPTION([no-define],,
475
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
476
 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
477
478
# Some tools Automake needs.
479
AC_REQUIRE([AM_SANITY_CHECK])dnl
480
AC_REQUIRE([AC_ARG_PROGRAM])dnl
481
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
482
AM_MISSING_PROG(AUTOCONF, autoconf)
483
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
484
AM_MISSING_PROG(AUTOHEADER, autoheader)
485
AM_MISSING_PROG(MAKEINFO, makeinfo)
486
AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
487
AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
488
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
489
# We need awk for the "check" target.  The system "awk" is bad on
490
# some platforms.
491
AC_REQUIRE([AC_PROG_AWK])dnl
492
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
493
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
494
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
495
	      [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
496
			     [_AM_PROG_TAR([v7])])])
497
_AM_IF_OPTION([no-dependencies],,
498
[AC_PROVIDE_IFELSE([AC_PROG_CC],
499
		  [_AM_DEPENDENCIES(CC)],
500
		  [define([AC_PROG_CC],
501
			  defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
502
AC_PROVIDE_IFELSE([AC_PROG_CXX],
503
		  [_AM_DEPENDENCIES(CXX)],
504
		  [define([AC_PROG_CXX],
505
			  defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
506
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
507
		  [_AM_DEPENDENCIES(OBJC)],
508
		  [define([AC_PROG_OBJC],
509
			  defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
510
])
511
_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
512
dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
513
dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
514
dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
515
AC_CONFIG_COMMANDS_PRE(dnl
516
[m4_provide_if([_AM_COMPILER_EXEEXT],
517
  [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
518
])
519
520
dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
521
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
522
dnl mangled by Autoconf and run in a shell conditional statement.
523
m4_define([_AC_COMPILER_EXEEXT],
524
m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
525
526
527
# When config.status generates a header, we must update the stamp-h file.
528
# This file resides in the same directory as the config header
529
# that is generated.  The stamp files are numbered to have different names.
530
531
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
532
# loop where config.status creates the headers, so we can generate
533
# our stamp files there.
534
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
535
[# Compute $1's index in $config_headers.
536
_am_arg=$1
537
_am_stamp_count=1
538
for _am_header in $config_headers :; do
539
  case $_am_header in
540
    $_am_arg | $_am_arg:* )
541
      break ;;
542
    * )
543
      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
544
  esac
545
done
546
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
547
548
# Copyright (C) 2001, 2003, 2005, 2008  Free Software Foundation, Inc.
549
#
550
# This file is free software; the Free Software Foundation
551
# gives unlimited permission to copy and/or distribute it,
552
# with or without modifications, as long as this notice is preserved.
553
554
# AM_PROG_INSTALL_SH
555
# ------------------
556
# Define $install_sh.
557
AC_DEFUN([AM_PROG_INSTALL_SH],
558
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
559
if test x"${install_sh}" != xset; then
560
  case $am_aux_dir in
561
  *\ * | *\	*)
562
    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
563
  *)
564
    install_sh="\${SHELL} $am_aux_dir/install-sh"
565
  esac
566
fi
567
AC_SUBST(install_sh)])
568
569
# Copyright (C) 2003, 2005  Free Software Foundation, Inc.
570
#
571
# This file is free software; the Free Software Foundation
572
# gives unlimited permission to copy and/or distribute it,
573
# with or without modifications, as long as this notice is preserved.
574
575
# serial 2
576
577
# Check whether the underlying file-system supports filenames
578
# with a leading dot.  For instance MS-DOS doesn't.
579
AC_DEFUN([AM_SET_LEADING_DOT],
580
[rm -rf .tst 2>/dev/null
581
mkdir .tst 2>/dev/null
582
if test -d .tst; then
583
  am__leading_dot=.
584
else
585
  am__leading_dot=_
586
fi
587
rmdir .tst 2>/dev/null
588
AC_SUBST([am__leading_dot])])
589
590
# Add --enable-maintainer-mode option to configure.         -*- Autoconf -*-
591
# From Jim Meyering
592
593
# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008
594
# Free Software Foundation, Inc.
595
#
596
# This file is free software; the Free Software Foundation
597
# gives unlimited permission to copy and/or distribute it,
598
# with or without modifications, as long as this notice is preserved.
599
600
# serial 5
601
602
# AM_MAINTAINER_MODE([DEFAULT-MODE])
603
# ----------------------------------
604
# Control maintainer-specific portions of Makefiles.
605
# Default is to disable them, unless `enable' is passed literally.
606
# For symmetry, `disable' may be passed as well.  Anyway, the user
607
# can override the default with the --enable/--disable switch.
608
AC_DEFUN([AM_MAINTAINER_MODE],
609
[m4_case(m4_default([$1], [disable]),
610
       [enable], [m4_define([am_maintainer_other], [disable])],
611
       [disable], [m4_define([am_maintainer_other], [enable])],
612
       [m4_define([am_maintainer_other], [enable])
613
        m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
614
AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles])
615
  dnl maintainer-mode's default is 'disable' unless 'enable' is passed
616
  AC_ARG_ENABLE([maintainer-mode],
617
[  --][am_maintainer_other][-maintainer-mode  am_maintainer_other make rules and dependencies not useful
618
			  (and sometimes confusing) to the casual installer],
619
      [USE_MAINTAINER_MODE=$enableval],
620
      [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
621
  AC_MSG_RESULT([$USE_MAINTAINER_MODE])
622
  AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
623
  MAINT=$MAINTAINER_MODE_TRUE
624
  AC_SUBST([MAINT])dnl
625
]
626
)
627
628
AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
629
630
# Check to see how 'make' treats includes.	            -*- Autoconf -*-
631
632
# Copyright (C) 2001, 2002, 2003, 2005, 2009  Free Software Foundation, Inc.
633
#
634
# This file is free software; the Free Software Foundation
635
# gives unlimited permission to copy and/or distribute it,
636
# with or without modifications, as long as this notice is preserved.
637
638
# serial 4
639
640
# AM_MAKE_INCLUDE()
641
# -----------------
642
# Check to see how make treats includes.
643
AC_DEFUN([AM_MAKE_INCLUDE],
644
[am_make=${MAKE-make}
645
cat > confinc << 'END'
646
am__doit:
647
	@echo this is the am__doit target
648
.PHONY: am__doit
649
END
650
# If we don't find an include directive, just comment out the code.
651
AC_MSG_CHECKING([for style of include used by $am_make])
652
am__include="#"
653
am__quote=
654
_am_result=none
655
# First try GNU make style include.
656
echo "include confinc" > confmf
657
# Ignore all kinds of additional output from `make'.
658
case `$am_make -s -f confmf 2> /dev/null` in #(
659
*the\ am__doit\ target*)
660
  am__include=include
661
  am__quote=
662
  _am_result=GNU
663
  ;;
664
esac
665
# Now try BSD make style include.
666
if test "$am__include" = "#"; then
667
   echo '.include "confinc"' > confmf
668
   case `$am_make -s -f confmf 2> /dev/null` in #(
669
   *the\ am__doit\ target*)
670
     am__include=.include
671
     am__quote="\""
672
     _am_result=BSD
673
     ;;
674
   esac
675
fi
676
AC_SUBST([am__include])
677
AC_SUBST([am__quote])
678
AC_MSG_RESULT([$_am_result])
679
rm -f confinc confmf
680
])
681
682
# Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
683
684
# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
685
# Free Software Foundation, Inc.
686
#
687
# This file is free software; the Free Software Foundation
688
# gives unlimited permission to copy and/or distribute it,
689
# with or without modifications, as long as this notice is preserved.
690
691
# serial 6
692
693
# AM_MISSING_PROG(NAME, PROGRAM)
694
# ------------------------------
695
AC_DEFUN([AM_MISSING_PROG],
696
[AC_REQUIRE([AM_MISSING_HAS_RUN])
697
$1=${$1-"${am_missing_run}$2"}
698
AC_SUBST($1)])
699
700
701
# AM_MISSING_HAS_RUN
702
# ------------------
703
# Define MISSING if not defined so far and test if it supports --run.
704
# If it does, set am_missing_run to use it, otherwise, to nothing.
705
AC_DEFUN([AM_MISSING_HAS_RUN],
706
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
707
AC_REQUIRE_AUX_FILE([missing])dnl
708
if test x"${MISSING+set}" != xset; then
709
  case $am_aux_dir in
710
  *\ * | *\	*)
711
    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
712
  *)
713
    MISSING="\${SHELL} $am_aux_dir/missing" ;;
714
  esac
715
fi
716
# Use eval to expand $SHELL
717
if eval "$MISSING --run true"; then
718
  am_missing_run="$MISSING --run "
719
else
720
  am_missing_run=
721
  AC_MSG_WARN([`missing' script is too old or missing])
722
fi
723
])
724
725
# Copyright (C) 2003, 2004, 2005, 2006  Free Software Foundation, Inc.
726
#
727
# This file is free software; the Free Software Foundation
728
# gives unlimited permission to copy and/or distribute it,
729
# with or without modifications, as long as this notice is preserved.
730
731
# AM_PROG_MKDIR_P
732
# ---------------
733
# Check for `mkdir -p'.
734
AC_DEFUN([AM_PROG_MKDIR_P],
735
[AC_PREREQ([2.60])dnl
736
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
737
dnl Automake 1.8 to 1.9.6 used to define mkdir_p.  We now use MKDIR_P,
738
dnl while keeping a definition of mkdir_p for backward compatibility.
739
dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
740
dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
741
dnl Makefile.ins that do not define MKDIR_P, so we do our own
742
dnl adjustment using top_builddir (which is defined more often than
743
dnl MKDIR_P).
744
AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
745
case $mkdir_p in
746
  [[\\/$]]* | ?:[[\\/]]*) ;;
747
  */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
748
esac
749
])
750
751
# Helper functions for option handling.                     -*- Autoconf -*-
752
753
# Copyright (C) 2001, 2002, 2003, 2005, 2008  Free Software Foundation, Inc.
754
#
755
# This file is free software; the Free Software Foundation
756
# gives unlimited permission to copy and/or distribute it,
757
# with or without modifications, as long as this notice is preserved.
758
759
# serial 4
760
761
# _AM_MANGLE_OPTION(NAME)
762
# -----------------------
763
AC_DEFUN([_AM_MANGLE_OPTION],
764
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
765
766
# _AM_SET_OPTION(NAME)
767
# ------------------------------
768
# Set option NAME.  Presently that only means defining a flag for this option.
769
AC_DEFUN([_AM_SET_OPTION],
770
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
771
772
# _AM_SET_OPTIONS(OPTIONS)
773
# ----------------------------------
774
# OPTIONS is a space-separated list of Automake options.
775
AC_DEFUN([_AM_SET_OPTIONS],
776
[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
777
778
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
779
# -------------------------------------------
780
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
781
AC_DEFUN([_AM_IF_OPTION],
782
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
783
784
# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
785
#
786
# This file is free software; the Free Software Foundation
787
# gives unlimited permission to copy and/or distribute it,
788
# with or without modifications, as long as this notice is preserved.
789
790
# AM_RUN_LOG(COMMAND)
791
# -------------------
792
# Run COMMAND, save the exit status in ac_status, and log it.
793
# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
794
AC_DEFUN([AM_RUN_LOG],
795
[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
796
   ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
797
   ac_status=$?
798
   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
799
   (exit $ac_status); }])
800
801
# Check to make sure that the build environment is sane.    -*- Autoconf -*-
802
803
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
804
# Free Software Foundation, Inc.
805
#
806
# This file is free software; the Free Software Foundation
807
# gives unlimited permission to copy and/or distribute it,
808
# with or without modifications, as long as this notice is preserved.
809
810
# serial 5
811
812
# AM_SANITY_CHECK
813
# ---------------
814
AC_DEFUN([AM_SANITY_CHECK],
815
[AC_MSG_CHECKING([whether build environment is sane])
816
# Just in case
817
sleep 1
818
echo timestamp > conftest.file
819
# Reject unsafe characters in $srcdir or the absolute working directory
820
# name.  Accept space and tab only in the latter.
821
am_lf='
822
'
823
case `pwd` in
824
  *[[\\\"\#\$\&\'\`$am_lf]]*)
825
    AC_MSG_ERROR([unsafe absolute working directory name]);;
826
esac
827
case $srcdir in
828
  *[[\\\"\#\$\&\'\`$am_lf\ \	]]*)
829
    AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
830
esac
831
832
# Do `set' in a subshell so we don't clobber the current shell's
833
# arguments.  Must try -L first in case configure is actually a
834
# symlink; some systems play weird games with the mod time of symlinks
835
# (eg FreeBSD returns the mod time of the symlink's containing
836
# directory).
837
if (
838
   set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
839
   if test "$[*]" = "X"; then
840
      # -L didn't work.
841
      set X `ls -t "$srcdir/configure" conftest.file`
842
   fi
843
   rm -f conftest.file
844
   if test "$[*]" != "X $srcdir/configure conftest.file" \
845
      && test "$[*]" != "X conftest.file $srcdir/configure"; then
846
847
      # If neither matched, then we have a broken ls.  This can happen
848
      # if, for instance, CONFIG_SHELL is bash and it inherits a
849
      # broken ls alias from the environment.  This has actually
850
      # happened.  Such a system could not be considered "sane".
851
      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
852
alias in your environment])
853
   fi
854
855
   test "$[2]" = conftest.file
856
   )
857
then
858
   # Ok.
859
   :
860
else
861
   AC_MSG_ERROR([newly created file is older than distributed files!
862
Check your system clock])
863
fi
864
AC_MSG_RESULT(yes)])
865
866
# Copyright (C) 2009  Free Software Foundation, Inc.
867
#
868
# This file is free software; the Free Software Foundation
869
# gives unlimited permission to copy and/or distribute it,
870
# with or without modifications, as long as this notice is preserved.
871
872
# serial 1
873
874
# AM_SILENT_RULES([DEFAULT])
875
# --------------------------
876
# Enable less verbose build rules; with the default set to DEFAULT
877
# (`yes' being less verbose, `no' or empty being verbose).
878
AC_DEFUN([AM_SILENT_RULES],
879
[AC_ARG_ENABLE([silent-rules],
880
[  --enable-silent-rules          less verbose build output (undo: `make V=1')
881
  --disable-silent-rules         verbose build output (undo: `make V=0')])
882
case $enable_silent_rules in
883
yes) AM_DEFAULT_VERBOSITY=0;;
884
no)  AM_DEFAULT_VERBOSITY=1;;
885
*)   AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
886
esac
887
AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
888
AM_BACKSLASH='\'
889
AC_SUBST([AM_BACKSLASH])dnl
890
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
891
])
892
893
# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
894
#
895
# This file is free software; the Free Software Foundation
896
# gives unlimited permission to copy and/or distribute it,
897
# with or without modifications, as long as this notice is preserved.
898
899
# AM_PROG_INSTALL_STRIP
900
# ---------------------
901
# One issue with vendor `install' (even GNU) is that you can't
902
# specify the program used to strip binaries.  This is especially
903
# annoying in cross-compiling environments, where the build's strip
904
# is unlikely to handle the host's binaries.
905
# Fortunately install-sh will honor a STRIPPROG variable, so we
906
# always use install-sh in `make install-strip', and initialize
907
# STRIPPROG with the value of the STRIP variable (set by the user).
908
AC_DEFUN([AM_PROG_INSTALL_STRIP],
909
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
910
# Installed binaries are usually stripped using `strip' when the user
911
# run `make install-strip'.  However `strip' might not be the right
912
# tool to use in cross-compilation environments, therefore Automake
913
# will honor the `STRIP' environment variable to overrule this program.
914
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
915
if test "$cross_compiling" != no; then
916
  AC_CHECK_TOOL([STRIP], [strip], :)
917
fi
918
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
919
AC_SUBST([INSTALL_STRIP_PROGRAM])])
920
921
# Copyright (C) 2006, 2008  Free Software Foundation, Inc.
922
#
923
# This file is free software; the Free Software Foundation
924
# gives unlimited permission to copy and/or distribute it,
925
# with or without modifications, as long as this notice is preserved.
926
927
# serial 2
928
929
# _AM_SUBST_NOTMAKE(VARIABLE)
930
# ---------------------------
931
# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
932
# This macro is traced by Automake.
933
AC_DEFUN([_AM_SUBST_NOTMAKE])
934
935
# AM_SUBST_NOTMAKE(VARIABLE)
936
# ---------------------------
937
# Public sister of _AM_SUBST_NOTMAKE.
938
AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
939
940
# Check how to create a tarball.                            -*- Autoconf -*-
941
942
# Copyright (C) 2004, 2005  Free Software Foundation, Inc.
943
#
944
# This file is free software; the Free Software Foundation
945
# gives unlimited permission to copy and/or distribute it,
946
# with or without modifications, as long as this notice is preserved.
947
948
# serial 2
949
950
# _AM_PROG_TAR(FORMAT)
951
# --------------------
952
# Check how to create a tarball in format FORMAT.
953
# FORMAT should be one of `v7', `ustar', or `pax'.
954
#
955
# Substitute a variable $(am__tar) that is a command
956
# writing to stdout a FORMAT-tarball containing the directory
957
# $tardir.
958
#     tardir=directory && $(am__tar) > result.tar
959
#
960
# Substitute a variable $(am__untar) that extract such
961
# a tarball read from stdin.
962
#     $(am__untar) < result.tar
963
AC_DEFUN([_AM_PROG_TAR],
964
[# Always define AMTAR for backward compatibility.
965
AM_MISSING_PROG([AMTAR], [tar])
966
m4_if([$1], [v7],
967
     [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
968
     [m4_case([$1], [ustar],, [pax],,
969
              [m4_fatal([Unknown tar format])])
970
AC_MSG_CHECKING([how to create a $1 tar archive])
971
# Loop over all known methods to create a tar archive until one works.
972
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
973
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
974
# Do not fold the above two line into one, because Tru64 sh and
975
# Solaris sh will not grok spaces in the rhs of `-'.
976
for _am_tool in $_am_tools
977
do
978
  case $_am_tool in
979
  gnutar)
980
    for _am_tar in tar gnutar gtar;
981
    do
982
      AM_RUN_LOG([$_am_tar --version]) && break
983
    done
984
    am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
985
    am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
986
    am__untar="$_am_tar -xf -"
987
    ;;
988
  plaintar)
989
    # Must skip GNU tar: if it does not support --format= it doesn't create
990
    # ustar tarball either.
991
    (tar --version) >/dev/null 2>&1 && continue
992
    am__tar='tar chf - "$$tardir"'
993
    am__tar_='tar chf - "$tardir"'
994
    am__untar='tar xf -'
995
    ;;
996
  pax)
997
    am__tar='pax -L -x $1 -w "$$tardir"'
998
    am__tar_='pax -L -x $1 -w "$tardir"'
999
    am__untar='pax -r'
1000
    ;;
1001
  cpio)
1002
    am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
1003
    am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
1004
    am__untar='cpio -i -H $1 -d'
1005
    ;;
1006
  none)
1007
    am__tar=false
1008
    am__tar_=false
1009
    am__untar=false
1010
    ;;
1011
  esac
1012
1013
  # If the value was cached, stop now.  We just wanted to have am__tar
1014
  # and am__untar set.
1015
  test -n "${am_cv_prog_tar_$1}" && break
1016
1017
  # tar/untar a dummy directory, and stop if the command works
1018
  rm -rf conftest.dir
1019
  mkdir conftest.dir
1020
  echo GrepMe > conftest.dir/file
1021
  AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
1022
  rm -rf conftest.dir
1023
  if test -s conftest.tar; then
1024
    AM_RUN_LOG([$am__untar <conftest.tar])
1025
    grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
1026
  fi
1027
done
1028
rm -rf conftest.dir
1029
1030
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
1031
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
1032
AC_SUBST([am__tar])
1033
AC_SUBST([am__untar])
1034
]) # _AM_PROG_TAR
1035
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1036
# gettext.m4 serial 63 (gettext-0.18)
1037
dnl Copyright (C) 1995-2010 Free Software Foundation, Inc.
1038
dnl This file is free software; the Free Software Foundation
1039
dnl gives unlimited permission to copy and/or distribute it,
1040
dnl with or without modifications, as long as this notice is preserved.
1041
dnl
1042
dnl This file can can be used in projects which are not available under
1043
dnl the GNU General Public License or the GNU Library General Public
1044
dnl License but which still want to provide support for the GNU gettext
1045
dnl functionality.
1046
dnl Please note that the actual code of the GNU gettext library is covered
1047
dnl by the GNU Library General Public License, and the rest of the GNU
1048
dnl gettext package package is covered by the GNU General Public License.
1049
dnl They are *not* in the public domain.
1050
1051
dnl Authors:
1052
dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
1053
dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2006, 2008-2010.
1054
1055
dnl Macro to add for using GNU gettext.
1056
1057
dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]).
1058
dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The
1059
dnl    default (if it is not specified or empty) is 'no-libtool'.
1060
dnl    INTLSYMBOL should be 'external' for packages with no intl directory,
1061
dnl    and 'no-libtool' or 'use-libtool' for packages with an intl directory.
1062
dnl    If INTLSYMBOL is 'use-libtool', then a libtool library
1063
dnl    $(top_builddir)/intl/libintl.la will be created (shared and/or static,
1064
dnl    depending on --{enable,disable}-{shared,static} and on the presence of
1065
dnl    AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library
1066
dnl    $(top_builddir)/intl/libintl.a will be created.
1067
dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext
1068
dnl    implementations (in libc or libintl) without the ngettext() function
1069
dnl    will be ignored.  If NEEDSYMBOL is specified and is
1070
dnl    'need-formatstring-macros', then GNU gettext implementations that don't
1071
dnl    support the ISO C 99 <inttypes.h> formatstring macros will be ignored.
1072
dnl INTLDIR is used to find the intl libraries.  If empty,
1073
dnl    the value `$(top_builddir)/intl/' is used.
1074
dnl
1075
dnl The result of the configuration is one of three cases:
1076
dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled
1077
dnl    and used.
1078
dnl    Catalog format: GNU --> install in $(datadir)
1079
dnl    Catalog extension: .mo after installation, .gmo in source tree
1080
dnl 2) GNU gettext has been found in the system's C library.
1081
dnl    Catalog format: GNU --> install in $(datadir)
1082
dnl    Catalog extension: .mo after installation, .gmo in source tree
1083
dnl 3) No internationalization, always use English msgid.
1084
dnl    Catalog format: none
1085
dnl    Catalog extension: none
1086
dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur.
1087
dnl The use of .gmo is historical (it was needed to avoid overwriting the
1088
dnl GNU format catalogs when building on a platform with an X/Open gettext),
1089
dnl but we keep it in order not to force irrelevant filename changes on the
1090
dnl maintainers.
1091
dnl
1092
AC_DEFUN([AM_GNU_GETTEXT],
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
1093
[
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1094
  dnl Argument checking.
1095
  ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], ,
1096
    [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT
1097
])])])])])
1098
  ifelse(ifelse([$1], [], [old])[]ifelse([$1], [no-libtool], [old]), [old],
1099
    [AC_DIAGNOSE([obsolete], [Use of AM_GNU_GETTEXT without [external] argument is deprecated.])])
1100
  ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], ,
1101
    [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT
1102
])])])])
1103
  define([gt_included_intl],
1104
    ifelse([$1], [external],
1105
      ifdef([AM_GNU_GETTEXT_][INTL_SUBDIR], [yes], [no]),
1106
      [yes]))
1107
  define([gt_libtool_suffix_prefix], ifelse([$1], [use-libtool], [l], []))
1108
  gt_NEEDS_INIT
1109
  AM_GNU_GETTEXT_NEED([$2])
1110
1111
  AC_REQUIRE([AM_PO_SUBDIRS])dnl
1112
  ifelse(gt_included_intl, yes, [
1113
    AC_REQUIRE([AM_INTL_SUBDIR])dnl
1114
  ])
1115
1116
  dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
1117
  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
1118
  AC_REQUIRE([AC_LIB_RPATH])
1119
1120
  dnl Sometimes libintl requires libiconv, so first search for libiconv.
1121
  dnl Ideally we would do this search only after the
1122
  dnl      if test "$USE_NLS" = "yes"; then
1123
  dnl        if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
1124
  dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT
1125
  dnl the configure script would need to contain the same shell code
1126
  dnl again, outside any 'if'. There are two solutions:
1127
  dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'.
1128
  dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE.
1129
  dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not
1130
  dnl documented, we avoid it.
1131
  ifelse(gt_included_intl, yes, , [
1132
    AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
1133
  ])
1134
1135
  dnl Sometimes, on MacOS X, libintl requires linking with CoreFoundation.
1136
  gt_INTL_MACOSX
1137
1138
  dnl Set USE_NLS.
1139
  AC_REQUIRE([AM_NLS])
1140
1141
  ifelse(gt_included_intl, yes, [
1142
    BUILD_INCLUDED_LIBINTL=no
1143
    USE_INCLUDED_LIBINTL=no
1144
  ])
1145
  LIBINTL=
1146
  LTLIBINTL=
1147
  POSUB=
1148
1149
  dnl Add a version number to the cache macros.
1150
  case " $gt_needs " in
1151
    *" need-formatstring-macros "*) gt_api_version=3 ;;
1152
    *" need-ngettext "*) gt_api_version=2 ;;
1153
    *) gt_api_version=1 ;;
1154
  esac
1155
  gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
1156
  gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
1157
1158
  dnl If we use NLS figure out what method
1159
  if test "$USE_NLS" = "yes"; then
1160
    gt_use_preinstalled_gnugettext=no
1161
    ifelse(gt_included_intl, yes, [
1162
      AC_MSG_CHECKING([whether included gettext is requested])
1163
      AC_ARG_WITH([included-gettext],
1164
        [  --with-included-gettext use the GNU gettext library included here],
1165
        nls_cv_force_use_gnu_gettext=$withval,
1166
        nls_cv_force_use_gnu_gettext=no)
1167
      AC_MSG_RESULT([$nls_cv_force_use_gnu_gettext])
1168
1169
      nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
1170
      if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
1171
    ])
1172
        dnl User does not insist on using GNU NLS library.  Figure out what
1173
        dnl to use.  If GNU gettext is available we use this.  Else we have
1174
        dnl to fall back to GNU NLS library.
1175
1176
        if test $gt_api_version -ge 3; then
1177
          gt_revision_test_code='
1178
#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
1179
#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
1180
#endif
1181
changequote(,)dnl
1182
typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
1183
changequote([,])dnl
1184
'
1185
        else
1186
          gt_revision_test_code=
1187
        fi
1188
        if test $gt_api_version -ge 2; then
1189
          gt_expression_test_code=' + * ngettext ("", "", 0)'
1190
        else
1191
          gt_expression_test_code=
1192
        fi
1193
1194
        AC_CACHE_CHECK([for GNU gettext in libc], [$gt_func_gnugettext_libc],
1195
         [AC_TRY_LINK([#include <libintl.h>
1196
$gt_revision_test_code
1197
extern int _nl_msg_cat_cntr;
1198
extern int *_nl_domain_bindings;],
1199
            [bindtextdomain ("", "");
1200
return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings],
1201
            [eval "$gt_func_gnugettext_libc=yes"],
1202
            [eval "$gt_func_gnugettext_libc=no"])])
1203
1204
        if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
1205
          dnl Sometimes libintl requires libiconv, so first search for libiconv.
1206
          ifelse(gt_included_intl, yes, , [
1207
            AM_ICONV_LINK
1208
          ])
1209
          dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL
1210
          dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv])
1211
          dnl because that would add "-liconv" to LIBINTL and LTLIBINTL
1212
          dnl even if libiconv doesn't exist.
1213
          AC_LIB_LINKFLAGS_BODY([intl])
1214
          AC_CACHE_CHECK([for GNU gettext in libintl],
1215
            [$gt_func_gnugettext_libintl],
1216
           [gt_save_CPPFLAGS="$CPPFLAGS"
1217
            CPPFLAGS="$CPPFLAGS $INCINTL"
1218
            gt_save_LIBS="$LIBS"
1219
            LIBS="$LIBS $LIBINTL"
1220
            dnl Now see whether libintl exists and does not depend on libiconv.
1221
            AC_TRY_LINK([#include <libintl.h>
1222
$gt_revision_test_code
1223
extern int _nl_msg_cat_cntr;
1224
extern
1225
#ifdef __cplusplus
1226
"C"
1227
#endif
1228
const char *_nl_expand_alias (const char *);],
1229
              [bindtextdomain ("", "");
1230
return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")],
1231
              [eval "$gt_func_gnugettext_libintl=yes"],
1232
              [eval "$gt_func_gnugettext_libintl=no"])
1233
            dnl Now see whether libintl exists and depends on libiconv.
1234
            if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
1235
              LIBS="$LIBS $LIBICONV"
1236
              AC_TRY_LINK([#include <libintl.h>
1237
$gt_revision_test_code
1238
extern int _nl_msg_cat_cntr;
1239
extern
1240
#ifdef __cplusplus
1241
"C"
1242
#endif
1243
const char *_nl_expand_alias (const char *);],
1244
                [bindtextdomain ("", "");
1245
return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")],
1246
               [LIBINTL="$LIBINTL $LIBICONV"
1247
                LTLIBINTL="$LTLIBINTL $LTLIBICONV"
1248
                eval "$gt_func_gnugettext_libintl=yes"
1249
               ])
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
1250
            fi
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1251
            CPPFLAGS="$gt_save_CPPFLAGS"
1252
            LIBS="$gt_save_LIBS"])
1253
        fi
1254
1255
        dnl If an already present or preinstalled GNU gettext() is found,
1256
        dnl use it.  But if this macro is used in GNU gettext, and GNU
1257
        dnl gettext is already preinstalled in libintl, we update this
1258
        dnl libintl.  (Cf. the install rule in intl/Makefile.in.)
1259
        if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
1260
           || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
1261
                && test "$PACKAGE" != gettext-runtime \
1262
                && test "$PACKAGE" != gettext-tools; }; then
1263
          gt_use_preinstalled_gnugettext=yes
1264
        else
1265
          dnl Reset the values set by searching for libintl.
1266
          LIBINTL=
1267
          LTLIBINTL=
1268
          INCINTL=
1269
        fi
1270
1271
    ifelse(gt_included_intl, yes, [
1272
        if test "$gt_use_preinstalled_gnugettext" != "yes"; then
1273
          dnl GNU gettext is not found in the C library.
1274
          dnl Fall back on included GNU gettext library.
1275
          nls_cv_use_gnu_gettext=yes
1276
        fi
1277
      fi
1278
1279
      if test "$nls_cv_use_gnu_gettext" = "yes"; then
1280
        dnl Mark actions used to generate GNU NLS library.
1281
        BUILD_INCLUDED_LIBINTL=yes
1282
        USE_INCLUDED_LIBINTL=yes
1283
        LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV $LIBTHREAD"
1284
        LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV $LTLIBTHREAD"
1285
        LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
1286
      fi
1287
1288
      CATOBJEXT=
1289
      if test "$gt_use_preinstalled_gnugettext" = "yes" \
1290
         || test "$nls_cv_use_gnu_gettext" = "yes"; then
1291
        dnl Mark actions to use GNU gettext tools.
1292
        CATOBJEXT=.gmo
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
1293
      fi
1294
    ])
1295
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1296
    if test -n "$INTL_MACOSX_LIBS"; then
1297
      if test "$gt_use_preinstalled_gnugettext" = "yes" \
1298
         || test "$nls_cv_use_gnu_gettext" = "yes"; then
1299
        dnl Some extra flags are needed during linking.
1300
        LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
1301
        LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
1302
      fi
1303
    fi
1304
1305
    if test "$gt_use_preinstalled_gnugettext" = "yes" \
1306
       || test "$nls_cv_use_gnu_gettext" = "yes"; then
1307
      AC_DEFINE([ENABLE_NLS], [1],
1308
        [Define to 1 if translation of program messages to the user's native language
1309
   is requested.])
1310
    else
1311
      USE_NLS=no
1312
    fi
1313
  fi
1314
1315
  AC_MSG_CHECKING([whether to use NLS])
1316
  AC_MSG_RESULT([$USE_NLS])
1317
  if test "$USE_NLS" = "yes"; then
1318
    AC_MSG_CHECKING([where the gettext function comes from])
1319
    if test "$gt_use_preinstalled_gnugettext" = "yes"; then
1320
      if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
1321
        gt_source="external libintl"
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
1322
      else
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1323
        gt_source="libc"
1324
      fi
1325
    else
1326
      gt_source="included intl directory"
1327
    fi
1328
    AC_MSG_RESULT([$gt_source])
1329
  fi
1330
1331
  if test "$USE_NLS" = "yes"; then
1332
1333
    if test "$gt_use_preinstalled_gnugettext" = "yes"; then
1334
      if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
1335
        AC_MSG_CHECKING([how to link with libintl])
1336
        AC_MSG_RESULT([$LIBINTL])
1337
        AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL])
1338
      fi
1339
1340
      dnl For backward compatibility. Some packages may be using this.
1341
      AC_DEFINE([HAVE_GETTEXT], [1],
1342
       [Define if the GNU gettext() function is already present or preinstalled.])
1343
      AC_DEFINE([HAVE_DCGETTEXT], [1],
1344
       [Define if the GNU dcgettext() function is already present or preinstalled.])
1345
    fi
1346
1347
    dnl We need to process the po/ directory.
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
1348
    POSUB=po
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1349
  fi
1350
1351
  ifelse(gt_included_intl, yes, [
1352
    dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL
1353
    dnl to 'yes' because some of the testsuite requires it.
1354
    if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then
1355
      BUILD_INCLUDED_LIBINTL=yes
1356
    fi
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
1357
1358
    dnl Make all variables we use known to autoconf.
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1359
    AC_SUBST([BUILD_INCLUDED_LIBINTL])
1360
    AC_SUBST([USE_INCLUDED_LIBINTL])
1361
    AC_SUBST([CATOBJEXT])
1362
1363
    dnl For backward compatibility. Some configure.ins may be using this.
1364
    nls_cv_header_intl=
1365
    nls_cv_header_libgt=
1366
1367
    dnl For backward compatibility. Some Makefiles may be using this.
1368
    DATADIRNAME=share
1369
    AC_SUBST([DATADIRNAME])
1370
1371
    dnl For backward compatibility. Some Makefiles may be using this.
1372
    INSTOBJEXT=.mo
1373
    AC_SUBST([INSTOBJEXT])
1374
1375
    dnl For backward compatibility. Some Makefiles may be using this.
1376
    GENCAT=gencat
1377
    AC_SUBST([GENCAT])
1378
1379
    dnl For backward compatibility. Some Makefiles may be using this.
1380
    INTLOBJS=
1381
    if test "$USE_INCLUDED_LIBINTL" = yes; then
1382
      INTLOBJS="\$(GETTOBJS)"
1383
    fi
1384
    AC_SUBST([INTLOBJS])
1385
1386
    dnl Enable libtool support if the surrounding package wishes it.
1387
    INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix
1388
    AC_SUBST([INTL_LIBTOOL_SUFFIX_PREFIX])
1389
  ])
1390
1391
  dnl For backward compatibility. Some Makefiles may be using this.
1392
  INTLLIBS="$LIBINTL"
1393
  AC_SUBST([INTLLIBS])
1394
1395
  dnl Make all documented variables known to autoconf.
1396
  AC_SUBST([LIBINTL])
1397
  AC_SUBST([LTLIBINTL])
1398
  AC_SUBST([POSUB])
1399
])
1400
1401
1402
dnl gt_NEEDS_INIT ensures that the gt_needs variable is initialized.
1403
m4_define([gt_NEEDS_INIT],
1404
[
1405
  m4_divert_text([DEFAULTS], [gt_needs=])
1406
  m4_define([gt_NEEDS_INIT], [])
1407
])
1408
1409
1410
dnl Usage: AM_GNU_GETTEXT_NEED([NEEDSYMBOL])
1411
AC_DEFUN([AM_GNU_GETTEXT_NEED],
1412
[
1413
  m4_divert_text([INIT_PREPARE], [gt_needs="$gt_needs $1"])
1414
])
1415
1416
1417
dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version])
1418
AC_DEFUN([AM_GNU_GETTEXT_VERSION], [])
1419
1420
# iconv.m4 serial 11 (gettext-0.18.1)
1421
dnl Copyright (C) 2000-2002, 2007-2010 Free Software Foundation, Inc.
1422
dnl This file is free software; the Free Software Foundation
1423
dnl gives unlimited permission to copy and/or distribute it,
1424
dnl with or without modifications, as long as this notice is preserved.
1425
1426
dnl From Bruno Haible.
1427
1428
AC_DEFUN([AM_ICONV_LINKFLAGS_BODY],
1429
[
1430
  dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
1431
  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
1432
  AC_REQUIRE([AC_LIB_RPATH])
1433
1434
  dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
1435
  dnl accordingly.
1436
  AC_LIB_LINKFLAGS_BODY([iconv])
1437
])
1438
1439
AC_DEFUN([AM_ICONV_LINK],
1440
[
1441
  dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and
1442
  dnl those with the standalone portable GNU libiconv installed).
1443
  AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
1444
1445
  dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
1446
  dnl accordingly.
1447
  AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
1448
1449
  dnl Add $INCICONV to CPPFLAGS before performing the following checks,
1450
  dnl because if the user has installed libiconv and not disabled its use
1451
  dnl via --without-libiconv-prefix, he wants to use it. The first
1452
  dnl AC_TRY_LINK will then fail, the second AC_TRY_LINK will succeed.
1453
  am_save_CPPFLAGS="$CPPFLAGS"
1454
  AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV])
1455
1456
  AC_CACHE_CHECK([for iconv], [am_cv_func_iconv], [
1457
    am_cv_func_iconv="no, consider installing GNU libiconv"
1458
    am_cv_lib_iconv=no
1459
    AC_TRY_LINK([#include <stdlib.h>
1460
#include <iconv.h>],
1461
      [iconv_t cd = iconv_open("","");
1462
       iconv(cd,NULL,NULL,NULL,NULL);
1463
       iconv_close(cd);],
1464
      [am_cv_func_iconv=yes])
1465
    if test "$am_cv_func_iconv" != yes; then
1466
      am_save_LIBS="$LIBS"
1467
      LIBS="$LIBS $LIBICONV"
1468
      AC_TRY_LINK([#include <stdlib.h>
1469
#include <iconv.h>],
1470
        [iconv_t cd = iconv_open("","");
1471
         iconv(cd,NULL,NULL,NULL,NULL);
1472
         iconv_close(cd);],
1473
        [am_cv_lib_iconv=yes]
1474
        [am_cv_func_iconv=yes])
1475
      LIBS="$am_save_LIBS"
1476
    fi
1477
  ])
1478
  if test "$am_cv_func_iconv" = yes; then
1479
    AC_CACHE_CHECK([for working iconv], [am_cv_func_iconv_works], [
1480
      dnl This tests against bugs in AIX 5.1, HP-UX 11.11, Solaris 10.
1481
      am_save_LIBS="$LIBS"
1482
      if test $am_cv_lib_iconv = yes; then
1483
        LIBS="$LIBS $LIBICONV"
1484
      fi
1485
      AC_TRY_RUN([
1486
#include <iconv.h>
1487
#include <string.h>
1488
int main ()
1489
{
1490
  /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
1491
     returns.  */
1492
  {
1493
    iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
1494
    if (cd_utf8_to_88591 != (iconv_t)(-1))
1495
      {
1496
        static const char input[] = "\342\202\254"; /* EURO SIGN */
1497
        char buf[10];
1498
        const char *inptr = input;
1499
        size_t inbytesleft = strlen (input);
1500
        char *outptr = buf;
1501
        size_t outbytesleft = sizeof (buf);
1502
        size_t res = iconv (cd_utf8_to_88591,
1503
                            (char **) &inptr, &inbytesleft,
1504
                            &outptr, &outbytesleft);
1505
        if (res == 0)
1506
          return 1;
1507
      }
1508
  }
1509
  /* Test against Solaris 10 bug: Failures are not distinguishable from
1510
     successful returns.  */
1511
  {
1512
    iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
1513
    if (cd_ascii_to_88591 != (iconv_t)(-1))
1514
      {
1515
        static const char input[] = "\263";
1516
        char buf[10];
1517
        const char *inptr = input;
1518
        size_t inbytesleft = strlen (input);
1519
        char *outptr = buf;
1520
        size_t outbytesleft = sizeof (buf);
1521
        size_t res = iconv (cd_ascii_to_88591,
1522
                            (char **) &inptr, &inbytesleft,
1523
                            &outptr, &outbytesleft);
1524
        if (res == 0)
1525
          return 1;
1526
      }
1527
  }
1528
#if 0 /* This bug could be worked around by the caller.  */
1529
  /* Test against HP-UX 11.11 bug: Positive return value instead of 0.  */
1530
  {
1531
    iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
1532
    if (cd_88591_to_utf8 != (iconv_t)(-1))
1533
      {
1534
        static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
1535
        char buf[50];
1536
        const char *inptr = input;
1537
        size_t inbytesleft = strlen (input);
1538
        char *outptr = buf;
1539
        size_t outbytesleft = sizeof (buf);
1540
        size_t res = iconv (cd_88591_to_utf8,
1541
                            (char **) &inptr, &inbytesleft,
1542
                            &outptr, &outbytesleft);
1543
        if ((int)res > 0)
1544
          return 1;
1545
      }
1546
  }
1547
#endif
1548
  /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
1549
     provided.  */
1550
  if (/* Try standardized names.  */
1551
      iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
1552
      /* Try IRIX, OSF/1 names.  */
1553
      && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
1554
      /* Try AIX names.  */
1555
      && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
1556
      /* Try HP-UX names.  */
1557
      && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
1558
    return 1;
1559
  return 0;
1560
}], [am_cv_func_iconv_works=yes], [am_cv_func_iconv_works=no],
1561
        [case "$host_os" in
1562
           aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
1563
           *)            am_cv_func_iconv_works="guessing yes" ;;
1564
         esac])
1565
      LIBS="$am_save_LIBS"
1566
    ])
1567
    case "$am_cv_func_iconv_works" in
1568
      *no) am_func_iconv=no am_cv_lib_iconv=no ;;
1569
      *)   am_func_iconv=yes ;;
1570
    esac
1571
  else
1572
    am_func_iconv=no am_cv_lib_iconv=no
1573
  fi
1574
  if test "$am_func_iconv" = yes; then
1575
    AC_DEFINE([HAVE_ICONV], [1],
1576
      [Define if you have the iconv() function and it works.])
1577
  fi
1578
  if test "$am_cv_lib_iconv" = yes; then
1579
    AC_MSG_CHECKING([how to link with libiconv])
1580
    AC_MSG_RESULT([$LIBICONV])
1581
  else
1582
    dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV
1583
    dnl either.
1584
    CPPFLAGS="$am_save_CPPFLAGS"
1585
    LIBICONV=
1586
    LTLIBICONV=
1587
  fi
1588
  AC_SUBST([LIBICONV])
1589
  AC_SUBST([LTLIBICONV])
1590
])
1591
1592
dnl Define AM_ICONV using AC_DEFUN_ONCE for Autoconf >= 2.64, in order to
1593
dnl avoid warnings like
1594
dnl "warning: AC_REQUIRE: `AM_ICONV' was expanded before it was required".
1595
dnl This is tricky because of the way 'aclocal' is implemented:
1596
dnl - It requires defining an auxiliary macro whose name ends in AC_DEFUN.
1597
dnl   Otherwise aclocal's initial scan pass would miss the macro definition.
1598
dnl - It requires a line break inside the AC_DEFUN_ONCE and AC_DEFUN expansions.
1599
dnl   Otherwise aclocal would emit many "Use of uninitialized value $1"
1600
dnl   warnings.
1601
m4_define([gl_iconv_AC_DEFUN],
1602
  m4_version_prereq([2.64],
1603
    [[AC_DEFUN_ONCE(
1604
        [$1], [$2])]],
1605
    [[AC_DEFUN(
1606
        [$1], [$2])]]))
1607
gl_iconv_AC_DEFUN([AM_ICONV],
1608
[
1609
  AM_ICONV_LINK
1610
  if test "$am_cv_func_iconv" = yes; then
1611
    AC_MSG_CHECKING([for iconv declaration])
1612
    AC_CACHE_VAL([am_cv_proto_iconv], [
1613
      AC_TRY_COMPILE([
1614
#include <stdlib.h>
1615
#include <iconv.h>
1616
extern
1617
#ifdef __cplusplus
1618
"C"
1619
#endif
1620
#if defined(__STDC__) || defined(__cplusplus)
1621
size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
1622
#else
1623
size_t iconv();
1624
#endif
1625
], [], [am_cv_proto_iconv_arg1=""], [am_cv_proto_iconv_arg1="const"])
1626
      am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"])
1627
    am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
1628
    AC_MSG_RESULT([
1629
         $am_cv_proto_iconv])
1630
    AC_DEFINE_UNQUOTED([ICONV_CONST], [$am_cv_proto_iconv_arg1],
1631
      [Define as const if the declaration of iconv() needs const.])
1632
  fi
1633
])
1634
1635
# intlmacosx.m4 serial 3 (gettext-0.18)
1636
dnl Copyright (C) 2004-2010 Free Software Foundation, Inc.
1637
dnl This file is free software; the Free Software Foundation
1638
dnl gives unlimited permission to copy and/or distribute it,
1639
dnl with or without modifications, as long as this notice is preserved.
1640
dnl
1641
dnl This file can can be used in projects which are not available under
1642
dnl the GNU General Public License or the GNU Library General Public
1643
dnl License but which still want to provide support for the GNU gettext
1644
dnl functionality.
1645
dnl Please note that the actual code of the GNU gettext library is covered
1646
dnl by the GNU Library General Public License, and the rest of the GNU
1647
dnl gettext package package is covered by the GNU General Public License.
1648
dnl They are *not* in the public domain.
1649
1650
dnl Checks for special options needed on MacOS X.
1651
dnl Defines INTL_MACOSX_LIBS.
1652
AC_DEFUN([gt_INTL_MACOSX],
1653
[
1654
  dnl Check for API introduced in MacOS X 10.2.
1655
  AC_CACHE_CHECK([for CFPreferencesCopyAppValue],
1656
    [gt_cv_func_CFPreferencesCopyAppValue],
1657
    [gt_save_LIBS="$LIBS"
1658
     LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
1659
     AC_TRY_LINK([#include <CoreFoundation/CFPreferences.h>],
1660
       [CFPreferencesCopyAppValue(NULL, NULL)],
1661
       [gt_cv_func_CFPreferencesCopyAppValue=yes],
1662
       [gt_cv_func_CFPreferencesCopyAppValue=no])
1663
     LIBS="$gt_save_LIBS"])
1664
  if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
1665
    AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1],
1666
      [Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in the CoreFoundation framework.])
1667
  fi
1668
  dnl Check for API introduced in MacOS X 10.3.
1669
  AC_CACHE_CHECK([for CFLocaleCopyCurrent], [gt_cv_func_CFLocaleCopyCurrent],
1670
    [gt_save_LIBS="$LIBS"
1671
     LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
1672
     AC_TRY_LINK([#include <CoreFoundation/CFLocale.h>], [CFLocaleCopyCurrent();],
1673
       [gt_cv_func_CFLocaleCopyCurrent=yes],
1674
       [gt_cv_func_CFLocaleCopyCurrent=no])
1675
     LIBS="$gt_save_LIBS"])
1676
  if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
1677
    AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], [1],
1678
      [Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the CoreFoundation framework.])
1679
  fi
1680
  INTL_MACOSX_LIBS=
1681
  if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
1682
    INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
1683
  fi
1684
  AC_SUBST([INTL_MACOSX_LIBS])
1685
])
1686
1687
# lib-ld.m4 serial 4 (gettext-0.18)
1688
dnl Copyright (C) 1996-2003, 2009-2010 Free Software Foundation, Inc.
1689
dnl This file is free software; the Free Software Foundation
1690
dnl gives unlimited permission to copy and/or distribute it,
1691
dnl with or without modifications, as long as this notice is preserved.
1692
1693
dnl Subroutines of libtool.m4,
1694
dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision
1695
dnl with libtool.m4.
1696
1697
dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.
1698
AC_DEFUN([AC_LIB_PROG_LD_GNU],
1699
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], [acl_cv_prog_gnu_ld],
1700
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
1701
case `$LD -v 2>&1 </dev/null` in
1702
*GNU* | *'with BFD'*)
1703
  acl_cv_prog_gnu_ld=yes ;;
1704
*)
1705
  acl_cv_prog_gnu_ld=no ;;
1706
esac])
1707
with_gnu_ld=$acl_cv_prog_gnu_ld
1708
])
1709
1710
dnl From libtool-1.4. Sets the variable LD.
1711
AC_DEFUN([AC_LIB_PROG_LD],
1712
[AC_ARG_WITH([gnu-ld],
1713
[  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]],
1714
test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
1715
AC_REQUIRE([AC_PROG_CC])dnl
1716
AC_REQUIRE([AC_CANONICAL_HOST])dnl
1717
# Prepare PATH_SEPARATOR.
1718
# The user is always right.
1719
if test "${PATH_SEPARATOR+set}" != set; then
1720
  echo "#! /bin/sh" >conf$$.sh
1721
  echo  "exit 0"   >>conf$$.sh
1722
  chmod +x conf$$.sh
1723
  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
1724
    PATH_SEPARATOR=';'
1725
  else
1726
    PATH_SEPARATOR=:
1727
  fi
1728
  rm -f conf$$.sh
1729
fi
1730
ac_prog=ld
1731
if test "$GCC" = yes; then
1732
  # Check if gcc -print-prog-name=ld gives a path.
1733
  AC_MSG_CHECKING([for ld used by GCC])
1734
  case $host in
1735
  *-*-mingw*)
1736
    # gcc leaves a trailing carriage return which upsets mingw
1737
    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
1738
  *)
1739
    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
1740
  esac
1741
  case $ac_prog in
1742
    # Accept absolute paths.
1743
    [[\\/]* | [A-Za-z]:[\\/]*)]
1744
      [re_direlt='/[^/][^/]*/\.\./']
1745
      # Canonicalize the path of ld
1746
      ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1747
      while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1748
        ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1749
      done
1750
      test -z "$LD" && LD="$ac_prog"
1751
      ;;
1752
  "")
1753
    # If it fails, then pretend we aren't using GCC.
1754
    ac_prog=ld
1755
    ;;
1756
  *)
1757
    # If it is relative, then search for the first ld in PATH.
1758
    with_gnu_ld=unknown
1759
    ;;
1760
  esac
1761
elif test "$with_gnu_ld" = yes; then
1762
  AC_MSG_CHECKING([for GNU ld])
1763
else
1764
  AC_MSG_CHECKING([for non-GNU ld])
1765
fi
1766
AC_CACHE_VAL([acl_cv_path_LD],
1767
[if test -z "$LD"; then
1768
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1769
  for ac_dir in $PATH; do
1770
    test -z "$ac_dir" && ac_dir=.
1771
    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
1772
      acl_cv_path_LD="$ac_dir/$ac_prog"
1773
      # Check to see if the program is GNU ld.  I'd rather use --version,
1774
      # but apparently some GNU ld's only accept -v.
1775
      # Break only if it was the GNU/non-GNU ld that we prefer.
1776
      case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in
1777
      *GNU* | *'with BFD'*)
1778
        test "$with_gnu_ld" != no && break ;;
1779
      *)
1780
        test "$with_gnu_ld" != yes && break ;;
1781
      esac
1782
    fi
1783
  done
1784
  IFS="$ac_save_ifs"
1785
else
1786
  acl_cv_path_LD="$LD" # Let the user override the test with a path.
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
1787
fi])
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1788
LD="$acl_cv_path_LD"
1789
if test -n "$LD"; then
1790
  AC_MSG_RESULT([$LD])
1791
else
1792
  AC_MSG_RESULT([no])
1793
fi
1794
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
1795
AC_LIB_PROG_LD_GNU
1796
])
1797
1798
# lib-link.m4 serial 21 (gettext-0.18)
1799
dnl Copyright (C) 2001-2010 Free Software Foundation, Inc.
1800
dnl This file is free software; the Free Software Foundation
1801
dnl gives unlimited permission to copy and/or distribute it,
1802
dnl with or without modifications, as long as this notice is preserved.
1803
1804
dnl From Bruno Haible.
1805
1806
AC_PREREQ([2.54])
1807
1808
dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
1809
dnl the libraries corresponding to explicit and implicit dependencies.
1810
dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
1811
dnl augments the CPPFLAGS variable.
1812
dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
1813
dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
1814
AC_DEFUN([AC_LIB_LINKFLAGS],
1815
[
1816
  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
1817
  AC_REQUIRE([AC_LIB_RPATH])
1818
  pushdef([Name],[translit([$1],[./-], [___])])
1819
  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
1820
                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
1821
  AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
1822
    AC_LIB_LINKFLAGS_BODY([$1], [$2])
1823
    ac_cv_lib[]Name[]_libs="$LIB[]NAME"
1824
    ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
1825
    ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
1826
    ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX"
1827
  ])
1828
  LIB[]NAME="$ac_cv_lib[]Name[]_libs"
1829
  LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
1830
  INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
1831
  LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix"
1832
  AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
1833
  AC_SUBST([LIB]NAME)
1834
  AC_SUBST([LTLIB]NAME)
1835
  AC_SUBST([LIB]NAME[_PREFIX])
1836
  dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
1837
  dnl results of this search when this library appears as a dependency.
1838
  HAVE_LIB[]NAME=yes
1839
  popdef([NAME])
1840
  popdef([Name])
1841
])
1842
1843
dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message])
1844
dnl searches for libname and the libraries corresponding to explicit and
1845
dnl implicit dependencies, together with the specified include files and
1846
dnl the ability to compile and link the specified testcode. The missing-message
1847
dnl defaults to 'no' and may contain additional hints for the user.
1848
dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME}
1849
dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and
1850
dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
1851
dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
1852
dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
1853
dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
1854
AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
1855
[
1856
  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
1857
  AC_REQUIRE([AC_LIB_RPATH])
1858
  pushdef([Name],[translit([$1],[./-], [___])])
1859
  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
1860
                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
1861
1862
  dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
1863
  dnl accordingly.
1864
  AC_LIB_LINKFLAGS_BODY([$1], [$2])
1865
1866
  dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
1867
  dnl because if the user has installed lib[]Name and not disabled its use
1868
  dnl via --without-lib[]Name-prefix, he wants to use it.
1869
  ac_save_CPPFLAGS="$CPPFLAGS"
1870
  AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
1871
1872
  AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
1873
    ac_save_LIBS="$LIBS"
1874
    dnl If $LIB[]NAME contains some -l options, add it to the end of LIBS,
1875
    dnl because these -l options might require -L options that are present in
1876
    dnl LIBS. -l options benefit only from the -L options listed before it.
1877
    dnl Otherwise, add it to the front of LIBS, because it may be a static
1878
    dnl library that depends on another static library that is present in LIBS.
1879
    dnl Static libraries benefit only from the static libraries listed after
1880
    dnl it.
1881
    case " $LIB[]NAME" in
1882
      *" -l"*) LIBS="$LIBS $LIB[]NAME" ;;
1883
      *)       LIBS="$LIB[]NAME $LIBS" ;;
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
1884
    esac
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
1885
    AC_TRY_LINK([$3], [$4],
1886
      [ac_cv_lib[]Name=yes],
1887
      [ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])'])
1888
    LIBS="$ac_save_LIBS"
1889
  ])
1890
  if test "$ac_cv_lib[]Name" = yes; then
1891
    HAVE_LIB[]NAME=yes
1892
    AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib][$1 library.])
1893
    AC_MSG_CHECKING([how to link with lib[]$1])
1894
    AC_MSG_RESULT([$LIB[]NAME])
1895
  else
1896
    HAVE_LIB[]NAME=no
1897
    dnl If $LIB[]NAME didn't lead to a usable library, we don't need
1898
    dnl $INC[]NAME either.
1899
    CPPFLAGS="$ac_save_CPPFLAGS"
1900
    LIB[]NAME=
1901
    LTLIB[]NAME=
1902
    LIB[]NAME[]_PREFIX=
1903
  fi
1904
  AC_SUBST([HAVE_LIB]NAME)
1905
  AC_SUBST([LIB]NAME)
1906
  AC_SUBST([LTLIB]NAME)
1907
  AC_SUBST([LIB]NAME[_PREFIX])
1908
  popdef([NAME])
1909
  popdef([Name])
1910
])
1911
1912
dnl Determine the platform dependent parameters needed to use rpath:
1913
dnl   acl_libext,
1914
dnl   acl_shlibext,
1915
dnl   acl_hardcode_libdir_flag_spec,
1916
dnl   acl_hardcode_libdir_separator,
1917
dnl   acl_hardcode_direct,
1918
dnl   acl_hardcode_minus_L.
1919
AC_DEFUN([AC_LIB_RPATH],
1920
[
1921
  dnl Tell automake >= 1.10 to complain if config.rpath is missing.
1922
  m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])])
1923
  AC_REQUIRE([AC_PROG_CC])                dnl we use $CC, $GCC, $LDFLAGS
1924
  AC_REQUIRE([AC_LIB_PROG_LD])            dnl we use $LD, $with_gnu_ld
1925
  AC_REQUIRE([AC_CANONICAL_HOST])         dnl we use $host
1926
  AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
1927
  AC_CACHE_CHECK([for shared library run path origin], [acl_cv_rpath], [
1928
    CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
1929
    ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
1930
    . ./conftest.sh
1931
    rm -f ./conftest.sh
1932
    acl_cv_rpath=done
1933
  ])
1934
  wl="$acl_cv_wl"
1935
  acl_libext="$acl_cv_libext"
1936
  acl_shlibext="$acl_cv_shlibext"
1937
  acl_libname_spec="$acl_cv_libname_spec"
1938
  acl_library_names_spec="$acl_cv_library_names_spec"
1939
  acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
1940
  acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
1941
  acl_hardcode_direct="$acl_cv_hardcode_direct"
1942
  acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
1943
  dnl Determine whether the user wants rpath handling at all.
1944
  AC_ARG_ENABLE([rpath],
1945
    [  --disable-rpath         do not hardcode runtime library paths],
1946
    :, enable_rpath=yes)
1947
])
1948
1949
dnl AC_LIB_FROMPACKAGE(name, package)
1950
dnl declares that libname comes from the given package. The configure file
1951
dnl will then not have a --with-libname-prefix option but a
1952
dnl --with-package-prefix option. Several libraries can come from the same
1953
dnl package. This declaration must occur before an AC_LIB_LINKFLAGS or similar
1954
dnl macro call that searches for libname.
1955
AC_DEFUN([AC_LIB_FROMPACKAGE],
1956
[
1957
  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
1958
                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
1959
  define([acl_frompackage_]NAME, [$2])
1960
  popdef([NAME])
1961
  pushdef([PACK],[$2])
1962
  pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-],
1963
                                  [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
1964
  define([acl_libsinpackage_]PACKUP,
1965
    m4_ifdef([acl_libsinpackage_]PACKUP, [acl_libsinpackage_]PACKUP[[, ]],)[lib$1])
1966
  popdef([PACKUP])
1967
  popdef([PACK])
1968
])
1969
1970
dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
1971
dnl the libraries corresponding to explicit and implicit dependencies.
1972
dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
1973
dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found
1974
dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
1975
AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
1976
[
1977
  AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
1978
  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
1979
                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
1980
  pushdef([PACK],[m4_ifdef([acl_frompackage_]NAME, [acl_frompackage_]NAME, lib[$1])])
1981
  pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-],
1982
                                  [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
1983
  pushdef([PACKLIBS],[m4_ifdef([acl_frompackage_]NAME, [acl_libsinpackage_]PACKUP, lib[$1])])
1984
  dnl Autoconf >= 2.61 supports dots in --with options.
1985
  pushdef([P_A_C_K],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit(PACK,[.],[_])],PACK)])
1986
  dnl By default, look in $includedir and $libdir.
1987
  use_additional=yes
1988
  AC_LIB_WITH_FINAL_PREFIX([
1989
    eval additional_includedir=\"$includedir\"
1990
    eval additional_libdir=\"$libdir\"
1991
  ])
1992
  AC_ARG_WITH(P_A_C_K[-prefix],
1993
[[  --with-]]P_A_C_K[[-prefix[=DIR]  search for ]PACKLIBS[ in DIR/include and DIR/lib
1994
  --without-]]P_A_C_K[[-prefix     don't search for ]PACKLIBS[ in includedir and libdir]],
1995
[
1996
    if test "X$withval" = "Xno"; then
1997
      use_additional=no
1998
    else
1999
      if test "X$withval" = "X"; then
2000
        AC_LIB_WITH_FINAL_PREFIX([
2001
          eval additional_includedir=\"$includedir\"
2002
          eval additional_libdir=\"$libdir\"
2003
        ])
2004
      else
2005
        additional_includedir="$withval/include"
2006
        additional_libdir="$withval/$acl_libdirstem"
2007
        if test "$acl_libdirstem2" != "$acl_libdirstem" \
2008
           && ! test -d "$withval/$acl_libdirstem"; then
2009
          additional_libdir="$withval/$acl_libdirstem2"
2010
        fi
2011
      fi
2012
    fi
2013
])
2014
  dnl Search the library and its dependencies in $additional_libdir and
2015
  dnl $LDFLAGS. Using breadth-first-seach.
2016
  LIB[]NAME=
2017
  LTLIB[]NAME=
2018
  INC[]NAME=
2019
  LIB[]NAME[]_PREFIX=
2020
  dnl HAVE_LIB${NAME} is an indicator that LIB${NAME}, LTLIB${NAME} have been
2021
  dnl computed. So it has to be reset here.
2022
  HAVE_LIB[]NAME=
2023
  rpathdirs=
2024
  ltrpathdirs=
2025
  names_already_handled=
2026
  names_next_round='$1 $2'
2027
  while test -n "$names_next_round"; do
2028
    names_this_round="$names_next_round"
2029
    names_next_round=
2030
    for name in $names_this_round; do
2031
      already_handled=
2032
      for n in $names_already_handled; do
2033
        if test "$n" = "$name"; then
2034
          already_handled=yes
2035
          break
2036
        fi
2037
      done
2038
      if test -z "$already_handled"; then
2039
        names_already_handled="$names_already_handled $name"
2040
        dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
2041
        dnl or AC_LIB_HAVE_LINKFLAGS call.
2042
        uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
2043
        eval value=\"\$HAVE_LIB$uppername\"
2044
        if test -n "$value"; then
2045
          if test "$value" = yes; then
2046
            eval value=\"\$LIB$uppername\"
2047
            test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
2048
            eval value=\"\$LTLIB$uppername\"
2049
            test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
2050
          else
2051
            dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
2052
            dnl that this library doesn't exist. So just drop it.
2053
            :
2054
          fi
2055
        else
2056
          dnl Search the library lib$name in $additional_libdir and $LDFLAGS
2057
          dnl and the already constructed $LIBNAME/$LTLIBNAME.
2058
          found_dir=
2059
          found_la=
2060
          found_so=
2061
          found_a=
2062
          eval libname=\"$acl_libname_spec\"    # typically: libname=lib$name
2063
          if test -n "$acl_shlibext"; then
2064
            shrext=".$acl_shlibext"             # typically: shrext=.so
2065
          else
2066
            shrext=
2067
          fi
2068
          if test $use_additional = yes; then
2069
            dir="$additional_libdir"
2070
            dnl The same code as in the loop below:
2071
            dnl First look for a shared library.
2072
            if test -n "$acl_shlibext"; then
2073
              if test -f "$dir/$libname$shrext"; then
2074
                found_dir="$dir"
2075
                found_so="$dir/$libname$shrext"
2076
              else
2077
                if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
2078
                  ver=`(cd "$dir" && \
2079
                        for f in "$libname$shrext".*; do echo "$f"; done \
2080
                        | sed -e "s,^$libname$shrext\\\\.,," \
2081
                        | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
2082
                        | sed 1q ) 2>/dev/null`
2083
                  if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
2084
                    found_dir="$dir"
2085
                    found_so="$dir/$libname$shrext.$ver"
2086
                  fi
2087
                else
2088
                  eval library_names=\"$acl_library_names_spec\"
2089
                  for f in $library_names; do
2090
                    if test -f "$dir/$f"; then
2091
                      found_dir="$dir"
2092
                      found_so="$dir/$f"
2093
                      break
2094
                    fi
2095
                  done
2096
                fi
2097
              fi
2098
            fi
2099
            dnl Then look for a static library.
2100
            if test "X$found_dir" = "X"; then
2101
              if test -f "$dir/$libname.$acl_libext"; then
2102
                found_dir="$dir"
2103
                found_a="$dir/$libname.$acl_libext"
2104
              fi
2105
            fi
2106
            if test "X$found_dir" != "X"; then
2107
              if test -f "$dir/$libname.la"; then
2108
                found_la="$dir/$libname.la"
2109
              fi
2110
            fi
2111
          fi
2112
          if test "X$found_dir" = "X"; then
2113
            for x in $LDFLAGS $LTLIB[]NAME; do
2114
              AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2115
              case "$x" in
2116
                -L*)
2117
                  dir=`echo "X$x" | sed -e 's/^X-L//'`
2118
                  dnl First look for a shared library.
2119
                  if test -n "$acl_shlibext"; then
2120
                    if test -f "$dir/$libname$shrext"; then
2121
                      found_dir="$dir"
2122
                      found_so="$dir/$libname$shrext"
2123
                    else
2124
                      if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
2125
                        ver=`(cd "$dir" && \
2126
                              for f in "$libname$shrext".*; do echo "$f"; done \
2127
                              | sed -e "s,^$libname$shrext\\\\.,," \
2128
                              | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
2129
                              | sed 1q ) 2>/dev/null`
2130
                        if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
2131
                          found_dir="$dir"
2132
                          found_so="$dir/$libname$shrext.$ver"
2133
                        fi
2134
                      else
2135
                        eval library_names=\"$acl_library_names_spec\"
2136
                        for f in $library_names; do
2137
                          if test -f "$dir/$f"; then
2138
                            found_dir="$dir"
2139
                            found_so="$dir/$f"
2140
                            break
2141
                          fi
2142
                        done
2143
                      fi
2144
                    fi
2145
                  fi
2146
                  dnl Then look for a static library.
2147
                  if test "X$found_dir" = "X"; then
2148
                    if test -f "$dir/$libname.$acl_libext"; then
2149
                      found_dir="$dir"
2150
                      found_a="$dir/$libname.$acl_libext"
2151
                    fi
2152
                  fi
2153
                  if test "X$found_dir" != "X"; then
2154
                    if test -f "$dir/$libname.la"; then
2155
                      found_la="$dir/$libname.la"
2156
                    fi
2157
                  fi
2158
                  ;;
2159
              esac
2160
              if test "X$found_dir" != "X"; then
2161
                break
2162
              fi
2163
            done
2164
          fi
2165
          if test "X$found_dir" != "X"; then
2166
            dnl Found the library.
2167
            LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name"
2168
            if test "X$found_so" != "X"; then
2169
              dnl Linking with a shared library. We attempt to hardcode its
2170
              dnl directory into the executable's runpath, unless it's the
2171
              dnl standard /usr/lib.
2172
              if test "$enable_rpath" = no \
2173
                 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
2174
                 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
2175
                dnl No hardcoding is needed.
2176
                LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
2177
              else
2178
                dnl Use an explicit option to hardcode DIR into the resulting
2179
                dnl binary.
2180
                dnl Potentially add DIR to ltrpathdirs.
2181
                dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
2182
                haveit=
2183
                for x in $ltrpathdirs; do
2184
                  if test "X$x" = "X$found_dir"; then
2185
                    haveit=yes
2186
                    break
2187
                  fi
2188
                done
2189
                if test -z "$haveit"; then
2190
                  ltrpathdirs="$ltrpathdirs $found_dir"
2191
                fi
2192
                dnl The hardcoding into $LIBNAME is system dependent.
2193
                if test "$acl_hardcode_direct" = yes; then
2194
                  dnl Using DIR/libNAME.so during linking hardcodes DIR into the
2195
                  dnl resulting binary.
2196
                  LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
2197
                else
2198
                  if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
2199
                    dnl Use an explicit option to hardcode DIR into the resulting
2200
                    dnl binary.
2201
                    LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
2202
                    dnl Potentially add DIR to rpathdirs.
2203
                    dnl The rpathdirs will be appended to $LIBNAME at the end.
2204
                    haveit=
2205
                    for x in $rpathdirs; do
2206
                      if test "X$x" = "X$found_dir"; then
2207
                        haveit=yes
2208
                        break
2209
                      fi
2210
                    done
2211
                    if test -z "$haveit"; then
2212
                      rpathdirs="$rpathdirs $found_dir"
2213
                    fi
2214
                  else
2215
                    dnl Rely on "-L$found_dir".
2216
                    dnl But don't add it if it's already contained in the LDFLAGS
2217
                    dnl or the already constructed $LIBNAME
2218
                    haveit=
2219
                    for x in $LDFLAGS $LIB[]NAME; do
2220
                      AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2221
                      if test "X$x" = "X-L$found_dir"; then
2222
                        haveit=yes
2223
                        break
2224
                      fi
2225
                    done
2226
                    if test -z "$haveit"; then
2227
                      LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir"
2228
                    fi
2229
                    if test "$acl_hardcode_minus_L" != no; then
2230
                      dnl FIXME: Not sure whether we should use
2231
                      dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
2232
                      dnl here.
2233
                      LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
2234
                    else
2235
                      dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH
2236
                      dnl here, because this doesn't fit in flags passed to the
2237
                      dnl compiler. So give up. No hardcoding. This affects only
2238
                      dnl very old systems.
2239
                      dnl FIXME: Not sure whether we should use
2240
                      dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
2241
                      dnl here.
2242
                      LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
2243
                    fi
2244
                  fi
2245
                fi
2246
              fi
2247
            else
2248
              if test "X$found_a" != "X"; then
2249
                dnl Linking with a static library.
2250
                LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a"
2251
              else
2252
                dnl We shouldn't come here, but anyway it's good to have a
2253
                dnl fallback.
2254
                LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name"
2255
              fi
2256
            fi
2257
            dnl Assume the include files are nearby.
2258
            additional_includedir=
2259
            case "$found_dir" in
2260
              */$acl_libdirstem | */$acl_libdirstem/)
2261
                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
2262
                if test "$name" = '$1'; then
2263
                  LIB[]NAME[]_PREFIX="$basedir"
2264
                fi
2265
                additional_includedir="$basedir/include"
2266
                ;;
2267
              */$acl_libdirstem2 | */$acl_libdirstem2/)
2268
                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
2269
                if test "$name" = '$1'; then
2270
                  LIB[]NAME[]_PREFIX="$basedir"
2271
                fi
2272
                additional_includedir="$basedir/include"
2273
                ;;
2274
            esac
2275
            if test "X$additional_includedir" != "X"; then
2276
              dnl Potentially add $additional_includedir to $INCNAME.
2277
              dnl But don't add it
2278
              dnl   1. if it's the standard /usr/include,
2279
              dnl   2. if it's /usr/local/include and we are using GCC on Linux,
2280
              dnl   3. if it's already present in $CPPFLAGS or the already
2281
              dnl      constructed $INCNAME,
2282
              dnl   4. if it doesn't exist as a directory.
2283
              if test "X$additional_includedir" != "X/usr/include"; then
2284
                haveit=
2285
                if test "X$additional_includedir" = "X/usr/local/include"; then
2286
                  if test -n "$GCC"; then
2287
                    case $host_os in
2288
                      linux* | gnu* | k*bsd*-gnu) haveit=yes;;
2289
                    esac
2290
                  fi
2291
                fi
2292
                if test -z "$haveit"; then
2293
                  for x in $CPPFLAGS $INC[]NAME; do
2294
                    AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2295
                    if test "X$x" = "X-I$additional_includedir"; then
2296
                      haveit=yes
2297
                      break
2298
                    fi
2299
                  done
2300
                  if test -z "$haveit"; then
2301
                    if test -d "$additional_includedir"; then
2302
                      dnl Really add $additional_includedir to $INCNAME.
2303
                      INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir"
2304
                    fi
2305
                  fi
2306
                fi
2307
              fi
2308
            fi
2309
            dnl Look for dependencies.
2310
            if test -n "$found_la"; then
2311
              dnl Read the .la file. It defines the variables
2312
              dnl dlname, library_names, old_library, dependency_libs, current,
2313
              dnl age, revision, installed, dlopen, dlpreopen, libdir.
2314
              save_libdir="$libdir"
2315
              case "$found_la" in
2316
                */* | *\\*) . "$found_la" ;;
2317
                *) . "./$found_la" ;;
2318
              esac
2319
              libdir="$save_libdir"
2320
              dnl We use only dependency_libs.
2321
              for dep in $dependency_libs; do
2322
                case "$dep" in
2323
                  -L*)
2324
                    additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
2325
                    dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME.
2326
                    dnl But don't add it
2327
                    dnl   1. if it's the standard /usr/lib,
2328
                    dnl   2. if it's /usr/local/lib and we are using GCC on Linux,
2329
                    dnl   3. if it's already present in $LDFLAGS or the already
2330
                    dnl      constructed $LIBNAME,
2331
                    dnl   4. if it doesn't exist as a directory.
2332
                    if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
2333
                       && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
2334
                      haveit=
2335
                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
2336
                         || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
2337
                        if test -n "$GCC"; then
2338
                          case $host_os in
2339
                            linux* | gnu* | k*bsd*-gnu) haveit=yes;;
2340
                          esac
2341
                        fi
2342
                      fi
2343
                      if test -z "$haveit"; then
2344
                        haveit=
2345
                        for x in $LDFLAGS $LIB[]NAME; do
2346
                          AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2347
                          if test "X$x" = "X-L$additional_libdir"; then
2348
                            haveit=yes
2349
                            break
2350
                          fi
2351
                        done
2352
                        if test -z "$haveit"; then
2353
                          if test -d "$additional_libdir"; then
2354
                            dnl Really add $additional_libdir to $LIBNAME.
2355
                            LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir"
2356
                          fi
2357
                        fi
2358
                        haveit=
2359
                        for x in $LDFLAGS $LTLIB[]NAME; do
2360
                          AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2361
                          if test "X$x" = "X-L$additional_libdir"; then
2362
                            haveit=yes
2363
                            break
2364
                          fi
2365
                        done
2366
                        if test -z "$haveit"; then
2367
                          if test -d "$additional_libdir"; then
2368
                            dnl Really add $additional_libdir to $LTLIBNAME.
2369
                            LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir"
2370
                          fi
2371
                        fi
2372
                      fi
2373
                    fi
2374
                    ;;
2375
                  -R*)
2376
                    dir=`echo "X$dep" | sed -e 's/^X-R//'`
2377
                    if test "$enable_rpath" != no; then
2378
                      dnl Potentially add DIR to rpathdirs.
2379
                      dnl The rpathdirs will be appended to $LIBNAME at the end.
2380
                      haveit=
2381
                      for x in $rpathdirs; do
2382
                        if test "X$x" = "X$dir"; then
2383
                          haveit=yes
2384
                          break
2385
                        fi
2386
                      done
2387
                      if test -z "$haveit"; then
2388
                        rpathdirs="$rpathdirs $dir"
2389
                      fi
2390
                      dnl Potentially add DIR to ltrpathdirs.
2391
                      dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
2392
                      haveit=
2393
                      for x in $ltrpathdirs; do
2394
                        if test "X$x" = "X$dir"; then
2395
                          haveit=yes
2396
                          break
2397
                        fi
2398
                      done
2399
                      if test -z "$haveit"; then
2400
                        ltrpathdirs="$ltrpathdirs $dir"
2401
                      fi
2402
                    fi
2403
                    ;;
2404
                  -l*)
2405
                    dnl Handle this in the next round.
2406
                    names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
2407
                    ;;
2408
                  *.la)
2409
                    dnl Handle this in the next round. Throw away the .la's
2410
                    dnl directory; it is already contained in a preceding -L
2411
                    dnl option.
2412
                    names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
2413
                    ;;
2414
                  *)
2415
                    dnl Most likely an immediate library name.
2416
                    LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep"
2417
                    LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep"
2418
                    ;;
2419
                esac
2420
              done
2421
            fi
2422
          else
2423
            dnl Didn't find the library; assume it is in the system directories
2424
            dnl known to the linker and runtime loader. (All the system
2425
            dnl directories known to the linker should also be known to the
2426
            dnl runtime loader, otherwise the system is severely misconfigured.)
2427
            LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
2428
            LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name"
2429
          fi
2430
        fi
2431
      fi
2432
    done
2433
  done
2434
  if test "X$rpathdirs" != "X"; then
2435
    if test -n "$acl_hardcode_libdir_separator"; then
2436
      dnl Weird platform: only the last -rpath option counts, the user must
2437
      dnl pass all path elements in one option. We can arrange that for a
2438
      dnl single library, but not when more than one $LIBNAMEs are used.
2439
      alldirs=
2440
      for found_dir in $rpathdirs; do
2441
        alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
2442
      done
2443
      dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl.
2444
      acl_save_libdir="$libdir"
2445
      libdir="$alldirs"
2446
      eval flag=\"$acl_hardcode_libdir_flag_spec\"
2447
      libdir="$acl_save_libdir"
2448
      LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
2449
    else
2450
      dnl The -rpath options are cumulative.
2451
      for found_dir in $rpathdirs; do
2452
        acl_save_libdir="$libdir"
2453
        libdir="$found_dir"
2454
        eval flag=\"$acl_hardcode_libdir_flag_spec\"
2455
        libdir="$acl_save_libdir"
2456
        LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
2457
      done
2458
    fi
2459
  fi
2460
  if test "X$ltrpathdirs" != "X"; then
2461
    dnl When using libtool, the option that works for both libraries and
2462
    dnl executables is -R. The -R options are cumulative.
2463
    for found_dir in $ltrpathdirs; do
2464
      LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
2465
    done
2466
  fi
2467
  popdef([P_A_C_K])
2468
  popdef([PACKLIBS])
2469
  popdef([PACKUP])
2470
  popdef([PACK])
2471
  popdef([NAME])
2472
])
2473
2474
dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
2475
dnl unless already present in VAR.
2476
dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes
2477
dnl contains two or three consecutive elements that belong together.
2478
AC_DEFUN([AC_LIB_APPENDTOVAR],
2479
[
2480
  for element in [$2]; do
2481
    haveit=
2482
    for x in $[$1]; do
2483
      AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2484
      if test "X$x" = "X$element"; then
2485
        haveit=yes
2486
        break
2487
      fi
2488
    done
2489
    if test -z "$haveit"; then
2490
      [$1]="${[$1]}${[$1]:+ }$element"
2491
    fi
2492
  done
2493
])
2494
2495
dnl For those cases where a variable contains several -L and -l options
2496
dnl referring to unknown libraries and directories, this macro determines the
2497
dnl necessary additional linker options for the runtime path.
2498
dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL])
2499
dnl sets LDADDVAR to linker options needed together with LIBSVALUE.
2500
dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed,
2501
dnl otherwise linking without libtool is assumed.
2502
AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],
2503
[
2504
  AC_REQUIRE([AC_LIB_RPATH])
2505
  AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
2506
  $1=
2507
  if test "$enable_rpath" != no; then
2508
    if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
2509
      dnl Use an explicit option to hardcode directories into the resulting
2510
      dnl binary.
2511
      rpathdirs=
2512
      next=
2513
      for opt in $2; do
2514
        if test -n "$next"; then
2515
          dir="$next"
2516
          dnl No need to hardcode the standard /usr/lib.
2517
          if test "X$dir" != "X/usr/$acl_libdirstem" \
2518
             && test "X$dir" != "X/usr/$acl_libdirstem2"; then
2519
            rpathdirs="$rpathdirs $dir"
2520
          fi
2521
          next=
2522
        else
2523
          case $opt in
2524
            -L) next=yes ;;
2525
            -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'`
2526
                 dnl No need to hardcode the standard /usr/lib.
2527
                 if test "X$dir" != "X/usr/$acl_libdirstem" \
2528
                    && test "X$dir" != "X/usr/$acl_libdirstem2"; then
2529
                   rpathdirs="$rpathdirs $dir"
2530
                 fi
2531
                 next= ;;
2532
            *) next= ;;
2533
          esac
2534
        fi
2535
      done
2536
      if test "X$rpathdirs" != "X"; then
2537
        if test -n ""$3""; then
2538
          dnl libtool is used for linking. Use -R options.
2539
          for dir in $rpathdirs; do
2540
            $1="${$1}${$1:+ }-R$dir"
2541
          done
2542
        else
2543
          dnl The linker is used for linking directly.
2544
          if test -n "$acl_hardcode_libdir_separator"; then
2545
            dnl Weird platform: only the last -rpath option counts, the user
2546
            dnl must pass all path elements in one option.
2547
            alldirs=
2548
            for dir in $rpathdirs; do
2549
              alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir"
2550
            done
2551
            acl_save_libdir="$libdir"
2552
            libdir="$alldirs"
2553
            eval flag=\"$acl_hardcode_libdir_flag_spec\"
2554
            libdir="$acl_save_libdir"
2555
            $1="$flag"
2556
          else
2557
            dnl The -rpath options are cumulative.
2558
            for dir in $rpathdirs; do
2559
              acl_save_libdir="$libdir"
2560
              libdir="$dir"
2561
              eval flag=\"$acl_hardcode_libdir_flag_spec\"
2562
              libdir="$acl_save_libdir"
2563
              $1="${$1}${$1:+ }$flag"
2564
            done
2565
          fi
2566
        fi
2567
      fi
2568
    fi
2569
  fi
2570
  AC_SUBST([$1])
2571
])
2572
2573
# lib-prefix.m4 serial 7 (gettext-0.18)
2574
dnl Copyright (C) 2001-2005, 2008-2010 Free Software Foundation, Inc.
2575
dnl This file is free software; the Free Software Foundation
2576
dnl gives unlimited permission to copy and/or distribute it,
2577
dnl with or without modifications, as long as this notice is preserved.
2578
2579
dnl From Bruno Haible.
2580
2581
dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and
2582
dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't
2583
dnl require excessive bracketing.
2584
ifdef([AC_HELP_STRING],
2585
[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])],
2586
[AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])])
2587
2588
dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed
2589
dnl to access previously installed libraries. The basic assumption is that
2590
dnl a user will want packages to use other packages he previously installed
2591
dnl with the same --prefix option.
2592
dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate
2593
dnl libraries, but is otherwise very convenient.
2594
AC_DEFUN([AC_LIB_PREFIX],
2595
[
2596
  AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
2597
  AC_REQUIRE([AC_PROG_CC])
2598
  AC_REQUIRE([AC_CANONICAL_HOST])
2599
  AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
2600
  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
2601
  dnl By default, look in $includedir and $libdir.
2602
  use_additional=yes
2603
  AC_LIB_WITH_FINAL_PREFIX([
2604
    eval additional_includedir=\"$includedir\"
2605
    eval additional_libdir=\"$libdir\"
2606
  ])
2607
  AC_LIB_ARG_WITH([lib-prefix],
2608
[  --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib
2609
  --without-lib-prefix    don't search for libraries in includedir and libdir],
2610
[
2611
    if test "X$withval" = "Xno"; then
2612
      use_additional=no
2613
    else
2614
      if test "X$withval" = "X"; then
2615
        AC_LIB_WITH_FINAL_PREFIX([
2616
          eval additional_includedir=\"$includedir\"
2617
          eval additional_libdir=\"$libdir\"
2618
        ])
2619
      else
2620
        additional_includedir="$withval/include"
2621
        additional_libdir="$withval/$acl_libdirstem"
2622
      fi
2623
    fi
2624
])
2625
  if test $use_additional = yes; then
2626
    dnl Potentially add $additional_includedir to $CPPFLAGS.
2627
    dnl But don't add it
2628
    dnl   1. if it's the standard /usr/include,
2629
    dnl   2. if it's already present in $CPPFLAGS,
2630
    dnl   3. if it's /usr/local/include and we are using GCC on Linux,
2631
    dnl   4. if it doesn't exist as a directory.
2632
    if test "X$additional_includedir" != "X/usr/include"; then
2633
      haveit=
2634
      for x in $CPPFLAGS; do
2635
        AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2636
        if test "X$x" = "X-I$additional_includedir"; then
2637
          haveit=yes
2638
          break
2639
        fi
2640
      done
2641
      if test -z "$haveit"; then
2642
        if test "X$additional_includedir" = "X/usr/local/include"; then
2643
          if test -n "$GCC"; then
2644
            case $host_os in
2645
              linux* | gnu* | k*bsd*-gnu) haveit=yes;;
2646
            esac
2647
          fi
2648
        fi
2649
        if test -z "$haveit"; then
2650
          if test -d "$additional_includedir"; then
2651
            dnl Really add $additional_includedir to $CPPFLAGS.
2652
            CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir"
2653
          fi
2654
        fi
2655
      fi
2656
    fi
2657
    dnl Potentially add $additional_libdir to $LDFLAGS.
2658
    dnl But don't add it
2659
    dnl   1. if it's the standard /usr/lib,
2660
    dnl   2. if it's already present in $LDFLAGS,
2661
    dnl   3. if it's /usr/local/lib and we are using GCC on Linux,
2662
    dnl   4. if it doesn't exist as a directory.
2663
    if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
2664
      haveit=
2665
      for x in $LDFLAGS; do
2666
        AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
2667
        if test "X$x" = "X-L$additional_libdir"; then
2668
          haveit=yes
2669
          break
2670
        fi
2671
      done
2672
      if test -z "$haveit"; then
2673
        if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
2674
          if test -n "$GCC"; then
2675
            case $host_os in
2676
              linux*) haveit=yes;;
2677
            esac
2678
          fi
2679
        fi
2680
        if test -z "$haveit"; then
2681
          if test -d "$additional_libdir"; then
2682
            dnl Really add $additional_libdir to $LDFLAGS.
2683
            LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
2684
          fi
2685
        fi
2686
      fi
2687
    fi
2688
  fi
2689
])
2690
2691
dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix,
2692
dnl acl_final_exec_prefix, containing the values to which $prefix and
2693
dnl $exec_prefix will expand at the end of the configure script.
2694
AC_DEFUN([AC_LIB_PREPARE_PREFIX],
2695
[
2696
  dnl Unfortunately, prefix and exec_prefix get only finally determined
2697
  dnl at the end of configure.
2698
  if test "X$prefix" = "XNONE"; then
2699
    acl_final_prefix="$ac_default_prefix"
2700
  else
2701
    acl_final_prefix="$prefix"
2702
  fi
2703
  if test "X$exec_prefix" = "XNONE"; then
2704
    acl_final_exec_prefix='${prefix}'
2705
  else
2706
    acl_final_exec_prefix="$exec_prefix"
2707
  fi
2708
  acl_save_prefix="$prefix"
2709
  prefix="$acl_final_prefix"
2710
  eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
2711
  prefix="$acl_save_prefix"
2712
])
2713
2714
dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the
2715
dnl variables prefix and exec_prefix bound to the values they will have
2716
dnl at the end of the configure script.
2717
AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
2718
[
2719
  acl_save_prefix="$prefix"
2720
  prefix="$acl_final_prefix"
2721
  acl_save_exec_prefix="$exec_prefix"
2722
  exec_prefix="$acl_final_exec_prefix"
2723
  $1
2724
  exec_prefix="$acl_save_exec_prefix"
2725
  prefix="$acl_save_prefix"
2726
])
2727
2728
dnl AC_LIB_PREPARE_MULTILIB creates
2729
dnl - a variable acl_libdirstem, containing the basename of the libdir, either
2730
dnl   "lib" or "lib64" or "lib/64",
2731
dnl - a variable acl_libdirstem2, as a secondary possible value for
2732
dnl   acl_libdirstem, either the same as acl_libdirstem or "lib/sparcv9" or
2733
dnl   "lib/amd64".
2734
AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
2735
[
2736
  dnl There is no formal standard regarding lib and lib64.
2737
  dnl On glibc systems, the current practice is that on a system supporting
2738
  dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
2739
  dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. We determine
2740
  dnl the compiler's default mode by looking at the compiler's library search
2741
  dnl path. If at least one of its elements ends in /lib64 or points to a
2742
  dnl directory whose absolute pathname ends in /lib64, we assume a 64-bit ABI.
2743
  dnl Otherwise we use the default, namely "lib".
2744
  dnl On Solaris systems, the current practice is that on a system supporting
2745
  dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
2746
  dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or
2747
  dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib.
2748
  AC_REQUIRE([AC_CANONICAL_HOST])
2749
  acl_libdirstem=lib
2750
  acl_libdirstem2=
2751
  case "$host_os" in
2752
    solaris*)
2753
      dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment
2754
      dnl <http://docs.sun.com/app/docs/doc/816-5138/dev-env?l=en&a=view>.
2755
      dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link."
2756
      dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the
2757
      dnl symlink is missing, so we set acl_libdirstem2 too.
2758
      AC_CACHE_CHECK([for 64-bit host], [gl_cv_solaris_64bit],
2759
        [AC_EGREP_CPP([sixtyfour bits], [
2760
#ifdef _LP64
2761
sixtyfour bits
2762
#endif
2763
           ], [gl_cv_solaris_64bit=yes], [gl_cv_solaris_64bit=no])
2764
        ])
2765
      if test $gl_cv_solaris_64bit = yes; then
2766
        acl_libdirstem=lib/64
2767
        case "$host_cpu" in
2768
          sparc*)        acl_libdirstem2=lib/sparcv9 ;;
2769
          i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
2770
        esac
2771
      fi
2772
      ;;
2773
    *)
2774
      searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
2775
      if test -n "$searchpath"; then
2776
        acl_save_IFS="${IFS= 	}"; IFS=":"
2777
        for searchdir in $searchpath; do
2778
          if test -d "$searchdir"; then
2779
            case "$searchdir" in
2780
              */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
2781
              */../ | */.. )
2782
                # Better ignore directories of this form. They are misleading.
2783
                ;;
2784
              *) searchdir=`cd "$searchdir" && pwd`
2785
                 case "$searchdir" in
2786
                   */lib64 ) acl_libdirstem=lib64 ;;
2787
                 esac ;;
2788
            esac
2789
          fi
2790
        done
2791
        IFS="$acl_save_IFS"
2792
      fi
2793
      ;;
2794
  esac
2795
  test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
2796
])
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
2797
1 by Daniel Holbach
Import upstream version 0.5.1
2798
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2799
#
2800
#   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2801
#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
2802
#                 Inc.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2803
#   Written by Gordon Matzigkeit, 1996
2804
#
2805
# This file is free software; the Free Software Foundation gives
2806
# unlimited permission to copy and/or distribute it, with or without
2807
# modifications, as long as this notice is preserved.
2808
2809
m4_define([_LT_COPYING], [dnl
2810
#   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2811
#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
2812
#                 Inc.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2813
#   Written by Gordon Matzigkeit, 1996
2814
#
2815
#   This file is part of GNU Libtool.
2816
#
2817
# GNU Libtool is free software; you can redistribute it and/or
2818
# modify it under the terms of the GNU General Public License as
2819
# published by the Free Software Foundation; either version 2 of
2820
# the License, or (at your option) any later version.
2821
#
2822
# As a special exception to the GNU General Public License,
2823
# if you distribute this file as part of a program or library that
2824
# is built using GNU Libtool, you may include this file under the
2825
# same distribution terms that you use for the rest of that program.
2826
#
2827
# GNU Libtool is distributed in the hope that it will be useful,
2828
# but WITHOUT ANY WARRANTY; without even the implied warranty of
2829
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
2830
# GNU General Public License for more details.
2831
#
2832
# You should have received a copy of the GNU General Public License
2833
# along with GNU Libtool; see the file COPYING.  If not, a copy
2834
# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
2835
# obtained by writing to the Free Software Foundation, Inc.,
2836
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
2837
])
2838
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2839
# serial 57 LT_INIT
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2840
2841
2842
# LT_PREREQ(VERSION)
2843
# ------------------
2844
# Complain and exit if this libtool version is less that VERSION.
2845
m4_defun([LT_PREREQ],
2846
[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
2847
       [m4_default([$3],
2848
		   [m4_fatal([Libtool version $1 or higher is required],
2849
		             63)])],
2850
       [$2])])
2851
2852
2853
# _LT_CHECK_BUILDDIR
2854
# ------------------
2855
# Complain if the absolute build directory name contains unusual characters
2856
m4_defun([_LT_CHECK_BUILDDIR],
2857
[case `pwd` in
2858
  *\ * | *\	*)
2859
    AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
2860
esac
2861
])
2862
2863
2864
# LT_INIT([OPTIONS])
2865
# ------------------
2866
AC_DEFUN([LT_INIT],
2867
[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2868
AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2869
AC_BEFORE([$0], [LT_LANG])dnl
2870
AC_BEFORE([$0], [LT_OUTPUT])dnl
2871
AC_BEFORE([$0], [LTDL_INIT])dnl
2872
m4_require([_LT_CHECK_BUILDDIR])dnl
2873
2874
dnl Autoconf doesn't catch unexpanded LT_ macros by default:
2875
m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
2876
m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
2877
dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
2878
dnl unless we require an AC_DEFUNed macro:
2879
AC_REQUIRE([LTOPTIONS_VERSION])dnl
2880
AC_REQUIRE([LTSUGAR_VERSION])dnl
2881
AC_REQUIRE([LTVERSION_VERSION])dnl
2882
AC_REQUIRE([LTOBSOLETE_VERSION])dnl
2883
m4_require([_LT_PROG_LTMAIN])dnl
2884
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2885
_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
2886
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2887
dnl Parse OPTIONS
2888
_LT_SET_OPTIONS([$0], [$1])
1 by Daniel Holbach
Import upstream version 0.5.1
2889
2890
# This can be used to rebuild libtool when needed
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2891
LIBTOOL_DEPS="$ltmain"
1 by Daniel Holbach
Import upstream version 0.5.1
2892
2893
# Always use our own libtool.
2894
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
2895
AC_SUBST(LIBTOOL)dnl
2896
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2897
_LT_SETUP
2898
2899
# Only expand once:
2900
m4_define([LT_INIT])
2901
])# LT_INIT
2902
2903
# Old names:
2904
AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
2905
AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
2906
dnl aclocal-1.4 backwards compatibility:
2907
dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
2908
dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
2909
2910
2911
# _LT_CC_BASENAME(CC)
2912
# -------------------
2913
# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
2914
m4_defun([_LT_CC_BASENAME],
2915
[for cc_temp in $1""; do
2916
  case $cc_temp in
2917
    compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
2918
    distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
2919
    \-*) ;;
2920
    *) break;;
2921
  esac
2922
done
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2923
cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2924
])
2925
2926
2927
# _LT_FILEUTILS_DEFAULTS
2928
# ----------------------
2929
# It is okay to use these file commands and assume they have been set
2930
# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
2931
m4_defun([_LT_FILEUTILS_DEFAULTS],
2932
[: ${CP="cp -f"}
2933
: ${MV="mv -f"}
2934
: ${RM="rm -f"}
2935
])# _LT_FILEUTILS_DEFAULTS
2936
2937
2938
# _LT_SETUP
2939
# ---------
2940
m4_defun([_LT_SETUP],
2941
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
2942
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1.1.16 by Robert Ancell
Import upstream version 2.31.6
2943
AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
2944
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
2945
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2946
_LT_DECL([], [host_alias], [0], [The host system])dnl
2947
_LT_DECL([], [host], [0])dnl
2948
_LT_DECL([], [host_os], [0])dnl
2949
dnl
2950
_LT_DECL([], [build_alias], [0], [The build system])dnl
2951
_LT_DECL([], [build], [0])dnl
2952
_LT_DECL([], [build_os], [0])dnl
2953
dnl
1 by Daniel Holbach
Import upstream version 0.5.1
2954
AC_REQUIRE([AC_PROG_CC])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2955
AC_REQUIRE([LT_PATH_LD])dnl
2956
AC_REQUIRE([LT_PATH_NM])dnl
2957
dnl
1 by Daniel Holbach
Import upstream version 0.5.1
2958
AC_REQUIRE([AC_PROG_LN_S])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2959
test -z "$LN_S" && LN_S="ln -s"
2960
_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
2961
dnl
2962
AC_REQUIRE([LT_CMD_MAX_LEN])dnl
2963
_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
2964
_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
2965
dnl
2966
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2967
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
2968
m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2969
m4_require([_LT_CMD_RELOAD])dnl
2970
m4_require([_LT_CHECK_MAGIC_METHOD])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
2971
m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2972
m4_require([_LT_CMD_OLD_ARCHIVE])dnl
2973
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
2974
m4_require([_LT_WITH_SYSROOT])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
2975
2976
_LT_CONFIG_LIBTOOL_INIT([
2977
# See if we are running on zsh, and set the options which allow our
2978
# commands through without removal of \ escapes INIT.
2979
if test -n "\${ZSH_VERSION+set}" ; then
2980
   setopt NO_GLOB_SUBST
2981
fi
2982
])
2983
if test -n "${ZSH_VERSION+set}" ; then
2984
   setopt NO_GLOB_SUBST
2985
fi
2986
2987
_LT_CHECK_OBJDIR
2988
2989
m4_require([_LT_TAG_COMPILER])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
2990
2991
case $host_os in
2992
aix3*)
2993
  # AIX sometimes has problems with the GCC collect2 program.  For some
2994
  # reason, if we set the COLLECT_NAMES environment variable, the problems
2995
  # vanish in a puff of smoke.
2996
  if test "X${COLLECT_NAMES+set}" != Xset; then
2997
    COLLECT_NAMES=
2998
    export COLLECT_NAMES
2999
  fi
3000
  ;;
3001
esac
3002
3003
# Global variables:
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3004
ofile=libtool
1 by Daniel Holbach
Import upstream version 0.5.1
3005
can_build_shared=yes
3006
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3007
# All known linkers require a `.a' archive for static linking (except MSVC,
1 by Daniel Holbach
Import upstream version 0.5.1
3008
# which needs '.lib').
3009
libext=a
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3010
1 by Daniel Holbach
Import upstream version 0.5.1
3011
with_gnu_ld="$lt_cv_prog_gnu_ld"
3012
3013
old_CC="$CC"
3014
old_CFLAGS="$CFLAGS"
3015
3016
# Set sane defaults for various variables
3017
test -z "$CC" && CC=cc
3018
test -z "$LTCC" && LTCC=$CC
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3019
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1 by Daniel Holbach
Import upstream version 0.5.1
3020
test -z "$LD" && LD=ld
3021
test -z "$ac_objext" && ac_objext=o
3022
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3023
_LT_CC_BASENAME([$compiler])
3024
1 by Daniel Holbach
Import upstream version 0.5.1
3025
# Only perform the check for file, if the check method requires it
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3026
test -z "$MAGIC_CMD" && MAGIC_CMD=file
1 by Daniel Holbach
Import upstream version 0.5.1
3027
case $deplibs_check_method in
3028
file_magic*)
3029
  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3030
    _LT_PATH_MAGIC
1 by Daniel Holbach
Import upstream version 0.5.1
3031
  fi
3032
  ;;
3033
esac
3034
3035
# Use C for the default configuration in the libtool script
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3036
LT_SUPPORTED_TAG([CC])
3037
_LT_LANG_C_CONFIG
3038
_LT_LANG_DEFAULT_CONFIG
3039
_LT_CONFIG_COMMANDS
3040
])# _LT_SETUP
3041
3042
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3043
# _LT_PREPARE_SED_QUOTE_VARS
3044
# --------------------------
3045
# Define a few sed substitution that help us do robust quoting.
3046
m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
3047
[# Backslashify metacharacters that are still active within
3048
# double-quoted strings.
3049
sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
3050
3051
# Same as above, but do not quote variable references.
3052
double_quote_subst='s/\([["`\\]]\)/\\\1/g'
3053
3054
# Sed substitution to delay expansion of an escaped shell variable in a
3055
# double_quote_subst'ed string.
3056
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
3057
3058
# Sed substitution to delay expansion of an escaped single quote.
3059
delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
3060
3061
# Sed substitution to avoid accidental globbing in evaled expressions
3062
no_glob_subst='s/\*/\\\*/g'
3063
])
3064
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3065
# _LT_PROG_LTMAIN
3066
# ---------------
3067
# Note that this code is called both from `configure', and `config.status'
3068
# now that we use AC_CONFIG_COMMANDS to generate libtool.  Notably,
3069
# `config.status' has no value for ac_aux_dir unless we are using Automake,
3070
# so we pass a copy along to make sure it has a sensible value anyway.
3071
m4_defun([_LT_PROG_LTMAIN],
3072
[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
3073
_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
3074
ltmain="$ac_aux_dir/ltmain.sh"
3075
])# _LT_PROG_LTMAIN
3076
3077
3078
3079
# So that we can recreate a full libtool script including additional
3080
# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
3081
# in macros and then make a single call at the end using the `libtool'
3082
# label.
3083
3084
3085
# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
3086
# ----------------------------------------
3087
# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
3088
m4_define([_LT_CONFIG_LIBTOOL_INIT],
3089
[m4_ifval([$1],
3090
          [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
3091
                     [$1
3092
])])])
3093
3094
# Initialize.
3095
m4_define([_LT_OUTPUT_LIBTOOL_INIT])
3096
3097
3098
# _LT_CONFIG_LIBTOOL([COMMANDS])
3099
# ------------------------------
3100
# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
3101
m4_define([_LT_CONFIG_LIBTOOL],
3102
[m4_ifval([$1],
3103
          [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
3104
                     [$1
3105
])])])
3106
3107
# Initialize.
3108
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
3109
3110
3111
# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
3112
# -----------------------------------------------------
3113
m4_defun([_LT_CONFIG_SAVE_COMMANDS],
3114
[_LT_CONFIG_LIBTOOL([$1])
3115
_LT_CONFIG_LIBTOOL_INIT([$2])
3116
])
3117
3118
3119
# _LT_FORMAT_COMMENT([COMMENT])
3120
# -----------------------------
3121
# Add leading comment marks to the start of each line, and a trailing
3122
# full-stop to the whole comment if one is not present already.
3123
m4_define([_LT_FORMAT_COMMENT],
3124
[m4_ifval([$1], [
3125
m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
3126
              [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
3127
)])
3128
3129
3130
3131
3132
3133
# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
3134
# -------------------------------------------------------------------
3135
# CONFIGNAME is the name given to the value in the libtool script.
3136
# VARNAME is the (base) name used in the configure script.
3137
# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
3138
# VARNAME.  Any other value will be used directly.
3139
m4_define([_LT_DECL],
3140
[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
3141
    [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
3142
	[m4_ifval([$1], [$1], [$2])])
3143
    lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
3144
    m4_ifval([$4],
3145
	[lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
3146
    lt_dict_add_subkey([lt_decl_dict], [$2],
3147
	[tagged?], [m4_ifval([$5], [yes], [no])])])
3148
])
3149
3150
3151
# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
3152
# --------------------------------------------------------
3153
m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
3154
3155
3156
# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
3157
# ------------------------------------------------
3158
m4_define([lt_decl_tag_varnames],
3159
[_lt_decl_filter([tagged?], [yes], $@)])
3160
3161
3162
# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
3163
# ---------------------------------------------------------
3164
m4_define([_lt_decl_filter],
3165
[m4_case([$#],
3166
  [0], [m4_fatal([$0: too few arguments: $#])],
3167
  [1], [m4_fatal([$0: too few arguments: $#: $1])],
3168
  [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
3169
  [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
3170
  [lt_dict_filter([lt_decl_dict], $@)])[]dnl
3171
])
3172
3173
3174
# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
3175
# --------------------------------------------------
3176
m4_define([lt_decl_quote_varnames],
3177
[_lt_decl_filter([value], [1], $@)])
3178
3179
3180
# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
3181
# ---------------------------------------------------
3182
m4_define([lt_decl_dquote_varnames],
3183
[_lt_decl_filter([value], [2], $@)])
3184
3185
3186
# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
3187
# ---------------------------------------------------
3188
m4_define([lt_decl_varnames_tagged],
3189
[m4_assert([$# <= 2])dnl
3190
_$0(m4_quote(m4_default([$1], [[, ]])),
3191
    m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
3192
    m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
3193
m4_define([_lt_decl_varnames_tagged],
3194
[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
3195
3196
3197
# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
3198
# ------------------------------------------------
3199
m4_define([lt_decl_all_varnames],
3200
[_$0(m4_quote(m4_default([$1], [[, ]])),
3201
     m4_if([$2], [],
3202
	   m4_quote(lt_decl_varnames),
3203
	m4_quote(m4_shift($@))))[]dnl
3204
])
3205
m4_define([_lt_decl_all_varnames],
3206
[lt_join($@, lt_decl_varnames_tagged([$1],
3207
			lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
3208
])
3209
3210
3211
# _LT_CONFIG_STATUS_DECLARE([VARNAME])
3212
# ------------------------------------
3213
# Quote a variable value, and forward it to `config.status' so that its
3214
# declaration there will have the same value as in `configure'.  VARNAME
3215
# must have a single quote delimited value for this to work.
3216
m4_define([_LT_CONFIG_STATUS_DECLARE],
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3217
[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3218
3219
3220
# _LT_CONFIG_STATUS_DECLARATIONS
3221
# ------------------------------
3222
# We delimit libtool config variables with single quotes, so when
3223
# we write them to config.status, we have to be sure to quote all
3224
# embedded single quotes properly.  In configure, this macro expands
3225
# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
3226
#
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3227
#    <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3228
m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
3229
[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
3230
    [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
3231
3232
3233
# _LT_LIBTOOL_TAGS
3234
# ----------------
3235
# Output comment and list of tags supported by the script
3236
m4_defun([_LT_LIBTOOL_TAGS],
3237
[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
3238
available_tags="_LT_TAGS"dnl
3239
])
3240
3241
3242
# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
3243
# -----------------------------------
3244
# Extract the dictionary values for VARNAME (optionally with TAG) and
3245
# expand to a commented shell variable setting:
3246
#
3247
#    # Some comment about what VAR is for.
3248
#    visible_name=$lt_internal_name
3249
m4_define([_LT_LIBTOOL_DECLARE],
3250
[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
3251
					   [description])))[]dnl
3252
m4_pushdef([_libtool_name],
3253
    m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
3254
m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
3255
    [0], [_libtool_name=[$]$1],
3256
    [1], [_libtool_name=$lt_[]$1],
3257
    [2], [_libtool_name=$lt_[]$1],
3258
    [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
3259
m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
3260
])
3261
3262
3263
# _LT_LIBTOOL_CONFIG_VARS
3264
# -----------------------
3265
# Produce commented declarations of non-tagged libtool config variables
3266
# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
3267
# script.  Tagged libtool config variables (even for the LIBTOOL CONFIG
3268
# section) are produced by _LT_LIBTOOL_TAG_VARS.
3269
m4_defun([_LT_LIBTOOL_CONFIG_VARS],
3270
[m4_foreach([_lt_var],
3271
    m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
3272
    [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
3273
3274
3275
# _LT_LIBTOOL_TAG_VARS(TAG)
3276
# -------------------------
3277
m4_define([_LT_LIBTOOL_TAG_VARS],
3278
[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
3279
    [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
3280
3281
3282
# _LT_TAGVAR(VARNAME, [TAGNAME])
3283
# ------------------------------
3284
m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
3285
3286
3287
# _LT_CONFIG_COMMANDS
1 by Daniel Holbach
Import upstream version 0.5.1
3288
# -------------------
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3289
# Send accumulated output to $CONFIG_STATUS.  Thanks to the lists of
3290
# variables for single and double quote escaping we saved from calls
3291
# to _LT_DECL, we can put quote escaped variables declarations
3292
# into `config.status', and then the shell code to quote escape them in
3293
# for loops in `config.status'.  Finally, any additional code accumulated
3294
# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
3295
m4_defun([_LT_CONFIG_COMMANDS],
3296
[AC_PROVIDE_IFELSE([LT_OUTPUT],
3297
	dnl If the libtool generation code has been placed in $CONFIG_LT,
3298
	dnl instead of duplicating it all over again into config.status,
3299
	dnl then we will have config.status run $CONFIG_LT later, so it
3300
	dnl needs to know what name is stored there:
3301
        [AC_CONFIG_COMMANDS([libtool],
3302
            [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
3303
    dnl If the libtool generation code is destined for config.status,
3304
    dnl expand the accumulated commands and init code now:
3305
    [AC_CONFIG_COMMANDS([libtool],
3306
        [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
3307
])#_LT_CONFIG_COMMANDS
3308
3309
3310
# Initialize.
3311
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
3312
[
3313
3314
# The HP-UX ksh and POSIX shell print the target directory to stdout
3315
# if CDPATH is set.
3316
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
3317
3318
sed_quote_subst='$sed_quote_subst'
3319
double_quote_subst='$double_quote_subst'
3320
delay_variable_subst='$delay_variable_subst'
3321
_LT_CONFIG_STATUS_DECLARATIONS
3322
LTCC='$LTCC'
3323
LTCFLAGS='$LTCFLAGS'
3324
compiler='$compiler_DEFAULT'
3325
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3326
# A function that is used when there is no print builtin or printf.
3327
func_fallback_echo ()
3328
{
3329
  eval 'cat <<_LTECHO_EOF
3330
\$[]1
3331
_LTECHO_EOF'
3332
}
3333
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3334
# Quote evaled strings.
3335
for var in lt_decl_all_varnames([[ \
3336
]], lt_decl_quote_varnames); do
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3337
    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3338
    *[[\\\\\\\`\\"\\\$]]*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3339
      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3340
      ;;
3341
    *)
3342
      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
3343
      ;;
3344
    esac
3345
done
3346
3347
# Double-quote double-evaled strings.
3348
for var in lt_decl_all_varnames([[ \
3349
]], lt_decl_dquote_varnames); do
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3350
    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3351
    *[[\\\\\\\`\\"\\\$]]*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3352
      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3353
      ;;
3354
    *)
3355
      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
3356
      ;;
3357
    esac
3358
done
3359
3360
_LT_OUTPUT_LIBTOOL_INIT
3361
])
3362
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3363
# _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
3364
# ------------------------------------
3365
# Generate a child script FILE with all initialization necessary to
3366
# reuse the environment learned by the parent script, and make the
3367
# file executable.  If COMMENT is supplied, it is inserted after the
3368
# `#!' sequence but before initialization text begins.  After this
3369
# macro, additional text can be appended to FILE to form the body of
3370
# the child script.  The macro ends with non-zero status if the
3371
# file could not be fully written (such as if the disk is full).
3372
m4_ifdef([AS_INIT_GENERATED],
3373
[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
3374
[m4_defun([_LT_GENERATED_FILE_INIT],
3375
[m4_require([AS_PREPARE])]dnl
3376
[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
3377
[lt_write_fail=0
3378
cat >$1 <<_ASEOF || lt_write_fail=1
3379
#! $SHELL
3380
# Generated by $as_me.
3381
$2
3382
SHELL=\${CONFIG_SHELL-$SHELL}
3383
export SHELL
3384
_ASEOF
3385
cat >>$1 <<\_ASEOF || lt_write_fail=1
3386
AS_SHELL_SANITIZE
3387
_AS_PREPARE
3388
exec AS_MESSAGE_FD>&1
3389
_ASEOF
3390
test $lt_write_fail = 0 && chmod +x $1[]dnl
3391
m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3392
3393
# LT_OUTPUT
3394
# ---------
3395
# This macro allows early generation of the libtool script (before
3396
# AC_OUTPUT is called), incase it is used in configure for compilation
3397
# tests.
3398
AC_DEFUN([LT_OUTPUT],
3399
[: ${CONFIG_LT=./config.lt}
3400
AC_MSG_NOTICE([creating $CONFIG_LT])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3401
_LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
3402
[# Run this file to recreate a libtool stub with the current configuration.])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3403
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3404
cat >>"$CONFIG_LT" <<\_LTEOF
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3405
lt_cl_silent=false
3406
exec AS_MESSAGE_LOG_FD>>config.log
3407
{
3408
  echo
3409
  AS_BOX([Running $as_me.])
3410
} >&AS_MESSAGE_LOG_FD
3411
3412
lt_cl_help="\
3413
\`$as_me' creates a local libtool stub from the current configuration,
3414
for use in further configure time tests before the real libtool is
3415
generated.
3416
3417
Usage: $[0] [[OPTIONS]]
3418
3419
  -h, --help      print this help, then exit
3420
  -V, --version   print version number, then exit
3421
  -q, --quiet     do not print progress messages
3422
  -d, --debug     don't remove temporary files
3423
3424
Report bugs to <bug-libtool@gnu.org>."
3425
3426
lt_cl_version="\
3427
m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
3428
m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
3429
configured by $[0], generated by m4_PACKAGE_STRING.
3430
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3431
Copyright (C) 2010 Free Software Foundation, Inc.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3432
This config.lt script is free software; the Free Software Foundation
3433
gives unlimited permision to copy, distribute and modify it."
3434
3435
while test $[#] != 0
3436
do
3437
  case $[1] in
3438
    --version | --v* | -V )
3439
      echo "$lt_cl_version"; exit 0 ;;
3440
    --help | --h* | -h )
3441
      echo "$lt_cl_help"; exit 0 ;;
3442
    --debug | --d* | -d )
3443
      debug=: ;;
3444
    --quiet | --q* | --silent | --s* | -q )
3445
      lt_cl_silent=: ;;
3446
3447
    -*) AC_MSG_ERROR([unrecognized option: $[1]
3448
Try \`$[0] --help' for more information.]) ;;
3449
3450
    *) AC_MSG_ERROR([unrecognized argument: $[1]
3451
Try \`$[0] --help' for more information.]) ;;
3452
  esac
3453
  shift
3454
done
3455
3456
if $lt_cl_silent; then
3457
  exec AS_MESSAGE_FD>/dev/null
3458
fi
3459
_LTEOF
3460
3461
cat >>"$CONFIG_LT" <<_LTEOF
3462
_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
3463
_LTEOF
3464
3465
cat >>"$CONFIG_LT" <<\_LTEOF
3466
AC_MSG_NOTICE([creating $ofile])
3467
_LT_OUTPUT_LIBTOOL_COMMANDS
3468
AS_EXIT(0)
3469
_LTEOF
3470
chmod +x "$CONFIG_LT"
3471
3472
# configure is writing to config.log, but config.lt does its own redirection,
3473
# appending to config.log, which fails on DOS, as config.log is still kept
3474
# open by configure.  Here we exec the FD to /dev/null, effectively closing
3475
# config.log, so it can be properly (re)opened and appended to by config.lt.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3476
lt_cl_success=:
3477
test "$silent" = yes &&
3478
  lt_config_lt_args="$lt_config_lt_args --quiet"
3479
exec AS_MESSAGE_LOG_FD>/dev/null
3480
$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
3481
exec AS_MESSAGE_LOG_FD>>config.log
3482
$lt_cl_success || AS_EXIT(1)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3483
])# LT_OUTPUT
3484
3485
3486
# _LT_CONFIG(TAG)
3487
# ---------------
3488
# If TAG is the built-in tag, create an initial libtool script with a
3489
# default configuration from the untagged config vars.  Otherwise add code
3490
# to config.status for appending the configuration named by TAG from the
3491
# matching tagged config vars.
3492
m4_defun([_LT_CONFIG],
3493
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3494
_LT_CONFIG_SAVE_COMMANDS([
3495
  m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
3496
  m4_if(_LT_TAG, [C], [
3497
    # See if we are running on zsh, and set the options which allow our
3498
    # commands through without removal of \ escapes.
3499
    if test -n "${ZSH_VERSION+set}" ; then
3500
      setopt NO_GLOB_SUBST
3501
    fi
3502
3503
    cfgfile="${ofile}T"
3504
    trap "$RM \"$cfgfile\"; exit 1" 1 2 15
3505
    $RM "$cfgfile"
3506
3507
    cat <<_LT_EOF >> "$cfgfile"
3508
#! $SHELL
3509
3510
# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
3511
# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
3512
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3513
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
3514
#
3515
_LT_COPYING
3516
_LT_LIBTOOL_TAGS
3517
3518
# ### BEGIN LIBTOOL CONFIG
3519
_LT_LIBTOOL_CONFIG_VARS
3520
_LT_LIBTOOL_TAG_VARS
3521
# ### END LIBTOOL CONFIG
3522
3523
_LT_EOF
3524
3525
  case $host_os in
3526
  aix3*)
3527
    cat <<\_LT_EOF >> "$cfgfile"
3528
# AIX sometimes has problems with the GCC collect2 program.  For some
3529
# reason, if we set the COLLECT_NAMES environment variable, the problems
3530
# vanish in a puff of smoke.
3531
if test "X${COLLECT_NAMES+set}" != Xset; then
3532
  COLLECT_NAMES=
3533
  export COLLECT_NAMES
3534
fi
3535
_LT_EOF
3536
    ;;
3537
  esac
3538
3539
  _LT_PROG_LTMAIN
3540
3541
  # We use sed instead of cat because bash on DJGPP gets confused if
3542
  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
3543
  # text mode, it properly converts lines to CR/LF.  This bash problem
3544
  # is reportedly fixed, but why not run on old versions too?
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
3545
  sed '$q' "$ltmain" >> "$cfgfile" \
3546
     || (rm -f "$cfgfile"; exit 1)
3547
3548
  _LT_PROG_REPLACE_SHELLFNS
3549
3550
   mv -f "$cfgfile" "$ofile" ||
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3551
    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
3552
  chmod +x "$ofile"
3553
],
3554
[cat <<_LT_EOF >> "$ofile"
3555
3556
dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
3557
dnl in a comment (ie after a #).
3558
# ### BEGIN LIBTOOL TAG CONFIG: $1
3559
_LT_LIBTOOL_TAG_VARS(_LT_TAG)
3560
# ### END LIBTOOL TAG CONFIG: $1
3561
_LT_EOF
3562
])dnl /m4_if
3563
],
3564
[m4_if([$1], [], [
3565
    PACKAGE='$PACKAGE'
3566
    VERSION='$VERSION'
3567
    TIMESTAMP='$TIMESTAMP'
3568
    RM='$RM'
3569
    ofile='$ofile'], [])
3570
])dnl /_LT_CONFIG_SAVE_COMMANDS
3571
])# _LT_CONFIG
3572
3573
3574
# LT_SUPPORTED_TAG(TAG)
3575
# ---------------------
3576
# Trace this macro to discover what tags are supported by the libtool
3577
# --tag option, using:
3578
#    autoconf --trace 'LT_SUPPORTED_TAG:$1'
3579
AC_DEFUN([LT_SUPPORTED_TAG], [])
3580
3581
3582
# C support is built-in for now
3583
m4_define([_LT_LANG_C_enabled], [])
3584
m4_define([_LT_TAGS], [])
3585
3586
3587
# LT_LANG(LANG)
3588
# -------------
3589
# Enable libtool support for the given language if not already enabled.
3590
AC_DEFUN([LT_LANG],
3591
[AC_BEFORE([$0], [LT_OUTPUT])dnl
3592
m4_case([$1],
3593
  [C],			[_LT_LANG(C)],
3594
  [C++],		[_LT_LANG(CXX)],
3595
  [Java],		[_LT_LANG(GCJ)],
3596
  [Fortran 77],		[_LT_LANG(F77)],
3597
  [Fortran],		[_LT_LANG(FC)],
3598
  [Windows Resource],	[_LT_LANG(RC)],
3599
  [m4_ifdef([_LT_LANG_]$1[_CONFIG],
3600
    [_LT_LANG($1)],
3601
    [m4_fatal([$0: unsupported language: "$1"])])])dnl
3602
])# LT_LANG
3603
3604
3605
# _LT_LANG(LANGNAME)
3606
# ------------------
3607
m4_defun([_LT_LANG],
3608
[m4_ifdef([_LT_LANG_]$1[_enabled], [],
3609
  [LT_SUPPORTED_TAG([$1])dnl
3610
  m4_append([_LT_TAGS], [$1 ])dnl
3611
  m4_define([_LT_LANG_]$1[_enabled], [])dnl
3612
  _LT_LANG_$1_CONFIG($1)])dnl
3613
])# _LT_LANG
3614
3615
3616
# _LT_LANG_DEFAULT_CONFIG
3617
# -----------------------
3618
m4_defun([_LT_LANG_DEFAULT_CONFIG],
3619
[AC_PROVIDE_IFELSE([AC_PROG_CXX],
3620
  [LT_LANG(CXX)],
3621
  [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
3622
3623
AC_PROVIDE_IFELSE([AC_PROG_F77],
3624
  [LT_LANG(F77)],
3625
  [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
3626
3627
AC_PROVIDE_IFELSE([AC_PROG_FC],
3628
  [LT_LANG(FC)],
3629
  [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
3630
3631
dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
3632
dnl pulling things in needlessly.
3633
AC_PROVIDE_IFELSE([AC_PROG_GCJ],
3634
  [LT_LANG(GCJ)],
3635
  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
3636
    [LT_LANG(GCJ)],
3637
    [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
3638
      [LT_LANG(GCJ)],
3639
      [m4_ifdef([AC_PROG_GCJ],
3640
	[m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
3641
       m4_ifdef([A][M_PROG_GCJ],
3642
	[m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
3643
       m4_ifdef([LT_PROG_GCJ],
3644
	[m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
3645
3646
AC_PROVIDE_IFELSE([LT_PROG_RC],
3647
  [LT_LANG(RC)],
3648
  [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
3649
])# _LT_LANG_DEFAULT_CONFIG
3650
3651
# Obsolete macros:
3652
AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
3653
AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
3654
AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
3655
AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3656
AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3657
dnl aclocal-1.4 backwards compatibility:
3658
dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
3659
dnl AC_DEFUN([AC_LIBTOOL_F77], [])
3660
dnl AC_DEFUN([AC_LIBTOOL_FC], [])
3661
dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3662
dnl AC_DEFUN([AC_LIBTOOL_RC], [])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3663
3664
3665
# _LT_TAG_COMPILER
3666
# ----------------
3667
m4_defun([_LT_TAG_COMPILER],
1 by Daniel Holbach
Import upstream version 0.5.1
3668
[AC_REQUIRE([AC_PROG_CC])dnl
3669
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3670
_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
3671
_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
3672
_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
3673
_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
3674
1 by Daniel Holbach
Import upstream version 0.5.1
3675
# If no C compiler was specified, use CC.
3676
LTCC=${LTCC-"$CC"}
3677
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3678
# If no C compiler flags were specified, use CFLAGS.
3679
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
3680
1 by Daniel Holbach
Import upstream version 0.5.1
3681
# Allow CC to be a program name with arguments.
3682
compiler=$CC
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3683
])# _LT_TAG_COMPILER
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3684
3685
3686
# _LT_COMPILER_BOILERPLATE
3687
# ------------------------
3688
# Check for compiler boilerplate output or warnings with
3689
# the simple compiler test code.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3690
m4_defun([_LT_COMPILER_BOILERPLATE],
3691
[m4_require([_LT_DECL_SED])dnl
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
3692
ac_outfile=conftest.$ac_objext
3693
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3694
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
3695
_lt_compiler_boilerplate=`cat conftest.err`
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3696
$RM conftest*
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3697
])# _LT_COMPILER_BOILERPLATE
3698
3699
3700
# _LT_LINKER_BOILERPLATE
3701
# ----------------------
3702
# Check for linker boilerplate output or warnings with
3703
# the simple link test code.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3704
m4_defun([_LT_LINKER_BOILERPLATE],
3705
[m4_require([_LT_DECL_SED])dnl
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
3706
ac_outfile=conftest.$ac_objext
3707
echo "$lt_simple_link_test_code" >conftest.$ac_ext
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3708
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
3709
_lt_linker_boilerplate=`cat conftest.err`
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3710
$RM -r conftest*
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3711
])# _LT_LINKER_BOILERPLATE
3712
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3713
# _LT_REQUIRED_DARWIN_CHECKS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3714
# -------------------------
3715
m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3716
  case $host_os in
3717
    rhapsody* | darwin*)
3718
    AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
3719
    AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3720
    AC_CHECK_TOOL([LIPO], [lipo], [:])
3721
    AC_CHECK_TOOL([OTOOL], [otool], [:])
3722
    AC_CHECK_TOOL([OTOOL64], [otool64], [:])
3723
    _LT_DECL([], [DSYMUTIL], [1],
3724
      [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
3725
    _LT_DECL([], [NMEDIT], [1],
3726
      [Tool to change global to local symbols on Mac OS X])
3727
    _LT_DECL([], [LIPO], [1],
3728
      [Tool to manipulate fat objects and archives on Mac OS X])
3729
    _LT_DECL([], [OTOOL], [1],
3730
      [ldd/readelf like tool for Mach-O binaries on Mac OS X])
3731
    _LT_DECL([], [OTOOL64], [1],
3732
      [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3733
3734
    AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
3735
      [lt_cv_apple_cc_single_mod=no
3736
      if test -z "${LT_MULTI_MODULE}"; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3737
	# By default we will add the -single_module flag. You can override
3738
	# by either setting the environment variable LT_MULTI_MODULE
3739
	# non-empty at configure time, or by adding -multi_module to the
3740
	# link flags.
3741
	rm -rf libconftest.dylib*
3742
	echo "int foo(void){return 1;}" > conftest.c
3743
	echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
3744
-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
3745
	$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
3746
	  -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
3747
        _lt_result=$?
3748
	if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
3749
	  lt_cv_apple_cc_single_mod=yes
3750
	else
3751
	  cat conftest.err >&AS_MESSAGE_LOG_FD
3752
	fi
3753
	rm -rf libconftest.dylib*
3754
	rm -f conftest.*
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3755
      fi])
3756
    AC_CACHE_CHECK([for -exported_symbols_list linker flag],
3757
      [lt_cv_ld_exported_symbols_list],
3758
      [lt_cv_ld_exported_symbols_list=no
3759
      save_LDFLAGS=$LDFLAGS
3760
      echo "_main" > conftest.sym
3761
      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
3762
      AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3763
	[lt_cv_ld_exported_symbols_list=yes],
3764
	[lt_cv_ld_exported_symbols_list=no])
3765
	LDFLAGS="$save_LDFLAGS"
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3766
    ])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3767
    AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
3768
      [lt_cv_ld_force_load=no
3769
      cat > conftest.c << _LT_EOF
3770
int forced_loaded() { return 2;}
3771
_LT_EOF
3772
      echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
3773
      $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
3774
      echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
3775
      $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
3776
      echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
3777
      $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
3778
      cat > conftest.c << _LT_EOF
3779
int main() { return 0;}
3780
_LT_EOF
3781
      echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
3782
      $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
3783
      _lt_result=$?
3784
      if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
3785
	lt_cv_ld_force_load=yes
3786
      else
3787
	cat conftest.err >&AS_MESSAGE_LOG_FD
3788
      fi
3789
        rm -f conftest.err libconftest.a conftest conftest.c
3790
        rm -rf conftest.dSYM
3791
    ])
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3792
    case $host_os in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3793
    rhapsody* | darwin1.[[012]])
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3794
      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
3795
    darwin1.*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3796
      _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
3797
    darwin*) # darwin 5.x on
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3798
      # if running on 10.5 or later, the deployment target defaults
3799
      # to the OS version, if on x86, and 10.4, the deployment
3800
      # target defaults to 10.4. Don't you love it?
3801
      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3802
	10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
3803
	  _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
3804
	10.[[012]]*)
3805
	  _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
3806
	10.*)
3807
	  _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3808
      esac
3809
    ;;
3810
  esac
3811
    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
3812
      _lt_dar_single_mod='$single_module'
3813
    fi
3814
    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
3815
      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
3816
    else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3817
      _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3818
    fi
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3819
    if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3820
      _lt_dsymutil='~$DSYMUTIL $lib || :'
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
3821
    else
3822
      _lt_dsymutil=
3823
    fi
3824
    ;;
3825
  esac
3826
])
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
3827
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3828
3829
# _LT_DARWIN_LINKER_FEATURES
3830
# --------------------------
3831
# Checks for linker and compiler features on darwin
3832
m4_defun([_LT_DARWIN_LINKER_FEATURES],
3833
[
3834
  m4_require([_LT_REQUIRED_DARWIN_CHECKS])
3835
  _LT_TAGVAR(archive_cmds_need_lc, $1)=no
3836
  _LT_TAGVAR(hardcode_direct, $1)=no
3837
  _LT_TAGVAR(hardcode_automatic, $1)=yes
3838
  _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3839
  if test "$lt_cv_ld_force_load" = "yes"; then
3840
    _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
3841
  else
3842
    _LT_TAGVAR(whole_archive_flag_spec, $1)=''
3843
  fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3844
  _LT_TAGVAR(link_all_deplibs, $1)=yes
3845
  _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
3846
  case $cc_basename in
3847
     ifort*) _lt_dar_can_shared=yes ;;
3848
     *) _lt_dar_can_shared=$GCC ;;
3849
  esac
3850
  if test "$_lt_dar_can_shared" = "yes"; then
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3851
    output_verbose_link_cmd=func_echo_all
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3852
    _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
3853
    _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
3854
    _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
3855
    _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
3856
    m4_if([$1], [CXX],
3857
[   if test "$lt_cv_apple_cc_single_mod" != "yes"; then
3858
      _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
3859
      _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
3860
    fi
3861
],[])
3862
  else
3863
  _LT_TAGVAR(ld_shlibs, $1)=no
3864
  fi
3865
])
3866
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
3867
# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
3868
# ----------------------------------
1 by Daniel Holbach
Import upstream version 0.5.1
3869
# Links a minimal program and checks the executable
3870
# for the system default hardcoded library path. In most cases,
3871
# this is /usr/lib:/lib, but when the MPI compilers are used
3872
# the location of the communication and MPI libs are included too.
3873
# If we don't find anything, use the default library path according
3874
# to the aix ld manual.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
3875
# Store the results from the different compilers for each TAGNAME.
3876
# Allow to override them for all tags through lt_cv_aix_libpath.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3877
m4_defun([_LT_SYS_MODULE_PATH_AIX],
3878
[m4_require([_LT_DECL_SED])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
3879
if test "${lt_cv_aix_libpath+set}" = set; then
3880
  aix_libpath=$lt_cv_aix_libpath
3881
else
3882
  AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
3883
  [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
3884
  lt_aix_libpath_sed='[
3885
      /Import File Strings/,/^$/ {
3886
	  /^0/ {
3887
	      s/^0  *\([^ ]*\) *$/\1/
3888
	      p
3889
	  }
3890
      }]'
3891
  _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
3892
  # Check for a 64-bit object if we didn't find anything.
3893
  if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
3894
    _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
3895
  fi],[])
3896
  if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
3897
    _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
3898
  fi
3899
  ])
3900
  aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
3901
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3902
])# _LT_SYS_MODULE_PATH_AIX
3903
3904
3905
# _LT_SHELL_INIT(ARG)
3906
# -------------------
3907
m4_define([_LT_SHELL_INIT],
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3908
[m4_divert_text([M4SH-INIT], [$1
3909
])])# _LT_SHELL_INIT
3910
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3911
3912
3913
# _LT_PROG_ECHO_BACKSLASH
3914
# -----------------------
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3915
# Find how we can fake an echo command that does not interpret backslash.
3916
# In particular, with Autoconf 2.60 or later we add some code to the start
3917
# of the generated configure script which will find a shell with a builtin
3918
# printf (which we can use as an echo command).
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3919
m4_defun([_LT_PROG_ECHO_BACKSLASH],
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3920
[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
3921
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
3922
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
3923
3924
AC_MSG_CHECKING([how to print strings])
3925
# Test print first, because it will be a builtin if present.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
3926
if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3927
   test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
3928
  ECHO='print -r --'
3929
elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
3930
  ECHO='printf %s\n'
3931
else
3932
  # Use this function as a fallback that always works.
3933
  func_fallback_echo ()
3934
  {
3935
    eval 'cat <<_LTECHO_EOF
3936
$[]1
3937
_LTECHO_EOF'
3938
  }
3939
  ECHO='func_fallback_echo'
3940
fi
3941
3942
# func_echo_all arg...
3943
# Invoke $ECHO with all args, space-separated.
3944
func_echo_all ()
3945
{
3946
    $ECHO "$*" 
3947
}
3948
3949
case "$ECHO" in
3950
  printf*) AC_MSG_RESULT([printf]) ;;
3951
  print*) AC_MSG_RESULT([print -r]) ;;
3952
  *) AC_MSG_RESULT([cat]) ;;
1 by Daniel Holbach
Import upstream version 0.5.1
3953
esac
3954
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3955
m4_ifdef([_AS_DETECT_SUGGESTED],
3956
[_AS_DETECT_SUGGESTED([
3957
  test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
3958
    ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
3959
    ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
3960
    ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
3961
    PATH=/empty FPATH=/empty; export PATH FPATH
3962
    test "X`printf %s $ECHO`" = "X$ECHO" \
3963
      || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
3964
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3965
_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
3966
_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
3967
])# _LT_PROG_ECHO_BACKSLASH
3968
3969
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
3970
# _LT_WITH_SYSROOT
3971
# ----------------
3972
AC_DEFUN([_LT_WITH_SYSROOT],
3973
[AC_MSG_CHECKING([for sysroot])
3974
AC_ARG_WITH([sysroot],
3975
[  --with-sysroot[=DIR] Search for dependent libraries within DIR
3976
                        (or the compiler's sysroot if not specified).],
3977
[], [with_sysroot=no])
3978
3979
dnl lt_sysroot will always be passed unquoted.  We quote it here
3980
dnl in case the user passed a directory name.
3981
lt_sysroot=
3982
case ${with_sysroot} in #(
3983
 yes)
3984
   if test "$GCC" = yes; then
3985
     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
3986
   fi
3987
   ;; #(
3988
 /*)
3989
   lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
3990
   ;; #(
3991
 no|'')
3992
   ;; #(
3993
 *)
3994
   AC_MSG_RESULT([${with_sysroot}])
3995
   AC_MSG_ERROR([The sysroot must be an absolute path.])
3996
   ;;
3997
esac
3998
3999
 AC_MSG_RESULT([${lt_sysroot:-no}])
4000
_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
4001
[dependent libraries, and in which our libraries should be installed.])])
4002
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4003
# _LT_ENABLE_LOCK
4004
# ---------------
4005
m4_defun([_LT_ENABLE_LOCK],
1 by Daniel Holbach
Import upstream version 0.5.1
4006
[AC_ARG_ENABLE([libtool-lock],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4007
  [AS_HELP_STRING([--disable-libtool-lock],
4008
    [avoid locking (might break parallel builds)])])
1 by Daniel Holbach
Import upstream version 0.5.1
4009
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
4010
4011
# Some flags need to be propagated to the compiler or linker for good
4012
# libtool support.
4013
case $host in
4014
ia64-*-hpux*)
4015
  # Find out which ABI we are using.
4016
  echo 'int i;' > conftest.$ac_ext
4017
  if AC_TRY_EVAL(ac_compile); then
4018
    case `/usr/bin/file conftest.$ac_objext` in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4019
      *ELF-32*)
4020
	HPUX_IA64_MODE="32"
4021
	;;
4022
      *ELF-64*)
4023
	HPUX_IA64_MODE="64"
4024
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
4025
    esac
4026
  fi
4027
  rm -rf conftest*
4028
  ;;
4029
*-*-irix6*)
4030
  # Find out which ABI we are using.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4031
  echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1 by Daniel Holbach
Import upstream version 0.5.1
4032
  if AC_TRY_EVAL(ac_compile); then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4033
    if test "$lt_cv_prog_gnu_ld" = yes; then
4034
      case `/usr/bin/file conftest.$ac_objext` in
4035
	*32-bit*)
4036
	  LD="${LD-ld} -melf32bsmip"
4037
	  ;;
4038
	*N32*)
4039
	  LD="${LD-ld} -melf32bmipn32"
4040
	  ;;
4041
	*64-bit*)
4042
	  LD="${LD-ld} -melf64bmip"
4043
	;;
4044
      esac
4045
    else
4046
      case `/usr/bin/file conftest.$ac_objext` in
4047
	*32-bit*)
4048
	  LD="${LD-ld} -32"
4049
	  ;;
4050
	*N32*)
4051
	  LD="${LD-ld} -n32"
4052
	  ;;
4053
	*64-bit*)
4054
	  LD="${LD-ld} -64"
4055
	  ;;
4056
      esac
4057
    fi
1 by Daniel Holbach
Import upstream version 0.5.1
4058
  fi
4059
  rm -rf conftest*
4060
  ;;
4061
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4062
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4063
s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1 by Daniel Holbach
Import upstream version 0.5.1
4064
  # Find out which ABI we are using.
4065
  echo 'int i;' > conftest.$ac_ext
4066
  if AC_TRY_EVAL(ac_compile); then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4067
    case `/usr/bin/file conftest.o` in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4068
      *32-bit*)
4069
	case $host in
4070
	  x86_64-*kfreebsd*-gnu)
4071
	    LD="${LD-ld} -m elf_i386_fbsd"
4072
	    ;;
4073
	  x86_64-*linux*)
4074
	    LD="${LD-ld} -m elf_i386"
4075
	    ;;
4076
	  ppc64-*linux*|powerpc64-*linux*)
4077
	    LD="${LD-ld} -m elf32ppclinux"
4078
	    ;;
4079
	  s390x-*linux*)
4080
	    LD="${LD-ld} -m elf_s390"
4081
	    ;;
4082
	  sparc64-*linux*)
4083
	    LD="${LD-ld} -m elf32_sparc"
4084
	    ;;
4085
	esac
4086
	;;
4087
      *64-bit*)
4088
	case $host in
4089
	  x86_64-*kfreebsd*-gnu)
4090
	    LD="${LD-ld} -m elf_x86_64_fbsd"
4091
	    ;;
4092
	  x86_64-*linux*)
4093
	    LD="${LD-ld} -m elf_x86_64"
4094
	    ;;
4095
	  ppc*-*linux*|powerpc*-*linux*)
4096
	    LD="${LD-ld} -m elf64ppc"
4097
	    ;;
4098
	  s390*-*linux*|s390*-*tpf*)
4099
	    LD="${LD-ld} -m elf64_s390"
4100
	    ;;
4101
	  sparc*-*linux*)
4102
	    LD="${LD-ld} -m elf64_sparc"
4103
	    ;;
4104
	esac
4105
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
4106
    esac
4107
  fi
4108
  rm -rf conftest*
4109
  ;;
4110
4111
*-*-sco3.2v5*)
4112
  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
4113
  SAVE_CFLAGS="$CFLAGS"
4114
  CFLAGS="$CFLAGS -belf"
4115
  AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
4116
    [AC_LANG_PUSH(C)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4117
     AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1 by Daniel Holbach
Import upstream version 0.5.1
4118
     AC_LANG_POP])
4119
  if test x"$lt_cv_cc_needs_belf" != x"yes"; then
4120
    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
4121
    CFLAGS="$SAVE_CFLAGS"
4122
  fi
4123
  ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4124
sparc*-*solaris*)
4125
  # Find out which ABI we are using.
4126
  echo 'int i;' > conftest.$ac_ext
4127
  if AC_TRY_EVAL(ac_compile); then
4128
    case `/usr/bin/file conftest.o` in
4129
    *64-bit*)
4130
      case $lt_cv_prog_gnu_ld in
4131
      yes*) LD="${LD-ld} -m elf64_sparc" ;;
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
4132
      *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4133
	if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
4134
	  LD="${LD-ld} -64"
4135
	fi
4136
	;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4137
      esac
4138
      ;;
4139
    esac
4140
  fi
4141
  rm -rf conftest*
4142
  ;;
1 by Daniel Holbach
Import upstream version 0.5.1
4143
esac
4144
4145
need_locks="$enable_libtool_lock"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4146
])# _LT_ENABLE_LOCK
4147
4148
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
4149
# _LT_PROG_AR
4150
# -----------
4151
m4_defun([_LT_PROG_AR],
4152
[AC_CHECK_TOOLS(AR, [ar], false)
4153
: ${AR=ar}
4154
: ${AR_FLAGS=cru}
4155
_LT_DECL([], [AR], [1], [The archiver])
4156
_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
4157
4158
AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
4159
  [lt_cv_ar_at_file=no
4160
   AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
4161
     [echo conftest.$ac_objext > conftest.lst
4162
      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
4163
      AC_TRY_EVAL([lt_ar_try])
4164
      if test "$ac_status" -eq 0; then
4165
	# Ensure the archiver fails upon bogus file names.
4166
	rm -f conftest.$ac_objext libconftest.a
4167
	AC_TRY_EVAL([lt_ar_try])
4168
	if test "$ac_status" -ne 0; then
4169
          lt_cv_ar_at_file=@
4170
        fi
4171
      fi
4172
      rm -f conftest.* libconftest.a
4173
     ])
4174
  ])
4175
4176
if test "x$lt_cv_ar_at_file" = xno; then
4177
  archiver_list_spec=
4178
else
4179
  archiver_list_spec=$lt_cv_ar_at_file
4180
fi
4181
_LT_DECL([], [archiver_list_spec], [1],
4182
  [How to feed a file listing to the archiver])
4183
])# _LT_PROG_AR
4184
4185
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4186
# _LT_CMD_OLD_ARCHIVE
4187
# -------------------
4188
m4_defun([_LT_CMD_OLD_ARCHIVE],
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
4189
[_LT_PROG_AR
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4190
4191
AC_CHECK_TOOL(STRIP, strip, :)
4192
test -z "$STRIP" && STRIP=:
4193
_LT_DECL([], [STRIP], [1], [A symbol stripping program])
4194
4195
AC_CHECK_TOOL(RANLIB, ranlib, :)
4196
test -z "$RANLIB" && RANLIB=:
4197
_LT_DECL([], [RANLIB], [1],
4198
    [Commands used to install an old-style archive])
4199
4200
# Determine commands to create old-style static archives.
4201
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
4202
old_postinstall_cmds='chmod 644 $oldlib'
4203
old_postuninstall_cmds=
4204
4205
if test -n "$RANLIB"; then
4206
  case $host_os in
4207
  openbsd*)
4208
    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
4209
    ;;
4210
  *)
4211
    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
4212
    ;;
4213
  esac
4214
  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
4215
fi
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4216
4217
case $host_os in
4218
  darwin*)
4219
    lock_old_archive_extraction=yes ;;
4220
  *)
4221
    lock_old_archive_extraction=no ;;
4222
esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4223
_LT_DECL([], [old_postinstall_cmds], [2])
4224
_LT_DECL([], [old_postuninstall_cmds], [2])
4225
_LT_TAGDECL([], [old_archive_cmds], [2],
4226
    [Commands used to build an old-style archive])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4227
_LT_DECL([], [lock_old_archive_extraction], [0],
4228
    [Whether to use a lock for old archive extraction])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4229
])# _LT_CMD_OLD_ARCHIVE
4230
4231
4232
# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1 by Daniel Holbach
Import upstream version 0.5.1
4233
#		[OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
4234
# ----------------------------------------------------------------
4235
# Check whether the given compiler option works
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4236
AC_DEFUN([_LT_COMPILER_OPTION],
4237
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4238
m4_require([_LT_DECL_SED])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
4239
AC_CACHE_CHECK([$1], [$2],
4240
  [$2=no
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4241
   m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4242
   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1 by Daniel Holbach
Import upstream version 0.5.1
4243
   lt_compiler_flag="$3"
4244
   # Insert the option either (1) after the last *FLAGS variable, or
4245
   # (2) before a word containing "conftest.", or (3) at the end.
4246
   # Note that $ac_compile itself does not contain backslashes and begins
4247
   # with a dollar sign (not a hyphen), so the echo should work correctly.
4248
   # The option is referenced via a variable to avoid confusing sed.
4249
   lt_compile=`echo "$ac_compile" | $SED \
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4250
   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1 by Daniel Holbach
Import upstream version 0.5.1
4251
   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
4252
   -e 's:$: $lt_compiler_flag:'`
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4253
   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1 by Daniel Holbach
Import upstream version 0.5.1
4254
   (eval "$lt_compile" 2>conftest.err)
4255
   ac_status=$?
4256
   cat conftest.err >&AS_MESSAGE_LOG_FD
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4257
   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1 by Daniel Holbach
Import upstream version 0.5.1
4258
   if (exit $ac_status) && test -s "$ac_outfile"; then
4259
     # The compiler can only warn and ignore the option if not recognized
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4260
     # So say no if there are warnings other than the usual output.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4261
     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4262
     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
4263
     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1 by Daniel Holbach
Import upstream version 0.5.1
4264
       $2=yes
4265
     fi
4266
   fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4267
   $RM conftest*
1 by Daniel Holbach
Import upstream version 0.5.1
4268
])
4269
4270
if test x"[$]$2" = xyes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4271
    m4_if([$5], , :, [$5])
1 by Daniel Holbach
Import upstream version 0.5.1
4272
else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4273
    m4_if([$6], , :, [$6])
1 by Daniel Holbach
Import upstream version 0.5.1
4274
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4275
])# _LT_COMPILER_OPTION
4276
4277
# Old name:
4278
AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
4279
dnl aclocal-1.4 backwards compatibility:
4280
dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
4281
4282
4283
# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
4284
#                  [ACTION-SUCCESS], [ACTION-FAILURE])
4285
# ----------------------------------------------------
4286
# Check whether the given linker option works
4287
AC_DEFUN([_LT_LINKER_OPTION],
4288
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4289
m4_require([_LT_DECL_SED])dnl
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4290
AC_CACHE_CHECK([$1], [$2],
1 by Daniel Holbach
Import upstream version 0.5.1
4291
  [$2=no
4292
   save_LDFLAGS="$LDFLAGS"
4293
   LDFLAGS="$LDFLAGS $3"
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4294
   echo "$lt_simple_link_test_code" > conftest.$ac_ext
1 by Daniel Holbach
Import upstream version 0.5.1
4295
   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4296
     # The linker can only warn and ignore the option if not recognized
1 by Daniel Holbach
Import upstream version 0.5.1
4297
     # So say no if there are warnings
4298
     if test -s conftest.err; then
4299
       # Append any errors to the config.log.
4300
       cat conftest.err 1>&AS_MESSAGE_LOG_FD
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4301
       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4302
       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
4303
       if diff conftest.exp conftest.er2 >/dev/null; then
4304
         $2=yes
4305
       fi
1 by Daniel Holbach
Import upstream version 0.5.1
4306
     else
4307
       $2=yes
4308
     fi
4309
   fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4310
   $RM -r conftest*
1 by Daniel Holbach
Import upstream version 0.5.1
4311
   LDFLAGS="$save_LDFLAGS"
4312
])
4313
4314
if test x"[$]$2" = xyes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4315
    m4_if([$4], , :, [$4])
1 by Daniel Holbach
Import upstream version 0.5.1
4316
else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4317
    m4_if([$5], , :, [$5])
1 by Daniel Holbach
Import upstream version 0.5.1
4318
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4319
])# _LT_LINKER_OPTION
4320
4321
# Old name:
4322
AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
4323
dnl aclocal-1.4 backwards compatibility:
4324
dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
4325
4326
4327
# LT_CMD_MAX_LEN
4328
#---------------
4329
AC_DEFUN([LT_CMD_MAX_LEN],
4330
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
4331
# find the maximum length of command line arguments
1 by Daniel Holbach
Import upstream version 0.5.1
4332
AC_MSG_CHECKING([the maximum length of command line arguments])
4333
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
4334
  i=0
4335
  teststring="ABCD"
4336
4337
  case $build_os in
4338
  msdosdjgpp*)
4339
    # On DJGPP, this test can blow up pretty badly due to problems in libc
4340
    # (any single argument exceeding 2000 bytes causes a buffer overrun
4341
    # during glob expansion).  Even if it were fixed, the result of this
4342
    # check would be larger than it should be.
4343
    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
4344
    ;;
4345
4346
  gnu*)
4347
    # Under GNU Hurd, this test is not required because there is
4348
    # no limit to the length of command line arguments.
4349
    # Libtool will interpret -1 as no limit whatsoever
4350
    lt_cv_sys_max_cmd_len=-1;
4351
    ;;
4352
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4353
  cygwin* | mingw* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
4354
    # On Win9x/ME, this test blows up -- it succeeds, but takes
4355
    # about 5 minutes as the teststring grows exponentially.
4356
    # Worse, since 9x/ME are not pre-emptively multitasking,
4357
    # you end up with a "frozen" computer, even though with patience
4358
    # the test eventually succeeds (with a max line length of 256k).
4359
    # Instead, let's just punt: use the minimum linelength reported by
4360
    # all of the supported platforms: 8192 (on NT/2K/XP).
4361
    lt_cv_sys_max_cmd_len=8192;
4362
    ;;
4363
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4364
  mint*)
4365
    # On MiNT this can take a long time and run out of memory.
4366
    lt_cv_sys_max_cmd_len=8192;
4367
    ;;
4368
1 by Daniel Holbach
Import upstream version 0.5.1
4369
  amigaos*)
4370
    # On AmigaOS with pdksh, this test takes hours, literally.
4371
    # So we just punt and use a minimum line length of 8192.
4372
    lt_cv_sys_max_cmd_len=8192;
4373
    ;;
4374
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4375
  netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
4376
    # This has been around since 386BSD, at least.  Likely further.
4377
    if test -x /sbin/sysctl; then
4378
      lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
4379
    elif test -x /usr/sbin/sysctl; then
4380
      lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
4381
    else
4382
      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
4383
    fi
4384
    # And add a safety zone
4385
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4386
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4387
    ;;
4388
4389
  interix*)
4390
    # We know the value 262144 and hardcode it with a safety zone (like BSD)
4391
    lt_cv_sys_max_cmd_len=196608
4392
    ;;
4393
4394
  osf*)
4395
    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
4396
    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
4397
    # nice to cause kernel panics so lets avoid the loop below.
4398
    # First set a reasonable default.
4399
    lt_cv_sys_max_cmd_len=16384
4400
    #
4401
    if test -x /sbin/sysconfig; then
4402
      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
4403
        *1*) lt_cv_sys_max_cmd_len=-1 ;;
4404
      esac
4405
    fi
4406
    ;;
4407
  sco3.2v5*)
4408
    lt_cv_sys_max_cmd_len=102400
4409
    ;;
4410
  sysv5* | sco5v6* | sysv4.2uw2*)
4411
    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
4412
    if test -n "$kargmax"; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4413
      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[	 ]]//'`
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4414
    else
4415
      lt_cv_sys_max_cmd_len=32768
4416
    fi
4417
    ;;
4418
  *)
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4419
    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
4420
    if test -n "$lt_cv_sys_max_cmd_len"; then
4421
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4422
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4423
    else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4424
      # Make teststring a little bigger before we do anything with it.
4425
      # a 1K string should be a reasonable start.
4426
      for i in 1 2 3 4 5 6 7 8 ; do
4427
        teststring=$teststring$teststring
4428
      done
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4429
      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4430
      # If test is not a shell built-in, we'll probably end up computing a
4431
      # maximum length that is only half of the actual maximum length, but
4432
      # we can't tell.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4433
      while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
4434
	         = "X$teststring$teststring"; } >/dev/null 2>&1 &&
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4435
	      test $i != 17 # 1/2 MB should be enough
4436
      do
4437
        i=`expr $i + 1`
4438
        teststring=$teststring$teststring
4439
      done
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4440
      # Only check the string length outside the loop.
4441
      lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4442
      teststring=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4443
      # Add a significant safety factor because C++ compilers can tack on
4444
      # massive amounts of additional arguments before passing them to the
4445
      # linker.  It appears as though 1/2 is a usable value.
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4446
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
4447
    fi
1 by Daniel Holbach
Import upstream version 0.5.1
4448
    ;;
4449
  esac
4450
])
4451
if test -n $lt_cv_sys_max_cmd_len ; then
4452
  AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
4453
else
4454
  AC_MSG_RESULT(none)
4455
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4456
max_cmd_len=$lt_cv_sys_max_cmd_len
4457
_LT_DECL([], [max_cmd_len], [0],
4458
    [What is the maximum length of a command?])
4459
])# LT_CMD_MAX_LEN
4460
4461
# Old name:
4462
AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
4463
dnl aclocal-1.4 backwards compatibility:
4464
dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
4465
4466
4467
# _LT_HEADER_DLFCN
4468
# ----------------
4469
m4_defun([_LT_HEADER_DLFCN],
4470
[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
4471
])# _LT_HEADER_DLFCN
4472
4473
4474
# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
4475
#                      ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
4476
# ----------------------------------------------------------------
4477
m4_defun([_LT_TRY_DLOPEN_SELF],
4478
[m4_require([_LT_HEADER_DLFCN])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
4479
if test "$cross_compiling" = yes; then :
4480
  [$4]
4481
else
4482
  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
4483
  lt_status=$lt_dlunknown
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4484
  cat > conftest.$ac_ext <<_LT_EOF
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4485
[#line $LINENO "configure"
1 by Daniel Holbach
Import upstream version 0.5.1
4486
#include "confdefs.h"
4487
4488
#if HAVE_DLFCN_H
4489
#include <dlfcn.h>
4490
#endif
4491
4492
#include <stdio.h>
4493
4494
#ifdef RTLD_GLOBAL
4495
#  define LT_DLGLOBAL		RTLD_GLOBAL
4496
#else
4497
#  ifdef DL_GLOBAL
4498
#    define LT_DLGLOBAL		DL_GLOBAL
4499
#  else
4500
#    define LT_DLGLOBAL		0
4501
#  endif
4502
#endif
4503
4504
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
4505
   find out it does not work in some platform. */
4506
#ifndef LT_DLLAZY_OR_NOW
4507
#  ifdef RTLD_LAZY
4508
#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
4509
#  else
4510
#    ifdef DL_LAZY
4511
#      define LT_DLLAZY_OR_NOW		DL_LAZY
4512
#    else
4513
#      ifdef RTLD_NOW
4514
#        define LT_DLLAZY_OR_NOW	RTLD_NOW
4515
#      else
4516
#        ifdef DL_NOW
4517
#          define LT_DLLAZY_OR_NOW	DL_NOW
4518
#        else
4519
#          define LT_DLLAZY_OR_NOW	0
4520
#        endif
4521
#      endif
4522
#    endif
4523
#  endif
4524
#endif
4525
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4526
/* When -fvisbility=hidden is used, assume the code has been annotated
4527
   correspondingly for the symbols needed.  */
4528
#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
4529
int fnord () __attribute__((visibility("default")));
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4530
#endif
4531
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
4532
int fnord () { return 42; }
1 by Daniel Holbach
Import upstream version 0.5.1
4533
int main ()
4534
{
4535
  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
4536
  int status = $lt_dlunknown;
4537
4538
  if (self)
4539
    {
4540
      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4541
      else
4542
        {
4543
	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
4544
          else puts (dlerror ());
4545
	}
1 by Daniel Holbach
Import upstream version 0.5.1
4546
      /* dlclose (self); */
4547
    }
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4548
  else
4549
    puts (dlerror ());
1 by Daniel Holbach
Import upstream version 0.5.1
4550
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4551
  return status;
1 by Daniel Holbach
Import upstream version 0.5.1
4552
}]
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4553
_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
4554
  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4555
    (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1 by Daniel Holbach
Import upstream version 0.5.1
4556
    lt_status=$?
4557
    case x$lt_status in
4558
      x$lt_dlno_uscore) $1 ;;
4559
      x$lt_dlneed_uscore) $2 ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4560
      x$lt_dlunknown|x*) $3 ;;
1 by Daniel Holbach
Import upstream version 0.5.1
4561
    esac
4562
  else :
4563
    # compilation failed
4564
    $3
4565
  fi
4566
fi
4567
rm -fr conftest*
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4568
])# _LT_TRY_DLOPEN_SELF
4569
4570
4571
# LT_SYS_DLOPEN_SELF
4572
# ------------------
4573
AC_DEFUN([LT_SYS_DLOPEN_SELF],
4574
[m4_require([_LT_HEADER_DLFCN])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
4575
if test "x$enable_dlopen" != xyes; then
4576
  enable_dlopen=unknown
4577
  enable_dlopen_self=unknown
4578
  enable_dlopen_self_static=unknown
4579
else
4580
  lt_cv_dlopen=no
4581
  lt_cv_dlopen_libs=
4582
4583
  case $host_os in
4584
  beos*)
4585
    lt_cv_dlopen="load_add_on"
4586
    lt_cv_dlopen_libs=
4587
    lt_cv_dlopen_self=yes
4588
    ;;
4589
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4590
  mingw* | pw32* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
4591
    lt_cv_dlopen="LoadLibrary"
4592
    lt_cv_dlopen_libs=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4593
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
4594
4595
  cygwin*)
4596
    lt_cv_dlopen="dlopen"
4597
    lt_cv_dlopen_libs=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4598
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
4599
4600
  darwin*)
4601
  # if libdl is installed we need to link against it
4602
    AC_CHECK_LIB([dl], [dlopen],
4603
		[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
4604
    lt_cv_dlopen="dyld"
4605
    lt_cv_dlopen_libs=
4606
    lt_cv_dlopen_self=yes
4607
    ])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4608
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
4609
4610
  *)
4611
    AC_CHECK_FUNC([shl_load],
4612
	  [lt_cv_dlopen="shl_load"],
4613
      [AC_CHECK_LIB([dld], [shl_load],
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
4614
	    [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1 by Daniel Holbach
Import upstream version 0.5.1
4615
	[AC_CHECK_FUNC([dlopen],
4616
	      [lt_cv_dlopen="dlopen"],
4617
	  [AC_CHECK_LIB([dl], [dlopen],
4618
		[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
4619
	    [AC_CHECK_LIB([svld], [dlopen],
4620
		  [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
4621
	      [AC_CHECK_LIB([dld], [dld_link],
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
4622
		    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1 by Daniel Holbach
Import upstream version 0.5.1
4623
	      ])
4624
	    ])
4625
	  ])
4626
	])
4627
      ])
4628
    ;;
4629
  esac
4630
4631
  if test "x$lt_cv_dlopen" != xno; then
4632
    enable_dlopen=yes
4633
  else
4634
    enable_dlopen=no
4635
  fi
4636
4637
  case $lt_cv_dlopen in
4638
  dlopen)
4639
    save_CPPFLAGS="$CPPFLAGS"
4640
    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
4641
4642
    save_LDFLAGS="$LDFLAGS"
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4643
    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1 by Daniel Holbach
Import upstream version 0.5.1
4644
4645
    save_LIBS="$LIBS"
4646
    LIBS="$lt_cv_dlopen_libs $LIBS"
4647
4648
    AC_CACHE_CHECK([whether a program can dlopen itself],
4649
	  lt_cv_dlopen_self, [dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4650
	  _LT_TRY_DLOPEN_SELF(
1 by Daniel Holbach
Import upstream version 0.5.1
4651
	    lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
4652
	    lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
4653
    ])
4654
4655
    if test "x$lt_cv_dlopen_self" = xyes; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4656
      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1 by Daniel Holbach
Import upstream version 0.5.1
4657
      AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4658
	  lt_cv_dlopen_self_static, [dnl
4659
	  _LT_TRY_DLOPEN_SELF(
1 by Daniel Holbach
Import upstream version 0.5.1
4660
	    lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
4661
	    lt_cv_dlopen_self_static=no,  lt_cv_dlopen_self_static=cross)
4662
      ])
4663
    fi
4664
4665
    CPPFLAGS="$save_CPPFLAGS"
4666
    LDFLAGS="$save_LDFLAGS"
4667
    LIBS="$save_LIBS"
4668
    ;;
4669
  esac
4670
4671
  case $lt_cv_dlopen_self in
4672
  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
4673
  *) enable_dlopen_self=unknown ;;
4674
  esac
4675
4676
  case $lt_cv_dlopen_self_static in
4677
  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
4678
  *) enable_dlopen_self_static=unknown ;;
4679
  esac
4680
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4681
_LT_DECL([dlopen_support], [enable_dlopen], [0],
4682
	 [Whether dlopen is supported])
4683
_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
4684
	 [Whether dlopen of programs is supported])
4685
_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
4686
	 [Whether dlopen of statically linked programs is supported])
4687
])# LT_SYS_DLOPEN_SELF
4688
4689
# Old name:
4690
AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
4691
dnl aclocal-1.4 backwards compatibility:
4692
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
4693
4694
4695
# _LT_COMPILER_C_O([TAGNAME])
4696
# ---------------------------
4697
# Check to see if options -c and -o are simultaneously supported by compiler.
4698
# This macro does not hard code the compiler like AC_PROG_CC_C_O.
4699
m4_defun([_LT_COMPILER_C_O],
4700
[m4_require([_LT_DECL_SED])dnl
4701
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4702
m4_require([_LT_TAG_COMPILER])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
4703
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4704
  [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
4705
  [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
4706
   $RM -r conftest 2>/dev/null
1 by Daniel Holbach
Import upstream version 0.5.1
4707
   mkdir conftest
4708
   cd conftest
4709
   mkdir out
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4710
   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1 by Daniel Holbach
Import upstream version 0.5.1
4711
4712
   lt_compiler_flag="-o out/conftest2.$ac_objext"
4713
   # Insert the option either (1) after the last *FLAGS variable, or
4714
   # (2) before a word containing "conftest.", or (3) at the end.
4715
   # Note that $ac_compile itself does not contain backslashes and begins
4716
   # with a dollar sign (not a hyphen), so the echo should work correctly.
4717
   lt_compile=`echo "$ac_compile" | $SED \
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4718
   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1 by Daniel Holbach
Import upstream version 0.5.1
4719
   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
4720
   -e 's:$: $lt_compiler_flag:'`
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4721
   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1 by Daniel Holbach
Import upstream version 0.5.1
4722
   (eval "$lt_compile" 2>out/conftest.err)
4723
   ac_status=$?
4724
   cat out/conftest.err >&AS_MESSAGE_LOG_FD
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4725
   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1 by Daniel Holbach
Import upstream version 0.5.1
4726
   if (exit $ac_status) && test -s out/conftest2.$ac_objext
4727
   then
4728
     # The compiler can only warn and ignore the option if not recognized
4729
     # So say no if there are warnings
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4730
     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4731
     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
4732
     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4733
       _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
4734
     fi
4735
   fi
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
4736
   chmod u+w . 2>&AS_MESSAGE_LOG_FD
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4737
   $RM conftest*
1 by Daniel Holbach
Import upstream version 0.5.1
4738
   # SGI C++ compiler will create directory out/ii_files/ for
4739
   # template instantiation
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4740
   test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
4741
   $RM out/* && rmdir out
1 by Daniel Holbach
Import upstream version 0.5.1
4742
   cd ..
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4743
   $RM -r conftest
4744
   $RM conftest*
1 by Daniel Holbach
Import upstream version 0.5.1
4745
])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4746
_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
4747
	[Does compiler simultaneously support -c and -o options?])
4748
])# _LT_COMPILER_C_O
4749
4750
4751
# _LT_COMPILER_FILE_LOCKS([TAGNAME])
4752
# ----------------------------------
1 by Daniel Holbach
Import upstream version 0.5.1
4753
# Check to see if we can do hard links to lock some files if needed
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4754
m4_defun([_LT_COMPILER_FILE_LOCKS],
4755
[m4_require([_LT_ENABLE_LOCK])dnl
4756
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4757
_LT_COMPILER_C_O([$1])
1 by Daniel Holbach
Import upstream version 0.5.1
4758
4759
hard_links="nottested"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4760
if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1 by Daniel Holbach
Import upstream version 0.5.1
4761
  # do not overwrite the value of need_locks provided by the user
4762
  AC_MSG_CHECKING([if we can lock with hard links])
4763
  hard_links=yes
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4764
  $RM conftest*
1 by Daniel Holbach
Import upstream version 0.5.1
4765
  ln conftest.a conftest.b 2>/dev/null && hard_links=no
4766
  touch conftest.a
4767
  ln conftest.a conftest.b 2>&5 || hard_links=no
4768
  ln conftest.a conftest.b 2>/dev/null && hard_links=no
4769
  AC_MSG_RESULT([$hard_links])
4770
  if test "$hard_links" = no; then
4771
    AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
4772
    need_locks=warn
4773
  fi
4774
else
4775
  need_locks=no
4776
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4777
_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
4778
])# _LT_COMPILER_FILE_LOCKS
4779
4780
4781
# _LT_CHECK_OBJDIR
4782
# ----------------
4783
m4_defun([_LT_CHECK_OBJDIR],
1 by Daniel Holbach
Import upstream version 0.5.1
4784
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
4785
[rm -f .libs 2>/dev/null
4786
mkdir .libs 2>/dev/null
4787
if test -d .libs; then
4788
  lt_cv_objdir=.libs
4789
else
4790
  # MS-DOS does not allow filenames that begin with a dot.
4791
  lt_cv_objdir=_libs
4792
fi
4793
rmdir .libs 2>/dev/null])
4794
objdir=$lt_cv_objdir
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4795
_LT_DECL([], [objdir], [0],
4796
         [The name of the directory that contains temporary libtool files])dnl
4797
m4_pattern_allow([LT_OBJDIR])dnl
4798
AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
4799
  [Define to the sub-directory in which libtool stores uninstalled libraries.])
4800
])# _LT_CHECK_OBJDIR
4801
4802
4803
# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
4804
# --------------------------------------
1 by Daniel Holbach
Import upstream version 0.5.1
4805
# Check hardcoding attributes.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4806
m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
1 by Daniel Holbach
Import upstream version 0.5.1
4807
[AC_MSG_CHECKING([how to hardcode library paths into programs])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4808
_LT_TAGVAR(hardcode_action, $1)=
4809
if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
4810
   test -n "$_LT_TAGVAR(runpath_var, $1)" ||
4811
   test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
1 by Daniel Holbach
Import upstream version 0.5.1
4812
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4813
  # We can hardcode non-existent directories.
4814
  if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
1 by Daniel Holbach
Import upstream version 0.5.1
4815
     # If the only mechanism to avoid hardcoding is shlibpath_var, we
4816
     # have to relink, otherwise we might link with an installed library
4817
     # when we should be linking with a yet-to-be-installed one
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4818
     ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
4819
     test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
1 by Daniel Holbach
Import upstream version 0.5.1
4820
    # Linking always hardcodes the temporary library directory.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4821
    _LT_TAGVAR(hardcode_action, $1)=relink
1 by Daniel Holbach
Import upstream version 0.5.1
4822
  else
4823
    # We can link without hardcoding, and we can hardcode nonexisting dirs.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4824
    _LT_TAGVAR(hardcode_action, $1)=immediate
1 by Daniel Holbach
Import upstream version 0.5.1
4825
  fi
4826
else
4827
  # We cannot hardcode anything, or else we can only hardcode existing
4828
  # directories.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4829
  _LT_TAGVAR(hardcode_action, $1)=unsupported
1 by Daniel Holbach
Import upstream version 0.5.1
4830
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4831
AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
1 by Daniel Holbach
Import upstream version 0.5.1
4832
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4833
if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
4834
   test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
1 by Daniel Holbach
Import upstream version 0.5.1
4835
  # Fast installation is not supported
4836
  enable_fast_install=no
4837
elif test "$shlibpath_overrides_runpath" = yes ||
4838
     test "$enable_shared" = no; then
4839
  # Fast installation is not necessary
4840
  enable_fast_install=needless
4841
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4842
_LT_TAGDECL([], [hardcode_action], [0],
4843
    [How to hardcode a shared library path into an executable])
4844
])# _LT_LINKER_HARDCODE_LIBPATH
4845
4846
4847
# _LT_CMD_STRIPLIB
4848
# ----------------
4849
m4_defun([_LT_CMD_STRIPLIB],
4850
[m4_require([_LT_DECL_EGREP])
4851
striplib=
1 by Daniel Holbach
Import upstream version 0.5.1
4852
old_striplib=
4853
AC_MSG_CHECKING([whether stripping libraries is possible])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4854
if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
1 by Daniel Holbach
Import upstream version 0.5.1
4855
  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
4856
  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
4857
  AC_MSG_RESULT([yes])
4858
else
4859
# FIXME - insert some real tests, host_os isn't really good enough
4860
  case $host_os in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4861
  darwin*)
4862
    if test -n "$STRIP" ; then
4863
      striplib="$STRIP -x"
4864
      old_striplib="$STRIP -S"
4865
      AC_MSG_RESULT([yes])
4866
    else
4867
      AC_MSG_RESULT([no])
4868
    fi
4869
    ;;
4870
  *)
4871
    AC_MSG_RESULT([no])
1 by Daniel Holbach
Import upstream version 0.5.1
4872
    ;;
4873
  esac
4874
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4875
_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
4876
_LT_DECL([], [striplib], [1])
4877
])# _LT_CMD_STRIPLIB
4878
4879
4880
# _LT_SYS_DYNAMIC_LINKER([TAG])
1 by Daniel Holbach
Import upstream version 0.5.1
4881
# -----------------------------
4882
# PORTME Fill in your ld.so characteristics
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4883
m4_defun([_LT_SYS_DYNAMIC_LINKER],
4884
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
4885
m4_require([_LT_DECL_EGREP])dnl
4886
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4887
m4_require([_LT_DECL_OBJDUMP])dnl
4888
m4_require([_LT_DECL_SED])dnl
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4889
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4890
AC_MSG_CHECKING([dynamic linker characteristics])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4891
m4_if([$1],
4892
	[], [
1 by Daniel Holbach
Import upstream version 0.5.1
4893
if test "$GCC" = yes; then
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4894
  case $host_os in
4895
    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
4896
    *) lt_awk_arg="/^libraries:/" ;;
4897
  esac
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4898
  case $host_os in
4899
    mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
4900
    *) lt_sed_strip_eq="s,=/,/,g" ;;
4901
  esac
4902
  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
4903
  case $lt_search_path_spec in
4904
  *\;*)
1 by Daniel Holbach
Import upstream version 0.5.1
4905
    # if the path contains ";" then we assume it to be the separator
4906
    # otherwise default to the standard path separator (i.e. ":") - it is
4907
    # assumed that no part of a normal pathname contains ";" but that should
4908
    # okay in the real world where ";" in dirpaths is itself problematic.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4909
    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
4910
    ;;
4911
  *)
4912
    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
4913
    ;;
4914
  esac
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4915
  # Ok, now we have the path, separated by spaces, we can step through it
4916
  # and add multilib dir if necessary.
4917
  lt_tmp_lt_search_path_spec=
4918
  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
4919
  for lt_sys_path in $lt_search_path_spec; do
4920
    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
4921
      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
4922
    else
4923
      test -d "$lt_sys_path" && \
4924
	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
4925
    fi
4926
  done
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4927
  lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4928
BEGIN {RS=" "; FS="/|\n";} {
4929
  lt_foo="";
4930
  lt_count=0;
4931
  for (lt_i = NF; lt_i > 0; lt_i--) {
4932
    if ($lt_i != "" && $lt_i != ".") {
4933
      if ($lt_i == "..") {
4934
        lt_count++;
4935
      } else {
4936
        if (lt_count == 0) {
4937
          lt_foo="/" $lt_i lt_foo;
4938
        } else {
4939
          lt_count--;
4940
        }
4941
      }
4942
    }
4943
  }
4944
  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
4945
  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
4946
}'`
1.1.16 by Robert Ancell
Import upstream version 2.31.6
4947
  # AWK program above erroneously prepends '/' to C:/dos/paths
4948
  # for these hosts.
4949
  case $host_os in
4950
    mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
4951
      $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
4952
  esac
4953
  sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
1 by Daniel Holbach
Import upstream version 0.5.1
4954
else
4955
  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
4956
fi])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
4957
library_names_spec=
4958
libname_spec='lib$name'
4959
soname_spec=
4960
shrext_cmds=".so"
4961
postinstall_cmds=
4962
postuninstall_cmds=
4963
finish_cmds=
4964
finish_eval=
4965
shlibpath_var=
4966
shlibpath_overrides_runpath=unknown
4967
version_type=none
4968
dynamic_linker="$host_os ld.so"
4969
sys_lib_dlsearch_path_spec="/lib /usr/lib"
1 by Daniel Holbach
Import upstream version 0.5.1
4970
need_lib_prefix=unknown
4971
hardcode_into_libs=no
4972
4973
# when you set need_version to no, make sure it does not cause -set_version
4974
# flags to be left without arguments
4975
need_version=unknown
4976
4977
case $host_os in
4978
aix3*)
4979
  version_type=linux
4980
  library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
4981
  shlibpath_var=LIBPATH
4982
4983
  # AIX 3 has no versioning support, so we append a major version to the name.
4984
  soname_spec='${libname}${release}${shared_ext}$major'
4985
  ;;
4986
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
4987
aix[[4-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
4988
  version_type=linux
4989
  need_lib_prefix=no
4990
  need_version=no
4991
  hardcode_into_libs=yes
4992
  if test "$host_cpu" = ia64; then
4993
    # AIX 5 supports IA64
4994
    library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
4995
    shlibpath_var=LD_LIBRARY_PATH
4996
  else
4997
    # With GCC up to 2.95.x, collect2 would create an import file
4998
    # for dependence libraries.  The import file would start with
4999
    # the line `#! .'.  This would cause the generated library to
5000
    # depend on `.', always an invalid library.  This was fixed in
5001
    # development snapshots of GCC prior to 3.0.
5002
    case $host_os in
5003
      aix4 | aix4.[[01]] | aix4.[[01]].*)
5004
      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
5005
	   echo ' yes '
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5006
	   echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
1 by Daniel Holbach
Import upstream version 0.5.1
5007
	:
5008
      else
5009
	can_build_shared=no
5010
      fi
5011
      ;;
5012
    esac
5013
    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
5014
    # soname into executable. Probably we can add versioning support to
5015
    # collect2, so additional links can be useful in future.
5016
    if test "$aix_use_runtimelinking" = yes; then
5017
      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
5018
      # instead of lib<name>.a to let people know that these are not
5019
      # typical AIX shared libraries.
5020
      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5021
    else
5022
      # We preserve .a as extension for shared libraries through AIX4.2
5023
      # and later when we are not doing run time linking.
5024
      library_names_spec='${libname}${release}.a $libname.a'
5025
      soname_spec='${libname}${release}${shared_ext}$major'
5026
    fi
5027
    shlibpath_var=LIBPATH
5028
  fi
5029
  ;;
5030
5031
amigaos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5032
  case $host_cpu in
5033
  powerpc)
5034
    # Since July 2007 AmigaOS4 officially supports .so libraries.
5035
    # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
5036
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5037
    ;;
5038
  m68k)
5039
    library_names_spec='$libname.ixlibrary $libname.a'
5040
    # Create ${libname}_ixlibrary.a entries in /sys/libs.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5041
    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5042
    ;;
5043
  esac
1 by Daniel Holbach
Import upstream version 0.5.1
5044
  ;;
5045
5046
beos*)
5047
  library_names_spec='${libname}${shared_ext}'
5048
  dynamic_linker="$host_os ld.so"
5049
  shlibpath_var=LIBRARY_PATH
5050
  ;;
5051
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5052
bsdi[[45]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
5053
  version_type=linux
5054
  need_version=no
5055
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5056
  soname_spec='${libname}${release}${shared_ext}$major'
5057
  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
5058
  shlibpath_var=LD_LIBRARY_PATH
5059
  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
5060
  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
5061
  # the default ld.so.conf also contains /usr/contrib/lib and
5062
  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
5063
  # libtool to hard-code these into programs
5064
  ;;
5065
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5066
cygwin* | mingw* | pw32* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
5067
  version_type=windows
5068
  shrext_cmds=".dll"
5069
  need_version=no
5070
  need_lib_prefix=no
5071
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
5072
  case $GCC,$cc_basename in
5073
  yes,*)
5074
    # gcc
1 by Daniel Holbach
Import upstream version 0.5.1
5075
    library_names_spec='$libname.dll.a'
5076
    # DLL is installed to $(libdir)/../bin by postinstall_cmds
5077
    postinstall_cmds='base_file=`basename \${file}`~
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5078
      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
1 by Daniel Holbach
Import upstream version 0.5.1
5079
      dldir=$destdir/`dirname \$dlpath`~
5080
      test -d \$dldir || mkdir -p \$dldir~
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5081
      $install_prog $dir/$dlname \$dldir/$dlname~
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5082
      chmod a+x \$dldir/$dlname~
5083
      if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
5084
        eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
5085
      fi'
1 by Daniel Holbach
Import upstream version 0.5.1
5086
    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
5087
      dlpath=$dir/\$dldll~
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5088
       $RM \$dlpath'
1 by Daniel Holbach
Import upstream version 0.5.1
5089
    shlibpath_overrides_runpath=yes
5090
5091
    case $host_os in
5092
    cygwin*)
5093
      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
5094
      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5095
m4_if([$1], [],[
5096
      sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
1 by Daniel Holbach
Import upstream version 0.5.1
5097
      ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5098
    mingw* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
5099
      # MinGW DLLs use traditional 'lib' prefix
5100
      soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
5101
      ;;
5102
    pw32*)
5103
      # pw32 DLLs use 'pw' prefix rather than 'lib'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5104
      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1 by Daniel Holbach
Import upstream version 0.5.1
5105
      ;;
5106
    esac
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
5107
    dynamic_linker='Win32 ld.exe'
5108
    ;;
5109
5110
  *,cl*)
5111
    # Native MSVC
5112
    libname_spec='$name'
5113
    soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
5114
    library_names_spec='${libname}.dll.lib'
5115
5116
    case $build_os in
5117
    mingw*)
5118
      sys_lib_search_path_spec=
5119
      lt_save_ifs=$IFS
5120
      IFS=';'
5121
      for lt_path in $LIB
5122
      do
5123
        IFS=$lt_save_ifs
5124
        # Let DOS variable expansion print the short 8.3 style file name.
5125
        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
5126
        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
5127
      done
5128
      IFS=$lt_save_ifs
5129
      # Convert to MSYS style.
5130
      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
5131
      ;;
5132
    cygwin*)
5133
      # Convert to unix form, then to dos form, then back to unix form
5134
      # but this time dos style (no spaces!) so that the unix form looks
5135
      # like /cygdrive/c/PROGRA~1:/cygdr...
5136
      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
5137
      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
5138
      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
5139
      ;;
5140
    *)
5141
      sys_lib_search_path_spec="$LIB"
5142
      if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
5143
        # It is most probably a Windows format PATH.
5144
        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
5145
      else
5146
        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
5147
      fi
5148
      # FIXME: find the short name or the path components, as spaces are
5149
      # common. (e.g. "Program Files" -> "PROGRA~1")
5150
      ;;
5151
    esac
5152
5153
    # DLL is installed to $(libdir)/../bin by postinstall_cmds
5154
    postinstall_cmds='base_file=`basename \${file}`~
5155
      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
5156
      dldir=$destdir/`dirname \$dlpath`~
5157
      test -d \$dldir || mkdir -p \$dldir~
5158
      $install_prog $dir/$dlname \$dldir/$dlname'
5159
    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
5160
      dlpath=$dir/\$dldll~
5161
       $RM \$dlpath'
5162
    shlibpath_overrides_runpath=yes
5163
    dynamic_linker='Win32 link.exe'
1 by Daniel Holbach
Import upstream version 0.5.1
5164
    ;;
5165
5166
  *)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
5167
    # Assume MSVC wrapper
1 by Daniel Holbach
Import upstream version 0.5.1
5168
    library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
5169
    dynamic_linker='Win32 ld.exe'
1 by Daniel Holbach
Import upstream version 0.5.1
5170
    ;;
5171
  esac
5172
  # FIXME: first we should search . and the directory the executable is in
5173
  shlibpath_var=PATH
5174
  ;;
5175
5176
darwin* | rhapsody*)
5177
  dynamic_linker="$host_os dyld"
5178
  version_type=darwin
5179
  need_lib_prefix=no
5180
  need_version=no
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5181
  library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
1 by Daniel Holbach
Import upstream version 0.5.1
5182
  soname_spec='${libname}${release}${major}$shared_ext'
5183
  shlibpath_overrides_runpath=yes
5184
  shlibpath_var=DYLD_LIBRARY_PATH
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5185
  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5186
m4_if([$1], [],[
5187
  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
1 by Daniel Holbach
Import upstream version 0.5.1
5188
  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
5189
  ;;
5190
5191
dgux*)
5192
  version_type=linux
5193
  need_lib_prefix=no
5194
  need_version=no
5195
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
5196
  soname_spec='${libname}${release}${shared_ext}$major'
5197
  shlibpath_var=LD_LIBRARY_PATH
5198
  ;;
5199
5200
freebsd1*)
5201
  dynamic_linker=no
5202
  ;;
5203
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5204
freebsd* | dragonfly*)
5205
  # DragonFly does not have aout.  When/if they implement a new
5206
  # versioning mechanism, adjust this.
5207
  if test -x /usr/bin/objformat; then
5208
    objformat=`/usr/bin/objformat`
5209
  else
5210
    case $host_os in
5211
    freebsd[[123]]*) objformat=aout ;;
5212
    *) objformat=elf ;;
5213
    esac
5214
  fi
1 by Daniel Holbach
Import upstream version 0.5.1
5215
  version_type=freebsd-$objformat
5216
  case $version_type in
5217
    freebsd-elf*)
5218
      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
5219
      need_version=no
5220
      need_lib_prefix=no
5221
      ;;
5222
    freebsd-*)
5223
      library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
5224
      need_version=yes
5225
      ;;
5226
  esac
5227
  shlibpath_var=LD_LIBRARY_PATH
5228
  case $host_os in
5229
  freebsd2*)
5230
    shlibpath_overrides_runpath=yes
5231
    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5232
  freebsd3.[[01]]* | freebsdelf3.[[01]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
5233
    shlibpath_overrides_runpath=yes
5234
    hardcode_into_libs=yes
5235
    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5236
  freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
5237
  freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
1 by Daniel Holbach
Import upstream version 0.5.1
5238
    shlibpath_overrides_runpath=no
5239
    hardcode_into_libs=yes
5240
    ;;
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5241
  *) # from 4.6 on, and DragonFly
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5242
    shlibpath_overrides_runpath=yes
5243
    hardcode_into_libs=yes
5244
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
5245
  esac
5246
  ;;
5247
5248
gnu*)
5249
  version_type=linux
5250
  need_lib_prefix=no
5251
  need_version=no
5252
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
5253
  soname_spec='${libname}${release}${shared_ext}$major'
5254
  shlibpath_var=LD_LIBRARY_PATH
5255
  hardcode_into_libs=yes
5256
  ;;
5257
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5258
haiku*)
5259
  version_type=linux
5260
  need_lib_prefix=no
5261
  need_version=no
5262
  dynamic_linker="$host_os runtime_loader"
5263
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
5264
  soname_spec='${libname}${release}${shared_ext}$major'
5265
  shlibpath_var=LIBRARY_PATH
5266
  shlibpath_overrides_runpath=yes
5267
  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
5268
  hardcode_into_libs=yes
5269
  ;;
5270
1 by Daniel Holbach
Import upstream version 0.5.1
5271
hpux9* | hpux10* | hpux11*)
5272
  # Give a soname corresponding to the major version so that dld.sl refuses to
5273
  # link against other versions.
5274
  version_type=sunos
5275
  need_lib_prefix=no
5276
  need_version=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5277
  case $host_cpu in
1 by Daniel Holbach
Import upstream version 0.5.1
5278
  ia64*)
5279
    shrext_cmds='.so'
5280
    hardcode_into_libs=yes
5281
    dynamic_linker="$host_os dld.so"
5282
    shlibpath_var=LD_LIBRARY_PATH
5283
    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
5284
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5285
    soname_spec='${libname}${release}${shared_ext}$major'
5286
    if test "X$HPUX_IA64_MODE" = X32; then
5287
      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
5288
    else
5289
      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
5290
    fi
5291
    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
5292
    ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5293
  hppa*64*)
5294
    shrext_cmds='.sl'
5295
    hardcode_into_libs=yes
5296
    dynamic_linker="$host_os dld.sl"
5297
    shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
5298
    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
5299
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5300
    soname_spec='${libname}${release}${shared_ext}$major'
5301
    sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
5302
    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
5303
    ;;
5304
  *)
1 by Daniel Holbach
Import upstream version 0.5.1
5305
    shrext_cmds='.sl'
5306
    dynamic_linker="$host_os dld.sl"
5307
    shlibpath_var=SHLIB_PATH
5308
    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
5309
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5310
    soname_spec='${libname}${release}${shared_ext}$major'
5311
    ;;
5312
  esac
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5313
  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
1 by Daniel Holbach
Import upstream version 0.5.1
5314
  postinstall_cmds='chmod 555 $lib'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5315
  # or fails outright, so override atomically:
5316
  install_override_mode=555
1 by Daniel Holbach
Import upstream version 0.5.1
5317
  ;;
5318
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5319
interix[[3-9]]*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5320
  version_type=linux
5321
  need_lib_prefix=no
5322
  need_version=no
5323
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
5324
  soname_spec='${libname}${release}${shared_ext}$major'
5325
  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
5326
  shlibpath_var=LD_LIBRARY_PATH
5327
  shlibpath_overrides_runpath=no
5328
  hardcode_into_libs=yes
5329
  ;;
5330
1 by Daniel Holbach
Import upstream version 0.5.1
5331
irix5* | irix6* | nonstopux*)
5332
  case $host_os in
5333
    nonstopux*) version_type=nonstopux ;;
5334
    *)
5335
	if test "$lt_cv_prog_gnu_ld" = yes; then
5336
		version_type=linux
5337
	else
5338
		version_type=irix
5339
	fi ;;
5340
  esac
5341
  need_lib_prefix=no
5342
  need_version=no
5343
  soname_spec='${libname}${release}${shared_ext}$major'
5344
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
5345
  case $host_os in
5346
  irix5* | nonstopux*)
5347
    libsuff= shlibsuff=
5348
    ;;
5349
  *)
5350
    case $LD in # libtool.m4 will add one of these switches to LD
5351
    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
5352
      libsuff= shlibsuff= libmagic=32-bit;;
5353
    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
5354
      libsuff=32 shlibsuff=N32 libmagic=N32;;
5355
    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
5356
      libsuff=64 shlibsuff=64 libmagic=64-bit;;
5357
    *) libsuff= shlibsuff= libmagic=never-match;;
5358
    esac
5359
    ;;
5360
  esac
5361
  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
5362
  shlibpath_overrides_runpath=no
5363
  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
5364
  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
5365
  hardcode_into_libs=yes
5366
  ;;
5367
5368
# No shared lib support for Linux oldld, aout, or coff.
5369
linux*oldld* | linux*aout* | linux*coff*)
5370
  dynamic_linker=no
5371
  ;;
5372
5373
# This must be Linux ELF.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5374
linux* | k*bsd*-gnu | kopensolaris*-gnu)
1 by Daniel Holbach
Import upstream version 0.5.1
5375
  version_type=linux
5376
  need_lib_prefix=no
5377
  need_version=no
5378
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5379
  soname_spec='${libname}${release}${shared_ext}$major'
5380
  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
5381
  shlibpath_var=LD_LIBRARY_PATH
5382
  shlibpath_overrides_runpath=no
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5383
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5384
  # Some binutils ld are patched to set DT_RUNPATH
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5385
  AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
5386
    [lt_cv_shlibpath_overrides_runpath=no
5387
    save_LDFLAGS=$LDFLAGS
5388
    save_libdir=$libdir
5389
    eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
5390
	 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
5391
    AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
5392
      [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
5393
	 [lt_cv_shlibpath_overrides_runpath=yes])])
5394
    LDFLAGS=$save_LDFLAGS
5395
    libdir=$save_libdir
5396
    ])
5397
  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5398
1 by Daniel Holbach
Import upstream version 0.5.1
5399
  # This implies no fast_install, which is unacceptable.
5400
  # Some rework will be needed to allow for fast_install
5401
  # before this can be enabled.
5402
  hardcode_into_libs=yes
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5403
5404
  # Add ABI-specific directories to the system library path.
5405
  sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
1.1.2 by Daniel Holbach
Import upstream version 0.7.0
5406
1 by Daniel Holbach
Import upstream version 0.5.1
5407
  # Append ld.so.conf contents to the search path
5408
  if test -f /etc/ld.so.conf; then
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5409
    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5410
    sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5411
1 by Daniel Holbach
Import upstream version 0.5.1
5412
  fi
5413
5414
  # We used to test for /lib/ld.so.1 and disable shared libraries on
5415
  # powerpc, because MkLinux only supported shared libraries with the
5416
  # GNU dynamic linker.  Since this was broken with cross compilers,
5417
  # most powerpc-linux boxes support dynamic linking these days and
5418
  # people can always --disable-shared, the test was removed, and we
5419
  # assume the GNU/Linux dynamic linker is in use.
5420
  dynamic_linker='GNU/Linux ld.so'
5421
  ;;
5422
5423
netbsd*)
5424
  version_type=sunos
5425
  need_lib_prefix=no
5426
  need_version=no
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5427
  if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
1 by Daniel Holbach
Import upstream version 0.5.1
5428
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
5429
    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
5430
    dynamic_linker='NetBSD (a.out) ld.so'
5431
  else
5432
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
5433
    soname_spec='${libname}${release}${shared_ext}$major'
5434
    dynamic_linker='NetBSD ld.elf_so'
5435
  fi
5436
  shlibpath_var=LD_LIBRARY_PATH
5437
  shlibpath_overrides_runpath=yes
5438
  hardcode_into_libs=yes
5439
  ;;
5440
5441
newsos6)
5442
  version_type=linux
5443
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5444
  shlibpath_var=LD_LIBRARY_PATH
5445
  shlibpath_overrides_runpath=yes
5446
  ;;
5447
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5448
*nto* | *qnx*)
5449
  version_type=qnx
1 by Daniel Holbach
Import upstream version 0.5.1
5450
  need_lib_prefix=no
5451
  need_version=no
5452
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5453
  soname_spec='${libname}${release}${shared_ext}$major'
5454
  shlibpath_var=LD_LIBRARY_PATH
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5455
  shlibpath_overrides_runpath=no
5456
  hardcode_into_libs=yes
5457
  dynamic_linker='ldqnx.so'
1 by Daniel Holbach
Import upstream version 0.5.1
5458
  ;;
5459
5460
openbsd*)
5461
  version_type=sunos
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5462
  sys_lib_dlsearch_path_spec="/usr/lib"
1 by Daniel Holbach
Import upstream version 0.5.1
5463
  need_lib_prefix=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5464
  # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
5465
  case $host_os in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5466
    openbsd3.3 | openbsd3.3.*)	need_version=yes ;;
5467
    *)				need_version=no  ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5468
  esac
1 by Daniel Holbach
Import upstream version 0.5.1
5469
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
5470
  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
5471
  shlibpath_var=LD_LIBRARY_PATH
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5472
  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
1 by Daniel Holbach
Import upstream version 0.5.1
5473
    case $host_os in
5474
      openbsd2.[[89]] | openbsd2.[[89]].*)
5475
	shlibpath_overrides_runpath=no
5476
	;;
5477
      *)
5478
	shlibpath_overrides_runpath=yes
5479
	;;
5480
      esac
5481
  else
5482
    shlibpath_overrides_runpath=yes
5483
  fi
5484
  ;;
5485
5486
os2*)
5487
  libname_spec='$name'
5488
  shrext_cmds=".dll"
5489
  need_lib_prefix=no
5490
  library_names_spec='$libname${shared_ext} $libname.a'
5491
  dynamic_linker='OS/2 ld.exe'
5492
  shlibpath_var=LIBPATH
5493
  ;;
5494
5495
osf3* | osf4* | osf5*)
5496
  version_type=osf
5497
  need_lib_prefix=no
5498
  need_version=no
5499
  soname_spec='${libname}${release}${shared_ext}$major'
5500
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5501
  shlibpath_var=LD_LIBRARY_PATH
5502
  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
5503
  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
5504
  ;;
5505
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5506
rdos*)
5507
  dynamic_linker=no
5508
  ;;
5509
1 by Daniel Holbach
Import upstream version 0.5.1
5510
solaris*)
5511
  version_type=linux
5512
  need_lib_prefix=no
5513
  need_version=no
5514
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5515
  soname_spec='${libname}${release}${shared_ext}$major'
5516
  shlibpath_var=LD_LIBRARY_PATH
5517
  shlibpath_overrides_runpath=yes
5518
  hardcode_into_libs=yes
5519
  # ldd complains unless libraries are executable
5520
  postinstall_cmds='chmod +x $lib'
5521
  ;;
5522
5523
sunos4*)
5524
  version_type=sunos
5525
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
5526
  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
5527
  shlibpath_var=LD_LIBRARY_PATH
5528
  shlibpath_overrides_runpath=yes
5529
  if test "$with_gnu_ld" = yes; then
5530
    need_lib_prefix=no
5531
  fi
5532
  need_version=yes
5533
  ;;
5534
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5535
sysv4 | sysv4.3*)
1 by Daniel Holbach
Import upstream version 0.5.1
5536
  version_type=linux
5537
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5538
  soname_spec='${libname}${release}${shared_ext}$major'
5539
  shlibpath_var=LD_LIBRARY_PATH
5540
  case $host_vendor in
5541
    sni)
5542
      shlibpath_overrides_runpath=no
5543
      need_lib_prefix=no
5544
      runpath_var=LD_RUN_PATH
5545
      ;;
5546
    siemens)
5547
      need_lib_prefix=no
5548
      ;;
5549
    motorola)
5550
      need_lib_prefix=no
5551
      need_version=no
5552
      shlibpath_overrides_runpath=no
5553
      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
5554
      ;;
5555
  esac
5556
  ;;
5557
5558
sysv4*MP*)
5559
  if test -d /usr/nec ;then
5560
    version_type=linux
5561
    library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
5562
    soname_spec='$libname${shared_ext}.$major'
5563
    shlibpath_var=LD_LIBRARY_PATH
5564
  fi
5565
  ;;
5566
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5567
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
5568
  version_type=freebsd-elf
5569
  need_lib_prefix=no
5570
  need_version=no
5571
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
5572
  soname_spec='${libname}${release}${shared_ext}$major'
5573
  shlibpath_var=LD_LIBRARY_PATH
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5574
  shlibpath_overrides_runpath=yes
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5575
  hardcode_into_libs=yes
5576
  if test "$with_gnu_ld" = yes; then
5577
    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
5578
  else
5579
    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
5580
    case $host_os in
5581
      sco3.2v5*)
5582
        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
5583
	;;
5584
    esac
5585
  fi
5586
  sys_lib_dlsearch_path_spec='/usr/lib'
5587
  ;;
5588
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5589
tpf*)
5590
  # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
5591
  version_type=linux
5592
  need_lib_prefix=no
5593
  need_version=no
5594
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5595
  shlibpath_var=LD_LIBRARY_PATH
5596
  shlibpath_overrides_runpath=no
5597
  hardcode_into_libs=yes
5598
  ;;
5599
1 by Daniel Holbach
Import upstream version 0.5.1
5600
uts4*)
5601
  version_type=linux
5602
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
5603
  soname_spec='${libname}${release}${shared_ext}$major'
5604
  shlibpath_var=LD_LIBRARY_PATH
5605
  ;;
5606
5607
*)
5608
  dynamic_linker=no
5609
  ;;
5610
esac
5611
AC_MSG_RESULT([$dynamic_linker])
5612
test "$dynamic_linker" = no && can_build_shared=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5613
5614
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
5615
if test "$GCC" = yes; then
5616
  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
5617
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5618
5619
if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
5620
  sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
5621
fi
5622
if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
5623
  sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
5624
fi
5625
5626
_LT_DECL([], [variables_saved_for_relink], [1],
5627
    [Variables whose values should be saved in libtool wrapper scripts and
5628
    restored at link time])
5629
_LT_DECL([], [need_lib_prefix], [0],
5630
    [Do we need the "lib" prefix for modules?])
5631
_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
5632
_LT_DECL([], [version_type], [0], [Library versioning type])
5633
_LT_DECL([], [runpath_var], [0],  [Shared library runtime path variable])
5634
_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
5635
_LT_DECL([], [shlibpath_overrides_runpath], [0],
5636
    [Is shlibpath searched before the hard-coded library search path?])
5637
_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
5638
_LT_DECL([], [library_names_spec], [1],
5639
    [[List of archive names.  First name is the real one, the rest are links.
5640
    The last name is the one that the linker finds with -lNAME]])
5641
_LT_DECL([], [soname_spec], [1],
5642
    [[The coded name of the library, if different from the real name]])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5643
_LT_DECL([], [install_override_mode], [1],
5644
    [Permission mode override for installation of shared libraries])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5645
_LT_DECL([], [postinstall_cmds], [2],
5646
    [Command to use after installation of a shared archive])
5647
_LT_DECL([], [postuninstall_cmds], [2],
5648
    [Command to use after uninstallation of a shared archive])
5649
_LT_DECL([], [finish_cmds], [2],
5650
    [Commands used to finish a libtool library installation in a directory])
5651
_LT_DECL([], [finish_eval], [1],
5652
    [[As "finish_cmds", except a single script fragment to be evaled but
5653
    not shown]])
5654
_LT_DECL([], [hardcode_into_libs], [0],
5655
    [Whether we should hardcode library paths into libraries])
5656
_LT_DECL([], [sys_lib_search_path_spec], [2],
5657
    [Compile-time system search path for libraries])
5658
_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
5659
    [Run-time system search path for libraries])
5660
])# _LT_SYS_DYNAMIC_LINKER
5661
5662
5663
# _LT_PATH_TOOL_PREFIX(TOOL)
1 by Daniel Holbach
Import upstream version 0.5.1
5664
# --------------------------
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5665
# find a file program which can recognize shared library
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5666
AC_DEFUN([_LT_PATH_TOOL_PREFIX],
5667
[m4_require([_LT_DECL_EGREP])dnl
1 by Daniel Holbach
Import upstream version 0.5.1
5668
AC_MSG_CHECKING([for $1])
5669
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
5670
[case $MAGIC_CMD in
5671
[[\\/*] |  ?:[\\/]*])
5672
  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
5673
  ;;
5674
*)
5675
  lt_save_MAGIC_CMD="$MAGIC_CMD"
5676
  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5677
dnl $ac_dummy forces splitting on constant user-supplied paths.
5678
dnl POSIX.2 word splitting is done only on the output of word expansions,
5679
dnl not every word.  This closes a longstanding sh security hole.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5680
  ac_dummy="m4_if([$2], , $PATH, [$2])"
1 by Daniel Holbach
Import upstream version 0.5.1
5681
  for ac_dir in $ac_dummy; do
5682
    IFS="$lt_save_ifs"
5683
    test -z "$ac_dir" && ac_dir=.
5684
    if test -f $ac_dir/$1; then
5685
      lt_cv_path_MAGIC_CMD="$ac_dir/$1"
5686
      if test -n "$file_magic_test_file"; then
5687
	case $deplibs_check_method in
5688
	"file_magic "*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5689
	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
1 by Daniel Holbach
Import upstream version 0.5.1
5690
	  MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
5691
	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
5692
	    $EGREP "$file_magic_regex" > /dev/null; then
5693
	    :
5694
	  else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5695
	    cat <<_LT_EOF 1>&2
1 by Daniel Holbach
Import upstream version 0.5.1
5696
5697
*** Warning: the command libtool uses to detect shared libraries,
5698
*** $file_magic_cmd, produces output that libtool cannot recognize.
5699
*** The result is that libtool may fail to recognize shared libraries
5700
*** as such.  This will affect the creation of libtool libraries that
5701
*** depend on shared libraries, but programs linked with such libtool
5702
*** libraries will work regardless of this problem.  Nevertheless, you
5703
*** may want to report the problem to your system manager and/or to
5704
*** bug-libtool@gnu.org
5705
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5706
_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
5707
	  fi ;;
5708
	esac
5709
      fi
5710
      break
5711
    fi
5712
  done
5713
  IFS="$lt_save_ifs"
5714
  MAGIC_CMD="$lt_save_MAGIC_CMD"
5715
  ;;
5716
esac])
5717
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
5718
if test -n "$MAGIC_CMD"; then
5719
  AC_MSG_RESULT($MAGIC_CMD)
5720
else
5721
  AC_MSG_RESULT(no)
5722
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5723
_LT_DECL([], [MAGIC_CMD], [0],
5724
	 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
5725
])# _LT_PATH_TOOL_PREFIX
5726
5727
# Old name:
5728
AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
5729
dnl aclocal-1.4 backwards compatibility:
5730
dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
5731
5732
5733
# _LT_PATH_MAGIC
5734
# --------------
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5735
# find a file program which can recognize a shared library
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5736
m4_defun([_LT_PATH_MAGIC],
5737
[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
1 by Daniel Holbach
Import upstream version 0.5.1
5738
if test -z "$lt_cv_path_MAGIC_CMD"; then
5739
  if test -n "$ac_tool_prefix"; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5740
    _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
1 by Daniel Holbach
Import upstream version 0.5.1
5741
  else
5742
    MAGIC_CMD=:
5743
  fi
5744
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5745
])# _LT_PATH_MAGIC
5746
5747
5748
# LT_PATH_LD
1 by Daniel Holbach
Import upstream version 0.5.1
5749
# ----------
5750
# find the pathname to the GNU or non-GNU linker
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5751
AC_DEFUN([LT_PATH_LD],
5752
[AC_REQUIRE([AC_PROG_CC])dnl
5753
AC_REQUIRE([AC_CANONICAL_HOST])dnl
5754
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
5755
m4_require([_LT_DECL_SED])dnl
5756
m4_require([_LT_DECL_EGREP])dnl
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5757
m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5758
5759
AC_ARG_WITH([gnu-ld],
5760
    [AS_HELP_STRING([--with-gnu-ld],
1 by Daniel Holbach
Import upstream version 0.5.1
5761
	[assume the C compiler uses GNU ld @<:@default=no@:>@])],
5762
    [test "$withval" = no || with_gnu_ld=yes],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5763
    [with_gnu_ld=no])dnl
5764
1 by Daniel Holbach
Import upstream version 0.5.1
5765
ac_prog=ld
5766
if test "$GCC" = yes; then
5767
  # Check if gcc -print-prog-name=ld gives a path.
5768
  AC_MSG_CHECKING([for ld used by $CC])
5769
  case $host in
5770
  *-*-mingw*)
5771
    # gcc leaves a trailing carriage return which upsets mingw
5772
    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5773
  *)
5774
    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5775
  esac
5776
  case $ac_prog in
5777
    # Accept absolute paths.
5778
    [[\\/]]* | ?:[[\\/]]*)
5779
      re_direlt='/[[^/]][[^/]]*/\.\./'
5780
      # Canonicalize the pathname of ld
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5781
      ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
5782
      while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
5783
	ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
1 by Daniel Holbach
Import upstream version 0.5.1
5784
      done
5785
      test -z "$LD" && LD="$ac_prog"
5786
      ;;
5787
  "")
5788
    # If it fails, then pretend we aren't using GCC.
5789
    ac_prog=ld
5790
    ;;
5791
  *)
5792
    # If it is relative, then search for the first ld in PATH.
5793
    with_gnu_ld=unknown
5794
    ;;
5795
  esac
5796
elif test "$with_gnu_ld" = yes; then
5797
  AC_MSG_CHECKING([for GNU ld])
5798
else
5799
  AC_MSG_CHECKING([for non-GNU ld])
5800
fi
5801
AC_CACHE_VAL(lt_cv_path_LD,
5802
[if test -z "$LD"; then
5803
  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5804
  for ac_dir in $PATH; do
5805
    IFS="$lt_save_ifs"
5806
    test -z "$ac_dir" && ac_dir=.
5807
    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5808
      lt_cv_path_LD="$ac_dir/$ac_prog"
5809
      # Check to see if the program is GNU ld.  I'd rather use --version,
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5810
      # but apparently some variants of GNU ld only accept -v.
1 by Daniel Holbach
Import upstream version 0.5.1
5811
      # Break only if it was the GNU/non-GNU ld that we prefer.
5812
      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
5813
      *GNU* | *'with BFD'*)
5814
	test "$with_gnu_ld" != no && break
5815
	;;
5816
      *)
5817
	test "$with_gnu_ld" != yes && break
5818
	;;
5819
      esac
5820
    fi
5821
  done
5822
  IFS="$lt_save_ifs"
5823
else
5824
  lt_cv_path_LD="$LD" # Let the user override the test with a path.
5825
fi])
5826
LD="$lt_cv_path_LD"
5827
if test -n "$LD"; then
5828
  AC_MSG_RESULT($LD)
5829
else
5830
  AC_MSG_RESULT(no)
5831
fi
5832
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5833
_LT_PATH_LD_GNU
5834
AC_SUBST([LD])
5835
5836
_LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
5837
])# LT_PATH_LD
5838
5839
# Old names:
5840
AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
5841
AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
5842
dnl aclocal-1.4 backwards compatibility:
5843
dnl AC_DEFUN([AM_PROG_LD], [])
5844
dnl AC_DEFUN([AC_PROG_LD], [])
5845
5846
5847
# _LT_PATH_LD_GNU
5848
#- --------------
5849
m4_defun([_LT_PATH_LD_GNU],
5850
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5851
[# I'd rather use --version here, but apparently some GNU lds only accept -v.
1 by Daniel Holbach
Import upstream version 0.5.1
5852
case `$LD -v 2>&1 </dev/null` in
5853
*GNU* | *'with BFD'*)
5854
  lt_cv_prog_gnu_ld=yes
5855
  ;;
5856
*)
5857
  lt_cv_prog_gnu_ld=no
5858
  ;;
5859
esac])
5860
with_gnu_ld=$lt_cv_prog_gnu_ld
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5861
])# _LT_PATH_LD_GNU
5862
5863
5864
# _LT_CMD_RELOAD
5865
# --------------
1 by Daniel Holbach
Import upstream version 0.5.1
5866
# find reload flag for linker
5867
#   -- PORTME Some linkers may need a different reload flag.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5868
m4_defun([_LT_CMD_RELOAD],
1 by Daniel Holbach
Import upstream version 0.5.1
5869
[AC_CACHE_CHECK([for $LD option to reload object files],
5870
  lt_cv_ld_reload_flag,
5871
  [lt_cv_ld_reload_flag='-r'])
5872
reload_flag=$lt_cv_ld_reload_flag
5873
case $reload_flag in
5874
"" | " "*) ;;
5875
*) reload_flag=" $reload_flag" ;;
5876
esac
5877
reload_cmds='$LD$reload_flag -o $output$reload_objs'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5878
case $host_os in
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
5879
  cygwin* | mingw* | pw32* | cegcc*)
5880
    if test "$GCC" != yes; then
5881
      reload_cmds=false
5882
    fi
5883
    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5884
  darwin*)
5885
    if test "$GCC" = yes; then
5886
      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
5887
    else
5888
      reload_cmds='$LD$reload_flag -o $output$reload_objs'
5889
    fi
5890
    ;;
5891
esac
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5892
_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
5893
_LT_TAGDECL([], [reload_cmds], [2])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5894
])# _LT_CMD_RELOAD
5895
5896
5897
# _LT_CHECK_MAGIC_METHOD
5898
# ----------------------
1 by Daniel Holbach
Import upstream version 0.5.1
5899
# how to check for library dependencies
5900
#  -- PORTME fill in with the dynamic library characteristics
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5901
m4_defun([_LT_CHECK_MAGIC_METHOD],
5902
[m4_require([_LT_DECL_EGREP])
5903
m4_require([_LT_DECL_OBJDUMP])
5904
AC_CACHE_CHECK([how to recognize dependent libraries],
1 by Daniel Holbach
Import upstream version 0.5.1
5905
lt_cv_deplibs_check_method,
5906
[lt_cv_file_magic_cmd='$MAGIC_CMD'
5907
lt_cv_file_magic_test_file=
5908
lt_cv_deplibs_check_method='unknown'
5909
# Need to set the preceding variable on all platforms that support
5910
# interlibrary dependencies.
5911
# 'none' -- dependencies not supported.
5912
# `unknown' -- same as none, but documents that we really don't know.
5913
# 'pass_all' -- all dependencies passed with no checks.
5914
# 'test_compile' -- check by making test program.
5915
# 'file_magic [[regex]]' -- check by looking for files in library path
5916
# which responds to the $file_magic_cmd with a given extended regex.
5917
# If you have `file' or equivalent on your system and you're not sure
5918
# whether `pass_all' will *always* work, you probably want this one.
5919
5920
case $host_os in
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
5921
aix[[4-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
5922
  lt_cv_deplibs_check_method=pass_all
5923
  ;;
5924
5925
beos*)
5926
  lt_cv_deplibs_check_method=pass_all
5927
  ;;
5928
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5929
bsdi[[45]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
5930
  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
5931
  lt_cv_file_magic_cmd='/usr/bin/file -L'
5932
  lt_cv_file_magic_test_file=/shlib/libc.so
5933
  ;;
5934
5935
cygwin*)
5936
  # func_win32_libid is a shell function defined in ltmain.sh
5937
  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5938
  lt_cv_file_magic_cmd='func_win32_libid'
5939
  ;;
5940
5941
mingw* | pw32*)
5942
  # Base MSYS/MinGW do not provide the 'file' command needed by
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5943
  # func_win32_libid shell function, so use a weaker test based on 'objdump',
5944
  # unless we find 'file', for example because we are cross-compiling.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5945
  # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
5946
  if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5947
    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5948
    lt_cv_file_magic_cmd='func_win32_libid'
5949
  else
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5950
    # Keep this pattern in sync with the one in func_win32_libid.
5951
    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5952
    lt_cv_file_magic_cmd='$OBJDUMP -f'
5953
  fi
1 by Daniel Holbach
Import upstream version 0.5.1
5954
  ;;
5955
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5956
cegcc*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5957
  # use the weaker test based on 'objdump'. See mingw*.
5958
  lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
5959
  lt_cv_file_magic_cmd='$OBJDUMP -f'
5960
  ;;
5961
1 by Daniel Holbach
Import upstream version 0.5.1
5962
darwin* | rhapsody*)
5963
  lt_cv_deplibs_check_method=pass_all
5964
  ;;
5965
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
5966
freebsd* | dragonfly*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
5967
  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
1 by Daniel Holbach
Import upstream version 0.5.1
5968
    case $host_cpu in
5969
    i*86 )
5970
      # Not sure whether the presence of OpenBSD here was a mistake.
5971
      # Let's accept both of them until this is cleared up.
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5972
      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
1 by Daniel Holbach
Import upstream version 0.5.1
5973
      lt_cv_file_magic_cmd=/usr/bin/file
5974
      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5975
      ;;
5976
    esac
5977
  else
5978
    lt_cv_deplibs_check_method=pass_all
5979
  fi
5980
  ;;
5981
5982
gnu*)
5983
  lt_cv_deplibs_check_method=pass_all
5984
  ;;
5985
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5986
haiku*)
5987
  lt_cv_deplibs_check_method=pass_all
5988
  ;;
5989
1 by Daniel Holbach
Import upstream version 0.5.1
5990
hpux10.20* | hpux11*)
5991
  lt_cv_file_magic_cmd=/usr/bin/file
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
5992
  case $host_cpu in
1 by Daniel Holbach
Import upstream version 0.5.1
5993
  ia64*)
5994
    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
5995
    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5996
    ;;
5997
  hppa*64*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
5998
    [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
1 by Daniel Holbach
Import upstream version 0.5.1
5999
    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
6000
    ;;
6001
  *)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6002
    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
1 by Daniel Holbach
Import upstream version 0.5.1
6003
    lt_cv_file_magic_test_file=/usr/lib/libc.sl
6004
    ;;
6005
  esac
6006
  ;;
6007
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6008
interix[[3-9]]*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6009
  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
6010
  lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
6011
  ;;
6012
1 by Daniel Holbach
Import upstream version 0.5.1
6013
irix5* | irix6* | nonstopux*)
6014
  case $LD in
6015
  *-32|*"-32 ") libmagic=32-bit;;
6016
  *-n32|*"-n32 ") libmagic=N32;;
6017
  *-64|*"-64 ") libmagic=64-bit;;
6018
  *) libmagic=never-match;;
6019
  esac
6020
  lt_cv_deplibs_check_method=pass_all
6021
  ;;
6022
6023
# This must be Linux ELF.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6024
linux* | k*bsd*-gnu | kopensolaris*-gnu)
1 by Daniel Holbach
Import upstream version 0.5.1
6025
  lt_cv_deplibs_check_method=pass_all
6026
  ;;
6027
1.1.2 by Daniel Holbach
Import upstream version 0.7.0
6028
netbsd*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6029
  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
1 by Daniel Holbach
Import upstream version 0.5.1
6030
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
6031
  else
6032
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
6033
  fi
6034
  ;;
6035
6036
newos6*)
6037
  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
6038
  lt_cv_file_magic_cmd=/usr/bin/file
6039
  lt_cv_file_magic_test_file=/usr/lib/libnls.so
6040
  ;;
6041
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6042
*nto* | *qnx*)
6043
  lt_cv_deplibs_check_method=pass_all
1 by Daniel Holbach
Import upstream version 0.5.1
6044
  ;;
6045
6046
openbsd*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6047
  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6048
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
1 by Daniel Holbach
Import upstream version 0.5.1
6049
  else
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6050
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
1 by Daniel Holbach
Import upstream version 0.5.1
6051
  fi
6052
  ;;
6053
6054
osf3* | osf4* | osf5*)
6055
  lt_cv_deplibs_check_method=pass_all
6056
  ;;
6057
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6058
rdos*)
6059
  lt_cv_deplibs_check_method=pass_all
6060
  ;;
6061
1 by Daniel Holbach
Import upstream version 0.5.1
6062
solaris*)
6063
  lt_cv_deplibs_check_method=pass_all
6064
  ;;
6065
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6066
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
6067
  lt_cv_deplibs_check_method=pass_all
6068
  ;;
6069
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6070
sysv4 | sysv4.3*)
1 by Daniel Holbach
Import upstream version 0.5.1
6071
  case $host_vendor in
6072
  motorola)
6073
    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
6074
    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
6075
    ;;
6076
  ncr)
6077
    lt_cv_deplibs_check_method=pass_all
6078
    ;;
6079
  sequent)
6080
    lt_cv_file_magic_cmd='/bin/file'
6081
    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
6082
    ;;
6083
  sni)
6084
    lt_cv_file_magic_cmd='/bin/file'
6085
    lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
6086
    lt_cv_file_magic_test_file=/lib/libc.so
6087
    ;;
6088
  siemens)
6089
    lt_cv_deplibs_check_method=pass_all
6090
    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6091
  pc)
6092
    lt_cv_deplibs_check_method=pass_all
6093
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
6094
  esac
6095
  ;;
6096
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6097
tpf*)
1 by Daniel Holbach
Import upstream version 0.5.1
6098
  lt_cv_deplibs_check_method=pass_all
6099
  ;;
6100
esac
6101
])
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6102
6103
file_magic_glob=
6104
want_nocaseglob=no
6105
if test "$build" = "$host"; then
6106
  case $host_os in
6107
  mingw* | pw32*)
6108
    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
6109
      want_nocaseglob=yes
6110
    else
6111
      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
6112
    fi
6113
    ;;
6114
  esac
6115
fi
6116
1 by Daniel Holbach
Import upstream version 0.5.1
6117
file_magic_cmd=$lt_cv_file_magic_cmd
6118
deplibs_check_method=$lt_cv_deplibs_check_method
6119
test -z "$deplibs_check_method" && deplibs_check_method=unknown
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6120
6121
_LT_DECL([], [deplibs_check_method], [1],
6122
    [Method to check whether dependent libraries are shared objects])
6123
_LT_DECL([], [file_magic_cmd], [1],
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6124
    [Command to use when deplibs_check_method = "file_magic"])
6125
_LT_DECL([], [file_magic_glob], [1],
6126
    [How to find potential files when deplibs_check_method = "file_magic"])
6127
_LT_DECL([], [want_nocaseglob], [1],
6128
    [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6129
])# _LT_CHECK_MAGIC_METHOD
6130
6131
6132
# LT_PATH_NM
1 by Daniel Holbach
Import upstream version 0.5.1
6133
# ----------
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6134
# find the pathname to a BSD- or MS-compatible name lister
6135
AC_DEFUN([LT_PATH_NM],
6136
[AC_REQUIRE([AC_PROG_CC])dnl
6137
AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
1 by Daniel Holbach
Import upstream version 0.5.1
6138
[if test -n "$NM"; then
6139
  # Let the user override the test.
6140
  lt_cv_path_NM="$NM"
6141
else
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6142
  lt_nm_to_check="${ac_tool_prefix}nm"
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6143
  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6144
    lt_nm_to_check="$lt_nm_to_check nm"
6145
  fi
6146
  for lt_tmp_nm in $lt_nm_to_check; do
6147
    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
6148
    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
6149
      IFS="$lt_save_ifs"
6150
      test -z "$ac_dir" && ac_dir=.
6151
      tmp_nm="$ac_dir/$lt_tmp_nm"
6152
      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
6153
	# Check to see if the nm accepts a BSD-compat flag.
6154
	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
6155
	#   nm: unknown option "B" ignored
6156
	# Tru64's nm complains that /dev/null is an invalid object file
6157
	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
6158
	*/dev/null* | *'Invalid file or object type'*)
6159
	  lt_cv_path_NM="$tmp_nm -B"
1 by Daniel Holbach
Import upstream version 0.5.1
6160
	  break
6161
	  ;;
6162
	*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6163
	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
6164
	  */dev/null*)
6165
	    lt_cv_path_NM="$tmp_nm -p"
6166
	    break
6167
	    ;;
6168
	  *)
6169
	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
6170
	    continue # so that we can try to find one that supports BSD flags
6171
	    ;;
6172
	  esac
1 by Daniel Holbach
Import upstream version 0.5.1
6173
	  ;;
6174
	esac
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6175
      fi
6176
    done
6177
    IFS="$lt_save_ifs"
1 by Daniel Holbach
Import upstream version 0.5.1
6178
  done
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6179
  : ${lt_cv_path_NM=no}
1 by Daniel Holbach
Import upstream version 0.5.1
6180
fi])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6181
if test "$lt_cv_path_NM" != "no"; then
6182
  NM="$lt_cv_path_NM"
6183
else
6184
  # Didn't find any BSD compatible name lister, look for dumpbin.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6185
  if test -n "$DUMPBIN"; then :
6186
    # Let the user override the test.
6187
  else
6188
    AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
6189
    case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
6190
    *COFF*)
6191
      DUMPBIN="$DUMPBIN -symbols"
6192
      ;;
6193
    *)
6194
      DUMPBIN=:
6195
      ;;
6196
    esac
6197
  fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6198
  AC_SUBST([DUMPBIN])
6199
  if test "$DUMPBIN" != ":"; then
6200
    NM="$DUMPBIN"
6201
  fi
6202
fi
6203
test -z "$NM" && NM=nm
6204
AC_SUBST([NM])
6205
_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
6206
6207
AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
6208
  [lt_cv_nm_interface="BSD nm"
6209
  echo "int some_variable = 0;" > conftest.$ac_ext
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6210
  (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6211
  (eval "$ac_compile" 2>conftest.err)
6212
  cat conftest.err >&AS_MESSAGE_LOG_FD
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6213
  (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6214
  (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
6215
  cat conftest.err >&AS_MESSAGE_LOG_FD
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6216
  (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6217
  cat conftest.out >&AS_MESSAGE_LOG_FD
6218
  if $GREP 'External.*some_variable' conftest.out > /dev/null; then
6219
    lt_cv_nm_interface="MS dumpbin"
6220
  fi
6221
  rm -f conftest*])
6222
])# LT_PATH_NM
6223
6224
# Old names:
6225
AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
6226
AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
6227
dnl aclocal-1.4 backwards compatibility:
6228
dnl AC_DEFUN([AM_PROG_NM], [])
6229
dnl AC_DEFUN([AC_PROG_NM], [])
6230
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6231
# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
6232
# --------------------------------
6233
# how to determine the name of the shared library
6234
# associated with a specific link library.
6235
#  -- PORTME fill in with the dynamic library characteristics
6236
m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
6237
[m4_require([_LT_DECL_EGREP])
6238
m4_require([_LT_DECL_OBJDUMP])
6239
m4_require([_LT_DECL_DLLTOOL])
6240
AC_CACHE_CHECK([how to associate runtime and link libraries],
6241
lt_cv_sharedlib_from_linklib_cmd,
6242
[lt_cv_sharedlib_from_linklib_cmd='unknown'
6243
6244
case $host_os in
6245
cygwin* | mingw* | pw32* | cegcc*)
6246
  # two different shell functions defined in ltmain.sh
6247
  # decide which to use based on capabilities of $DLLTOOL
6248
  case `$DLLTOOL --help 2>&1` in
6249
  *--identify-strict*)
6250
    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
6251
    ;;
6252
  *)
6253
    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
6254
    ;;
6255
  esac
6256
  ;;
6257
*)
6258
  # fallback: assume linklib IS sharedlib
6259
  lt_cv_sharedlib_from_linklib_cmd="$ECHO"
6260
  ;;
6261
esac
6262
])
6263
sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
6264
test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
6265
6266
_LT_DECL([], [sharedlib_from_linklib_cmd], [1],
6267
    [Command to associate shared and link libraries])
6268
])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
6269
6270
6271
# _LT_PATH_MANIFEST_TOOL
6272
# ----------------------
6273
# locate the manifest tool
6274
m4_defun([_LT_PATH_MANIFEST_TOOL],
6275
[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
6276
test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
6277
AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
6278
  [lt_cv_path_mainfest_tool=no
6279
  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
6280
  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
6281
  cat conftest.err >&AS_MESSAGE_LOG_FD
6282
  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
6283
    lt_cv_path_mainfest_tool=yes
6284
  fi
6285
  rm -f conftest*])
6286
if test "x$lt_cv_path_mainfest_tool" != xyes; then
6287
  MANIFEST_TOOL=:
6288
fi
6289
_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
6290
])# _LT_PATH_MANIFEST_TOOL
6291
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6292
6293
# LT_LIB_M
6294
# --------
1 by Daniel Holbach
Import upstream version 0.5.1
6295
# check for math library
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6296
AC_DEFUN([LT_LIB_M],
1 by Daniel Holbach
Import upstream version 0.5.1
6297
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
6298
LIBM=
6299
case $host in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6300
*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
1 by Daniel Holbach
Import upstream version 0.5.1
6301
  # These system don't have libm, or don't need it
6302
  ;;
6303
*-ncr-sysv4.3*)
6304
  AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
6305
  AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
6306
  ;;
6307
*)
6308
  AC_CHECK_LIB(m, cos, LIBM="-lm")
6309
  ;;
6310
esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6311
AC_SUBST([LIBM])
6312
])# LT_LIB_M
6313
6314
# Old name:
6315
AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
6316
dnl aclocal-1.4 backwards compatibility:
6317
dnl AC_DEFUN([AC_CHECK_LIBM], [])
6318
6319
6320
# _LT_COMPILER_NO_RTTI([TAGNAME])
6321
# -------------------------------
6322
m4_defun([_LT_COMPILER_NO_RTTI],
6323
[m4_require([_LT_TAG_COMPILER])dnl
6324
6325
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
6326
6327
if test "$GCC" = yes; then
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6328
  case $cc_basename in
6329
  nvcc*)
6330
    _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
6331
  *)
6332
    _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
6333
  esac
1 by Daniel Holbach
Import upstream version 0.5.1
6334
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6335
  _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
1 by Daniel Holbach
Import upstream version 0.5.1
6336
    lt_cv_prog_compiler_rtti_exceptions,
6337
    [-fno-rtti -fno-exceptions], [],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6338
    [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
1 by Daniel Holbach
Import upstream version 0.5.1
6339
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6340
_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
6341
	[Compiler flag to turn off builtin functions])
6342
])# _LT_COMPILER_NO_RTTI
6343
6344
6345
# _LT_CMD_GLOBAL_SYMBOLS
6346
# ----------------------
6347
m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
6348
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
6349
AC_REQUIRE([AC_PROG_CC])dnl
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6350
AC_REQUIRE([AC_PROG_AWK])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6351
AC_REQUIRE([LT_PATH_NM])dnl
6352
AC_REQUIRE([LT_PATH_LD])dnl
6353
m4_require([_LT_DECL_SED])dnl
6354
m4_require([_LT_DECL_EGREP])dnl
6355
m4_require([_LT_TAG_COMPILER])dnl
6356
1 by Daniel Holbach
Import upstream version 0.5.1
6357
# Check for command to grab the raw symbol name followed by C symbol from nm.
6358
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
6359
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
6360
[
6361
# These are sane defaults that work on at least a few old systems.
6362
# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
6363
6364
# Character class describing NM global symbol codes.
6365
symcode='[[BCDEGRST]]'
6366
6367
# Regexp to match symbols that can be accessed directly from C.
6368
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
6369
6370
# Define system-specific variables.
6371
case $host_os in
6372
aix*)
6373
  symcode='[[BCDT]]'
6374
  ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6375
cygwin* | mingw* | pw32* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
6376
  symcode='[[ABCDGISTW]]'
6377
  ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6378
hpux*)
1 by Daniel Holbach
Import upstream version 0.5.1
6379
  if test "$host_cpu" = ia64; then
6380
    symcode='[[ABCDEGRST]]'
6381
  fi
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6382
  ;;
1 by Daniel Holbach
Import upstream version 0.5.1
6383
irix* | nonstopux*)
6384
  symcode='[[BCDEGRST]]'
6385
  ;;
6386
osf*)
6387
  symcode='[[BCDEGQRST]]'
6388
  ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6389
solaris*)
1 by Daniel Holbach
Import upstream version 0.5.1
6390
  symcode='[[BDRT]]'
6391
  ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6392
sco3.2v5*)
6393
  symcode='[[DT]]'
6394
  ;;
6395
sysv4.2uw2*)
6396
  symcode='[[DT]]'
6397
  ;;
6398
sysv5* | sco5v6* | unixware* | OpenUNIX*)
6399
  symcode='[[ABDT]]'
6400
  ;;
1 by Daniel Holbach
Import upstream version 0.5.1
6401
sysv4)
6402
  symcode='[[DFNSTU]]'
6403
  ;;
6404
esac
6405
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6406
# If we're using GNU nm, then use its standard symbol codes.
6407
case `$NM -V 2>&1` in
6408
*GNU* | *'with BFD'*)
6409
  symcode='[[ABCDGIRSTW]]' ;;
6410
esac
6411
6412
# Transform an extracted symbol line into a proper C declaration.
6413
# Some systems (esp. on ia64) link data and code symbols differently,
6414
# so use this general approach.
6415
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6416
6417
# Transform an extracted symbol line into symbol name and symbol address
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6418
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
6419
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6420
1 by Daniel Holbach
Import upstream version 0.5.1
6421
# Handle CRLF in mingw tool chain
6422
opt_cr=
6423
case $build_os in
6424
mingw*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6425
  opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
1 by Daniel Holbach
Import upstream version 0.5.1
6426
  ;;
6427
esac
6428
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6429
# Try without a prefix underscore, then with it.
1 by Daniel Holbach
Import upstream version 0.5.1
6430
for ac_symprfx in "" "_"; do
6431
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6432
  # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6433
  symxfrm="\\1 $ac_symprfx\\2 \\2"
6434
1 by Daniel Holbach
Import upstream version 0.5.1
6435
  # Write the raw and C identifiers.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6436
  if test "$lt_cv_nm_interface" = "MS dumpbin"; then
6437
    # Fake it for dumpbin and say T for any non-static function
6438
    # and D for any global variable.
6439
    # Also find C++ and __fastcall symbols from MSVC++,
6440
    # which start with @ or ?.
6441
    lt_cv_sys_global_symbol_pipe="$AWK ['"\
6442
"     {last_section=section; section=\$ 3};"\
6443
"     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
6444
"     \$ 0!~/External *\|/{next};"\
6445
"     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
6446
"     {if(hide[section]) next};"\
6447
"     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
6448
"     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
6449
"     s[1]~/^[@?]/{print s[1], s[1]; next};"\
6450
"     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
6451
"     ' prfx=^$ac_symprfx]"
6452
  else
6453
    lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[	 ]]\($symcode$symcode*\)[[	 ]][[	 ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
6454
  fi
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6455
  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
1 by Daniel Holbach
Import upstream version 0.5.1
6456
6457
  # Check to see that the pipe works correctly.
6458
  pipe_works=no
6459
6460
  rm -f conftest*
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6461
  cat > conftest.$ac_ext <<_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
6462
#ifdef __cplusplus
6463
extern "C" {
6464
#endif
6465
char nm_test_var;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6466
void nm_test_func(void);
6467
void nm_test_func(void){}
1 by Daniel Holbach
Import upstream version 0.5.1
6468
#ifdef __cplusplus
6469
}
6470
#endif
6471
int main(){nm_test_var='a';nm_test_func();return(0);}
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6472
_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
6473
6474
  if AC_TRY_EVAL(ac_compile); then
6475
    # Now try to grab the symbols.
6476
    nlist=conftest.nm
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6477
    if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
1 by Daniel Holbach
Import upstream version 0.5.1
6478
      # Try sorting and uniquifying the output.
6479
      if sort "$nlist" | uniq > "$nlist"T; then
6480
	mv -f "$nlist"T "$nlist"
6481
      else
6482
	rm -f "$nlist"T
6483
      fi
6484
6485
      # Make sure that we snagged all the symbols we need.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6486
      if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
6487
	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
6488
	  cat <<_LT_EOF > conftest.$ac_ext
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6489
/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
6490
#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
6491
/* DATA imports from DLLs on WIN32 con't be const, because runtime
6492
   relocations are performed -- see ld's documentation on pseudo-relocs.  */
6493
# define LT@&t@_DLSYM_CONST
6494
#elif defined(__osf__)
6495
/* This system does not cope well with relocations in const data.  */
6496
# define LT@&t@_DLSYM_CONST
6497
#else
6498
# define LT@&t@_DLSYM_CONST const
6499
#endif
6500
1 by Daniel Holbach
Import upstream version 0.5.1
6501
#ifdef __cplusplus
6502
extern "C" {
6503
#endif
6504
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6505
_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
6506
	  # Now generate the symbol file.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6507
	  eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
6508
6509
	  cat <<_LT_EOF >> conftest.$ac_ext
6510
6511
/* The mapping between symbol names and symbols.  */
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6512
LT@&t@_DLSYM_CONST struct {
1 by Daniel Holbach
Import upstream version 0.5.1
6513
  const char *name;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6514
  void       *address;
1 by Daniel Holbach
Import upstream version 0.5.1
6515
}
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6516
lt__PROGRAM__LTX_preloaded_symbols[[]] =
1 by Daniel Holbach
Import upstream version 0.5.1
6517
{
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6518
  { "@PROGRAM@", (void *) 0 },
6519
_LT_EOF
6520
	  $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
6521
	  cat <<\_LT_EOF >> conftest.$ac_ext
6522
  {0, (void *) 0}
1 by Daniel Holbach
Import upstream version 0.5.1
6523
};
6524
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6525
/* This works around a problem in FreeBSD linker */
6526
#ifdef FREEBSD_WORKAROUND
6527
static const void *lt_preloaded_setup() {
6528
  return lt__PROGRAM__LTX_preloaded_symbols;
6529
}
6530
#endif
6531
1 by Daniel Holbach
Import upstream version 0.5.1
6532
#ifdef __cplusplus
6533
}
6534
#endif
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6535
_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
6536
	  # Now try linking the two files.
6537
	  mv conftest.$ac_objext conftstm.$ac_objext
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6538
	  lt_globsym_save_LIBS=$LIBS
6539
	  lt_globsym_save_CFLAGS=$CFLAGS
1 by Daniel Holbach
Import upstream version 0.5.1
6540
	  LIBS="conftstm.$ac_objext"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6541
	  CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
1 by Daniel Holbach
Import upstream version 0.5.1
6542
	  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
6543
	    pipe_works=yes
6544
	  fi
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6545
	  LIBS=$lt_globsym_save_LIBS
6546
	  CFLAGS=$lt_globsym_save_CFLAGS
1 by Daniel Holbach
Import upstream version 0.5.1
6547
	else
6548
	  echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
6549
	fi
6550
      else
6551
	echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
6552
      fi
6553
    else
6554
      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
6555
    fi
6556
  else
6557
    echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
6558
    cat conftest.$ac_ext >&5
6559
  fi
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
6560
  rm -rf conftest* conftst*
1 by Daniel Holbach
Import upstream version 0.5.1
6561
6562
  # Do not use the global_symbol_pipe unless it works.
6563
  if test "$pipe_works" = yes; then
6564
    break
6565
  else
6566
    lt_cv_sys_global_symbol_pipe=
6567
  fi
6568
done
6569
])
6570
if test -z "$lt_cv_sys_global_symbol_pipe"; then
6571
  lt_cv_sys_global_symbol_to_cdecl=
6572
fi
6573
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
6574
  AC_MSG_RESULT(failed)
6575
else
6576
  AC_MSG_RESULT(ok)
6577
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6578
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6579
# Response file support.
6580
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
6581
  nm_file_list_spec='@'
6582
elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
6583
  nm_file_list_spec='@'
6584
fi
6585
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6586
_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
6587
    [Take the output of nm and produce a listing of raw symbols and C names])
6588
_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
6589
    [Transform the output of nm in a proper C declaration])
6590
_LT_DECL([global_symbol_to_c_name_address],
6591
    [lt_cv_sys_global_symbol_to_c_name_address], [1],
6592
    [Transform the output of nm in a C name address pair])
6593
_LT_DECL([global_symbol_to_c_name_address_lib_prefix],
6594
    [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
6595
    [Transform the output of nm in a C name address pair when lib prefix is needed])
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6596
_LT_DECL([], [nm_file_list_spec], [1],
6597
    [Specify filename containing input files for $NM])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6598
]) # _LT_CMD_GLOBAL_SYMBOLS
6599
6600
6601
# _LT_COMPILER_PIC([TAGNAME])
6602
# ---------------------------
6603
m4_defun([_LT_COMPILER_PIC],
6604
[m4_require([_LT_TAG_COMPILER])dnl
6605
_LT_TAGVAR(lt_prog_compiler_wl, $1)=
6606
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
6607
_LT_TAGVAR(lt_prog_compiler_static, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
6608
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6609
m4_if([$1], [CXX], [
1 by Daniel Holbach
Import upstream version 0.5.1
6610
  # C++ specific cases for pic, static, wl, etc.
6611
  if test "$GXX" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6612
    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6613
    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
1 by Daniel Holbach
Import upstream version 0.5.1
6614
6615
    case $host_os in
6616
    aix*)
6617
      # All AIX code is PIC.
6618
      if test "$host_cpu" = ia64; then
6619
	# AIX 5 now supports IA64 processor
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6620
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
6621
      fi
6622
      ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6623
1 by Daniel Holbach
Import upstream version 0.5.1
6624
    amigaos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6625
      case $host_cpu in
6626
      powerpc)
6627
            # see comment about AmigaOS4 .so support
6628
            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6629
        ;;
6630
      m68k)
6631
            # FIXME: we need at least 68020 code to build shared libraries, but
6632
            # adding the `-m68020' flag to GCC prevents building anything better,
6633
            # like `-m68040'.
6634
            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
6635
        ;;
6636
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
6637
      ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6638
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6639
    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
1 by Daniel Holbach
Import upstream version 0.5.1
6640
      # PIC is the default for these OSes.
6641
      ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6642
    mingw* | cygwin* | os2* | pw32* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
6643
      # This hack is so that the source file can tell whether it is being
6644
      # built for inclusion in a dll (and should export symbols for example).
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6645
      # Although the cygwin gcc ignores -fPIC, still need this for old-style
6646
      # (--disable-auto-import) libraries
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
6647
      m4_if([$1], [GCJ], [],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6648
	[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
1 by Daniel Holbach
Import upstream version 0.5.1
6649
      ;;
6650
    darwin* | rhapsody*)
6651
      # PIC is the default on this platform
6652
      # Common symbols not allowed in MH_DYLIB files
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6653
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
1 by Daniel Holbach
Import upstream version 0.5.1
6654
      ;;
6655
    *djgpp*)
6656
      # DJGPP does not support shared libraries at all
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6657
      _LT_TAGVAR(lt_prog_compiler_pic, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
6658
      ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6659
    haiku*)
6660
      # PIC is the default for Haiku.
6661
      # The "-static" flag exists, but is broken.
6662
      _LT_TAGVAR(lt_prog_compiler_static, $1)=
6663
      ;;
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6664
    interix[[3-9]]*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6665
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
6666
      # Instead, we relocate shared libraries at runtime.
6667
      ;;
1 by Daniel Holbach
Import upstream version 0.5.1
6668
    sysv4*MP*)
6669
      if test -d /usr/nec; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6670
	_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
1 by Daniel Holbach
Import upstream version 0.5.1
6671
      fi
6672
      ;;
6673
    hpux*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6674
      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
6675
      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
6676
      # sets the default TLS model and affects inlining.
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6677
      case $host_cpu in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6678
      hppa*64*)
1 by Daniel Holbach
Import upstream version 0.5.1
6679
	;;
6680
      *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6681
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
1 by Daniel Holbach
Import upstream version 0.5.1
6682
	;;
6683
      esac
6684
      ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6685
    *qnx* | *nto*)
6686
      # QNX uses GNU C++, but need to define -shared option too, otherwise
6687
      # it will coredump.
6688
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
6689
      ;;
1 by Daniel Holbach
Import upstream version 0.5.1
6690
    *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6691
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
1 by Daniel Holbach
Import upstream version 0.5.1
6692
      ;;
6693
    esac
6694
  else
6695
    case $host_os in
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
6696
      aix[[4-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
6697
	# All AIX code is PIC.
6698
	if test "$host_cpu" = ia64; then
6699
	  # AIX 5 now supports IA64 processor
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6700
	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
6701
	else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6702
	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
1 by Daniel Holbach
Import upstream version 0.5.1
6703
	fi
6704
	;;
6705
      chorus*)
6706
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6707
	cxch68*)
1 by Daniel Holbach
Import upstream version 0.5.1
6708
	  # Green Hills C++ Compiler
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6709
	  # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
1 by Daniel Holbach
Import upstream version 0.5.1
6710
	  ;;
6711
	esac
6712
	;;
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
6713
      mingw* | cygwin* | os2* | pw32* | cegcc*)
6714
	# This hack is so that the source file can tell whether it is being
6715
	# built for inclusion in a dll (and should export symbols for example).
6716
	m4_if([$1], [GCJ], [],
6717
	  [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
6718
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
6719
      dgux*)
6720
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6721
	  ec++*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6722
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
1 by Daniel Holbach
Import upstream version 0.5.1
6723
	    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6724
	  ghcx*)
1 by Daniel Holbach
Import upstream version 0.5.1
6725
	    # Green Hills C++ Compiler
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6726
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
1 by Daniel Holbach
Import upstream version 0.5.1
6727
	    ;;
6728
	  *)
6729
	    ;;
6730
	esac
6731
	;;
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6732
      freebsd* | dragonfly*)
1 by Daniel Holbach
Import upstream version 0.5.1
6733
	# FreeBSD uses GNU C++
6734
	;;
6735
      hpux9* | hpux10* | hpux11*)
6736
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6737
	  CC*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6738
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6739
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
1 by Daniel Holbach
Import upstream version 0.5.1
6740
	    if test "$host_cpu" != ia64; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6741
	      _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
1 by Daniel Holbach
Import upstream version 0.5.1
6742
	    fi
6743
	    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6744
	  aCC*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6745
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6746
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6747
	    case $host_cpu in
1 by Daniel Holbach
Import upstream version 0.5.1
6748
	    hppa*64*|ia64*)
6749
	      # +Z the default
6750
	      ;;
6751
	    *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6752
	      _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
1 by Daniel Holbach
Import upstream version 0.5.1
6753
	      ;;
6754
	    esac
6755
	    ;;
6756
	  *)
6757
	    ;;
6758
	esac
6759
	;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6760
      interix*)
6761
	# This is c89, which is MS Visual C++ (no shared libs)
6762
	# Anyone wants to do a port?
6763
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
6764
      irix5* | irix6* | nonstopux*)
6765
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6766
	  CC*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6767
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6768
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
1 by Daniel Holbach
Import upstream version 0.5.1
6769
	    # CC pic flag -KPIC is the default.
6770
	    ;;
6771
	  *)
6772
	    ;;
6773
	esac
6774
	;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6775
      linux* | k*bsd*-gnu | kopensolaris*-gnu)
1 by Daniel Holbach
Import upstream version 0.5.1
6776
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6777
	  KCC*)
1 by Daniel Holbach
Import upstream version 0.5.1
6778
	    # KAI C++ Compiler
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6779
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
6780
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6781
	    ;;
6782
	  ecpc* )
6783
	    # old Intel C++ for x86_64 which still supported -KPIC.
6784
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6785
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6786
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
6787
	    ;;
6788
	  icpc* )
6789
	    # Intel C++, used to be incompatible with GCC.
6790
	    # ICC 10 doesn't accept -KPIC any more.
6791
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6792
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6793
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
1 by Daniel Holbach
Import upstream version 0.5.1
6794
	    ;;
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
6795
	  pgCC* | pgcpp*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6796
	    # Portland Group C++ compiler
6797
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6798
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
6799
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6800
	    ;;
6801
	  cxx*)
1 by Daniel Holbach
Import upstream version 0.5.1
6802
	    # Compaq C++
6803
	    # Make sure the PIC flag is empty.  It appears that all Alpha
6804
	    # Linux and Compaq Tru64 Unix objects are PIC.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6805
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
6806
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6807
	    ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6808
	  xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
6809
	    # IBM XL 8.0, 9.0 on PPC and BlueGene
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6810
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6811
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
6812
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
1 by Daniel Holbach
Import upstream version 0.5.1
6813
	    ;;
6814
	  *)
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6815
	    case `$CC -V 2>&1 | sed 5q` in
6816
	    *Sun\ C*)
6817
	      # Sun C++ 5.9
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6818
	      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6819
	      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6820
	      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6821
	      ;;
6822
	    esac
1 by Daniel Holbach
Import upstream version 0.5.1
6823
	    ;;
6824
	esac
6825
	;;
6826
      lynxos*)
6827
	;;
6828
      m88k*)
6829
	;;
6830
      mvs*)
6831
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6832
	  cxx*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6833
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
1 by Daniel Holbach
Import upstream version 0.5.1
6834
	    ;;
6835
	  *)
6836
	    ;;
6837
	esac
6838
	;;
1.1.2 by Daniel Holbach
Import upstream version 0.7.0
6839
      netbsd*)
1 by Daniel Holbach
Import upstream version 0.5.1
6840
	;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6841
      *qnx* | *nto*)
6842
        # QNX uses GNU C++, but need to define -shared option too, otherwise
6843
        # it will coredump.
6844
        _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
6845
        ;;
1 by Daniel Holbach
Import upstream version 0.5.1
6846
      osf3* | osf4* | osf5*)
6847
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6848
	  KCC*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6849
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
6850
	    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6851
	  RCC*)
1 by Daniel Holbach
Import upstream version 0.5.1
6852
	    # Rational C++ 2.4.1
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6853
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
1 by Daniel Holbach
Import upstream version 0.5.1
6854
	    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6855
	  cxx*)
1 by Daniel Holbach
Import upstream version 0.5.1
6856
	    # Digital/Compaq C++
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6857
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
6858
	    # Make sure the PIC flag is empty.  It appears that all Alpha
6859
	    # Linux and Compaq Tru64 Unix objects are PIC.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6860
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
6861
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
1 by Daniel Holbach
Import upstream version 0.5.1
6862
	    ;;
6863
	  *)
6864
	    ;;
6865
	esac
6866
	;;
6867
      psos*)
6868
	;;
6869
      solaris*)
6870
	case $cc_basename in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6871
	  CC* | sunCC*)
1 by Daniel Holbach
Import upstream version 0.5.1
6872
	    # Sun C++ 4.2, 5.x and Centerline C++
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6873
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6874
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6875
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
1 by Daniel Holbach
Import upstream version 0.5.1
6876
	    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6877
	  gcx*)
1 by Daniel Holbach
Import upstream version 0.5.1
6878
	    # Green Hills C++ Compiler
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6879
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
1 by Daniel Holbach
Import upstream version 0.5.1
6880
	    ;;
6881
	  *)
6882
	    ;;
6883
	esac
6884
	;;
6885
      sunos4*)
6886
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6887
	  CC*)
1 by Daniel Holbach
Import upstream version 0.5.1
6888
	    # Sun C++ 4.x
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6889
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6890
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
6891
	    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6892
	  lcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
6893
	    # Lucid
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6894
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
1 by Daniel Holbach
Import upstream version 0.5.1
6895
	    ;;
6896
	  *)
6897
	    ;;
6898
	esac
6899
	;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6900
      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6901
	case $cc_basename in
6902
	  CC*)
6903
	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6904
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6905
	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6906
	    ;;
6907
	esac
6908
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
6909
      tandem*)
6910
	case $cc_basename in
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6911
	  NCC*)
1 by Daniel Holbach
Import upstream version 0.5.1
6912
	    # NonStop-UX NCC 3.20
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6913
	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
1 by Daniel Holbach
Import upstream version 0.5.1
6914
	    ;;
6915
	  *)
6916
	    ;;
6917
	esac
6918
	;;
6919
      vxworks*)
6920
	;;
6921
      *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6922
	_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
6923
	;;
6924
    esac
6925
  fi
6926
],
6927
[
6928
  if test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6929
    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6930
    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
1 by Daniel Holbach
Import upstream version 0.5.1
6931
6932
    case $host_os in
6933
      aix*)
6934
      # All AIX code is PIC.
6935
      if test "$host_cpu" = ia64; then
6936
	# AIX 5 now supports IA64 processor
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6937
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
6938
      fi
6939
      ;;
6940
6941
    amigaos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6942
      case $host_cpu in
6943
      powerpc)
6944
            # see comment about AmigaOS4 .so support
6945
            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6946
        ;;
6947
      m68k)
6948
            # FIXME: we need at least 68020 code to build shared libraries, but
6949
            # adding the `-m68020' flag to GCC prevents building anything better,
6950
            # like `-m68040'.
6951
            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
6952
        ;;
6953
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
6954
      ;;
6955
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6956
    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
1 by Daniel Holbach
Import upstream version 0.5.1
6957
      # PIC is the default for these OSes.
6958
      ;;
6959
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6960
    mingw* | cygwin* | pw32* | os2* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
6961
      # This hack is so that the source file can tell whether it is being
6962
      # built for inclusion in a dll (and should export symbols for example).
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6963
      # Although the cygwin gcc ignores -fPIC, still need this for old-style
6964
      # (--disable-auto-import) libraries
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
6965
      m4_if([$1], [GCJ], [],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6966
	[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
1 by Daniel Holbach
Import upstream version 0.5.1
6967
      ;;
6968
6969
    darwin* | rhapsody*)
6970
      # PIC is the default on this platform
6971
      # Common symbols not allowed in MH_DYLIB files
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6972
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
6973
      ;;
6974
1.1.16 by Robert Ancell
Import upstream version 2.31.6
6975
    haiku*)
6976
      # PIC is the default for Haiku.
6977
      # The "-static" flag exists, but is broken.
6978
      _LT_TAGVAR(lt_prog_compiler_static, $1)=
6979
      ;;
6980
1.1.8 by Alexander Sack
Import upstream version 2.27.8
6981
    hpux*)
6982
      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
6983
      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
6984
      # sets the default TLS model and affects inlining.
6985
      case $host_cpu in
6986
      hppa*64*)
6987
	# +Z the default
6988
	;;
6989
      *)
6990
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6991
	;;
6992
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
6993
      ;;
6994
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
6995
    interix[[3-9]]*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
6996
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
6997
      # Instead, we relocate shared libraries at runtime.
6998
      ;;
6999
1 by Daniel Holbach
Import upstream version 0.5.1
7000
    msdosdjgpp*)
7001
      # Just because we use GCC doesn't mean we suddenly get shared libraries
7002
      # on systems that don't support them.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7003
      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7004
      enable_shared=no
7005
      ;;
7006
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7007
    *nto* | *qnx*)
7008
      # QNX uses GNU C++, but need to define -shared option too, otherwise
7009
      # it will coredump.
7010
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
7011
      ;;
7012
1 by Daniel Holbach
Import upstream version 0.5.1
7013
    sysv4*MP*)
7014
      if test -d /usr/nec; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7015
	_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
1 by Daniel Holbach
Import upstream version 0.5.1
7016
      fi
7017
      ;;
7018
7019
    *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7020
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
1 by Daniel Holbach
Import upstream version 0.5.1
7021
      ;;
7022
    esac
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7023
7024
    case $cc_basename in
7025
    nvcc*) # Cuda Compiler Driver 2.2
7026
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
7027
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC'
7028
      ;;
7029
    esac
1 by Daniel Holbach
Import upstream version 0.5.1
7030
  else
7031
    # PORTME Check for flag to pass linker flags through the system compiler.
7032
    case $host_os in
7033
    aix*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7034
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
7035
      if test "$host_cpu" = ia64; then
7036
	# AIX 5 now supports IA64 processor
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7037
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
7038
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7039
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
1 by Daniel Holbach
Import upstream version 0.5.1
7040
      fi
7041
      ;;
7042
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7043
    mingw* | cygwin* | pw32* | os2* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
7044
      # This hack is so that the source file can tell whether it is being
7045
      # built for inclusion in a dll (and should export symbols for example).
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
7046
      m4_if([$1], [GCJ], [],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7047
	[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
1 by Daniel Holbach
Import upstream version 0.5.1
7048
      ;;
7049
7050
    hpux9* | hpux10* | hpux11*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7051
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
7052
      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7053
      # not for PA HP-UX.
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7054
      case $host_cpu in
1 by Daniel Holbach
Import upstream version 0.5.1
7055
      hppa*64*|ia64*)
7056
	# +Z the default
7057
	;;
7058
      *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7059
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
1 by Daniel Holbach
Import upstream version 0.5.1
7060
	;;
7061
      esac
7062
      # Is there a better lt_prog_compiler_static that works with the bundled CC?
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7063
      _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
1 by Daniel Holbach
Import upstream version 0.5.1
7064
      ;;
7065
7066
    irix5* | irix6* | nonstopux*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7067
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
7068
      # PIC (with -KPIC) is the default.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7069
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
1 by Daniel Holbach
Import upstream version 0.5.1
7070
      ;;
7071
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7072
    linux* | k*bsd*-gnu | kopensolaris*-gnu)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7073
      case $cc_basename in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7074
      # old Intel for x86_64 which still supported -KPIC.
7075
      ecc*)
7076
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7077
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7078
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
7079
        ;;
7080
      # icc used to be incompatible with GCC.
7081
      # ICC 10 doesn't accept -KPIC any more.
7082
      icc* | ifort*)
7083
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7084
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
7085
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
7086
        ;;
7087
      # Lahey Fortran 8.1.
7088
      lf95*)
7089
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7090
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
7091
	_LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
7092
	;;
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7093
      nagfor*)
7094
	# NAG Fortran compiler
7095
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
7096
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
7097
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
7098
	;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7099
      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7100
        # Portland Group compilers (*not* the Pentium gcc compiler,
7101
	# which looks to be a dead project)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7102
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7103
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
7104
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7105
        ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7106
      ccc*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7107
        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
7108
        # All Alpha code is PIC.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7109
        _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
1 by Daniel Holbach
Import upstream version 0.5.1
7110
        ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7111
      xl* | bgxl* | bgf* | mpixl*)
7112
	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7113
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7114
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
7115
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
7116
	;;
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7117
      *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7118
	case `$CC -V 2>&1 | sed 5q` in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7119
	*Sun\ F* | *Sun*Fortran*)
7120
	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
7121
	  _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7122
	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
7123
	  _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
7124
	  ;;
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7125
	*Sun\ C*)
7126
	  # Sun C 5.9
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7127
	  _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7128
	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
7129
	  _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7130
	  ;;
7131
	esac
7132
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
7133
      esac
7134
      ;;
7135
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7136
    newsos6)
7137
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7138
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
7139
      ;;
7140
7141
    *nto* | *qnx*)
7142
      # QNX uses GNU C++, but need to define -shared option too, otherwise
7143
      # it will coredump.
7144
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
7145
      ;;
7146
1 by Daniel Holbach
Import upstream version 0.5.1
7147
    osf3* | osf4* | osf5*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7148
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
1 by Daniel Holbach
Import upstream version 0.5.1
7149
      # All OSF/1 code is PIC.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7150
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
1 by Daniel Holbach
Import upstream version 0.5.1
7151
      ;;
7152
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7153
    rdos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7154
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7155
      ;;
7156
1 by Daniel Holbach
Import upstream version 0.5.1
7157
    solaris*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7158
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7159
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7160
      case $cc_basename in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7161
      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7162
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7163
      *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7164
	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7165
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
7166
      ;;
7167
7168
    sunos4*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7169
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
7170
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
7171
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
7172
      ;;
7173
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7174
    sysv4 | sysv4.2uw2* | sysv4.3*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7175
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7176
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7177
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
7178
      ;;
7179
7180
    sysv4*MP*)
7181
      if test -d /usr/nec ;then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7182
	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
7183
	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
7184
      fi
7185
      ;;
7186
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7187
    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7188
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7189
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
7190
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7191
      ;;
7192
7193
    unicos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7194
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
7195
      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7196
      ;;
7197
1 by Daniel Holbach
Import upstream version 0.5.1
7198
    uts4*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7199
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
7200
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
1 by Daniel Holbach
Import upstream version 0.5.1
7201
      ;;
7202
7203
    *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7204
      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7205
      ;;
7206
    esac
7207
  fi
7208
])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7209
case $host_os in
7210
  # For platforms which do not support PIC, -DPIC is meaningless:
7211
  *djgpp*)
7212
    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
7213
    ;;
7214
  *)
7215
    _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
7216
    ;;
7217
esac
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7218
7219
AC_CACHE_CHECK([for $compiler option to produce PIC],
7220
  [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
7221
  [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
7222
_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
1 by Daniel Holbach
Import upstream version 0.5.1
7223
7224
#
7225
# Check to make sure the PIC flag actually works.
7226
#
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7227
if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
7228
  _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
7229
    [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
7230
    [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
7231
    [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
1 by Daniel Holbach
Import upstream version 0.5.1
7232
     "" | " "*) ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7233
     *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7234
     esac],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7235
    [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
7236
     _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
1 by Daniel Holbach
Import upstream version 0.5.1
7237
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7238
_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
7239
	[Additional compiler flags for building library objects])
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7240
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7241
_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
7242
	[How to pass a linker flag through the compiler])
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7243
#
7244
# Check to make sure the static flag actually works.
7245
#
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7246
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
7247
_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
7248
  _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7249
  $lt_tmp_static_flag,
7250
  [],
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7251
  [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
7252
_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
7253
	[Compiler flag to prevent dynamic linking])
7254
])# _LT_COMPILER_PIC
7255
7256
7257
# _LT_LINKER_SHLIBS([TAGNAME])
7258
# ----------------------------
1 by Daniel Holbach
Import upstream version 0.5.1
7259
# See if the linker supports building shared libraries.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7260
m4_defun([_LT_LINKER_SHLIBS],
7261
[AC_REQUIRE([LT_PATH_LD])dnl
7262
AC_REQUIRE([LT_PATH_NM])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7263
m4_require([_LT_PATH_MANIFEST_TOOL])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7264
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7265
m4_require([_LT_DECL_EGREP])dnl
7266
m4_require([_LT_DECL_SED])dnl
7267
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
7268
m4_require([_LT_TAG_COMPILER])dnl
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7269
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7270
m4_if([$1], [CXX], [
7271
  _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7272
  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
1 by Daniel Holbach
Import upstream version 0.5.1
7273
  case $host_os in
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
7274
  aix[[4-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
7275
    # If we're using GNU nm, then we don't want the "-C" option.
7276
    # -C means demangle to AIX nm, but means don't demangle with GNU nm
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7277
    # Also, AIX nm treats weak defined symbols like other global defined
7278
    # symbols, whereas GNU nm marks them as "W".
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7279
    if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7280
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
1 by Daniel Holbach
Import upstream version 0.5.1
7281
    else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7282
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
1 by Daniel Holbach
Import upstream version 0.5.1
7283
    fi
7284
    ;;
7285
  pw32*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7286
    _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7287
    ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7288
  cygwin* | mingw* | cegcc*)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7289
    case $cc_basename in
7290
    cl*) ;;
7291
    *)
7292
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
7293
      _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
7294
      ;;
7295
    esac
7296
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7297
  *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7298
    _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7299
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7300
  esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7301
], [
1 by Daniel Holbach
Import upstream version 0.5.1
7302
  runpath_var=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7303
  _LT_TAGVAR(allow_undefined_flag, $1)=
7304
  _LT_TAGVAR(always_export_symbols, $1)=no
7305
  _LT_TAGVAR(archive_cmds, $1)=
7306
  _LT_TAGVAR(archive_expsym_cmds, $1)=
7307
  _LT_TAGVAR(compiler_needs_object, $1)=no
7308
  _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7309
  _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7310
  _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
7311
  _LT_TAGVAR(hardcode_automatic, $1)=no
7312
  _LT_TAGVAR(hardcode_direct, $1)=no
7313
  _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7314
  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7315
  _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
7316
  _LT_TAGVAR(hardcode_libdir_separator, $1)=
7317
  _LT_TAGVAR(hardcode_minus_L, $1)=no
7318
  _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
7319
  _LT_TAGVAR(inherit_rpath, $1)=no
7320
  _LT_TAGVAR(link_all_deplibs, $1)=unknown
7321
  _LT_TAGVAR(module_cmds, $1)=
7322
  _LT_TAGVAR(module_expsym_cmds, $1)=
7323
  _LT_TAGVAR(old_archive_from_new_cmds, $1)=
7324
  _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
7325
  _LT_TAGVAR(thread_safe_flag_spec, $1)=
7326
  _LT_TAGVAR(whole_archive_flag_spec, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
7327
  # include_expsyms should be a list of space-separated symbols to be *always*
7328
  # included in the symbol list
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7329
  _LT_TAGVAR(include_expsyms, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
7330
  # exclude_expsyms can be an extended regexp of symbols to exclude
7331
  # it will be wrapped by ` (' and `)$', so one must not match beginning or
7332
  # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
7333
  # as well as any symbol that contains `d'.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7334
  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
1 by Daniel Holbach
Import upstream version 0.5.1
7335
  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
7336
  # platforms (ab)use it in PIC code, but their linkers get confused if
7337
  # the symbol is explicitly referenced.  Since portable code cannot
7338
  # rely on this symbol name, it's probably fine to never include it in
7339
  # preloaded symbol tables.
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
7340
  # Exclude shared library initialization/finalization symbols.
7341
dnl Note also adjust exclude_expsyms for C++ above.
1 by Daniel Holbach
Import upstream version 0.5.1
7342
  extract_expsyms_cmds=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7343
1 by Daniel Holbach
Import upstream version 0.5.1
7344
  case $host_os in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7345
  cygwin* | mingw* | pw32* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
7346
    # FIXME: the MSVC++ port hasn't been tested in a loooong time
7347
    # When not using gcc, we currently assume that we are using
7348
    # Microsoft Visual C++.
7349
    if test "$GCC" != yes; then
7350
      with_gnu_ld=no
7351
    fi
7352
    ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7353
  interix*)
7354
    # we just hope/assume this is gcc and not c89 (= MSVC++)
7355
    with_gnu_ld=yes
7356
    ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7357
  openbsd*)
7358
    with_gnu_ld=no
7359
    ;;
7360
  esac
7361
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7362
  _LT_TAGVAR(ld_shlibs, $1)=yes
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7363
7364
  # On some targets, GNU ld is compatible enough with the native linker
7365
  # that we're better off using the native interface for both.
7366
  lt_use_gnu_ld_interface=no
1 by Daniel Holbach
Import upstream version 0.5.1
7367
  if test "$with_gnu_ld" = yes; then
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7368
    case $host_os in
7369
      aix*)
7370
	# The AIX port of GNU ld has always aspired to compatibility
7371
	# with the native linker.  However, as the warning in the GNU ld
7372
	# block says, versions before 2.19.5* couldn't really create working
7373
	# shared libraries, regardless of the interface used.
7374
	case `$LD -v 2>&1` in
7375
	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
7376
	  *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
7377
	  *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
7378
	  *)
7379
	    lt_use_gnu_ld_interface=yes
7380
	    ;;
7381
	esac
7382
	;;
7383
      *)
7384
	lt_use_gnu_ld_interface=yes
7385
	;;
7386
    esac
7387
  fi
7388
7389
  if test "$lt_use_gnu_ld_interface" = yes; then
1 by Daniel Holbach
Import upstream version 0.5.1
7390
    # If archive_cmds runs LD, not CC, wlarc should be empty
7391
    wlarc='${wl}'
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
7392
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7393
    # Set some defaults for GNU ld with shared library support. These
7394
    # are reset later if shared libraries are not supported. Putting them
7395
    # here allows them to be overridden if necessary.
7396
    runpath_var=LD_RUN_PATH
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7397
    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7398
    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7399
    # ancient GNU ld didn't support --whole-archive et. al.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7400
    if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
7401
      _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7402
    else
7403
      _LT_TAGVAR(whole_archive_flag_spec, $1)=
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7404
    fi
7405
    supports_anon_versioning=no
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7406
    case `$LD -v 2>&1` in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7407
      *GNU\ gold*) supports_anon_versioning=yes ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7408
      *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
7409
      *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
7410
      *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
7411
      *\ 2.11.*) ;; # other 2.11 versions
7412
      *) supports_anon_versioning=yes ;;
7413
    esac
7414
1 by Daniel Holbach
Import upstream version 0.5.1
7415
    # See if GNU ld supports shared libraries.
7416
    case $host_os in
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
7417
    aix[[3-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
7418
      # On AIX/PPC, the GNU linker is very broken
7419
      if test "$host_cpu" != ia64; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7420
	_LT_TAGVAR(ld_shlibs, $1)=no
7421
	cat <<_LT_EOF 1>&2
1 by Daniel Holbach
Import upstream version 0.5.1
7422
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7423
*** Warning: the GNU linker, at least up to release 2.19, is reported
1 by Daniel Holbach
Import upstream version 0.5.1
7424
*** to be unable to reliably create shared libraries on AIX.
7425
*** Therefore, libtool is disabling shared libraries support.  If you
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7426
*** really care for shared libraries, you may want to install binutils
7427
*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
7428
*** You will then need to restart the configuration process.
1 by Daniel Holbach
Import upstream version 0.5.1
7429
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7430
_LT_EOF
1 by Daniel Holbach
Import upstream version 0.5.1
7431
      fi
7432
      ;;
7433
7434
    amigaos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7435
      case $host_cpu in
7436
      powerpc)
7437
            # see comment about AmigaOS4 .so support
7438
            _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7439
            _LT_TAGVAR(archive_expsym_cmds, $1)=''
7440
        ;;
7441
      m68k)
7442
            _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
7443
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7444
            _LT_TAGVAR(hardcode_minus_L, $1)=yes
7445
        ;;
7446
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
7447
      ;;
7448
7449
    beos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7450
      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7451
	_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
1 by Daniel Holbach
Import upstream version 0.5.1
7452
	# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
7453
	# support --undefined.  This deserves some investigation.  FIXME
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7454
	_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7455
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7456
	_LT_TAGVAR(ld_shlibs, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7457
      fi
7458
      ;;
7459
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7460
    cygwin* | mingw* | pw32* | cegcc*)
7461
      # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
1 by Daniel Holbach
Import upstream version 0.5.1
7462
      # as there is no search path for DLLs.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7463
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7464
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7465
      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7466
      _LT_TAGVAR(always_export_symbols, $1)=no
7467
      _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7468
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
7469
      _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
1 by Daniel Holbach
Import upstream version 0.5.1
7470
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7471
      if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7472
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7473
	# If the export-symbols file already is a .def file (1st line
7474
	# is EXPORTS), use it as is; otherwise, prepend...
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7475
	_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
1 by Daniel Holbach
Import upstream version 0.5.1
7476
	  cp $export_symbols $output_objdir/$soname.def;
7477
	else
7478
	  echo EXPORTS > $output_objdir/$soname.def;
7479
	  cat $export_symbols >> $output_objdir/$soname.def;
7480
	fi~
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7481
	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
7482
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7483
	_LT_TAGVAR(ld_shlibs, $1)=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7484
      fi
7485
      ;;
7486
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7487
    haiku*)
7488
      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7489
      _LT_TAGVAR(link_all_deplibs, $1)=yes
7490
      ;;
7491
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7492
    interix[[3-9]]*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7493
      _LT_TAGVAR(hardcode_direct, $1)=no
7494
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7495
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7496
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7497
      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
7498
      # Instead, shared libraries are loaded at an image base (0x10000000 by
7499
      # default) and relocated if they conflict, which is a slow very memory
7500
      # consuming and fragmenting process.  To avoid this, we pick a random,
7501
      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
7502
      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7503
      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
7504
      _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7505
      ;;
7506
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7507
    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7508
      tmp_diet=no
7509
      if test "$host_os" = linux-dietlibc; then
7510
	case $cc_basename in
7511
	  diet\ *) tmp_diet=yes;;	# linux-dietlibc with static linking (!diet-dyn)
7512
	esac
7513
      fi
7514
      if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
7515
	 && test "$tmp_diet" = no
7516
      then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7517
	tmp_addflag=' $pic_flag'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7518
	tmp_sharedflag='-shared'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7519
	case $cc_basename,$host_cpu in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7520
        pgcc*)				# Portland Group C compiler
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7521
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7522
	  tmp_addflag=' $pic_flag'
7523
	  ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7524
	pgf77* | pgf90* | pgf95* | pgfortran*)
7525
					# Portland Group f77 and f90 compilers
7526
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7527
	  tmp_addflag=' $pic_flag -Mnomain' ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7528
	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7529
	  tmp_addflag=' -i_dynamic' ;;
7530
	efc*,ia64* | ifort*,ia64*)	# Intel Fortran compiler on ia64
7531
	  tmp_addflag=' -i_dynamic -nofor_main' ;;
7532
	ifc* | ifort*)			# Intel Fortran compiler
7533
	  tmp_addflag=' -nofor_main' ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7534
	lf95*)				# Lahey Fortran 8.1
7535
	  _LT_TAGVAR(whole_archive_flag_spec, $1)=
7536
	  tmp_sharedflag='--shared' ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7537
	xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7538
	  tmp_sharedflag='-qmkshrobj'
7539
	  tmp_addflag= ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7540
	nvcc*)	# Cuda Compiler Driver 2.2
7541
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
7542
	  _LT_TAGVAR(compiler_needs_object, $1)=yes
7543
	  ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7544
	esac
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7545
	case `$CC -V 2>&1 | sed 5q` in
7546
	*Sun\ C*)			# Sun C 5.9
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7547
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7548
	  _LT_TAGVAR(compiler_needs_object, $1)=yes
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7549
	  tmp_sharedflag='-G' ;;
7550
	*Sun\ F*)			# Sun Fortran 8.3
7551
	  tmp_sharedflag='-G' ;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7552
	esac
7553
	_LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7554
7555
        if test "x$supports_anon_versioning" = xyes; then
7556
          _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7557
	    cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7558
	    echo "local: *; };" >> $output_objdir/$libname.ver~
7559
	    $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
7560
        fi
7561
7562
	case $cc_basename in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7563
	xlf* | bgf* | bgxlf* | mpixlf*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7564
	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
7565
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
7566
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7567
	  _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7568
	  _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7569
	  if test "x$supports_anon_versioning" = xyes; then
7570
	    _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7571
	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7572
	      echo "local: *; };" >> $output_objdir/$libname.ver~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7573
	      $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7574
	  fi
7575
	  ;;
7576
	esac
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7577
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7578
        _LT_TAGVAR(ld_shlibs, $1)=no
1.1.2 by Daniel Holbach
Import upstream version 0.7.0
7579
      fi
7580
      ;;
7581
7582
    netbsd*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7583
      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7584
	_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7585
	wlarc=
7586
      else
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7587
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7588
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7589
      fi
7590
      ;;
7591
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7592
    solaris*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7593
      if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
7594
	_LT_TAGVAR(ld_shlibs, $1)=no
7595
	cat <<_LT_EOF 1>&2
1 by Daniel Holbach
Import upstream version 0.5.1
7596
7597
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
7598
*** create shared libraries on Solaris systems.  Therefore, libtool
7599
*** is disabling shared libraries support.  We urge you to upgrade GNU
7600
*** binutils to release 2.9.1 or newer.  Another option is to modify
7601
*** your PATH or compiler configuration so that the native linker is
7602
*** used, and then restart.
7603
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7604
_LT_EOF
7605
      elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7606
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7607
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7608
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7609
	_LT_TAGVAR(ld_shlibs, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7610
      fi
7611
      ;;
7612
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7613
    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
7614
      case `$LD -v 2>&1` in
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7615
        *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7616
	_LT_TAGVAR(ld_shlibs, $1)=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7617
	cat <<_LT_EOF 1>&2
7618
7619
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
7620
*** reliably create shared libraries on SCO systems.  Therefore, libtool
7621
*** is disabling shared libraries support.  We urge you to upgrade GNU
7622
*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
7623
*** your PATH or compiler configuration so that the native linker is
7624
*** used, and then restart.
7625
7626
_LT_EOF
7627
	;;
7628
	*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7629
	  # For security reasons, it is highly recommended that you always
7630
	  # use absolute paths for naming shared libraries, and exclude the
7631
	  # DT_RUNPATH tag from executables and libraries.  But doing so
7632
	  # requires that you compile everything twice, which is a pain.
7633
	  if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7634
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7635
	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7636
	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7637
	  else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7638
	    _LT_TAGVAR(ld_shlibs, $1)=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7639
	  fi
7640
	;;
7641
      esac
7642
      ;;
7643
1 by Daniel Holbach
Import upstream version 0.5.1
7644
    sunos4*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7645
      _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
1 by Daniel Holbach
Import upstream version 0.5.1
7646
      wlarc=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7647
      _LT_TAGVAR(hardcode_direct, $1)=yes
7648
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7649
      ;;
7650
7651
    *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7652
      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7653
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7654
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7655
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7656
	_LT_TAGVAR(ld_shlibs, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7657
      fi
7658
      ;;
7659
    esac
7660
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7661
    if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7662
      runpath_var=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7663
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7664
      _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7665
      _LT_TAGVAR(whole_archive_flag_spec, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
7666
    fi
7667
  else
7668
    # PORTME fill in a description of your system's linker (not GNU ld)
7669
    case $host_os in
7670
    aix3*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7671
      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7672
      _LT_TAGVAR(always_export_symbols, $1)=yes
7673
      _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
1 by Daniel Holbach
Import upstream version 0.5.1
7674
      # Note: this linker hardcodes the directories in LIBPATH if there
7675
      # are no directories specified by -L.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7676
      _LT_TAGVAR(hardcode_minus_L, $1)=yes
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7677
      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
1 by Daniel Holbach
Import upstream version 0.5.1
7678
	# Neither direct hardcoding nor static linking is supported with a
7679
	# broken collect2.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7680
	_LT_TAGVAR(hardcode_direct, $1)=unsupported
1 by Daniel Holbach
Import upstream version 0.5.1
7681
      fi
7682
      ;;
7683
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
7684
    aix[[4-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
7685
      if test "$host_cpu" = ia64; then
7686
	# On IA64, the linker does run time linking by default, so we don't
7687
	# have to do anything special.
7688
	aix_use_runtimelinking=no
7689
	exp_sym_flag='-Bexport'
7690
	no_entry_flag=""
7691
      else
7692
	# If we're using GNU nm, then we don't want the "-C" option.
7693
	# -C means demangle to AIX nm, but means don't demangle with GNU nm
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7694
	# Also, AIX nm treats weak defined symbols like other global
7695
	# defined symbols, whereas GNU nm marks them as "W".
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7696
	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7697
	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
1 by Daniel Holbach
Import upstream version 0.5.1
7698
	else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7699
	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
1 by Daniel Holbach
Import upstream version 0.5.1
7700
	fi
7701
	aix_use_runtimelinking=no
7702
7703
	# Test if we are trying to use run time linking or normal
7704
	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
7705
	# need to do runtime linking.
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
7706
	case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
1 by Daniel Holbach
Import upstream version 0.5.1
7707
	  for ld_flag in $LDFLAGS; do
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7708
	  if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
7709
	    aix_use_runtimelinking=yes
7710
	    break
7711
	  fi
1 by Daniel Holbach
Import upstream version 0.5.1
7712
	  done
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7713
	  ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7714
	esac
7715
7716
	exp_sym_flag='-bexport'
7717
	no_entry_flag='-bnoentry'
7718
      fi
7719
7720
      # When large executables or shared objects are built, AIX ld can
7721
      # have problems creating the table of contents.  If linking a library
7722
      # or program results in "error TOC overflow" add -mminimal-toc to
7723
      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
7724
      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
7725
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7726
      _LT_TAGVAR(archive_cmds, $1)=''
7727
      _LT_TAGVAR(hardcode_direct, $1)=yes
7728
      _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7729
      _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7730
      _LT_TAGVAR(link_all_deplibs, $1)=yes
7731
      _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
1 by Daniel Holbach
Import upstream version 0.5.1
7732
7733
      if test "$GCC" = yes; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7734
	case $host_os in aix4.[[012]]|aix4.[[012]].*)
1 by Daniel Holbach
Import upstream version 0.5.1
7735
	# We only want to do this on AIX 4.2 and lower, the check
7736
	# below for broken collect2 doesn't work under 4.3+
7737
	  collect2name=`${CC} -print-prog-name=collect2`
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7738
	  if test -f "$collect2name" &&
7739
	   strings "$collect2name" | $GREP resolve_lib_name >/dev/null
1 by Daniel Holbach
Import upstream version 0.5.1
7740
	  then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7741
	  # We have reworked collect2
7742
	  :
1 by Daniel Holbach
Import upstream version 0.5.1
7743
	  else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7744
	  # We have old collect2
7745
	  _LT_TAGVAR(hardcode_direct, $1)=unsupported
7746
	  # It fails to find uninstalled libraries when the uninstalled
7747
	  # path is not listed in the libpath.  Setting hardcode_minus_L
7748
	  # to unsupported forces relinking
7749
	  _LT_TAGVAR(hardcode_minus_L, $1)=yes
7750
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7751
	  _LT_TAGVAR(hardcode_libdir_separator, $1)=
1 by Daniel Holbach
Import upstream version 0.5.1
7752
	  fi
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7753
	  ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7754
	esac
7755
	shared_flag='-shared'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7756
	if test "$aix_use_runtimelinking" = yes; then
7757
	  shared_flag="$shared_flag "'${wl}-G'
7758
	fi
1 by Daniel Holbach
Import upstream version 0.5.1
7759
      else
7760
	# not using gcc
7761
	if test "$host_cpu" = ia64; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7762
	# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
7763
	# chokes on -Wl,-G. The following line is correct:
1 by Daniel Holbach
Import upstream version 0.5.1
7764
	  shared_flag='-G'
7765
	else
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7766
	  if test "$aix_use_runtimelinking" = yes; then
1 by Daniel Holbach
Import upstream version 0.5.1
7767
	    shared_flag='${wl}-G'
7768
	  else
7769
	    shared_flag='${wl}-bM:SRE'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7770
	  fi
1 by Daniel Holbach
Import upstream version 0.5.1
7771
	fi
7772
      fi
7773
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7774
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
1 by Daniel Holbach
Import upstream version 0.5.1
7775
      # It seems that -bexpall does not export symbols beginning with
7776
      # underscore (_), so it is better to generate a list of symbols to export.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7777
      _LT_TAGVAR(always_export_symbols, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
7778
      if test "$aix_use_runtimelinking" = yes; then
7779
	# Warning - without using the other runtime loading flags (-brtl),
7780
	# -berok will link without error, but may produce a broken library.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7781
	_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
7782
        # Determine the default libpath from the value encoded in an
7783
        # empty executable.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7784
        _LT_SYS_MODULE_PATH_AIX([$1])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7785
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7786
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7787
      else
1 by Daniel Holbach
Import upstream version 0.5.1
7788
	if test "$host_cpu" = ia64; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7789
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
7790
	  _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7791
	  _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
1 by Daniel Holbach
Import upstream version 0.5.1
7792
	else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7793
	 # Determine the default libpath from the value encoded in an
7794
	 # empty executable.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7795
	 _LT_SYS_MODULE_PATH_AIX([$1])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7796
	 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
1 by Daniel Holbach
Import upstream version 0.5.1
7797
	  # Warning - without using the other run time loading flags,
7798
	  # -berok will link without error, but may produce a broken library.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7799
	  _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
7800
	  _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7801
	  if test "$with_gnu_ld" = yes; then
7802
	    # We only use this code for GNU lds that support --whole-archive.
7803
	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7804
	  else
7805
	    # Exported symbols can be pulled into shared objects from archives
7806
	    _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
7807
	  fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7808
	  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7809
	  # This is similar to how AIX traditionally builds its shared libraries.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7810
	  _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
1 by Daniel Holbach
Import upstream version 0.5.1
7811
	fi
7812
      fi
7813
      ;;
7814
7815
    amigaos*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7816
      case $host_cpu in
7817
      powerpc)
7818
            # see comment about AmigaOS4 .so support
7819
            _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7820
            _LT_TAGVAR(archive_expsym_cmds, $1)=''
7821
        ;;
7822
      m68k)
7823
            _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
7824
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7825
            _LT_TAGVAR(hardcode_minus_L, $1)=yes
7826
        ;;
7827
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
7828
      ;;
7829
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7830
    bsdi[[45]]*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7831
      _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
1 by Daniel Holbach
Import upstream version 0.5.1
7832
      ;;
7833
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7834
    cygwin* | mingw* | pw32* | cegcc*)
1 by Daniel Holbach
Import upstream version 0.5.1
7835
      # When not using gcc, we currently assume that we are using
7836
      # Microsoft Visual C++.
7837
      # hardcode_libdir_flag_spec is actually meaningless, as there is
7838
      # no search path for DLLs.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7839
      case $cc_basename in
7840
      cl*)
7841
	# Native MSVC
7842
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
7843
	_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7844
	_LT_TAGVAR(always_export_symbols, $1)=yes
7845
	_LT_TAGVAR(file_list_spec, $1)='@'
7846
	# Tell ltmain to make .lib files, not .a files.
7847
	libext=lib
7848
	# Tell ltmain to make .dll files, not .so files.
7849
	shrext_cmds=".dll"
7850
	# FIXME: Setting linknames here is a bad hack.
7851
	_LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
7852
	_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7853
	    sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
7854
	  else
7855
	    sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
7856
	  fi~
7857
	  $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
7858
	  linknames='
7859
	# The linker will not automatically build a static lib if we build a DLL.
7860
	# _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
7861
	_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7862
	_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
7863
	# Don't use ranlib
7864
	_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
7865
	_LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
7866
	  lt_tool_outputfile="@TOOL_OUTPUT@"~
7867
	  case $lt_outputfile in
7868
	    *.exe|*.EXE) ;;
7869
	    *)
7870
	      lt_outputfile="$lt_outputfile.exe"
7871
	      lt_tool_outputfile="$lt_tool_outputfile.exe"
7872
	      ;;
7873
	  esac~
7874
	  if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
7875
	    $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
7876
	    $RM "$lt_outputfile.manifest";
7877
	  fi'
7878
	;;
7879
      *)
7880
	# Assume MSVC wrapper
7881
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
7882
	_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7883
	# Tell ltmain to make .lib files, not .a files.
7884
	libext=lib
7885
	# Tell ltmain to make .dll files, not .so files.
7886
	shrext_cmds=".dll"
7887
	# FIXME: Setting linknames here is a bad hack.
7888
	_LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
7889
	# The linker will automatically build a .lib file if we build a DLL.
7890
	_LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
7891
	# FIXME: Should let the user specify the lib program.
7892
	_LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
7893
	_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7894
	;;
7895
      esac
1 by Daniel Holbach
Import upstream version 0.5.1
7896
      ;;
7897
7898
    darwin* | rhapsody*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7899
      _LT_DARWIN_LINKER_FEATURES($1)
1 by Daniel Holbach
Import upstream version 0.5.1
7900
      ;;
7901
7902
    dgux*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7903
      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7904
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7905
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7906
      ;;
7907
7908
    freebsd1*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7909
      _LT_TAGVAR(ld_shlibs, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7910
      ;;
7911
7912
    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
7913
    # support.  Future versions do this automatically, but an explicit c++rt0.o
7914
    # does not break anything, and helps significantly (at the cost of a little
7915
    # extra space).
7916
    freebsd2.2*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7917
      _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
7918
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7919
      _LT_TAGVAR(hardcode_direct, $1)=yes
7920
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7921
      ;;
7922
7923
    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
7924
    freebsd2*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7925
      _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
7926
      _LT_TAGVAR(hardcode_direct, $1)=yes
7927
      _LT_TAGVAR(hardcode_minus_L, $1)=yes
7928
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7929
      ;;
7930
7931
    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
7932
    freebsd* | dragonfly*)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7933
      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7934
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7935
      _LT_TAGVAR(hardcode_direct, $1)=yes
7936
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
7937
      ;;
7938
7939
    hpux9*)
7940
      if test "$GCC" = yes; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7941
	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7942
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7943
	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
7944
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7945
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7946
      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7947
      _LT_TAGVAR(hardcode_direct, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
7948
7949
      # hardcode_minus_L: Not really in the search PATH,
7950
      # but as the default location of the library.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7951
      _LT_TAGVAR(hardcode_minus_L, $1)=yes
7952
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
1 by Daniel Holbach
Import upstream version 0.5.1
7953
      ;;
7954
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7955
    hpux10*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7956
      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7957
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7958
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7959
	_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7960
      fi
7961
      if test "$with_gnu_ld" = no; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7962
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7963
	_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
7964
	_LT_TAGVAR(hardcode_libdir_separator, $1)=:
7965
	_LT_TAGVAR(hardcode_direct, $1)=yes
7966
	_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7967
	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7968
	# hardcode_minus_L: Not really in the search PATH,
7969
	# but as the default location of the library.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7970
	_LT_TAGVAR(hardcode_minus_L, $1)=yes
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7971
      fi
7972
      ;;
7973
7974
    hpux11*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7975
      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7976
	case $host_cpu in
7977
	hppa*64*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7978
	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
1 by Daniel Holbach
Import upstream version 0.5.1
7979
	  ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7980
	ia64*)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7981
	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7982
	  ;;
1 by Daniel Holbach
Import upstream version 0.5.1
7983
	*)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
7984
	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
1 by Daniel Holbach
Import upstream version 0.5.1
7985
	  ;;
7986
	esac
7987
      else
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7988
	case $host_cpu in
7989
	hppa*64*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7990
	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
7991
	  ;;
7992
	ia64*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
7993
	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
1 by Daniel Holbach
Import upstream version 0.5.1
7994
	  ;;
7995
	*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
7996
	m4_if($1, [], [
7997
	  # Older versions of the 11.00 compiler do not understand -b yet
7998
	  # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
7999
	  _LT_LINKER_OPTION([if $CC understands -b],
8000
	    _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
8001
	    [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
8002
	    [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
8003
	  [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
1 by Daniel Holbach
Import upstream version 0.5.1
8004
	  ;;
8005
	esac
8006
      fi
8007
      if test "$with_gnu_ld" = no; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8008
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
8009
	_LT_TAGVAR(hardcode_libdir_separator, $1)=:
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8010
8011
	case $host_cpu in
8012
	hppa*64*|ia64*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8013
	  _LT_TAGVAR(hardcode_direct, $1)=no
8014
	  _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8015
	  ;;
8016
	*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8017
	  _LT_TAGVAR(hardcode_direct, $1)=yes
8018
	  _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
8019
	  _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
1 by Daniel Holbach
Import upstream version 0.5.1
8020
8021
	  # hardcode_minus_L: Not really in the search PATH,
8022
	  # but as the default location of the library.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8023
	  _LT_TAGVAR(hardcode_minus_L, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
8024
	  ;;
8025
	esac
8026
      fi
8027
      ;;
8028
8029
    irix5* | irix6* | nonstopux*)
8030
      if test "$GCC" = yes; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8031
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8032
	# Try to use the -exported_symbol ld option, if it does not
8033
	# work, assume that -exports_file does not work either and
8034
	# implicitly export all symbols.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8035
	# This should be the same for all languages, so no per-tag cache variable.
8036
	AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
8037
	  [lt_cv_irix_exported_symbol],
8038
	  [save_LDFLAGS="$LDFLAGS"
8039
	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
8040
	   AC_LINK_IFELSE(
8041
	     [AC_LANG_SOURCE(
8042
	        [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
8043
			      [C++], [[int foo (void) { return 0; }]],
8044
			      [Fortran 77], [[
8045
      subroutine foo
8046
      end]],
8047
			      [Fortran], [[
8048
      subroutine foo
8049
      end]])])],
8050
	      [lt_cv_irix_exported_symbol=yes],
8051
	      [lt_cv_irix_exported_symbol=no])
8052
           LDFLAGS="$save_LDFLAGS"])
8053
	if test "$lt_cv_irix_exported_symbol" = yes; then
8054
          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
8055
	fi
1 by Daniel Holbach
Import upstream version 0.5.1
8056
      else
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8057
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
8058
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
8059
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8060
      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
8061
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8062
      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
8063
      _LT_TAGVAR(inherit_rpath, $1)=yes
8064
      _LT_TAGVAR(link_all_deplibs, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
8065
      ;;
8066
1.1.2 by Daniel Holbach
Import upstream version 0.7.0
8067
    netbsd*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8068
      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
8069
	_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
1 by Daniel Holbach
Import upstream version 0.5.1
8070
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8071
	_LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
1 by Daniel Holbach
Import upstream version 0.5.1
8072
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8073
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
8074
      _LT_TAGVAR(hardcode_direct, $1)=yes
8075
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8076
      ;;
8077
8078
    newsos6)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8079
      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8080
      _LT_TAGVAR(hardcode_direct, $1)=yes
8081
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8082
      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
8083
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8084
      ;;
8085
8086
    *nto* | *qnx*)
1 by Daniel Holbach
Import upstream version 0.5.1
8087
      ;;
8088
8089
    openbsd*)
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8090
      if test -f /usr/libexec/ld.so; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8091
	_LT_TAGVAR(hardcode_direct, $1)=yes
8092
	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8093
	_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
8094
	if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8095
	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8096
	  _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
8097
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
8098
	  _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8099
	else
8100
	  case $host_os in
8101
	   openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8102
	     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8103
	     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8104
	     ;;
8105
	   *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8106
	     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8107
	     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8108
	     ;;
8109
	  esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8110
	fi
1 by Daniel Holbach
Import upstream version 0.5.1
8111
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8112
	_LT_TAGVAR(ld_shlibs, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8113
      fi
8114
      ;;
8115
8116
    os2*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8117
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
8118
      _LT_TAGVAR(hardcode_minus_L, $1)=yes
8119
      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8120
      _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8121
      _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
1 by Daniel Holbach
Import upstream version 0.5.1
8122
      ;;
8123
8124
    osf3*)
8125
      if test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8126
	_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8127
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
8128
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8129
	_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8130
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
1 by Daniel Holbach
Import upstream version 0.5.1
8131
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8132
      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
8133
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8134
      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
1 by Daniel Holbach
Import upstream version 0.5.1
8135
      ;;
8136
8137
    osf4* | osf5*)	# as osf3* with the addition of -msym flag
8138
      if test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8139
	_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8140
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8141
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
1 by Daniel Holbach
Import upstream version 0.5.1
8142
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8143
	_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8144
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8145
	_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8146
	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
1 by Daniel Holbach
Import upstream version 0.5.1
8147
8148
	# Both c and cxx compiler support -rpath directly
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8149
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
1 by Daniel Holbach
Import upstream version 0.5.1
8150
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8151
      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
8152
      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
1 by Daniel Holbach
Import upstream version 0.5.1
8153
      ;;
8154
8155
    solaris*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8156
      _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
1 by Daniel Holbach
Import upstream version 0.5.1
8157
      if test "$GCC" = yes; then
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8158
	wlarc='${wl}'
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8159
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8160
	_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8161
	  $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
1 by Daniel Holbach
Import upstream version 0.5.1
8162
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8163
	case `$CC -V 2>&1` in
8164
	*"Compilers 5.0"*)
8165
	  wlarc=''
8166
	  _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8167
	  _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
8168
	  $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
8169
	  ;;
8170
	*)
8171
	  wlarc='${wl}'
8172
	  _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
8173
	  _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
8174
	  $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
8175
	  ;;
8176
	esac
1 by Daniel Holbach
Import upstream version 0.5.1
8177
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8178
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
8179
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8180
      case $host_os in
8181
      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8182
      *)
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8183
	# The compiler driver will combine and reorder linker options,
8184
	# but understands `-z linker_flag'.  GCC discards it without `$wl',
8185
	# but is careful enough not to reorder.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8186
	# Supported since Solaris 2.6 (maybe 2.5.1?)
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8187
	if test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8188
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8189
	else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8190
	  _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8191
	fi
8192
	;;
1 by Daniel Holbach
Import upstream version 0.5.1
8193
      esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8194
      _LT_TAGVAR(link_all_deplibs, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
8195
      ;;
8196
8197
    sunos4*)
8198
      if test "x$host_vendor" = xsequent; then
8199
	# Use $CC to link under sequent, because it throws in some extra .o
8200
	# files that make .init and .fini sections work.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8201
	_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
1 by Daniel Holbach
Import upstream version 0.5.1
8202
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8203
	_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
1 by Daniel Holbach
Import upstream version 0.5.1
8204
      fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8205
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
8206
      _LT_TAGVAR(hardcode_direct, $1)=yes
8207
      _LT_TAGVAR(hardcode_minus_L, $1)=yes
8208
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8209
      ;;
8210
8211
    sysv4)
8212
      case $host_vendor in
8213
	sni)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8214
	  _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8215
	  _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
1 by Daniel Holbach
Import upstream version 0.5.1
8216
	;;
8217
	siemens)
8218
	  ## LD is ld it makes a PLAMLIB
8219
	  ## CC just makes a GrossModule.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8220
	  _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8221
	  _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
8222
	  _LT_TAGVAR(hardcode_direct, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8223
        ;;
8224
	motorola)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8225
	  _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8226
	  _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
1 by Daniel Holbach
Import upstream version 0.5.1
8227
	;;
8228
      esac
8229
      runpath_var='LD_RUN_PATH'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8230
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8231
      ;;
8232
8233
    sysv4.3*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8234
      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8235
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8236
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
1 by Daniel Holbach
Import upstream version 0.5.1
8237
      ;;
8238
8239
    sysv4*MP*)
8240
      if test -d /usr/nec; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8241
	_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8242
	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8243
	runpath_var=LD_RUN_PATH
8244
	hardcode_runpath_var=yes
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8245
	_LT_TAGVAR(ld_shlibs, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
8246
      fi
8247
      ;;
8248
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
8249
    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8250
      _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
8251
      _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8252
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8253
      runpath_var='LD_RUN_PATH'
8254
8255
      if test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8256
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8257
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8258
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8259
	_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8260
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8261
      fi
8262
      ;;
8263
8264
    sysv5* | sco3.2v5* | sco5v6*)
8265
      # Note: We can NOT use -z defs as we might desire, because we do not
8266
      # link with -lc, and that would cause any symbols used from libc to
8267
      # always be unresolved, which means just about no library would
8268
      # ever link correctly.  If we're not using GNU ld we use -z text
8269
      # though, which does catch some bad symbols but isn't as heavy-handed
8270
      # as -z defs.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8271
      _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
8272
      _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
8273
      _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8274
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8275
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
8276
      _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
8277
      _LT_TAGVAR(link_all_deplibs, $1)=yes
8278
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8279
      runpath_var='LD_RUN_PATH'
8280
8281
      if test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8282
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8283
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8284
      else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8285
	_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8286
	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
8287
      fi
1 by Daniel Holbach
Import upstream version 0.5.1
8288
      ;;
8289
8290
    uts4*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8291
      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8292
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
8293
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8294
      ;;
8295
8296
    *)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8297
      _LT_TAGVAR(ld_shlibs, $1)=no
1 by Daniel Holbach
Import upstream version 0.5.1
8298
      ;;
8299
    esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8300
8301
    if test x$host_vendor = xsni; then
8302
      case $host in
8303
      sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
8304
	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
8305
	;;
8306
      esac
8307
    fi
1 by Daniel Holbach
Import upstream version 0.5.1
8308
  fi
8309
])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8310
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
8311
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
8312
8313
_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
8314
8315
_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
8316
_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
8317
_LT_DECL([], [extract_expsyms_cmds], [2],
8318
    [The commands to extract the exported symbol list from a shared archive])
1 by Daniel Holbach
Import upstream version 0.5.1
8319
8320
#
8321
# Do we need to explicitly link libc?
8322
#
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8323
case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
1 by Daniel Holbach
Import upstream version 0.5.1
8324
x|xyes)
8325
  # Assume -lc should be added
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8326
  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
1 by Daniel Holbach
Import upstream version 0.5.1
8327
8328
  if test "$enable_shared" = yes && test "$GCC" = yes; then
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8329
    case $_LT_TAGVAR(archive_cmds, $1) in
1 by Daniel Holbach
Import upstream version 0.5.1
8330
    *'~'*)
8331
      # FIXME: we may have to deal with multi-command sequences.
8332
      ;;
8333
    '$CC '*)
8334
      # Test whether the compiler implicitly links with -lc since on some
8335
      # systems, -lgcc has to come before -lc. If gcc already passes -lc
8336
      # to ld, don't add -lc before -lgcc.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8337
      AC_CACHE_CHECK([whether -lc should be explicitly linked in],
8338
	[lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
8339
	[$RM conftest*
8340
	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1 by Daniel Holbach
Import upstream version 0.5.1
8341
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8342
	if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
8343
	  soname=conftest
8344
	  lib=conftest
8345
	  libobjs=conftest.$ac_objext
8346
	  deplibs=
8347
	  wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
8348
	  pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
8349
	  compiler_flags=-v
8350
	  linker_flags=-v
8351
	  verstring=
8352
	  output_objdir=.
8353
	  libname=conftest
8354
	  lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
8355
	  _LT_TAGVAR(allow_undefined_flag, $1)=
8356
	  if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
8357
	  then
8358
	    lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
8359
	  else
8360
	    lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
8361
	  fi
8362
	  _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
8363
	else
8364
	  cat conftest.err 1>&5
8365
	fi
8366
	$RM conftest*
8367
	])
8368
      _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
1 by Daniel Holbach
Import upstream version 0.5.1
8369
      ;;
8370
    esac
8371
  fi
8372
  ;;
8373
esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8374
8375
_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
8376
    [Whether or not to add -lc for building shared libraries])
8377
_LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
8378
    [enable_shared_with_static_runtimes], [0],
8379
    [Whether or not to disallow shared libs when runtime libs are static])
8380
_LT_TAGDECL([], [export_dynamic_flag_spec], [1],
8381
    [Compiler flag to allow reflexive dlopens])
8382
_LT_TAGDECL([], [whole_archive_flag_spec], [1],
8383
    [Compiler flag to generate shared objects directly from archives])
8384
_LT_TAGDECL([], [compiler_needs_object], [1],
8385
    [Whether the compiler copes with passing no objects directly])
8386
_LT_TAGDECL([], [old_archive_from_new_cmds], [2],
8387
    [Create an old-style archive from a shared archive])
8388
_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
8389
    [Create a temporary old-style archive to link instead of a shared archive])
8390
_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
8391
_LT_TAGDECL([], [archive_expsym_cmds], [2])
8392
_LT_TAGDECL([], [module_cmds], [2],
8393
    [Commands used to build a loadable module if different from building
8394
    a shared archive.])
8395
_LT_TAGDECL([], [module_expsym_cmds], [2])
8396
_LT_TAGDECL([], [with_gnu_ld], [1],
8397
    [Whether we are building with GNU ld or not])
8398
_LT_TAGDECL([], [allow_undefined_flag], [1],
8399
    [Flag that allows shared libraries with undefined symbols to be built])
8400
_LT_TAGDECL([], [no_undefined_flag], [1],
8401
    [Flag that enforces no undefined symbols])
8402
_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
8403
    [Flag to hardcode $libdir into a binary during linking.
8404
    This must work even if $libdir does not exist])
8405
_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
8406
    [[If ld is used when linking, flag to hardcode $libdir into a binary
8407
    during linking.  This must work even if $libdir does not exist]])
8408
_LT_TAGDECL([], [hardcode_libdir_separator], [1],
8409
    [Whether we need a single "-rpath" flag with a separated argument])
8410
_LT_TAGDECL([], [hardcode_direct], [0],
8411
    [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
8412
    DIR into the resulting binary])
8413
_LT_TAGDECL([], [hardcode_direct_absolute], [0],
8414
    [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
8415
    DIR into the resulting binary and the resulting library dependency is
8416
    "absolute", i.e impossible to change by setting ${shlibpath_var} if the
8417
    library is relocated])
8418
_LT_TAGDECL([], [hardcode_minus_L], [0],
8419
    [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
8420
    into the resulting binary])
8421
_LT_TAGDECL([], [hardcode_shlibpath_var], [0],
8422
    [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
8423
    into the resulting binary])
8424
_LT_TAGDECL([], [hardcode_automatic], [0],
8425
    [Set to "yes" if building a shared library automatically hardcodes DIR
8426
    into the library and all subsequent libraries and executables linked
8427
    against it])
8428
_LT_TAGDECL([], [inherit_rpath], [0],
8429
    [Set to yes if linker adds runtime paths of dependent libraries
8430
    to runtime path list])
8431
_LT_TAGDECL([], [link_all_deplibs], [0],
8432
    [Whether libtool must link a program against all its dependency libraries])
8433
_LT_TAGDECL([], [always_export_symbols], [0],
8434
    [Set to "yes" if exported symbols are required])
8435
_LT_TAGDECL([], [export_symbols_cmds], [2],
8436
    [The commands to list exported symbols])
8437
_LT_TAGDECL([], [exclude_expsyms], [1],
8438
    [Symbols that should not be listed in the preloaded symbols])
8439
_LT_TAGDECL([], [include_expsyms], [1],
8440
    [Symbols that must always be exported])
8441
_LT_TAGDECL([], [prelink_cmds], [2],
8442
    [Commands necessary for linking programs (against libraries) with templates])
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8443
_LT_TAGDECL([], [postlink_cmds], [2],
8444
    [Commands necessary for finishing linking programs])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8445
_LT_TAGDECL([], [file_list_spec], [1],
8446
    [Specify filename containing input files])
8447
dnl FIXME: Not yet implemented
8448
dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
8449
dnl    [Compiler flag to generate thread safe objects])
8450
])# _LT_LINKER_SHLIBS
8451
8452
8453
# _LT_LANG_C_CONFIG([TAG])
8454
# ------------------------
8455
# Ensure that the configuration variables for a C compiler are suitably
8456
# defined.  These variables are subsequently used by _LT_CONFIG to write
8457
# the compiler configuration to `libtool'.
8458
m4_defun([_LT_LANG_C_CONFIG],
8459
[m4_require([_LT_DECL_EGREP])dnl
8460
lt_save_CC="$CC"
8461
AC_LANG_PUSH(C)
8462
8463
# Source file extension for C test sources.
8464
ac_ext=c
8465
8466
# Object file extension for compiled C test sources.
8467
objext=o
8468
_LT_TAGVAR(objext, $1)=$objext
8469
8470
# Code to be used in simple compile tests
8471
lt_simple_compile_test_code="int some_variable = 0;"
8472
8473
# Code to be used in simple link tests
8474
lt_simple_link_test_code='int main(){return(0);}'
8475
8476
_LT_TAG_COMPILER
8477
# Save the default compiler, since it gets overwritten when the other
8478
# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
8479
compiler_DEFAULT=$CC
8480
8481
# save warnings/boilerplate of simple test code
8482
_LT_COMPILER_BOILERPLATE
8483
_LT_LINKER_BOILERPLATE
8484
8485
if test -n "$compiler"; then
8486
  _LT_COMPILER_NO_RTTI($1)
8487
  _LT_COMPILER_PIC($1)
8488
  _LT_COMPILER_C_O($1)
8489
  _LT_COMPILER_FILE_LOCKS($1)
8490
  _LT_LINKER_SHLIBS($1)
8491
  _LT_SYS_DYNAMIC_LINKER($1)
8492
  _LT_LINKER_HARDCODE_LIBPATH($1)
8493
  LT_SYS_DLOPEN_SELF
8494
  _LT_CMD_STRIPLIB
8495
8496
  # Report which library types will actually be built
8497
  AC_MSG_CHECKING([if libtool supports shared libraries])
8498
  AC_MSG_RESULT([$can_build_shared])
8499
8500
  AC_MSG_CHECKING([whether to build shared libraries])
8501
  test "$can_build_shared" = "no" && enable_shared=no
8502
8503
  # On AIX, shared libraries and static libraries use the same namespace, and
8504
  # are all built from PIC.
8505
  case $host_os in
8506
  aix3*)
8507
    test "$enable_shared" = yes && enable_static=no
8508
    if test -n "$RANLIB"; then
8509
      archive_cmds="$archive_cmds~\$RANLIB \$lib"
8510
      postinstall_cmds='$RANLIB $lib'
8511
    fi
8512
    ;;
8513
8514
  aix[[4-9]]*)
8515
    if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8516
      test "$enable_shared" = yes && enable_static=no
8517
    fi
8518
    ;;
8519
  esac
8520
  AC_MSG_RESULT([$enable_shared])
8521
8522
  AC_MSG_CHECKING([whether to build static libraries])
8523
  # Make sure either enable_shared or enable_static is yes.
8524
  test "$enable_shared" = yes || enable_static=yes
8525
  AC_MSG_RESULT([$enable_static])
8526
8527
  _LT_CONFIG($1)
8528
fi
8529
AC_LANG_POP
8530
CC="$lt_save_CC"
8531
])# _LT_LANG_C_CONFIG
8532
8533
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8534
# _LT_LANG_CXX_CONFIG([TAG])
8535
# --------------------------
8536
# Ensure that the configuration variables for a C++ compiler are suitably
8537
# defined.  These variables are subsequently used by _LT_CONFIG to write
8538
# the compiler configuration to `libtool'.
8539
m4_defun([_LT_LANG_CXX_CONFIG],
8540
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
8541
m4_require([_LT_DECL_EGREP])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8542
m4_require([_LT_PATH_MANIFEST_TOOL])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8543
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
8544
    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
8545
    (test "X$CXX" != "Xg++"))) ; then
8546
  AC_PROG_CXXCPP
8547
else
8548
  _lt_caught_CXX_error=yes
8549
fi
8550
8551
AC_LANG_PUSH(C++)
8552
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
8553
_LT_TAGVAR(allow_undefined_flag, $1)=
8554
_LT_TAGVAR(always_export_symbols, $1)=no
8555
_LT_TAGVAR(archive_expsym_cmds, $1)=
8556
_LT_TAGVAR(compiler_needs_object, $1)=no
8557
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
8558
_LT_TAGVAR(hardcode_direct, $1)=no
8559
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
8560
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8561
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
8562
_LT_TAGVAR(hardcode_libdir_separator, $1)=
8563
_LT_TAGVAR(hardcode_minus_L, $1)=no
8564
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
8565
_LT_TAGVAR(hardcode_automatic, $1)=no
8566
_LT_TAGVAR(inherit_rpath, $1)=no
8567
_LT_TAGVAR(module_cmds, $1)=
8568
_LT_TAGVAR(module_expsym_cmds, $1)=
8569
_LT_TAGVAR(link_all_deplibs, $1)=unknown
8570
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8571
_LT_TAGVAR(reload_flag, $1)=$reload_flag
8572
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8573
_LT_TAGVAR(no_undefined_flag, $1)=
8574
_LT_TAGVAR(whole_archive_flag_spec, $1)=
8575
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8576
8577
# Source file extension for C++ test sources.
8578
ac_ext=cpp
8579
8580
# Object file extension for compiled C++ test sources.
8581
objext=o
8582
_LT_TAGVAR(objext, $1)=$objext
8583
8584
# No sense in running all these tests if we already determined that
8585
# the CXX compiler isn't working.  Some variables (like enable_shared)
8586
# are currently assumed to apply to all compilers on this platform,
8587
# and will be corrupted by setting them based on a non-working compiler.
8588
if test "$_lt_caught_CXX_error" != yes; then
8589
  # Code to be used in simple compile tests
8590
  lt_simple_compile_test_code="int some_variable = 0;"
8591
8592
  # Code to be used in simple link tests
8593
  lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
8594
8595
  # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8596
  _LT_TAG_COMPILER
8597
8598
  # save warnings/boilerplate of simple test code
8599
  _LT_COMPILER_BOILERPLATE
8600
  _LT_LINKER_BOILERPLATE
8601
8602
  # Allow CC to be a program name with arguments.
8603
  lt_save_CC=$CC
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8604
  lt_save_CFLAGS=$CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8605
  lt_save_LD=$LD
8606
  lt_save_GCC=$GCC
8607
  GCC=$GXX
8608
  lt_save_with_gnu_ld=$with_gnu_ld
8609
  lt_save_path_LD=$lt_cv_path_LD
8610
  if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
8611
    lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
8612
  else
8613
    $as_unset lt_cv_prog_gnu_ld
8614
  fi
8615
  if test -n "${lt_cv_path_LDCXX+set}"; then
8616
    lt_cv_path_LD=$lt_cv_path_LDCXX
8617
  else
8618
    $as_unset lt_cv_path_LD
8619
  fi
8620
  test -z "${LDCXX+set}" || LD=$LDCXX
8621
  CC=${CXX-"c++"}
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8622
  CFLAGS=$CXXFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8623
  compiler=$CC
8624
  _LT_TAGVAR(compiler, $1)=$CC
8625
  _LT_CC_BASENAME([$compiler])
8626
8627
  if test -n "$compiler"; then
8628
    # We don't want -fno-exception when compiling C++ code, so set the
8629
    # no_builtin_flag separately
8630
    if test "$GXX" = yes; then
8631
      _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
8632
    else
8633
      _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
8634
    fi
8635
8636
    if test "$GXX" = yes; then
8637
      # Set up default GNU C++ configuration
8638
8639
      LT_PATH_LD
8640
8641
      # Check if GNU C++ uses GNU ld as the underlying linker, since the
8642
      # archiving commands below assume that GNU ld is being used.
8643
      if test "$with_gnu_ld" = yes; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8644
        _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
8645
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8646
8647
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8648
        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
8649
8650
        # If archive_cmds runs LD, not CC, wlarc should be empty
8651
        # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
8652
        #     investigate it a little bit more. (MM)
8653
        wlarc='${wl}'
8654
8655
        # ancient GNU ld didn't support --whole-archive et. al.
8656
        if eval "`$CC -print-prog-name=ld` --help 2>&1" |
8657
	  $GREP 'no-whole-archive' > /dev/null; then
8658
          _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8659
        else
8660
          _LT_TAGVAR(whole_archive_flag_spec, $1)=
8661
        fi
8662
      else
8663
        with_gnu_ld=no
8664
        wlarc=
8665
8666
        # A generic and very simple default shared library creation
8667
        # command for GNU C++ for the case where it uses the native
8668
        # linker, instead of GNU ld.  If possible, this setting should
8669
        # overridden to take advantage of the native linker features on
8670
        # the platform it is being used on.
8671
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
8672
      fi
8673
8674
      # Commands to make compiler produce verbose output that lists
8675
      # what "hidden" libraries, object files and flags are used when
8676
      # linking a shared library.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8677
      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8678
8679
    else
8680
      GXX=no
8681
      with_gnu_ld=no
8682
      wlarc=
8683
    fi
8684
8685
    # PORTME: fill in a description of your system's C++ link characteristics
8686
    AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
8687
    _LT_TAGVAR(ld_shlibs, $1)=yes
8688
    case $host_os in
8689
      aix3*)
8690
        # FIXME: insert proper C++ library support
8691
        _LT_TAGVAR(ld_shlibs, $1)=no
8692
        ;;
8693
      aix[[4-9]]*)
8694
        if test "$host_cpu" = ia64; then
8695
          # On IA64, the linker does run time linking by default, so we don't
8696
          # have to do anything special.
8697
          aix_use_runtimelinking=no
8698
          exp_sym_flag='-Bexport'
8699
          no_entry_flag=""
8700
        else
8701
          aix_use_runtimelinking=no
8702
8703
          # Test if we are trying to use run time linking or normal
8704
          # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8705
          # need to do runtime linking.
8706
          case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
8707
	    for ld_flag in $LDFLAGS; do
8708
	      case $ld_flag in
8709
	      *-brtl*)
8710
	        aix_use_runtimelinking=yes
8711
	        break
8712
	        ;;
8713
	      esac
8714
	    done
8715
	    ;;
8716
          esac
8717
8718
          exp_sym_flag='-bexport'
8719
          no_entry_flag='-bnoentry'
8720
        fi
8721
8722
        # When large executables or shared objects are built, AIX ld can
8723
        # have problems creating the table of contents.  If linking a library
8724
        # or program results in "error TOC overflow" add -mminimal-toc to
8725
        # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8726
        # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8727
8728
        _LT_TAGVAR(archive_cmds, $1)=''
8729
        _LT_TAGVAR(hardcode_direct, $1)=yes
8730
        _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
8731
        _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
8732
        _LT_TAGVAR(link_all_deplibs, $1)=yes
8733
        _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
8734
8735
        if test "$GXX" = yes; then
8736
          case $host_os in aix4.[[012]]|aix4.[[012]].*)
8737
          # We only want to do this on AIX 4.2 and lower, the check
8738
          # below for broken collect2 doesn't work under 4.3+
8739
	  collect2name=`${CC} -print-prog-name=collect2`
8740
	  if test -f "$collect2name" &&
8741
	     strings "$collect2name" | $GREP resolve_lib_name >/dev/null
8742
	  then
8743
	    # We have reworked collect2
8744
	    :
8745
	  else
8746
	    # We have old collect2
8747
	    _LT_TAGVAR(hardcode_direct, $1)=unsupported
8748
	    # It fails to find uninstalled libraries when the uninstalled
8749
	    # path is not listed in the libpath.  Setting hardcode_minus_L
8750
	    # to unsupported forces relinking
8751
	    _LT_TAGVAR(hardcode_minus_L, $1)=yes
8752
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
8753
	    _LT_TAGVAR(hardcode_libdir_separator, $1)=
8754
	  fi
8755
          esac
8756
          shared_flag='-shared'
8757
	  if test "$aix_use_runtimelinking" = yes; then
8758
	    shared_flag="$shared_flag "'${wl}-G'
8759
	  fi
8760
        else
8761
          # not using gcc
8762
          if test "$host_cpu" = ia64; then
8763
	  # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8764
	  # chokes on -Wl,-G. The following line is correct:
8765
	  shared_flag='-G'
8766
          else
8767
	    if test "$aix_use_runtimelinking" = yes; then
8768
	      shared_flag='${wl}-G'
8769
	    else
8770
	      shared_flag='${wl}-bM:SRE'
8771
	    fi
8772
          fi
8773
        fi
8774
8775
        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
8776
        # It seems that -bexpall does not export symbols beginning with
8777
        # underscore (_), so it is better to generate a list of symbols to
8778
	# export.
8779
        _LT_TAGVAR(always_export_symbols, $1)=yes
8780
        if test "$aix_use_runtimelinking" = yes; then
8781
          # Warning - without using the other runtime loading flags (-brtl),
8782
          # -berok will link without error, but may produce a broken library.
8783
          _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
8784
          # Determine the default libpath from the value encoded in an empty
8785
          # executable.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8786
          _LT_SYS_MODULE_PATH_AIX([$1])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8787
          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
8788
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8789
          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8790
        else
8791
          if test "$host_cpu" = ia64; then
8792
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
8793
	    _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
8794
	    _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
8795
          else
8796
	    # Determine the default libpath from the value encoded in an
8797
	    # empty executable.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8798
	    _LT_SYS_MODULE_PATH_AIX([$1])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8799
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
8800
	    # Warning - without using the other run time loading flags,
8801
	    # -berok will link without error, but may produce a broken library.
8802
	    _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
8803
	    _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8804
	    if test "$with_gnu_ld" = yes; then
8805
	      # We only use this code for GNU lds that support --whole-archive.
8806
	      _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
8807
	    else
8808
	      # Exported symbols can be pulled into shared objects from archives
8809
	      _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
8810
	    fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8811
	    _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
8812
	    # This is similar to how AIX traditionally builds its shared
8813
	    # libraries.
8814
	    _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
8815
          fi
8816
        fi
8817
        ;;
8818
8819
      beos*)
8820
	if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8821
	  _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
8822
	  # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8823
	  # support --undefined.  This deserves some investigation.  FIXME
8824
	  _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8825
	else
8826
	  _LT_TAGVAR(ld_shlibs, $1)=no
8827
	fi
8828
	;;
8829
8830
      chorus*)
8831
        case $cc_basename in
8832
          *)
8833
	  # FIXME: insert proper C++ library support
8834
	  _LT_TAGVAR(ld_shlibs, $1)=no
8835
	  ;;
8836
        esac
8837
        ;;
8838
8839
      cygwin* | mingw* | pw32* | cegcc*)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8840
	case $GXX,$cc_basename in
8841
	,cl* | no,cl*)
8842
	  # Native MSVC
8843
	  # hardcode_libdir_flag_spec is actually meaningless, as there is
8844
	  # no search path for DLLs.
8845
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
8846
	  _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
8847
	  _LT_TAGVAR(always_export_symbols, $1)=yes
8848
	  _LT_TAGVAR(file_list_spec, $1)='@'
8849
	  # Tell ltmain to make .lib files, not .a files.
8850
	  libext=lib
8851
	  # Tell ltmain to make .dll files, not .so files.
8852
	  shrext_cmds=".dll"
8853
	  # FIXME: Setting linknames here is a bad hack.
8854
	  _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
8855
	  _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8856
	      $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
8857
	    else
8858
	      $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
8859
	    fi~
8860
	    $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
8861
	    linknames='
8862
	  # The linker will not automatically build a static lib if we build a DLL.
8863
	  # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
8864
	  _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
8865
	  # Don't use ranlib
8866
	  _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
8867
	  _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
8868
	    lt_tool_outputfile="@TOOL_OUTPUT@"~
8869
	    case $lt_outputfile in
8870
	      *.exe|*.EXE) ;;
8871
	      *)
8872
		lt_outputfile="$lt_outputfile.exe"
8873
		lt_tool_outputfile="$lt_tool_outputfile.exe"
8874
		;;
8875
	    esac~
8876
	    func_to_tool_file "$lt_outputfile"~
8877
	    if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
8878
	      $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
8879
	      $RM "$lt_outputfile.manifest";
8880
	    fi'
8881
	  ;;
8882
	*)
8883
	  # g++
8884
	  # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
8885
	  # as there is no search path for DLLs.
8886
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
8887
	  _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
8888
	  _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
8889
	  _LT_TAGVAR(always_export_symbols, $1)=no
8890
	  _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8891
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8892
	  if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
8893
	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
8894
	    # If the export-symbols file already is a .def file (1st line
8895
	    # is EXPORTS), use it as is; otherwise, prepend...
8896
	    _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8897
	      cp $export_symbols $output_objdir/$soname.def;
8898
	    else
8899
	      echo EXPORTS > $output_objdir/$soname.def;
8900
	      cat $export_symbols >> $output_objdir/$soname.def;
8901
	    fi~
8902
	    $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
8903
	  else
8904
	    _LT_TAGVAR(ld_shlibs, $1)=no
8905
	  fi
8906
	  ;;
8907
	esac
8908
	;;
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8909
      darwin* | rhapsody*)
8910
        _LT_DARWIN_LINKER_FEATURES($1)
8911
	;;
8912
8913
      dgux*)
8914
        case $cc_basename in
8915
          ec++*)
8916
	    # FIXME: insert proper C++ library support
8917
	    _LT_TAGVAR(ld_shlibs, $1)=no
8918
	    ;;
8919
          ghcx*)
8920
	    # Green Hills C++ Compiler
8921
	    # FIXME: insert proper C++ library support
8922
	    _LT_TAGVAR(ld_shlibs, $1)=no
8923
	    ;;
8924
          *)
8925
	    # FIXME: insert proper C++ library support
8926
	    _LT_TAGVAR(ld_shlibs, $1)=no
8927
	    ;;
8928
        esac
8929
        ;;
8930
8931
      freebsd[[12]]*)
8932
        # C++ shared libraries reported to be fairly broken before
8933
	# switch to ELF
8934
        _LT_TAGVAR(ld_shlibs, $1)=no
8935
        ;;
8936
8937
      freebsd-elf*)
8938
        _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8939
        ;;
8940
8941
      freebsd* | dragonfly*)
8942
        # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
8943
        # conventions
8944
        _LT_TAGVAR(ld_shlibs, $1)=yes
8945
        ;;
8946
8947
      gnu*)
8948
        ;;
8949
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8950
      haiku*)
8951
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8952
        _LT_TAGVAR(link_all_deplibs, $1)=yes
8953
        ;;
8954
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8955
      hpux9*)
8956
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
8957
        _LT_TAGVAR(hardcode_libdir_separator, $1)=:
8958
        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
8959
        _LT_TAGVAR(hardcode_direct, $1)=yes
8960
        _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
8961
				             # but as the default
8962
				             # location of the library.
8963
8964
        case $cc_basename in
8965
          CC*)
8966
            # FIXME: insert proper C++ library support
8967
            _LT_TAGVAR(ld_shlibs, $1)=no
8968
            ;;
8969
          aCC*)
8970
            _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
8971
            # Commands to make compiler produce verbose output that lists
8972
            # what "hidden" libraries, object files and flags are used when
8973
            # linking a shared library.
8974
            #
8975
            # There doesn't appear to be a way to prevent this compiler from
8976
            # explicitly linking system object files so we need to strip them
8977
            # from the output so that they don't get included in the library
8978
            # dependencies.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
8979
            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8980
            ;;
8981
          *)
8982
            if test "$GXX" = yes; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
8983
              _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
8984
            else
8985
              # FIXME: insert proper C++ library support
8986
              _LT_TAGVAR(ld_shlibs, $1)=no
8987
            fi
8988
            ;;
8989
        esac
8990
        ;;
8991
8992
      hpux10*|hpux11*)
8993
        if test $with_gnu_ld = no; then
8994
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
8995
	  _LT_TAGVAR(hardcode_libdir_separator, $1)=:
8996
8997
          case $host_cpu in
8998
            hppa*64*|ia64*)
8999
              ;;
9000
            *)
9001
	      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
9002
              ;;
9003
          esac
9004
        fi
9005
        case $host_cpu in
9006
          hppa*64*|ia64*)
9007
            _LT_TAGVAR(hardcode_direct, $1)=no
9008
            _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9009
            ;;
9010
          *)
9011
            _LT_TAGVAR(hardcode_direct, $1)=yes
9012
            _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
9013
            _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
9014
					         # but as the default
9015
					         # location of the library.
9016
            ;;
9017
        esac
9018
9019
        case $cc_basename in
9020
          CC*)
9021
	    # FIXME: insert proper C++ library support
9022
	    _LT_TAGVAR(ld_shlibs, $1)=no
9023
	    ;;
9024
          aCC*)
9025
	    case $host_cpu in
9026
	      hppa*64*)
9027
	        _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
9028
	        ;;
9029
	      ia64*)
9030
	        _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
9031
	        ;;
9032
	      *)
9033
	        _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
9034
	        ;;
9035
	    esac
9036
	    # Commands to make compiler produce verbose output that lists
9037
	    # what "hidden" libraries, object files and flags are used when
9038
	    # linking a shared library.
9039
	    #
9040
	    # There doesn't appear to be a way to prevent this compiler from
9041
	    # explicitly linking system object files so we need to strip them
9042
	    # from the output so that they don't get included in the library
9043
	    # dependencies.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9044
	    output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9045
	    ;;
9046
          *)
9047
	    if test "$GXX" = yes; then
9048
	      if test $with_gnu_ld = no; then
9049
	        case $host_cpu in
9050
	          hppa*64*)
9051
	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
9052
	            ;;
9053
	          ia64*)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9054
	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9055
	            ;;
9056
	          *)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9057
	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9058
	            ;;
9059
	        esac
9060
	      fi
9061
	    else
9062
	      # FIXME: insert proper C++ library support
9063
	      _LT_TAGVAR(ld_shlibs, $1)=no
9064
	    fi
9065
	    ;;
9066
        esac
9067
        ;;
9068
9069
      interix[[3-9]]*)
9070
	_LT_TAGVAR(hardcode_direct, $1)=no
9071
	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9072
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
9073
	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
9074
	# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
9075
	# Instead, shared libraries are loaded at an image base (0x10000000 by
9076
	# default) and relocated if they conflict, which is a slow very memory
9077
	# consuming and fragmenting process.  To avoid this, we pick a random,
9078
	# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
9079
	# time.  Moving up from 0x10000000 also allows more sbrk(2) space.
9080
	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
9081
	_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
9082
	;;
9083
      irix5* | irix6*)
9084
        case $cc_basename in
9085
          CC*)
9086
	    # SGI C++
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9087
	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9088
9089
	    # Archives containing C++ object files must be created using
9090
	    # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
9091
	    # necessary to make sure instantiated templates are included
9092
	    # in the archive.
9093
	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
9094
	    ;;
9095
          *)
9096
	    if test "$GXX" = yes; then
9097
	      if test "$with_gnu_ld" = no; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9098
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9099
	      else
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9100
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9101
	      fi
9102
	    fi
9103
	    _LT_TAGVAR(link_all_deplibs, $1)=yes
9104
	    ;;
9105
        esac
9106
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
9107
        _LT_TAGVAR(hardcode_libdir_separator, $1)=:
9108
        _LT_TAGVAR(inherit_rpath, $1)=yes
9109
        ;;
9110
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9111
      linux* | k*bsd*-gnu | kopensolaris*-gnu)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9112
        case $cc_basename in
9113
          KCC*)
9114
	    # Kuck and Associates, Inc. (KAI) C++ Compiler
9115
9116
	    # KCC will only create a shared library if the output file
9117
	    # ends with ".so" (or ".sl" for HP-UX), so rename the library
9118
	    # to its proper name (with version) after linking.
9119
	    _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
9120
	    _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
9121
	    # Commands to make compiler produce verbose output that lists
9122
	    # what "hidden" libraries, object files and flags are used when
9123
	    # linking a shared library.
9124
	    #
9125
	    # There doesn't appear to be a way to prevent this compiler from
9126
	    # explicitly linking system object files so we need to strip them
9127
	    # from the output so that they don't get included in the library
9128
	    # dependencies.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9129
	    output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9130
9131
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
9132
	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
9133
9134
	    # Archives containing C++ object files must be created using
9135
	    # "CC -Bstatic", where "CC" is the KAI C++ compiler.
9136
	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
9137
	    ;;
9138
	  icpc* | ecpc* )
9139
	    # Intel C++
9140
	    with_gnu_ld=yes
9141
	    # version 8.0 and above of icpc choke on multiply defined symbols
9142
	    # if we add $predep_objects and $postdep_objects, however 7.1 and
9143
	    # earlier do not add the objects themselves.
9144
	    case `$CC -V 2>&1` in
9145
	      *"Version 7."*)
9146
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
9147
		_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9148
		;;
9149
	      *)  # Version 8.0 or newer
9150
	        tmp_idyn=
9151
	        case $host_cpu in
9152
		  ia64*) tmp_idyn=' -i_dynamic';;
9153
		esac
9154
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9155
		_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9156
		;;
9157
	    esac
9158
	    _LT_TAGVAR(archive_cmds_need_lc, $1)=no
9159
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
9160
	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
9161
	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
9162
	    ;;
9163
          pgCC* | pgcpp*)
9164
            # Portland Group C++ compiler
9165
	    case `$CC -V` in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9166
	    *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9167
	      _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
9168
		rm -rf $tpldir~
9169
		$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9170
		compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9171
	      _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
9172
		rm -rf $tpldir~
9173
		$CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9174
		$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9175
		$RANLIB $oldlib'
9176
	      _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
9177
		rm -rf $tpldir~
9178
		$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9179
		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9180
	      _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
9181
		rm -rf $tpldir~
9182
		$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9183
		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9184
	      ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9185
	    *) # Version 6 and above use weak symbols
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9186
	      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
9187
	      _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
9188
	      ;;
9189
	    esac
9190
9191
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
9192
	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9193
	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9194
            ;;
9195
	  cxx*)
9196
	    # Compaq C++
9197
	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
9198
	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname  -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
9199
9200
	    runpath_var=LD_RUN_PATH
9201
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
9202
	    _LT_TAGVAR(hardcode_libdir_separator, $1)=:
9203
9204
	    # Commands to make compiler produce verbose output that lists
9205
	    # what "hidden" libraries, object files and flags are used when
9206
	    # linking a shared library.
9207
	    #
9208
	    # There doesn't appear to be a way to prevent this compiler from
9209
	    # explicitly linking system object files so we need to strip them
9210
	    # from the output so that they don't get included in the library
9211
	    # dependencies.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9212
	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9213
	    ;;
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9214
	  xl* | mpixl* | bgxl*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9215
	    # IBM XL 8.0 on PPC, with GNU ld
9216
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
9217
	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
9218
	    _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9219
	    if test "x$supports_anon_versioning" = xyes; then
9220
	      _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
9221
		cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
9222
		echo "local: *; };" >> $output_objdir/$libname.ver~
9223
		$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
9224
	    fi
9225
	    ;;
9226
	  *)
9227
	    case `$CC -V 2>&1 | sed 5q` in
9228
	    *Sun\ C*)
9229
	      # Sun C++ 5.9
9230
	      _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
9231
	      _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
9232
	      _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
9233
	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9234
	      _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9235
	      _LT_TAGVAR(compiler_needs_object, $1)=yes
9236
9237
	      # Not sure whether something based on
9238
	      # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
9239
	      # would be better.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9240
	      output_verbose_link_cmd='func_echo_all'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9241
9242
	      # Archives containing C++ object files must be created using
9243
	      # "CC -xar", where "CC" is the Sun C++ compiler.  This is
9244
	      # necessary to make sure instantiated templates are included
9245
	      # in the archive.
9246
	      _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
9247
	      ;;
9248
	    esac
9249
	    ;;
9250
	esac
9251
	;;
9252
9253
      lynxos*)
9254
        # FIXME: insert proper C++ library support
9255
	_LT_TAGVAR(ld_shlibs, $1)=no
9256
	;;
9257
9258
      m88k*)
9259
        # FIXME: insert proper C++ library support
9260
        _LT_TAGVAR(ld_shlibs, $1)=no
9261
	;;
9262
9263
      mvs*)
9264
        case $cc_basename in
9265
          cxx*)
9266
	    # FIXME: insert proper C++ library support
9267
	    _LT_TAGVAR(ld_shlibs, $1)=no
9268
	    ;;
9269
	  *)
9270
	    # FIXME: insert proper C++ library support
9271
	    _LT_TAGVAR(ld_shlibs, $1)=no
9272
	    ;;
9273
	esac
9274
	;;
9275
9276
      netbsd*)
9277
        if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
9278
	  _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
9279
	  wlarc=
9280
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
9281
	  _LT_TAGVAR(hardcode_direct, $1)=yes
9282
	  _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9283
	fi
9284
	# Workaround some broken pre-1.5 toolchains
9285
	output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
9286
	;;
9287
9288
      *nto* | *qnx*)
9289
        _LT_TAGVAR(ld_shlibs, $1)=yes
9290
	;;
9291
9292
      openbsd2*)
9293
        # C++ shared libraries are fairly broken
9294
	_LT_TAGVAR(ld_shlibs, $1)=no
9295
	;;
9296
9297
      openbsd*)
9298
	if test -f /usr/libexec/ld.so; then
9299
	  _LT_TAGVAR(hardcode_direct, $1)=yes
9300
	  _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9301
	  _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
9302
	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
9303
	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
9304
	  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9305
	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
9306
	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
9307
	    _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
9308
	  fi
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9309
	  output_verbose_link_cmd=func_echo_all
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9310
	else
9311
	  _LT_TAGVAR(ld_shlibs, $1)=no
9312
	fi
9313
	;;
9314
9315
      osf3* | osf4* | osf5*)
9316
        case $cc_basename in
9317
          KCC*)
9318
	    # Kuck and Associates, Inc. (KAI) C++ Compiler
9319
9320
	    # KCC will only create a shared library if the output file
9321
	    # ends with ".so" (or ".sl" for HP-UX), so rename the library
9322
	    # to its proper name (with version) after linking.
9323
	    _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
9324
9325
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
9326
	    _LT_TAGVAR(hardcode_libdir_separator, $1)=:
9327
9328
	    # Archives containing C++ object files must be created using
9329
	    # the KAI C++ compiler.
9330
	    case $host in
9331
	      osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
9332
	      *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
9333
	    esac
9334
	    ;;
9335
          RCC*)
9336
	    # Rational C++ 2.4.1
9337
	    # FIXME: insert proper C++ library support
9338
	    _LT_TAGVAR(ld_shlibs, $1)=no
9339
	    ;;
9340
          cxx*)
9341
	    case $host in
9342
	      osf3*)
9343
	        _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9344
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9345
	        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
9346
		;;
9347
	      *)
9348
	        _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9349
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9350
	        _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
9351
	          echo "-hidden">> $lib.exp~
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9352
	          $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp  `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9353
	          $RM $lib.exp'
9354
	        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
9355
		;;
9356
	    esac
9357
9358
	    _LT_TAGVAR(hardcode_libdir_separator, $1)=:
9359
9360
	    # Commands to make compiler produce verbose output that lists
9361
	    # what "hidden" libraries, object files and flags are used when
9362
	    # linking a shared library.
9363
	    #
9364
	    # There doesn't appear to be a way to prevent this compiler from
9365
	    # explicitly linking system object files so we need to strip them
9366
	    # from the output so that they don't get included in the library
9367
	    # dependencies.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9368
	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9369
	    ;;
9370
	  *)
9371
	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
9372
	      _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
9373
	      case $host in
9374
	        osf3*)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9375
	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9376
		  ;;
9377
	        *)
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9378
	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9379
		  ;;
9380
	      esac
9381
9382
	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
9383
	      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
9384
9385
	      # Commands to make compiler produce verbose output that lists
9386
	      # what "hidden" libraries, object files and flags are used when
9387
	      # linking a shared library.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9388
	      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9389
9390
	    else
9391
	      # FIXME: insert proper C++ library support
9392
	      _LT_TAGVAR(ld_shlibs, $1)=no
9393
	    fi
9394
	    ;;
9395
        esac
9396
        ;;
9397
9398
      psos*)
9399
        # FIXME: insert proper C++ library support
9400
        _LT_TAGVAR(ld_shlibs, $1)=no
9401
        ;;
9402
9403
      sunos4*)
9404
        case $cc_basename in
9405
          CC*)
9406
	    # Sun C++ 4.x
9407
	    # FIXME: insert proper C++ library support
9408
	    _LT_TAGVAR(ld_shlibs, $1)=no
9409
	    ;;
9410
          lcc*)
9411
	    # Lucid
9412
	    # FIXME: insert proper C++ library support
9413
	    _LT_TAGVAR(ld_shlibs, $1)=no
9414
	    ;;
9415
          *)
9416
	    # FIXME: insert proper C++ library support
9417
	    _LT_TAGVAR(ld_shlibs, $1)=no
9418
	    ;;
9419
        esac
9420
        ;;
9421
9422
      solaris*)
9423
        case $cc_basename in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9424
          CC* | sunCC*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9425
	    # Sun C++ 4.2, 5.x and Centerline C++
9426
            _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
9427
	    _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
9428
	    _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
9429
	    _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9430
	      $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
9431
9432
	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
9433
	    _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9434
	    case $host_os in
9435
	      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
9436
	      *)
9437
		# The compiler driver will combine and reorder linker options,
9438
		# but understands `-z linker_flag'.
9439
	        # Supported since Solaris 2.6 (maybe 2.5.1?)
9440
		_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
9441
	        ;;
9442
	    esac
9443
	    _LT_TAGVAR(link_all_deplibs, $1)=yes
9444
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9445
	    output_verbose_link_cmd='func_echo_all'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9446
9447
	    # Archives containing C++ object files must be created using
9448
	    # "CC -xar", where "CC" is the Sun C++ compiler.  This is
9449
	    # necessary to make sure instantiated templates are included
9450
	    # in the archive.
9451
	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
9452
	    ;;
9453
          gcx*)
9454
	    # Green Hills C++ Compiler
9455
	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
9456
9457
	    # The C++ compiler must be used to create the archive.
9458
	    _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
9459
	    ;;
9460
          *)
9461
	    # GNU C++ compiler with Solaris linker
9462
	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
9463
	      _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
9464
	      if $CC --version | $GREP -v '^2\.7' > /dev/null; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9465
	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9466
	        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9467
		  $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9468
9469
	        # Commands to make compiler produce verbose output that lists
9470
	        # what "hidden" libraries, object files and flags are used when
9471
	        # linking a shared library.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9472
	        output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9473
	      else
9474
	        # g++ 2.7 appears to require `-G' NOT `-shared' on this
9475
	        # platform.
9476
	        _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
9477
	        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9478
		  $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
9479
9480
	        # Commands to make compiler produce verbose output that lists
9481
	        # what "hidden" libraries, object files and flags are used when
9482
	        # linking a shared library.
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9483
	        output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9484
	      fi
9485
9486
	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
9487
	      case $host_os in
9488
		solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
9489
		*)
9490
		  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
9491
		  ;;
9492
	      esac
9493
	    fi
9494
	    ;;
9495
        esac
9496
        ;;
9497
9498
    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
9499
      _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
9500
      _LT_TAGVAR(archive_cmds_need_lc, $1)=no
9501
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9502
      runpath_var='LD_RUN_PATH'
9503
9504
      case $cc_basename in
9505
        CC*)
9506
	  _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9507
	  _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9508
	  ;;
9509
	*)
9510
	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9511
	  _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9512
	  ;;
9513
      esac
9514
      ;;
9515
9516
      sysv5* | sco3.2v5* | sco5v6*)
9517
	# Note: We can NOT use -z defs as we might desire, because we do not
9518
	# link with -lc, and that would cause any symbols used from libc to
9519
	# always be unresolved, which means just about no library would
9520
	# ever link correctly.  If we're not using GNU ld we use -z text
9521
	# though, which does catch some bad symbols but isn't as heavy-handed
9522
	# as -z defs.
9523
	_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
9524
	_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
9525
	_LT_TAGVAR(archive_cmds_need_lc, $1)=no
9526
	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
9527
	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
9528
	_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
9529
	_LT_TAGVAR(link_all_deplibs, $1)=yes
9530
	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
9531
	runpath_var='LD_RUN_PATH'
9532
9533
	case $cc_basename in
9534
          CC*)
9535
	    _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9536
	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9537
	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
9538
	      '"$_LT_TAGVAR(old_archive_cmds, $1)"
9539
	    _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
9540
	      '"$_LT_TAGVAR(reload_cmds, $1)"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9541
	    ;;
9542
	  *)
9543
	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9544
	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9545
	    ;;
9546
	esac
9547
      ;;
9548
9549
      tandem*)
9550
        case $cc_basename in
9551
          NCC*)
9552
	    # NonStop-UX NCC 3.20
9553
	    # FIXME: insert proper C++ library support
9554
	    _LT_TAGVAR(ld_shlibs, $1)=no
9555
	    ;;
9556
          *)
9557
	    # FIXME: insert proper C++ library support
9558
	    _LT_TAGVAR(ld_shlibs, $1)=no
9559
	    ;;
9560
        esac
9561
        ;;
9562
9563
      vxworks*)
9564
        # FIXME: insert proper C++ library support
9565
        _LT_TAGVAR(ld_shlibs, $1)=no
9566
        ;;
9567
9568
      *)
9569
        # FIXME: insert proper C++ library support
9570
        _LT_TAGVAR(ld_shlibs, $1)=no
9571
        ;;
9572
    esac
9573
9574
    AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
9575
    test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
9576
9577
    _LT_TAGVAR(GCC, $1)="$GXX"
9578
    _LT_TAGVAR(LD, $1)="$LD"
9579
9580
    ## CAVEAT EMPTOR:
9581
    ## There is no encapsulation within the following macros, do not change
9582
    ## the running order or otherwise move them around unless you know exactly
9583
    ## what you are doing...
9584
    _LT_SYS_HIDDEN_LIBDEPS($1)
9585
    _LT_COMPILER_PIC($1)
9586
    _LT_COMPILER_C_O($1)
9587
    _LT_COMPILER_FILE_LOCKS($1)
9588
    _LT_LINKER_SHLIBS($1)
9589
    _LT_SYS_DYNAMIC_LINKER($1)
9590
    _LT_LINKER_HARDCODE_LIBPATH($1)
9591
9592
    _LT_CONFIG($1)
9593
  fi # test -n "$compiler"
9594
9595
  CC=$lt_save_CC
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9596
  CFLAGS=$lt_save_CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9597
  LDCXX=$LD
9598
  LD=$lt_save_LD
9599
  GCC=$lt_save_GCC
9600
  with_gnu_ld=$lt_save_with_gnu_ld
9601
  lt_cv_path_LDCXX=$lt_cv_path_LD
9602
  lt_cv_path_LD=$lt_save_path_LD
9603
  lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
9604
  lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
9605
fi # test "$_lt_caught_CXX_error" != yes
9606
9607
AC_LANG_POP
9608
])# _LT_LANG_CXX_CONFIG
9609
9610
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9611
# _LT_FUNC_STRIPNAME_CNF
9612
# ----------------------
9613
# func_stripname_cnf prefix suffix name
9614
# strip PREFIX and SUFFIX off of NAME.
9615
# PREFIX and SUFFIX must not contain globbing or regex special
9616
# characters, hashes, percent signs, but SUFFIX may contain a leading
9617
# dot (in which case that matches only a dot).
9618
#
9619
# This function is identical to the (non-XSI) version of func_stripname,
9620
# except this one can be used by m4 code that may be executed by configure,
9621
# rather than the libtool script.
9622
m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
9623
AC_REQUIRE([_LT_DECL_SED])
9624
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
9625
func_stripname_cnf ()
9626
{
9627
  case ${2} in
9628
  .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
9629
  *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
9630
  esac
9631
} # func_stripname_cnf
9632
])# _LT_FUNC_STRIPNAME_CNF
9633
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9634
# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
1 by Daniel Holbach
Import upstream version 0.5.1
9635
# ---------------------------------
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9636
# Figure out "hidden" library dependencies from verbose
9637
# compiler output when linking a shared library.
9638
# Parse the compiler output and extract the necessary
9639
# objects, libraries and library flags.
9640
m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
9641
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9642
AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9643
# Dependencies to place before and after the object being linked:
9644
_LT_TAGVAR(predep_objects, $1)=
9645
_LT_TAGVAR(postdep_objects, $1)=
9646
_LT_TAGVAR(predeps, $1)=
9647
_LT_TAGVAR(postdeps, $1)=
9648
_LT_TAGVAR(compiler_lib_search_path, $1)=
9649
9650
dnl we can't use the lt_simple_compile_test_code here,
9651
dnl because it contains code intended for an executable,
9652
dnl not a library.  It's possible we should let each
9653
dnl tag define a new lt_????_link_test_code variable,
9654
dnl but it's only used here...
9655
m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
9656
int a;
9657
void foo (void) { a = 0; }
9658
_LT_EOF
9659
], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
9660
class Foo
9661
{
9662
public:
9663
  Foo (void) { a = 0; }
9664
private:
9665
  int a;
9666
};
9667
_LT_EOF
9668
], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
9669
      subroutine foo
9670
      implicit none
9671
      integer*4 a
9672
      a=0
9673
      return
9674
      end
9675
_LT_EOF
9676
], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
9677
      subroutine foo
9678
      implicit none
9679
      integer a
9680
      a=0
9681
      return
9682
      end
9683
_LT_EOF
9684
], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
9685
public class foo {
9686
  private int a;
9687
  public void bar (void) {
9688
    a = 0;
9689
  }
9690
};
9691
_LT_EOF
9692
])
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9693
9694
_lt_libdeps_save_CFLAGS=$CFLAGS
9695
case "$CC $CFLAGS " in #(
9696
*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
9697
*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
9698
esac
9699
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9700
dnl Parse the compiler output and extract the necessary
9701
dnl objects, libraries and library flags.
9702
if AC_TRY_EVAL(ac_compile); then
9703
  # Parse the compiler output and extract the necessary
9704
  # objects, libraries and library flags.
9705
9706
  # Sentinel used to keep track of whether or not we are before
9707
  # the conftest object file.
9708
  pre_test_object_deps_done=no
9709
9710
  for p in `eval "$output_verbose_link_cmd"`; do
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9711
    case ${prev}${p} in
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9712
9713
    -L* | -R* | -l*)
9714
       # Some compilers place space between "-{L,R}" and the path.
9715
       # Remove the space.
9716
       if test $p = "-L" ||
9717
          test $p = "-R"; then
9718
	 prev=$p
9719
	 continue
9720
       fi
9721
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9722
       # Expand the sysroot to ease extracting the directories later.
9723
       if test -z "$prev"; then
9724
         case $p in
9725
         -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
9726
         -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
9727
         -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
9728
         esac
9729
       fi
9730
       case $p in
9731
       =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
9732
       esac
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9733
       if test "$pre_test_object_deps_done" = no; then
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9734
	 case ${prev} in
9735
	 -L | -R)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9736
	   # Internal compiler library paths should come after those
9737
	   # provided the user.  The postdeps already come after the
9738
	   # user supplied libs so there is no need to process them.
9739
	   if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
9740
	     _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
9741
	   else
9742
	     _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
9743
	   fi
9744
	   ;;
9745
	 # The "-l" case would never come before the object being
9746
	 # linked, so don't bother handling this case.
9747
	 esac
9748
       else
9749
	 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
9750
	   _LT_TAGVAR(postdeps, $1)="${prev}${p}"
9751
	 else
9752
	   _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
9753
	 fi
9754
       fi
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9755
       prev=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9756
       ;;
9757
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9758
    *.lto.$objext) ;; # Ignore GCC LTO objects
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9759
    *.$objext)
9760
       # This assumes that the test object file only shows up
9761
       # once in the compiler output.
9762
       if test "$p" = "conftest.$objext"; then
9763
	 pre_test_object_deps_done=yes
9764
	 continue
9765
       fi
9766
9767
       if test "$pre_test_object_deps_done" = no; then
9768
	 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
9769
	   _LT_TAGVAR(predep_objects, $1)="$p"
9770
	 else
9771
	   _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
9772
	 fi
9773
       else
9774
	 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
9775
	   _LT_TAGVAR(postdep_objects, $1)="$p"
9776
	 else
9777
	   _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
9778
	 fi
9779
       fi
9780
       ;;
9781
9782
    *) ;; # Ignore the rest.
9783
9784
    esac
9785
  done
9786
9787
  # Clean up.
9788
  rm -f a.out a.exe
1.1.6 by Baptiste Mille-Mathias
Import upstream version 0.11.0
9789
else
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9790
  echo "libtool.m4: error: problem compiling $1 test program"
9791
fi
9792
9793
$RM -f confest.$objext
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9794
CFLAGS=$_lt_libdeps_save_CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9795
9796
# PORTME: override above test on systems where it is broken
9797
m4_if([$1], [CXX],
9798
[case $host_os in
9799
interix[[3-9]]*)
9800
  # Interix 3.5 installs completely hosed .la files for C++, so rather than
9801
  # hack all around it, let's just trust "g++" to DTRT.
9802
  _LT_TAGVAR(predep_objects,$1)=
9803
  _LT_TAGVAR(postdep_objects,$1)=
9804
  _LT_TAGVAR(postdeps,$1)=
9805
  ;;
9806
9807
linux*)
9808
  case `$CC -V 2>&1 | sed 5q` in
9809
  *Sun\ C*)
9810
    # Sun C++ 5.9
9811
9812
    # The more standards-conforming stlport4 library is
9813
    # incompatible with the Cstd library. Avoid specifying
9814
    # it if it's in CXXFLAGS. Ignore libCrun as
9815
    # -library=stlport4 depends on it.
9816
    case " $CXX $CXXFLAGS " in
9817
    *" -library=stlport4 "*)
9818
      solaris_use_stlport4=yes
9819
      ;;
9820
    esac
9821
9822
    if test "$solaris_use_stlport4" != yes; then
9823
      _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
9824
    fi
9825
    ;;
9826
  esac
9827
  ;;
9828
9829
solaris*)
9830
  case $cc_basename in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9831
  CC* | sunCC*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9832
    # The more standards-conforming stlport4 library is
9833
    # incompatible with the Cstd library. Avoid specifying
9834
    # it if it's in CXXFLAGS. Ignore libCrun as
9835
    # -library=stlport4 depends on it.
9836
    case " $CXX $CXXFLAGS " in
9837
    *" -library=stlport4 "*)
9838
      solaris_use_stlport4=yes
9839
      ;;
9840
    esac
9841
9842
    # Adding this requires a known-good setup of shared libraries for
9843
    # Sun compiler versions before 5.6, else PIC objects from an old
9844
    # archive will be linked into the output, leading to subtle bugs.
9845
    if test "$solaris_use_stlport4" != yes; then
9846
      _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
9847
    fi
9848
    ;;
9849
  esac
9850
  ;;
9851
esac
9852
])
9853
9854
case " $_LT_TAGVAR(postdeps, $1) " in
9855
*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
9856
esac
9857
 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
9858
if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
9859
 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
9860
fi
9861
_LT_TAGDECL([], [compiler_lib_search_dirs], [1],
9862
    [The directories searched by this compiler when creating a shared library])
9863
_LT_TAGDECL([], [predep_objects], [1],
9864
    [Dependencies to place before and after the objects being linked to
9865
    create a shared library])
9866
_LT_TAGDECL([], [postdep_objects], [1])
9867
_LT_TAGDECL([], [predeps], [1])
9868
_LT_TAGDECL([], [postdeps], [1])
9869
_LT_TAGDECL([], [compiler_lib_search_path], [1],
9870
    [The library search path used internally by the compiler when linking
9871
    a shared library])
9872
])# _LT_SYS_HIDDEN_LIBDEPS
9873
9874
9875
# _LT_LANG_F77_CONFIG([TAG])
9876
# --------------------------
9877
# Ensure that the configuration variables for a Fortran 77 compiler are
9878
# suitably defined.  These variables are subsequently used by _LT_CONFIG
9879
# to write the compiler configuration to `libtool'.
9880
m4_defun([_LT_LANG_F77_CONFIG],
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9881
[AC_LANG_PUSH(Fortran 77)
9882
if test -z "$F77" || test "X$F77" = "Xno"; then
9883
  _lt_disable_F77=yes
9884
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9885
9886
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
9887
_LT_TAGVAR(allow_undefined_flag, $1)=
9888
_LT_TAGVAR(always_export_symbols, $1)=no
9889
_LT_TAGVAR(archive_expsym_cmds, $1)=
9890
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
9891
_LT_TAGVAR(hardcode_direct, $1)=no
9892
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
9893
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
9894
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
9895
_LT_TAGVAR(hardcode_libdir_separator, $1)=
9896
_LT_TAGVAR(hardcode_minus_L, $1)=no
9897
_LT_TAGVAR(hardcode_automatic, $1)=no
9898
_LT_TAGVAR(inherit_rpath, $1)=no
9899
_LT_TAGVAR(module_cmds, $1)=
9900
_LT_TAGVAR(module_expsym_cmds, $1)=
9901
_LT_TAGVAR(link_all_deplibs, $1)=unknown
9902
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
1.1.16 by Robert Ancell
Import upstream version 2.31.6
9903
_LT_TAGVAR(reload_flag, $1)=$reload_flag
9904
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9905
_LT_TAGVAR(no_undefined_flag, $1)=
9906
_LT_TAGVAR(whole_archive_flag_spec, $1)=
9907
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
9908
9909
# Source file extension for f77 test sources.
9910
ac_ext=f
9911
9912
# Object file extension for compiled f77 test sources.
9913
objext=o
9914
_LT_TAGVAR(objext, $1)=$objext
9915
9916
# No sense in running all these tests if we already determined that
9917
# the F77 compiler isn't working.  Some variables (like enable_shared)
9918
# are currently assumed to apply to all compilers on this platform,
9919
# and will be corrupted by setting them based on a non-working compiler.
9920
if test "$_lt_disable_F77" != yes; then
9921
  # Code to be used in simple compile tests
9922
  lt_simple_compile_test_code="\
9923
      subroutine t
9924
      return
9925
      end
9926
"
9927
9928
  # Code to be used in simple link tests
9929
  lt_simple_link_test_code="\
9930
      program t
9931
      end
9932
"
9933
9934
  # ltmain only uses $CC for tagged configurations so make sure $CC is set.
9935
  _LT_TAG_COMPILER
9936
9937
  # save warnings/boilerplate of simple test code
9938
  _LT_COMPILER_BOILERPLATE
9939
  _LT_LINKER_BOILERPLATE
9940
9941
  # Allow CC to be a program name with arguments.
9942
  lt_save_CC="$CC"
9943
  lt_save_GCC=$GCC
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9944
  lt_save_CFLAGS=$CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9945
  CC=${F77-"f77"}
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
9946
  CFLAGS=$FFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
9947
  compiler=$CC
9948
  _LT_TAGVAR(compiler, $1)=$CC
9949
  _LT_CC_BASENAME([$compiler])
9950
  GCC=$G77
9951
  if test -n "$compiler"; then
9952
    AC_MSG_CHECKING([if libtool supports shared libraries])
9953
    AC_MSG_RESULT([$can_build_shared])
9954
9955
    AC_MSG_CHECKING([whether to build shared libraries])
9956
    test "$can_build_shared" = "no" && enable_shared=no
9957
9958
    # On AIX, shared libraries and static libraries use the same namespace, and
9959
    # are all built from PIC.
9960
    case $host_os in
9961
      aix3*)
9962
        test "$enable_shared" = yes && enable_static=no
9963
        if test -n "$RANLIB"; then
9964
          archive_cmds="$archive_cmds~\$RANLIB \$lib"
9965
          postinstall_cmds='$RANLIB $lib'
9966
        fi
9967
        ;;
9968
      aix[[4-9]]*)
9969
	if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
9970
	  test "$enable_shared" = yes && enable_static=no
9971
	fi
9972
        ;;
9973
    esac
9974
    AC_MSG_RESULT([$enable_shared])
9975
9976
    AC_MSG_CHECKING([whether to build static libraries])
9977
    # Make sure either enable_shared or enable_static is yes.
9978
    test "$enable_shared" = yes || enable_static=yes
9979
    AC_MSG_RESULT([$enable_static])
9980
9981
    _LT_TAGVAR(GCC, $1)="$G77"
9982
    _LT_TAGVAR(LD, $1)="$LD"
9983
9984
    ## CAVEAT EMPTOR:
9985
    ## There is no encapsulation within the following macros, do not change
9986
    ## the running order or otherwise move them around unless you know exactly
9987
    ## what you are doing...
9988
    _LT_COMPILER_PIC($1)
9989
    _LT_COMPILER_C_O($1)
9990
    _LT_COMPILER_FILE_LOCKS($1)
9991
    _LT_LINKER_SHLIBS($1)
9992
    _LT_SYS_DYNAMIC_LINKER($1)
9993
    _LT_LINKER_HARDCODE_LIBPATH($1)
9994
9995
    _LT_CONFIG($1)
9996
  fi # test -n "$compiler"
9997
9998
  GCC=$lt_save_GCC
9999
  CC="$lt_save_CC"
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10000
  CFLAGS="$lt_save_CFLAGS"
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10001
fi # test "$_lt_disable_F77" != yes
10002
10003
AC_LANG_POP
10004
])# _LT_LANG_F77_CONFIG
10005
10006
10007
# _LT_LANG_FC_CONFIG([TAG])
10008
# -------------------------
10009
# Ensure that the configuration variables for a Fortran compiler are
10010
# suitably defined.  These variables are subsequently used by _LT_CONFIG
10011
# to write the compiler configuration to `libtool'.
10012
m4_defun([_LT_LANG_FC_CONFIG],
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10013
[AC_LANG_PUSH(Fortran)
10014
10015
if test -z "$FC" || test "X$FC" = "Xno"; then
10016
  _lt_disable_FC=yes
10017
fi
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10018
10019
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
10020
_LT_TAGVAR(allow_undefined_flag, $1)=
10021
_LT_TAGVAR(always_export_symbols, $1)=no
10022
_LT_TAGVAR(archive_expsym_cmds, $1)=
10023
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
10024
_LT_TAGVAR(hardcode_direct, $1)=no
10025
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
10026
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
10027
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
10028
_LT_TAGVAR(hardcode_libdir_separator, $1)=
10029
_LT_TAGVAR(hardcode_minus_L, $1)=no
10030
_LT_TAGVAR(hardcode_automatic, $1)=no
10031
_LT_TAGVAR(inherit_rpath, $1)=no
10032
_LT_TAGVAR(module_cmds, $1)=
10033
_LT_TAGVAR(module_expsym_cmds, $1)=
10034
_LT_TAGVAR(link_all_deplibs, $1)=unknown
10035
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10036
_LT_TAGVAR(reload_flag, $1)=$reload_flag
10037
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10038
_LT_TAGVAR(no_undefined_flag, $1)=
10039
_LT_TAGVAR(whole_archive_flag_spec, $1)=
10040
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
10041
10042
# Source file extension for fc test sources.
10043
ac_ext=${ac_fc_srcext-f}
10044
10045
# Object file extension for compiled fc test sources.
10046
objext=o
10047
_LT_TAGVAR(objext, $1)=$objext
10048
10049
# No sense in running all these tests if we already determined that
10050
# the FC compiler isn't working.  Some variables (like enable_shared)
10051
# are currently assumed to apply to all compilers on this platform,
10052
# and will be corrupted by setting them based on a non-working compiler.
10053
if test "$_lt_disable_FC" != yes; then
10054
  # Code to be used in simple compile tests
10055
  lt_simple_compile_test_code="\
10056
      subroutine t
10057
      return
10058
      end
10059
"
10060
10061
  # Code to be used in simple link tests
10062
  lt_simple_link_test_code="\
10063
      program t
10064
      end
10065
"
10066
10067
  # ltmain only uses $CC for tagged configurations so make sure $CC is set.
10068
  _LT_TAG_COMPILER
10069
10070
  # save warnings/boilerplate of simple test code
10071
  _LT_COMPILER_BOILERPLATE
10072
  _LT_LINKER_BOILERPLATE
10073
10074
  # Allow CC to be a program name with arguments.
10075
  lt_save_CC="$CC"
10076
  lt_save_GCC=$GCC
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10077
  lt_save_CFLAGS=$CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10078
  CC=${FC-"f95"}
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10079
  CFLAGS=$FCFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10080
  compiler=$CC
10081
  GCC=$ac_cv_fc_compiler_gnu
10082
10083
  _LT_TAGVAR(compiler, $1)=$CC
10084
  _LT_CC_BASENAME([$compiler])
10085
10086
  if test -n "$compiler"; then
10087
    AC_MSG_CHECKING([if libtool supports shared libraries])
10088
    AC_MSG_RESULT([$can_build_shared])
10089
10090
    AC_MSG_CHECKING([whether to build shared libraries])
10091
    test "$can_build_shared" = "no" && enable_shared=no
10092
10093
    # On AIX, shared libraries and static libraries use the same namespace, and
10094
    # are all built from PIC.
10095
    case $host_os in
10096
      aix3*)
10097
        test "$enable_shared" = yes && enable_static=no
10098
        if test -n "$RANLIB"; then
10099
          archive_cmds="$archive_cmds~\$RANLIB \$lib"
10100
          postinstall_cmds='$RANLIB $lib'
10101
        fi
10102
        ;;
10103
      aix[[4-9]]*)
10104
	if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
10105
	  test "$enable_shared" = yes && enable_static=no
10106
	fi
10107
        ;;
10108
    esac
10109
    AC_MSG_RESULT([$enable_shared])
10110
10111
    AC_MSG_CHECKING([whether to build static libraries])
10112
    # Make sure either enable_shared or enable_static is yes.
10113
    test "$enable_shared" = yes || enable_static=yes
10114
    AC_MSG_RESULT([$enable_static])
10115
10116
    _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
10117
    _LT_TAGVAR(LD, $1)="$LD"
10118
10119
    ## CAVEAT EMPTOR:
10120
    ## There is no encapsulation within the following macros, do not change
10121
    ## the running order or otherwise move them around unless you know exactly
10122
    ## what you are doing...
10123
    _LT_SYS_HIDDEN_LIBDEPS($1)
10124
    _LT_COMPILER_PIC($1)
10125
    _LT_COMPILER_C_O($1)
10126
    _LT_COMPILER_FILE_LOCKS($1)
10127
    _LT_LINKER_SHLIBS($1)
10128
    _LT_SYS_DYNAMIC_LINKER($1)
10129
    _LT_LINKER_HARDCODE_LIBPATH($1)
10130
10131
    _LT_CONFIG($1)
10132
  fi # test -n "$compiler"
10133
10134
  GCC=$lt_save_GCC
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10135
  CC=$lt_save_CC
10136
  CFLAGS=$lt_save_CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10137
fi # test "$_lt_disable_FC" != yes
10138
10139
AC_LANG_POP
10140
])# _LT_LANG_FC_CONFIG
10141
10142
10143
# _LT_LANG_GCJ_CONFIG([TAG])
10144
# --------------------------
10145
# Ensure that the configuration variables for the GNU Java Compiler compiler
10146
# are suitably defined.  These variables are subsequently used by _LT_CONFIG
10147
# to write the compiler configuration to `libtool'.
10148
m4_defun([_LT_LANG_GCJ_CONFIG],
10149
[AC_REQUIRE([LT_PROG_GCJ])dnl
10150
AC_LANG_SAVE
10151
10152
# Source file extension for Java test sources.
10153
ac_ext=java
10154
10155
# Object file extension for compiled Java test sources.
10156
objext=o
10157
_LT_TAGVAR(objext, $1)=$objext
10158
10159
# Code to be used in simple compile tests
10160
lt_simple_compile_test_code="class foo {}"
10161
10162
# Code to be used in simple link tests
10163
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
10164
10165
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
10166
_LT_TAG_COMPILER
10167
10168
# save warnings/boilerplate of simple test code
10169
_LT_COMPILER_BOILERPLATE
10170
_LT_LINKER_BOILERPLATE
10171
10172
# Allow CC to be a program name with arguments.
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10173
lt_save_CC=$CC
10174
lt_save_CFLAGS=$CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10175
lt_save_GCC=$GCC
10176
GCC=yes
10177
CC=${GCJ-"gcj"}
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10178
CFLAGS=$GCJFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10179
compiler=$CC
10180
_LT_TAGVAR(compiler, $1)=$CC
10181
_LT_TAGVAR(LD, $1)="$LD"
10182
_LT_CC_BASENAME([$compiler])
10183
10184
# GCJ did not exist at the time GCC didn't implicitly link libc in.
10185
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
10186
10187
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10188
_LT_TAGVAR(reload_flag, $1)=$reload_flag
10189
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10190
10191
if test -n "$compiler"; then
10192
  _LT_COMPILER_NO_RTTI($1)
10193
  _LT_COMPILER_PIC($1)
10194
  _LT_COMPILER_C_O($1)
10195
  _LT_COMPILER_FILE_LOCKS($1)
10196
  _LT_LINKER_SHLIBS($1)
10197
  _LT_LINKER_HARDCODE_LIBPATH($1)
10198
10199
  _LT_CONFIG($1)
10200
fi
10201
10202
AC_LANG_RESTORE
10203
10204
GCC=$lt_save_GCC
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10205
CC=$lt_save_CC
10206
CFLAGS=$lt_save_CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10207
])# _LT_LANG_GCJ_CONFIG
10208
10209
10210
# _LT_LANG_RC_CONFIG([TAG])
10211
# -------------------------
10212
# Ensure that the configuration variables for the Windows resource compiler
10213
# are suitably defined.  These variables are subsequently used by _LT_CONFIG
10214
# to write the compiler configuration to `libtool'.
10215
m4_defun([_LT_LANG_RC_CONFIG],
10216
[AC_REQUIRE([LT_PROG_RC])dnl
10217
AC_LANG_SAVE
10218
10219
# Source file extension for RC test sources.
10220
ac_ext=rc
10221
10222
# Object file extension for compiled RC test sources.
10223
objext=o
10224
_LT_TAGVAR(objext, $1)=$objext
10225
10226
# Code to be used in simple compile tests
10227
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
10228
10229
# Code to be used in simple link tests
10230
lt_simple_link_test_code="$lt_simple_compile_test_code"
10231
10232
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
10233
_LT_TAG_COMPILER
10234
10235
# save warnings/boilerplate of simple test code
10236
_LT_COMPILER_BOILERPLATE
10237
_LT_LINKER_BOILERPLATE
10238
10239
# Allow CC to be a program name with arguments.
10240
lt_save_CC="$CC"
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10241
lt_save_CFLAGS=$CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10242
lt_save_GCC=$GCC
10243
GCC=
10244
CC=${RC-"windres"}
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10245
CFLAGS=
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10246
compiler=$CC
10247
_LT_TAGVAR(compiler, $1)=$CC
10248
_LT_CC_BASENAME([$compiler])
10249
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
10250
10251
if test -n "$compiler"; then
10252
  :
10253
  _LT_CONFIG($1)
10254
fi
10255
10256
GCC=$lt_save_GCC
10257
AC_LANG_RESTORE
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10258
CC=$lt_save_CC
10259
CFLAGS=$lt_save_CFLAGS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10260
])# _LT_LANG_RC_CONFIG
10261
10262
10263
# LT_PROG_GCJ
10264
# -----------
10265
AC_DEFUN([LT_PROG_GCJ],
10266
[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
10267
  [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
10268
    [AC_CHECK_TOOL(GCJ, gcj,)
10269
      test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
10270
      AC_SUBST(GCJFLAGS)])])[]dnl
10271
])
10272
10273
# Old name:
10274
AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
10275
dnl aclocal-1.4 backwards compatibility:
10276
dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
10277
10278
10279
# LT_PROG_RC
10280
# ----------
10281
AC_DEFUN([LT_PROG_RC],
10282
[AC_CHECK_TOOL(RC, windres,)
10283
])
10284
10285
# Old name:
10286
AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
10287
dnl aclocal-1.4 backwards compatibility:
10288
dnl AC_DEFUN([LT_AC_PROG_RC], [])
10289
10290
10291
# _LT_DECL_EGREP
10292
# --------------
10293
# If we don't have a new enough Autoconf to choose the best grep
10294
# available, choose the one first in the user's PATH.
10295
m4_defun([_LT_DECL_EGREP],
10296
[AC_REQUIRE([AC_PROG_EGREP])dnl
10297
AC_REQUIRE([AC_PROG_FGREP])dnl
10298
test -z "$GREP" && GREP=grep
10299
_LT_DECL([], [GREP], [1], [A grep program that handles long lines])
10300
_LT_DECL([], [EGREP], [1], [An ERE matcher])
10301
_LT_DECL([], [FGREP], [1], [A literal string matcher])
10302
dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
10303
AC_SUBST([GREP])
10304
])
10305
10306
10307
# _LT_DECL_OBJDUMP
10308
# --------------
10309
# If we don't have a new enough Autoconf to choose the best objdump
10310
# available, choose the one first in the user's PATH.
10311
m4_defun([_LT_DECL_OBJDUMP],
10312
[AC_CHECK_TOOL(OBJDUMP, objdump, false)
10313
test -z "$OBJDUMP" && OBJDUMP=objdump
10314
_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
10315
AC_SUBST([OBJDUMP])
10316
])
10317
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10318
# _LT_DECL_DLLTOOL
10319
# ----------------
10320
# Ensure DLLTOOL variable is set.
10321
m4_defun([_LT_DECL_DLLTOOL],
10322
[AC_CHECK_TOOL(DLLTOOL, dlltool, false)
10323
test -z "$DLLTOOL" && DLLTOOL=dlltool
10324
_LT_DECL([], [DLLTOOL], [1], [DLL creation program])
10325
AC_SUBST([DLLTOOL])
10326
])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10327
10328
# _LT_DECL_SED
10329
# ------------
10330
# Check for a fully-functional sed program, that truncates
10331
# as few characters as possible.  Prefer GNU sed if found.
10332
m4_defun([_LT_DECL_SED],
10333
[AC_PROG_SED
10334
test -z "$SED" && SED=sed
10335
Xsed="$SED -e 1s/^X//"
10336
_LT_DECL([], [SED], [1], [A sed program that does not truncate output])
10337
_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
10338
    [Sed that helps us avoid accidentally triggering echo(1) options like -n])
10339
])# _LT_DECL_SED
10340
10341
m4_ifndef([AC_PROG_SED], [
1 by Daniel Holbach
Import upstream version 0.5.1
10342
# NOTE: This macro has been submitted for inclusion into   #
10343
#  GNU Autoconf as AC_PROG_SED.  When it is available in   #
10344
#  a released version of Autoconf we should remove this    #
10345
#  macro and use it instead.                               #
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10346
10347
m4_defun([AC_PROG_SED],
1 by Daniel Holbach
Import upstream version 0.5.1
10348
[AC_MSG_CHECKING([for a sed that does not truncate output])
10349
AC_CACHE_VAL(lt_cv_path_SED,
10350
[# Loop through the user's path and test for sed and gsed.
10351
# Then use that list of sed's as ones to test for truncation.
10352
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10353
for as_dir in $PATH
10354
do
10355
  IFS=$as_save_IFS
10356
  test -z "$as_dir" && as_dir=.
10357
  for lt_ac_prog in sed gsed; do
10358
    for ac_exec_ext in '' $ac_executable_extensions; do
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10359
      if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
1 by Daniel Holbach
Import upstream version 0.5.1
10360
        lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
10361
      fi
10362
    done
10363
  done
10364
done
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
10365
IFS=$as_save_IFS
1 by Daniel Holbach
Import upstream version 0.5.1
10366
lt_ac_max=0
10367
lt_ac_count=0
10368
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
10369
# along with /bin/sed that truncates output.
10370
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
10371
  test ! -f $lt_ac_sed && continue
1 by Daniel Holbach
Import upstream version 0.5.1
10372
  cat /dev/null > conftest.in
10373
  lt_ac_count=0
10374
  echo $ECHO_N "0123456789$ECHO_C" >conftest.in
10375
  # Check for GNU sed and select it if it is found.
10376
  if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
10377
    lt_cv_path_SED=$lt_ac_sed
10378
    break
10379
  fi
10380
  while true; do
10381
    cat conftest.in conftest.in >conftest.tmp
10382
    mv conftest.tmp conftest.in
10383
    cp conftest.in conftest.nl
10384
    echo >>conftest.nl
10385
    $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
10386
    cmp -s conftest.out conftest.nl || break
10387
    # 10000 chars as input seems more than enough
10388
    test $lt_ac_count -gt 10 && break
10389
    lt_ac_count=`expr $lt_ac_count + 1`
10390
    if test $lt_ac_count -gt $lt_ac_max; then
10391
      lt_ac_max=$lt_ac_count
10392
      lt_cv_path_SED=$lt_ac_sed
10393
    fi
10394
  done
10395
done
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
10396
])
1 by Daniel Holbach
Import upstream version 0.5.1
10397
SED=$lt_cv_path_SED
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
10398
AC_SUBST([SED])
1 by Daniel Holbach
Import upstream version 0.5.1
10399
AC_MSG_RESULT([$SED])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10400
])#AC_PROG_SED
10401
])#m4_ifndef
10402
10403
# Old name:
10404
AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
10405
dnl aclocal-1.4 backwards compatibility:
10406
dnl AC_DEFUN([LT_AC_PROG_SED], [])
10407
10408
10409
# _LT_CHECK_SHELL_FEATURES
10410
# ------------------------
10411
# Find out whether the shell is Bourne or XSI compatible,
10412
# or has some other useful features.
10413
m4_defun([_LT_CHECK_SHELL_FEATURES],
10414
[AC_MSG_CHECKING([whether the shell understands some XSI constructs])
10415
# Try some XSI features
10416
xsi_shell=no
10417
( _lt_dummy="a/b/c"
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10418
  test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
10419
      = c,a/b,b/c, \
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10420
    && eval 'test $(( 1 + 1 )) -eq 2 \
10421
    && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
10422
  && xsi_shell=yes
10423
AC_MSG_RESULT([$xsi_shell])
10424
_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
10425
10426
AC_MSG_CHECKING([whether the shell understands "+="])
10427
lt_shell_append=no
10428
( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
10429
    >/dev/null 2>&1 \
10430
  && lt_shell_append=yes
10431
AC_MSG_RESULT([$lt_shell_append])
10432
_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
10433
10434
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
10435
  lt_unset=unset
10436
else
10437
  lt_unset=false
10438
fi
10439
_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
10440
10441
# test EBCDIC or ASCII
10442
case `echo X|tr X '\101'` in
10443
 A) # ASCII based system
10444
    # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
10445
  lt_SP2NL='tr \040 \012'
10446
  lt_NL2SP='tr \015\012 \040\040'
10447
  ;;
10448
 *) # EBCDIC based system
10449
  lt_SP2NL='tr \100 \n'
10450
  lt_NL2SP='tr \r\n \100\100'
10451
  ;;
10452
esac
10453
_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
10454
_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
10455
])# _LT_CHECK_SHELL_FEATURES
10456
10457
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
10458
# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
10459
# ------------------------------------------------------
10460
# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
10461
# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
10462
m4_defun([_LT_PROG_FUNCTION_REPLACE],
10463
[dnl {
10464
sed -e '/^$1 ()$/,/^} # $1 /c\
10465
$1 ()\
10466
{\
10467
m4_bpatsubsts([$2], [$], [\\], [^\([	 ]\)], [\\\1])
10468
} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
10469
  && mv -f "$cfgfile.tmp" "$cfgfile" \
10470
    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10471
test 0 -eq $? || _lt_function_replace_fail=:
10472
])
10473
10474
10475
# _LT_PROG_REPLACE_SHELLFNS
10476
# -------------------------
10477
# Replace existing portable implementations of several shell functions with
10478
# equivalent extended shell implementations where those features are available..
10479
m4_defun([_LT_PROG_REPLACE_SHELLFNS],
10480
[if test x"$xsi_shell" = xyes; then
10481
  _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
10482
    case ${1} in
10483
      */*) func_dirname_result="${1%/*}${2}" ;;
10484
      *  ) func_dirname_result="${3}" ;;
10485
    esac])
10486
10487
  _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
10488
    func_basename_result="${1##*/}"])
10489
10490
  _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
10491
    case ${1} in
10492
      */*) func_dirname_result="${1%/*}${2}" ;;
10493
      *  ) func_dirname_result="${3}" ;;
10494
    esac
10495
    func_basename_result="${1##*/}"])
10496
10497
  _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
10498
    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
10499
    # positional parameters, so assign one to ordinary parameter first.
10500
    func_stripname_result=${3}
10501
    func_stripname_result=${func_stripname_result#"${1}"}
10502
    func_stripname_result=${func_stripname_result%"${2}"}])
10503
10504
  _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
10505
    func_split_long_opt_name=${1%%=*}
10506
    func_split_long_opt_arg=${1#*=}])
10507
10508
  _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
10509
    func_split_short_opt_arg=${1#??}
10510
    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
10511
10512
  _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
10513
    case ${1} in
10514
      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
10515
      *)    func_lo2o_result=${1} ;;
10516
    esac])
10517
10518
  _LT_PROG_FUNCTION_REPLACE([func_xform], [    func_xform_result=${1%.*}.lo])
10519
10520
  _LT_PROG_FUNCTION_REPLACE([func_arith], [    func_arith_result=$(( $[*] ))])
10521
10522
  _LT_PROG_FUNCTION_REPLACE([func_len], [    func_len_result=${#1}])
10523
fi
10524
10525
if test x"$lt_shell_append" = xyes; then
10526
  _LT_PROG_FUNCTION_REPLACE([func_append], [    eval "${1}+=\\${2}"])
10527
10528
  _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
10529
    func_quote_for_eval "${2}"
10530
dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
10531
    eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
10532
10533
  # Save a `func_append' function call where possible by direct use of '+='
10534
  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
10535
    && mv -f "$cfgfile.tmp" "$cfgfile" \
10536
      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10537
  test 0 -eq $? || _lt_function_replace_fail=:
10538
else
10539
  # Save a `func_append' function call even when '+=' is not available
10540
  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
10541
    && mv -f "$cfgfile.tmp" "$cfgfile" \
10542
      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10543
  test 0 -eq $? || _lt_function_replace_fail=:
10544
fi
10545
10546
if test x"$_lt_function_replace_fail" = x":"; then
10547
  AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
10548
fi
10549
])
10550
10551
# _LT_PATH_CONVERSION_FUNCTIONS
10552
# -----------------------------
10553
# Determine which file name conversion functions should be used by
10554
# func_to_host_file (and, implicitly, by func_to_host_path).  These are needed
10555
# for certain cross-compile configurations and native mingw.
10556
m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
10557
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
10558
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
10559
AC_MSG_CHECKING([how to convert $build file names to $host format])
10560
AC_CACHE_VAL(lt_cv_to_host_file_cmd,
10561
[case $host in
10562
  *-*-mingw* )
10563
    case $build in
10564
      *-*-mingw* ) # actually msys
10565
        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
10566
        ;;
10567
      *-*-cygwin* )
10568
        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
10569
        ;;
10570
      * ) # otherwise, assume *nix
10571
        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
10572
        ;;
10573
    esac
10574
    ;;
10575
  *-*-cygwin* )
10576
    case $build in
10577
      *-*-mingw* ) # actually msys
10578
        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
10579
        ;;
10580
      *-*-cygwin* )
10581
        lt_cv_to_host_file_cmd=func_convert_file_noop
10582
        ;;
10583
      * ) # otherwise, assume *nix
10584
        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
10585
        ;;
10586
    esac
10587
    ;;
10588
  * ) # unhandled hosts (and "normal" native builds)
10589
    lt_cv_to_host_file_cmd=func_convert_file_noop
10590
    ;;
10591
esac
10592
])
10593
to_host_file_cmd=$lt_cv_to_host_file_cmd
10594
AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
10595
_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
10596
         [0], [convert $build file names to $host format])dnl
10597
10598
AC_MSG_CHECKING([how to convert $build file names to toolchain format])
10599
AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
10600
[#assume ordinary cross tools, or native build.
10601
lt_cv_to_tool_file_cmd=func_convert_file_noop
10602
case $host in
10603
  *-*-mingw* )
10604
    case $build in
10605
      *-*-mingw* ) # actually msys
10606
        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
10607
        ;;
10608
    esac
10609
    ;;
10610
esac
10611
])
10612
to_tool_file_cmd=$lt_cv_to_tool_file_cmd
10613
AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
10614
_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
10615
         [0], [convert $build files to toolchain format])dnl
10616
])# _LT_PATH_CONVERSION_FUNCTIONS
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10617
10618
# Helper functions for option handling.                    -*- Autoconf -*-
10619
#
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10620
#   Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
10621
#   Inc.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10622
#   Written by Gary V. Vaughan, 2004
10623
#
10624
# This file is free software; the Free Software Foundation gives
10625
# unlimited permission to copy and/or distribute it, with or without
10626
# modifications, as long as this notice is preserved.
10627
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10628
# serial 7 ltoptions.m4
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10629
10630
# This is to help aclocal find these macros, as it can't see m4_define.
10631
AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
10632
10633
10634
# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
10635
# ------------------------------------------
10636
m4_define([_LT_MANGLE_OPTION],
10637
[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
10638
10639
10640
# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
10641
# ---------------------------------------
10642
# Set option OPTION-NAME for macro MACRO-NAME, and if there is a
10643
# matching handler defined, dispatch to it.  Other OPTION-NAMEs are
10644
# saved as a flag.
10645
m4_define([_LT_SET_OPTION],
10646
[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
10647
m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
10648
        _LT_MANGLE_DEFUN([$1], [$2]),
10649
    [m4_warning([Unknown $1 option `$2'])])[]dnl
10650
])
10651
10652
10653
# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
10654
# ------------------------------------------------------------
10655
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
10656
m4_define([_LT_IF_OPTION],
10657
[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
10658
10659
10660
# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
10661
# -------------------------------------------------------
10662
# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
10663
# are set.
10664
m4_define([_LT_UNLESS_OPTIONS],
10665
[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
10666
	    [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
10667
		      [m4_define([$0_found])])])[]dnl
10668
m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
10669
])[]dnl
10670
])
10671
10672
10673
# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
10674
# ----------------------------------------
10675
# OPTION-LIST is a space-separated list of Libtool options associated
10676
# with MACRO-NAME.  If any OPTION has a matching handler declared with
10677
# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
10678
# the unknown option and exit.
10679
m4_defun([_LT_SET_OPTIONS],
10680
[# Set options
10681
m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
10682
    [_LT_SET_OPTION([$1], _LT_Option)])
10683
10684
m4_if([$1],[LT_INIT],[
10685
  dnl
10686
  dnl Simply set some default values (i.e off) if boolean options were not
10687
  dnl specified:
10688
  _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
10689
  ])
10690
  _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
10691
  ])
10692
  dnl
10693
  dnl If no reference was made to various pairs of opposing options, then
10694
  dnl we run the default mode handler for the pair.  For example, if neither
10695
  dnl `shared' nor `disable-shared' was passed, we enable building of shared
10696
  dnl archives by default:
10697
  _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
10698
  _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
10699
  _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
10700
  _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
10701
  		   [_LT_ENABLE_FAST_INSTALL])
10702
  ])
10703
])# _LT_SET_OPTIONS
10704
10705
10706
10707
# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
10708
# -----------------------------------------
10709
m4_define([_LT_MANGLE_DEFUN],
10710
[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
10711
10712
10713
# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
10714
# -----------------------------------------------
10715
m4_define([LT_OPTION_DEFINE],
10716
[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
10717
])# LT_OPTION_DEFINE
10718
10719
10720
# dlopen
10721
# ------
10722
LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
10723
])
10724
10725
AU_DEFUN([AC_LIBTOOL_DLOPEN],
10726
[_LT_SET_OPTION([LT_INIT], [dlopen])
10727
AC_DIAGNOSE([obsolete],
10728
[$0: Remove this warning and the call to _LT_SET_OPTION when you
10729
put the `dlopen' option into LT_INIT's first parameter.])
10730
])
10731
10732
dnl aclocal-1.4 backwards compatibility:
10733
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
10734
10735
10736
# win32-dll
10737
# ---------
10738
# Declare package support for building win32 dll's.
10739
LT_OPTION_DEFINE([LT_INIT], [win32-dll],
10740
[enable_win32_dll=yes
10741
10742
case $host in
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10743
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10744
  AC_CHECK_TOOL(AS, as, false)
10745
  AC_CHECK_TOOL(DLLTOOL, dlltool, false)
10746
  AC_CHECK_TOOL(OBJDUMP, objdump, false)
10747
  ;;
10748
esac
10749
10750
test -z "$AS" && AS=as
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10751
_LT_DECL([], [AS],      [1], [Assembler program])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10752
10753
test -z "$DLLTOOL" && DLLTOOL=dlltool
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10754
_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10755
10756
test -z "$OBJDUMP" && OBJDUMP=objdump
1.1.16 by Robert Ancell
Import upstream version 2.31.6
10757
_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
1.1.8 by Alexander Sack
Import upstream version 2.27.8
10758
])# win32-dll
10759
10760
AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
10761
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
10762
_LT_SET_OPTION([LT_INIT], [win32-dll])
10763
AC_DIAGNOSE([obsolete],
10764
[$0: Remove this warning and the call to _LT_SET_OPTION when you
10765
put the `win32-dll' option into LT_INIT's first parameter.])
10766
])
10767
10768
dnl aclocal-1.4 backwards compatibility:
10769
dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
10770
10771
10772
# _LT_ENABLE_SHARED([DEFAULT])
10773
# ----------------------------
10774
# implement the --enable-shared flag, and supports the `shared' and
10775
# `disable-shared' LT_INIT options.
10776
# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
10777
m4_define([_LT_ENABLE_SHARED],
10778
[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
10779
AC_ARG_ENABLE([shared],
10780
    [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
10781
	[build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
10782
    [p=${PACKAGE-default}
10783
    case $enableval in
10784
    yes) enable_shared=yes ;;
10785
    no) enable_shared=no ;;
10786
    *)
10787
      enable_shared=no
10788
      # Look at the argument we got.  We use all the common list separators.
10789
      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10790
      for pkg in $enableval; do
10791
	IFS="$lt_save_ifs"
10792
	if test "X$pkg" = "X$p"; then
10793
	  enable_shared=yes
10794
	fi
10795
      done
10796
      IFS="$lt_save_ifs"
10797
      ;;
10798
    esac],
10799
    [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
10800
10801
    _LT_DECL([build_libtool_libs], [enable_shared], [0],
10802
	[Whether or not to build shared libraries])
10803
])# _LT_ENABLE_SHARED
10804
10805
LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
10806
LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
10807
10808
# Old names:
10809
AC_DEFUN([AC_ENABLE_SHARED],
10810
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
10811
])
10812
10813
AC_DEFUN([AC_DISABLE_SHARED],
10814
[_LT_SET_OPTION([LT_INIT], [disable-shared])
10815
])
10816
10817
AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
10818
AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
10819
10820
dnl aclocal-1.4 backwards compatibility:
10821
dnl AC_DEFUN([AM_ENABLE_SHARED], [])
10822
dnl AC_DEFUN([AM_DISABLE_SHARED], [])
10823
10824
10825
10826
# _LT_ENABLE_STATIC([DEFAULT])
10827
# ----------------------------
10828
# implement the --enable-static flag, and support the `static' and
10829
# `disable-static' LT_INIT options.
10830
# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
10831
m4_define([_LT_ENABLE_STATIC],
10832
[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
10833
AC_ARG_ENABLE([static],
10834
    [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
10835
	[build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
10836
    [p=${PACKAGE-default}
10837
    case $enableval in
10838
    yes) enable_static=yes ;;
10839
    no) enable_static=no ;;
10840
    *)
10841
     enable_static=no
10842
      # Look at the argument we got.  We use all the common list separators.
10843
      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10844
      for pkg in $enableval; do
10845
	IFS="$lt_save_ifs"
10846
	if test "X$pkg" = "X$p"; then
10847
	  enable_static=yes
10848
	fi
10849
      done
10850
      IFS="$lt_save_ifs"
10851
      ;;
10852
    esac],
10853
    [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
10854
10855
    _LT_DECL([build_old_libs], [enable_static], [0],
10856
	[Whether or not to build static libraries])
10857
])# _LT_ENABLE_STATIC
10858
10859
LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
10860
LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
10861
10862
# Old names:
10863
AC_DEFUN([AC_ENABLE_STATIC],
10864
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
10865
])
10866
10867
AC_DEFUN([AC_DISABLE_STATIC],
10868
[_LT_SET_OPTION([LT_INIT], [disable-static])
10869
])
10870
10871
AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
10872
AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
10873
10874
dnl aclocal-1.4 backwards compatibility:
10875
dnl AC_DEFUN([AM_ENABLE_STATIC], [])
10876
dnl AC_DEFUN([AM_DISABLE_STATIC], [])
10877
10878
10879
10880
# _LT_ENABLE_FAST_INSTALL([DEFAULT])
10881
# ----------------------------------
10882
# implement the --enable-fast-install flag, and support the `fast-install'
10883
# and `disable-fast-install' LT_INIT options.
10884
# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
10885
m4_define([_LT_ENABLE_FAST_INSTALL],
10886
[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
10887
AC_ARG_ENABLE([fast-install],
10888
    [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
10889
    [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
10890
    [p=${PACKAGE-default}
10891
    case $enableval in
10892
    yes) enable_fast_install=yes ;;
10893
    no) enable_fast_install=no ;;
10894
    *)
10895
      enable_fast_install=no
10896
      # Look at the argument we got.  We use all the common list separators.
10897
      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10898
      for pkg in $enableval; do
10899
	IFS="$lt_save_ifs"
10900
	if test "X$pkg" = "X$p"; then
10901
	  enable_fast_install=yes
10902
	fi
10903
      done
10904
      IFS="$lt_save_ifs"
10905
      ;;
10906
    esac],
10907
    [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
10908
10909
_LT_DECL([fast_install], [enable_fast_install], [0],
10910
	 [Whether or not to optimize for fast installation])dnl
10911
])# _LT_ENABLE_FAST_INSTALL
10912
10913
LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
10914
LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
10915
10916
# Old names:
10917
AU_DEFUN([AC_ENABLE_FAST_INSTALL],
10918
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
10919
AC_DIAGNOSE([obsolete],
10920
[$0: Remove this warning and the call to _LT_SET_OPTION when you put
10921
the `fast-install' option into LT_INIT's first parameter.])
10922
])
10923
10924
AU_DEFUN([AC_DISABLE_FAST_INSTALL],
10925
[_LT_SET_OPTION([LT_INIT], [disable-fast-install])
10926
AC_DIAGNOSE([obsolete],
10927
[$0: Remove this warning and the call to _LT_SET_OPTION when you put
10928
the `disable-fast-install' option into LT_INIT's first parameter.])
10929
])
10930
10931
dnl aclocal-1.4 backwards compatibility:
10932
dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
10933
dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
10934
10935
10936
# _LT_WITH_PIC([MODE])
10937
# --------------------
10938
# implement the --with-pic flag, and support the `pic-only' and `no-pic'
10939
# LT_INIT options.
10940
# MODE is either `yes' or `no'.  If omitted, it defaults to `both'.
10941
m4_define([_LT_WITH_PIC],
10942
[AC_ARG_WITH([pic],
10943
    [AS_HELP_STRING([--with-pic],
10944
	[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
10945
    [pic_mode="$withval"],
10946
    [pic_mode=default])
10947
10948
test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
10949
10950
_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
10951
])# _LT_WITH_PIC
10952
10953
LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
10954
LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
10955
10956
# Old name:
10957
AU_DEFUN([AC_LIBTOOL_PICMODE],
10958
[_LT_SET_OPTION([LT_INIT], [pic-only])
10959
AC_DIAGNOSE([obsolete],
10960
[$0: Remove this warning and the call to _LT_SET_OPTION when you
10961
put the `pic-only' option into LT_INIT's first parameter.])
10962
])
10963
10964
dnl aclocal-1.4 backwards compatibility:
10965
dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
10966
10967
10968
m4_define([_LTDL_MODE], [])
10969
LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
10970
		 [m4_define([_LTDL_MODE], [nonrecursive])])
10971
LT_OPTION_DEFINE([LTDL_INIT], [recursive],
10972
		 [m4_define([_LTDL_MODE], [recursive])])
10973
LT_OPTION_DEFINE([LTDL_INIT], [subproject],
10974
		 [m4_define([_LTDL_MODE], [subproject])])
10975
10976
m4_define([_LTDL_TYPE], [])
10977
LT_OPTION_DEFINE([LTDL_INIT], [installable],
10978
		 [m4_define([_LTDL_TYPE], [installable])])
10979
LT_OPTION_DEFINE([LTDL_INIT], [convenience],
10980
		 [m4_define([_LTDL_TYPE], [convenience])])
10981
10982
# ltsugar.m4 -- libtool m4 base layer.                         -*-Autoconf-*-
10983
#
10984
# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
10985
# Written by Gary V. Vaughan, 2004
10986
#
10987
# This file is free software; the Free Software Foundation gives
10988
# unlimited permission to copy and/or distribute it, with or without
10989
# modifications, as long as this notice is preserved.
10990
10991
# serial 6 ltsugar.m4
10992
10993
# This is to help aclocal find these macros, as it can't see m4_define.
10994
AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
10995
10996
10997
# lt_join(SEP, ARG1, [ARG2...])
10998
# -----------------------------
10999
# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
11000
# associated separator.
11001
# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
11002
# versions in m4sugar had bugs.
11003
m4_define([lt_join],
11004
[m4_if([$#], [1], [],
11005
       [$#], [2], [[$2]],
11006
       [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
11007
m4_define([_lt_join],
11008
[m4_if([$#$2], [2], [],
11009
       [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
11010
11011
11012
# lt_car(LIST)
11013
# lt_cdr(LIST)
11014
# ------------
11015
# Manipulate m4 lists.
11016
# These macros are necessary as long as will still need to support
11017
# Autoconf-2.59 which quotes differently.
11018
m4_define([lt_car], [[$1]])
11019
m4_define([lt_cdr],
11020
[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
11021
       [$#], 1, [],
11022
       [m4_dquote(m4_shift($@))])])
11023
m4_define([lt_unquote], $1)
11024
11025
11026
# lt_append(MACRO-NAME, STRING, [SEPARATOR])
11027
# ------------------------------------------
11028
# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
11029
# Note that neither SEPARATOR nor STRING are expanded; they are appended
11030
# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
11031
# No SEPARATOR is output if MACRO-NAME was previously undefined (different
11032
# than defined and empty).
11033
#
11034
# This macro is needed until we can rely on Autoconf 2.62, since earlier
11035
# versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
11036
m4_define([lt_append],
11037
[m4_define([$1],
11038
	   m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
11039
11040
11041
11042
# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
11043
# ----------------------------------------------------------
11044
# Produce a SEP delimited list of all paired combinations of elements of
11045
# PREFIX-LIST with SUFFIX1 through SUFFIXn.  Each element of the list
11046
# has the form PREFIXmINFIXSUFFIXn.
11047
# Needed until we can rely on m4_combine added in Autoconf 2.62.
11048
m4_define([lt_combine],
11049
[m4_if(m4_eval([$# > 3]), [1],
11050
       [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
11051
[[m4_foreach([_Lt_prefix], [$2],
11052
	     [m4_foreach([_Lt_suffix],
11053
		]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
11054
	[_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
11055
11056
11057
# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
11058
# -----------------------------------------------------------------------
11059
# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
11060
# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
11061
m4_define([lt_if_append_uniq],
11062
[m4_ifdef([$1],
11063
	  [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
11064
		 [lt_append([$1], [$2], [$3])$4],
11065
		 [$5])],
11066
	  [lt_append([$1], [$2], [$3])$4])])
11067
11068
11069
# lt_dict_add(DICT, KEY, VALUE)
11070
# -----------------------------
11071
m4_define([lt_dict_add],
11072
[m4_define([$1($2)], [$3])])
11073
11074
11075
# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
11076
# --------------------------------------------
11077
m4_define([lt_dict_add_subkey],
11078
[m4_define([$1($2:$3)], [$4])])
11079
11080
11081
# lt_dict_fetch(DICT, KEY, [SUBKEY])
11082
# ----------------------------------
11083
m4_define([lt_dict_fetch],
11084
[m4_ifval([$3],
11085
	m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
11086
    m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
11087
11088
11089
# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
11090
# -----------------------------------------------------------------
11091
m4_define([lt_if_dict_fetch],
11092
[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
11093
	[$5],
11094
    [$6])])
11095
11096
11097
# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
11098
# --------------------------------------------------------------
11099
m4_define([lt_dict_filter],
11100
[m4_if([$5], [], [],
11101
  [lt_join(m4_quote(m4_default([$4], [[, ]])),
11102
           lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
11103
		      [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
11104
])
11105
11106
# ltversion.m4 -- version numbers			-*- Autoconf -*-
11107
#
11108
#   Copyright (C) 2004 Free Software Foundation, Inc.
11109
#   Written by Scott James Remnant, 2004
11110
#
11111
# This file is free software; the Free Software Foundation gives
11112
# unlimited permission to copy and/or distribute it, with or without
11113
# modifications, as long as this notice is preserved.
11114
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
11115
# @configure_input@
1.1.8 by Alexander Sack
Import upstream version 2.27.8
11116
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
11117
# serial 3293 ltversion.m4
1.1.8 by Alexander Sack
Import upstream version 2.27.8
11118
# This file is part of GNU Libtool
11119
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
11120
m4_define([LT_PACKAGE_VERSION], [2.4])
11121
m4_define([LT_PACKAGE_REVISION], [1.3293])
1.1.8 by Alexander Sack
Import upstream version 2.27.8
11122
11123
AC_DEFUN([LTVERSION_VERSION],
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
11124
[macro_version='2.4'
11125
macro_revision='1.3293'
1.1.8 by Alexander Sack
Import upstream version 2.27.8
11126
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
11127
_LT_DECL(, macro_revision, 0)
11128
])
11129
11130
# lt~obsolete.m4 -- aclocal satisfying obsolete definitions.    -*-Autoconf-*-
11131
#
1.1.16 by Robert Ancell
Import upstream version 2.31.6
11132
#   Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
1.1.8 by Alexander Sack
Import upstream version 2.27.8
11133
#   Written by Scott James Remnant, 2004.
11134
#
11135
# This file is free software; the Free Software Foundation gives
11136
# unlimited permission to copy and/or distribute it, with or without
11137
# modifications, as long as this notice is preserved.
11138
1.1.16 by Robert Ancell
Import upstream version 2.31.6
11139
# serial 5 lt~obsolete.m4
1.1.8 by Alexander Sack
Import upstream version 2.27.8
11140
11141
# These exist entirely to fool aclocal when bootstrapping libtool.
11142
#
11143
# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
11144
# which have later been changed to m4_define as they aren't part of the
11145
# exported API, or moved to Autoconf or Automake where they belong.
11146
#
11147
# The trouble is, aclocal is a bit thick.  It'll see the old AC_DEFUN
11148
# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
11149
# using a macro with the same name in our local m4/libtool.m4 it'll
11150
# pull the old libtool.m4 in (it doesn't see our shiny new m4_define
11151
# and doesn't know about Autoconf macros at all.)
11152
#
11153
# So we provide this file, which has a silly filename so it's always
11154
# included after everything else.  This provides aclocal with the
11155
# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
11156
# because those macros already exist, or will be overwritten later.
11157
# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 
11158
#
11159
# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
11160
# Yes, that means every name once taken will need to remain here until
11161
# we give up compatibility with versions before 1.7, at which point
11162
# we need to keep only those names which we still refer to.
11163
11164
# This is to help aclocal find these macros, as it can't see m4_define.
11165
AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
11166
11167
m4_ifndef([AC_LIBTOOL_LINKER_OPTION],	[AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
11168
m4_ifndef([AC_PROG_EGREP],		[AC_DEFUN([AC_PROG_EGREP])])
11169
m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH],	[AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
11170
m4_ifndef([_LT_AC_SHELL_INIT],		[AC_DEFUN([_LT_AC_SHELL_INIT])])
11171
m4_ifndef([_LT_AC_SYS_LIBPATH_AIX],	[AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
11172
m4_ifndef([_LT_PROG_LTMAIN],		[AC_DEFUN([_LT_PROG_LTMAIN])])
11173
m4_ifndef([_LT_AC_TAGVAR],		[AC_DEFUN([_LT_AC_TAGVAR])])
11174
m4_ifndef([AC_LTDL_ENABLE_INSTALL],	[AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
11175
m4_ifndef([AC_LTDL_PREOPEN],		[AC_DEFUN([AC_LTDL_PREOPEN])])
11176
m4_ifndef([_LT_AC_SYS_COMPILER],	[AC_DEFUN([_LT_AC_SYS_COMPILER])])
11177
m4_ifndef([_LT_AC_LOCK],		[AC_DEFUN([_LT_AC_LOCK])])
11178
m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE],	[AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
11179
m4_ifndef([_LT_AC_TRY_DLOPEN_SELF],	[AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
11180
m4_ifndef([AC_LIBTOOL_PROG_CC_C_O],	[AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
11181
m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
11182
m4_ifndef([AC_LIBTOOL_OBJDIR],		[AC_DEFUN([AC_LIBTOOL_OBJDIR])])
11183
m4_ifndef([AC_LTDL_OBJDIR],		[AC_DEFUN([AC_LTDL_OBJDIR])])
11184
m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
11185
m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP],	[AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
11186
m4_ifndef([AC_PATH_MAGIC],		[AC_DEFUN([AC_PATH_MAGIC])])
11187
m4_ifndef([AC_PROG_LD_GNU],		[AC_DEFUN([AC_PROG_LD_GNU])])
11188
m4_ifndef([AC_PROG_LD_RELOAD_FLAG],	[AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
11189
m4_ifndef([AC_DEPLIBS_CHECK_METHOD],	[AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
11190
m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
11191
m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
11192
m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
11193
m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS],	[AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
11194
m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP],	[AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
11195
m4_ifndef([LT_AC_PROG_EGREP],		[AC_DEFUN([LT_AC_PROG_EGREP])])
11196
m4_ifndef([LT_AC_PROG_SED],		[AC_DEFUN([LT_AC_PROG_SED])])
11197
m4_ifndef([_LT_CC_BASENAME],		[AC_DEFUN([_LT_CC_BASENAME])])
11198
m4_ifndef([_LT_COMPILER_BOILERPLATE],	[AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
11199
m4_ifndef([_LT_LINKER_BOILERPLATE],	[AC_DEFUN([_LT_LINKER_BOILERPLATE])])
11200
m4_ifndef([_AC_PROG_LIBTOOL],		[AC_DEFUN([_AC_PROG_LIBTOOL])])
11201
m4_ifndef([AC_LIBTOOL_SETUP],		[AC_DEFUN([AC_LIBTOOL_SETUP])])
11202
m4_ifndef([_LT_AC_CHECK_DLFCN],		[AC_DEFUN([_LT_AC_CHECK_DLFCN])])
11203
m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER],	[AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
11204
m4_ifndef([_LT_AC_TAGCONFIG],		[AC_DEFUN([_LT_AC_TAGCONFIG])])
11205
m4_ifndef([AC_DISABLE_FAST_INSTALL],	[AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
11206
m4_ifndef([_LT_AC_LANG_CXX],		[AC_DEFUN([_LT_AC_LANG_CXX])])
11207
m4_ifndef([_LT_AC_LANG_F77],		[AC_DEFUN([_LT_AC_LANG_F77])])
11208
m4_ifndef([_LT_AC_LANG_GCJ],		[AC_DEFUN([_LT_AC_LANG_GCJ])])
11209
m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
11210
m4_ifndef([_LT_AC_LANG_C_CONFIG],	[AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
11211
m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
11212
m4_ifndef([_LT_AC_LANG_CXX_CONFIG],	[AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
11213
m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
11214
m4_ifndef([_LT_AC_LANG_F77_CONFIG],	[AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
11215
m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
11216
m4_ifndef([_LT_AC_LANG_GCJ_CONFIG],	[AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
11217
m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
11218
m4_ifndef([_LT_AC_LANG_RC_CONFIG],	[AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
11219
m4_ifndef([AC_LIBTOOL_CONFIG],		[AC_DEFUN([AC_LIBTOOL_CONFIG])])
11220
m4_ifndef([_LT_AC_FILE_LTDLL_C],	[AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
1.1.16 by Robert Ancell
Import upstream version 2.31.6
11221
m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS],	[AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
11222
m4_ifndef([_LT_AC_PROG_CXXCPP],		[AC_DEFUN([_LT_AC_PROG_CXXCPP])])
11223
m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS],	[AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
11224
m4_ifndef([_LT_PROG_ECHO_BACKSLASH],	[AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
11225
m4_ifndef([_LT_PROG_F77],		[AC_DEFUN([_LT_PROG_F77])])
11226
m4_ifndef([_LT_PROG_FC],		[AC_DEFUN([_LT_PROG_FC])])
11227
m4_ifndef([_LT_PROG_CXX],		[AC_DEFUN([_LT_PROG_CXX])])
1 by Daniel Holbach
Import upstream version 0.5.1
11228
1.1.17 by Didier Roche
Import upstream version 2.31.90
11229
# nls.m4 serial 5 (gettext-0.18)
11230
dnl Copyright (C) 1995-2003, 2005-2006, 2008-2010 Free Software Foundation,
11231
dnl Inc.
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11232
dnl This file is free software; the Free Software Foundation
11233
dnl gives unlimited permission to copy and/or distribute it,
11234
dnl with or without modifications, as long as this notice is preserved.
11235
dnl
11236
dnl This file can can be used in projects which are not available under
11237
dnl the GNU General Public License or the GNU Library General Public
11238
dnl License but which still want to provide support for the GNU gettext
11239
dnl functionality.
11240
dnl Please note that the actual code of the GNU gettext library is covered
11241
dnl by the GNU Library General Public License, and the rest of the GNU
11242
dnl gettext package package is covered by the GNU General Public License.
11243
dnl They are *not* in the public domain.
11244
11245
dnl Authors:
11246
dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
11247
dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2003.
11248
1.1.17 by Didier Roche
Import upstream version 2.31.90
11249
AC_PREREQ([2.50])
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11250
11251
AC_DEFUN([AM_NLS],
11252
[
11253
  AC_MSG_CHECKING([whether NLS is requested])
11254
  dnl Default is enabled NLS
1.1.17 by Didier Roche
Import upstream version 2.31.90
11255
  AC_ARG_ENABLE([nls],
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11256
    [  --disable-nls           do not use Native Language Support],
11257
    USE_NLS=$enableval, USE_NLS=yes)
1.1.17 by Didier Roche
Import upstream version 2.31.90
11258
  AC_MSG_RESULT([$USE_NLS])
11259
  AC_SUBST([USE_NLS])
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11260
])
11261
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11262
# pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
1.1.17 by Didier Roche
Import upstream version 2.31.90
11263
# serial 1 (pkg-config-0.24)
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11264
# 
11265
# Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
11266
#
11267
# This program is free software; you can redistribute it and/or modify
11268
# it under the terms of the GNU General Public License as published by
11269
# the Free Software Foundation; either version 2 of the License, or
11270
# (at your option) any later version.
11271
#
11272
# This program is distributed in the hope that it will be useful, but
11273
# WITHOUT ANY WARRANTY; without even the implied warranty of
11274
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11275
# General Public License for more details.
11276
#
11277
# You should have received a copy of the GNU General Public License
11278
# along with this program; if not, write to the Free Software
11279
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
11280
#
11281
# As a special exception to the GNU General Public License, if you
11282
# distribute this file as part of a program that contains a
11283
# configuration script generated by Autoconf, you may include it under
11284
# the same distribution terms that you use for the rest of that program.
11285
11286
# PKG_PROG_PKG_CONFIG([MIN-VERSION])
11287
# ----------------------------------
11288
AC_DEFUN([PKG_PROG_PKG_CONFIG],
11289
[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
11290
m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
1.1.17 by Didier Roche
Import upstream version 2.31.90
11291
AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
11292
AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
11293
AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
11294
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11295
if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
11296
	AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
11297
fi
11298
if test -n "$PKG_CONFIG"; then
11299
	_pkg_min_version=m4_default([$1], [0.9.0])
11300
	AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
11301
	if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
11302
		AC_MSG_RESULT([yes])
11303
	else
11304
		AC_MSG_RESULT([no])
11305
		PKG_CONFIG=""
11306
	fi
11307
fi[]dnl
11308
])# PKG_PROG_PKG_CONFIG
11309
11310
# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
11311
#
11312
# Check to see whether a particular set of modules exists.  Similar
11313
# to PKG_CHECK_MODULES(), but does not set variables or print errors.
11314
#
1.1.17 by Didier Roche
Import upstream version 2.31.90
11315
# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
11316
# only at the first occurence in configure.ac, so if the first place
11317
# it's called might be skipped (such as if it is within an "if", you
11318
# have to call PKG_CHECK_EXISTS manually
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11319
# --------------------------------------------------------------
11320
AC_DEFUN([PKG_CHECK_EXISTS],
11321
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
11322
if test -n "$PKG_CONFIG" && \
11323
    AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
1.1.17 by Didier Roche
Import upstream version 2.31.90
11324
  m4_default([$2], [:])
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11325
m4_ifvaln([$3], [else
11326
  $3])dnl
11327
fi])
11328
11329
# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
11330
# ---------------------------------------------
11331
m4_define([_PKG_CONFIG],
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11332
[if test -n "$$1"; then
11333
    pkg_cv_[]$1="$$1"
11334
 elif test -n "$PKG_CONFIG"; then
11335
    PKG_CHECK_EXISTS([$3],
11336
                     [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
11337
		     [pkg_failed=yes])
11338
 else
11339
    pkg_failed=untried
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11340
fi[]dnl
11341
])# _PKG_CONFIG
11342
11343
# _PKG_SHORT_ERRORS_SUPPORTED
11344
# -----------------------------
11345
AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
11346
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])
11347
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
11348
        _pkg_short_errors_supported=yes
11349
else
11350
        _pkg_short_errors_supported=no
11351
fi[]dnl
11352
])# _PKG_SHORT_ERRORS_SUPPORTED
11353
11354
11355
# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
11356
# [ACTION-IF-NOT-FOUND])
11357
#
11358
#
11359
# Note that if there is a possibility the first call to
11360
# PKG_CHECK_MODULES might not happen, you should be sure to include an
11361
# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
11362
#
11363
#
11364
# --------------------------------------------------------------
11365
AC_DEFUN([PKG_CHECK_MODULES],
11366
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
11367
AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
11368
AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
11369
11370
pkg_failed=no
11371
AC_MSG_CHECKING([for $1])
11372
11373
_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
11374
_PKG_CONFIG([$1][_LIBS], [libs], [$2])
11375
11376
m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
11377
and $1[]_LIBS to avoid the need to call pkg-config.
11378
See the pkg-config man page for more details.])
11379
11380
if test $pkg_failed = yes; then
1.1.17 by Didier Roche
Import upstream version 2.31.90
11381
   	AC_MSG_RESULT([no])
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11382
        _PKG_SHORT_ERRORS_SUPPORTED
11383
        if test $_pkg_short_errors_supported = yes; then
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11384
	        $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11385
        else 
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
11386
	        $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
1.1.2 by Daniel Holbach
Import upstream version 0.7.0
11387
        fi
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11388
	# Put the nasty error message in config.log where it belongs
11389
	echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
11390
1.1.17 by Didier Roche
Import upstream version 2.31.90
11391
	m4_default([$4], [AC_MSG_ERROR(
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11392
[Package requirements ($2) were not met:
11393
11394
$$1_PKG_ERRORS
11395
11396
Consider adjusting the PKG_CONFIG_PATH environment variable if you
11397
installed software in a non-standard prefix.
11398
1.1.17 by Didier Roche
Import upstream version 2.31.90
11399
_PKG_TEXT])
11400
        ])
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11401
elif test $pkg_failed = untried; then
1.1.17 by Didier Roche
Import upstream version 2.31.90
11402
     	AC_MSG_RESULT([no])
11403
	m4_default([$4], [AC_MSG_FAILURE(
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11404
[The pkg-config script could not be found or is too old.  Make sure it
11405
is in your PATH or set the PKG_CONFIG environment variable to the full
11406
path to pkg-config.
11407
11408
_PKG_TEXT
11409
1.1.17 by Didier Roche
Import upstream version 2.31.90
11410
To get pkg-config, see <http://pkg-config.freedesktop.org/>.])
11411
        ])
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11412
else
11413
	$1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
11414
	$1[]_LIBS=$pkg_cv_[]$1[]_LIBS
11415
        AC_MSG_RESULT([yes])
1.1.17 by Didier Roche
Import upstream version 2.31.90
11416
	$3
1.1.3 by Daniel Holbach
Import upstream version 0.8.0
11417
fi[]dnl
11418
])# PKG_CHECK_MODULES
11419
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
11420
# po.m4 serial 17 (gettext-0.18)
11421
dnl Copyright (C) 1995-2010 Free Software Foundation, Inc.
11422
dnl This file is free software; the Free Software Foundation
11423
dnl gives unlimited permission to copy and/or distribute it,
11424
dnl with or without modifications, as long as this notice is preserved.
11425
dnl
11426
dnl This file can can be used in projects which are not available under
11427
dnl the GNU General Public License or the GNU Library General Public
11428
dnl License but which still want to provide support for the GNU gettext
11429
dnl functionality.
11430
dnl Please note that the actual code of the GNU gettext library is covered
11431
dnl by the GNU Library General Public License, and the rest of the GNU
11432
dnl gettext package package is covered by the GNU General Public License.
11433
dnl They are *not* in the public domain.
11434
11435
dnl Authors:
11436
dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
11437
dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2003.
11438
11439
AC_PREREQ([2.50])
11440
11441
dnl Checks for all prerequisites of the po subdirectory.
11442
AC_DEFUN([AM_PO_SUBDIRS],
11443
[
11444
  AC_REQUIRE([AC_PROG_MAKE_SET])dnl
11445
  AC_REQUIRE([AC_PROG_INSTALL])dnl
11446
  AC_REQUIRE([AM_PROG_MKDIR_P])dnl defined by automake
11447
  AC_REQUIRE([AM_NLS])dnl
11448
11449
  dnl Release version of the gettext macros. This is used to ensure that
11450
  dnl the gettext macros and po/Makefile.in.in are in sync.
11451
  AC_SUBST([GETTEXT_MACRO_VERSION], [0.18])
11452
11453
  dnl Perform the following tests also if --disable-nls has been given,
11454
  dnl because they are needed for "make dist" to work.
11455
11456
  dnl Search for GNU msgfmt in the PATH.
11457
  dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions.
11458
  dnl The second test excludes FreeBSD msgfmt.
11459
  AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
11460
    [$ac_dir/$ac_word --statistics /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
11461
     (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
11462
    :)
11463
  AC_PATH_PROG([GMSGFMT], [gmsgfmt], [$MSGFMT])
11464
11465
  dnl Test whether it is GNU msgfmt >= 0.15.
11466
changequote(,)dnl
11467
  case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
11468
    '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;;
11469
    *) MSGFMT_015=$MSGFMT ;;
11470
  esac
11471
changequote([,])dnl
11472
  AC_SUBST([MSGFMT_015])
11473
changequote(,)dnl
11474
  case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
11475
    '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
11476
    *) GMSGFMT_015=$GMSGFMT ;;
11477
  esac
11478
changequote([,])dnl
11479
  AC_SUBST([GMSGFMT_015])
11480
11481
  dnl Search for GNU xgettext 0.12 or newer in the PATH.
11482
  dnl The first test excludes Solaris xgettext and early GNU xgettext versions.
11483
  dnl The second test excludes FreeBSD xgettext.
11484
  AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
11485
    [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
11486
     (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
11487
    :)
11488
  dnl Remove leftover from FreeBSD xgettext call.
11489
  rm -f messages.po
11490
11491
  dnl Test whether it is GNU xgettext >= 0.15.
11492
changequote(,)dnl
11493
  case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
11494
    '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
11495
    *) XGETTEXT_015=$XGETTEXT ;;
11496
  esac
11497
changequote([,])dnl
11498
  AC_SUBST([XGETTEXT_015])
11499
11500
  dnl Search for GNU msgmerge 0.11 or newer in the PATH.
11501
  AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge,
11502
    [$ac_dir/$ac_word --update -q /dev/null /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1], :)
11503
11504
  dnl Installation directories.
11505
  dnl Autoconf >= 2.60 defines localedir. For older versions of autoconf, we
11506
  dnl have to define it here, so that it can be used in po/Makefile.
11507
  test -n "$localedir" || localedir='${datadir}/locale'
11508
  AC_SUBST([localedir])
11509
11510
  dnl Support for AM_XGETTEXT_OPTION.
11511
  test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
11512
  AC_SUBST([XGETTEXT_EXTRA_OPTIONS])
11513
11514
  AC_CONFIG_COMMANDS([po-directories], [[
11515
    for ac_file in $CONFIG_FILES; do
11516
      # Support "outfile[:infile[:infile...]]"
11517
      case "$ac_file" in
11518
        *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
11519
      esac
11520
      # PO directories have a Makefile.in generated from Makefile.in.in.
11521
      case "$ac_file" in */Makefile.in)
11522
        # Adjust a relative srcdir.
11523
        ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
11524
        ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
11525
        ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
11526
        # In autoconf-2.13 it is called $ac_given_srcdir.
11527
        # In autoconf-2.50 it is called $srcdir.
11528
        test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
11529
        case "$ac_given_srcdir" in
11530
          .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
11531
          /*) top_srcdir="$ac_given_srcdir" ;;
11532
          *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
11533
        esac
11534
        # Treat a directory as a PO directory if and only if it has a
11535
        # POTFILES.in file. This allows packages to have multiple PO
11536
        # directories under different names or in different locations.
11537
        if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
11538
          rm -f "$ac_dir/POTFILES"
11539
          test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
11540
          cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ 	]*\$/d" -e "s,.*,     $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
11541
          POMAKEFILEDEPS="POTFILES.in"
11542
          # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
11543
          # on $ac_dir but don't depend on user-specified configuration
11544
          # parameters.
11545
          if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
11546
            # The LINGUAS file contains the set of available languages.
11547
            if test -n "$OBSOLETE_ALL_LINGUAS"; then
11548
              test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
11549
            fi
11550
            ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
11551
            # Hide the ALL_LINGUAS assigment from automake < 1.5.
11552
            eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
11553
            POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
11554
          else
11555
            # The set of available languages was given in configure.in.
11556
            # Hide the ALL_LINGUAS assigment from automake < 1.5.
11557
            eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
11558
          fi
11559
          # Compute POFILES
11560
          # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
11561
          # Compute UPDATEPOFILES
11562
          # as      $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
11563
          # Compute DUMMYPOFILES
11564
          # as      $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
11565
          # Compute GMOFILES
11566
          # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
11567
          case "$ac_given_srcdir" in
11568
            .) srcdirpre= ;;
11569
            *) srcdirpre='$(srcdir)/' ;;
11570
          esac
11571
          POFILES=
11572
          UPDATEPOFILES=
11573
          DUMMYPOFILES=
11574
          GMOFILES=
11575
          for lang in $ALL_LINGUAS; do
11576
            POFILES="$POFILES $srcdirpre$lang.po"
11577
            UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
11578
            DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
11579
            GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
11580
          done
11581
          # CATALOGS depends on both $ac_dir and the user's LINGUAS
11582
          # environment variable.
11583
          INST_LINGUAS=
11584
          if test -n "$ALL_LINGUAS"; then
11585
            for presentlang in $ALL_LINGUAS; do
11586
              useit=no
11587
              if test "%UNSET%" != "$LINGUAS"; then
11588
                desiredlanguages="$LINGUAS"
11589
              else
11590
                desiredlanguages="$ALL_LINGUAS"
11591
              fi
11592
              for desiredlang in $desiredlanguages; do
11593
                # Use the presentlang catalog if desiredlang is
11594
                #   a. equal to presentlang, or
11595
                #   b. a variant of presentlang (because in this case,
11596
                #      presentlang can be used as a fallback for messages
11597
                #      which are not translated in the desiredlang catalog).
11598
                case "$desiredlang" in
11599
                  "$presentlang"*) useit=yes;;
11600
                esac
11601
              done
11602
              if test $useit = yes; then
11603
                INST_LINGUAS="$INST_LINGUAS $presentlang"
11604
              fi
11605
            done
11606
          fi
11607
          CATALOGS=
11608
          if test -n "$INST_LINGUAS"; then
11609
            for lang in $INST_LINGUAS; do
11610
              CATALOGS="$CATALOGS $lang.gmo"
11611
            done
11612
          fi
11613
          test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
11614
          sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
11615
          for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
11616
            if test -f "$f"; then
11617
              case "$f" in
11618
                *.orig | *.bak | *~) ;;
11619
                *) cat "$f" >> "$ac_dir/Makefile" ;;
11620
              esac
11621
            fi
11622
          done
11623
        fi
11624
        ;;
11625
      esac
11626
    done]],
11627
   [# Capture the value of obsolete ALL_LINGUAS because we need it to compute
11628
    # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
11629
    # from automake < 1.5.
11630
    eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
11631
    # Capture the value of LINGUAS because we need it to compute CATALOGS.
11632
    LINGUAS="${LINGUAS-%UNSET%}"
11633
   ])
11634
])
11635
11636
dnl Postprocesses a Makefile in a directory containing PO files.
11637
AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE],
11638
[
11639
  # When this code is run, in config.status, two variables have already been
11640
  # set:
11641
  # - OBSOLETE_ALL_LINGUAS is the value of LINGUAS set in configure.in,
11642
  # - LINGUAS is the value of the environment variable LINGUAS at configure
11643
  #   time.
11644
11645
changequote(,)dnl
11646
  # Adjust a relative srcdir.
11647
  ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
11648
  ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
11649
  ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
11650
  # In autoconf-2.13 it is called $ac_given_srcdir.
11651
  # In autoconf-2.50 it is called $srcdir.
11652
  test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
11653
  case "$ac_given_srcdir" in
11654
    .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
11655
    /*) top_srcdir="$ac_given_srcdir" ;;
11656
    *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
11657
  esac
11658
11659
  # Find a way to echo strings without interpreting backslash.
11660
  if test "X`(echo '\t') 2>/dev/null`" = 'X\t'; then
11661
    gt_echo='echo'
11662
  else
11663
    if test "X`(printf '%s\n' '\t') 2>/dev/null`" = 'X\t'; then
11664
      gt_echo='printf %s\n'
11665
    else
11666
      echo_func () {
11667
        cat <<EOT
11668
$*
11669
EOT
11670
      }
11671
      gt_echo='echo_func'
11672
    fi
11673
  fi
11674
11675
  # A sed script that extracts the value of VARIABLE from a Makefile.
11676
  sed_x_variable='
11677
# Test if the hold space is empty.
11678
x
11679
s/P/P/
11680
x
11681
ta
11682
# Yes it was empty. Look if we have the expected variable definition.
11683
/^[	 ]*VARIABLE[	 ]*=/{
11684
  # Seen the first line of the variable definition.
11685
  s/^[	 ]*VARIABLE[	 ]*=//
11686
  ba
11687
}
11688
bd
11689
:a
11690
# Here we are processing a line from the variable definition.
11691
# Remove comment, more precisely replace it with a space.
11692
s/#.*$/ /
11693
# See if the line ends in a backslash.
11694
tb
11695
:b
11696
s/\\$//
11697
# Print the line, without the trailing backslash.
11698
p
11699
tc
11700
# There was no trailing backslash. The end of the variable definition is
11701
# reached. Clear the hold space.
11702
s/^.*$//
11703
x
11704
bd
11705
:c
11706
# A trailing backslash means that the variable definition continues in the
11707
# next line. Put a nonempty string into the hold space to indicate this.
11708
s/^.*$/P/
11709
x
11710
:d
11711
'
11712
changequote([,])dnl
11713
11714
  # Set POTFILES to the value of the Makefile variable POTFILES.
11715
  sed_x_POTFILES=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/POTFILES/g'`
11716
  POTFILES=`sed -n -e "$sed_x_POTFILES" < "$ac_file"`
11717
  # Compute POTFILES_DEPS as
11718
  #   $(foreach file, $(POTFILES), $(top_srcdir)/$(file))
11719
  POTFILES_DEPS=
11720
  for file in $POTFILES; do
11721
    POTFILES_DEPS="$POTFILES_DEPS "'$(top_srcdir)/'"$file"
11722
  done
11723
  POMAKEFILEDEPS=""
11724
11725
  if test -n "$OBSOLETE_ALL_LINGUAS"; then
11726
    test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
11727
  fi
11728
  if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
11729
    # The LINGUAS file contains the set of available languages.
11730
    ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
11731
    POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
11732
  else
11733
    # Set ALL_LINGUAS to the value of the Makefile variable LINGUAS.
11734
    sed_x_LINGUAS=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/LINGUAS/g'`
11735
    ALL_LINGUAS_=`sed -n -e "$sed_x_LINGUAS" < "$ac_file"`
11736
  fi
11737
  # Hide the ALL_LINGUAS assigment from automake < 1.5.
11738
  eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
11739
  # Compute POFILES
11740
  # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
11741
  # Compute UPDATEPOFILES
11742
  # as      $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
11743
  # Compute DUMMYPOFILES
11744
  # as      $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
11745
  # Compute GMOFILES
11746
  # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
11747
  # Compute PROPERTIESFILES
11748
  # as      $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).properties)
11749
  # Compute CLASSFILES
11750
  # as      $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).class)
11751
  # Compute QMFILES
11752
  # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).qm)
11753
  # Compute MSGFILES
11754
  # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang)).msg)
11755
  # Compute RESOURCESDLLFILES
11756
  # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang))/$(DOMAIN).resources.dll)
11757
  case "$ac_given_srcdir" in
11758
    .) srcdirpre= ;;
11759
    *) srcdirpre='$(srcdir)/' ;;
11760
  esac
11761
  POFILES=
11762
  UPDATEPOFILES=
11763
  DUMMYPOFILES=
11764
  GMOFILES=
11765
  PROPERTIESFILES=
11766
  CLASSFILES=
11767
  QMFILES=
11768
  MSGFILES=
11769
  RESOURCESDLLFILES=
11770
  for lang in $ALL_LINGUAS; do
11771
    POFILES="$POFILES $srcdirpre$lang.po"
11772
    UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
11773
    DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
11774
    GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
11775
    PROPERTIESFILES="$PROPERTIESFILES \$(top_srcdir)/\$(DOMAIN)_$lang.properties"
11776
    CLASSFILES="$CLASSFILES \$(top_srcdir)/\$(DOMAIN)_$lang.class"
11777
    QMFILES="$QMFILES $srcdirpre$lang.qm"
11778
    frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
11779
    MSGFILES="$MSGFILES $srcdirpre$frobbedlang.msg"
11780
    frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
11781
    RESOURCESDLLFILES="$RESOURCESDLLFILES $srcdirpre$frobbedlang/\$(DOMAIN).resources.dll"
11782
  done
11783
  # CATALOGS depends on both $ac_dir and the user's LINGUAS
11784
  # environment variable.
11785
  INST_LINGUAS=
11786
  if test -n "$ALL_LINGUAS"; then
11787
    for presentlang in $ALL_LINGUAS; do
11788
      useit=no
11789
      if test "%UNSET%" != "$LINGUAS"; then
11790
        desiredlanguages="$LINGUAS"
1.1.20 by Sebastien Bacher
Import upstream version 2.91.2.is.2.32.0
11791
      else
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
11792
        desiredlanguages="$ALL_LINGUAS"
11793
      fi
11794
      for desiredlang in $desiredlanguages; do
11795
        # Use the presentlang catalog if desiredlang is
11796
        #   a. equal to presentlang, or
11797
        #   b. a variant of presentlang (because in this case,
11798
        #      presentlang can be used as a fallback for messages
11799
        #      which are not translated in the desiredlang catalog).
11800
        case "$desiredlang" in
11801
          "$presentlang"*) useit=yes;;
11802
        esac
11803
      done
11804
      if test $useit = yes; then
11805
        INST_LINGUAS="$INST_LINGUAS $presentlang"
11806
      fi
11807
    done
11808
  fi
11809
  CATALOGS=
11810
  JAVACATALOGS=
11811
  QTCATALOGS=
11812
  TCLCATALOGS=
11813
  CSHARPCATALOGS=
11814
  if test -n "$INST_LINGUAS"; then
11815
    for lang in $INST_LINGUAS; do
11816
      CATALOGS="$CATALOGS $lang.gmo"
11817
      JAVACATALOGS="$JAVACATALOGS \$(DOMAIN)_$lang.properties"
11818
      QTCATALOGS="$QTCATALOGS $lang.qm"
11819
      frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
11820
      TCLCATALOGS="$TCLCATALOGS $frobbedlang.msg"
11821
      frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
11822
      CSHARPCATALOGS="$CSHARPCATALOGS $frobbedlang/\$(DOMAIN).resources.dll"
11823
    done
11824
  fi
11825
11826
  sed -e "s|@POTFILES_DEPS@|$POTFILES_DEPS|g" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@PROPERTIESFILES@|$PROPERTIESFILES|g" -e "s|@CLASSFILES@|$CLASSFILES|g" -e "s|@QMFILES@|$QMFILES|g" -e "s|@MSGFILES@|$MSGFILES|g" -e "s|@RESOURCESDLLFILES@|$RESOURCESDLLFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@JAVACATALOGS@|$JAVACATALOGS|g" -e "s|@QTCATALOGS@|$QTCATALOGS|g" -e "s|@TCLCATALOGS@|$TCLCATALOGS|g" -e "s|@CSHARPCATALOGS@|$CSHARPCATALOGS|g" -e 's,^#distdir:,distdir:,' < "$ac_file" > "$ac_file.tmp"
11827
  if grep -l '@TCLCATALOGS@' "$ac_file" > /dev/null; then
11828
    # Add dependencies that cannot be formulated as a simple suffix rule.
11829
    for lang in $ALL_LINGUAS; do
11830
      frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
11831
      cat >> "$ac_file.tmp" <<EOF
11832
$frobbedlang.msg: $lang.po
11833
	@echo "\$(MSGFMT) -c --tcl -d \$(srcdir) -l $lang $srcdirpre$lang.po"; \
11834
	\$(MSGFMT) -c --tcl -d "\$(srcdir)" -l $lang $srcdirpre$lang.po || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
11835
EOF
11836
    done
11837
  fi
11838
  if grep -l '@CSHARPCATALOGS@' "$ac_file" > /dev/null; then
11839
    # Add dependencies that cannot be formulated as a simple suffix rule.
11840
    for lang in $ALL_LINGUAS; do
11841
      frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
11842
      cat >> "$ac_file.tmp" <<EOF
11843
$frobbedlang/\$(DOMAIN).resources.dll: $lang.po
11844
	@echo "\$(MSGFMT) -c --csharp -d \$(srcdir) -l $lang $srcdirpre$lang.po -r \$(DOMAIN)"; \
11845
	\$(MSGFMT) -c --csharp -d "\$(srcdir)" -l $lang $srcdirpre$lang.po -r "\$(DOMAIN)" || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
11846
EOF
11847
    done
11848
  fi
11849
  if test -n "$POMAKEFILEDEPS"; then
11850
    cat >> "$ac_file.tmp" <<EOF
11851
Makefile: $POMAKEFILEDEPS
11852
EOF
11853
  fi
11854
  mv "$ac_file.tmp" "$ac_file"
11855
])
11856
11857
dnl Initializes the accumulator used by AM_XGETTEXT_OPTION.
11858
AC_DEFUN([AM_XGETTEXT_OPTION_INIT],
11859
[
11860
  XGETTEXT_EXTRA_OPTIONS=
11861
])
11862
11863
dnl Registers an option to be passed to xgettext in the po subdirectory.
11864
AC_DEFUN([AM_XGETTEXT_OPTION],
11865
[
11866
  AC_REQUIRE([AM_XGETTEXT_OPTION_INIT])
11867
  XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS $1"
11868
])
11869
11870
# progtest.m4 serial 6 (gettext-0.18)
11871
dnl Copyright (C) 1996-2003, 2005, 2008-2010 Free Software Foundation, Inc.
11872
dnl This file is free software; the Free Software Foundation
11873
dnl gives unlimited permission to copy and/or distribute it,
11874
dnl with or without modifications, as long as this notice is preserved.
11875
dnl
11876
dnl This file can can be used in projects which are not available under
11877
dnl the GNU General Public License or the GNU Library General Public
11878
dnl License but which still want to provide support for the GNU gettext
11879
dnl functionality.
11880
dnl Please note that the actual code of the GNU gettext library is covered
11881
dnl by the GNU Library General Public License, and the rest of the GNU
11882
dnl gettext package package is covered by the GNU General Public License.
11883
dnl They are *not* in the public domain.
11884
11885
dnl Authors:
11886
dnl   Ulrich Drepper <drepper@cygnus.com>, 1996.
11887
11888
AC_PREREQ([2.50])
11889
11890
# Search path for a program which passes the given test.
11891
11892
dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
11893
dnl   TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
11894
AC_DEFUN([AM_PATH_PROG_WITH_TEST],
11895
[
11896
# Prepare PATH_SEPARATOR.
11897
# The user is always right.
11898
if test "${PATH_SEPARATOR+set}" != set; then
11899
  echo "#! /bin/sh" >conf$$.sh
11900
  echo  "exit 0"   >>conf$$.sh
11901
  chmod +x conf$$.sh
11902
  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
11903
    PATH_SEPARATOR=';'
11904
  else
11905
    PATH_SEPARATOR=:
11906
  fi
11907
  rm -f conf$$.sh
11908
fi
11909
11910
# Find out how to test for executable files. Don't use a zero-byte file,
11911
# as systems may use methods other than mode bits to determine executability.
11912
cat >conf$$.file <<_ASEOF
11913
#! /bin/sh
11914
exit 0
11915
_ASEOF
11916
chmod +x conf$$.file
11917
if test -x conf$$.file >/dev/null 2>&1; then
11918
  ac_executable_p="test -x"
11919
else
11920
  ac_executable_p="test -f"
11921
fi
11922
rm -f conf$$.file
11923
11924
# Extract the first word of "$2", so it can be a program name with args.
11925
set dummy $2; ac_word=[$]2
11926
AC_MSG_CHECKING([for $ac_word])
11927
AC_CACHE_VAL([ac_cv_path_$1],
11928
[case "[$]$1" in
11929
  [[\\/]]* | ?:[[\\/]]*)
11930
    ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
11931
    ;;
11932
  *)
11933
    ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
11934
    for ac_dir in ifelse([$5], , $PATH, [$5]); do
11935
      IFS="$ac_save_IFS"
11936
      test -z "$ac_dir" && ac_dir=.
11937
      for ac_exec_ext in '' $ac_executable_extensions; do
11938
        if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
11939
          echo "$as_me: trying $ac_dir/$ac_word..." >&AS_MESSAGE_LOG_FD
11940
          if [$3]; then
11941
            ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext"
11942
            break 2
11943
          fi
11944
        fi
11945
      done
11946
    done
11947
    IFS="$ac_save_IFS"
11948
dnl If no 4th arg is given, leave the cache variable unset,
11949
dnl so AC_PATH_PROGS will keep looking.
11950
ifelse([$4], , , [  test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
11951
])dnl
11952
    ;;
11953
esac])dnl
11954
$1="$ac_cv_path_$1"
11955
if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
11956
  AC_MSG_RESULT([$][$1])
11957
else
11958
  AC_MSG_RESULT([no])
11959
fi
11960
AC_SUBST([$1])dnl
11961
])
11962
1.1.24 by Chris Coulson
Import upstream version 3.1.4
11963
# gnome-common.m4
11964
#
11965
# serial 3
11966
# 
11967
11968
dnl GNOME_COMMON_INIT
11969
11970
AU_DEFUN([GNOME_COMMON_INIT],
11971
[
11972
  dnl this macro should come after AC_CONFIG_MACRO_DIR
11973
  AC_BEFORE([AC_CONFIG_MACRO_DIR], [$0])
11974
11975
  dnl ensure that when the Automake generated makefile calls aclocal,
11976
  dnl it honours the $ACLOCAL_FLAGS environment variable
11977
  ACLOCAL_AMFLAGS="\${ACLOCAL_FLAGS}"
11978
  if test -n "$ac_macro_dir"; then
11979
    ACLOCAL_AMFLAGS="-I $ac_macro_dir $ACLOCAL_AMFLAGS"
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
11980
  fi
1.1.24 by Chris Coulson
Import upstream version 3.1.4
11981
11982
  AC_SUBST([ACLOCAL_AMFLAGS])
11983
],
11984
[[$0: This macro is deprecated. You should set put "ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}"
11985
in your top-level Makefile.am, instead, where "m4" is the macro directory set
11986
with AC_CONFIG_MACRO_DIR() in your configure.ac]])
11987
11988
AC_DEFUN([GNOME_DEBUG_CHECK],
11989
[
11990
	AC_ARG_ENABLE([debug],
11991
                      AC_HELP_STRING([--enable-debug],
11992
                                     [turn on debugging]),,
11993
                      [enable_debug=no])
11994
11995
	if test x$enable_debug = xyes ; then
11996
	    AC_DEFINE(GNOME_ENABLE_DEBUG, 1,
11997
		[Enable additional debugging at the expense of performance and size])
11998
	fi
11999
])
12000
12001
dnl GNOME_MAINTAINER_MODE_DEFINES ()
12002
dnl define DISABLE_DEPRECATED
12003
dnl
12004
AC_DEFUN([GNOME_MAINTAINER_MODE_DEFINES],
12005
[
12006
	AC_REQUIRE([AM_MAINTAINER_MODE])
12007
12008
	DISABLE_DEPRECATED=""
12009
	if test $USE_MAINTAINER_MODE = yes; then
12010
	        DOMAINS="G ATK PANGO GDK GDK_PIXBUF GTK GCONF BONOBO BONOBO_UI GNOME LIBGLADE VTE GNOME_VFS WNCK LIBSOUP"
12011
	        for DOMAIN in $DOMAINS; do
12012
	               DISABLE_DEPRECATED="$DISABLE_DEPRECATED -D${DOMAIN}_DISABLE_DEPRECATED -D${DOMAIN}_DISABLE_SINGLE_INCLUDES"
12013
	        done
12014
	fi
12015
12016
	AC_SUBST(DISABLE_DEPRECATED)
12017
])
12018
12019
dnl GNOME_COMPILE_WARNINGS
12020
dnl Turn on many useful compiler warnings
12021
dnl For now, only works on GCC
12022
AC_DEFUN([GNOME_COMPILE_WARNINGS],[
12023
    dnl ******************************
12024
    dnl More compiler warnings
12025
    dnl ******************************
12026
12027
    AC_ARG_ENABLE(compile-warnings, 
12028
                  AC_HELP_STRING([--enable-compile-warnings=@<:@no/minimum/yes/maximum/error@:>@],
12029
                                 [Turn on compiler warnings]),,
12030
                  [enable_compile_warnings="m4_default([$1],[yes])"])
12031
12032
    warnCFLAGS=
12033
    if test "x$GCC" != xyes; then
12034
	enable_compile_warnings=no
12035
    fi
12036
12037
    warning_flags=
12038
    realsave_CFLAGS="$CFLAGS"
12039
12040
    case "$enable_compile_warnings" in
12041
    no)
12042
	warning_flags=
12043
	;;
12044
    minimum)
12045
	warning_flags="-Wall"
12046
	;;
12047
    yes)
12048
	warning_flags="-Wall -Wmissing-prototypes"
12049
	;;
12050
    maximum|error)
12051
	warning_flags="-Wall -Wmissing-prototypes -Wnested-externs -Wpointer-arith"
12052
	CFLAGS="$warning_flags $CFLAGS"
12053
	for option in -Wno-sign-compare; do
12054
		SAVE_CFLAGS="$CFLAGS"
12055
		CFLAGS="$CFLAGS $option"
12056
		AC_MSG_CHECKING([whether gcc understands $option])
12057
		AC_TRY_COMPILE([], [],
12058
			has_option=yes,
12059
			has_option=no,)
12060
		CFLAGS="$SAVE_CFLAGS"
12061
		AC_MSG_RESULT($has_option)
12062
		if test $has_option = yes; then
12063
		  warning_flags="$warning_flags $option"
12064
		fi
12065
		unset has_option
12066
		unset SAVE_CFLAGS
12067
	done
12068
	unset option
12069
	if test "$enable_compile_warnings" = "error" ; then
12070
	    warning_flags="$warning_flags -Werror"
12071
	fi
12072
	;;
12073
    *)
12074
	AC_MSG_ERROR(Unknown argument '$enable_compile_warnings' to --enable-compile-warnings)
12075
	;;
1.1.20 by Sebastien Bacher
Import upstream version 2.91.2.is.2.32.0
12076
    esac
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12077
    CFLAGS="$realsave_CFLAGS"
12078
    AC_MSG_CHECKING(what warning flags to pass to the C compiler)
12079
    AC_MSG_RESULT($warning_flags)
12080
12081
    AC_ARG_ENABLE(iso-c,
12082
                  AC_HELP_STRING([--enable-iso-c],
12083
                                 [Try to warn if code is not ISO C ]),,
12084
                  [enable_iso_c=no])
12085
12086
    AC_MSG_CHECKING(what language compliance flags to pass to the C compiler)
12087
    complCFLAGS=
12088
    if test "x$enable_iso_c" != "xno"; then
12089
	if test "x$GCC" = "xyes"; then
12090
	case " $CFLAGS " in
12091
	    *[\ \	]-ansi[\ \	]*) ;;
12092
	    *) complCFLAGS="$complCFLAGS -ansi" ;;
12093
	esac
12094
	case " $CFLAGS " in
12095
	    *[\ \	]-pedantic[\ \	]*) ;;
12096
	    *) complCFLAGS="$complCFLAGS -pedantic" ;;
12097
	esac
12098
	fi
12099
    fi
12100
    AC_MSG_RESULT($complCFLAGS)
12101
12102
    WARN_CFLAGS="$warning_flags $complCFLAGS"
12103
    AC_SUBST(WARN_CFLAGS)
12104
])
12105
12106
dnl For C++, do basically the same thing.
12107
12108
AC_DEFUN([GNOME_CXX_WARNINGS],[
12109
  AC_ARG_ENABLE(cxx-warnings,
12110
                AC_HELP_STRING([--enable-cxx-warnings=@<:@no/minimum/yes@:>@]
12111
                               [Turn on compiler warnings.]),,
12112
                [enable_cxx_warnings="m4_default([$1],[minimum])"])
12113
12114
  AC_MSG_CHECKING(what warning flags to pass to the C++ compiler)
12115
  warnCXXFLAGS=
12116
  if test "x$GXX" != xyes; then
12117
    enable_cxx_warnings=no
12118
  fi
12119
  if test "x$enable_cxx_warnings" != "xno"; then
12120
    if test "x$GXX" = "xyes"; then
12121
      case " $CXXFLAGS " in
12122
      *[\ \	]-Wall[\ \	]*) ;;
12123
      *) warnCXXFLAGS="-Wall -Wno-unused" ;;
12124
      esac
12125
12126
      ## -W is not all that useful.  And it cannot be controlled
12127
      ## with individual -Wno-xxx flags, unlike -Wall
12128
      if test "x$enable_cxx_warnings" = "xyes"; then
12129
	warnCXXFLAGS="$warnCXXFLAGS -Wshadow -Woverloaded-virtual"
1.1.20 by Sebastien Bacher
Import upstream version 2.91.2.is.2.32.0
12130
      fi
12131
    fi
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12132
  fi
12133
  AC_MSG_RESULT($warnCXXFLAGS)
12134
12135
   AC_ARG_ENABLE(iso-cxx,
12136
                 AC_HELP_STRING([--enable-iso-cxx],
12137
                                [Try to warn if code is not ISO C++ ]),,
12138
                 [enable_iso_cxx=no])
12139
12140
   AC_MSG_CHECKING(what language compliance flags to pass to the C++ compiler)
12141
   complCXXFLAGS=
12142
   if test "x$enable_iso_cxx" != "xno"; then
12143
     if test "x$GXX" = "xyes"; then
12144
      case " $CXXFLAGS " in
12145
      *[\ \	]-ansi[\ \	]*) ;;
12146
      *) complCXXFLAGS="$complCXXFLAGS -ansi" ;;
12147
      esac
12148
12149
      case " $CXXFLAGS " in
12150
      *[\ \	]-pedantic[\ \	]*) ;;
12151
      *) complCXXFLAGS="$complCXXFLAGS -pedantic" ;;
12152
      esac
12153
     fi
12154
   fi
12155
  AC_MSG_RESULT($complCXXFLAGS)
12156
12157
  WARN_CXXFLAGS="$CXXFLAGS $warnCXXFLAGS $complCXXFLAGS"
12158
  AC_SUBST(WARN_CXXFLAGS)
12159
])
12160
12161
dnl Do not call GNOME_DOC_DEFINES directly.  It is split out from
12162
dnl GNOME_DOC_INIT to allow gnome-doc-utils to bootstrap off itself.
12163
AC_DEFUN([GNOME_DOC_DEFINES],
12164
[
12165
AC_ARG_WITH([help-dir],
12166
  AC_HELP_STRING([--with-help-dir=DIR], [path to help docs]),,
12167
  [with_help_dir='${datadir}/gnome/help'])
12168
HELP_DIR="$with_help_dir"
12169
AC_SUBST(HELP_DIR)
12170
12171
AC_ARG_WITH([omf-dir],
12172
  AC_HELP_STRING([--with-omf-dir=DIR], [path to OMF files]),,
12173
  [with_omf_dir='${datadir}/omf'])
12174
OMF_DIR="$with_omf_dir"
12175
AC_SUBST(OMF_DIR)
12176
12177
AC_ARG_WITH([help-formats],
12178
  AC_HELP_STRING([--with-help-formats=FORMATS], [list of formats]),,
12179
  [with_help_formats=''])
12180
DOC_USER_FORMATS="$with_help_formats"
12181
AC_SUBST(DOC_USER_FORMATS)
12182
12183
AC_ARG_ENABLE([scrollkeeper],
12184
	[AC_HELP_STRING([--disable-scrollkeeper],
12185
			[do not make updates to the scrollkeeper database])],,
12186
	enable_scrollkeeper=yes)
12187
AM_CONDITIONAL([ENABLE_SK],[test "$gdu_cv_have_gdu" = "yes" -a "$enable_scrollkeeper" = "yes"])
12188
12189
dnl disable scrollkeeper automatically for distcheck
12190
DISTCHECK_CONFIGURE_FLAGS="--disable-scrollkeeper $DISTCHECK_CONFIGURE_FLAGS"
12191
AC_SUBST(DISTCHECK_CONFIGURE_FLAGS)
12192
12193
AM_CONDITIONAL([HAVE_GNOME_DOC_UTILS],[test "$gdu_cv_have_gdu" = "yes"])
12194
])
12195
12196
# GNOME_DOC_INIT ([MINIMUM-VERSION],[ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND])
12197
#
12198
AC_DEFUN([GNOME_DOC_INIT],
12199
[AC_REQUIRE([AC_PROG_LN_S])dnl
12200
12201
ifelse([$1],,[gdu_cv_version_required=0.3.2],[gdu_cv_version_required=$1])
12202
12203
AC_MSG_CHECKING([gnome-doc-utils >= $gdu_cv_version_required])
12204
PKG_CHECK_EXISTS([gnome-doc-utils >= $gdu_cv_version_required],
12205
	[gdu_cv_have_gdu=yes],[gdu_cv_have_gdu=no])
12206
12207
if test "$gdu_cv_have_gdu" = "yes"; then
12208
	AC_MSG_RESULT([yes])
12209
	ifelse([$2],,[:],[$2])
12210
else
12211
	AC_MSG_RESULT([no])
12212
	ifelse([$3],,[AC_MSG_ERROR([gnome-doc-utils >= $gdu_cv_version_required not found])],[$3])
12213
fi
12214
12215
GNOME_DOC_DEFINES
12216
])
12217
12218
dnl GLIB_GSETTINGS
12219
dnl Defines GSETTINGS_SCHEMAS_INSTALL which controls whether
12220
dnl the schema should be compiled
12221
dnl
12222
12223
AC_DEFUN([GLIB_GSETTINGS],
12224
[
12225
  m4_pattern_allow([AM_V_GEN])
12226
  AC_ARG_ENABLE(schemas-compile,
12227
                AS_HELP_STRING([--disable-schemas-compile],
12228
                               [Disable regeneration of gschemas.compiled on install]),
12229
                [case ${enableval} in
12230
                  yes) GSETTINGS_DISABLE_SCHEMAS_COMPILE=""  ;;
12231
                  no)  GSETTINGS_DISABLE_SCHEMAS_COMPILE="1" ;;
12232
                  *) AC_MSG_ERROR([bad value ${enableval} for --enable-schemas-compile]) ;;
12233
                 esac])
12234
  AC_SUBST([GSETTINGS_DISABLE_SCHEMAS_COMPILE])
12235
  PKG_PROG_PKG_CONFIG([0.16])
12236
  AC_SUBST(gsettingsschemadir, [${datadir}/glib-2.0/schemas])
12237
  if test x$cross_compiling != xyes; then
12238
    GLIB_COMPILE_SCHEMAS=`$PKG_CONFIG --variable glib_compile_schemas gio-2.0`
12239
  else
12240
    AC_PATH_PROG(GLIB_COMPILE_SCHEMAS, glib-compile-schemas)
12241
  fi
12242
  AC_SUBST(GLIB_COMPILE_SCHEMAS)
12243
  if test "x$GLIB_COMPILE_SCHEMAS" = "x"; then
12244
    ifelse([$2],,[AC_MSG_ERROR([glib-compile-schemas not found.])],[$2])
12245
  else
12246
    ifelse([$1],,[:],[$1])
12247
  fi
12248
12249
  GSETTINGS_RULES='
12250
.PHONY : uninstall-gsettings-schemas install-gsettings-schemas clean-gsettings-schemas
12251
12252
mostlyclean-am: clean-gsettings-schemas
12253
12254
gsettings__enum_file = $(addsuffix .enums.xml,$(gsettings_ENUM_NAMESPACE))
12255
12256
%.gschema.valid: %.gschema.xml $(gsettings__enum_file)
12257
	$(AM_V_GEN) if test -f "$<"; then d=; else d="$(srcdir)/"; fi; $(GLIB_COMPILE_SCHEMAS) --strict --dry-run $(addprefix --schema-file=,$(gsettings__enum_file)) --schema-file=$${d}$< && touch [$]@
12258
12259
all-am: $(gsettings_SCHEMAS:.xml=.valid)
12260
uninstall-am: uninstall-gsettings-schemas
12261
install-data-am: install-gsettings-schemas
12262
12263
.SECONDARY: $(gsettings_SCHEMAS)
12264
12265
install-gsettings-schemas: $(gsettings_SCHEMAS) $(gsettings__enum_file)
12266
	@$(NORMAL_INSTALL)
12267
	if test -n "$^"; then \
12268
		test -z "$(gsettingsschemadir)" || $(MKDIR_P) "$(DESTDIR)$(gsettingsschemadir)"; \
12269
		$(INSTALL_DATA) $^ "$(DESTDIR)$(gsettingsschemadir)"; \
12270
		test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir); \
12271
	fi
12272
12273
uninstall-gsettings-schemas:
12274
	@$(NORMAL_UNINSTALL)
12275
	@list='\''$(gsettings_SCHEMAS) $(gsettings__enum_file)'\''; test -n "$(gsettingsschemadir)" || list=; \
12276
	files=`for p in $$list; do echo $$p; done | sed -e '\''s|^.*/||'\''`; \
12277
	test -n "$$files" || exit 0; \
12278
	echo " ( cd '\''$(DESTDIR)$(gsettingsschemadir)'\'' && rm -f" $$files ")"; \
12279
	cd "$(DESTDIR)$(gsettingsschemadir)" && rm -f $$files
12280
	test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir)
12281
12282
clean-gsettings-schemas:
12283
	rm -f $(gsettings_SCHEMAS:.xml=.valid) $(gsettings__enum_file)
12284
12285
ifdef gsettings_ENUM_NAMESPACE
12286
$(gsettings__enum_file): $(gsettings_ENUM_FILES)
12287
	$(AM_V_GEN) glib-mkenums --comments '\''<!-- @comment@ -->'\'' --fhead "<schemalist>" --vhead "  <@type@ id='\''$(gsettings_ENUM_NAMESPACE).@EnumName@'\''>" --vprod "    <value nick='\''@valuenick@'\'' value='\''@valuenum@'\''/>" --vtail "  </@type@>" --ftail "</schemalist>" [$]^ > [$]@.tmp && mv [$]@.tmp [$]@
12288
endif
1.4.1 by Emilio Pozuelo Monfort
Import upstream version 2.91.5
12289
'
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12290
  _GSETTINGS_SUBST(GSETTINGS_RULES)
12291
])
12292
12293
dnl _GSETTINGS_SUBST(VARIABLE)
12294
dnl Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
12295
AC_DEFUN([_GSETTINGS_SUBST],
12296
[
12297
AC_SUBST([$1])
12298
m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
12299
]
12300
)
12301
12302
dnl -*- mode: autoconf -*-
12303
12304
# serial 1
12305
12306
dnl Usage:
12307
dnl   GTK_DOC_CHECK([minimum-gtk-doc-version])
12308
AC_DEFUN([GTK_DOC_CHECK],
12309
[
12310
  AC_REQUIRE([PKG_PROG_PKG_CONFIG])
12311
  AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
12312
  AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
12313
12314
  dnl check for tools we added during development
12315
  AC_PATH_PROG([GTKDOC_CHECK],[gtkdoc-check])
12316
  AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true])
12317
  AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf])
12318
12319
  dnl for overriding the documentation installation directory
12320
  AC_ARG_WITH([html-dir],
12321
    AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
12322
    [with_html_dir='${datadir}/gtk-doc/html'])
12323
  HTML_DIR="$with_html_dir"
12324
  AC_SUBST([HTML_DIR])
12325
12326
  dnl enable/disable documentation building
12327
  AC_ARG_ENABLE([gtk-doc],
12328
    AS_HELP_STRING([--enable-gtk-doc],
12329
                   [use gtk-doc to build documentation [[default=no]]]),,
12330
    [enable_gtk_doc=no])
12331
12332
  if test x$enable_gtk_doc = xyes; then
12333
    ifelse([$1],[],
12334
      [PKG_CHECK_EXISTS([gtk-doc],,
12335
                        AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))],
12336
      [PKG_CHECK_EXISTS([gtk-doc >= $1],,
12337
                        AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build $PACKAGE_NAME]))])
12338
    PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0)
12339
  fi
12340
12341
  AC_MSG_CHECKING([whether to build gtk-doc documentation])
12342
  AC_MSG_RESULT($enable_gtk_doc)
12343
12344
  dnl enable/disable output formats
12345
  AC_ARG_ENABLE([gtk-doc-html],
12346
    AS_HELP_STRING([--enable-gtk-doc-html],
12347
                   [build documentation in html format [[default=yes]]]),,
12348
    [enable_gtk_doc_html=yes])
12349
    AC_ARG_ENABLE([gtk-doc-pdf],
12350
      AS_HELP_STRING([--enable-gtk-doc-pdf],
12351
                     [build documentation in pdf format [[default=no]]]),,
12352
      [enable_gtk_doc_pdf=no])
12353
12354
  if test -z "$GTKDOC_MKPDF"; then
12355
    enable_gtk_doc_pdf=no
12356
  fi
12357
12358
12359
  AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
12360
  AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
12361
  AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])
12362
  AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"])
12363
  AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"])
12364
])
12365
12366
12367
dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
12368
# serial 40 IT_PROG_INTLTOOL
12369
AC_DEFUN([IT_PROG_INTLTOOL], [
12370
AC_PREREQ([2.50])dnl
12371
AC_REQUIRE([AM_NLS])dnl
12372
12373
case "$am__api_version" in
12374
    1.[01234])
12375
	AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
12376
    ;;
12377
    *)
12378
    ;;
12379
esac
12380
12381
if test -n "$1"; then
12382
    AC_MSG_CHECKING([for intltool >= $1])
12383
12384
    INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
12385
    INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
12386
    [INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
12387
    ]
12388
    AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
12389
    test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
12390
	AC_MSG_ERROR([Your intltool is too old.  You need intltool $1 or later.])
12391
fi
12392
12393
AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
12394
AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
12395
AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
12396
if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
12397
    AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
12398
fi
12399
12400
  INTLTOOL_DESKTOP_RULE='%.desktop:   %.desktop.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12401
INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12402
     INTLTOOL_KEYS_RULE='%.keys:      %.keys.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12403
     INTLTOOL_PROP_RULE='%.prop:      %.prop.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12404
      INTLTOOL_OAF_RULE='%.oaf:       %.oaf.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -p $(top_srcdir)/po $< [$]@'
12405
     INTLTOOL_PONG_RULE='%.pong:      %.pong.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12406
   INTLTOOL_SERVER_RULE='%.server:    %.server.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12407
    INTLTOOL_SHEET_RULE='%.sheet:     %.sheet.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12408
INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12409
       INTLTOOL_UI_RULE='%.ui:        %.ui.in        $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12410
      INTLTOOL_XML_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12411
      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< [$]@' 
12412
      INTLTOOL_XAM_RULE='%.xam:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12413
      INTLTOOL_KBD_RULE='%.kbd:       %.kbd.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12414
    INTLTOOL_CAVES_RULE='%.caves:     %.caves.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12415
  INTLTOOL_SCHEMAS_RULE='%.schemas:   %.schemas.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12416
    INTLTOOL_THEME_RULE='%.theme:     %.theme.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
12417
    INTLTOOL_SERVICE_RULE='%.service: %.service.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
12418
   INTLTOOL_POLICY_RULE='%.policy:    %.policy.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
12419
12420
_IT_SUBST(INTLTOOL_DESKTOP_RULE)
12421
_IT_SUBST(INTLTOOL_DIRECTORY_RULE)
12422
_IT_SUBST(INTLTOOL_KEYS_RULE)
12423
_IT_SUBST(INTLTOOL_PROP_RULE)
12424
_IT_SUBST(INTLTOOL_OAF_RULE)
12425
_IT_SUBST(INTLTOOL_PONG_RULE)
12426
_IT_SUBST(INTLTOOL_SERVER_RULE)
12427
_IT_SUBST(INTLTOOL_SHEET_RULE)
12428
_IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
12429
_IT_SUBST(INTLTOOL_UI_RULE)
12430
_IT_SUBST(INTLTOOL_XAM_RULE)
12431
_IT_SUBST(INTLTOOL_KBD_RULE)
12432
_IT_SUBST(INTLTOOL_XML_RULE)
12433
_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
12434
_IT_SUBST(INTLTOOL_CAVES_RULE)
12435
_IT_SUBST(INTLTOOL_SCHEMAS_RULE)
12436
_IT_SUBST(INTLTOOL_THEME_RULE)
12437
_IT_SUBST(INTLTOOL_SERVICE_RULE)
12438
_IT_SUBST(INTLTOOL_POLICY_RULE)
12439
12440
# Check the gettext tools to make sure they are GNU
12441
AC_PATH_PROG(XGETTEXT, xgettext)
12442
AC_PATH_PROG(MSGMERGE, msgmerge)
12443
AC_PATH_PROG(MSGFMT, msgfmt)
12444
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
12445
if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
12446
    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
12447
fi
12448
xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
12449
mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
12450
mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
12451
if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
12452
    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
12453
fi
12454
12455
AC_PATH_PROG(INTLTOOL_PERL, perl)
12456
if test -z "$INTLTOOL_PERL"; then
12457
   AC_MSG_ERROR([perl not found])
12458
fi
12459
AC_MSG_CHECKING([for perl >= 5.8.1])
12460
$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
12461
if test $? -ne 0; then
12462
   AC_MSG_ERROR([perl 5.8.1 is required for intltool])
1.1.23 by Sebastien Bacher
Import upstream version 3.1.3
12463
else
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12464
   IT_PERL_VERSION="`$INTLTOOL_PERL -e \"printf '%vd', $^V\"`"
12465
   AC_MSG_RESULT([$IT_PERL_VERSION])
12466
fi
12467
if test "x$2" != "xno-xml"; then
12468
   AC_MSG_CHECKING([for XML::Parser])
12469
   if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
12470
       AC_MSG_RESULT([ok])
12471
   else
12472
       AC_MSG_ERROR([XML::Parser perl module is required for intltool])
12473
   fi
12474
fi
12475
12476
# Substitute ALL_LINGUAS so we can use it in po/Makefile
12477
AC_SUBST(ALL_LINGUAS)
12478
12479
# Set DATADIRNAME correctly if it is not set yet
12480
# (copied from glib-gettext.m4)
12481
if test -z "$DATADIRNAME"; then
12482
  AC_LINK_IFELSE(
12483
    [AC_LANG_PROGRAM([[]],
12484
                     [[extern int _nl_msg_cat_cntr;
12485
                       return _nl_msg_cat_cntr]])],
12486
    [DATADIRNAME=share],
12487
    [case $host in
12488
    *-*-solaris*)
12489
    dnl On Solaris, if bind_textdomain_codeset is in libc,
12490
    dnl GNU format message catalog is always supported,
12491
    dnl since both are added to the libc all together.
12492
    dnl Hence, we'd like to go with DATADIRNAME=share
12493
    dnl in this case.
12494
    AC_CHECK_FUNC(bind_textdomain_codeset,
12495
      [DATADIRNAME=share], [DATADIRNAME=lib])
12496
    ;;
12497
    *)
12498
    [DATADIRNAME=lib]
12499
    ;;
12500
    esac])
12501
fi
12502
AC_SUBST(DATADIRNAME)
12503
12504
IT_PO_SUBDIR([po])
12505
1.1.9 by Alexander Sack
Import upstream version 2.27.90
12506
])
12507
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
12508
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12509
# IT_PO_SUBDIR(DIRNAME)
1.1.4 by Evan Dandrea
Import upstream version 0.9.0
12510
# ---------------------
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12511
# All po subdirs have to be declared with this macro; the subdir "po" is
12512
# declared by IT_PROG_INTLTOOL.
12513
#
12514
AC_DEFUN([IT_PO_SUBDIR],
12515
[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
12516
dnl
12517
dnl The following CONFIG_COMMANDS should be executed at the very end
12518
dnl of config.status.
12519
AC_CONFIG_COMMANDS_PRE([
12520
  AC_CONFIG_COMMANDS([$1/stamp-it], [
12521
    if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
12522
       AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
12523
    fi
12524
    rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
12525
    >"$1/stamp-it.tmp"
12526
    [sed '/^#/d
12527
	 s/^[[].*] *//
12528
	 /^[ 	]*$/d
12529
	'"s|^|	$ac_top_srcdir/|" \
12530
      "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
12531
    ]
12532
    [sed '/^POTFILES =/,/[^\\]$/ {
12533
		/^POTFILES =/!d
12534
		r $1/POTFILES
12535
	  }
12536
	 ' "$1/Makefile.in" >"$1/Makefile"]
12537
    rm -f "$1/Makefile.tmp"
12538
    mv "$1/stamp-it.tmp" "$1/stamp-it"
12539
  ])
12540
])dnl
12541
])
12542
12543
# _IT_SUBST(VARIABLE)
12544
# -------------------
12545
# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
12546
#
12547
AC_DEFUN([_IT_SUBST],
12548
[
12549
AC_SUBST([$1])
12550
m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
12551
]
12552
)
12553
12554
# deprecated macros
12555
AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
12556
# A hint is needed for aclocal from Automake <= 1.9.4:
12557
# AC_DEFUN([AC_PROG_INTLTOOL], ...)
12558
12559
12560
dnl -*- mode: autoconf -*-
12561
dnl Copyright 2009 Johan Dahlin
12562
dnl
12563
dnl This file is free software; the author(s) gives unlimited
12564
dnl permission to copy and/or distribute it, with or without
12565
dnl modifications, as long as this notice is preserved.
12566
dnl
12567
12568
# serial 1
12569
12570
m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
12571
[
12572
    AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
12573
    AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
12574
    AC_BEFORE([LT_INIT],[$0])dnl setup libtool first
12575
12576
    dnl enable/disable introspection
12577
    m4_if([$2], [require],
12578
    [dnl
12579
        enable_introspection=yes
12580
    ],[dnl
12581
        AC_ARG_ENABLE(introspection,
12582
                  AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
12583
                                 [Enable introspection for this build]),, 
12584
                                 [enable_introspection=auto])
12585
    ])dnl
12586
12587
    AC_MSG_CHECKING([for gobject-introspection])
12588
12589
    dnl presence/version checking
12590
    AS_CASE([$enable_introspection],
12591
    [no], [dnl
12592
        found_introspection="no (disabled, use --enable-introspection to enable)"
12593
    ],dnl
12594
    [yes],[dnl
12595
        PKG_CHECK_EXISTS([gobject-introspection-1.0],,
12596
                         AC_MSG_ERROR([gobject-introspection-1.0 is not installed]))
12597
        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1],
12598
                         found_introspection=yes,
12599
                         AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME]))
12600
    ],dnl
12601
    [auto],[dnl
12602
        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
12603
    ],dnl
12604
    [dnl	
12605
        AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@])
12606
    ])dnl
12607
12608
    AC_MSG_RESULT([$found_introspection])
12609
12610
    INTROSPECTION_SCANNER=
12611
    INTROSPECTION_COMPILER=
12612
    INTROSPECTION_GENERATE=
12613
    INTROSPECTION_GIRDIR=
12614
    INTROSPECTION_TYPELIBDIR=
12615
    if test "x$found_introspection" = "xyes"; then
12616
       INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
12617
       INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
12618
       INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
12619
       INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
12620
       INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
12621
       INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
12622
       INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
12623
       INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
12624
    fi
12625
    AC_SUBST(INTROSPECTION_SCANNER)
12626
    AC_SUBST(INTROSPECTION_COMPILER)
12627
    AC_SUBST(INTROSPECTION_GENERATE)
12628
    AC_SUBST(INTROSPECTION_GIRDIR)
12629
    AC_SUBST(INTROSPECTION_TYPELIBDIR)
12630
    AC_SUBST(INTROSPECTION_CFLAGS)
12631
    AC_SUBST(INTROSPECTION_LIBS)
12632
    AC_SUBST(INTROSPECTION_MAKEFILE)
12633
12634
    AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes")
12635
])
12636
12637
12638
dnl Usage:
12639
dnl   GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version])
12640
12641
AC_DEFUN([GOBJECT_INTROSPECTION_CHECK],
12642
[
12643
  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1])
12644
])
12645
12646
dnl Usage:
12647
dnl   GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version])
12648
12649
12650
AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE],
12651
[
12652
  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require])
12653
])
1.1.1 by Daniel Holbach
Import upstream version 0.6.0+cvs2005.09.09
12654
1.1.8 by Alexander Sack
Import upstream version 2.27.8
12655
m4_include([acinclude.m4])