~ubuntu-branches/ubuntu/quantal/libgc/quantal

« back to all changes in this revision

Viewing changes to libatomic_ops-1.2/aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Christoph Egger
  • Date: 2011-03-02 13:43:18 UTC
  • mfrom: (1.2.5 upstream) (3.1.6 sid)
  • Revision ID: james.westby@ubuntu.com-20110302134318-82ful0us5ce82qe8
Tags: 1:7.1-7
* Add ppc64 symbol file (Closes: #615469)
* Add sh4 symbol file (Closes: #614744)
* Add armhf symbol file
* Add powerpcspe symbol file
* Handle sparc64 the same as sparc
* Clear non-arch symbol file to support building on not yet captured
  architectures
* add -pthread to fix build with --no-add-needed

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# generated automatically by aclocal 1.9.3 -*- Autoconf -*-
 
2
 
 
3
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
 
4
# Free Software Foundation, Inc.
 
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.
 
8
 
 
9
# This program is distributed in the hope that it will be useful,
 
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
 
 
14
#                                                        -*- Autoconf -*-
 
15
# Copyright (C) 2002, 2003  Free Software Foundation, Inc.
 
16
# Generated from amversion.in; do not edit by hand.
 
17
 
 
18
# This program is free software; you can redistribute it and/or modify
 
19
# it under the terms of the GNU General Public License as published by
 
20
# the Free Software Foundation; either version 2, or (at your option)
 
21
# any later version.
 
22
 
 
23
# This program is distributed in the hope that it will be useful,
 
24
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
25
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
26
# GNU General Public License for more details.
 
27
 
 
28
# You should have received a copy of the GNU General Public License
 
29
# along with this program; if not, write to the Free Software
 
30
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
31
 
 
32
# AM_AUTOMAKE_VERSION(VERSION)
 
33
# ----------------------------
 
34
# Automake X.Y traces this macro to ensure aclocal.m4 has been
 
35
# generated from the m4 files accompanying Automake X.Y.
 
36
AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.9"])
 
37
 
 
38
# AM_SET_CURRENT_AUTOMAKE_VERSION
 
39
# -------------------------------
 
40
# Call AM_AUTOMAKE_VERSION so it can be traced.
 
41
# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
 
42
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
 
43
         [AM_AUTOMAKE_VERSION([1.9.3])])
 
44
 
 
45
# Figure out how to run the assembler.             -*- Autoconf -*-
 
46
 
 
47
# serial 3
 
48
 
 
49
# Copyright (C) 2001, 2003, 2004 Free Software Foundation, Inc.
 
50
 
 
51
# This program is free software; you can redistribute it and/or modify
 
52
# it under the terms of the GNU General Public License as published by
 
53
# the Free Software Foundation; either version 2, or (at your option)
 
54
# any later version.
 
55
 
 
56
# This program is distributed in the hope that it will be useful,
 
57
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
58
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
59
# GNU General Public License for more details.
 
60
 
 
61
# You should have received a copy of the GNU General Public License
 
62
# along with this program; if not, write to the Free Software
 
63
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
64
# 02111-1307, USA.
 
65
 
 
66
# AM_PROG_AS
 
67
# ----------
 
68
AC_DEFUN([AM_PROG_AS],
 
69
[# By default we simply use the C compiler to build assembly code.
 
70
AC_REQUIRE([AC_PROG_CC])
 
71
test "${CCAS+set}" = set || CCAS=$CC
 
72
test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS
 
73
AC_ARG_VAR([CCAS],      [assembler compiler command (defaults to CC)])
 
74
AC_ARG_VAR([CCASFLAGS], [assembler compiler flags (defaults to CFLAGS)])
 
75
])
 
76
 
 
77
# AM_AUX_DIR_EXPAND
 
78
 
 
79
# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
 
80
 
 
81
# This program is free software; you can redistribute it and/or modify
 
82
# it under the terms of the GNU General Public License as published by
 
83
# the Free Software Foundation; either version 2, or (at your option)
 
84
# any later version.
 
85
 
 
86
# This program is distributed in the hope that it will be useful,
 
87
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
88
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
89
# GNU General Public License for more details.
 
90
 
 
91
# You should have received a copy of the GNU General Public License
 
92
# along with this program; if not, write to the Free Software
 
93
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
94
# 02111-1307, USA.
 
95
 
 
96
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
 
97
# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
 
98
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
 
99
#
 
100
# Of course, Automake must honor this variable whenever it calls a
 
101
# tool from the auxiliary directory.  The problem is that $srcdir (and
 
102
# therefore $ac_aux_dir as well) can be either absolute or relative,
 
103
# depending on how configure is run.  This is pretty annoying, since
 
104
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
 
105
# source directory, any form will work fine, but in subdirectories a
 
106
# relative path needs to be adjusted first.
 
107
#
 
108
# $ac_aux_dir/missing
 
109
#    fails when called from a subdirectory if $ac_aux_dir is relative
 
110
# $top_srcdir/$ac_aux_dir/missing
 
111
#    fails if $ac_aux_dir is absolute,
 
112
#    fails when called from a subdirectory in a VPATH build with
 
113
#          a relative $ac_aux_dir
 
114
#
 
115
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
 
116
# are both prefixed by $srcdir.  In an in-source build this is usually
 
117
# harmless because $srcdir is `.', but things will broke when you
 
118
# start a VPATH build or use an absolute $srcdir.
 
119
#
 
120
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
 
121
# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
 
122
#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
 
123
# and then we would define $MISSING as
 
124
#   MISSING="\${SHELL} $am_aux_dir/missing"
 
125
# This will work as long as MISSING is not called from configure, because
 
126
# unfortunately $(top_srcdir) has no meaning in configure.
 
127
# However there are other variables, like CC, which are often used in
 
128
# configure, and could therefore not use this "fixed" $ac_aux_dir.
 
129
#
 
130
# Another solution, used here, is to always expand $ac_aux_dir to an
 
131
# absolute PATH.  The drawback is that using absolute paths prevent a
 
132
# configured tree to be moved without reconfiguration.
 
133
 
 
134
AC_DEFUN([AM_AUX_DIR_EXPAND],
 
135
[dnl Rely on autoconf to set up CDPATH properly.
 
136
AC_PREREQ([2.50])dnl
 
137
# expand $ac_aux_dir to an absolute path
 
138
am_aux_dir=`cd $ac_aux_dir && pwd`
 
139
])
 
140
 
 
141
# AM_CONDITIONAL                                              -*- Autoconf -*-
 
142
 
 
143
# Copyright (C) 1997, 2000, 2001, 2003, 2004 Free Software Foundation, Inc.
 
144
 
 
145
# This program is free software; you can redistribute it and/or modify
 
146
# it under the terms of the GNU General Public License as published by
 
147
# the Free Software Foundation; either version 2, or (at your option)
 
148
# any later version.
 
149
 
 
150
# This program is distributed in the hope that it will be useful,
 
151
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
152
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
153
# GNU General Public License for more details.
 
154
 
 
155
# You should have received a copy of the GNU General Public License
 
156
# along with this program; if not, write to the Free Software
 
157
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
158
# 02111-1307, USA.
 
159
 
 
160
# serial 6
 
161
 
 
162
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
 
163
# -------------------------------------
 
164
# Define a conditional.
 
165
AC_DEFUN([AM_CONDITIONAL],
 
166
[AC_PREREQ(2.52)dnl
 
167
 ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
 
168
        [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
 
169
AC_SUBST([$1_TRUE])
 
170
AC_SUBST([$1_FALSE])
 
171
if $2; then
 
172
  $1_TRUE=
 
173
  $1_FALSE='#'
 
174
else
 
175
  $1_TRUE='#'
 
176
  $1_FALSE=
 
177
fi
 
178
AC_CONFIG_COMMANDS_PRE(
 
179
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
 
180
  AC_MSG_ERROR([[conditional "$1" was never defined.
 
181
Usually this means the macro was only invoked conditionally.]])
 
182
fi])])
 
183
 
 
184
# serial 7                                              -*- Autoconf -*-
 
185
 
 
186
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004
 
187
# Free Software Foundation, Inc.
 
188
 
 
189
# This program is free software; you can redistribute it and/or modify
 
190
# it under the terms of the GNU General Public License as published by
 
191
# the Free Software Foundation; either version 2, or (at your option)
 
192
# any later version.
 
193
 
 
194
# This program is distributed in the hope that it will be useful,
 
195
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
196
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
197
# GNU General Public License for more details.
 
198
 
 
199
# You should have received a copy of the GNU General Public License
 
200
# along with this program; if not, write to the Free Software
 
201
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
202
# 02111-1307, USA.
 
203
 
 
204
 
 
205
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
 
206
# written in clear, in which case automake, when reading aclocal.m4,
 
207
# will think it sees a *use*, and therefore will trigger all it's
 
208
# C support machinery.  Also note that it means that autoscan, seeing
 
209
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
 
210
 
 
211
 
 
212
 
 
213
# _AM_DEPENDENCIES(NAME)
 
214
# ----------------------
 
215
# See how the compiler implements dependency checking.
 
216
# NAME is "CC", "CXX", "GCJ", or "OBJC".
 
217
# We try a few techniques and use that to set a single cache variable.
 
218
#
 
219
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
 
220
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
 
221
# dependency, and given that the user is not expected to run this macro,
 
222
# just rely on AC_PROG_CC.
 
223
AC_DEFUN([_AM_DEPENDENCIES],
 
224
[AC_REQUIRE([AM_SET_DEPDIR])dnl
 
225
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
 
226
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
 
227
AC_REQUIRE([AM_DEP_TRACK])dnl
 
228
 
 
229
ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
 
230
       [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
 
231
       [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
 
232
       [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
 
233
                   [depcc="$$1"   am_compiler_list=])
 
234
 
 
235
AC_CACHE_CHECK([dependency style of $depcc],
 
236
               [am_cv_$1_dependencies_compiler_type],
 
237
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
 
238
  # We make a subdir and do the tests there.  Otherwise we can end up
 
239
  # making bogus files that we don't know about and never remove.  For
 
240
  # instance it was reported that on HP-UX the gcc test will end up
 
241
  # making a dummy file named `D' -- because `-MD' means `put the output
 
242
  # in D'.
 
243
  mkdir conftest.dir
 
244
  # Copy depcomp to subdir because otherwise we won't find it if we're
 
245
  # using a relative directory.
 
246
  cp "$am_depcomp" conftest.dir
 
247
  cd conftest.dir
 
248
  # We will build objects and dependencies in a subdirectory because
 
249
  # it helps to detect inapplicable dependency modes.  For instance
 
250
  # both Tru64's cc and ICC support -MD to output dependencies as a
 
251
  # side effect of compilation, but ICC will put the dependencies in
 
252
  # the current directory while Tru64 will put them in the object
 
253
  # directory.
 
254
  mkdir sub
 
255
 
 
256
  am_cv_$1_dependencies_compiler_type=none
 
257
  if test "$am_compiler_list" = ""; then
 
258
     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
 
259
  fi
 
260
  for depmode in $am_compiler_list; do
 
261
    # Setup a source with many dependencies, because some compilers
 
262
    # like to wrap large dependency lists on column 80 (with \), and
 
263
    # we should not choose a depcomp mode which is confused by this.
 
264
    #
 
265
    # We need to recreate these files for each test, as the compiler may
 
266
    # overwrite some of them when testing with obscure command lines.
 
267
    # This happens at least with the AIX C compiler.
 
268
    : > sub/conftest.c
 
269
    for i in 1 2 3 4 5 6; do
 
270
      echo '#include "conftst'$i'.h"' >> sub/conftest.c
 
271
      # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
 
272
      # Solaris 8's {/usr,}/bin/sh.
 
273
      touch sub/conftst$i.h
 
274
    done
 
275
    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
 
276
 
 
277
    case $depmode in
 
278
    nosideeffect)
 
279
      # after this tag, mechanisms are not by side-effect, so they'll
 
280
      # only be used when explicitly requested
 
281
      if test "x$enable_dependency_tracking" = xyes; then
 
282
        continue
 
283
      else
 
284
        break
 
285
      fi
 
286
      ;;
 
287
    none) break ;;
 
288
    esac
 
289
    # We check with `-c' and `-o' for the sake of the "dashmstdout"
 
290
    # mode.  It turns out that the SunPro C++ compiler does not properly
 
291
    # handle `-M -o', and we need to detect this.
 
292
    if depmode=$depmode \
 
293
       source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
 
294
       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
 
295
       $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
 
296
         >/dev/null 2>conftest.err &&
 
297
       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
 
298
       grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
 
299
       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
 
300
      # icc doesn't choke on unknown options, it will just issue warnings
 
301
      # or remarks (even with -Werror).  So we grep stderr for any message
 
302
      # that says an option was ignored or not supported.
 
303
      # When given -MP, icc 7.0 and 7.1 complain thusly:
 
304
      #   icc: Command line warning: ignoring option '-M'; no argument required
 
305
      # The diagnosis changed in icc 8.0:
 
306
      #   icc: Command line remark: option '-MP' not supported
 
307
      if (grep 'ignoring option' conftest.err ||
 
308
          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
 
309
        am_cv_$1_dependencies_compiler_type=$depmode
 
310
        break
 
311
      fi
 
312
    fi
 
313
  done
 
314
 
 
315
  cd ..
 
316
  rm -rf conftest.dir
 
317
else
 
318
  am_cv_$1_dependencies_compiler_type=none
 
319
fi
 
320
])
 
321
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
 
322
AM_CONDITIONAL([am__fastdep$1], [
 
323
  test "x$enable_dependency_tracking" != xno \
 
324
  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
 
325
])
 
326
 
 
327
 
 
328
# AM_SET_DEPDIR
 
329
# -------------
 
330
# Choose a directory name for dependency files.
 
331
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
 
332
AC_DEFUN([AM_SET_DEPDIR],
 
333
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 
334
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
 
335
])
 
336
 
 
337
 
 
338
# AM_DEP_TRACK
 
339
# ------------
 
340
AC_DEFUN([AM_DEP_TRACK],
 
341
[AC_ARG_ENABLE(dependency-tracking,
 
342
[  --disable-dependency-tracking  speeds up one-time build
 
343
  --enable-dependency-tracking   do not reject slow dependency extractors])
 
344
if test "x$enable_dependency_tracking" != xno; then
 
345
  am_depcomp="$ac_aux_dir/depcomp"
 
346
  AMDEPBACKSLASH='\'
 
347
fi
 
348
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
 
349
AC_SUBST([AMDEPBACKSLASH])
 
350
])
 
351
 
 
352
# Generate code to set up dependency tracking.   -*- Autoconf -*-
 
353
 
 
354
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004
 
355
#   Free Software Foundation, Inc.
 
356
 
 
357
# This program is free software; you can redistribute it and/or modify
 
358
# it under the terms of the GNU General Public License as published by
 
359
# the Free Software Foundation; either version 2, or (at your option)
 
360
# any later version.
 
361
 
 
362
# This program is distributed in the hope that it will be useful,
 
363
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
364
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
365
# GNU General Public License for more details.
 
366
 
 
367
# You should have received a copy of the GNU General Public License
 
368
# along with this program; if not, write to the Free Software
 
369
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
370
# 02111-1307, USA.
 
371
 
 
372
#serial 2
 
373
 
 
374
# _AM_OUTPUT_DEPENDENCY_COMMANDS
 
375
# ------------------------------
 
376
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
 
377
[for mf in $CONFIG_FILES; do
 
378
  # Strip MF so we end up with the name of the file.
 
379
  mf=`echo "$mf" | sed -e 's/:.*$//'`
 
380
  # Check whether this is an Automake generated Makefile or not.
 
381
  # We used to match only the files named `Makefile.in', but
 
382
  # some people rename them; so instead we look at the file content.
 
383
  # Grep'ing the first line is not enough: some people post-process
 
384
  # each Makefile.in and add a new line on top of each file to say so.
 
385
  # So let's grep whole file.
 
386
  if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
 
387
    dirpart=`AS_DIRNAME("$mf")`
 
388
  else
 
389
    continue
 
390
  fi
 
391
  # Extract the definition of DEPDIR, am__include, and am__quote
 
392
  # from the Makefile without running `make'.
 
393
  DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
 
394
  test -z "$DEPDIR" && continue
 
395
  am__include=`sed -n 's/^am__include = //p' < "$mf"`
 
396
  test -z "am__include" && continue
 
397
  am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
 
398
  # When using ansi2knr, U may be empty or an underscore; expand it
 
399
  U=`sed -n 's/^U = //p' < "$mf"`
 
400
  # Find all dependency output files, they are included files with
 
401
  # $(DEPDIR) in their names.  We invoke sed twice because it is the
 
402
  # simplest approach to changing $(DEPDIR) to its actual value in the
 
403
  # expansion.
 
404
  for file in `sed -n "
 
405
    s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
 
406
       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
 
407
    # Make sure the directory exists.
 
408
    test -f "$dirpart/$file" && continue
 
409
    fdir=`AS_DIRNAME(["$file"])`
 
410
    AS_MKDIR_P([$dirpart/$fdir])
 
411
    # echo "creating $dirpart/$file"
 
412
    echo '# dummy' > "$dirpart/$file"
 
413
  done
 
414
done
 
415
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
 
416
 
 
417
 
 
418
# AM_OUTPUT_DEPENDENCY_COMMANDS
 
419
# -----------------------------
 
420
# This macro should only be invoked once -- use via AC_REQUIRE.
 
421
#
 
422
# This code is only required when automatic dependency tracking
 
423
# is enabled.  FIXME.  This creates each `.P' file that we will
 
424
# need in order to bootstrap the dependency handling code.
 
425
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 
426
[AC_CONFIG_COMMANDS([depfiles],
 
427
     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
 
428
     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
 
429
])
 
430
 
 
431
# Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
 
432
 
 
433
# Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
 
434
 
 
435
# This program is free software; you can redistribute it and/or modify
 
436
# it under the terms of the GNU General Public License as published by
 
437
# the Free Software Foundation; either version 2, or (at your option)
 
438
# any later version.
 
439
 
 
440
# This program is distributed in the hope that it will be useful,
 
441
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
442
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
443
# GNU General Public License for more details.
 
444
 
 
445
# You should have received a copy of the GNU General Public License
 
446
# along with this program; if not, write to the Free Software
 
447
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
448
# 02111-1307, USA.
 
449
 
 
450
# serial 7
 
451
 
 
452
# AM_CONFIG_HEADER is obsolete.  It has been replaced by AC_CONFIG_HEADERS.
 
453
AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
 
454
 
 
455
# Do all the work for Automake.                            -*- Autoconf -*-
 
456
 
 
457
# This macro actually does too much some checks are only needed if
 
458
# your package does certain things.  But this isn't really a big deal.
 
459
 
 
460
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
 
461
# Free Software Foundation, Inc.
 
462
 
 
463
# This program is free software; you can redistribute it and/or modify
 
464
# it under the terms of the GNU General Public License as published by
 
465
# the Free Software Foundation; either version 2, or (at your option)
 
466
# any later version.
 
467
 
 
468
# This program is distributed in the hope that it will be useful,
 
469
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
470
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
471
# GNU General Public License for more details.
 
472
 
 
473
# You should have received a copy of the GNU General Public License
 
474
# along with this program; if not, write to the Free Software
 
475
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
476
# 02111-1307, USA.
 
477
 
 
478
# serial 11
 
479
 
 
480
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
 
481
# AM_INIT_AUTOMAKE([OPTIONS])
 
482
# -----------------------------------------------
 
483
# The call with PACKAGE and VERSION arguments is the old style
 
484
# call (pre autoconf-2.50), which is being phased out.  PACKAGE
 
485
# and VERSION should now be passed to AC_INIT and removed from
 
486
# the call to AM_INIT_AUTOMAKE.
 
487
# We support both call styles for the transition.  After
 
488
# the next Automake release, Autoconf can make the AC_INIT
 
489
# arguments mandatory, and then we can depend on a new Autoconf
 
490
# release and drop the old call support.
 
491
AC_DEFUN([AM_INIT_AUTOMAKE],
 
492
[AC_PREREQ([2.58])dnl
 
493
dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 
494
dnl the ones we care about.
 
495
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
 
496
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
 
497
AC_REQUIRE([AC_PROG_INSTALL])dnl
 
498
# test to see if srcdir already configured
 
499
if test "`cd $srcdir && pwd`" != "`pwd`" &&
 
500
   test -f $srcdir/config.status; then
 
501
  AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
 
502
fi
 
503
 
 
504
# test whether we have cygpath
 
505
if test -z "$CYGPATH_W"; then
 
506
  if (cygpath --version) >/dev/null 2>/dev/null; then
 
507
    CYGPATH_W='cygpath -w'
 
508
  else
 
509
    CYGPATH_W=echo
 
510
  fi
 
511
fi
 
512
AC_SUBST([CYGPATH_W])
 
513
 
 
514
# Define the identity of the package.
 
515
dnl Distinguish between old-style and new-style calls.
 
516
m4_ifval([$2],
 
517
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
 
518
 AC_SUBST([PACKAGE], [$1])dnl
 
519
 AC_SUBST([VERSION], [$2])],
 
520
[_AM_SET_OPTIONS([$1])dnl
 
521
 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
 
522
 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
 
523
 
 
524
_AM_IF_OPTION([no-define],,
 
525
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
 
526
 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
 
527
 
 
528
# Some tools Automake needs.
 
529
AC_REQUIRE([AM_SANITY_CHECK])dnl
 
530
AC_REQUIRE([AC_ARG_PROGRAM])dnl
 
531
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
 
532
AM_MISSING_PROG(AUTOCONF, autoconf)
 
533
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
 
534
AM_MISSING_PROG(AUTOHEADER, autoheader)
 
535
AM_MISSING_PROG(MAKEINFO, makeinfo)
 
536
AM_PROG_INSTALL_SH
 
537
AM_PROG_INSTALL_STRIP
 
538
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
 
539
# We need awk for the "check" target.  The system "awk" is bad on
 
540
# some platforms.
 
541
AC_REQUIRE([AC_PROG_AWK])dnl
 
542
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 
543
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 
544
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
 
545
              [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
 
546
                             [_AM_PROG_TAR([v7])])])
 
547
_AM_IF_OPTION([no-dependencies],,
 
548
[AC_PROVIDE_IFELSE([AC_PROG_CC],
 
549
                  [_AM_DEPENDENCIES(CC)],
 
550
                  [define([AC_PROG_CC],
 
551
                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
 
552
AC_PROVIDE_IFELSE([AC_PROG_CXX],
 
553
                  [_AM_DEPENDENCIES(CXX)],
 
554
                  [define([AC_PROG_CXX],
 
555
                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
 
556
])
 
557
])
 
558
 
 
559
 
 
560
# When config.status generates a header, we must update the stamp-h file.
 
561
# This file resides in the same directory as the config header
 
562
# that is generated.  The stamp files are numbered to have different names.
 
563
 
 
564
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
 
565
# loop where config.status creates the headers, so we can generate
 
566
# our stamp files there.
 
567
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
 
568
[# Compute $1's index in $config_headers.
 
569
_am_stamp_count=1
 
570
for _am_header in $config_headers :; do
 
571
  case $_am_header in
 
572
    $1 | $1:* )
 
573
      break ;;
 
574
    * )
 
575
      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
 
576
  esac
 
577
done
 
578
echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
 
579
 
 
580
# AM_PROG_INSTALL_SH
 
581
# ------------------
 
582
# Define $install_sh.
 
583
 
 
584
# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
 
585
 
 
586
# This program is free software; you can redistribute it and/or modify
 
587
# it under the terms of the GNU General Public License as published by
 
588
# the Free Software Foundation; either version 2, or (at your option)
 
589
# any later version.
 
590
 
 
591
# This program is distributed in the hope that it will be useful,
 
592
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
593
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
594
# GNU General Public License for more details.
 
595
 
 
596
# You should have received a copy of the GNU General Public License
 
597
# along with this program; if not, write to the Free Software
 
598
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
599
# 02111-1307, USA.
 
600
 
 
601
AC_DEFUN([AM_PROG_INSTALL_SH],
 
602
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 
603
install_sh=${install_sh-"$am_aux_dir/install-sh"}
 
604
AC_SUBST(install_sh)])
 
605
 
 
606
#                                                          -*- Autoconf -*-
 
607
# Copyright (C) 2003  Free Software Foundation, Inc.
 
608
 
 
609
# This program is free software; you can redistribute it and/or modify
 
610
# it under the terms of the GNU General Public License as published by
 
611
# the Free Software Foundation; either version 2, or (at your option)
 
612
# any later version.
 
613
 
 
614
# This program is distributed in the hope that it will be useful,
 
615
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
616
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
617
# GNU General Public License for more details.
 
618
 
 
619
# You should have received a copy of the GNU General Public License
 
620
# along with this program; if not, write to the Free Software
 
621
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
622
# 02111-1307, USA.
 
623
 
 
624
# serial 1
 
625
 
 
626
# Check whether the underlying file-system supports filenames
 
627
# with a leading dot.  For instance MS-DOS doesn't.
 
628
AC_DEFUN([AM_SET_LEADING_DOT],
 
629
[rm -rf .tst 2>/dev/null
 
630
mkdir .tst 2>/dev/null
 
631
if test -d .tst; then
 
632
  am__leading_dot=.
 
633
else
 
634
  am__leading_dot=_
 
635
fi
 
636
rmdir .tst 2>/dev/null
 
637
AC_SUBST([am__leading_dot])])
 
638
 
 
639
# Check to see how 'make' treats includes.      -*- Autoconf -*-
 
640
 
 
641
# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
 
642
 
 
643
# This program is free software; you can redistribute it and/or modify
 
644
# it under the terms of the GNU General Public License as published by
 
645
# the Free Software Foundation; either version 2, or (at your option)
 
646
# any later version.
 
647
 
 
648
# This program is distributed in the hope that it will be useful,
 
649
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
650
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
651
# GNU General Public License for more details.
 
652
 
 
653
# You should have received a copy of the GNU General Public License
 
654
# along with this program; if not, write to the Free Software
 
655
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
656
# 02111-1307, USA.
 
657
 
 
658
# serial 2
 
659
 
 
660
# AM_MAKE_INCLUDE()
 
661
# -----------------
 
662
# Check to see how make treats includes.
 
663
AC_DEFUN([AM_MAKE_INCLUDE],
 
664
[am_make=${MAKE-make}
 
665
cat > confinc << 'END'
 
666
am__doit:
 
667
        @echo done
 
668
.PHONY: am__doit
 
669
END
 
670
# If we don't find an include directive, just comment out the code.
 
671
AC_MSG_CHECKING([for style of include used by $am_make])
 
672
am__include="#"
 
673
am__quote=
 
674
_am_result=none
 
675
# First try GNU make style include.
 
676
echo "include confinc" > confmf
 
677
# We grep out `Entering directory' and `Leaving directory'
 
678
# messages which can occur if `w' ends up in MAKEFLAGS.
 
679
# In particular we don't look at `^make:' because GNU make might
 
680
# be invoked under some other name (usually "gmake"), in which
 
681
# case it prints its new name instead of `make'.
 
682
if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
 
683
   am__include=include
 
684
   am__quote=
 
685
   _am_result=GNU
 
686
fi
 
687
# Now try BSD make style include.
 
688
if test "$am__include" = "#"; then
 
689
   echo '.include "confinc"' > confmf
 
690
   if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
 
691
      am__include=.include
 
692
      am__quote="\""
 
693
      _am_result=BSD
 
694
   fi
 
695
fi
 
696
AC_SUBST([am__include])
 
697
AC_SUBST([am__quote])
 
698
AC_MSG_RESULT([$_am_result])
 
699
rm -f confinc confmf
 
700
])
 
701
 
 
702
#  -*- Autoconf -*-
 
703
 
 
704
 
 
705
# Copyright (C) 1997, 1999, 2000, 2001, 2003 Free Software Foundation, Inc.
 
706
 
 
707
# This program is free software; you can redistribute it and/or modify
 
708
# it under the terms of the GNU General Public License as published by
 
709
# the Free Software Foundation; either version 2, or (at your option)
 
710
# any later version.
 
711
 
 
712
# This program is distributed in the hope that it will be useful,
 
713
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
714
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
715
# GNU General Public License for more details.
 
716
 
 
717
# You should have received a copy of the GNU General Public License
 
718
# along with this program; if not, write to the Free Software
 
719
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
720
# 02111-1307, USA.
 
721
 
 
722
# serial 3
 
723
 
 
724
# AM_MISSING_PROG(NAME, PROGRAM)
 
725
# ------------------------------
 
726
AC_DEFUN([AM_MISSING_PROG],
 
727
[AC_REQUIRE([AM_MISSING_HAS_RUN])
 
728
$1=${$1-"${am_missing_run}$2"}
 
729
AC_SUBST($1)])
 
730
 
 
731
 
 
732
# AM_MISSING_HAS_RUN
 
733
# ------------------
 
734
# Define MISSING if not defined so far and test if it supports --run.
 
735
# If it does, set am_missing_run to use it, otherwise, to nothing.
 
736
AC_DEFUN([AM_MISSING_HAS_RUN],
 
737
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 
738
test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
 
739
# Use eval to expand $SHELL
 
740
if eval "$MISSING --run true"; then
 
741
  am_missing_run="$MISSING --run "
 
742
else
 
743
  am_missing_run=
 
744
  AC_MSG_WARN([`missing' script is too old or missing])
 
745
fi
 
746
])
 
747
 
 
748
# AM_PROG_MKDIR_P
 
749
# ---------------
 
750
# Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise.
 
751
 
 
752
# Copyright (C) 2003, 2004 Free Software Foundation, Inc.
 
753
 
 
754
# This program is free software; you can redistribute it and/or modify
 
755
# it under the terms of the GNU General Public License as published by
 
756
# the Free Software Foundation; either version 2, or (at your option)
 
757
# any later version.
 
758
 
 
759
# This program is distributed in the hope that it will be useful,
 
760
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
761
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
762
# GNU General Public License for more details.
 
763
 
 
764
# You should have received a copy of the GNU General Public License
 
765
# along with this program; if not, write to the Free Software
 
766
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
767
# 02111-1307, USA.
 
768
 
 
769
# Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories
 
770
# created by `make install' are always world readable, even if the
 
771
# installer happens to have an overly restrictive umask (e.g. 077).
 
772
# This was a mistake.  There are at least two reasons why we must not
 
773
# use `-m 0755':
 
774
#   - it causes special bits like SGID to be ignored,
 
775
#   - it may be too restrictive (some setups expect 775 directories).
 
776
#
 
777
# Do not use -m 0755 and let people choose whatever they expect by
 
778
# setting umask.
 
779
#
 
780
# We cannot accept any implementation of `mkdir' that recognizes `-p'.
 
781
# Some implementations (such as Solaris 8's) are not thread-safe: if a
 
782
# parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c'
 
783
# concurrently, both version can detect that a/ is missing, but only
 
784
# one can create it and the other will error out.  Consequently we
 
785
# restrict ourselves to GNU make (using the --version option ensures
 
786
# this.)
 
787
AC_DEFUN([AM_PROG_MKDIR_P],
 
788
[if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
 
789
  # We used to keeping the `.' as first argument, in order to
 
790
  # allow $(mkdir_p) to be used without argument.  As in
 
791
  #   $(mkdir_p) $(somedir)
 
792
  # where $(somedir) is conditionally defined.  However this is wrong
 
793
  # for two reasons:
 
794
  #  1. if the package is installed by a user who cannot write `.'
 
795
  #     make install will fail,
 
796
  #  2. the above comment should most certainly read
 
797
  #     $(mkdir_p) $(DESTDIR)$(somedir)
 
798
  #     so it does not work when $(somedir) is undefined and
 
799
  #     $(DESTDIR) is not.
 
800
  #  To support the latter case, we have to write
 
801
  #     test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir),
 
802
  #  so the `.' trick is pointless.
 
803
  mkdir_p='mkdir -p --'
 
804
else
 
805
  # On NextStep and OpenStep, the `mkdir' command does not
 
806
  # recognize any option.  It will interpret all options as
 
807
  # directories to create, and then abort because `.' already
 
808
  # exists.
 
809
  for d in ./-p ./--version;
 
810
  do
 
811
    test -d $d && rmdir $d
 
812
  done
 
813
  # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
 
814
  if test -f "$ac_aux_dir/mkinstalldirs"; then
 
815
    mkdir_p='$(mkinstalldirs)'
 
816
  else
 
817
    mkdir_p='$(install_sh) -d'
 
818
  fi
 
819
fi
 
820
AC_SUBST([mkdir_p])])
 
821
 
 
822
# Helper functions for option handling.                    -*- Autoconf -*-
 
823
 
 
824
# Copyright (C) 2001, 2002, 2003  Free Software Foundation, Inc.
 
825
 
 
826
# This program is free software; you can redistribute it and/or modify
 
827
# it under the terms of the GNU General Public License as published by
 
828
# the Free Software Foundation; either version 2, or (at your option)
 
829
# any later version.
 
830
 
 
831
# This program is distributed in the hope that it will be useful,
 
832
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
833
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
834
# GNU General Public License for more details.
 
835
 
 
836
# You should have received a copy of the GNU General Public License
 
837
# along with this program; if not, write to the Free Software
 
838
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
839
# 02111-1307, USA.
 
840
 
 
841
# serial 2
 
842
 
 
843
# _AM_MANGLE_OPTION(NAME)
 
844
# -----------------------
 
845
AC_DEFUN([_AM_MANGLE_OPTION],
 
846
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
 
847
 
 
848
# _AM_SET_OPTION(NAME)
 
849
# ------------------------------
 
850
# Set option NAME.  Presently that only means defining a flag for this option.
 
851
AC_DEFUN([_AM_SET_OPTION],
 
852
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
 
853
 
 
854
# _AM_SET_OPTIONS(OPTIONS)
 
855
# ----------------------------------
 
856
# OPTIONS is a space-separated list of Automake options.
 
857
AC_DEFUN([_AM_SET_OPTIONS],
 
858
[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
 
859
 
 
860
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 
861
# -------------------------------------------
 
862
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
 
863
AC_DEFUN([_AM_IF_OPTION],
 
864
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
865
 
 
866
#
 
867
# Check to make sure that the build environment is sane.
 
868
#
 
869
 
 
870
# Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
 
871
 
 
872
# This program is free software; you can redistribute it and/or modify
 
873
# it under the terms of the GNU General Public License as published by
 
874
# the Free Software Foundation; either version 2, or (at your option)
 
875
# any later version.
 
876
 
 
877
# This program is distributed in the hope that it will be useful,
 
878
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
879
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
880
# GNU General Public License for more details.
 
881
 
 
882
# You should have received a copy of the GNU General Public License
 
883
# along with this program; if not, write to the Free Software
 
884
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
885
# 02111-1307, USA.
 
886
 
 
887
# serial 3
 
888
 
 
889
# AM_SANITY_CHECK
 
890
# ---------------
 
891
AC_DEFUN([AM_SANITY_CHECK],
 
892
[AC_MSG_CHECKING([whether build environment is sane])
 
893
# Just in case
 
894
sleep 1
 
895
echo timestamp > conftest.file
 
896
# Do `set' in a subshell so we don't clobber the current shell's
 
897
# arguments.  Must try -L first in case configure is actually a
 
898
# symlink; some systems play weird games with the mod time of symlinks
 
899
# (eg FreeBSD returns the mod time of the symlink's containing
 
900
# directory).
 
901
if (
 
902
   set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
 
903
   if test "$[*]" = "X"; then
 
904
      # -L didn't work.
 
905
      set X `ls -t $srcdir/configure conftest.file`
 
906
   fi
 
907
   rm -f conftest.file
 
908
   if test "$[*]" != "X $srcdir/configure conftest.file" \
 
909
      && test "$[*]" != "X conftest.file $srcdir/configure"; then
 
910
 
 
911
      # If neither matched, then we have a broken ls.  This can happen
 
912
      # if, for instance, CONFIG_SHELL is bash and it inherits a
 
913
      # broken ls alias from the environment.  This has actually
 
914
      # happened.  Such a system could not be considered "sane".
 
915
      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
 
916
alias in your environment])
 
917
   fi
 
918
 
 
919
   test "$[2]" = conftest.file
 
920
   )
 
921
then
 
922
   # Ok.
 
923
   :
 
924
else
 
925
   AC_MSG_ERROR([newly created file is older than distributed files!
 
926
Check your system clock])
 
927
fi
 
928
AC_MSG_RESULT(yes)])
 
929
 
 
930
# AM_PROG_INSTALL_STRIP
 
931
 
 
932
# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
 
933
 
 
934
# This program is free software; you can redistribute it and/or modify
 
935
# it under the terms of the GNU General Public License as published by
 
936
# the Free Software Foundation; either version 2, or (at your option)
 
937
# any later version.
 
938
 
 
939
# This program is distributed in the hope that it will be useful,
 
940
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
941
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
942
# GNU General Public License for more details.
 
943
 
 
944
# You should have received a copy of the GNU General Public License
 
945
# along with this program; if not, write to the Free Software
 
946
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
947
# 02111-1307, USA.
 
948
 
 
949
# One issue with vendor `install' (even GNU) is that you can't
 
950
# specify the program used to strip binaries.  This is especially
 
951
# annoying in cross-compiling environments, where the build's strip
 
952
# is unlikely to handle the host's binaries.
 
953
# Fortunately install-sh will honor a STRIPPROG variable, so we
 
954
# always use install-sh in `make install-strip', and initialize
 
955
# STRIPPROG with the value of the STRIP variable (set by the user).
 
956
AC_DEFUN([AM_PROG_INSTALL_STRIP],
 
957
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 
958
# Installed binaries are usually stripped using `strip' when the user
 
959
# run `make install-strip'.  However `strip' might not be the right
 
960
# tool to use in cross-compilation environments, therefore Automake
 
961
# will honor the `STRIP' environment variable to overrule this program.
 
962
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
 
963
if test "$cross_compiling" != no; then
 
964
  AC_CHECK_TOOL([STRIP], [strip], :)
 
965
fi
 
966
INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
 
967
AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
968
 
 
969
# Check how to create a tarball.                            -*- Autoconf -*-
 
970
 
 
971
# Copyright (C) 2004  Free Software Foundation, Inc.
 
972
 
 
973
# This program is free software; you can redistribute it and/or modify
 
974
# it under the terms of the GNU General Public License as published by
 
975
# the Free Software Foundation; either version 2, or (at your option)
 
976
# any later version.
 
977
 
 
978
# This program is distributed in the hope that it will be useful,
 
979
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
980
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
981
# GNU General Public License for more details.
 
982
 
 
983
# You should have received a copy of the GNU General Public License
 
984
# along with this program; if not, write to the Free Software
 
985
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 
986
# 02111-1307, USA.
 
987
 
 
988
# serial 1
 
989
 
 
990
 
 
991
# _AM_PROG_TAR(FORMAT)
 
992
# --------------------
 
993
# Check how to create a tarball in format FORMAT.
 
994
# FORMAT should be one of `v7', `ustar', or `pax'.
 
995
#
 
996
# Substitute a variable $(am__tar) that is a command
 
997
# writing to stdout a FORMAT-tarball containing the directory
 
998
# $tardir.
 
999
#     tardir=directory && $(am__tar) > result.tar
 
1000
#
 
1001
# Substitute a variable $(am__untar) that extract such
 
1002
# a tarball read from stdin.
 
1003
#     $(am__untar) < result.tar
 
1004
AC_DEFUN([_AM_PROG_TAR],
 
1005
[# Always define AMTAR for backward compatibility.
 
1006
AM_MISSING_PROG([AMTAR], [tar])
 
1007
m4_if([$1], [v7],
 
1008
     [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
 
1009
     [m4_case([$1], [ustar],, [pax],,
 
1010
              [m4_fatal([Unknown tar format])])
 
1011
AC_MSG_CHECKING([how to create a $1 tar archive])
 
1012
# Loop over all known methods to create a tar archive until one works.
 
1013
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
 
1014
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
 
1015
# Do not fold the above two line into one, because Tru64 sh and
 
1016
# Solaris sh will not grok spaces in the rhs of `-'.
 
1017
for _am_tool in $_am_tools
 
1018
do
 
1019
  case $_am_tool in
 
1020
  gnutar)
 
1021
    for _am_tar in tar gnutar gtar;
 
1022
    do
 
1023
      AM_RUN_LOG([$_am_tar --version]) && break
 
1024
    done
 
1025
    am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
 
1026
    am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
 
1027
    am__untar="$_am_tar -xf -"
 
1028
    ;;
 
1029
  plaintar)
 
1030
    # Must skip GNU tar: if it does not support --format= it doesn't create
 
1031
    # ustar tarball either.
 
1032
    (tar --version) >/dev/null 2>&1 && continue
 
1033
    am__tar='tar chf - "$$tardir"'
 
1034
    am__tar_='tar chf - "$tardir"'
 
1035
    am__untar='tar xf -'
 
1036
    ;;
 
1037
  pax)
 
1038
    am__tar='pax -L -x $1 -w "$$tardir"'
 
1039
    am__tar_='pax -L -x $1 -w "$tardir"'
 
1040
    am__untar='pax -r'
 
1041
    ;;
 
1042
  cpio)
 
1043
    am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
 
1044
    am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
 
1045
    am__untar='cpio -i -H $1 -d'
 
1046
    ;;
 
1047
  none)
 
1048
    am__tar=false
 
1049
    am__tar_=false
 
1050
    am__untar=false
 
1051
    ;;
 
1052
  esac
 
1053
 
 
1054
  # If the value was cached, stop now.  We just wanted to have am__tar
 
1055
  # and am__untar set.
 
1056
  test -n "${am_cv_prog_tar_$1}" && break
 
1057
 
 
1058
  # tar/untar a dummy directory, and stop if the command works
 
1059
  rm -rf conftest.dir
 
1060
  mkdir conftest.dir
 
1061
  echo GrepMe > conftest.dir/file
 
1062
  AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
 
1063
  rm -rf conftest.dir
 
1064
  if test -s conftest.tar; then
 
1065
    AM_RUN_LOG([$am__untar <conftest.tar])
 
1066
    grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
 
1067
  fi
 
1068
done
 
1069
rm -rf conftest.dir
 
1070
 
 
1071
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
 
1072
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
 
1073
AC_SUBST([am__tar])
 
1074
AC_SUBST([am__untar])
 
1075
]) # _AM_PROG_TAR
 
1076