aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2018-10-18 17:44:00 +0200
committerChristian Grothoff <christian@grothoff.org>2018-10-18 17:44:00 +0200
commit7bbc25b0916b8eca88bfe11f799fe0612f231392 (patch)
tree2872c186b7148ef63a86751ee863aecdfc8101b1
parente3f0d7e7f1bad57faad649e59c416ebab755e690 (diff)
downloadgnunet-gtk-7bbc25b0916b8eca88bfe11f799fe0612f231392.tar.gz
gnunet-gtk-7bbc25b0916b8eca88bfe11f799fe0612f231392.zip
use modernized bootstrap script
-rw-r--r--INSTALL321
-rwxr-xr-xbootstrap22
-rw-r--r--m4/codeset.m426
-rw-r--r--m4/glibc2.m421
-rw-r--r--m4/glibc21.m436
-rw-r--r--m4/intdiv0.m463
-rw-r--r--m4/intldir.m46
-rw-r--r--m4/intmax.m432
-rw-r--r--m4/inttypes-pri.m436
-rw-r--r--m4/inttypes_h.m435
-rw-r--r--m4/lcmessage.m429
-rw-r--r--m4/lock.m4323
-rw-r--r--m4/longlong.m4124
-rw-r--r--m4/printf-posix.m434
-rw-r--r--m4/size_max.m4102
-rw-r--r--m4/stdint_h.m433
-rw-r--r--m4/uintmax_t.m430
-rw-r--r--m4/visibility.m449
-rw-r--r--m4/wchar_t.m426
-rw-r--r--m4/wint_t.m434
-rw-r--r--m4/xsize.m414
-rw-r--r--po/POTFILES.in3
22 files changed, 659 insertions, 740 deletions
diff --git a/INSTALL b/INSTALL
index 7d1c323b..8865734f 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,8 +1,8 @@
1Installation Instructions 1Installation Instructions
2************************* 2*************************
3 3
4Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, 4 Copyright (C) 1994-1996, 1999-2002, 2004-2016 Free Software
52006, 2007, 2008, 2009 Free Software Foundation, Inc. 5Foundation, Inc.
6 6
7 Copying and distribution of this file, with or without modification, 7 Copying and distribution of this file, with or without modification,
8are permitted in any medium without royalty provided the copyright 8are permitted in any medium without royalty provided the copyright
@@ -12,97 +12,96 @@ without warranty of any kind.
12Basic Installation 12Basic Installation
13================== 13==================
14 14
15 Briefly, the shell commands `./configure; make; make install' should 15 Briefly, the shell command './configure && make && make install'
16configure, build, and install this package. The following 16should configure, build, and install this package. The following
17more-detailed instructions are generic; see the `README' file for 17more-detailed instructions are generic; see the 'README' file for
18instructions specific to this package. Some packages provide this 18instructions specific to this package. Some packages provide this
19`INSTALL' file but do not implement all of the features documented 19'INSTALL' file but do not implement all of the features documented
20below. The lack of an optional feature in a given package is not 20below. The lack of an optional feature in a given package is not
21necessarily a bug. More recommendations for GNU packages can be found 21necessarily a bug. More recommendations for GNU packages can be found
22in *note Makefile Conventions: (standards)Makefile Conventions. 22in *note Makefile Conventions: (standards)Makefile Conventions.
23 23
24 The `configure' shell script attempts to guess correct values for 24 The 'configure' shell script attempts to guess correct values for
25various system-dependent variables used during compilation. It uses 25various system-dependent variables used during compilation. It uses
26those values to create a `Makefile' in each directory of the package. 26those values to create a 'Makefile' in each directory of the package.
27It may also create one or more `.h' files containing system-dependent 27It may also create one or more '.h' files containing system-dependent
28definitions. Finally, it creates a shell script `config.status' that 28definitions. Finally, it creates a shell script 'config.status' that
29you can run in the future to recreate the current configuration, and a 29you can run in the future to recreate the current configuration, and a
30file `config.log' containing compiler output (useful mainly for 30file 'config.log' containing compiler output (useful mainly for
31debugging `configure'). 31debugging 'configure').
32 32
33 It can also use an optional file (typically called `config.cache' 33 It can also use an optional file (typically called 'config.cache' and
34and enabled with `--cache-file=config.cache' or simply `-C') that saves 34enabled with '--cache-file=config.cache' or simply '-C') that saves the
35the results of its tests to speed up reconfiguring. Caching is 35results of its tests to speed up reconfiguring. Caching is disabled by
36disabled by default to prevent problems with accidental use of stale 36default to prevent problems with accidental use of stale cache files.
37cache files.
38 37
39 If you need to do unusual things to compile the package, please try 38 If you need to do unusual things to compile the package, please try
40to figure out how `configure' could check whether to do them, and mail 39to figure out how 'configure' could check whether to do them, and mail
41diffs or instructions to the address given in the `README' so they can 40diffs or instructions to the address given in the 'README' so they can
42be considered for the next release. If you are using the cache, and at 41be considered for the next release. If you are using the cache, and at
43some point `config.cache' contains results you don't want to keep, you 42some point 'config.cache' contains results you don't want to keep, you
44may remove or edit it. 43may remove or edit it.
45 44
46 The file `configure.ac' (or `configure.in') is used to create 45 The file 'configure.ac' (or 'configure.in') is used to create
47`configure' by a program called `autoconf'. You need `configure.ac' if 46'configure' by a program called 'autoconf'. You need 'configure.ac' if
48you want to change it or regenerate `configure' using a newer version 47you want to change it or regenerate 'configure' using a newer version of
49of `autoconf'. 48'autoconf'.
50 49
51 The simplest way to compile this package is: 50 The simplest way to compile this package is:
52 51
53 1. `cd' to the directory containing the package's source code and type 52 1. 'cd' to the directory containing the package's source code and type
54 `./configure' to configure the package for your system. 53 './configure' to configure the package for your system.
55 54
56 Running `configure' might take a while. While running, it prints 55 Running 'configure' might take a while. While running, it prints
57 some messages telling which features it is checking for. 56 some messages telling which features it is checking for.
58 57
59 2. Type `make' to compile the package. 58 2. Type 'make' to compile the package.
60 59
61 3. Optionally, type `make check' to run any self-tests that come with 60 3. Optionally, type 'make check' to run any self-tests that come with
62 the package, generally using the just-built uninstalled binaries. 61 the package, generally using the just-built uninstalled binaries.
63 62
64 4. Type `make install' to install the programs and any data files and 63 4. Type 'make install' to install the programs and any data files and
65 documentation. When installing into a prefix owned by root, it is 64 documentation. When installing into a prefix owned by root, it is
66 recommended that the package be configured and built as a regular 65 recommended that the package be configured and built as a regular
67 user, and only the `make install' phase executed with root 66 user, and only the 'make install' phase executed with root
68 privileges. 67 privileges.
69 68
70 5. Optionally, type `make installcheck' to repeat any self-tests, but 69 5. Optionally, type 'make installcheck' to repeat any self-tests, but
71 this time using the binaries in their final installed location. 70 this time using the binaries in their final installed location.
72 This target does not install anything. Running this target as a 71 This target does not install anything. Running this target as a
73 regular user, particularly if the prior `make install' required 72 regular user, particularly if the prior 'make install' required
74 root privileges, verifies that the installation completed 73 root privileges, verifies that the installation completed
75 correctly. 74 correctly.
76 75
77 6. You can remove the program binaries and object files from the 76 6. You can remove the program binaries and object files from the
78 source code directory by typing `make clean'. To also remove the 77 source code directory by typing 'make clean'. To also remove the
79 files that `configure' created (so you can compile the package for 78 files that 'configure' created (so you can compile the package for
80 a different kind of computer), type `make distclean'. There is 79 a different kind of computer), type 'make distclean'. There is
81 also a `make maintainer-clean' target, but that is intended mainly 80 also a 'make maintainer-clean' target, but that is intended mainly
82 for the package's developers. If you use it, you may have to get 81 for the package's developers. If you use it, you may have to get
83 all sorts of other programs in order to regenerate files that came 82 all sorts of other programs in order to regenerate files that came
84 with the distribution. 83 with the distribution.
85 84
86 7. Often, you can also type `make uninstall' to remove the installed 85 7. Often, you can also type 'make uninstall' to remove the installed
87 files again. In practice, not all packages have tested that 86 files again. In practice, not all packages have tested that
88 uninstallation works correctly, even though it is required by the 87 uninstallation works correctly, even though it is required by the
89 GNU Coding Standards. 88 GNU Coding Standards.
90 89
91 8. Some packages, particularly those that use Automake, provide `make 90 8. Some packages, particularly those that use Automake, provide 'make
92 distcheck', which can by used by developers to test that all other 91 distcheck', which can by used by developers to test that all other
93 targets like `make install' and `make uninstall' work correctly. 92 targets like 'make install' and 'make uninstall' work correctly.
94 This target is generally not run by end users. 93 This target is generally not run by end users.
95 94
96Compilers and Options 95Compilers and Options
97===================== 96=====================
98 97
99 Some systems require unusual options for compilation or linking that 98 Some systems require unusual options for compilation or linking that
100the `configure' script does not know about. Run `./configure --help' 99the 'configure' script does not know about. Run './configure --help'
101for details on some of the pertinent environment variables. 100for details on some of the pertinent environment variables.
102 101
103 You can give `configure' initial values for configuration parameters 102 You can give 'configure' initial values for configuration parameters
104by setting variables in the command line or in the environment. Here 103by setting variables in the command line or in the environment. Here is
105is an example: 104an example:
106 105
107 ./configure CC=c99 CFLAGS=-g LIBS=-lposix 106 ./configure CC=c99 CFLAGS=-g LIBS=-lposix
108 107
@@ -113,21 +112,21 @@ Compiling For Multiple Architectures
113 112
114 You can compile the package for more than one kind of computer at the 113 You can compile the package for more than one kind of computer at the
115same time, by placing the object files for each architecture in their 114same time, by placing the object files for each architecture in their
116own directory. To do this, you can use GNU `make'. `cd' to the 115own directory. To do this, you can use GNU 'make'. 'cd' to the
117directory where you want the object files and executables to go and run 116directory where you want the object files and executables to go and run
118the `configure' script. `configure' automatically checks for the 117the 'configure' script. 'configure' automatically checks for the source
119source code in the directory that `configure' is in and in `..'. This 118code in the directory that 'configure' is in and in '..'. This is known
120is known as a "VPATH" build. 119as a "VPATH" build.
121 120
122 With a non-GNU `make', it is safer to compile the package for one 121 With a non-GNU 'make', it is safer to compile the package for one
123architecture at a time in the source code directory. After you have 122architecture at a time in the source code directory. After you have
124installed the package for one architecture, use `make distclean' before 123installed the package for one architecture, use 'make distclean' before
125reconfiguring for another architecture. 124reconfiguring for another architecture.
126 125
127 On MacOS X 10.5 and later systems, you can create libraries and 126 On MacOS X 10.5 and later systems, you can create libraries and
128executables that work on multiple system types--known as "fat" or 127executables that work on multiple system types--known as "fat" or
129"universal" binaries--by specifying multiple `-arch' options to the 128"universal" binaries--by specifying multiple '-arch' options to the
130compiler but only a single `-arch' option to the preprocessor. Like 129compiler but only a single '-arch' option to the preprocessor. Like
131this: 130this:
132 131
133 ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ 132 ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
@@ -136,100 +135,104 @@ this:
136 135
137 This is not guaranteed to produce working output in all cases, you 136 This is not guaranteed to produce working output in all cases, you
138may have to build one architecture at a time and combine the results 137may have to build one architecture at a time and combine the results
139using the `lipo' tool if you have problems. 138using the 'lipo' tool if you have problems.
140 139
141Installation Names 140Installation Names
142================== 141==================
143 142
144 By default, `make install' installs the package's commands under 143 By default, 'make install' installs the package's commands under
145`/usr/local/bin', include files under `/usr/local/include', etc. You 144'/usr/local/bin', include files under '/usr/local/include', etc. You
146can specify an installation prefix other than `/usr/local' by giving 145can specify an installation prefix other than '/usr/local' by giving
147`configure' the option `--prefix=PREFIX', where PREFIX must be an 146'configure' the option '--prefix=PREFIX', where PREFIX must be an
148absolute file name. 147absolute file name.
149 148
150 You can specify separate installation prefixes for 149 You can specify separate installation prefixes for
151architecture-specific files and architecture-independent files. If you 150architecture-specific files and architecture-independent files. If you
152pass the option `--exec-prefix=PREFIX' to `configure', the package uses 151pass the option '--exec-prefix=PREFIX' to 'configure', the package uses
153PREFIX as the prefix for installing programs and libraries. 152PREFIX as the prefix for installing programs and libraries.
154Documentation and other data files still use the regular prefix. 153Documentation and other data files still use the regular prefix.
155 154
156 In addition, if you use an unusual directory layout you can give 155 In addition, if you use an unusual directory layout you can give
157options like `--bindir=DIR' to specify different values for particular 156options like '--bindir=DIR' to specify different values for particular
158kinds of files. Run `configure --help' for a list of the directories 157kinds of files. Run 'configure --help' for a list of the directories
159you can set and what kinds of files go in them. In general, the 158you can set and what kinds of files go in them. In general, the default
160default for these options is expressed in terms of `${prefix}', so that 159for these options is expressed in terms of '${prefix}', so that
161specifying just `--prefix' will affect all of the other directory 160specifying just '--prefix' will affect all of the other directory
162specifications that were not explicitly provided. 161specifications that were not explicitly provided.
163 162
164 The most portable way to affect installation locations is to pass the 163 The most portable way to affect installation locations is to pass the
165correct locations to `configure'; however, many packages provide one or 164correct locations to 'configure'; however, many packages provide one or
166both of the following shortcuts of passing variable assignments to the 165both of the following shortcuts of passing variable assignments to the
167`make install' command line to change installation locations without 166'make install' command line to change installation locations without
168having to reconfigure or recompile. 167having to reconfigure or recompile.
169 168
170 The first method involves providing an override variable for each 169 The first method involves providing an override variable for each
171affected directory. For example, `make install 170affected directory. For example, 'make install
172prefix=/alternate/directory' will choose an alternate location for all 171prefix=/alternate/directory' will choose an alternate location for all
173directory configuration variables that were expressed in terms of 172directory configuration variables that were expressed in terms of
174`${prefix}'. Any directories that were specified during `configure', 173'${prefix}'. Any directories that were specified during 'configure',
175but not in terms of `${prefix}', must each be overridden at install 174but not in terms of '${prefix}', must each be overridden at install time
176time for the entire installation to be relocated. The approach of 175for the entire installation to be relocated. The approach of makefile
177makefile variable overrides for each directory variable is required by 176variable overrides for each directory variable is required by the GNU
178the GNU Coding Standards, and ideally causes no recompilation. 177Coding Standards, and ideally causes no recompilation. However, some
179However, some platforms have known limitations with the semantics of 178platforms have known limitations with the semantics of shared libraries
180shared libraries that end up requiring recompilation when using this 179that end up requiring recompilation when using this method, particularly
181method, particularly noticeable in packages that use GNU Libtool. 180noticeable in packages that use GNU Libtool.
182 181
183 The second method involves providing the `DESTDIR' variable. For 182 The second method involves providing the 'DESTDIR' variable. For
184example, `make install DESTDIR=/alternate/directory' will prepend 183example, 'make install DESTDIR=/alternate/directory' will prepend
185`/alternate/directory' before all installation names. The approach of 184'/alternate/directory' before all installation names. The approach of
186`DESTDIR' overrides is not required by the GNU Coding Standards, and 185'DESTDIR' overrides is not required by the GNU Coding Standards, and
187does not work on platforms that have drive letters. On the other hand, 186does not work on platforms that have drive letters. On the other hand,
188it does better at avoiding recompilation issues, and works well even 187it does better at avoiding recompilation issues, and works well even
189when some directory options were not specified in terms of `${prefix}' 188when some directory options were not specified in terms of '${prefix}'
190at `configure' time. 189at 'configure' time.
191 190
192Optional Features 191Optional Features
193================= 192=================
194 193
195 If the package supports it, you can cause programs to be installed 194 If the package supports it, you can cause programs to be installed
196with an extra prefix or suffix on their names by giving `configure' the 195with an extra prefix or suffix on their names by giving 'configure' the
197option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. 196option '--program-prefix=PREFIX' or '--program-suffix=SUFFIX'.
198 197
199 Some packages pay attention to `--enable-FEATURE' options to 198 Some packages pay attention to '--enable-FEATURE' options to
200`configure', where FEATURE indicates an optional part of the package. 199'configure', where FEATURE indicates an optional part of the package.
201They may also pay attention to `--with-PACKAGE' options, where PACKAGE 200They may also pay attention to '--with-PACKAGE' options, where PACKAGE
202is something like `gnu-as' or `x' (for the X Window System). The 201is something like 'gnu-as' or 'x' (for the X Window System). The
203`README' should mention any `--enable-' and `--with-' options that the 202'README' should mention any '--enable-' and '--with-' options that the
204package recognizes. 203package recognizes.
205 204
206 For packages that use the X Window System, `configure' can usually 205 For packages that use the X Window System, 'configure' can usually
207find the X include and library files automatically, but if it doesn't, 206find the X include and library files automatically, but if it doesn't,
208you can use the `configure' options `--x-includes=DIR' and 207you can use the 'configure' options '--x-includes=DIR' and
209`--x-libraries=DIR' to specify their locations. 208'--x-libraries=DIR' to specify their locations.
210 209
211 Some packages offer the ability to configure how verbose the 210 Some packages offer the ability to configure how verbose the
212execution of `make' will be. For these packages, running `./configure 211execution of 'make' will be. For these packages, running './configure
213--enable-silent-rules' sets the default to minimal output, which can be 212--enable-silent-rules' sets the default to minimal output, which can be
214overridden with `make V=1'; while running `./configure 213overridden with 'make V=1'; while running './configure
215--disable-silent-rules' sets the default to verbose, which can be 214--disable-silent-rules' sets the default to verbose, which can be
216overridden with `make V=0'. 215overridden with 'make V=0'.
217 216
218Particular systems 217Particular systems
219================== 218==================
220 219
221 On HP-UX, the default C compiler is not ANSI C compatible. If GNU 220 On HP-UX, the default C compiler is not ANSI C compatible. If GNU CC
222CC is not installed, it is recommended to use the following options in 221is not installed, it is recommended to use the following options in
223order to use an ANSI C compiler: 222order to use an ANSI C compiler:
224 223
225 ./configure CC="cc -Ae -D_XOPEN_SOURCE=500" 224 ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
226 225
227and if that doesn't work, install pre-built binaries of GCC for HP-UX. 226and if that doesn't work, install pre-built binaries of GCC for HP-UX.
228 227
228 HP-UX 'make' updates targets which have the same time stamps as their
229prerequisites, which makes it generally unusable when shipped generated
230files such as 'configure' are involved. Use GNU 'make' instead.
231
229 On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot 232 On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
230parse its `<wchar.h>' header file. The option `-nodtk' can be used as 233parse its '<wchar.h>' header file. The option '-nodtk' can be used as a
231a workaround. If GNU CC is not installed, it is therefore recommended 234workaround. If GNU CC is not installed, it is therefore recommended to
232to try 235try
233 236
234 ./configure CC="cc" 237 ./configure CC="cc"
235 238
@@ -237,26 +240,26 @@ and if that doesn't work, try
237 240
238 ./configure CC="cc -nodtk" 241 ./configure CC="cc -nodtk"
239 242
240 On Solaris, don't put `/usr/ucb' early in your `PATH'. This 243 On Solaris, don't put '/usr/ucb' early in your 'PATH'. This
241directory contains several dysfunctional programs; working variants of 244directory contains several dysfunctional programs; working variants of
242these programs are available in `/usr/bin'. So, if you need `/usr/ucb' 245these programs are available in '/usr/bin'. So, if you need '/usr/ucb'
243in your `PATH', put it _after_ `/usr/bin'. 246in your 'PATH', put it _after_ '/usr/bin'.
244 247
245 On Haiku, software installed for all users goes in `/boot/common', 248 On Haiku, software installed for all users goes in '/boot/common',
246not `/usr/local'. It is recommended to use the following options: 249not '/usr/local'. It is recommended to use the following options:
247 250
248 ./configure --prefix=/boot/common 251 ./configure --prefix=/boot/common
249 252
250Specifying the System Type 253Specifying the System Type
251========================== 254==========================
252 255
253 There may be some features `configure' cannot figure out 256 There may be some features 'configure' cannot figure out
254automatically, but needs to determine by the type of machine the package 257automatically, but needs to determine by the type of machine the package
255will run on. Usually, assuming the package is built to be run on the 258will run on. Usually, assuming the package is built to be run on the
256_same_ architectures, `configure' can figure that out, but if it prints 259_same_ architectures, 'configure' can figure that out, but if it prints
257a message saying it cannot guess the machine type, give it the 260a message saying it cannot guess the machine type, give it the
258`--build=TYPE' option. TYPE can either be a short name for the system 261'--build=TYPE' option. TYPE can either be a short name for the system
259type, such as `sun4', or a canonical name which has the form: 262type, such as 'sun4', or a canonical name which has the form:
260 263
261 CPU-COMPANY-SYSTEM 264 CPU-COMPANY-SYSTEM
262 265
@@ -265,101 +268,101 @@ where SYSTEM can have one of these forms:
265 OS 268 OS
266 KERNEL-OS 269 KERNEL-OS
267 270
268 See the file `config.sub' for the possible values of each field. If 271 See the file 'config.sub' for the possible values of each field. If
269`config.sub' isn't included in this package, then this package doesn't 272'config.sub' isn't included in this package, then this package doesn't
270need to know the machine type. 273need to know the machine type.
271 274
272 If you are _building_ compiler tools for cross-compiling, you should 275 If you are _building_ compiler tools for cross-compiling, you should
273use the option `--target=TYPE' to select the type of system they will 276use the option '--target=TYPE' to select the type of system they will
274produce code for. 277produce code for.
275 278
276 If you want to _use_ a cross compiler, that generates code for a 279 If you want to _use_ a cross compiler, that generates code for a
277platform different from the build platform, you should specify the 280platform different from the build platform, you should specify the
278"host" platform (i.e., that on which the generated programs will 281"host" platform (i.e., that on which the generated programs will
279eventually be run) with `--host=TYPE'. 282eventually be run) with '--host=TYPE'.
280 283
281Sharing Defaults 284Sharing Defaults
282================ 285================
283 286
284 If you want to set default values for `configure' scripts to share, 287 If you want to set default values for 'configure' scripts to share,
285you can create a site shell script called `config.site' that gives 288you can create a site shell script called 'config.site' that gives
286default values for variables like `CC', `cache_file', and `prefix'. 289default values for variables like 'CC', 'cache_file', and 'prefix'.
287`configure' looks for `PREFIX/share/config.site' if it exists, then 290'configure' looks for 'PREFIX/share/config.site' if it exists, then
288`PREFIX/etc/config.site' if it exists. Or, you can set the 291'PREFIX/etc/config.site' if it exists. Or, you can set the
289`CONFIG_SITE' environment variable to the location of the site script. 292'CONFIG_SITE' environment variable to the location of the site script.
290A warning: not all `configure' scripts look for a site script. 293A warning: not all 'configure' scripts look for a site script.
291 294
292Defining Variables 295Defining Variables
293================== 296==================
294 297
295 Variables not defined in a site shell script can be set in the 298 Variables not defined in a site shell script can be set in the
296environment passed to `configure'. However, some packages may run 299environment passed to 'configure'. However, some packages may run
297configure again during the build, and the customized values of these 300configure again during the build, and the customized values of these
298variables may be lost. In order to avoid this problem, you should set 301variables may be lost. In order to avoid this problem, you should set
299them in the `configure' command line, using `VAR=value'. For example: 302them in the 'configure' command line, using 'VAR=value'. For example:
300 303
301 ./configure CC=/usr/local2/bin/gcc 304 ./configure CC=/usr/local2/bin/gcc
302 305
303causes the specified `gcc' to be used as the C compiler (unless it is 306causes the specified 'gcc' to be used as the C compiler (unless it is
304overridden in the site shell script). 307overridden in the site shell script).
305 308
306Unfortunately, this technique does not work for `CONFIG_SHELL' due to 309Unfortunately, this technique does not work for 'CONFIG_SHELL' due to an
307an Autoconf bug. Until the bug is fixed you can use this workaround: 310Autoconf limitation. Until the limitation is lifted, you can use this
311workaround:
308 312
309 CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash 313 CONFIG_SHELL=/bin/bash ./configure CONFIG_SHELL=/bin/bash
310 314
311`configure' Invocation 315'configure' Invocation
312====================== 316======================
313 317
314 `configure' recognizes the following options to control how it 318 'configure' recognizes the following options to control how it
315operates. 319operates.
316 320
317`--help' 321'--help'
318`-h' 322'-h'
319 Print a summary of all of the options to `configure', and exit. 323 Print a summary of all of the options to 'configure', and exit.
320 324
321`--help=short' 325'--help=short'
322`--help=recursive' 326'--help=recursive'
323 Print a summary of the options unique to this package's 327 Print a summary of the options unique to this package's
324 `configure', and exit. The `short' variant lists options used 328 'configure', and exit. The 'short' variant lists options used only
325 only in the top level, while the `recursive' variant lists options 329 in the top level, while the 'recursive' variant lists options also
326 also present in any nested packages. 330 present in any nested packages.
327 331
328`--version' 332'--version'
329`-V' 333'-V'
330 Print the version of Autoconf used to generate the `configure' 334 Print the version of Autoconf used to generate the 'configure'
331 script, and exit. 335 script, and exit.
332 336
333`--cache-file=FILE' 337'--cache-file=FILE'
334 Enable the cache: use and save the results of the tests in FILE, 338 Enable the cache: use and save the results of the tests in FILE,
335 traditionally `config.cache'. FILE defaults to `/dev/null' to 339 traditionally 'config.cache'. FILE defaults to '/dev/null' to
336 disable caching. 340 disable caching.
337 341
338`--config-cache' 342'--config-cache'
339`-C' 343'-C'
340 Alias for `--cache-file=config.cache'. 344 Alias for '--cache-file=config.cache'.
341 345
342`--quiet' 346'--quiet'
343`--silent' 347'--silent'
344`-q' 348'-q'
345 Do not print messages saying which checks are being made. To 349 Do not print messages saying which checks are being made. To
346 suppress all normal output, redirect it to `/dev/null' (any error 350 suppress all normal output, redirect it to '/dev/null' (any error
347 messages will still be shown). 351 messages will still be shown).
348 352
349`--srcdir=DIR' 353'--srcdir=DIR'
350 Look for the package's source code in directory DIR. Usually 354 Look for the package's source code in directory DIR. Usually
351 `configure' can determine that directory automatically. 355 'configure' can determine that directory automatically.
352 356
353`--prefix=DIR' 357'--prefix=DIR'
354 Use DIR as the installation prefix. *note Installation Names:: 358 Use DIR as the installation prefix. *note Installation Names:: for
355 for more details, including other options available for fine-tuning 359 more details, including other options available for fine-tuning the
356 the installation locations. 360 installation locations.
357 361
358`--no-create' 362'--no-create'
359`-n' 363'-n'
360 Run the configure checks, but stop before creating any output 364 Run the configure checks, but stop before creating any output
361 files. 365 files.
362 366
363`configure' also accepts some other, not widely useful, options. Run 367'configure' also accepts some other, not widely useful, options. Run
364`configure --help' for more details. 368'configure --help' for more details.
365
diff --git a/bootstrap b/bootstrap
index c5d20984..2875484f 100755
--- a/bootstrap
+++ b/bootstrap
@@ -1,8 +1,20 @@
1#!/bin/sh 1#!/bin/sh
2echo "Removing folder 'libltdl'..."
3rm -rf libltdl
2 4
3libtoolize --automake --copy --force 5echo "checking for libtoolize / libtool... "
4aclocal -I m4
5autoheader
6autoconf
7automake --add-missing --copy
8 6
7# This is more portable than `which' but comes with
8# the caveat of not(?) properly working on busybox's ash:
9existence()
10{
11 command -v "$1" >/dev/null 2>&1
12}
13
14if existence libtool || existence libtoolize || existence glibtoolize; then
15 autoreconf -if
16 . "contrib/pogen.sh"
17else
18 echo "*** No libtoolize (libtool) or libtool found, please install it ***" >&2;
19 exit 1
20fi
diff --git a/m4/codeset.m4 b/m4/codeset.m4
index 59535ebc..d7de8d67 100644
--- a/m4/codeset.m4
+++ b/m4/codeset.m4
@@ -1,23 +1,23 @@
1# codeset.m4 serial AM1 (gettext-0.10.40) 1# codeset.m4 serial 5 (gettext-0.18.2)
2dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. 2dnl Copyright (C) 2000-2002, 2006, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10 8
11AC_DEFUN([AM_LANGINFO_CODESET], 9AC_DEFUN([AM_LANGINFO_CODESET],
12[ 10[
13 AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset, 11 AC_CACHE_CHECK([for nl_langinfo and CODESET], [am_cv_langinfo_codeset],
14 [AC_TRY_LINK([#include <langinfo.h>], 12 [AC_LINK_IFELSE(
15 [char* cs = nl_langinfo(CODESET);], 13 [AC_LANG_PROGRAM(
16 am_cv_langinfo_codeset=yes, 14 [[#include <langinfo.h>]],
17 am_cv_langinfo_codeset=no) 15 [[char* cs = nl_langinfo(CODESET); return !cs;]])],
16 [am_cv_langinfo_codeset=yes],
17 [am_cv_langinfo_codeset=no])
18 ]) 18 ])
19 if test $am_cv_langinfo_codeset = yes; then 19 if test $am_cv_langinfo_codeset = yes; then
20 AC_DEFINE(HAVE_LANGINFO_CODESET, 1, 20 AC_DEFINE([HAVE_LANGINFO_CODESET], [1],
21 [Define if you have <langinfo.h> and nl_langinfo(CODESET).]) 21 [Define if you have <langinfo.h> and nl_langinfo(CODESET).])
22 fi 22 fi
23]) 23])
diff --git a/m4/glibc2.m4 b/m4/glibc2.m4
index e8f5bfe6..71dd8a12 100644
--- a/m4/glibc2.m4
+++ b/m4/glibc2.m4
@@ -1,5 +1,6 @@
1# glibc2.m4 serial 1 1# glibc2.m4 serial 3
2dnl Copyright (C) 2000-2002, 2004 Free Software Foundation, Inc. 2dnl Copyright (C) 2000-2002, 2004, 2008, 2010-2014 Free Software Foundation,
3dnl Inc.
3dnl This file is free software; the Free Software Foundation 4dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it, 5dnl gives unlimited permission to copy and/or distribute it,
5dnl with or without modifications, as long as this notice is preserved. 6dnl with or without modifications, as long as this notice is preserved.
@@ -9,22 +10,22 @@ dnl with or without modifications, as long as this notice is preserved.
9 10
10AC_DEFUN([gt_GLIBC2], 11AC_DEFUN([gt_GLIBC2],
11 [ 12 [
12 AC_CACHE_CHECK(whether we are using the GNU C Library 2 or newer, 13 AC_CACHE_CHECK([whether we are using the GNU C Library 2 or newer],
13 ac_cv_gnu_library_2, 14 [ac_cv_gnu_library_2],
14 [AC_EGREP_CPP([Lucky GNU user], 15 [AC_EGREP_CPP([Lucky GNU user],
15 [ 16 [
16#include <features.h> 17#include <features.h>
17#ifdef __GNU_LIBRARY__ 18#ifdef __GNU_LIBRARY__
18 #if (__GLIBC__ >= 2) 19 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
19 Lucky GNU user 20 Lucky GNU user
20 #endif 21 #endif
21#endif 22#endif
22 ], 23 ],
23 ac_cv_gnu_library_2=yes, 24 [ac_cv_gnu_library_2=yes],
24 ac_cv_gnu_library_2=no) 25 [ac_cv_gnu_library_2=no])
25 ] 26 ]
26 ) 27 )
27 AC_SUBST(GLIBC2) 28 AC_SUBST([GLIBC2])
28 GLIBC2="$ac_cv_gnu_library_2" 29 GLIBC2="$ac_cv_gnu_library_2"
29 ] 30 ]
30) 31)
diff --git a/m4/glibc21.m4 b/m4/glibc21.m4
index 9c9f3db3..ab58b712 100644
--- a/m4/glibc21.m4
+++ b/m4/glibc21.m4
@@ -1,32 +1,34 @@
1# glibc21.m4 serial 2 (fileutils-4.1.3, gettext-0.10.40) 1# glibc21.m4 serial 5
2dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. 2dnl Copyright (C) 2000-2002, 2004, 2008, 2010-2014 Free Software Foundation,
3dnl This file is free software, distributed under the terms of the GNU 3dnl Inc.
4dnl General Public License. As a special exception to the GNU General 4dnl This file is free software; the Free Software Foundation
5dnl Public License, this file may be distributed as part of a program 5dnl gives unlimited permission to copy and/or distribute it,
6dnl that contains a configuration script generated by Autoconf, under 6dnl with or without modifications, as long as this notice is preserved.
7dnl the same distribution terms as the rest of that program.
8 7
9# Test for the GNU C Library, version 2.1 or newer. 8# Test for the GNU C Library, version 2.1 or newer, or uClibc.
10# From Bruno Haible. 9# From Bruno Haible.
11 10
12AC_DEFUN([jm_GLIBC21], 11AC_DEFUN([gl_GLIBC21],
13 [ 12 [
14 AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer, 13 AC_CACHE_CHECK([whether we are using the GNU C Library >= 2.1 or uClibc],
15 ac_cv_gnu_library_2_1, 14 [ac_cv_gnu_library_2_1],
16 [AC_EGREP_CPP([Lucky GNU user], 15 [AC_EGREP_CPP([Lucky],
17 [ 16 [
18#include <features.h> 17#include <features.h>
19#ifdef __GNU_LIBRARY__ 18#ifdef __GNU_LIBRARY__
20 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) 19 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
21 Lucky GNU user 20 Lucky GNU user
22 #endif 21 #endif
23#endif 22#endif
24 ], 23#ifdef __UCLIBC__
25 ac_cv_gnu_library_2_1=yes, 24 Lucky user
26 ac_cv_gnu_library_2_1=no) 25#endif
26 ],
27 [ac_cv_gnu_library_2_1=yes],
28 [ac_cv_gnu_library_2_1=no])
27 ] 29 ]
28 ) 30 )
29 AC_SUBST(GLIBC21) 31 AC_SUBST([GLIBC21])
30 GLIBC21="$ac_cv_gnu_library_2_1" 32 GLIBC21="$ac_cv_gnu_library_2_1"
31 ] 33 ]
32) 34)
diff --git a/m4/intdiv0.m4 b/m4/intdiv0.m4
index 55dddcf1..afa9acb8 100644
--- a/m4/intdiv0.m4
+++ b/m4/intdiv0.m4
@@ -1,10 +1,8 @@
1# intdiv0.m4 serial 1 (gettext-0.11.3) 1# intdiv0.m4 serial 6 (gettext-0.18.2)
2dnl Copyright (C) 2002 Free Software Foundation, Inc. 2dnl Copyright (C) 2002, 2007-2008, 2010-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10 8
@@ -16,16 +14,28 @@ AC_DEFUN([gt_INTDIV0],
16 AC_CACHE_CHECK([whether integer division by zero raises SIGFPE], 14 AC_CACHE_CHECK([whether integer division by zero raises SIGFPE],
17 gt_cv_int_divbyzero_sigfpe, 15 gt_cv_int_divbyzero_sigfpe,
18 [ 16 [
19 AC_TRY_RUN([ 17 gt_cv_int_divbyzero_sigfpe=
18changequote(,)dnl
19 case "$host_os" in
20 macos* | darwin[6-9]* | darwin[1-9][0-9]*)
21 # On Mac OS X 10.2 or newer, just assume the same as when cross-
22 # compiling. If we were to perform the real test, 1 Crash Report
23 # dialog window would pop up.
24 case "$host_cpu" in
25 i[34567]86 | x86_64)
26 gt_cv_int_divbyzero_sigfpe="guessing yes" ;;
27 esac
28 ;;
29 esac
30changequote([,])dnl
31 if test -z "$gt_cv_int_divbyzero_sigfpe"; then
32 AC_RUN_IFELSE(
33 [AC_LANG_SOURCE([[
20#include <stdlib.h> 34#include <stdlib.h>
21#include <signal.h> 35#include <signal.h>
22 36
23static void 37static void
24#ifdef __cplusplus
25sigfpe_handler (int sig) 38sigfpe_handler (int sig)
26#else
27sigfpe_handler (sig) int sig;
28#endif
29{ 39{
30 /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ 40 /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */
31 exit (sig != SIGFPE); 41 exit (sig != SIGFPE);
@@ -50,23 +60,28 @@ int main ()
50 60
51 z = x / y; 61 z = x / y;
52 nan = y / y; 62 nan = y / y;
53 exit (1); 63 exit (2);
54} 64}
55], gt_cv_int_divbyzero_sigfpe=yes, gt_cv_int_divbyzero_sigfpe=no, 65]])],
56 [ 66 [gt_cv_int_divbyzero_sigfpe=yes],
57 # Guess based on the CPU. 67 [gt_cv_int_divbyzero_sigfpe=no],
58 case "$host_cpu" in 68 [
59 alpha* | i[34567]86 | m68k | s390*) 69 # Guess based on the CPU.
60 gt_cv_int_divbyzero_sigfpe="guessing yes";; 70changequote(,)dnl
61 *) 71 case "$host_cpu" in
62 gt_cv_int_divbyzero_sigfpe="guessing no";; 72 alpha* | i[34567]86 | x86_64 | m68k | s390*)
63 esac 73 gt_cv_int_divbyzero_sigfpe="guessing yes";;
64 ]) 74 *)
75 gt_cv_int_divbyzero_sigfpe="guessing no";;
76 esac
77changequote([,])dnl
78 ])
79 fi
65 ]) 80 ])
66 case "$gt_cv_int_divbyzero_sigfpe" in 81 case "$gt_cv_int_divbyzero_sigfpe" in
67 *yes) value=1;; 82 *yes) value=1;;
68 *) value=0;; 83 *) value=0;;
69 esac 84 esac
70 AC_DEFINE_UNQUOTED(INTDIV0_RAISES_SIGFPE, $value, 85 AC_DEFINE_UNQUOTED([INTDIV0_RAISES_SIGFPE], [$value],
71 [Define if integer division by zero raises signal SIGFPE.]) 86 [Define if integer division by zero raises signal SIGFPE.])
72]) 87])
diff --git a/m4/intldir.m4 b/m4/intldir.m4
index 7a28843f..73b672a5 100644
--- a/m4/intldir.m4
+++ b/m4/intldir.m4
@@ -1,5 +1,5 @@
1# intldir.m4 serial 1 (gettext-0.16) 1# intldir.m4 serial 2 (gettext-0.18)
2dnl Copyright (C) 2006 Free Software Foundation, Inc. 2dnl Copyright (C) 2006, 2009-2014 Free Software Foundation, Inc.
3dnl This file is free software; the Free Software Foundation 3dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it, 4dnl gives unlimited permission to copy and/or distribute it,
5dnl with or without modifications, as long as this notice is preserved. 5dnl with or without modifications, as long as this notice is preserved.
@@ -13,7 +13,7 @@ dnl by the GNU Library General Public License, and the rest of the GNU
13dnl gettext package package is covered by the GNU General Public License. 13dnl gettext package package is covered by the GNU General Public License.
14dnl They are *not* in the public domain. 14dnl They are *not* in the public domain.
15 15
16AC_PREREQ(2.52) 16AC_PREREQ([2.52])
17 17
18dnl Tells the AM_GNU_GETTEXT macro to consider an intl/ directory. 18dnl Tells the AM_GNU_GETTEXT macro to consider an intl/ directory.
19AC_DEFUN([AM_GNU_GETTEXT_INTL_SUBDIR], []) 19AC_DEFUN([AM_GNU_GETTEXT_INTL_SUBDIR], [])
diff --git a/m4/intmax.m4 b/m4/intmax.m4
index dfb08ccc..f70ceeea 100644
--- a/m4/intmax.m4
+++ b/m4/intmax.m4
@@ -1,10 +1,8 @@
1# intmax.m4 serial 1 (gettext-0.12) 1# intmax.m4 serial 6 (gettext-0.18.2)
2dnl Copyright (C) 2002-2003 Free Software Foundation, Inc. 2dnl Copyright (C) 2002-2005, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10dnl Test whether the system has the 'intmax_t' type, but don't attempt to 8dnl Test whether the system has the 'intmax_t' type, but don't attempt to
@@ -12,11 +10,13 @@ dnl find a replacement if it is lacking.
12 10
13AC_DEFUN([gt_TYPE_INTMAX_T], 11AC_DEFUN([gt_TYPE_INTMAX_T],
14[ 12[
15 AC_REQUIRE([jm_AC_HEADER_INTTYPES_H]) 13 AC_REQUIRE([gl_AC_HEADER_INTTYPES_H])
16 AC_REQUIRE([jm_AC_HEADER_STDINT_H]) 14 AC_REQUIRE([gl_AC_HEADER_STDINT_H])
17 AC_CACHE_CHECK(for intmax_t, gt_cv_c_intmax_t, 15 AC_CACHE_CHECK([for intmax_t], [gt_cv_c_intmax_t],
18 [AC_TRY_COMPILE([ 16 [AC_COMPILE_IFELSE(
19#include <stddef.h> 17 [AC_LANG_PROGRAM(
18 [[
19#include <stddef.h>
20#include <stdlib.h> 20#include <stdlib.h>
21#if HAVE_STDINT_H_WITH_UINTMAX 21#if HAVE_STDINT_H_WITH_UINTMAX
22#include <stdint.h> 22#include <stdint.h>
@@ -24,9 +24,13 @@ AC_DEFUN([gt_TYPE_INTMAX_T],
24#if HAVE_INTTYPES_H_WITH_UINTMAX 24#if HAVE_INTTYPES_H_WITH_UINTMAX
25#include <inttypes.h> 25#include <inttypes.h>
26#endif 26#endif
27], [intmax_t x = -1;], gt_cv_c_intmax_t=yes, gt_cv_c_intmax_t=no)]) 27 ]],
28 [[intmax_t x = -1;
29 return !x;]])],
30 [gt_cv_c_intmax_t=yes],
31 [gt_cv_c_intmax_t=no])])
28 if test $gt_cv_c_intmax_t = yes; then 32 if test $gt_cv_c_intmax_t = yes; then
29 AC_DEFINE(HAVE_INTMAX_T, 1, 33 AC_DEFINE([HAVE_INTMAX_T], [1],
30 [Define if you have the 'intmax_t' type in <stdint.h> or <inttypes.h>.]) 34 [Define if you have the 'intmax_t' type in <stdint.h> or <inttypes.h>.])
31 fi 35 fi
32]) 36])
diff --git a/m4/inttypes-pri.m4 b/m4/inttypes-pri.m4
index fd007c31..00251e1d 100644
--- a/m4/inttypes-pri.m4
+++ b/m4/inttypes-pri.m4
@@ -1,32 +1,42 @@
1# inttypes-pri.m4 serial 1 (gettext-0.11.4) 1# inttypes-pri.m4 serial 7 (gettext-0.18.2)
2dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. 2dnl Copyright (C) 1997-2002, 2006, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10 8
9AC_PREREQ([2.53])
10
11# Define PRI_MACROS_BROKEN if <inttypes.h> exists and defines the PRI* 11# Define PRI_MACROS_BROKEN if <inttypes.h> exists and defines the PRI*
12# macros to non-string values. This is the case on AIX 4.3.3. 12# macros to non-string values. This is the case on AIX 4.3.3.
13 13
14AC_DEFUN([gt_INTTYPES_PRI], 14AC_DEFUN([gt_INTTYPES_PRI],
15[ 15[
16 AC_REQUIRE([gt_HEADER_INTTYPES_H]) 16 AC_CHECK_HEADERS([inttypes.h])
17 if test $gt_cv_header_inttypes_h = yes; then 17 if test $ac_cv_header_inttypes_h = yes; then
18 AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken], 18 AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken],
19 gt_cv_inttypes_pri_broken, 19 [gt_cv_inttypes_pri_broken],
20 [ 20 [
21 AC_TRY_COMPILE([#include <inttypes.h> 21 AC_COMPILE_IFELSE(
22 [AC_LANG_PROGRAM(
23 [[
24#include <inttypes.h>
22#ifdef PRId32 25#ifdef PRId32
23char *p = PRId32; 26char *p = PRId32;
24#endif 27#endif
25], [], gt_cv_inttypes_pri_broken=no, gt_cv_inttypes_pri_broken=yes) 28 ]],
29 [[]])],
30 [gt_cv_inttypes_pri_broken=no],
31 [gt_cv_inttypes_pri_broken=yes])
26 ]) 32 ])
27 fi 33 fi
28 if test "$gt_cv_inttypes_pri_broken" = yes; then 34 if test "$gt_cv_inttypes_pri_broken" = yes; then
29 AC_DEFINE_UNQUOTED(PRI_MACROS_BROKEN, 1, 35 AC_DEFINE_UNQUOTED([PRI_MACROS_BROKEN], [1],
30 [Define if <inttypes.h> exists and defines unusable PRI* macros.]) 36 [Define if <inttypes.h> exists and defines unusable PRI* macros.])
37 PRI_MACROS_BROKEN=1
38 else
39 PRI_MACROS_BROKEN=0
31 fi 40 fi
41 AC_SUBST([PRI_MACROS_BROKEN])
32]) 42])
diff --git a/m4/inttypes_h.m4 b/m4/inttypes_h.m4
index f342eba3..87be9cfb 100644
--- a/m4/inttypes_h.m4
+++ b/m4/inttypes_h.m4
@@ -1,27 +1,28 @@
1# inttypes_h.m4 serial 5 (gettext-0.12) 1# inttypes_h.m4 serial 10
2dnl Copyright (C) 1997-2003 Free Software Foundation, Inc. 2dnl Copyright (C) 1997-2004, 2006, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Paul Eggert. 7dnl From Paul Eggert.
10 8
11# Define HAVE_INTTYPES_H_WITH_UINTMAX if <inttypes.h> exists, 9# Define HAVE_INTTYPES_H_WITH_UINTMAX if <inttypes.h> exists,
12# doesn't clash with <sys/types.h>, and declares uintmax_t. 10# doesn't clash with <sys/types.h>, and declares uintmax_t.
13 11
14AC_DEFUN([jm_AC_HEADER_INTTYPES_H], 12AC_DEFUN([gl_AC_HEADER_INTTYPES_H],
15[ 13[
16 AC_CACHE_CHECK([for inttypes.h], jm_ac_cv_header_inttypes_h, 14 AC_CACHE_CHECK([for inttypes.h], [gl_cv_header_inttypes_h],
17 [AC_TRY_COMPILE( 15 [AC_COMPILE_IFELSE(
18 [#include <sys/types.h> 16 [AC_LANG_PROGRAM(
19#include <inttypes.h>], 17 [[
20 [uintmax_t i = (uintmax_t) -1;], 18#include <sys/types.h>
21 jm_ac_cv_header_inttypes_h=yes, 19#include <inttypes.h>
22 jm_ac_cv_header_inttypes_h=no)]) 20 ]],
23 if test $jm_ac_cv_header_inttypes_h = yes; then 21 [[uintmax_t i = (uintmax_t) -1; return !i;]])],
24 AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1, 22 [gl_cv_header_inttypes_h=yes],
23 [gl_cv_header_inttypes_h=no])])
24 if test $gl_cv_header_inttypes_h = yes; then
25 AC_DEFINE_UNQUOTED([HAVE_INTTYPES_H_WITH_UINTMAX], [1],
25 [Define if <inttypes.h> exists, doesn't clash with <sys/types.h>, 26 [Define if <inttypes.h> exists, doesn't clash with <sys/types.h>,
26 and declares uintmax_t. ]) 27 and declares uintmax_t. ])
27 fi 28 fi
diff --git a/m4/lcmessage.m4 b/m4/lcmessage.m4
index ffd4008b..7470ec59 100644
--- a/m4/lcmessage.m4
+++ b/m4/lcmessage.m4
@@ -1,10 +1,9 @@
1# lcmessage.m4 serial 3 (gettext-0.11.3) 1# lcmessage.m4 serial 7 (gettext-0.18.2)
2dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. 2dnl Copyright (C) 1995-2002, 2004-2005, 2008-2014 Free Software Foundation,
3dnl This file is free software, distributed under the terms of the GNU 3dnl Inc.
4dnl General Public License. As a special exception to the GNU General 4dnl This file is free software; the Free Software Foundation
5dnl Public License, this file may be distributed as part of a program 5dnl gives unlimited permission to copy and/or distribute it,
6dnl that contains a configuration script generated by Autoconf, under 6dnl with or without modifications, as long as this notice is preserved.
7dnl the same distribution terms as the rest of that program.
8dnl 7dnl
9dnl This file can can be used in projects which are not available under 8dnl This file can can be used in projects which are not available under
10dnl the GNU General Public License or the GNU Library General Public 9dnl the GNU General Public License or the GNU Library General Public
@@ -20,13 +19,17 @@ dnl Ulrich Drepper <drepper@cygnus.com>, 1995.
20 19
21# Check whether LC_MESSAGES is available in <locale.h>. 20# Check whether LC_MESSAGES is available in <locale.h>.
22 21
23AC_DEFUN([AM_LC_MESSAGES], 22AC_DEFUN([gt_LC_MESSAGES],
24[ 23[
25 AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, 24 AC_CACHE_CHECK([for LC_MESSAGES], [gt_cv_val_LC_MESSAGES],
26 [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES], 25 [AC_LINK_IFELSE(
27 am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) 26 [AC_LANG_PROGRAM(
28 if test $am_cv_val_LC_MESSAGES = yes; then 27 [[#include <locale.h>]],
29 AC_DEFINE(HAVE_LC_MESSAGES, 1, 28 [[return LC_MESSAGES]])],
29 [gt_cv_val_LC_MESSAGES=yes],
30 [gt_cv_val_LC_MESSAGES=no])])
31 if test $gt_cv_val_LC_MESSAGES = yes; then
32 AC_DEFINE([HAVE_LC_MESSAGES], [1],
30 [Define if your <locale.h> file defines LC_MESSAGES.]) 33 [Define if your <locale.h> file defines LC_MESSAGES.])
31 fi 34 fi
32]) 35])
diff --git a/m4/lock.m4 b/m4/lock.m4
index 0224f2ff..73a3c54c 100644
--- a/m4/lock.m4
+++ b/m4/lock.m4
@@ -1,311 +1,42 @@
1# lock.m4 serial 6 (gettext-0.16) 1# lock.m4 serial 13 (gettext-0.18.2)
2dnl Copyright (C) 2005-2006 Free Software Foundation, Inc. 2dnl Copyright (C) 2005-2014 Free Software Foundation, Inc.
3dnl This file is free software; the Free Software Foundation 3dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it, 4dnl gives unlimited permission to copy and/or distribute it,
5dnl with or without modifications, as long as this notice is preserved. 5dnl with or without modifications, as long as this notice is preserved.
6 6
7dnl From Bruno Haible. 7dnl From Bruno Haible.
8 8
9dnl Tests for a multithreading library to be used. 9AC_DEFUN([gl_LOCK],
10dnl Defines at most one of the macros USE_POSIX_THREADS, USE_SOLARIS_THREADS,
11dnl USE_PTH_THREADS, USE_WIN32_THREADS
12dnl Sets the variables LIBTHREAD and LTLIBTHREAD to the linker options for use
13dnl in a Makefile (LIBTHREAD for use without libtool, LTLIBTHREAD for use with
14dnl libtool).
15dnl Sets the variables LIBMULTITHREAD and LTLIBMULTITHREAD similarly, for
16dnl programs that really need multithread functionality. The difference
17dnl between LIBTHREAD and LIBMULTITHREAD is that on platforms supporting weak
18dnl symbols, typically LIBTHREAD="" whereas LIBMULTITHREAD="-lpthread".
19dnl Adds to CPPFLAGS the flag -D_REENTRANT or -D_THREAD_SAFE if needed for
20dnl multithread-safe programs.
21
22AC_DEFUN([gl_LOCK_EARLY],
23[
24 AC_REQUIRE([gl_LOCK_EARLY_BODY])
25])
26
27dnl The guts of gl_LOCK_EARLY. Needs to be expanded only once.
28
29AC_DEFUN([gl_LOCK_EARLY_BODY],
30[
31 dnl Ordering constraints: This macro modifies CPPFLAGS in a way that
32 dnl influences the result of the autoconf tests that test for *_unlocked
33 dnl declarations, on AIX 5 at least. Therefore it must come early.
34 AC_BEFORE([$0], [gl_FUNC_GLIBC_UNLOCKED_IO])dnl
35 AC_BEFORE([$0], [gl_ARGP])dnl
36
37 AC_REQUIRE([AC_CANONICAL_HOST])
38 AC_REQUIRE([AC_GNU_SOURCE]) dnl needed for pthread_rwlock_t on glibc systems
39 dnl Check for multithreading.
40 AC_ARG_ENABLE(threads,
41AC_HELP_STRING([--enable-threads={posix|solaris|pth|win32}], [specify multithreading API])
42AC_HELP_STRING([--disable-threads], [build without multithread safety]),
43 [gl_use_threads=$enableval],
44 [case "$host_os" in
45 dnl Disable multithreading by default on OSF/1, because it interferes
46 dnl with fork()/exec(): When msgexec is linked with -lpthread, its child
47 dnl process gets an endless segmentation fault inside execvp().
48 osf*) gl_use_threads=no ;;
49 *) gl_use_threads=yes ;;
50 esac
51 ])
52 if test "$gl_use_threads" = yes || test "$gl_use_threads" = posix; then
53 # For using <pthread.h>:
54 case "$host_os" in
55 osf*)
56 # On OSF/1, the compiler needs the flag -D_REENTRANT so that it
57 # groks <pthread.h>. cc also understands the flag -pthread, but
58 # we don't use it because 1. gcc-2.95 doesn't understand -pthread,
59 # 2. putting a flag into CPPFLAGS that has an effect on the linker
60 # causes the AC_TRY_LINK test below to succeed unexpectedly,
61 # leading to wrong values of LIBTHREAD and LTLIBTHREAD.
62 CPPFLAGS="$CPPFLAGS -D_REENTRANT"
63 ;;
64 esac
65 # Some systems optimize for single-threaded programs by default, and
66 # need special flags to disable these optimizations. For example, the
67 # definition of 'errno' in <errno.h>.
68 case "$host_os" in
69 aix* | freebsd*) CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE" ;;
70 solaris*) CPPFLAGS="$CPPFLAGS -D_REENTRANT" ;;
71 esac
72 fi
73])
74
75dnl The guts of gl_LOCK. Needs to be expanded only once.
76
77AC_DEFUN([gl_LOCK_BODY],
78[ 10[
79 AC_REQUIRE([gl_LOCK_EARLY_BODY]) 11 AC_REQUIRE([gl_THREADLIB])
80 gl_threads_api=none 12 if test "$gl_threads_api" = posix; then
81 LIBTHREAD= 13 # OSF/1 4.0 and Mac OS X 10.1 lack the pthread_rwlock_t type and the
82 LTLIBTHREAD= 14 # pthread_rwlock_* functions.
83 LIBMULTITHREAD= 15 AC_CHECK_TYPE([pthread_rwlock_t],
84 LTLIBMULTITHREAD= 16 [AC_DEFINE([HAVE_PTHREAD_RWLOCK], [1],
85 if test "$gl_use_threads" != no; then 17 [Define if the POSIX multithreading library has read/write locks.])],
86 dnl Check whether the compiler and linker support weak declarations. 18 [],
87 AC_MSG_CHECKING([whether imported symbols can be declared weak]) 19 [#include <pthread.h>])
88 gl_have_weak=no 20 # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro.
89 AC_TRY_LINK([extern void xyzzy (); 21 AC_COMPILE_IFELSE([
90#pragma weak xyzzy], [xyzzy();], [gl_have_weak=yes]) 22 AC_LANG_PROGRAM(
91 AC_MSG_RESULT([$gl_have_weak]) 23 [[#include <pthread.h>]],
92 if test "$gl_use_threads" = yes || test "$gl_use_threads" = posix; then 24 [[
93 # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that 25#if __FreeBSD__ == 4
94 # it groks <pthread.h>. It's added above, in gl_LOCK_EARLY_BODY.
95 AC_CHECK_HEADER(pthread.h, gl_have_pthread_h=yes, gl_have_pthread_h=no)
96 if test "$gl_have_pthread_h" = yes; then
97 # Other possible tests:
98 # -lpthreads (FSU threads, PCthreads)
99 # -lgthreads
100 gl_have_pthread=
101 # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
102 # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
103 # the second one only in libpthread, and lock.c needs it.
104 AC_TRY_LINK([#include <pthread.h>],
105 [pthread_mutex_lock((pthread_mutex_t*)0);
106 pthread_mutexattr_init((pthread_mutexattr_t*)0);],
107 [gl_have_pthread=yes])
108 # Test for libpthread by looking for pthread_kill. (Not pthread_self,
109 # since it is defined as a macro on OSF/1.)
110 if test -n "$gl_have_pthread"; then
111 # The program links fine without libpthread. But it may actually
112 # need to link with libpthread in order to create multiple threads.
113 AC_CHECK_LIB(pthread, pthread_kill,
114 [LIBMULTITHREAD=-lpthread LTLIBMULTITHREAD=-lpthread
115 # On Solaris and HP-UX, most pthread functions exist also in libc.
116 # Therefore pthread_in_use() needs to actually try to create a
117 # thread: pthread_create from libc will fail, whereas
118 # pthread_create will actually create a thread.
119 case "$host_os" in
120 solaris* | hpux*)
121 AC_DEFINE([PTHREAD_IN_USE_DETECTION_HARD], 1,
122 [Define if the pthread_in_use() detection is hard.])
123 esac
124 ])
125 else
126 # Some library is needed. Try libpthread and libc_r.
127 AC_CHECK_LIB(pthread, pthread_kill,
128 [gl_have_pthread=yes
129 LIBTHREAD=-lpthread LTLIBTHREAD=-lpthread
130 LIBMULTITHREAD=-lpthread LTLIBMULTITHREAD=-lpthread])
131 if test -z "$gl_have_pthread"; then
132 # For FreeBSD 4.
133 AC_CHECK_LIB(c_r, pthread_kill,
134 [gl_have_pthread=yes
135 LIBTHREAD=-lc_r LTLIBTHREAD=-lc_r
136 LIBMULTITHREAD=-lc_r LTLIBMULTITHREAD=-lc_r])
137 fi
138 fi
139 if test -n "$gl_have_pthread"; then
140 gl_threads_api=posix
141 AC_DEFINE([USE_POSIX_THREADS], 1,
142 [Define if the POSIX multithreading library can be used.])
143 if test -n "$LIBMULTITHREAD" || test -n "$LTLIBMULTITHREAD"; then
144 if test $gl_have_weak = yes; then
145 AC_DEFINE([USE_POSIX_THREADS_WEAK], 1,
146 [Define if references to the POSIX multithreading library should be made weak.])
147 LIBTHREAD=
148 LTLIBTHREAD=
149 fi
150 fi
151 # OSF/1 4.0 and MacOS X 10.1 lack the pthread_rwlock_t type and the
152 # pthread_rwlock_* functions.
153 AC_CHECK_TYPE([pthread_rwlock_t],
154 [AC_DEFINE([HAVE_PTHREAD_RWLOCK], 1,
155 [Define if the POSIX multithreading library has read/write locks.])],
156 [],
157 [#include <pthread.h>])
158 # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro.
159 AC_TRY_COMPILE([#include <pthread.h>],
160 [#if __FreeBSD__ == 4
161error "No, in FreeBSD 4.0 recursive mutexes actually don't work." 26error "No, in FreeBSD 4.0 recursive mutexes actually don't work."
27#elif (defined __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ \
28 && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070)
29error "No, in Mac OS X < 10.7 recursive mutexes actually don't work."
162#else 30#else
163int x = (int)PTHREAD_MUTEX_RECURSIVE; 31int x = (int)PTHREAD_MUTEX_RECURSIVE;
164return !x; 32return !x;
165#endif], 33#endif
166 [AC_DEFINE([HAVE_PTHREAD_MUTEX_RECURSIVE], 1, 34 ]])],
167 [Define if the <pthread.h> defines PTHREAD_MUTEX_RECURSIVE.])]) 35 [AC_DEFINE([HAVE_PTHREAD_MUTEX_RECURSIVE], [1],
168 fi 36 [Define if the <pthread.h> defines PTHREAD_MUTEX_RECURSIVE.])])
169 fi
170 fi
171 if test -z "$gl_have_pthread"; then
172 if test "$gl_use_threads" = yes || test "$gl_use_threads" = solaris; then
173 gl_have_solaristhread=
174 gl_save_LIBS="$LIBS"
175 LIBS="$LIBS -lthread"
176 AC_TRY_LINK([#include <thread.h>
177#include <synch.h>],
178 [thr_self();],
179 [gl_have_solaristhread=yes])
180 LIBS="$gl_save_LIBS"
181 if test -n "$gl_have_solaristhread"; then
182 gl_threads_api=solaris
183 LIBTHREAD=-lthread
184 LTLIBTHREAD=-lthread
185 LIBMULTITHREAD="$LIBTHREAD"
186 LTLIBMULTITHREAD="$LTLIBTHREAD"
187 AC_DEFINE([USE_SOLARIS_THREADS], 1,
188 [Define if the old Solaris multithreading library can be used.])
189 if test $gl_have_weak = yes; then
190 AC_DEFINE([USE_SOLARIS_THREADS_WEAK], 1,
191 [Define if references to the old Solaris multithreading library should be made weak.])
192 LIBTHREAD=
193 LTLIBTHREAD=
194 fi
195 fi
196 fi
197 fi
198 if test "$gl_use_threads" = pth; then
199 gl_save_CPPFLAGS="$CPPFLAGS"
200 AC_LIB_LINKFLAGS(pth)
201 gl_have_pth=
202 gl_save_LIBS="$LIBS"
203 LIBS="$LIBS -lpth"
204 AC_TRY_LINK([#include <pth.h>], [pth_self();], gl_have_pth=yes)
205 LIBS="$gl_save_LIBS"
206 if test -n "$gl_have_pth"; then
207 gl_threads_api=pth
208 LIBTHREAD="$LIBPTH"
209 LTLIBTHREAD="$LTLIBPTH"
210 LIBMULTITHREAD="$LIBTHREAD"
211 LTLIBMULTITHREAD="$LTLIBTHREAD"
212 AC_DEFINE([USE_PTH_THREADS], 1,
213 [Define if the GNU Pth multithreading library can be used.])
214 if test -n "$LIBMULTITHREAD" || test -n "$LTLIBMULTITHREAD"; then
215 if test $gl_have_weak = yes; then
216 AC_DEFINE([USE_PTH_THREADS_WEAK], 1,
217 [Define if references to the GNU Pth multithreading library should be made weak.])
218 LIBTHREAD=
219 LTLIBTHREAD=
220 fi
221 fi
222 else
223 CPPFLAGS="$gl_save_CPPFLAGS"
224 fi
225 fi
226 if test -z "$gl_have_pthread"; then
227 if test "$gl_use_threads" = yes || test "$gl_use_threads" = win32; then
228 if { case "$host_os" in
229 mingw*) true;;
230 *) false;;
231 esac
232 }; then
233 gl_threads_api=win32
234 AC_DEFINE([USE_WIN32_THREADS], 1,
235 [Define if the Win32 multithreading API can be used.])
236 fi
237 fi
238 fi
239 fi 37 fi
240 AC_MSG_CHECKING([for multithread API to use])
241 AC_MSG_RESULT([$gl_threads_api])
242 AC_SUBST(LIBTHREAD)
243 AC_SUBST(LTLIBTHREAD)
244 AC_SUBST(LIBMULTITHREAD)
245 AC_SUBST(LTLIBMULTITHREAD)
246])
247
248AC_DEFUN([gl_LOCK],
249[
250 AC_REQUIRE([gl_LOCK_EARLY])
251 AC_REQUIRE([gl_LOCK_BODY])
252 gl_PREREQ_LOCK 38 gl_PREREQ_LOCK
253]) 39])
254 40
255# Prerequisites of lib/lock.c. 41# Prerequisites of lib/glthread/lock.c.
256AC_DEFUN([gl_PREREQ_LOCK], [ 42AC_DEFUN([gl_PREREQ_LOCK], [:])
257 AC_REQUIRE([AC_C_INLINE])
258])
259
260dnl Survey of platforms:
261dnl
262dnl Platform Available Compiler Supports test-lock
263dnl flavours option weak result
264dnl --------------- --------- --------- -------- ---------
265dnl Linux 2.4/glibc posix -lpthread Y OK
266dnl
267dnl GNU Hurd/glibc posix
268dnl
269dnl FreeBSD 5.3 posix -lc_r Y
270dnl posix -lkse ? Y
271dnl posix -lpthread ? Y
272dnl posix -lthr Y
273dnl
274dnl FreeBSD 5.2 posix -lc_r Y
275dnl posix -lkse Y
276dnl posix -lthr Y
277dnl
278dnl FreeBSD 4.0,4.10 posix -lc_r Y OK
279dnl
280dnl NetBSD 1.6 --
281dnl
282dnl OpenBSD 3.4 posix -lpthread Y OK
283dnl
284dnl MacOS X 10.[123] posix -lpthread Y OK
285dnl
286dnl Solaris 7,8,9 posix -lpthread Y Sol 7,8: 0.0; Sol 9: OK
287dnl solaris -lthread Y Sol 7,8: 0.0; Sol 9: OK
288dnl
289dnl HP-UX 11 posix -lpthread N (cc) OK
290dnl Y (gcc)
291dnl
292dnl IRIX 6.5 posix -lpthread Y 0.5
293dnl
294dnl AIX 4.3,5.1 posix -lpthread N AIX 4: 0.5; AIX 5: OK
295dnl
296dnl OSF/1 4.0,5.1 posix -pthread (cc) N OK
297dnl -lpthread (gcc) Y
298dnl
299dnl Cygwin posix -lpthread Y OK
300dnl
301dnl Any of the above pth -lpth 0.0
302dnl
303dnl Mingw win32 N OK
304dnl
305dnl BeOS 5 --
306dnl
307dnl The test-lock result shows what happens if in test-lock.c EXPLICIT_YIELD is
308dnl turned off:
309dnl OK if all three tests terminate OK,
310dnl 0.5 if the first test terminates OK but the second one loops endlessly,
311dnl 0.0 if the first test already loops endlessly.
diff --git a/m4/longlong.m4 b/m4/longlong.m4
index d7d7350b..eefb37c4 100644
--- a/m4/longlong.m4
+++ b/m4/longlong.m4
@@ -1,25 +1,113 @@
1# longlong.m4 serial 4 1# longlong.m4 serial 17
2dnl Copyright (C) 1999-2003 Free Software Foundation, Inc. 2dnl Copyright (C) 1999-2007, 2009-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Paul Eggert. 7dnl From Paul Eggert.
10 8
11# Define HAVE_LONG_LONG if 'long long' works. 9# Define HAVE_LONG_LONG_INT if 'long long int' works.
10# This fixes a bug in Autoconf 2.61, and can be faster
11# than what's in Autoconf 2.62 through 2.68.
12 12
13AC_DEFUN([jm_AC_TYPE_LONG_LONG], 13# Note: If the type 'long long int' exists but is only 32 bits large
14# (as on some very old compilers), HAVE_LONG_LONG_INT will not be
15# defined. In this case you can treat 'long long int' like 'long int'.
16
17AC_DEFUN([AC_TYPE_LONG_LONG_INT],
18[
19 AC_REQUIRE([AC_TYPE_UNSIGNED_LONG_LONG_INT])
20 AC_CACHE_CHECK([for long long int], [ac_cv_type_long_long_int],
21 [ac_cv_type_long_long_int=yes
22 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
23 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
24 if test $ac_cv_type_long_long_int = yes; then
25 dnl Catch a bug in Tandem NonStop Kernel (OSS) cc -O circa 2004.
26 dnl If cross compiling, assume the bug is not important, since
27 dnl nobody cross compiles for this platform as far as we know.
28 AC_RUN_IFELSE(
29 [AC_LANG_PROGRAM(
30 [[@%:@include <limits.h>
31 @%:@ifndef LLONG_MAX
32 @%:@ define HALF \
33 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
34 @%:@ define LLONG_MAX (HALF - 1 + HALF)
35 @%:@endif]],
36 [[long long int n = 1;
37 int i;
38 for (i = 0; ; i++)
39 {
40 long long int m = n << i;
41 if (m >> i != n)
42 return 1;
43 if (LLONG_MAX / 2 < m)
44 break;
45 }
46 return 0;]])],
47 [],
48 [ac_cv_type_long_long_int=no],
49 [:])
50 fi
51 fi])
52 if test $ac_cv_type_long_long_int = yes; then
53 AC_DEFINE([HAVE_LONG_LONG_INT], [1],
54 [Define to 1 if the system has the type 'long long int'.])
55 fi
56])
57
58# Define HAVE_UNSIGNED_LONG_LONG_INT if 'unsigned long long int' works.
59# This fixes a bug in Autoconf 2.61, and can be faster
60# than what's in Autoconf 2.62 through 2.68.
61
62# Note: If the type 'unsigned long long int' exists but is only 32 bits
63# large (as on some very old compilers), AC_TYPE_UNSIGNED_LONG_LONG_INT
64# will not be defined. In this case you can treat 'unsigned long long int'
65# like 'unsigned long int'.
66
67AC_DEFUN([AC_TYPE_UNSIGNED_LONG_LONG_INT],
14[ 68[
15 AC_CACHE_CHECK([for long long], ac_cv_type_long_long, 69 AC_CACHE_CHECK([for unsigned long long int],
16 [AC_TRY_LINK([long long ll = 1LL; int i = 63;], 70 [ac_cv_type_unsigned_long_long_int],
17 [long long llmax = (long long) -1; 71 [ac_cv_type_unsigned_long_long_int=yes
18 return ll << i | ll >> i | llmax / ll | llmax % ll;], 72 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19 ac_cv_type_long_long=yes, 73 AC_LINK_IFELSE(
20 ac_cv_type_long_long=no)]) 74 [_AC_TYPE_LONG_LONG_SNIPPET],
21 if test $ac_cv_type_long_long = yes; then 75 [],
22 AC_DEFINE(HAVE_LONG_LONG, 1, 76 [ac_cv_type_unsigned_long_long_int=no])
23 [Define if you have the 'long long' type.]) 77 fi])
78 if test $ac_cv_type_unsigned_long_long_int = yes; then
79 AC_DEFINE([HAVE_UNSIGNED_LONG_LONG_INT], [1],
80 [Define to 1 if the system has the type 'unsigned long long int'.])
24 fi 81 fi
25]) 82])
83
84# Expands to a C program that can be used to test for simultaneous support
85# of 'long long' and 'unsigned long long'. We don't want to say that
86# 'long long' is available if 'unsigned long long' is not, or vice versa,
87# because too many programs rely on the symmetry between signed and unsigned
88# integer types (excluding 'bool').
89AC_DEFUN([_AC_TYPE_LONG_LONG_SNIPPET],
90[
91 AC_LANG_PROGRAM(
92 [[/* For now, do not test the preprocessor; as of 2007 there are too many
93 implementations with broken preprocessors. Perhaps this can
94 be revisited in 2012. In the meantime, code should not expect
95 #if to work with literals wider than 32 bits. */
96 /* Test literals. */
97 long long int ll = 9223372036854775807ll;
98 long long int nll = -9223372036854775807LL;
99 unsigned long long int ull = 18446744073709551615ULL;
100 /* Test constant expressions. */
101 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
102 ? 1 : -1)];
103 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
104 ? 1 : -1)];
105 int i = 63;]],
106 [[/* Test availability of runtime routines for shift and division. */
107 long long int llmax = 9223372036854775807ll;
108 unsigned long long int ullmax = 18446744073709551615ull;
109 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
110 | (llmax / ll) | (llmax % ll)
111 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
112 | (ullmax / ull) | (ullmax % ull));]])
113])
diff --git a/m4/printf-posix.m4 b/m4/printf-posix.m4
index 186ba6a6..3be95c13 100644
--- a/m4/printf-posix.m4
+++ b/m4/printf-posix.m4
@@ -1,10 +1,8 @@
1# printf-posix.m4 serial 2 (gettext-0.13.1) 1# printf-posix.m4 serial 6 (gettext-0.18.2)
2dnl Copyright (C) 2003 Free Software Foundation, Inc. 2dnl Copyright (C) 2003, 2007, 2009-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10dnl Test whether the printf() function supports POSIX/XSI format strings with 8dnl Test whether the printf() function supports POSIX/XSI format strings with
@@ -16,7 +14,8 @@ AC_DEFUN([gt_PRINTF_POSIX],
16 AC_CACHE_CHECK([whether printf() supports POSIX/XSI format strings], 14 AC_CACHE_CHECK([whether printf() supports POSIX/XSI format strings],
17 gt_cv_func_printf_posix, 15 gt_cv_func_printf_posix,
18 [ 16 [
19 AC_TRY_RUN([ 17 AC_RUN_IFELSE(
18 [AC_LANG_SOURCE([[
20#include <stdio.h> 19#include <stdio.h>
21#include <string.h> 20#include <string.h>
22/* The string "%2$d %1$d", with dollar characters protected from the shell's 21/* The string "%2$d %1$d", with dollar characters protected from the shell's
@@ -27,19 +26,22 @@ int main ()
27{ 26{
28 sprintf (buf, format, 33, 55); 27 sprintf (buf, format, 33, 55);
29 return (strcmp (buf, "55 33") != 0); 28 return (strcmp (buf, "55 33") != 0);
30}], gt_cv_func_printf_posix=yes, gt_cv_func_printf_posix=no, 29}]])],
31 [ 30 [gt_cv_func_printf_posix=yes],
32 AC_EGREP_CPP(notposix, [ 31 [gt_cv_func_printf_posix=no],
33#if defined __NetBSD__ || defined _MSC_VER || defined __MINGW32__ || defined __CYGWIN__ 32 [
33 AC_EGREP_CPP([notposix], [
34#if defined __NetBSD__ || defined __BEOS__ || defined _MSC_VER || defined __MINGW32__ || defined __CYGWIN__
34 notposix 35 notposix
35#endif 36#endif
36 ], gt_cv_func_printf_posix="guessing no", 37 ],
37 gt_cv_func_printf_posix="guessing yes") 38 [gt_cv_func_printf_posix="guessing no"],
38 ]) 39 [gt_cv_func_printf_posix="guessing yes"])
40 ])
39 ]) 41 ])
40 case $gt_cv_func_printf_posix in 42 case $gt_cv_func_printf_posix in
41 *yes) 43 *yes)
42 AC_DEFINE(HAVE_POSIX_PRINTF, 1, 44 AC_DEFINE([HAVE_POSIX_PRINTF], [1],
43 [Define if your printf() function supports format strings with positions.]) 45 [Define if your printf() function supports format strings with positions.])
44 ;; 46 ;;
45 esac 47 esac
diff --git a/m4/size_max.m4 b/m4/size_max.m4
index 5762fc33..7e192d5e 100644
--- a/m4/size_max.m4
+++ b/m4/size_max.m4
@@ -1,20 +1,18 @@
1# size_max.m4 serial 2 1# size_max.m4 serial 10
2dnl Copyright (C) 2003 Free Software Foundation, Inc. 2dnl Copyright (C) 2003, 2005-2006, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10 8
11AC_DEFUN([gl_SIZE_MAX], 9AC_DEFUN([gl_SIZE_MAX],
12[ 10[
13 AC_CHECK_HEADERS(stdint.h) 11 AC_CHECK_HEADERS([stdint.h])
14 dnl First test whether the system already has SIZE_MAX. 12 dnl First test whether the system already has SIZE_MAX.
15 AC_MSG_CHECKING([for SIZE_MAX]) 13 AC_CACHE_CHECK([for SIZE_MAX], [gl_cv_size_max], [
16 result= 14 gl_cv_size_max=
17 AC_EGREP_CPP([Found it], [ 15 AC_EGREP_CPP([Found it], [
18#include <limits.h> 16#include <limits.h>
19#if HAVE_STDINT_H 17#if HAVE_STDINT_H
20#include <stdint.h> 18#include <stdint.h>
@@ -22,40 +20,60 @@ AC_DEFUN([gl_SIZE_MAX],
22#ifdef SIZE_MAX 20#ifdef SIZE_MAX
23Found it 21Found it
24#endif 22#endif
25], result=yes) 23], [gl_cv_size_max=yes])
26 if test -z "$result"; then 24 if test -z "$gl_cv_size_max"; then
27 dnl Define it ourselves. Here we assume that the type 'size_t' is not wider 25 dnl Define it ourselves. Here we assume that the type 'size_t' is not wider
28 dnl than the type 'unsigned long'. 26 dnl than the type 'unsigned long'. Try hard to find a definition that can
29 dnl The _AC_COMPUTE_INT macro works up to LONG_MAX, since it uses 'expr', 27 dnl be used in a preprocessor #if, i.e. doesn't contain a cast.
30 dnl which is guaranteed to work from LONG_MIN to LONG_MAX. 28 AC_COMPUTE_INT([size_t_bits_minus_1], [sizeof (size_t) * CHAR_BIT - 1],
31 _AC_COMPUTE_INT([~(size_t)0 / 10], res_hi, 29 [#include <stddef.h>
32 [#include <stddef.h>], result=?) 30#include <limits.h>], [size_t_bits_minus_1=])
33 _AC_COMPUTE_INT([~(size_t)0 % 10], res_lo, 31 AC_COMPUTE_INT([fits_in_uint], [sizeof (size_t) <= sizeof (unsigned int)],
34 [#include <stddef.h>], result=?) 32 [#include <stddef.h>], [fits_in_uint=])
35 _AC_COMPUTE_INT([sizeof (size_t) <= sizeof (unsigned int)], fits_in_uint, 33 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
36 [#include <stddef.h>], result=?) 34 if test $fits_in_uint = 1; then
37 if test "$fits_in_uint" = 1; then 35 dnl Even though SIZE_MAX fits in an unsigned int, it must be of type
38 dnl Even though SIZE_MAX fits in an unsigned int, it must be of type 36 dnl 'unsigned long' if the type 'size_t' is the same as 'unsigned long'.
39 dnl 'unsigned long' if the type 'size_t' is the same as 'unsigned long'. 37 AC_COMPILE_IFELSE(
40 AC_TRY_COMPILE([#include <stddef.h> 38 [AC_LANG_PROGRAM(
41 extern size_t foo; 39 [[#include <stddef.h>
42 extern unsigned long foo; 40 extern size_t foo;
43 ], [], fits_in_uint=0) 41 extern unsigned long foo;
44 fi 42 ]],
45 if test -z "$result"; then 43 [[]])],
46 if test "$fits_in_uint" = 1; then 44 [fits_in_uint=0])
47 result="$res_hi$res_lo"U 45 fi
46 dnl We cannot use 'expr' to simplify this expression, because 'expr'
47 dnl works only with 'long' integers in the host environment, while we
48 dnl might be cross-compiling from a 32-bit platform to a 64-bit platform.
49 if test $fits_in_uint = 1; then
50 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
51 else
52 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
53 fi
48 else 54 else
49 result="$res_hi$res_lo"UL 55 dnl Shouldn't happen, but who knows...
56 gl_cv_size_max='((size_t)~(size_t)0)'
50 fi 57 fi
51 else
52 dnl Shouldn't happen, but who knows...
53 result='~(size_t)0'
54 fi 58 fi
55 fi 59 ])
56 AC_MSG_RESULT([$result]) 60 if test "$gl_cv_size_max" != yes; then
57 if test "$result" != yes; then 61 AC_DEFINE_UNQUOTED([SIZE_MAX], [$gl_cv_size_max],
58 AC_DEFINE_UNQUOTED([SIZE_MAX], [$result],
59 [Define as the maximum value of type 'size_t', if the system doesn't define it.]) 62 [Define as the maximum value of type 'size_t', if the system doesn't define it.])
60 fi 63 fi
64 dnl Don't redefine SIZE_MAX in config.h if config.h is re-included after
65 dnl <stdint.h>. Remember that the #undef in AH_VERBATIM gets replaced with
66 dnl #define by AC_DEFINE_UNQUOTED.
67 AH_VERBATIM([SIZE_MAX],
68[/* Define as the maximum value of type 'size_t', if the system doesn't define
69 it. */
70#ifndef SIZE_MAX
71# undef SIZE_MAX
72#endif])
73])
74
75dnl Autoconf >= 2.61 has AC_COMPUTE_INT built-in.
76dnl Remove this when we can assume autoconf >= 2.61.
77m4_ifdef([AC_COMPUTE_INT], [], [
78 AC_DEFUN([AC_COMPUTE_INT], [_AC_COMPUTE_INT([$2],[$1],[$3],[$4])])
61]) 79])
diff --git a/m4/stdint_h.m4 b/m4/stdint_h.m4
index 32ba7ae7..7fc2ce9a 100644
--- a/m4/stdint_h.m4
+++ b/m4/stdint_h.m4
@@ -1,27 +1,26 @@
1# stdint_h.m4 serial 3 (gettext-0.12) 1# stdint_h.m4 serial 9
2dnl Copyright (C) 1997-2003 Free Software Foundation, Inc. 2dnl Copyright (C) 1997-2004, 2006, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Paul Eggert. 7dnl From Paul Eggert.
10 8
11# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists, 9# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists,
12# doesn't clash with <sys/types.h>, and declares uintmax_t. 10# doesn't clash with <sys/types.h>, and declares uintmax_t.
13 11
14AC_DEFUN([jm_AC_HEADER_STDINT_H], 12AC_DEFUN([gl_AC_HEADER_STDINT_H],
15[ 13[
16 AC_CACHE_CHECK([for stdint.h], jm_ac_cv_header_stdint_h, 14 AC_CACHE_CHECK([for stdint.h], [gl_cv_header_stdint_h],
17 [AC_TRY_COMPILE( 15 [AC_COMPILE_IFELSE(
18 [#include <sys/types.h> 16 [AC_LANG_PROGRAM(
19#include <stdint.h>], 17 [[#include <sys/types.h>
20 [uintmax_t i = (uintmax_t) -1;], 18 #include <stdint.h>]],
21 jm_ac_cv_header_stdint_h=yes, 19 [[uintmax_t i = (uintmax_t) -1; return !i;]])],
22 jm_ac_cv_header_stdint_h=no)]) 20 [gl_cv_header_stdint_h=yes],
23 if test $jm_ac_cv_header_stdint_h = yes; then 21 [gl_cv_header_stdint_h=no])])
24 AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1, 22 if test $gl_cv_header_stdint_h = yes; then
23 AC_DEFINE_UNQUOTED([HAVE_STDINT_H_WITH_UINTMAX], [1],
25 [Define if <stdint.h> exists, doesn't clash with <sys/types.h>, 24 [Define if <stdint.h> exists, doesn't clash with <sys/types.h>,
26 and declares uintmax_t. ]) 25 and declares uintmax_t. ])
27 fi 26 fi
diff --git a/m4/uintmax_t.m4 b/m4/uintmax_t.m4
index b5f28d44..0a94f17f 100644
--- a/m4/uintmax_t.m4
+++ b/m4/uintmax_t.m4
@@ -1,32 +1,30 @@
1# uintmax_t.m4 serial 7 (gettext-0.12) 1# uintmax_t.m4 serial 12
2dnl Copyright (C) 1997-2003 Free Software Foundation, Inc. 2dnl Copyright (C) 1997-2004, 2007-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Paul Eggert. 7dnl From Paul Eggert.
10 8
11AC_PREREQ(2.13) 9AC_PREREQ([2.13])
12 10
13# Define uintmax_t to 'unsigned long' or 'unsigned long long' 11# Define uintmax_t to 'unsigned long' or 'unsigned long long'
14# if it is not already defined in <stdint.h> or <inttypes.h>. 12# if it is not already defined in <stdint.h> or <inttypes.h>.
15 13
16AC_DEFUN([jm_AC_TYPE_UINTMAX_T], 14AC_DEFUN([gl_AC_TYPE_UINTMAX_T],
17[ 15[
18 AC_REQUIRE([jm_AC_HEADER_INTTYPES_H]) 16 AC_REQUIRE([gl_AC_HEADER_INTTYPES_H])
19 AC_REQUIRE([jm_AC_HEADER_STDINT_H]) 17 AC_REQUIRE([gl_AC_HEADER_STDINT_H])
20 if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then 18 if test $gl_cv_header_inttypes_h = no && test $gl_cv_header_stdint_h = no; then
21 AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG]) 19 AC_REQUIRE([AC_TYPE_UNSIGNED_LONG_LONG_INT])
22 test $ac_cv_type_unsigned_long_long = yes \ 20 test $ac_cv_type_unsigned_long_long_int = yes \
23 && ac_type='unsigned long long' \ 21 && ac_type='unsigned long long' \
24 || ac_type='unsigned long' 22 || ac_type='unsigned long'
25 AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, 23 AC_DEFINE_UNQUOTED([uintmax_t], [$ac_type],
26 [Define to unsigned long or unsigned long long 24 [Define to unsigned long or unsigned long long
27 if <stdint.h> and <inttypes.h> don't define.]) 25 if <stdint.h> and <inttypes.h> don't define.])
28 else 26 else
29 AC_DEFINE(HAVE_UINTMAX_T, 1, 27 AC_DEFINE([HAVE_UINTMAX_T], [1],
30 [Define if you have the 'uintmax_t' type in <stdint.h> or <inttypes.h>.]) 28 [Define if you have the 'uintmax_t' type in <stdint.h> or <inttypes.h>.])
31 fi 29 fi
32]) 30])
diff --git a/m4/visibility.m4 b/m4/visibility.m4
index 2ff6330a..552e3977 100644
--- a/m4/visibility.m4
+++ b/m4/visibility.m4
@@ -1,5 +1,5 @@
1# visibility.m4 serial 1 (gettext-0.15) 1# visibility.m4 serial 5 (gettext-0.18.2)
2dnl Copyright (C) 2005 Free Software Foundation, Inc. 2dnl Copyright (C) 2005, 2008, 2010-2014 Free Software Foundation, Inc.
3dnl This file is free software; the Free Software Foundation 3dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it, 4dnl gives unlimited permission to copy and/or distribute it,
5dnl with or without modifications, as long as this notice is preserved. 5dnl with or without modifications, as long as this notice is preserved.
@@ -12,7 +12,7 @@ dnl __attribute__((__visibility__("hidden"))) and
12dnl __attribute__((__visibility__("default"))). 12dnl __attribute__((__visibility__("default"))).
13dnl Does *not* test for __visibility__("protected") - which has tricky 13dnl Does *not* test for __visibility__("protected") - which has tricky
14dnl semantics (see the 'vismain' test in glibc) and does not exist e.g. on 14dnl semantics (see the 'vismain' test in glibc) and does not exist e.g. on
15dnl MacOS X. 15dnl Mac OS X.
16dnl Does *not* test for __visibility__("internal") - which has processor 16dnl Does *not* test for __visibility__("internal") - which has processor
17dnl dependent semantics. 17dnl dependent semantics.
18dnl Does *not* test for #pragma GCC visibility push(hidden) - which is 18dnl Does *not* test for #pragma GCC visibility push(hidden) - which is
@@ -26,18 +26,43 @@ AC_DEFUN([gl_VISIBILITY],
26 CFLAG_VISIBILITY= 26 CFLAG_VISIBILITY=
27 HAVE_VISIBILITY=0 27 HAVE_VISIBILITY=0
28 if test -n "$GCC"; then 28 if test -n "$GCC"; then
29 dnl First, check whether -Werror can be added to the command line, or
30 dnl whether it leads to an error because of some other option that the
31 dnl user has put into $CC $CFLAGS $CPPFLAGS.
32 AC_MSG_CHECKING([whether the -Werror option is usable])
33 AC_CACHE_VAL([gl_cv_cc_vis_werror], [
34 gl_save_CFLAGS="$CFLAGS"
35 CFLAGS="$CFLAGS -Werror"
36 AC_COMPILE_IFELSE(
37 [AC_LANG_PROGRAM([[]], [[]])],
38 [gl_cv_cc_vis_werror=yes],
39 [gl_cv_cc_vis_werror=no])
40 CFLAGS="$gl_save_CFLAGS"])
41 AC_MSG_RESULT([$gl_cv_cc_vis_werror])
42 dnl Now check whether visibility declarations are supported.
29 AC_MSG_CHECKING([for simple visibility declarations]) 43 AC_MSG_CHECKING([for simple visibility declarations])
30 AC_CACHE_VAL(gl_cv_cc_visibility, [ 44 AC_CACHE_VAL([gl_cv_cc_visibility], [
31 gl_save_CFLAGS="$CFLAGS" 45 gl_save_CFLAGS="$CFLAGS"
32 CFLAGS="$CFLAGS -fvisibility=hidden" 46 CFLAGS="$CFLAGS -fvisibility=hidden"
33 AC_TRY_COMPILE( 47 dnl We use the option -Werror and a function dummyfunc, because on some
34 [extern __attribute__((__visibility__("hidden"))) int hiddenvar; 48 dnl platforms (Cygwin 1.7) the use of -fvisibility triggers a warning
35 extern __attribute__((__visibility__("default"))) int exportedvar; 49 dnl "visibility attribute not supported in this configuration; ignored"
36 extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void); 50 dnl at the first function definition in every compilation unit, and we
37 extern __attribute__((__visibility__("default"))) int exportedfunc (void);], 51 dnl don't want to use the option in this case.
38 [], 52 if test $gl_cv_cc_vis_werror = yes; then
39 gl_cv_cc_visibility=yes, 53 CFLAGS="$CFLAGS -Werror"
40 gl_cv_cc_visibility=no) 54 fi
55 AC_COMPILE_IFELSE(
56 [AC_LANG_PROGRAM(
57 [[extern __attribute__((__visibility__("hidden"))) int hiddenvar;
58 extern __attribute__((__visibility__("default"))) int exportedvar;
59 extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void);
60 extern __attribute__((__visibility__("default"))) int exportedfunc (void);
61 void dummyfunc (void) {}
62 ]],
63 [[]])],
64 [gl_cv_cc_visibility=yes],
65 [gl_cv_cc_visibility=no])
41 CFLAGS="$gl_save_CFLAGS"]) 66 CFLAGS="$gl_save_CFLAGS"])
42 AC_MSG_RESULT([$gl_cv_cc_visibility]) 67 AC_MSG_RESULT([$gl_cv_cc_visibility])
43 if test $gl_cv_cc_visibility = yes; then 68 if test $gl_cv_cc_visibility = yes; then
diff --git a/m4/wchar_t.m4 b/m4/wchar_t.m4
index d8fd1ec5..839a04c1 100644
--- a/m4/wchar_t.m4
+++ b/m4/wchar_t.m4
@@ -1,10 +1,8 @@
1# wchar_t.m4 serial 1 (gettext-0.12) 1# wchar_t.m4 serial 4 (gettext-0.18.2)
2dnl Copyright (C) 2002-2003 Free Software Foundation, Inc. 2dnl Copyright (C) 2002-2003, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10dnl Test whether <stddef.h> has the 'wchar_t' type. 8dnl Test whether <stddef.h> has the 'wchar_t' type.
@@ -12,11 +10,15 @@ dnl Prerequisite: AC_PROG_CC
12 10
13AC_DEFUN([gt_TYPE_WCHAR_T], 11AC_DEFUN([gt_TYPE_WCHAR_T],
14[ 12[
15 AC_CACHE_CHECK([for wchar_t], gt_cv_c_wchar_t, 13 AC_CACHE_CHECK([for wchar_t], [gt_cv_c_wchar_t],
16 [AC_TRY_COMPILE([#include <stddef.h> 14 [AC_COMPILE_IFELSE(
17 wchar_t foo = (wchar_t)'\0';], , 15 [AC_LANG_PROGRAM(
18 gt_cv_c_wchar_t=yes, gt_cv_c_wchar_t=no)]) 16 [[#include <stddef.h>
17 wchar_t foo = (wchar_t)'\0';]],
18 [[]])],
19 [gt_cv_c_wchar_t=yes],
20 [gt_cv_c_wchar_t=no])])
19 if test $gt_cv_c_wchar_t = yes; then 21 if test $gt_cv_c_wchar_t = yes; then
20 AC_DEFINE(HAVE_WCHAR_T, 1, [Define if you have the 'wchar_t' type.]) 22 AC_DEFINE([HAVE_WCHAR_T], [1], [Define if you have the 'wchar_t' type.])
21 fi 23 fi
22]) 24])
diff --git a/m4/wint_t.m4 b/m4/wint_t.m4
index 3d8d2159..9b07b070 100644
--- a/m4/wint_t.m4
+++ b/m4/wint_t.m4
@@ -1,10 +1,8 @@
1# wint_t.m4 serial 1 (gettext-0.12) 1# wint_t.m4 serial 5 (gettext-0.18.2)
2dnl Copyright (C) 2003 Free Software Foundation, Inc. 2dnl Copyright (C) 2003, 2007-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9dnl From Bruno Haible. 7dnl From Bruno Haible.
10dnl Test whether <wchar.h> has the 'wint_t' type. 8dnl Test whether <wchar.h> has the 'wint_t' type.
@@ -12,11 +10,23 @@ dnl Prerequisite: AC_PROG_CC
12 10
13AC_DEFUN([gt_TYPE_WINT_T], 11AC_DEFUN([gt_TYPE_WINT_T],
14[ 12[
15 AC_CACHE_CHECK([for wint_t], gt_cv_c_wint_t, 13 AC_CACHE_CHECK([for wint_t], [gt_cv_c_wint_t],
16 [AC_TRY_COMPILE([#include <wchar.h> 14 [AC_COMPILE_IFELSE(
17 wint_t foo = (wchar_t)'\0';], , 15 [AC_LANG_PROGRAM(
18 gt_cv_c_wint_t=yes, gt_cv_c_wint_t=no)]) 16 [[
17/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18 <wchar.h>.
19 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
20 before <wchar.h>. */
21#include <stddef.h>
22#include <stdio.h>
23#include <time.h>
24#include <wchar.h>
25 wint_t foo = (wchar_t)'\0';]],
26 [[]])],
27 [gt_cv_c_wint_t=yes],
28 [gt_cv_c_wint_t=no])])
19 if test $gt_cv_c_wint_t = yes; then 29 if test $gt_cv_c_wint_t = yes; then
20 AC_DEFINE(HAVE_WINT_T, 1, [Define if you have the 'wint_t' type.]) 30 AC_DEFINE([HAVE_WINT_T], [1], [Define if you have the 'wint_t' type.])
21 fi 31 fi
22]) 32])
diff --git a/m4/xsize.m4 b/m4/xsize.m4
index 9b7cf9b4..3af23ec7 100644
--- a/m4/xsize.m4
+++ b/m4/xsize.m4
@@ -1,14 +1,12 @@
1# xsize.m4 serial 2 1# xsize.m4 serial 5
2dnl Copyright (C) 2003 Free Software Foundation, Inc. 2dnl Copyright (C) 2003-2004, 2008-2014 Free Software Foundation, Inc.
3dnl This file is free software, distributed under the terms of the GNU 3dnl This file is free software; the Free Software Foundation
4dnl General Public License. As a special exception to the GNU General 4dnl gives unlimited permission to copy and/or distribute it,
5dnl Public License, this file may be distributed as part of a program 5dnl with or without modifications, as long as this notice is preserved.
6dnl that contains a configuration script generated by Autoconf, under
7dnl the same distribution terms as the rest of that program.
8 6
9AC_DEFUN([gl_XSIZE], 7AC_DEFUN([gl_XSIZE],
10[ 8[
11 dnl Prerequisites of lib/xsize.h. 9 dnl Prerequisites of lib/xsize.h.
12 AC_REQUIRE([gl_SIZE_MAX]) 10 AC_REQUIRE([gl_SIZE_MAX])
13 AC_CHECK_HEADERS(stdint.h) 11 AC_CHECK_HEADERS([stdint.h])
14]) 12])
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 8687613b..46fd1bf5 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -25,9 +25,6 @@ src/fs/gnunet-fs-gtk_publish-dialog.c
25src/fs/gnunet-fs-gtk_publish-edit-dialog.c 25src/fs/gnunet-fs-gtk_publish-edit-dialog.c
26src/fs/gnunet-fs-gtk_unindex.c 26src/fs/gnunet-fs-gtk_unindex.c
27src/fs/metatypes.c 27src/fs/metatypes.c
28src/identity/gnunet-identity-gtk_about.c
29src/identity/gnunet-identity-gtk_advertise.c
30src/identity/gnunet-identity-gtk.c
31src/lib/about.c 28src/lib/about.c
32src/lib/animations.c 29src/lib/animations.c
33src/lib/eventloop.c 30src/lib/eventloop.c