~kxteam/xts/xts-server-trunk

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Joshua Mark Higgins
  • Date: 2013-04-07 20:24:40 UTC
  • Revision ID: joshiggins@gmail.com-20130407202440-25czw5iaea8wsp41
Inital import of project

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# generated automatically by aclocal 1.11.6 -*- Autoconf -*-
 
2
 
 
3
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
 
4
# 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation,
 
5
# Inc.
 
6
# This file is free software; the Free Software Foundation
 
7
# gives unlimited permission to copy and/or distribute it,
 
8
# with or without modifications, as long as this notice is preserved.
 
9
 
 
10
# This program is distributed in the hope that it will be useful,
 
11
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
 
12
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
 
13
# PARTICULAR PURPOSE.
 
14
 
 
15
m4_ifndef([AC_AUTOCONF_VERSION],
 
16
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 
17
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
 
18
[m4_warning([this file was generated for autoconf 2.69.
 
19
You have another version of autoconf.  It may work, but is not guaranteed to.
 
20
If you have problems, you may need to regenerate the build system entirely.
 
21
To do so, use the procedure documented by the package, typically `autoreconf'.])])
 
22
 
 
23
# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008, 2011 Free Software
 
24
# Foundation, Inc.
 
25
#
 
26
# This file is free software; the Free Software Foundation
 
27
# gives unlimited permission to copy and/or distribute it,
 
28
# with or without modifications, as long as this notice is preserved.
 
29
 
 
30
# serial 1
 
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
# (This private macro should not be called outside this file.)
 
37
AC_DEFUN([AM_AUTOMAKE_VERSION],
 
38
[am__api_version='1.11'
 
39
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 
40
dnl require some minimum version.  Point them to the right macro.
 
41
m4_if([$1], [1.11.6], [],
 
42
      [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 
43
])
 
44
 
 
45
# _AM_AUTOCONF_VERSION(VERSION)
 
46
# -----------------------------
 
47
# aclocal traces this macro to find the Autoconf version.
 
48
# This is a private macro too.  Using m4_define simplifies
 
49
# the logic in aclocal, which can simply ignore this definition.
 
50
m4_define([_AM_AUTOCONF_VERSION], [])
 
51
 
 
52
# AM_SET_CURRENT_AUTOMAKE_VERSION
 
53
# -------------------------------
 
54
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 
55
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 
56
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
 
57
[AM_AUTOMAKE_VERSION([1.11.6])dnl
 
58
m4_ifndef([AC_AUTOCONF_VERSION],
 
59
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 
60
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
61
 
 
62
# AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
63
 
 
64
# Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
 
65
#
 
66
# This file is free software; the Free Software Foundation
 
67
# gives unlimited permission to copy and/or distribute it,
 
68
# with or without modifications, as long as this notice is preserved.
 
69
 
 
70
# serial 1
 
71
 
 
72
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
 
73
# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
 
74
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
 
75
#
 
76
# Of course, Automake must honor this variable whenever it calls a
 
77
# tool from the auxiliary directory.  The problem is that $srcdir (and
 
78
# therefore $ac_aux_dir as well) can be either absolute or relative,
 
79
# depending on how configure is run.  This is pretty annoying, since
 
80
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
 
81
# source directory, any form will work fine, but in subdirectories a
 
82
# relative path needs to be adjusted first.
 
83
#
 
84
# $ac_aux_dir/missing
 
85
#    fails when called from a subdirectory if $ac_aux_dir is relative
 
86
# $top_srcdir/$ac_aux_dir/missing
 
87
#    fails if $ac_aux_dir is absolute,
 
88
#    fails when called from a subdirectory in a VPATH build with
 
89
#          a relative $ac_aux_dir
 
90
#
 
91
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
 
92
# are both prefixed by $srcdir.  In an in-source build this is usually
 
93
# harmless because $srcdir is `.', but things will broke when you
 
94
# start a VPATH build or use an absolute $srcdir.
 
95
#
 
96
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
 
97
# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
 
98
#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
 
99
# and then we would define $MISSING as
 
100
#   MISSING="\${SHELL} $am_aux_dir/missing"
 
101
# This will work as long as MISSING is not called from configure, because
 
102
# unfortunately $(top_srcdir) has no meaning in configure.
 
103
# However there are other variables, like CC, which are often used in
 
104
# configure, and could therefore not use this "fixed" $ac_aux_dir.
 
105
#
 
106
# Another solution, used here, is to always expand $ac_aux_dir to an
 
107
# absolute PATH.  The drawback is that using absolute paths prevent a
 
108
# configured tree to be moved without reconfiguration.
 
109
 
 
110
AC_DEFUN([AM_AUX_DIR_EXPAND],
 
111
[dnl Rely on autoconf to set up CDPATH properly.
 
112
AC_PREREQ([2.50])dnl
 
113
# expand $ac_aux_dir to an absolute path
 
114
am_aux_dir=`cd $ac_aux_dir && pwd`
 
115
])
 
116
 
 
117
# Do all the work for Automake.                             -*- Autoconf -*-
 
118
 
 
119
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
 
120
# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
 
121
#
 
122
# This file is free software; the Free Software Foundation
 
123
# gives unlimited permission to copy and/or distribute it,
 
124
# with or without modifications, as long as this notice is preserved.
 
125
 
 
126
# serial 16
 
127
 
 
128
# This macro actually does too much.  Some checks are only needed if
 
129
# your package does certain things.  But this isn't really a big deal.
 
130
 
 
131
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
 
132
# AM_INIT_AUTOMAKE([OPTIONS])
 
133
# -----------------------------------------------
 
134
# The call with PACKAGE and VERSION arguments is the old style
 
135
# call (pre autoconf-2.50), which is being phased out.  PACKAGE
 
136
# and VERSION should now be passed to AC_INIT and removed from
 
137
# the call to AM_INIT_AUTOMAKE.
 
138
# We support both call styles for the transition.  After
 
139
# the next Automake release, Autoconf can make the AC_INIT
 
140
# arguments mandatory, and then we can depend on a new Autoconf
 
141
# release and drop the old call support.
 
142
AC_DEFUN([AM_INIT_AUTOMAKE],
 
143
[AC_PREREQ([2.62])dnl
 
144
dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 
145
dnl the ones we care about.
 
146
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
 
147
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
 
148
AC_REQUIRE([AC_PROG_INSTALL])dnl
 
149
if test "`cd $srcdir && pwd`" != "`pwd`"; then
 
150
  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
 
151
  # is not polluted with repeated "-I."
 
152
  AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
 
153
  # test to see if srcdir already configured
 
154
  if test -f $srcdir/config.status; then
 
155
    AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
 
156
  fi
 
157
fi
 
158
 
 
159
# test whether we have cygpath
 
160
if test -z "$CYGPATH_W"; then
 
161
  if (cygpath --version) >/dev/null 2>/dev/null; then
 
162
    CYGPATH_W='cygpath -w'
 
163
  else
 
164
    CYGPATH_W=echo
 
165
  fi
 
166
fi
 
167
AC_SUBST([CYGPATH_W])
 
168
 
 
169
# Define the identity of the package.
 
170
dnl Distinguish between old-style and new-style calls.
 
171
m4_ifval([$2],
 
172
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
 
173
 AC_SUBST([PACKAGE], [$1])dnl
 
174
 AC_SUBST([VERSION], [$2])],
 
175
[_AM_SET_OPTIONS([$1])dnl
 
176
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
 
177
m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
 
178
  [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
 
179
 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
 
180
 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
 
181
 
 
182
_AM_IF_OPTION([no-define],,
 
183
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
 
184
 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
 
185
 
 
186
# Some tools Automake needs.
 
187
AC_REQUIRE([AM_SANITY_CHECK])dnl
 
188
AC_REQUIRE([AC_ARG_PROGRAM])dnl
 
189
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
 
190
AM_MISSING_PROG(AUTOCONF, autoconf)
 
191
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
 
192
AM_MISSING_PROG(AUTOHEADER, autoheader)
 
193
AM_MISSING_PROG(MAKEINFO, makeinfo)
 
194
AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 
195
AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
 
196
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
 
197
# We need awk for the "check" target.  The system "awk" is bad on
 
198
# some platforms.
 
199
AC_REQUIRE([AC_PROG_AWK])dnl
 
200
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 
201
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 
202
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
 
203
              [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
 
204
                             [_AM_PROG_TAR([v7])])])
 
205
_AM_IF_OPTION([no-dependencies],,
 
206
[AC_PROVIDE_IFELSE([AC_PROG_CC],
 
207
                  [_AM_DEPENDENCIES(CC)],
 
208
                  [define([AC_PROG_CC],
 
209
                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
 
210
AC_PROVIDE_IFELSE([AC_PROG_CXX],
 
211
                  [_AM_DEPENDENCIES(CXX)],
 
212
                  [define([AC_PROG_CXX],
 
213
                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
 
214
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
 
215
                  [_AM_DEPENDENCIES(OBJC)],
 
216
                  [define([AC_PROG_OBJC],
 
217
                          defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
 
218
])
 
219
_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
 
220
dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
 
221
dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
 
222
dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
 
223
AC_CONFIG_COMMANDS_PRE(dnl
 
224
[m4_provide_if([_AM_COMPILER_EXEEXT],
 
225
  [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
 
226
])
 
227
 
 
228
dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
 
229
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
 
230
dnl mangled by Autoconf and run in a shell conditional statement.
 
231
m4_define([_AC_COMPILER_EXEEXT],
 
232
m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
 
233
 
 
234
 
 
235
# When config.status generates a header, we must update the stamp-h file.
 
236
# This file resides in the same directory as the config header
 
237
# that is generated.  The stamp files are numbered to have different names.
 
238
 
 
239
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
 
240
# loop where config.status creates the headers, so we can generate
 
241
# our stamp files there.
 
242
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
 
243
[# Compute $1's index in $config_headers.
 
244
_am_arg=$1
 
245
_am_stamp_count=1
 
246
for _am_header in $config_headers :; do
 
247
  case $_am_header in
 
248
    $_am_arg | $_am_arg:* )
 
249
      break ;;
 
250
    * )
 
251
      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
 
252
  esac
 
253
done
 
254
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
255
 
 
256
# Copyright (C) 2001, 2003, 2005, 2008, 2011 Free Software Foundation,
 
257
# Inc.
 
258
#
 
259
# This file is free software; the Free Software Foundation
 
260
# gives unlimited permission to copy and/or distribute it,
 
261
# with or without modifications, as long as this notice is preserved.
 
262
 
 
263
# serial 1
 
264
 
 
265
# AM_PROG_INSTALL_SH
 
266
# ------------------
 
267
# Define $install_sh.
 
268
AC_DEFUN([AM_PROG_INSTALL_SH],
 
269
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 
270
if test x"${install_sh}" != xset; then
 
271
  case $am_aux_dir in
 
272
  *\ * | *\     *)
 
273
    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
 
274
  *)
 
275
    install_sh="\${SHELL} $am_aux_dir/install-sh"
 
276
  esac
 
277
fi
 
278
AC_SUBST(install_sh)])
 
279
 
 
280
# Copyright (C) 2003, 2005  Free Software Foundation, Inc.
 
281
#
 
282
# This file is free software; the Free Software Foundation
 
283
# gives unlimited permission to copy and/or distribute it,
 
284
# with or without modifications, as long as this notice is preserved.
 
285
 
 
286
# serial 2
 
287
 
 
288
# Check whether the underlying file-system supports filenames
 
289
# with a leading dot.  For instance MS-DOS doesn't.
 
290
AC_DEFUN([AM_SET_LEADING_DOT],
 
291
[rm -rf .tst 2>/dev/null
 
292
mkdir .tst 2>/dev/null
 
293
if test -d .tst; then
 
294
  am__leading_dot=.
 
295
else
 
296
  am__leading_dot=_
 
297
fi
 
298
rmdir .tst 2>/dev/null
 
299
AC_SUBST([am__leading_dot])])
 
300
 
 
301
# Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
302
 
 
303
# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
 
304
# Free Software Foundation, Inc.
 
305
#
 
306
# This file is free software; the Free Software Foundation
 
307
# gives unlimited permission to copy and/or distribute it,
 
308
# with or without modifications, as long as this notice is preserved.
 
309
 
 
310
# serial 6
 
311
 
 
312
# AM_MISSING_PROG(NAME, PROGRAM)
 
313
# ------------------------------
 
314
AC_DEFUN([AM_MISSING_PROG],
 
315
[AC_REQUIRE([AM_MISSING_HAS_RUN])
 
316
$1=${$1-"${am_missing_run}$2"}
 
317
AC_SUBST($1)])
 
318
 
 
319
 
 
320
# AM_MISSING_HAS_RUN
 
321
# ------------------
 
322
# Define MISSING if not defined so far and test if it supports --run.
 
323
# If it does, set am_missing_run to use it, otherwise, to nothing.
 
324
AC_DEFUN([AM_MISSING_HAS_RUN],
 
325
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 
326
AC_REQUIRE_AUX_FILE([missing])dnl
 
327
if test x"${MISSING+set}" != xset; then
 
328
  case $am_aux_dir in
 
329
  *\ * | *\     *)
 
330
    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
 
331
  *)
 
332
    MISSING="\${SHELL} $am_aux_dir/missing" ;;
 
333
  esac
 
334
fi
 
335
# Use eval to expand $SHELL
 
336
if eval "$MISSING --run true"; then
 
337
  am_missing_run="$MISSING --run "
 
338
else
 
339
  am_missing_run=
 
340
  AC_MSG_WARN([`missing' script is too old or missing])
 
341
fi
 
342
])
 
343
 
 
344
# Copyright (C) 2003, 2004, 2005, 2006, 2011 Free Software Foundation,
 
345
# Inc.
 
346
#
 
347
# This file is free software; the Free Software Foundation
 
348
# gives unlimited permission to copy and/or distribute it,
 
349
# with or without modifications, as long as this notice is preserved.
 
350
 
 
351
# serial 1
 
352
 
 
353
# AM_PROG_MKDIR_P
 
354
# ---------------
 
355
# Check for `mkdir -p'.
 
356
AC_DEFUN([AM_PROG_MKDIR_P],
 
357
[AC_PREREQ([2.60])dnl
 
358
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
 
359
dnl Automake 1.8 to 1.9.6 used to define mkdir_p.  We now use MKDIR_P,
 
360
dnl while keeping a definition of mkdir_p for backward compatibility.
 
361
dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
 
362
dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
 
363
dnl Makefile.ins that do not define MKDIR_P, so we do our own
 
364
dnl adjustment using top_builddir (which is defined more often than
 
365
dnl MKDIR_P).
 
366
AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
 
367
case $mkdir_p in
 
368
  [[\\/$]]* | ?:[[\\/]]*) ;;
 
369
  */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
 
370
esac
 
371
])
 
372
 
 
373
# Helper functions for option handling.                     -*- Autoconf -*-
 
374
 
 
375
# Copyright (C) 2001, 2002, 2003, 2005, 2008, 2010 Free Software
 
376
# Foundation, Inc.
 
377
#
 
378
# This file is free software; the Free Software Foundation
 
379
# gives unlimited permission to copy and/or distribute it,
 
380
# with or without modifications, as long as this notice is preserved.
 
381
 
 
382
# serial 5
 
383
 
 
384
# _AM_MANGLE_OPTION(NAME)
 
385
# -----------------------
 
386
AC_DEFUN([_AM_MANGLE_OPTION],
 
387
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
 
388
 
 
389
# _AM_SET_OPTION(NAME)
 
390
# --------------------
 
391
# Set option NAME.  Presently that only means defining a flag for this option.
 
392
AC_DEFUN([_AM_SET_OPTION],
 
393
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
 
394
 
 
395
# _AM_SET_OPTIONS(OPTIONS)
 
396
# ------------------------
 
397
# OPTIONS is a space-separated list of Automake options.
 
398
AC_DEFUN([_AM_SET_OPTIONS],
 
399
[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
 
400
 
 
401
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 
402
# -------------------------------------------
 
403
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
 
404
AC_DEFUN([_AM_IF_OPTION],
 
405
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
406
 
 
407
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008, 2009,
 
408
# 2011 Free Software Foundation, Inc.
 
409
#
 
410
# This file is free software; the Free Software Foundation
 
411
# gives unlimited permission to copy and/or distribute it,
 
412
# with or without modifications, as long as this notice is preserved.
 
413
 
 
414
# serial 2
 
415
 
 
416
# AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
 
417
# ---------------------------------------------------------------------------
 
418
# Adds support for distributing Python modules and packages.  To
 
419
# install modules, copy them to $(pythondir), using the python_PYTHON
 
420
# automake variable.  To install a package with the same name as the
 
421
# automake package, install to $(pkgpythondir), or use the
 
422
# pkgpython_PYTHON automake variable.
 
423
#
 
424
# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as
 
425
# locations to install python extension modules (shared libraries).
 
426
# Another macro is required to find the appropriate flags to compile
 
427
# extension modules.
 
428
#
 
429
# If your package is configured with a different prefix to python,
 
430
# users will have to add the install directory to the PYTHONPATH
 
431
# environment variable, or create a .pth file (see the python
 
432
# documentation for details).
 
433
#
 
434
# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will
 
435
# cause an error if the version of python installed on the system
 
436
# doesn't meet the requirement.  MINIMUM-VERSION should consist of
 
437
# numbers and dots only.
 
438
AC_DEFUN([AM_PATH_PYTHON],
 
439
 [
 
440
  dnl Find a Python interpreter.  Python versions prior to 2.0 are not
 
441
  dnl supported. (2.0 was released on October 16, 2000).
 
442
  m4_define_default([_AM_PYTHON_INTERPRETER_LIST],
 
443
[python python2 python3 python3.2 python3.1 python3.0 python2.7 dnl
 
444
 python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0])
 
445
 
 
446
  AC_ARG_VAR([PYTHON], [the Python interpreter])
 
447
 
 
448
  m4_if([$1],[],[
 
449
    dnl No version check is needed.
 
450
    # Find any Python interpreter.
 
451
    if test -z "$PYTHON"; then
 
452
      AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :)
 
453
    fi
 
454
    am_display_PYTHON=python
 
455
  ], [
 
456
    dnl A version check is needed.
 
457
    if test -n "$PYTHON"; then
 
458
      # If the user set $PYTHON, use it and don't search something else.
 
459
      AC_MSG_CHECKING([whether $PYTHON version >= $1])
 
460
      AM_PYTHON_CHECK_VERSION([$PYTHON], [$1],
 
461
                              [AC_MSG_RESULT(yes)],
 
462
                              [AC_MSG_ERROR(too old)])
 
463
      am_display_PYTHON=$PYTHON
 
464
    else
 
465
      # Otherwise, try each interpreter until we find one that satisfies
 
466
      # VERSION.
 
467
      AC_CACHE_CHECK([for a Python interpreter with version >= $1],
 
468
        [am_cv_pathless_PYTHON],[
 
469
        for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do
 
470
          test "$am_cv_pathless_PYTHON" = none && break
 
471
          AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break])
 
472
        done])
 
473
      # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
 
474
      if test "$am_cv_pathless_PYTHON" = none; then
 
475
        PYTHON=:
 
476
      else
 
477
        AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON])
 
478
      fi
 
479
      am_display_PYTHON=$am_cv_pathless_PYTHON
 
480
    fi
 
481
  ])
 
482
 
 
483
  if test "$PYTHON" = :; then
 
484
  dnl Run any user-specified action, or abort.
 
485
    m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])])
 
486
  else
 
487
 
 
488
  dnl Query Python for its version number.  Getting [:3] seems to be
 
489
  dnl the best way to do this; it's what "site.py" does in the standard
 
490
  dnl library.
 
491
 
 
492
  AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version],
 
493
    [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`])
 
494
  AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
 
495
 
 
496
  dnl Use the values of $prefix and $exec_prefix for the corresponding
 
497
  dnl values of PYTHON_PREFIX and PYTHON_EXEC_PREFIX.  These are made
 
498
  dnl distinct variables so they can be overridden if need be.  However,
 
499
  dnl general consensus is that you shouldn't need this ability.
 
500
 
 
501
  AC_SUBST([PYTHON_PREFIX], ['${prefix}'])
 
502
  AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}'])
 
503
 
 
504
  dnl At times (like when building shared libraries) you may want
 
505
  dnl to know which OS platform Python thinks this is.
 
506
 
 
507
  AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform],
 
508
    [am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`])
 
509
  AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform])
 
510
 
 
511
 
 
512
  dnl Set up 4 directories:
 
513
 
 
514
  dnl pythondir -- where to install python scripts.  This is the
 
515
  dnl   site-packages directory, not the python standard library
 
516
  dnl   directory like in previous automake betas.  This behavior
 
517
  dnl   is more consistent with lispdir.m4 for example.
 
518
  dnl Query distutils for this directory.
 
519
  AC_CACHE_CHECK([for $am_display_PYTHON script directory],
 
520
    [am_cv_python_pythondir],
 
521
    [if test "x$prefix" = xNONE
 
522
     then
 
523
       am_py_prefix=$ac_default_prefix
 
524
     else
 
525
       am_py_prefix=$prefix
 
526
     fi
 
527
     am_cv_python_pythondir=`$PYTHON -c "import sys; from distutils import sysconfig; sys.stdout.write(sysconfig.get_python_lib(0,0,prefix='$am_py_prefix'))" 2>/dev/null`
 
528
     case $am_cv_python_pythondir in
 
529
     $am_py_prefix*)
 
530
       am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
 
531
       am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
 
532
       ;;
 
533
     *)
 
534
       case $am_py_prefix in
 
535
         /usr|/System*) ;;
 
536
         *)
 
537
          am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
 
538
          ;;
 
539
       esac
 
540
       ;;
 
541
     esac
 
542
    ])
 
543
  AC_SUBST([pythondir], [$am_cv_python_pythondir])
 
544
 
 
545
  dnl pkgpythondir -- $PACKAGE directory under pythondir.  Was
 
546
  dnl   PYTHON_SITE_PACKAGE in previous betas, but this naming is
 
547
  dnl   more consistent with the rest of automake.
 
548
 
 
549
  AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE])
 
550
 
 
551
  dnl pyexecdir -- directory for installing python extension modules
 
552
  dnl   (shared libraries)
 
553
  dnl Query distutils for this directory.
 
554
  AC_CACHE_CHECK([for $am_display_PYTHON extension module directory],
 
555
    [am_cv_python_pyexecdir],
 
556
    [if test "x$exec_prefix" = xNONE
 
557
     then
 
558
       am_py_exec_prefix=$am_py_prefix
 
559
     else
 
560
       am_py_exec_prefix=$exec_prefix
 
561
     fi
 
562
     am_cv_python_pyexecdir=`$PYTHON -c "import sys; from distutils import sysconfig; sys.stdout.write(sysconfig.get_python_lib(1,0,prefix='$am_py_exec_prefix'))" 2>/dev/null`
 
563
     case $am_cv_python_pyexecdir in
 
564
     $am_py_exec_prefix*)
 
565
       am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
 
566
       am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
 
567
       ;;
 
568
     *)
 
569
       case $am_py_exec_prefix in
 
570
         /usr|/System*) ;;
 
571
         *)
 
