~cm-t/ubuntu-fr-tour/ubuntu-fr-tour

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: cm-t arudy
  • Date: 2013-10-22 01:24:09 UTC
  • Revision ID: arudy@ubuntu-fr.org-20131022012409-3dmo4i9u4ufohe5f
First Fr push to 13.10
Fixed many icons (updated to new version or fixed graphic)
Added Cloud indicator
Added Keyboard uindicator
Fixed many layout to fit Fr string

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# generated automatically by aclocal 1.13.3 -*- Autoconf -*-
 
2
 
 
3
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 
4
 
 
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
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
 
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) 1995-2002 Free Software Foundation, Inc.
 
24
# Copyright (C) 2001-2003,2004 Red Hat, Inc.
 
25
#
 
26
# This file is free software, distributed under the terms of the GNU
 
27
# General Public License.  As a special exception to the GNU General
 
28
# Public License, this file may be distributed as part of a program
 
29
# that contains a configuration script generated by Autoconf, under
 
30
# the same distribution terms as the rest of that program.
 
31
#
 
32
# This file can be copied and used freely without restrictions.  It can
 
33
# be used in projects which are not available under the GNU Public License
 
34
# but which still want to provide support for the GNU gettext functionality.
 
35
#
 
36
# Macro to add for using GNU gettext.
 
37
# Ulrich Drepper <drepper@cygnus.com>, 1995, 1996
 
38
#
 
39
# Modified to never use included libintl. 
 
40
# Owen Taylor <otaylor@redhat.com>, 12/15/1998
 
41
#
 
42
# Major rework to remove unused code
 
43
# Owen Taylor <otaylor@redhat.com>, 12/11/2002
 
44
#
 
45
# Added better handling of ALL_LINGUAS from GNU gettext version 
 
46
# written by Bruno Haible, Owen Taylor <otaylor.redhat.com> 5/30/3002
 
47
#
 
48
# Modified to require ngettext
 
49
# Matthias Clasen <mclasen@redhat.com> 08/06/2004
 
50
#
 
51
# We need this here as well, since someone might use autoconf-2.5x
 
52
# to configure GLib then an older version to configure a package
 
53
# using AM_GLIB_GNU_GETTEXT
 
54
AC_PREREQ(2.53)
 
55
 
 
56
dnl
 
57
dnl We go to great lengths to make sure that aclocal won't 
 
58
dnl try to pull in the installed version of these macros
 
59
dnl when running aclocal in the glib directory.
 
60
dnl
 
61
m4_copy([AC_DEFUN],[glib_DEFUN])
 
62
m4_copy([AC_REQUIRE],[glib_REQUIRE])
 
63
dnl
 
64
dnl At the end, if we're not within glib, we'll define the public
 
65
dnl definitions in terms of our private definitions.
 
66
dnl
 
67
 
 
68
# GLIB_LC_MESSAGES
 
69
#--------------------
 