572
           am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
 
573
           ;;
 
574
       esac
 
575
       ;;
 
576
     esac
 
577
    ])
 
578
  AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir])
 
579
 
 
580
  dnl pkgpyexecdir -- $(pyexecdir)/$(PACKAGE)
 
581
 
 
582
  AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE])
 
583
 
 
584
  dnl Run any user-specified action.
 
585
  $2
 
586
  fi
 
587
 
 
588
])
 
589
 
 
590
 
 
591
# AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
 
592
# ---------------------------------------------------------------------------
 
593
# Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION.
 
594
# Run ACTION-IF-FALSE otherwise.
 
595
# This test uses sys.hexversion instead of the string equivalent (first
 
596
# word of sys.version), in order to cope with versions such as 2.2c1.
 
597
# This supports Python 2.0 or higher. (2.0 was released on October 16, 2000).
 
598
AC_DEFUN([AM_PYTHON_CHECK_VERSION],
 
599
 [prog="import sys
 
600
# split strings by '.' and convert to numeric.  Append some zeros
 
601
# because we need at least 4 digits for the hex conversion.
 
602
# map returns an iterator in Python 3.0 and a list in 2.x
 
603
minver = list(map(int, '$2'.split('.'))) + [[0, 0, 0]]
 
604
minverhex = 0
 
605
# xrange is not present in Python 3.0 and range returns an iterator
 
606
for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[[i]]
 
607
sys.exit(sys.hexversion < minverhex)"
 
608
  AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])])
 