70
glib_DEFUN([GLIB_LC_MESSAGES],
 
71
  [AC_CHECK_HEADERS([locale.h])
 
72
    if test $ac_cv_header_locale_h = yes; then
 
73
    AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
 
74
      [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
 
75
       am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
 
76
    if test $am_cv_val_LC_MESSAGES = yes; then
 
77
      AC_DEFINE(HAVE_LC_MESSAGES, 1,
 
78
        [Define if your <locale.h> file defines LC_MESSAGES.])
 
79
    fi
 
80
  fi])
 
81
 
 
82
# GLIB_PATH_PROG_WITH_TEST
 
83
#----------------------------
 
84
dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
 
85
dnl   TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
 
86
glib_DEFUN([GLIB_PATH_PROG_WITH_TEST],
 
87
[# Extract the first word of "$2", so it can be a program name with args.
 
88
set dummy $2; ac_word=[$]2
 
89
AC_MSG_CHECKING([for $ac_word])
 
90
AC_CACHE_VAL(ac_cv_path_$1,
 
91
[case "[$]$1" in
 
92
  /*)
 
93
  ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
 
94
  ;;
 
95
  *)
 
96
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
 
97
  for ac_dir in ifelse([$5], , $PATH, [$5]); do
 
98
    test -z "$ac_dir" && ac_dir=.
 
99
    if test -f $ac_dir/$ac_word; then
 
100
      if [$3]; then
 
101
        ac_cv_path_$1="$ac_dir/$ac_word"
 
102
        break
 
103
      fi
 
104
    fi
 
105
  done
 
106
  IFS="$ac_save_ifs"
 
107
dnl If no 4th arg is given, leave the cache variable unset,
 
108
dnl so AC_PATH_PROGS will keep looking.
 
109
ifelse([$4], , , [  test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
 
110
])dnl
 
111
  ;;
 
112
esac])dnl
 
113
$1="$ac_cv_path_$1"
 
114
if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
 
115
  AC_MSG_RESULT([$]$1)
 
116
else
 
117
  AC_MSG_RESULT(no)
 
118
fi
 
119
AC_SUBST($1)dnl
 
120
])
 
121
 
 
122
# GLIB_WITH_NLS
 
123
#-----------------
 
124
glib_DEFUN([GLIB_WITH_NLS],
 
125
  dnl NLS is obligatory
 
126
  [USE_NLS=yes
 
127
    AC_SUBST(USE_NLS)
 
128
 
 
129
    gt_cv_have_gettext=no
 
130
 
 
131
    CATOBJEXT=NONE
 
132
    XGETTEXT=:
 
133
    INTLLIBS=
 
134
 
 
135
    AC_CHECK_HEADER(libintl.h,
 
136
     [gt_cv_func_dgettext_libintl="no"
 
137
      libintl_extra_libs=""
 
138
 
 
139
      #
 
140
      # First check in libc
 
141
      #
 
142
      AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc,
 
143
        [AC_TRY_LINK([
 
144
#include <libintl.h>
 
145
],
 
146
         [return !ngettext ("","", 1)],
 
147
          gt_cv_func_ngettext_libc=yes,
 
148
          gt_cv_func_ngettext_libc=no)
 
149
        ])
 
150
  
 
151
      if test "$gt_cv_func_ngettext_libc" = "yes" ; then
 
152
              AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc,
 
153
                [AC_TRY_LINK([
 
154
#include <libintl.h>
 
155
],
 
156
                  [return !dgettext ("","")],
 
157
                  gt_cv_func_dgettext_libc=yes,
 
158
                  gt_cv_func_dgettext_libc=no)
 
159
                ])
 
160
      fi
 
161
  
 
162
      if test "$gt_cv_func_ngettext_libc" = "yes" ; then
 
163
        AC_CHECK_FUNCS(bind_textdomain_codeset)
 
164
      fi
 
165
 
 
166
      #
 
167
      # If we don't have everything we want, check in libintl
 
168
      #
 
169
      if test "$gt_cv_func_dgettext_libc" != "yes" \
 
170
         || test "$gt_cv_func_ngettext_libc" != "yes" \
 
171
         || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then
 
172
        
 
173
        AC_CHECK_LIB(intl, bindtextdomain,
 
174
            [AC_CHECK_LIB(intl, ngettext,
 
175
                    [AC_CHECK_LIB(intl, dgettext,
 
176
                                  gt_cv_func_dgettext_libintl=yes)])])
 
177
 
 
178
        if test "$gt_cv_func_dgettext_libintl" != "yes" ; then
 
179
          AC_MSG_CHECKING([if -liconv is needed to use gettext])
 
180
          AC_MSG_RESULT([])
 
181
          AC_CHECK_LIB(intl, ngettext,
 
182
                [AC_CHECK_LIB(intl, dcgettext,
 
183
                       [gt_cv_func_dgettext_libintl=yes
 
184
                        libintl_extra_libs=-liconv],
 
185
                        :,-liconv)],
 
186
                :,-liconv)
 
187
        fi
 
188
 
 
189
        #
 
190
        # If we found libintl, then check in it for bind_textdomain_codeset();
 
191
        # we'll prefer libc if neither have bind_textdomain_codeset(),
 
192
        # and both have dgettext and ngettext
 
193
        #
 
194
        if test "$gt_cv_func_dgettext_libintl" = "yes" ; then
 
195
          glib_save_LIBS="$LIBS"
 
196
          LIBS="$LIBS -lintl $libintl_extra_libs"
 
197
          unset ac_cv_func_bind_textdomain_codeset
 
198
          AC_CHECK_FUNCS(bind_textdomain_codeset)
 
199
          LIBS="$glib_save_LIBS"
 
200
 
 
201
          if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then
 
202
            gt_cv_func_dgettext_libc=no
 
203
          else
 
204
            if test "$gt_cv_func_dgettext_libc" = "yes" \
 
205
                && test "$gt_cv_func_ngettext_libc" = "yes"; then
 
206
              gt_cv_func_dgettext_libintl=no
 
207
            fi
 
208
          fi
 
209
        fi
 
210
      fi
 
211
 
 
212
      if test "$gt_cv_func_dgettext_libc" = "yes" \
 
213
        || test "$gt_cv_func_dgettext_libintl" = "yes"; then
 
214
        gt_cv_have_gettext=yes
 
215
      fi
 
216
  
 
217
      if test "$gt_cv_func_dgettext_libintl" = "yes"; then
 
218
        INTLLIBS="-lintl $libintl_extra_libs"
 
219
      fi
 
220
  
 
221
      if test "$gt_cv_have_gettext" = "yes"; then
 
222
        AC_DEFINE(HAVE_GETTEXT,1,
 
223
          [Define if the GNU gettext() function is already present or preinstalled.])
 
224
        GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
 
225
          [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
 
226
        if test "$MSGFMT" != "no"; then
 
227
          glib_save_LIBS="$LIBS"
 
228
          LIBS="$LIBS $INTLLIBS"
 
229
          AC_CHECK_FUNCS(dcgettext)
 
230
          MSGFMT_OPTS=
 
231
          AC_MSG_CHECKING([if msgfmt accepts -c])
 
232
          GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[
 
233
msgid ""
 
234
msgstr ""
 
235
"Content-Type: text/plain; charset=UTF-8\n"
 
236
"Project-Id-Version: test 1.0\n"
 
237
"PO-Revision-Date: 2007-02-15 12:01+0100\n"
 
238
"Last-Translator: test <foo@bar.xx>\n"
 
239
"Language-Team: C <LL@li.org>\n"
 
240
"MIME-Version: 1.0\n"
 
241
"Content-Transfer-Encoding: 8bit\n"
 
242
], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])])
 
243
          AC_SUBST(MSGFMT_OPTS)
 
244
          AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
 
245
          GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
 
246
            [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
 
247
          AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
 
248
                         return _nl_msg_cat_cntr],
 
249
            [CATOBJEXT=.gmo 
 
250
             DATADIRNAME=share],
 
251
            [case $host in
 
252
            *-*-solaris*)
 
253
            dnl On Solaris, if bind_textdomain_codeset is in libc,
 
254
            dnl GNU format message catalog is always supported,
 
255
            dnl since both are added to the libc all together.
 
256
            dnl Hence, we'd like to go with DATADIRNAME=share and
 
257
            dnl and CATOBJEXT=.gmo in this case.
 
258
            AC_CHECK_FUNC(bind_textdomain_codeset,
 
259
              [CATOBJEXT=.gmo 
 
260
               DATADIRNAME=share],
 
261
              [CATOBJEXT=.mo
 
262
               DATADIRNAME=lib])
 
263
            ;;
 
264
            *-*-openbsd*)
 
265
            CATOBJEXT=.mo
 
266
            DATADIRNAME=share
 
267
            ;;
 
268
            *)
 
269
            CATOBJEXT=.mo
 
270
            DATADIRNAME=lib
 
271
            ;;
 
272
            esac])
 
273
          LIBS="$glib_save_LIBS"
 
274
          INSTOBJEXT=.mo
 
275
        else
 
276
          gt_cv_have_gettext=no
 
277
        fi
 
278
      fi
 
279
    ])
 
280
 
 
281
    if test "$gt_cv_have_gettext" = "yes" ; then
 
282
      AC_DEFINE(ENABLE_NLS, 1,
 
283
        [always defined to indicate that i18n is enabled])
 
284
    fi
 
285
 
 
286
    dnl Test whether we really found GNU xgettext.
 
287
    if test "$XGETTEXT" != ":"; then
 
288
      dnl If it is not GNU xgettext we define it as : so that the
 
289
      dnl Makefiles still can work.
 
290
      if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
 
291
        : ;
 
292
      else
 
293
        AC_MSG_RESULT(
 
294
          [found xgettext program is not GNU xgettext; ignore it])
 
295
        XGETTEXT=":"
 
296
      fi
 
297
    fi
 
298
 
 
299
    # We need to process the po/ directory.
 
300
    POSUB=po
 
301
 
 
302
    AC_OUTPUT_COMMANDS(
 
303
      [case "$CONFIG_FILES" in *po/Makefile.in*)
 
304
        sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
 
305
      esac])
 
306
 
 
307
    dnl These rules are solely for the distribution goal.  While doing this
 
308
    dnl we only have to keep exactly one list of the available catalogs
 
309
    dnl in configure.ac.
 
310
    for lang in $ALL_LINGUAS; do
 
311
      GMOFILES="$GMOFILES $lang.gmo"
 
312
      POFILES="$POFILES $lang.po"
 
313
    done
 
314
 
 
315
    dnl Make all variables we use known to autoconf.
 
316
    AC_SUBST(CATALOGS)
 
317
    AC_SUBST(CATOBJEXT)
 
318
    AC_SUBST(DATADIRNAME)
 
319
    AC_SUBST(GMOFILES)
 
320
    AC_SUBST(INSTOBJEXT)
 
321
    AC_SUBST(INTLLIBS)
 
322
    AC_SUBST(PO_IN_DATADIR_TRUE)
 
323
    AC_SUBST(PO_IN_DATADIR_FALSE)
 
324
    AC_SUBST(POFILES)
 
325
    AC_SUBST(POSUB)
 
326
  ])
 
327
 
 
328
# AM_GLIB_GNU_GETTEXT
 
329
# -------------------
 
330
# Do checks necessary for use of gettext. If a suitable implementation 
 
331
# of gettext is found in either in libintl or in the C library,
 
332
# it will set INTLLIBS to the libraries needed for use of gettext
 
333
# and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable
 
334
# gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST()
 
335
# on various variables needed by the Makefile.in.in installed by 
 
336
# glib-gettextize.
 
337
dnl
 
338
glib_DEFUN([GLIB_GNU_GETTEXT],
 
339
  [AC_REQUIRE([AC_PROG_CC])dnl
 
340
   
 
341
   GLIB_LC_MESSAGES
 
342
   GLIB_WITH_NLS
 
343
 
 
344
   if test "$gt_cv_have_gettext" = "yes"; then
 
345
     if test "x$ALL_LINGUAS" = "x"; then
 
346
       LINGUAS=
 
347
     else
 
348
       AC_MSG_CHECKING(for catalogs to be installed)
 
349
       NEW_LINGUAS=
 
350
       for presentlang in $ALL_LINGUAS; do
 
351
         useit=no
 
352
         if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then
 
353
           desiredlanguages="$LINGUAS"
 
354
         else
 
355
           desiredlanguages="$ALL_LINGUAS"
 
356
         fi
 
357
         for desiredlang in $desiredlanguages; do
 
358
           # Use the presentlang catalog if desiredlang is
 
359
           #   a. equal to presentlang, or
 
360
           #   b. a variant of presentlang (because in this case,
 
361
           #      presentlang can be used as a fallback for messages
 
362
           #      which are not translated in the desiredlang catalog).
 
363
           case "$desiredlang" in
 
364
             "$presentlang"*) useit=yes;;
 
365
           esac
 
366
         done
 
367
         if test $useit = yes; then
 
368
           NEW_LINGUAS="$NEW_LINGUAS $presentlang"
 
369
         fi
 
370
       done
 
371
       LINGUAS=$NEW_LINGUAS
 
372
       AC_MSG_RESULT($LINGUAS)
 
373
     fi
 
374
 
 
375
     dnl Construct list of names of catalog files to be constructed.
 
376
     if test -n "$LINGUAS"; then
 
377
       for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
 
378
     fi
 
379
   fi
 
380
 
 
381
   dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
 
382
   dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
 
383
   dnl Try to locate is.
 
384
   MKINSTALLDIRS=
 
385
   if test -n "$ac_aux_dir"; then
 
386
     MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
 
387
   fi
 
388
   if test -z "$MKINSTALLDIRS"; then
 
389
     MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
 
390
   fi
 
391
   AC_SUBST(MKINSTALLDIRS)
 
392
 
 
393
   dnl Generate list of files to be processed by xgettext which will
 
394
   dnl be included in po/Makefile.
 
395
   test -d po || mkdir po
 
396
   if test "x$srcdir" != "x."; then
 
397
     if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
 
398
       posrcprefix="$srcdir/"
 
399
     else
 
400
       posrcprefix="../$srcdir/"
 
401
     fi
 
402
   else
 
403
     posrcprefix="../"
 
404
   fi
 
405
   rm -f po/POTFILES
 
406
   sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
 
407
        < $srcdir/po/POTFILES.in > po/POTFILES
 
408
  ])
 
409
 
 
410
# AM_GLIB_DEFINE_LOCALEDIR(VARIABLE)
 
411
# -------------------------------
 
412
# Define VARIABLE to the location where catalog files will
 
413
# be installed by po/Makefile.
 
414
glib_DEFUN([GLIB_DEFINE_LOCALEDIR],
 
415
[glib_REQUIRE([GLIB_GNU_GETTEXT])dnl
 
416
glib_save_prefix="$prefix"
 
417
glib_save_exec_prefix="$exec_prefix"
 
418
glib_save_datarootdir="$datarootdir"
 
419
test "x$prefix" = xNONE && prefix=$ac_default_prefix
 
420
test "x$exec_prefix" = xNONE && exec_prefix=$prefix
 
421
datarootdir=`eval echo "${datarootdir}"`
 
422
if test "x$CATOBJEXT" = "x.mo" ; then
 
423
  localedir=`eval echo "${libdir}/locale"`
 
424
else
 
425
  localedir=`eval echo "${datadir}/locale"`
 
426
fi
 
427
prefix="$glib_save_prefix"
 
428
exec_prefix="$glib_save_exec_prefix"
 
429
datarootdir="$glib_save_datarootdir"
 
430
AC_DEFINE_UNQUOTED($1, "$localedir",
 
431
  [Define the location where the catalogs will be installed])
 
432
])
 
433
 
 
434
dnl
 
435
dnl Now the definitions that aclocal will find
 
436
dnl
 
437
ifdef(glib_configure_ac,[],[
 
438
AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)])
 
439
AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)])
 
440
])dnl
 
441
 
 
442
# GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL])
 
443
 
444
# Create a temporary file with TEST-FILE as its contents and pass the
 
445
# file name to PROGRAM.  Perform ACTION-IF-PASS if PROGRAM exits with
 
446
# 0 and perform ACTION-IF-FAIL for any other exit status.
 
447
AC_DEFUN([GLIB_RUN_PROG],
 
448
[cat >conftest.foo <<_ACEOF
 
449
$2
 
450
_ACEOF
 
451
if AC_RUN_LOG([$1 conftest.foo]); then
 
452
  m4_ifval([$3], [$3], [:])
 
453
m4_ifvaln([$4], [else $4])dnl
 
454
echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD
 
455
sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
 
456
fi])
 
457
 
 
458
 
 
459
 
 
460
dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
 
461
# serial 42 IT_PROG_INTLTOOL
 
462
AC_DEFUN([IT_PROG_INTLTOOL], [
 
463
AC_PREREQ([2.50])dnl
 
464
AC_REQUIRE([AM_NLS])dnl
 
465
 
 
466
case "$am__api_version" in
 
467
    1.[01234])
 
468
        AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
 
469
    ;;
 
470
    *)
 
471
    ;;
 
472
esac
 
473
 
 
474
INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
 
475
INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
 
476
INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
 
477
if test -n "$1"; then
 
478
    AC_MSG_CHECKING([for intltool >= $1])
 
479
    AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
 
480
    test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
 
481
        AC_MSG_ERROR([Your intltool is too old.  You need intltool $1 or later.])
 
482
fi
 
483
 
 
484
AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
 
485
AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
 
486
AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
 
487
if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
 
488
    AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
 
489
fi
 
490
 
 
491
if test -z "$AM_DEFAULT_VERBOSITY"; then
 
492
  AM_DEFAULT_VERBOSITY=1
 
493
fi
 
494
AC_SUBST([AM_DEFAULT_VERBOSITY])
 
495
 
 
496
INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
 
497
INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
 
498
INTLTOOL__v_MERGE_0='@echo "  ITMRG " [$]@;'
 
499
AC_SUBST(INTLTOOL_V_MERGE)
 
500
AC_SUBST(INTLTOOL__v_MERGE_)
 
501
AC_SUBST(INTLTOOL__v_MERGE_0)
 
502
 
 
503
INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
 
504
intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
 
505
intltool__v_merge_options_0='-q'
 
506
AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
 
507
AC_SUBST(intltool__v_merge_options_)
 
508
AC_SUBST(intltool__v_merge_options_0)
 
509
 
 
510
  INTLTOOL_DESKTOP_RULE='%.desktop:   %.desktop.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
511
INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
512
     INTLTOOL_KEYS_RULE='%.keys:      %.keys.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
513
     INTLTOOL_PROP_RULE='%.prop:      %.prop.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
514
      INTLTOOL_OAF_RULE='%.oaf:       %.oaf.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -p $(top_srcdir)/po $< [$]@'
 
515
     INTLTOOL_PONG_RULE='%.pong:      %.pong.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
516
   INTLTOOL_SERVER_RULE='%.server:    %.server.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
517
    INTLTOOL_SHEET_RULE='%.sheet:     %.sheet.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
518
INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
519
       INTLTOOL_UI_RULE='%.ui:        %.ui.in        $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
520
      INTLTOOL_XML_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
521
if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
 
522
      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u --no-translations $< [$]@'
 
523
else
 
524
      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)_it_tmp_dir=tmp.intltool.[$][$]RANDOM && mkdir [$][$]_it_tmp_dir && LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u [$][$]_it_tmp_dir $< [$]@ && rmdir [$][$]_it_tmp_dir'
 
525
fi
 
526
      INTLTOOL_XAM_RULE='%.xam:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
527
      INTLTOOL_KBD_RULE='%.kbd:       %.kbd.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
528
    INTLTOOL_CAVES_RULE='%.caves:     %.caves.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
529
  INTLTOOL_SCHEMAS_RULE='%.schemas:   %.schemas.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
530
    INTLTOOL_THEME_RULE='%.theme:     %.theme.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
 
531
    INTLTOOL_SERVICE_RULE='%.service: %.service.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
 
532
   INTLTOOL_POLICY_RULE='%.policy:    %.policy.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
 
533
 
 
534
_IT_SUBST(INTLTOOL_DESKTOP_RULE)
 
535
_IT_SUBST(INTLTOOL_DIRECTORY_RULE)
 
536
_IT_SUBST(INTLTOOL_KEYS_RULE)
 
537
_IT_SUBST(INTLTOOL_PROP_RULE)
 
538
_IT_SUBST(INTLTOOL_OAF_RULE)
 
539
_IT_SUBST(INTLTOOL_PONG_RULE)
 
540
_IT_SUBST(INTLTOOL_SERVER_RULE)
 
541
_IT_SUBST(INTLTOOL_SHEET_RULE)
 
542
_IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
 
543
_IT_SUBST(INTLTOOL_UI_RULE)
 
544
_IT_SUBST(INTLTOOL_XAM_RULE)
 
545
_IT_SUBST(INTLTOOL_KBD_RULE)
 
546
_IT_SUBST(INTLTOOL_XML_RULE)
 
547
_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
 
548
_IT_SUBST(INTLTOOL_CAVES_RULE)
 
549
_IT_SUBST(INTLTOOL_SCHEMAS_RULE)
 
550
_IT_SUBST(INTLTOOL_THEME_RULE)
 
551
_IT_SUBST(INTLTOOL_SERVICE_RULE)
 
552
_IT_SUBST(INTLTOOL_POLICY_RULE)
 
553
 
 
554
# Check the gettext tools to make sure they are GNU
 
555
AC_PATH_PROG(XGETTEXT, xgettext)
 
556
AC_PATH_PROG(MSGMERGE, msgmerge)
 
557
AC_PATH_PROG(MSGFMT, msgfmt)
 
558
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
 
559
if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
 
560
    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
 
561
fi
 
562
xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
 
563
mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
 
564
mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
 
565
if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
 
566
    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
 
567
fi
 
568
 
 
569
AC_PATH_PROG(INTLTOOL_PERL, perl)
 
570
if test -z "$INTLTOOL_PERL"; then
 
571
   AC_MSG_ERROR([perl not found])
 
572
fi
 
573
AC_MSG_CHECKING([for perl >= 5.8.1])
 
574
$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
 
575
if test $? -ne 0; then
 
576
   AC_MSG_ERROR([perl 5.8.1 is required for intltool])
 
577
else
 
578
   IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
 
579
   AC_MSG_RESULT([$IT_PERL_VERSION])
 
580
fi
 
581
if test "x$2" != "xno-xml"; then
 
582
   AC_MSG_CHECKING([for XML::Parser])
 
583
   if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
 
584
       AC_MSG_RESULT([ok])
 
585
   else
 
586
       AC_MSG_ERROR([XML::Parser perl module is required for intltool])
 
587
   fi
 
588
fi
 
589
 
 
590
# Substitute ALL_LINGUAS so we can use it in po/Makefile
 
591
AC_SUBST(ALL_LINGUAS)
 
592
 
 
593
# Set DATADIRNAME correctly if it is not set yet
 
594
# (copied from glib-gettext.m4)
 
595
if test -z "$DATADIRNAME"; then
 
596
  AC_LINK_IFELSE(
 
597
    [AC_LANG_PROGRAM([[]],
 
598
                     [[extern int _nl_msg_cat_cntr;
 
599
                       return _nl_msg_cat_cntr]])],
 
600
    [DATADIRNAME=share],
 
601
    [case $host in
 
602
    *-*-solaris*)
 
603
    dnl On Solaris, if bind_textdomain_codeset is in libc,
 
604
    dnl GNU format message catalog is always supported,
 
605
    dnl since both are added to the libc all together.
 
606
    dnl Hence, we'd like to go with DATADIRNAME=share
 
607
    dnl in this case.
 
608
    AC_CHECK_FUNC(bind_textdomain_codeset,
 
609
      [DATADIRNAME=share], [DATADIRNAME=lib])
 
610
    ;;
 
611
    *)
 
612
    [DATADIRNAME=lib]
 
613
    ;;
 
614
    esac])
 
615
fi
 
616
AC_SUBST(DATADIRNAME)
 
617
 
 
618
IT_PO_SUBDIR([po])
 
619
 
 
620
])
 
621
 
 
622
 
 
623
# IT_PO_SUBDIR(DIRNAME)
 
624
# ---------------------
 
625
# All po subdirs have to be declared with this macro; the subdir "po" is
 
626
# declared by IT_PROG_INTLTOOL.
 
627
#
 
628
AC_DEFUN([IT_PO_SUBDIR],
 
629
[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
 
630
dnl
 
631
dnl The following CONFIG_COMMANDS should be executed at the very end
 
632
dnl of config.status.
 
633
AC_CONFIG_COMMANDS_PRE([
 
634
  AC_CONFIG_COMMANDS([$1/stamp-it], [
 
635
    if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
 
636
       AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
 
637
    fi
 
638
    rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
 
639
    >"$1/stamp-it.tmp"
 
640
    [sed '/^#/d
 
641
         s/^[[].*] *//
 
642
         /^[    ]*$/d
 
643
        '"s|^|  $ac_top_srcdir/|" \
 
644
      "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
 
645
    ]
 
646
    [sed '/^POTFILES =/,/[^\\]$/ {
 
647
                /^POTFILES =/!d
 
648
                r $1/POTFILES
 
649
          }
 
650
         ' "$1/Makefile.in" >"$1/Makefile"]
 
651
    rm -f "$1/Makefile.tmp"
 
652
    mv "$1/stamp-it.tmp" "$1/stamp-it"
 
653
  ])
 
654
])dnl
 
655
])
 
656
 
 
657
# _IT_SUBST(VARIABLE)
 
658
# -------------------
 
659
# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
 
660
#
 
661
AC_DEFUN([_IT_SUBST],
 
662
[
 
663
AC_SUBST([$1])
 
664
m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
 
665
]
 
666
)
 
667
 
 
668
# deprecated macros
 
669
AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
 
670
# A hint is needed for aclocal from Automake <= 1.9.4:
 
671
# AC_DEFUN([AC_PROG_INTLTOOL], ...)
 
672
 
 
673
 
 
674
# nls.m4 serial 5 (gettext-0.18)
 
675
dnl Copyright (C) 1995-2003, 2005-2006, 2008-2010 Free Software Foundation,
 
676
dnl Inc.
 
677
dnl This file is free software; the Free Software Foundation
 
678
dnl gives unlimited permission to copy and/or distribute it,
 
679
dnl with or without modifications, as long as this notice is preserved.
 
680
dnl
 
681
dnl This file can can be used in projects which are not available under
 
682
dnl the GNU General Public License or the GNU Library General Public
 
683
dnl License but which still want to provide support for the GNU gettext
 
684
dnl functionality.
 
685
dnl Please note that the actual code of the GNU gettext library is covered
 
686
dnl by the GNU Library General Public License, and the rest of the GNU
 