609
 
 
610
# Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
 
611
#
 
612
# This file is free software; the Free Software Foundation
 
613
# gives unlimited permission to copy and/or distribute it,
 
614
# with or without modifications, as long as this notice is preserved.
 
615
 
 
616
# serial 1
 
617
 
 
618
# AM_RUN_LOG(COMMAND)
 
619
# -------------------
 
620
# Run COMMAND, save the exit status in ac_status, and log it.
 
621
# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
 
622
AC_DEFUN([AM_RUN_LOG],
 
623
[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
 
624
   ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
 
625
   ac_status=$?
 
626
   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
 
627
   (exit $ac_status); }])
 
628
 
 
629
# Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
630
 
 
631
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
 
632
# 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 5
 
639
 
 
640
# AM_SANITY_CHECK
 
641
# ---------------
 
642
AC_DEFUN([AM_SANITY_CHECK],
 
643
[AC_MSG_CHECKING([whether build environment is sane])
 
644
# Just in case
 
645
sleep 1
 
646
echo timestamp > conftest.file
 
647
# Reject unsafe characters in $srcdir or the absolute working directory
 
648
# name.  Accept space and tab only in the latter.
 
649
am_lf='
 
650
'
 
651
case `pwd` in
 
652
  *[[\\\"\#\$\&\'\`$am_lf]]*)
 
653
    AC_MSG_ERROR([unsafe absolute working directory name]);;
 
654
esac
 
655
case $srcdir in
 
656
  *[[\\\"\#\$\&\'\`$am_lf\ \    ]]*)
 
657
    AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
 
658
esac
 
659
 
 
660
# Do `set' in a subshell so we don't clobber the current shell's
 
661
# arguments.  Must try -L first in case configure is actually a
 
662
# symlink; some systems play weird games with the mod time of symlinks
 
663
# (eg FreeBSD returns the mod time of the symlink's containing
 
664
# directory).
 
665
if (
 
666
   set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
 
667
   if test "$[*]" = "X"; then
 
668
      # -L didn't work.
 
669
      set X `ls -t "$srcdir/configure" conftest.file`
 
670
   fi
 
671
   rm -f conftest.file
 
672
   if test "$[*]" != "X $srcdir/configure conftest.file" \
 
673
      && test "$[*]" != "X conftest.file $srcdir/configure"; then
 
674
 
 
675
      # If neither matched, then we have a broken ls.  This can happen
 
676
      # if, for instance, CONFIG_SHELL is bash and it inherits a
 
677
      # broken ls alias from the environment.  This has actually
 
678
      # happened.  Such a system could not be considered "sane".
 
679
      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
 
680
alias in your environment])
 
681
   fi
 
682
 
 
683
   test "$[2]" = conftest.file
 
684
   )
 
685
then
 
686
   # Ok.
 
687
   :
 
688
else
 
689
   AC_MSG_ERROR([newly created file is older than distributed files!
 
690
Check your system clock])
 
691
fi
 
692
AC_MSG_RESULT(yes)])
 
693
 
 
694
# Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
 
695
#
 
696
# This file is free software; the Free Software Foundation
 
697
# gives unlimited permission to copy and/or distribute it,
 
698
# with or without modifications, as long as this notice is preserved.
 
699
 
 
700
# serial 1
 
701
 
 
702
# AM_PROG_INSTALL_STRIP
 
703
# ---------------------
 
704
# One issue with vendor `install' (even GNU) is that you can't
 
705
# specify the program used to strip binaries.  This is especially
 
706
# annoying in cross-compiling environments, where the build's strip
 
707
# is unlikely to handle the host's binaries.
 
708
# Fortunately install-sh will honor a STRIPPROG variable, so we
 
709
# always use install-sh in `make install-strip', and initialize
 
710
# STRIPPROG with the value of the STRIP variable (set by the user).
 
711
AC_DEFUN([AM_PROG_INSTALL_STRIP],
 
712
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 
713
# Installed binaries are usually stripped using `strip' when the user
 
714
# run `make install-strip'.  However `strip' might not be the right
 
715
# tool to use in cross-compilation environments, therefore Automake
 
716
# will honor the `STRIP' environment variable to overrule this program.
 
717
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
 
718
if test "$cross_compiling" != no; then
 
719
  AC_CHECK_TOOL([STRIP], [strip], :)
 
720
fi
 
721
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 
722
AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
723
 
 
724
# Copyright (C) 2006, 2008, 2010 Free Software Foundation, Inc.
 
725
#
 
726
# This file is free software; the Free Software Foundation
 
727
# gives unlimited permission to copy and/or distribute it,
 
728
# with or without modifications, as long as this notice is preserved.
 
729
 
 
730
# serial 3
 
731
 
 
732
# _AM_SUBST_NOTMAKE(VARIABLE)
 
733
# ---------------------------
 
734
# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
 
735
# This macro is traced by Automake.
 
736
AC_DEFUN([_AM_SUBST_NOTMAKE])
 
737
 
 
738
# AM_SUBST_NOTMAKE(VARIABLE)
 
739
# --------------------------
 
740
# Public sister of _AM_SUBST_NOTMAKE.
 
741
AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 
742
 
 
743
# Check how to create a tarball.                            -*- Autoconf -*-
 
744
 
 
745
# Copyright (C) 2004, 2005, 2012 Free Software Foundation, Inc.
 
746
#
 
747
# This file is free software; the Free Software Foundation
 
748
# gives unlimited permission to copy and/or distribute it,
 
749
# with or without modifications, as long as this notice is preserved.
 
750
 
 
751
# serial 2
 
752
 
 
753
# _AM_PROG_TAR(FORMAT)
 
754
# --------------------
 
755
# Check how to create a tarball in format FORMAT.
 
756
# FORMAT should be one of `v7', `ustar', or `pax'.
 
757
#
 
758
# Substitute a variable $(am__tar) that is a command
 
759
# writing to stdout a FORMAT-tarball containing the directory
 
760
# $tardir.
 
761
#     tardir=directory && $(am__tar) > result.tar
 
762
#
 
763
# Substitute a variable $(am__untar) that extract such
 
764
# a tarball read from stdin.
 
765
#     $(am__untar) < result.tar
 
766
AC_DEFUN([_AM_PROG_TAR],
 
767
[# Always define AMTAR for backward compatibility.  Yes, it's still used
 
768
# in the wild :-(  We should find a proper way to deprecate it ...
 
769
AC_SUBST([AMTAR], ['$${TAR-tar}'])
 
770
m4_if([$1], [v7],
 
771
     [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
 
772
     [m4_case([$1], [ustar],, [pax],,
 
773
              [m4_fatal([Unknown tar format])])
 
774
AC_MSG_CHECKING([how to create a $1 tar archive])
 
775
# Loop over all known methods to create a tar archive until one works.
 
776
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
 
777
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
 
778
# Do not fold the above two line into one, because Tru64 sh and
 
779
# Solaris sh will not grok spaces in the rhs of `-'.
 
780
for _am_tool in $_am_tools
 
781
do
 
782
  case $_am_tool in
 
783
  gnutar)
 
784
    for _am_tar in tar gnutar gtar;
 
785
    do
 
786
      AM_RUN_LOG([$_am_tar --version]) && break
 
787
    done
 
788
    am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
 
789
    am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
 
790
    am__untar="$_am_tar -xf -"
 
791
    ;;
 
792
  plaintar)
 
793
    # Must skip GNU tar: if it does not support --format= it doesn't create
 
794
    # ustar tarball either.
 
795
    (tar --version) >/dev/null 2>&1 && continue
 
796
    am__tar='tar chf - "$$tardir"'
 
797
    am__tar_='tar chf - "$tardir"'
 
798
    am__untar='tar xf -'
 
799
    ;;
 
800
  pax)
 
801
    am__tar='pax -L -x $1 -w "$$tardir"'
 
802
    am__tar_='pax -L -x $1 -w "$tardir"'
 
803
    am__untar='pax -r'
 
804
    ;;
 
805
  cpio)
 
806
    am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
 
807
    am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
 
808
    am__untar='cpio -i -H $1 -d'
 
809
    ;;
 
810
  none)
 
811
    am__tar=false
 
812
    am__tar_=false
 
813
    am__untar=false
 
814
    ;;
 
815
  esac
 
816
 
 
817
  # If the value was cached, stop now.  We just wanted to have am__tar
 
818
  # and am__untar set.
 
819
  test -n "${am_cv_prog_tar_$1}" && break
 
820
 
 
821
  # tar/untar a dummy directory, and stop if the command works
 
822
  rm -rf conftest.dir
 
823
  mkdir conftest.dir
 
824
  echo GrepMe > conftest.dir/file
 
825
  AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
 
826
  rm -rf conftest.dir
 
827
  if test -s conftest.tar; then
 
828
    AM_RUN_LOG([$am__untar <conftest.tar])
 
829
    grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
 
830
  fi
 
831
done
 
832
rm -rf conftest.dir
 
833
 
 
834
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
 
835
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
 
836
AC_SUBST([am__tar])
 
837
AC_SUBST([am__untar])
 
838
]) # _AM_PROG_TAR
 
839