687
dnl gettext package package is covered by the GNU General Public License.
 
688
dnl They are *not* in the public domain.
 
689
 
 
690
dnl Authors:
 
691
dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
 
692
dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2003.
 
693
 
 
694
AC_PREREQ([2.50])
 
695
 
 
696
AC_DEFUN([AM_NLS],
 
697
[
 
698
  AC_MSG_CHECKING([whether NLS is requested])
 
699
  dnl Default is enabled NLS
 
700
  AC_ARG_ENABLE([nls],
 
701
    [  --disable-nls           do not use Native Language Support],
 
702
    USE_NLS=$enableval, USE_NLS=yes)
 
703
  AC_MSG_RESULT([$USE_NLS])
 
704
  AC_SUBST([USE_NLS])
 
705
])
 
706
 
 
707
# Copyright (C) 2002-2013 Free Software Foundation, Inc.
 
708
#
 
709
# This file is free software; the Free Software Foundation
 
710
# gives unlimited permission to copy and/or distribute it,
 
711
# with or without modifications, as long as this notice is preserved.
 
712
 
 
713
# AM_AUTOMAKE_VERSION(VERSION)
 
714
# ----------------------------
 
715
# Automake X.Y traces this macro to ensure aclocal.m4 has been
 
716
# generated from the m4 files accompanying Automake X.Y.
 
717
# (This private macro should not be called outside this file.)
 
718
AC_DEFUN([AM_AUTOMAKE_VERSION],
 
719
[am__api_version='1.13'
 
720
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 
721
dnl require some minimum version.  Point them to the right macro.
 
722
m4_if([$1], [1.13.3], [],
 
723
      [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 
724
])
 
725
 
 
726
# _AM_AUTOCONF_VERSION(VERSION)
 
727
# -----------------------------
 
728
# aclocal traces this macro to find the Autoconf version.
 
729
# This is a private macro too.  Using m4_define simplifies
 
730
# the logic in aclocal, which can simply ignore this definition.
 
731
m4_define([_AM_AUTOCONF_VERSION], [])
 
732
 
 
733
# AM_SET_CURRENT_AUTOMAKE_VERSION
 
734
# -------------------------------
 
735
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 
736
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 
737
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
 
738
[AM_AUTOMAKE_VERSION([1.13.3])dnl
 
739
m4_ifndef([AC_AUTOCONF_VERSION],
 
740
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 
741
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
742
 
 
743
# AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
744
 
 
745
# Copyright (C) 2001-2013 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
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
 
752
# $ac_aux_dir to '$srcdir/foo'.  In other projects, it is set to
 
753
# '$srcdir', '$srcdir/..', or '$srcdir/../..'.
 
754
#
 
755
# Of course, Automake must honor this variable whenever it calls a
 
756
# tool from the auxiliary directory.  The problem is that $srcdir (and
 
757
# therefore $ac_aux_dir as well) can be either absolute or relative,
 
758
# depending on how configure is run.  This is pretty annoying, since
 
759
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
 
760
# source directory, any form will work fine, but in subdirectories a
 
761
# relative path needs to be adjusted first.
 
762
#
 
763
# $ac_aux_dir/missing
 
764
#    fails when called from a subdirectory if $ac_aux_dir is relative
 
765
# $top_srcdir/$ac_aux_dir/missing
 
766
#    fails if $ac_aux_dir is absolute,
 
767
#    fails when called from a subdirectory in a VPATH build with
 
768
#          a relative $ac_aux_dir
 
769
#
 
770
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
 
771
# are both prefixed by $srcdir.  In an in-source build this is usually
 
772
# harmless because $srcdir is '.', but things will broke when you
 
773
# start a VPATH build or use an absolute $srcdir.
 
774
#
 
775
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
 
776
# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
 
777
#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
 
778
# and then we would define $MISSING as
 
779
#   MISSING="\${SHELL} $am_aux_dir/missing"
 
780
# This will work as long as MISSING is not called from configure, because
 
781
# unfortunately $(top_srcdir) has no meaning in configure.
 
782
# However there are other variables, like CC, which are often used in
 
783
# configure, and could therefore not use this "fixed" $ac_aux_dir.
 
784
#
 
785
# Another solution, used here, is to always expand $ac_aux_dir to an
 
786
# absolute PATH.  The drawback is that using absolute paths prevent a
 
787
# configured tree to be moved without reconfiguration.
 
788
 
 
789
AC_DEFUN([AM_AUX_DIR_EXPAND],
 
790
[dnl Rely on autoconf to set up CDPATH properly.
 
791
AC_PREREQ([2.50])dnl
 
792
# expand $ac_aux_dir to an absolute path
 
793
am_aux_dir=`cd $ac_aux_dir && pwd`
 
794
])
 
795
 
 
796
# AM_CONDITIONAL                                            -*- Autoconf -*-
 
797
 
 
798
# Copyright (C) 1997-2013 Free Software Foundation, Inc.
 
799
#
 
800
# This file is free software; the Free Software Foundation
 
801
# gives unlimited permission to copy and/or distribute it,
 
802
# with or without modifications, as long as this notice is preserved.
 
803
 
 
804
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
 
805
# -------------------------------------
 
806
# Define a conditional.
 
807
AC_DEFUN([AM_CONDITIONAL],
 
808
[AC_PREREQ([2.52])dnl
 
809
 m4_if([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
 
810
       [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
 
811
AC_SUBST([$1_TRUE])dnl
 
812
AC_SUBST([$1_FALSE])dnl
 
813
_AM_SUBST_NOTMAKE([$1_TRUE])dnl
 
814
_AM_SUBST_NOTMAKE([$1_FALSE])dnl
 
815
m4_define([_AM_COND_VALUE_$1], [$2])dnl
 
816
if $2; then
 
817
  $1_TRUE=
 
818
  $1_FALSE='#'
 
819
else
 
820
  $1_TRUE='#'
 
821
  $1_FALSE=
 
822
fi
 
823
AC_CONFIG_COMMANDS_PRE(
 
824
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
 
825
  AC_MSG_ERROR([[conditional "$1" was never defined.
 
826
Usually this means the macro was only invoked conditionally.]])
 
827
fi])])
 
828
 
 
829
# Copyright (C) 1999-2013 Free Software Foundation, Inc.
 
830
#
 
831
# This file is free software; the Free Software Foundation
 
832
# gives unlimited permission to copy and/or distribute it,
 
833
# with or without modifications, as long as this notice is preserved.
 
834
 
 
835
 
 
836
# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
 
837
# written in clear, in which case automake, when reading aclocal.m4,
 
838
# will think it sees a *use*, and therefore will trigger all it's
 
839
# C support machinery.  Also note that it means that autoscan, seeing
 
840
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
 
841
 
 
842
 
 
843
# _AM_DEPENDENCIES(NAME)
 
844
# ----------------------
 
845
# See how the compiler implements dependency checking.
 
846
# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
 
847
# We try a few techniques and use that to set a single cache variable.
 
848
#
 
849
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
 
850
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
 
851
# dependency, and given that the user is not expected to run this macro,
 
852
# just rely on AC_PROG_CC.
 
853
AC_DEFUN([_AM_DEPENDENCIES],
 
854
[AC_REQUIRE([AM_SET_DEPDIR])dnl
 
855
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
 
856
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
 
857
AC_REQUIRE([AM_DEP_TRACK])dnl
 
858
 
 
859
m4_if([$1], [CC],   [depcc="$CC"   am_compiler_list=],
 
860
      [$1], [CXX],  [depcc="$CXX"  am_compiler_list=],
 
861
      [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
 
862
      [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
 
863
      [$1], [UPC],  [depcc="$UPC"  am_compiler_list=],
 
864
      [$1], [GCJ],  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
 
865
                    [depcc="$$1"   am_compiler_list=])
 
866
 
 
867
AC_CACHE_CHECK([dependency style of $depcc],
 
868
               [am_cv_$1_dependencies_compiler_type],
 
869
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
 
870
  # We make a subdir and do the tests there.  Otherwise we can end up
 
871
  # making bogus files that we don't know about and never remove.  For
 
872
  # instance it was reported that on HP-UX the gcc test will end up
 
873
  # making a dummy file named 'D' -- because '-MD' means "put the output
 
874
  # in D".
 
875
  rm -rf conftest.dir
 
876
  mkdir conftest.dir
 
877
  # Copy depcomp to subdir because otherwise we won't find it if we're
 
878
  # using a relative directory.
 
879
  cp "$am_depcomp" conftest.dir
 
880
  cd conftest.dir
 
881
  # We will build objects and dependencies in a subdirectory because
 
882
  # it helps to detect inapplicable dependency modes.  For instance
 
883
  # both Tru64's cc and ICC support -MD to output dependencies as a
 
884
  # side effect of compilation, but ICC will put the dependencies in
 
885
  # the current directory while Tru64 will put them in the object
 
886
  # directory.
 
887
  mkdir sub
 
888
 
 
889
  am_cv_$1_dependencies_compiler_type=none
 
890
  if test "$am_compiler_list" = ""; then
 
891
     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
 
892
  fi
 
893
  am__universal=false
 
894
  m4_case([$1], [CC],
 
895
    [case " $depcc " in #(
 
896
     *\ -arch\ *\ -arch\ *) am__universal=true ;;
 
897
     esac],
 
898
    [CXX],
 
899
    [case " $depcc " in #(
 
900
     *\ -arch\ *\ -arch\ *) am__universal=true ;;
 
901
     esac])
 
902
 
 
903
  for depmode in $am_compiler_list; do
 
904
    # Setup a source with many dependencies, because some compilers
 
905
    # like to wrap large dependency lists on column 80 (with \), and
 
906
    # we should not choose a depcomp mode which is confused by this.
 
907
    #
 
908
    # We need to recreate these files for each test, as the compiler may
 
909
    # overwrite some of them when testing with obscure command lines.
 
910
    # This happens at least with the AIX C compiler.
 
911
    : > sub/conftest.c
 
912
    for i in 1 2 3 4 5 6; do
 
913
      echo '#include "conftst'$i'.h"' >> sub/conftest.c
 
914
      # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
 
915
      # Solaris 10 /bin/sh.
 
916
      echo '/* dummy */' > sub/conftst$i.h
 
917
    done
 
918
    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
 
919
 
 
920
    # We check with '-c' and '-o' for the sake of the "dashmstdout"
 
921
    # mode.  It turns out that the SunPro C++ compiler does not properly
 
922
    # handle '-M -o', and we need to detect this.  Also, some Intel
 
923
    # versions had trouble with output in subdirs.
 
924
    am__obj=sub/conftest.${OBJEXT-o}
 
925
    am__minus_obj="-o $am__obj"
 
926
    case $depmode in
 
927
    gcc)
 
928
      # This depmode causes a compiler race in universal mode.
 
929
      test "$am__universal" = false || continue
 
930
      ;;
 
931
    nosideeffect)
 
932
      # After this tag, mechanisms are not by side-effect, so they'll
 
933
      # only be used when explicitly requested.
 
934
      if test "x$enable_dependency_tracking" = xyes; then
 
935
        continue
 
936
      else
 
937
        break
 
938
      fi
 
939
      ;;
 
940
    msvc7 | msvc7msys | msvisualcpp | msvcmsys)
 
941
      # This compiler won't grok '-c -o', but also, the minuso test has
 
942
      # not run yet.  These depmodes are late enough in the game, and
 
943
      # so weak that their functioning should not be impacted.
 
944
      am__obj=conftest.${OBJEXT-o}
 
945
      am__minus_obj=
 
946
      ;;
 
947
    none) break ;;
 
948
    esac
 
949
    if depmode=$depmode \
 
950
       source=sub/conftest.c object=$am__obj \
 
951
       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
 
952
       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
 
953
         >/dev/null 2>conftest.err &&
 
954
       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
 
955
       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
 
956
       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
 
957
       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
 
958
      # icc doesn't choke on unknown options, it will just issue warnings
 
959
      # or remarks (even with -Werror).  So we grep stderr for any message
 
960
      # that says an option was ignored or not supported.
 
961
      # When given -MP, icc 7.0 and 7.1 complain thusly:
 
962
      #   icc: Command line warning: ignoring option '-M'; no argument required
 
963
      # The diagnosis changed in icc 8.0:
 
964
      #   icc: Command line remark: option '-MP' not supported
 
965
      if (grep 'ignoring option' conftest.err ||
 
966
          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
 
967
        am_cv_$1_dependencies_compiler_type=$depmode
 
968
        break
 
969
      fi
 
970
    fi
 
971
  done
 
972
 
 
973
  cd ..
 
974
  rm -rf conftest.dir
 
975
else
 
976
  am_cv_$1_dependencies_compiler_type=none
 
977
fi
 
978
])
 
979
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
 
980
AM_CONDITIONAL([am__fastdep$1], [
 
981
  test "x$enable_dependency_tracking" != xno \
 
982
  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
 
983
])
 
984
 
 
985
 
 
986
# AM_SET_DEPDIR
 
987
# -------------
 
988
# Choose a directory name for dependency files.
 
989
# This macro is AC_REQUIREd in _AM_DEPENDENCIES.
 
990
AC_DEFUN([AM_SET_DEPDIR],
 
991
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 
992
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
 
993
])
 
994
 
 
995
 
 
996
# AM_DEP_TRACK
 
997
# ------------
 
998
AC_DEFUN([AM_DEP_TRACK],
 
999
[AC_ARG_ENABLE([dependency-tracking], [dnl
 
1000
AS_HELP_STRING(
 
1001
  [--enable-dependency-tracking],
 
1002
  [do not reject slow dependency extractors])
 
1003
AS_HELP_STRING(
 
1004
  [--disable-dependency-tracking],
 
1005
  [speeds up one-time build])])
 
1006
if test "x$enable_dependency_tracking" != xno; then
 
1007
  am_depcomp="$ac_aux_dir/depcomp"
 
1008
  AMDEPBACKSLASH='\'
 
1009
  am__nodep='_no'
 
1010
fi
 
1011
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
 
1012
AC_SUBST([AMDEPBACKSLASH])dnl
 
1013
_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
 
1014
AC_SUBST([am__nodep])dnl
 
1015
_AM_SUBST_NOTMAKE([am__nodep])dnl
 
1016
])
 
1017
 
 
1018
# Generate code to set up dependency tracking.              -*- Autoconf -*-
 
1019
 
 
1020
# Copyright (C) 1999-2013 Free Software Foundation, Inc.
 
1021
#
 
1022
# This file is free software; the Free Software Foundation
 
1023
# gives unlimited permission to copy and/or distribute it,
 
1024
# with or without modifications, as long as this notice is preserved.
 
1025
 
 
1026
 
 
1027
# _AM_OUTPUT_DEPENDENCY_COMMANDS
 
1028
# ------------------------------
 
1029
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
 
1030
[{
 
1031
  # Older Autoconf quotes --file arguments for eval, but not when files
 
1032
  # are listed without --file.  Let's play safe and only enable the eval
 
1033
  # if we detect the quoting.
 
1034
  case $CONFIG_FILES in
 
1035
  *\'*) eval set x "$CONFIG_FILES" ;;
 
1036
  *)   set x $CONFIG_FILES ;;
 
1037
  esac
 
1038
  shift
 
1039
  for mf
 
1040
  do
 
1041
    # Strip MF so we end up with the name of the file.
 
1042
    mf=`echo "$mf" | sed -e 's/:.*$//'`
 
1043
    # Check whether this is an Automake generated Makefile or not.
 
1044
    # We used to match only the files named 'Makefile.in', but
 
1045
    # some people rename them; so instead we look at the file content.
 
1046
    # Grep'ing the first line is not enough: some people post-process
 
1047
    # each Makefile.in and add a new line on top of each file to say so.
 
1048
    # Grep'ing the whole file is not good either: AIX grep has a line
 
1049
    # limit of 2048, but all sed's we know have understand at least 4000.
 
1050
    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
 
1051
      dirpart=`AS_DIRNAME("$mf")`
 
1052
    else
 
1053
      continue
 
1054
    fi
 
1055
    # Extract the definition of DEPDIR, am__include, and am__quote
 
1056
    # from the Makefile without running 'make'.
 
1057
    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
 
1058
    test -z "$DEPDIR" && continue
 
1059
    am__include=`sed -n 's/^am__include = //p' < "$mf"`
 
1060
    test -z "$am__include" && continue
 
1061
    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
 
1062
    # Find all dependency output files, they are included files with
 
1063
    # $(DEPDIR) in their names.  We invoke sed twice because it is the
 
1064
    # simplest approach to changing $(DEPDIR) to its actual value in the
 
1065
    # expansion.
 
1066
    for file in `sed -n "
 
1067
      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
 
1068
         sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
 
1069
      # Make sure the directory exists.
 
1070
      test -f "$dirpart/$file" && continue
 
1071
      fdir=`AS_DIRNAME(["$file"])`
 
1072
      AS_MKDIR_P([$dirpart/$fdir])
 
1073
      # echo "creating $dirpart/$file"
 
1074
      echo '# dummy' > "$dirpart/$file"
 
1075
    done
 
1076
  done
 
1077
}
 
1078
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
 
1079
 
 
1080
 
 
1081
# AM_OUTPUT_DEPENDENCY_COMMANDS
 
1082
# -----------------------------
 
1083
# This macro should only be invoked once -- use via AC_REQUIRE.
 
1084
#
 
1085
# This code is only required when automatic dependency tracking
 
1086
# is enabled.  FIXME.  This creates each '.P' file that we will
 
1087
# need in order to bootstrap the dependency handling code.
 
1088
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 
1089
[AC_CONFIG_COMMANDS([depfiles],
 
1090
     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
 
1091
     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
 
1092
])
 
1093
 
 
1094
# Do all the work for Automake.                             -*- Autoconf -*-
 
1095
 
 
1096
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 
1097
#
 
1098
# This file is free software; the Free Software Foundation
 
1099
# gives unlimited permission to copy and/or distribute it,
 
1100
# with or without modifications, as long as this notice is preserved.
 
1101
 
 
1102
# This macro actually does too much.  Some checks are only needed if
 
1103
# your package does certain things.  But this isn't really a big deal.
 
1104
 
 
1105
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
 
1106
# AM_INIT_AUTOMAKE([OPTIONS])
 
1107
# -----------------------------------------------
 
1108
# The call with PACKAGE and VERSION arguments is the old style
 
1109
# call (pre autoconf-2.50), which is being phased out.  PACKAGE
 
1110
# and VERSION should now be passed to AC_INIT and removed from
 
1111
# the call to AM_INIT_AUTOMAKE.
 
1112
# We support both call styles for the transition.  After
 
1113
# the next Automake release, Autoconf can make the AC_INIT
 
1114
# arguments mandatory, and then we can depend on a new Autoconf
 
1115
# release and drop the old call support.
 
1116
AC_DEFUN([AM_INIT_AUTOMAKE],
 
1117
[AC_PREREQ([2.65])dnl
 
1118
dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 
1119
dnl the ones we care about.
 
1120
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
 
1121
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
 
1122
AC_REQUIRE([AC_PROG_INSTALL])dnl
 
1123
if test "`cd $srcdir && pwd`" != "`pwd`"; then
 
1124
  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
 
1125
  # is not polluted with repeated "-I."
 
1126
  AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
 
1127
  # test to see if srcdir already configured
 
1128
  if test -f $srcdir/config.status; then
 
1129
    AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
 
1130
  fi
 
1131
fi
 
1132
 
 
1133
# test whether we have cygpath
 
1134
if test -z "$CYGPATH_W"; then
 
1135
  if (cygpath --version) >/dev/null 2>/dev/null; then
 
1136
    CYGPATH_W='cygpath -w'
 
1137
  else
 
1138
    CYGPATH_W=echo
 
1139
  fi
 
1140
fi
 
1141
AC_SUBST([CYGPATH_W])
 
1142
 
 
1143
# Define the identity of the package.
 
1144
dnl Distinguish between old-style and new-style calls.
 
1145
m4_ifval([$2],
 
1146
[AC_DIAGNOSE([obsolete],
 
1147
             [$0: two- and three-arguments forms are deprecated.])
 
1148
m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
 
1149
 AC_SUBST([PACKAGE], [$1])dnl
 
1150
 AC_SUBST([VERSION], [$2])],
 
1151
[_AM_SET_OPTIONS([$1])dnl
 
1152
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
 
1153
m4_if(
 
1154
  m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
 
1155
  [ok:ok],,
 
1156
  [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
 
1157
 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
 
1158
 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
 
1159
 
 
1160
_AM_IF_OPTION([no-define],,
 
1161
[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
 
1162
 AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
 
1163
 
 
1164
# Some tools Automake needs.
 
1165
AC_REQUIRE([AM_SANITY_CHECK])dnl
 
1166
AC_REQUIRE([AC_ARG_PROGRAM])dnl
 
1167
AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
 
1168
AM_MISSING_PROG([AUTOCONF], [autoconf])
 
1169
AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
 
1170
AM_MISSING_PROG([AUTOHEADER], [autoheader])
 
1171
AM_MISSING_PROG([MAKEINFO], [makeinfo])
 
1172
AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 
1173
AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
 
1174
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
 
1175
# For better backward compatibility.  To be removed once Automake 1.9.x
 
1176
# dies out for good.  For more background, see:
 
1177
# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
 
1178
# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
 
1179
AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
 
1180
# We need awk for the "check" target.  The system "awk" is bad on
 
1181
# some platforms.
 
1182
AC_REQUIRE([AC_PROG_AWK])dnl
 
1183
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 
1184
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 
1185
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
 
1186
              [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
 
1187
                             [_AM_PROG_TAR([v7])])])
 
1188
_AM_IF_OPTION([no-dependencies],,
 
1189
[AC_PROVIDE_IFELSE([AC_PROG_CC],
 
1190
                  [_AM_DEPENDENCIES([CC])],
 
1191
                  [m4_define([AC_PROG_CC],
 
1192
                             m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
 
1193
AC_PROVIDE_IFELSE([AC_PROG_CXX],
 
1194
                  [_AM_DEPENDENCIES([CXX])],
 
1195
                  [m4_define([AC_PROG_CXX],
 
1196
                             m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
 
1197
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
 
1198
                  [_AM_DEPENDENCIES([OBJC])],
 
1199
                  [m4_define([AC_PROG_OBJC],
 
1200
                             m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
 
1201
AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
 
1202
                  [_AM_DEPENDENCIES([OBJCXX])],
 
1203
                  [m4_define([AC_PROG_OBJCXX],
 
1204
                             m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
 
1205
])
 
1206
AC_REQUIRE([AM_SILENT_RULES])dnl
 
1207
dnl The testsuite driver may need to know about EXEEXT, so add the
 
1208
dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This
 
1209
dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
 
1210
AC_CONFIG_COMMANDS_PRE(dnl
 
1211
[m4_provide_if([_AM_COMPILER_EXEEXT],
 
1212
  [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
 
1213
])
 
1214
 
 
1215
dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
 
1216
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
 
1217
dnl mangled by Autoconf and run in a shell conditional statement.
 
1218
m4_define([_AC_COMPILER_EXEEXT],
 
1219
m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
 
1220
 
 
1221
 
 
1222
# When config.status generates a header, we must update the stamp-h file.
 
1223
# This file resides in the same directory as the config header
 
1224
# that is generated.  The stamp files are numbered to have different names.
 
1225
 
 
1226
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
 
1227
# loop where config.status creates the headers, so we can generate
 
1228
# our stamp files there.
 
1229
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
 
1230
[# Compute $1's index in $config_headers.
 
1231
_am_arg=$1
 
1232
_am_stamp_count=1
 
1233
for _am_header in $config_headers :; do
 
1234
  case $_am_header in
 
1235
    $_am_arg | $_am_arg:* )
 
1236
      break ;;
 
1237
    * )
 
1238
      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
 
1239
  esac
 
1240
done
 
1241
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
1242
 
 
1243
# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 
1244
#
 
1245
# This file is free software; the Free Software Foundation
 
1246
# gives unlimited permission to copy and/or distribute it,
 
1247
# with or without modifications, as long as this notice is preserved.
 
1248
 
 
1249
# AM_PROG_INSTALL_SH
 
1250
# ------------------
 
1251
# Define $install_sh.
 
1252
AC_DEFUN([AM_PROG_INSTALL_SH],
 
1253
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 
1254
if test x"${install_sh}" != xset; then
 
1255
  case $am_aux_dir in
 
1256
  *\ * | *\     *)
 
1257
    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
 
1258
  *)
 
1259
    install_sh="\${SHELL} $am_aux_dir/install-sh"
 
1260
  esac
 
1261
fi
 
1262
AC_SUBST([install_sh])])
 
1263
 
 
1264
# Copyright (C) 2003-2013 Free Software Foundation, Inc.
 
1265
#
 
1266
# This file is free software; the Free Software Foundation
 
1267
# gives unlimited permission to copy and/or distribute it,
 
1268
# with or without modifications, as long as this notice is preserved.
 
1269
 
 
1270
# Check whether the underlying file-system supports filenames
 
1271
# with a leading dot.  For instance MS-DOS doesn't.
 
1272
AC_DEFUN([AM_SET_LEADING_DOT],
 
1273
[rm -rf .tst 2>/dev/null
 
1274
mkdir .tst 2>/dev/null
 
1275
if test -d .tst; then
 
1276
  am__leading_dot=.
 
1277
else
 
1278
  am__leading_dot=_
 
1279
fi
 
1280
rmdir .tst 2>/dev/null
 
1281
AC_SUBST([am__leading_dot])])
 
1282
 
 
1283
# Add --enable-maintainer-mode option to configure.         -*- Autoconf -*-
 
1284
# From Jim Meyering
 
1285
 
 
1286
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 
1287
#
 
1288
# This file is free software; the Free Software Foundation
 
1289
# gives unlimited permission to copy and/or distribute it,
 
1290
# with or without modifications, as long as this notice is preserved.
 
1291
 
 
1292
# AM_MAINTAINER_MODE([DEFAULT-MODE])
 
1293
# ----------------------------------
 
1294
# Control maintainer-specific portions of Makefiles.
 
1295
# Default is to disable them, unless 'enable' is passed literally.
 
1296
# For symmetry, 'disable' may be passed as well.  Anyway, the user
 
1297
# can override the default with the --enable/--disable switch.
 
1298
AC_DEFUN([AM_MAINTAINER_MODE],
 
1299
[m4_case(m4_default([$1], [disable]),
 
1300
       [enable], [m4_define([am_maintainer_other], [disable])],
 
1301
       [disable], [m4_define([am_maintainer_other], [enable])],
 
1302
       [m4_define([am_maintainer_other], [enable])
 
1303
        m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
 
1304
AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
 
1305
  dnl maintainer-mode's default is 'disable' unless 'enable' is passed
 
1306
  AC_ARG_ENABLE([maintainer-mode],
 
1307
    [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
 
1308
      am_maintainer_other[ make rules and dependencies not useful
 
1309
      (and sometimes confusing) to the casual installer])],
 
1310
    [USE_MAINTAINER_MODE=$enableval],
 
1311
    [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
 
1312
  AC_MSG_RESULT([$USE_MAINTAINER_MODE])
 
1313
  AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
 
1314
  MAINT=$MAINTAINER_MODE_TRUE
 
1315
  AC_SUBST([MAINT])dnl
 
1316
]
 
1317
)
 
1318
 
 
1319
# Check to see how 'make' treats includes.                  -*- Autoconf -*-
 
1320
 
 
1321
# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 
1322
#
 
1323
# This file is free software; the Free Software Foundation
 
1324
# gives unlimited permission to copy and/or distribute it,
 
1325
# with or without modifications, as long as this notice is preserved.
 
1326
 
 
1327
# AM_MAKE_INCLUDE()
 
1328
# -----------------
 
1329
# Check to see how make treats includes.
 
1330
AC_DEFUN([AM_MAKE_INCLUDE],
 
1331
[am_make=${MAKE-make}
 
1332
cat > confinc << 'END'
 
1333
am__doit:
 
1334
        @echo this is the am__doit target
 
1335
.PHONY: am__doit
 
1336
END
 
1337
# If we don't find an include directive, just comment out the code.
 
1338
AC_MSG_CHECKING([for style of include used by $am_make])
 
1339
am__include="#"
 
1340
am__quote=
 
1341
_am_result=none
 
1342
# First try GNU make style include.
 
1343
echo "include confinc" > confmf
 
1344
# Ignore all kinds of additional output from 'make'.
 
1345
case `$am_make -s -f confmf 2> /dev/null` in #(
 
1346
*the\ am__doit\ target*)
 
1347
  am__include=include
 
1348
  am__quote=
 
1349
  _am_result=GNU
 
1350
  ;;
 
1351
esac
 
1352
# Now try BSD make style include.
 
1353
if test "$am__include" = "#"; then
 
1354
   echo '.include "confinc"' > confmf
 
1355
   case `$am_make -s -f confmf 2> /dev/null` in #(
 
1356
   *the\ am__doit\ target*)
 
1357
     am__include=.include
 
1358
     am__quote="\""
 
1359
     _am_result=BSD
 
1360
     ;;
 
1361
   esac
 
1362
fi
 
1363
AC_SUBST([am__include])
 
1364
AC_SUBST([am__quote])
 
1365
AC_MSG_RESULT([$_am_result])
 
1366
rm -f confinc confmf
 
1367
])
 
1368
 
 
1369
# Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
1370
 
 
1371
# Copyright (C) 1997-2013 Free Software Foundation, Inc.
 
1372
#
 
1373
# This file is free software; the Free Software Foundation
 
1374
# gives unlimited permission to copy and/or distribute it,
 
1375
# with or without modifications, as long as this notice is preserved.
 
1376
 
 
1377
# AM_MISSING_PROG(NAME, PROGRAM)
 
1378
# ------------------------------
 
1379
AC_DEFUN([AM_MISSING_PROG],
 
1380
[AC_REQUIRE([AM_MISSING_HAS_RUN])
 
1381
$1=${$1-"${am_missing_run}$2"}
 
1382
AC_SUBST($1)])
 
1383
 
 
1384
# AM_MISSING_HAS_RUN
 
1385
# ------------------
 
1386
# Define MISSING if not defined so far and test if it is modern enough.
 
1387
# If it is, set am_missing_run to use it, otherwise, to nothing.
 
1388
AC_DEFUN([AM_MISSING_HAS_RUN],
 
1389
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 
1390
AC_REQUIRE_AUX_FILE([missing])dnl
 
1391
if test x"${MISSING+set}" != xset; then
 
1392
  case $am_aux_dir in
 
1393
  *\ * | *\     *)
 
1394
    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
 
1395
  *)
 
1396
    MISSING="\${SHELL} $am_aux_dir/missing" ;;
 
1397
  esac
 
1398
fi
 
1399
# Use eval to expand $SHELL
 
1400
if eval "$MISSING --is-lightweight"; then
 
1401
  am_missing_run="$MISSING "
 
1402
else
 
1403
  am_missing_run=
 
1404
  AC_MSG_WARN(['missing' script is too old or missing])
 
1405
fi
 
1406
])
 
1407
 
 
1408
# Helper functions for option handling.                     -*- Autoconf -*-
 
1409
 
 
1410
# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 
1411
#
 
1412
# This file is free software; the Free Software Foundation
 
1413
# gives unlimited permission to copy and/or distribute it,
 
1414
# with or without modifications, as long as this notice is preserved.
 
1415
 
 
1416
# _AM_MANGLE_OPTION(NAME)
 
1417
# -----------------------
 
1418
AC_DEFUN([_AM_MANGLE_OPTION],
 
1419
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
 
1420
 
 
1421
# _AM_SET_OPTION(NAME)
 
1422
# --------------------
 
1423
# Set option NAME.  Presently that only means defining a flag for this option.
 
1424
AC_DEFUN([_AM_SET_OPTION],
 
1425
[m4_define(_AM_MANGLE_OPTION([$1]), [1])])
 
1426
 
 
1427
# _AM_SET_OPTIONS(OPTIONS)
 
1428
# ------------------------
 
1429
# OPTIONS is a space-separated list of Automake options.
 
1430
AC_DEFUN([_AM_SET_OPTIONS],
 
1431
[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
 
1432
 
 
1433
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 
1434
# -------------------------------------------
 
1435
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
 
1436
AC_DEFUN([_AM_IF_OPTION],
 
1437
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
1438
 
 
1439
# Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
1440
 
 
1441
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 
1442
#
 
1443
# This file is free software; the Free Software Foundation
 
1444
# gives unlimited permission to copy and/or distribute it,
 
1445
# with or without modifications, as long as this notice is preserved.
 
1446
 
 
1447
# AM_SANITY_CHECK
 
1448
# ---------------
 
1449
AC_DEFUN([AM_SANITY_CHECK],
 
1450
[AC_MSG_CHECKING([whether build environment is sane])
 
1451
# Reject unsafe characters in $srcdir or the absolute working directory
 
1452
# name.  Accept space and tab only in the latter.
 
1453
am_lf='
 
1454
'
 
1455
case `pwd` in
 
1456
  *[[\\\"\#\$\&\'\`$am_lf]]*)
 
1457
    AC_MSG_ERROR([unsafe absolute working directory name]);;
 
1458
esac
 
1459
case $srcdir in
 
1460
  *[[\\\"\#\$\&\'\`$am_lf\ \    ]]*)
 
1461
    AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
 
1462
esac
 
1463
 
 
1464
# Do 'set' in a subshell so we don't clobber the current shell's
 
1465
# arguments.  Must try -L first in case configure is actually a
 
1466
# symlink; some systems play weird games with the mod time of symlinks
 
1467
# (eg FreeBSD returns the mod time of the symlink's containing
 
1468
# directory).
 
1469
if (
 
1470
   am_has_slept=no
 
1471
   for am_try in 1 2; do
 
1472
     echo "timestamp, slept: $am_has_slept" > conftest.file
 
1473
     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
 
1474
     if test "$[*]" = "X"; then
 
1475
        # -L didn't work.
 
1476
        set X `ls -t "$srcdir/configure" conftest.file`
 
1477
     fi
 
1478
     if test "$[*]" != "X $srcdir/configure conftest.file" \
 
1479
        && test "$[*]" != "X conftest.file $srcdir/configure"; then
 
1480
 
 
1481
        # If neither matched, then we have a broken ls.  This can happen
 
1482
        # if, for instance, CONFIG_SHELL is bash and it inherits a
 
1483
        # broken ls alias from the environment.  This has actually
 
1484
        # happened.  Such a system could not be considered "sane".
 
1485
        AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
 
1486
  alias in your environment])
 
1487
     fi
 
1488
     if test "$[2]" = conftest.file || test $am_try -eq 2; then
 
1489
       break
 
1490
     fi
 
1491
     # Just in case.
 
1492
     sleep 1
 
1493
     am_has_slept=yes
 
1494
   done
 
1495
   test "$[2]" = conftest.file
 
1496
   )
 
1497
then
 
1498
   # Ok.
 
1499
   :
 
1500
else
 
1501
   AC_MSG_ERROR([newly created file is older than distributed files!
 
1502
Check your system clock])
 
1503
fi
 
1504
AC_MSG_RESULT([yes])
 
1505
# If we didn't sleep, we still need to ensure time stamps of config.status and
 
1506
# generated files are strictly newer.
 
1507
am_sleep_pid=
 
1508
if grep 'slept: no' conftest.file >/dev/null 2>&1; then
 
1509
  ( sleep 1 ) &
 
1510
  am_sleep_pid=$!
 
1511
fi
 
1512
AC_CONFIG_COMMANDS_PRE(
 
1513
  [AC_MSG_CHECKING([that generated files are newer than configure])
 
1514
   if test -n "$am_sleep_pid"; then
 
1515
     # Hide warnings about reused PIDs.
 
1516
     wait $am_sleep_pid 2>/dev/null
 
1517
   fi
 
1518
   AC_MSG_RESULT([done])])
 
1519
rm -f conftest.file
 
1520
])
 
1521
 
 
1522
# Copyright (C) 2009-2013 Free Software Foundation, Inc.
 
1523
#
 
1524
# This file is free software; the Free Software Foundation
 
1525
# gives unlimited permission to copy and/or distribute it,
 
1526
# with or without modifications, as long as this notice is preserved.
 
1527
 
 
1528
# AM_SILENT_RULES([DEFAULT])
 
1529
# --------------------------
 
1530
# Enable less verbose build rules; with the default set to DEFAULT
 
1531
# ("yes" being less verbose, "no" or empty being verbose).
 
1532
AC_DEFUN([AM_SILENT_RULES],
 
1533
[AC_ARG_ENABLE([silent-rules], [dnl
 
1534
AS_HELP_STRING(
 
1535
  [--enable-silent-rules],
 
1536
  [less verbose build output (undo: "make V=1")])
 
1537
AS_HELP_STRING(
 
1538
  [--disable-silent-rules],
 
1539
  [verbose build output (undo: "make V=0")])dnl
 
1540
])
 
1541
case $enable_silent_rules in @%:@ (((
 
1542
  yes) AM_DEFAULT_VERBOSITY=0;;
 
1543
   no) AM_DEFAULT_VERBOSITY=1;;
 
1544
    *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
 
1545
esac
 
1546
dnl
 
1547
dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
 
1548
dnl do not support nested variable expansions.
 
1549
dnl See automake bug#9928 and bug#10237.
 
1550
am_make=${MAKE-make}
 
1551
AC_CACHE_CHECK([whether $am_make supports nested variables],
 
1552
   [am_cv_make_support_nested_variables],
 
1553
   [if AS_ECHO([['TRUE=$(BAR$(V))
 
1554
BAR0=false
 
1555
BAR1=true
 
1556
V=1
 
1557
am__doit:
 
1558
        @$(TRUE)
 
1559
.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
 
1560
  am_cv_make_support_nested_variables=yes
 
1561
else
 
1562
  am_cv_make_support_nested_variables=no
 
1563
fi])
 
1564
if test $am_cv_make_support_nested_variables = yes; then
 
1565
  dnl Using '$V' instead of '$(V)' breaks IRIX make.
 
1566
  AM_V='$(V)'
 
1567
  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
 
1568
else
 
1569
  AM_V=$AM_DEFAULT_VERBOSITY
 
1570
  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
 
1571
fi
 
1572
AC_SUBST([AM_V])dnl
 
1573
AM_SUBST_NOTMAKE([AM_V])dnl
 
1574
AC_SUBST([AM_DEFAULT_V])dnl
 
1575
AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
 
1576
AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
 
1577
AM_BACKSLASH='\'
 
1578
AC_SUBST([AM_BACKSLASH])dnl
 
1579
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
 
1580
])
 
1581
 
 
1582
# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 
1583
#
 
1584
# This file is free software; the Free Software Foundation
 
1585
# gives unlimited permission to copy and/or distribute it,
 
1586
# with or without modifications, as long as this notice is preserved.
 
1587
 
 
1588
# AM_PROG_INSTALL_STRIP
 
1589
# ---------------------
 
1590
# One issue with vendor 'install' (even GNU) is that you can't
 
1591
# specify the program used to strip binaries.  This is especially
 
1592
# annoying in cross-compiling environments, where the build's strip
 
1593
# is unlikely to handle the host's binaries.
 
1594
# Fortunately install-sh will honor a STRIPPROG variable, so we
 
1595
# always use install-sh in "make install-strip", and initialize
 
1596
# STRIPPROG with the value of the STRIP variable (set by the user).
 
1597
AC_DEFUN([AM_PROG_INSTALL_STRIP],
 
1598
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 
1599
# Installed binaries are usually stripped using 'strip' when the user
 
1600
# run "make install-strip".  However 'strip' might not be the right
 
1601
# tool to use in cross-compilation environments, therefore Automake
 
1602
# will honor the 'STRIP' environment variable to overrule this program.
 
1603
dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
 
1604
if test "$cross_compiling" != no; then
 
1605
  AC_CHECK_TOOL([STRIP], [strip], :)
 
1606
fi
 
1607
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 
1608
AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
1609
 
 
1610
# Copyright (C) 2006-2013 Free Software Foundation, Inc.
 
1611
#
 
1612
# This file is free software; the Free Software Foundation
 
1613
# gives unlimited permission to copy and/or distribute it,
 
1614
# with or without modifications, as long as this notice is preserved.
 
1615
 
 
1616
# _AM_SUBST_NOTMAKE(VARIABLE)
 
1617
# ---------------------------
 
1618
# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
 
1619
# This macro is traced by Automake.
 
1620
AC_DEFUN([_AM_SUBST_NOTMAKE])
 
1621
 
 
1622
# AM_SUBST_NOTMAKE(VARIABLE)
 
1623
# --------------------------
 
1624
# Public sister of _AM_SUBST_NOTMAKE.
 
1625
AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 
1626
 
 
1627
# Check how to create a tarball.                            -*- Autoconf -*-
 
1628
 
 
1629
# Copyright (C) 2004-2013 Free Software Foundation, Inc.
 
1630
#
 
1631
# This file is free software; the Free Software Foundation
 
1632
# gives unlimited permission to copy and/or distribute it,
 
1633
# with or without modifications, as long as this notice is preserved.
 
1634
 
 
1635
# _AM_PROG_TAR(FORMAT)
 
1636
# --------------------
 
1637
# Check how to create a tarball in format FORMAT.
 
1638
# FORMAT should be one of 'v7', 'ustar', or 'pax'.
 
1639
#
 
1640
# Substitute a variable $(am__tar) that is a command
 
1641
# writing to stdout a FORMAT-tarball containing the directory
 
1642
# $tardir.
 
1643
#     tardir=directory && $(am__tar) > result.tar
 
1644
#
 
1645
# Substitute a variable $(am__untar) that extract such
 
1646
# a tarball read from stdin.
 
1647
#     $(am__untar) < result.tar
 
1648
#
 
1649
AC_DEFUN([_AM_PROG_TAR],
 
1650
[# Always define AMTAR for backward compatibility.  Yes, it's still used
 
1651
# in the wild :-(  We should find a proper way to deprecate it ...
 
1652
AC_SUBST([AMTAR], ['$${TAR-tar}'])
 
1653
 
 
1654
# We'll loop over all known methods to create a tar archive until one works.
 
1655
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
 
1656
 
 
1657
m4_if([$1], [v7],
 
1658
  [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
 
1659
 
 
1660
  [m4_case([$1],
 
1661
    [ustar],
 
1662
     [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
 
1663
      # There is notably a 21 bits limit for the UID and the GID.  In fact,
 
1664
      # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
 
1665
      # and bug#13588).
 
1666
      am_max_uid=2097151 # 2^21 - 1
 
1667
      am_max_gid=$am_max_uid
 
1668
      # The $UID and $GID variables are not portable, so we need to resort
 
1669
      # to the POSIX-mandated id(1) utility.  Errors in the 'id' calls
 
1670
      # below are definitely unexpected, so allow the users to see them
 
1671
      # (that is, avoid stderr redirection).
 
1672
      am_uid=`id -u || echo unknown`
 
1673
      am_gid=`id -g || echo unknown`
 
1674
      AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
 
1675
      if test $am_uid -le $am_max_uid; then
 
1676
         AC_MSG_RESULT([yes])
 
1677
      else
 
1678
         AC_MSG_RESULT([no])
 
1679
         _am_tools=none
 
1680
      fi
 
1681
      AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
 
1682
      if test $am_gid -le $am_max_gid; then
 
1683
         AC_MSG_RESULT([yes])
 
1684
      else
 
1685
        AC_MSG_RESULT([no])
 
1686
        _am_tools=none
 
1687
      fi],
 
1688
 
 
1689
  [pax],
 
1690
    [],
 
1691
 
 
1692
  [m4_fatal([Unknown tar format])])
 
1693
 
 
1694
  AC_MSG_CHECKING([how to create a $1 tar archive])
 
1695
 
 
1696
  # Go ahead even if we have the value already cached.  We do so because we
 
1697
  # need to set the values for the 'am__tar' and 'am__untar' variables.
 
1698
  _am_tools=${am_cv_prog_tar_$1-$_am_tools}
 
1699
 
 
1700
  for _am_tool in $_am_tools; do
 
1701
    case $_am_tool in
 
1702
    gnutar)
 
1703
      for _am_tar in tar gnutar gtar; do
 
1704
        AM_RUN_LOG([$_am_tar --version]) && break
 
1705
      done
 
1706
      am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
 
1707
      am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
 
1708
      am__untar="$_am_tar -xf -"
 
1709
      ;;
 
1710
    plaintar)
 
1711
      # Must skip GNU tar: if it does not support --format= it doesn't create
 
1712
      # ustar tarball either.
 
1713
      (tar --version) >/dev/null 2>&1 && continue
 
1714
      am__tar='tar chf - "$$tardir"'
 
1715
      am__tar_='tar chf - "$tardir"'
 
1716
      am__untar='tar xf -'
 
1717
      ;;
 
1718
    pax)
 
1719
      am__tar='pax -L -x $1 -w "$$tardir"'
 
1720
      am__tar_='pax -L -x $1 -w "$tardir"'
 
1721
      am__untar='pax -r'
 
1722
      ;;
 
1723
    cpio)
 
1724
      am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
 
1725
      am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
 
1726
      am__untar='cpio -i -H $1 -d'
 
1727
      ;;
 
1728
    none)
 
1729
      am__tar=false
 
1730
      am__tar_=false
 
1731
      am__untar=false
 
1732
      ;;
 
1733
    esac
 
1734
 
 
1735
    # If the value was cached, stop now.  We just wanted to have am__tar
 
1736
    # and am__untar set.
 
1737
    test -n "${am_cv_prog_tar_$1}" && break
 
1738
 
 
1739
    # tar/untar a dummy directory, and stop if the command works.
 
1740
    rm -rf conftest.dir
 
1741
    mkdir conftest.dir
 
1742
    echo GrepMe > conftest.dir/file
 
1743
    AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
 
1744
    rm -rf conftest.dir
 
1745
    if test -s conftest.tar; then
 
1746
      AM_RUN_LOG([$am__untar <conftest.tar])
 
1747
      AM_RUN_LOG([cat conftest.dir/file])
 
1748
      grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
 
1749
    fi
 
1750
  done
 
1751
  rm -rf conftest.dir
 
1752
 
 
1753
  AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
 
1754
  AC_MSG_RESULT([$am_cv_prog_tar_$1])])
 
1755
 
 
1756
AC_SUBST([am__tar])
 
1757
AC_SUBST([am__untar])
 
1758
]) # _AM_PROG_TAR
 
1759