Merge lp:~indicator-applet-developers/indicator-datetime/ubuntu into lp:~ubuntu-desktop/indicator-datetime/ubuntu
- ubuntu
- Merge into ubuntu
Proposed by
Ted Gould
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ken VanDine | Pending | ||
Review via email: mp+35016@code.launchpad.net |
Commit message
Description of the change
0.0.6
To post a comment you must log in.
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'ChangeLog' |
2 | --- ChangeLog 2010-07-15 15:31:28 +0000 |
3 | +++ ChangeLog 2010-09-09 18:15:53 +0000 |
4 | @@ -1,5 +1,265 @@ |
5 | # Generated by Makefile. Do not edit. |
6 | |
7 | +2010-09-07 Ted Gould <ted@gould.cx> |
8 | + |
9 | + Distributing the schema XML |
10 | + |
11 | +2010-09-07 Ted Gould <ted@gould.cx> |
12 | + |
13 | + Fix for make dist |
14 | + |
15 | +2010-09-07 Ted Gould <ted@gould.cx> |
16 | + |
17 | + Update appropriately |
18 | + |
19 | +2010-08-31 Ted Gould <ted@gould.cx> |
20 | + |
21 | + Updating to trunk |
22 | + |
23 | +2010-08-30 Ted Gould <ted@gould.cx> |
24 | + |
25 | + Copyright stuffs |
26 | + |
27 | +2010-08-30 Ted Gould <ted@gould.cx> |
28 | + |
29 | + If the timezone changes we need to setup a different timer. |
30 | + |
31 | +2010-08-30 Ted Gould <ted@gould.cx> |
32 | + |
33 | + Set a timer to update the date once a day. |
34 | + |
35 | +2010-08-30 Ted Gould <ted@gould.cx> |
36 | + |
37 | + Add in a signal handler for the update time signal |
38 | + |
39 | +2010-08-30 Ted Gould <ted@gould.cx> |
40 | + |
41 | + Create the service proxy and give it a lifecycle |
42 | + |
43 | +2010-08-30 Ted Gould <ted@gould.cx> |
44 | + |
45 | + Watching the timezone file and updating based on it |
46 | + |
47 | +2010-08-30 Ted Gould <ted@gould.cx> |
48 | + |
49 | + Adding a way to emit the signal |
50 | + |
51 | +2010-08-30 Ted Gould <ted@gould.cx> |
52 | + |
53 | + Adding in the update time signal |
54 | + |
55 | +2010-08-30 Ted Gould <ted@gould.cx> |
56 | + |
57 | + Building us a dbus interface |
58 | + |
59 | +2010-08-30 Ted Gould <ted@gould.cx> |
60 | + |
61 | + Connecting onto the dbus |
62 | + |
63 | +2010-08-30 Ted Gould <ted@gould.cx> |
64 | + |
65 | + Whitespace cleanup |
66 | + |
67 | +2010-08-30 Ted Gould <ted@gould.cx> |
68 | + |
69 | + Adding an object to be the interface object for dbus |
70 | + |
71 | +2010-08-30 Ted Gould <ted@gould.cx> |
72 | + |
73 | + Adding in a dbus interface file. |
74 | + |
75 | +2010-08-30 Ted Gould <ted@gould.cx> |
76 | + |
77 | + Putting the timezone file into the build line |
78 | + |
79 | +2010-07-22 David Barth <david.barth@canonical.com> |
80 | + |
81 | + version 0.0.5 |
82 | + |
83 | +2010-07-22 David Barth <david.barth@canonical.com> |
84 | + |
85 | + merging the new calendar widget branch |
86 | + |
87 | +2010-07-22 David Barth <david.barth@canonical.com> |
88 | + |
89 | + updates the label for changing settings |
90 | + |
91 | +2010-07-22 David Barth <david.barth@canonical.com> |
92 | + |
93 | + add a calendar widget to the menu |
94 | + |
95 | +2010-07-22 David Barth <david.barth@canonical.com> |
96 | + |
97 | + make sure we get the new IDO calendar menu item |
98 | + |
99 | +2010-07-22 David Barth <david.barth@canonical.com> |
100 | + |
101 | + make sure we get the right glib version with gsettings support |
102 | + |
103 | +2010-07-19 Ted Gould <ted@gould.cx> |
104 | + |
105 | + Making the timeformat configurable via translations and gsettings. |
106 | + |
107 | +2010-07-16 Ted Gould <ted@gould.cx> |
108 | + |
109 | + In the timer function we're recycling the pointer to struct tm |
110 | + |
111 | +2010-07-16 Ted Gould <ted@gould.cx> |
112 | + |
113 | + Making it so that update_label can return struct tm |
114 | + |
115 | +2010-07-16 Ted Gould <ted@gould.cx> |
116 | + |
117 | + Making it so that ltime can be a parameter. |
118 | + |
119 | +2010-07-16 Ted Gould <ted@gould.cx> |
120 | + |
121 | + Starting to smartly choose when to update the time. |
122 | + |
123 | +2010-07-16 Ted Gould <ted@gould.cx> |
124 | + |
125 | + Protecting the timer from setting up more than one and having it setup when the properties change. |
126 | + |
127 | +2010-07-16 Ted Gould <ted@gould.cx> |
128 | + |
129 | + Adding a level of indirection to encapsulate the setting up of the timer func |
130 | + |
131 | +2010-07-16 Ted Gould <ted@gould.cx> |
132 | + |
133 | + Don't check the size of a label we don't have. |
134 | + |
135 | +2010-07-16 Ted Gould <ted@gould.cx> |
136 | + |
137 | + Ah, dumb bug |
138 | + |
139 | +2010-07-16 Ted Gould <ted@gould.cx> |
140 | + |
141 | + Debug message to check posibilities. |
142 | + |
143 | +2010-07-16 Ted Gould <ted@gould.cx> |
144 | + |
145 | + Making the posibility of huge arrays testing length of month names and weekday names, and posibily both. |
146 | + |
147 | +2010-07-16 Ted Gould <ted@gould.cx> |
148 | + |
149 | + Bring in the measuring tape. |
150 | + |
151 | +2010-07-16 Ted Gould <ted@gould.cx> |
152 | + |
153 | + Starting to build up our new measuring algorithm. Now with just AM/PM in it. |
154 | + |
155 | +2010-07-16 Ted Gould <ted@gould.cx> |
156 | + |
157 | + Generating the bitmask of posibilities from the format string. |
158 | + |
159 | +2010-07-16 Ted Gould <ted@gould.cx> |
160 | + |
161 | + A big ass table of the strftime() format strings and what they effect, now we can calculate the max length. |
162 | + |
163 | +2010-07-16 Ted Gould <ted@gould.cx> |
164 | + |
165 | + Building up the date string. |
166 | + |
167 | +2010-07-16 Ted Gould <ted@gould.cx> |
168 | + |
169 | + Setting the properties only changes things if we're not in custom mode. |
170 | + |
171 | +2010-07-16 Ted Gould <ted@gould.cx> |
172 | + |
173 | + Adding in an update on changing the format string. |
174 | + |
175 | +2010-07-16 Ted Gould <ted@gould.cx> |
176 | + |
177 | + Gets us somewhere of coming up with a time string. Wow, complex. |
178 | + |
179 | +2010-07-15 Ted Gould <ted@gould.cx> |
180 | + |
181 | + Filling out set too. |
182 | + |
183 | +2010-07-15 Ted Gould <ted@gould.cx> |
184 | + |
185 | + Getting some guts into get |
186 | + |
187 | +2010-07-15 Ted Gould <ted@gould.cx> |
188 | + |
189 | + Fleshing out the set and get enum functions. |
190 | + |
191 | +2010-07-15 Ted Gould <ted@gould.cx> |
192 | + |
193 | + Adding a mapping function to pull in the enum value. |
194 | + |
195 | +2010-07-15 Ted Gould <ted@gould.cx> |
196 | + |
197 | + Clearing set and get property as we're going to have to start from scratch there. |
198 | + |
199 | +2010-07-15 Ted Gould <ted@gould.cx> |
200 | + |
201 | + Moving all these properties into the private structure. |
202 | + |
203 | +2010-07-15 Ted Gould <ted@gould.cx> |
204 | + |
205 | + Binding the properties into the settings database. |
206 | + |
207 | +2010-07-15 Ted Gould <ted@gould.cx> |
208 | + |
209 | + Whoa, we got lots of properties now. |
210 | + |
211 | +2010-07-15 Ted Gould <ted@gould.cx> |
212 | + |
213 | + Turning the time format string into custom time format. |
214 | + |
215 | +2010-07-15 Ted Gould <ted@gould.cx> |
216 | + |
217 | + Getting defines for all the new settings and making things compile again. |
218 | + |
219 | +2010-07-15 Ted Gould <ted@gould.cx> |
220 | + |
221 | + I swear, there were somethings I didn't change! Getting some final settings that make sense. |
222 | + |
223 | +2010-07-14 Ted Gould <ted@gould.cx> |
224 | + |
225 | + Ignoring the tramp stamp |
226 | + |
227 | +2010-07-12 Ted Gould <ted@gould.cx> |
228 | + |
229 | + Going into the gsettings world. |
230 | + |
231 | +2010-07-12 Ted Gould <ted@gould.cx> |
232 | + |
233 | + Moving the default format into a define and using our new variable. |
234 | + |
235 | +2010-07-12 Ted Gould <ted@gould.cx> |
236 | + |
237 | + Setting up a 'time_format' variable and pulling it into a property. |
238 | + |
239 | +2010-07-12 Ted Gould <ted@gould.cx> |
240 | + |
241 | + Setting up basic property stuff and making a husk of a first property. |
242 | + |
243 | +2010-07-12 Ted Gould <ted@gould.cx> |
244 | + |
245 | + Getting the schema to validate. |
246 | + |
247 | +2010-07-12 Ted Gould <ted@gould.cx> |
248 | + |
249 | + Renaming file |
250 | + |
251 | +2010-07-12 Ted Gould <ted@gould.cx> |
252 | + |
253 | + Bringing in the gesttings love. |
254 | + |
255 | +2010-07-12 Ted Gould <ted@gould.cx> |
256 | + |
257 | + Trying to build the first gschema file. |
258 | + |
259 | +2010-07-12 Ted Gould <ted@gould.cx> |
260 | + |
261 | + As a basis we need to have a service based architecture. |
262 | + |
263 | +2010-07-15 Ted Gould <ted@gould.cx> |
264 | + |
265 | + 0.0.4 |
266 | + |
267 | 2010-07-13 Ted Gould <ted@gould.cx> |
268 | |
269 | Adjusting indicator to be service based. |
270 | |
271 | === modified file 'INSTALL' |
272 | --- INSTALL 2010-02-26 09:39:44 +0000 |
273 | +++ INSTALL 2010-09-09 18:15:53 +0000 |
274 | @@ -4,8 +4,10 @@ |
275 | Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, |
276 | 2006, 2007, 2008, 2009 Free Software Foundation, Inc. |
277 | |
278 | - This file is free documentation; the Free Software Foundation gives |
279 | -unlimited permission to copy, distribute and modify it. |
280 | + Copying and distribution of this file, with or without modification, |
281 | +are permitted in any medium without royalty provided the copyright |
282 | +notice and this notice are preserved. This file is offered as-is, |
283 | +without warranty of any kind. |
284 | |
285 | Basic Installation |
286 | ================== |
287 | @@ -13,7 +15,11 @@ |
288 | Briefly, the shell commands `./configure; make; make install' should |
289 | configure, build, and install this package. The following |
290 | more-detailed instructions are generic; see the `README' file for |
291 | -instructions specific to this package. |
292 | +instructions specific to this package. Some packages provide this |
293 | +`INSTALL' file but do not implement all of the features documented |
294 | +below. The lack of an optional feature in a given package is not |
295 | +necessarily a bug. More recommendations for GNU packages can be found |
296 | +in *note Makefile Conventions: (standards)Makefile Conventions. |
297 | |
298 | The `configure' shell script attempts to guess correct values for |
299 | various system-dependent variables used during compilation. It uses |
300 | @@ -42,7 +48,7 @@ |
301 | you want to change it or regenerate `configure' using a newer version |
302 | of `autoconf'. |
303 | |
304 | -The simplest way to compile this package is: |
305 | + The simplest way to compile this package is: |
306 | |
307 | 1. `cd' to the directory containing the package's source code and type |
308 | `./configure' to configure the package for your system. |
309 | @@ -53,12 +59,22 @@ |
310 | 2. Type `make' to compile the package. |
311 | |
312 | 3. Optionally, type `make check' to run any self-tests that come with |
313 | - the package. |
314 | + the package, generally using the just-built uninstalled binaries. |
315 | |
316 | 4. Type `make install' to install the programs and any data files and |
317 | - documentation. |
318 | - |
319 | - 5. You can remove the program binaries and object files from the |
320 | + documentation. When installing into a prefix owned by root, it is |
321 | + recommended that the package be configured and built as a regular |
322 | + user, and only the `make install' phase executed with root |
323 | + privileges. |
324 | + |
325 | + 5. Optionally, type `make installcheck' to repeat any self-tests, but |
326 | + this time using the binaries in their final installed location. |
327 | + This target does not install anything. Running this target as a |
328 | + regular user, particularly if the prior `make install' required |
329 | + root privileges, verifies that the installation completed |
330 | + correctly. |
331 | + |
332 | + 6. You can remove the program binaries and object files from the |
333 | source code directory by typing `make clean'. To also remove the |
334 | files that `configure' created (so you can compile the package for |
335 | a different kind of computer), type `make distclean'. There is |
336 | @@ -67,8 +83,15 @@ |
337 | all sorts of other programs in order to regenerate files that came |
338 | with the distribution. |
339 | |
340 | - 6. Often, you can also type `make uninstall' to remove the installed |
341 | - files again. |
342 | + 7. Often, you can also type `make uninstall' to remove the installed |
343 | + files again. In practice, not all packages have tested that |
344 | + uninstallation works correctly, even though it is required by the |
345 | + GNU Coding Standards. |
346 | + |
347 | + 8. Some packages, particularly those that use Automake, provide `make |
348 | + distcheck', which can by used by developers to test that all other |
349 | + targets like `make install' and `make uninstall' work correctly. |
350 | + This target is generally not run by end users. |
351 | |
352 | Compilers and Options |
353 | ===================== |
354 | @@ -93,7 +116,8 @@ |
355 | own directory. To do this, you can use GNU `make'. `cd' to the |
356 | directory where you want the object files and executables to go and run |
357 | the `configure' script. `configure' automatically checks for the |
358 | -source code in the directory that `configure' is in and in `..'. |
359 | +source code in the directory that `configure' is in and in `..'. This |
360 | +is known as a "VPATH" build. |
361 | |
362 | With a non-GNU `make', it is safer to compile the package for one |
363 | architecture at a time in the source code directory. After you have |
364 | @@ -120,7 +144,8 @@ |
365 | By default, `make install' installs the package's commands under |
366 | `/usr/local/bin', include files under `/usr/local/include', etc. You |
367 | can specify an installation prefix other than `/usr/local' by giving |
368 | -`configure' the option `--prefix=PREFIX'. |
369 | +`configure' the option `--prefix=PREFIX', where PREFIX must be an |
370 | +absolute file name. |
371 | |
372 | You can specify separate installation prefixes for |
373 | architecture-specific files and architecture-independent files. If you |
374 | @@ -131,15 +156,46 @@ |
375 | In addition, if you use an unusual directory layout you can give |
376 | options like `--bindir=DIR' to specify different values for particular |
377 | kinds of files. Run `configure --help' for a list of the directories |
378 | -you can set and what kinds of files go in them. |
379 | +you can set and what kinds of files go in them. In general, the |
380 | +default for these options is expressed in terms of `${prefix}', so that |
381 | +specifying just `--prefix' will affect all of the other directory |
382 | +specifications that were not explicitly provided. |
383 | + |
384 | + The most portable way to affect installation locations is to pass the |
385 | +correct locations to `configure'; however, many packages provide one or |
386 | +both of the following shortcuts of passing variable assignments to the |
387 | +`make install' command line to change installation locations without |
388 | +having to reconfigure or recompile. |
389 | + |
390 | + The first method involves providing an override variable for each |
391 | +affected directory. For example, `make install |
392 | +prefix=/alternate/directory' will choose an alternate location for all |
393 | +directory configuration variables that were expressed in terms of |
394 | +`${prefix}'. Any directories that were specified during `configure', |
395 | +but not in terms of `${prefix}', must each be overridden at install |
396 | +time for the entire installation to be relocated. The approach of |
397 | +makefile variable overrides for each directory variable is required by |
398 | +the GNU Coding Standards, and ideally causes no recompilation. |
399 | +However, some platforms have known limitations with the semantics of |
400 | +shared libraries that end up requiring recompilation when using this |
401 | +method, particularly noticeable in packages that use GNU Libtool. |
402 | + |
403 | + The second method involves providing the `DESTDIR' variable. For |
404 | +example, `make install DESTDIR=/alternate/directory' will prepend |
405 | +`/alternate/directory' before all installation names. The approach of |
406 | +`DESTDIR' overrides is not required by the GNU Coding Standards, and |
407 | +does not work on platforms that have drive letters. On the other hand, |
408 | +it does better at avoiding recompilation issues, and works well even |
409 | +when some directory options were not specified in terms of `${prefix}' |
410 | +at `configure' time. |
411 | + |
412 | +Optional Features |
413 | +================= |
414 | |
415 | If the package supports it, you can cause programs to be installed |
416 | with an extra prefix or suffix on their names by giving `configure' the |
417 | option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. |
418 | |
419 | -Optional Features |
420 | -================= |
421 | - |
422 | Some packages pay attention to `--enable-FEATURE' options to |
423 | `configure', where FEATURE indicates an optional part of the package. |
424 | They may also pay attention to `--with-PACKAGE' options, where PACKAGE |
425 | @@ -152,6 +208,13 @@ |
426 | you can use the `configure' options `--x-includes=DIR' and |
427 | `--x-libraries=DIR' to specify their locations. |
428 | |
429 | + Some packages offer the ability to configure how verbose the |
430 | +execution of `make' will be. For these packages, running `./configure |
431 | +--enable-silent-rules' sets the default to minimal output, which can be |
432 | +overridden with `make V=1'; while running `./configure |
433 | +--disable-silent-rules' sets the default to verbose, which can be |
434 | +overridden with `make V=0'. |
435 | + |
436 | Particular systems |
437 | ================== |
438 | |
439 | @@ -288,7 +351,7 @@ |
440 | `configure' can determine that directory automatically. |
441 | |
442 | `--prefix=DIR' |
443 | - Use DIR as the installation prefix. *Note Installation Names:: |
444 | + Use DIR as the installation prefix. *note Installation Names:: |
445 | for more details, including other options available for fine-tuning |
446 | the installation locations. |
447 | |
448 | |
449 | === modified file 'Makefile.in' |
450 | --- Makefile.in 2010-03-04 18:05:07 +0000 |
451 | +++ Makefile.in 2010-09-09 18:15:53 +0000 |
452 | @@ -40,10 +40,7 @@ |
453 | compile config.guess config.sub depcomp install-sh ltmain.sh \ |
454 | missing mkinstalldirs |
455 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 |
456 | -am__aclocal_m4_deps = $(top_srcdir)/m4/intltool.m4 \ |
457 | - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ |
458 | - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ |
459 | - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac |
460 | +am__aclocal_m4_deps = $(top_srcdir)/configure.ac |
461 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
462 | $(ACLOCAL_M4) |
463 | am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ |
464 | @@ -141,12 +138,14 @@ |
465 | EXEEXT = @EXEEXT@ |
466 | FGREP = @FGREP@ |
467 | GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ |
468 | +GLIB_COMPILE_SCHEMAS = @GLIB_COMPILE_SCHEMAS@ |
469 | GLIB_GENMARSHAL = @GLIB_GENMARSHAL@ |
470 | GLIB_MKENUMS = @GLIB_MKENUMS@ |
471 | GMOFILES = @GMOFILES@ |
472 | GMSGFMT = @GMSGFMT@ |
473 | GNOMELOCALEDIR = @GNOMELOCALEDIR@ |
474 | GREP = @GREP@ |
475 | +GSETTINGS_DISABLE_SCHEMAS_COMPILE = @GSETTINGS_DISABLE_SCHEMAS_COMPILE@ |
476 | INDICATORDIR = @INDICATORDIR@ |
477 | INDICATORICONSDIR = @INDICATORICONSDIR@ |
478 | INDICATOR_CFLAGS = @INDICATOR_CFLAGS@ |
479 | @@ -192,6 +191,8 @@ |
480 | PACKAGE_VERSION = @PACKAGE_VERSION@ |
481 | PATH_SEPARATOR = @PATH_SEPARATOR@ |
482 | PKG_CONFIG = @PKG_CONFIG@ |
483 | +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ |
484 | +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ |
485 | POFILES = @POFILES@ |
486 | POSUB = @POSUB@ |
487 | PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ |
488 | @@ -227,6 +228,7 @@ |
489 | docdir = @docdir@ |
490 | dvidir = @dvidir@ |
491 | exec_prefix = @exec_prefix@ |
492 | +gsettingsschemadir = @gsettingsschemadir@ |
493 | host = @host@ |
494 | host_alias = @host_alias@ |
495 | host_cpu = @host_cpu@ |
496 | |
497 | === modified file 'aclocal.m4' |
498 | --- aclocal.m4 2010-03-04 18:05:07 +0000 |
499 | +++ aclocal.m4 2010-09-09 18:15:53 +0000 |
500 | @@ -13,8 +13,8 @@ |
501 | |
502 | m4_ifndef([AC_AUTOCONF_VERSION], |
503 | [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl |
504 | -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],, |
505 | -[m4_warning([this file was generated for autoconf 2.65. |
506 | +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],, |
507 | +[m4_warning([this file was generated for autoconf 2.67. |
508 | You have another version of autoconf. It may work, but is not guaranteed to. |
509 | If you have problems, you may need to regenerate the build system entirely. |
510 | To do so, use the procedure documented by the package, typically `autoreconf'.])]) |
511 | @@ -301,7 +301,7 @@ |
512 | |
513 | dnl These rules are solely for the distribution goal. While doing this |
514 | dnl we only have to keep exactly one list of the available catalogs |
515 | - dnl in configure.in. |
516 | + dnl in configure.ac. |
517 | for lang in $ALL_LINGUAS; do |
518 | GMOFILES="$GMOFILES $lang.gmo" |
519 | POFILES="$POFILES $lang.po" |
520 | @@ -430,7 +430,7 @@ |
521 | dnl |
522 | dnl Now the definitions that aclocal will find |
523 | dnl |
524 | -ifdef(glib_configure_in,[],[ |
525 | +ifdef(glib_configure_ac,[],[ |
526 | AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)]) |
527 | AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)]) |
528 | ])dnl |
529 | @@ -452,8 +452,8263 @@ |
530 | fi]) |
531 | |
532 | |
533 | -# nls.m4 serial 3 (gettext-0.15) |
534 | -dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc. |
535 | +dnl GLIB_GSETTINGS |
536 | +dnl Defines GSETTINGS_SCHEMAS_INSTALL which controls whether |
537 | +dnl the schema should be compiled |
538 | +dnl |
539 | + |
540 | +AC_DEFUN([GLIB_GSETTINGS], |
541 | +[ |
542 | + m4_pattern_allow([AM_V_GEN]) |
543 | + AC_ARG_ENABLE(schemas-compile, |
544 | + AC_HELP_STRING([--disable-schemas-compile], |
545 | + [Disable regeneration of gschemas.compiled on install]), |
546 | + [case ${enableval} in |
547 | + yes) GSETTINGS_DISABLE_SCHEMAS_COMPILE="" ;; |
548 | + no) GSETTINGS_DISABLE_SCHEMAS_COMPILE="1" ;; |
549 | + *) AC_MSG_ERROR([bad value ${enableval} for --enable-schemas-compile]) ;; |
550 | + esac]) |
551 | + AC_SUBST([GSETTINGS_DISABLE_SCHEMAS_COMPILE]) |
552 | + PKG_PROG_PKG_CONFIG([0.16]) |
553 | + AC_SUBST(gsettingsschemadir, [${datadir}/glib-2.0/schemas]) |
554 | + if test x$cross_compiling != xyes; then |
555 | + GLIB_COMPILE_SCHEMAS=`$PKG_CONFIG --variable glib_compile_schemas gio-2.0` |
556 | + else |
557 | + AC_PATH_PROG(GLIB_COMPILE_SCHEMAS, glib-compile-schemas) |
558 | + fi |
559 | + AC_SUBST(GLIB_COMPILE_SCHEMAS) |
560 | + if test "x$GLIB_COMPILE_SCHEMAS" = "x"; then |
561 | + ifelse([$2],,[AC_MSG_ERROR([glib-compile-schemas not found.])],[$2]) |
562 | + else |
563 | + ifelse([$1],,[:],[$1]) |
564 | + fi |
565 | + |
566 | + GSETTINGS_RULES=' |
567 | +.PHONY : uninstall-gsettings-schemas install-gsettings-schemas clean-gsettings-schemas |
568 | + |
569 | +mostlyclean-am: clean-gsettings-schemas |
570 | + |
571 | +gsettings__enum_file = $(addsuffix .enums.xml,$(gsettings_ENUM_NAMESPACE)) |
572 | + |
573 | +%.gschema.valid: %.gschema.xml $(gsettings__enum_file) |
574 | + $(AM_V_GEN) if test -f "$<"; then d=; else d="$(srcdir)/"; fi; $(GLIB_COMPILE_SCHEMAS) --dry-run $(addprefix --schema-file=,$(gsettings__enum_file)) --schema-file=$${d}$< && touch [$]@ |
575 | + |
576 | +all-am: $(gsettings_SCHEMAS:.xml=.valid) |
577 | +uninstall-am: uninstall-gsettings-schemas |
578 | +install-data-am: install-gsettings-schemas |
579 | + |
580 | +.SECONDARY: $(gsettings_SCHEMAS) |
581 | + |
582 | +gsettings__base_list = \ |
583 | + sed "$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g" | \ |
584 | + sed "$$!N;$$!N;$$!N;$$!N;s/\n/ /g" |
585 | + |
586 | +install-gsettings-schemas: $(gsettings_SCHEMAS:.xml=.valid) $(gsettings__enum_file) |
587 | + @$(NORMAL_INSTALL) |
588 | + test -z "$(gsettingsschemadir)" || $(MKDIR_P) "$(DESTDIR)$(gsettingsschemadir)" |
589 | + @list='\''$(gsettings__enum_file) $(gsettings_SCHEMAS)'\''; test -n "$(gsettingsschemadir)" || list=; \ |
590 | + for p in $$list; do \ |
591 | + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ |
592 | + echo "$$d$$p"; \ |
593 | + done | $(gsettings__base_list) | \ |
594 | + while read files; do \ |
595 | + echo " $(INSTALL_DATA) $$files '\''$(DESTDIR)$(gsettingsschemadir)'\''"; \ |
596 | + $(INSTALL_DATA) $$files "$(DESTDIR)$(gsettingsschemadir)" || exit $$?; \ |
597 | + done |
598 | + test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir) |
599 | + |
600 | +uninstall-gsettings-schemas: |
601 | + @$(NORMAL_UNINSTALL) |
602 | + @list='\''$(gsettings_SCHEMAS) $(gsettings__enum_file)'\''; test -n "$(gsettingsschemadir)" || list=; \ |
603 | + files=`for p in $$list; do echo $$p; done | sed -e '\''s|^.*/||'\''`; \ |
604 | + test -n "$$files" || exit 0; \ |
605 | + echo " ( cd '\''$(DESTDIR)$(gsettingsschemadir)'\'' && rm -f" $$files ")"; \ |
606 | + cd "$(DESTDIR)$(gsettingsschemadir)" && rm -f $$files |
607 | + test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir) |
608 | + |
609 | +clean-gsettings-schemas: |
610 | + rm -f $(gsettings_SCHEMAS:.xml=.valid) $(gsettings__enum_file) |
611 | + |
612 | +ifdef gsettings_ENUM_NAMESPACE |
613 | +$(gsettings__enum_file): $(gsettings_ENUM_FILES) |
614 | + $(AM_V_GEN) glib-mkenums --comments '\''<!-- @comment@ -->'\'' --fhead "<schemalist>" --vhead " <@type@ id='\''$(gsettings_ENUM_NAMESPACE).@EnumName@'\''>" --vprod " <value nick='\''@valuenick@'\'' value='\''@valuenum@'\''/>" --vtail " </@type@>" --ftail "</schemalist>" $(gsettings_ENUM_FILES) > [$]@.tmp && mv [$]@.tmp [$]@ |
615 | +endif |
616 | +' |
617 | + _GSETTINGS_SUBST(GSETTINGS_RULES) |
618 | +]) |
619 | + |
620 | +dnl _GSETTINGS_SUBST(VARIABLE) |
621 | +dnl Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST |
622 | +AC_DEFUN([_GSETTINGS_SUBST], |
623 | +[ |
624 | +AC_SUBST([$1]) |
625 | +m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])]) |
626 | +] |
627 | +) |
628 | + |
629 | + |
630 | +dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml]) |
631 | +# serial 40 IT_PROG_INTLTOOL |
632 | +AC_DEFUN([IT_PROG_INTLTOOL], [ |
633 | +AC_PREREQ([2.50])dnl |
634 | +AC_REQUIRE([AM_NLS])dnl |
635 | + |
636 | +case "$am__api_version" in |
637 | + 1.[01234]) |
638 | + AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool]) |
639 | + ;; |
640 | + *) |
641 | + ;; |
642 | +esac |
643 | + |
644 | +if test -n "$1"; then |
645 | + AC_MSG_CHECKING([for intltool >= $1]) |
646 | + |
647 | + INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'` |
648 | + INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3` |
649 | + [INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'` |
650 | + ] |
651 | + AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found]) |
652 | + test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" || |
653 | + AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.]) |
654 | +fi |
655 | + |
656 | +AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update]) |
657 | +AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge]) |
658 | +AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract]) |
659 | +if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then |
660 | + AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.]) |
661 | +fi |
662 | + |
663 | + INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
664 | +INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
665 | + INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
666 | + INTLTOOL_PROP_RULE='%.prop: %.prop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
667 | + INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -p $(top_srcdir)/po $< [$]@' |
668 | + INTLTOOL_PONG_RULE='%.pong: %.pong.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
669 | + INTLTOOL_SERVER_RULE='%.server: %.server.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
670 | + INTLTOOL_SHEET_RULE='%.sheet: %.sheet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
671 | +INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
672 | + INTLTOOL_UI_RULE='%.ui: %.ui.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
673 | + INTLTOOL_XML_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
674 | + INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< [$]@' |
675 | + INTLTOOL_XAM_RULE='%.xam: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
676 | + INTLTOOL_KBD_RULE='%.kbd: %.kbd.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
677 | + INTLTOOL_CAVES_RULE='%.caves: %.caves.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
678 | + INTLTOOL_SCHEMAS_RULE='%.schemas: %.schemas.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
679 | + INTLTOOL_THEME_RULE='%.theme: %.theme.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
680 | + INTLTOOL_SERVICE_RULE='%.service: %.service.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
681 | + INTLTOOL_POLICY_RULE='%.policy: %.policy.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' |
682 | + |
683 | +_IT_SUBST(INTLTOOL_DESKTOP_RULE) |
684 | +_IT_SUBST(INTLTOOL_DIRECTORY_RULE) |
685 | +_IT_SUBST(INTLTOOL_KEYS_RULE) |
686 | +_IT_SUBST(INTLTOOL_PROP_RULE) |
687 | +_IT_SUBST(INTLTOOL_OAF_RULE) |
688 | +_IT_SUBST(INTLTOOL_PONG_RULE) |
689 | +_IT_SUBST(INTLTOOL_SERVER_RULE) |
690 | +_IT_SUBST(INTLTOOL_SHEET_RULE) |
691 | +_IT_SUBST(INTLTOOL_SOUNDLIST_RULE) |
692 | +_IT_SUBST(INTLTOOL_UI_RULE) |
693 | +_IT_SUBST(INTLTOOL_XAM_RULE) |
694 | +_IT_SUBST(INTLTOOL_KBD_RULE) |
695 | +_IT_SUBST(INTLTOOL_XML_RULE) |
696 | +_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE) |
697 | +_IT_SUBST(INTLTOOL_CAVES_RULE) |
698 | +_IT_SUBST(INTLTOOL_SCHEMAS_RULE) |
699 | +_IT_SUBST(INTLTOOL_THEME_RULE) |
700 | +_IT_SUBST(INTLTOOL_SERVICE_RULE) |
701 | +_IT_SUBST(INTLTOOL_POLICY_RULE) |
702 | + |
703 | +# Check the gettext tools to make sure they are GNU |
704 | +AC_PATH_PROG(XGETTEXT, xgettext) |
705 | +AC_PATH_PROG(MSGMERGE, msgmerge) |
706 | +AC_PATH_PROG(MSGFMT, msgfmt) |
707 | +AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) |
708 | +if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then |
709 | + AC_MSG_ERROR([GNU gettext tools not found; required for intltool]) |
710 | +fi |
711 | +xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`" |
712 | +mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`" |
713 | +mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`" |
714 | +if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then |
715 | + AC_MSG_ERROR([GNU gettext tools not found; required for intltool]) |
716 | +fi |
717 | + |
718 | +AC_PATH_PROG(INTLTOOL_PERL, perl) |
719 | +if test -z "$INTLTOOL_PERL"; then |
720 | + AC_MSG_ERROR([perl not found]) |
721 | +fi |
722 | +AC_MSG_CHECKING([for perl >= 5.8.1]) |
723 | +$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1 |
724 | +if test $? -ne 0; then |
725 | + AC_MSG_ERROR([perl 5.8.1 is required for intltool]) |
726 | +else |
727 | + IT_PERL_VERSION="`$INTLTOOL_PERL -e \"printf '%vd', $^V\"`" |
728 | + AC_MSG_RESULT([$IT_PERL_VERSION]) |
729 | +fi |
730 | +if test "x$2" != "xno-xml"; then |
731 | + AC_MSG_CHECKING([for XML::Parser]) |
732 | + if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then |
733 | + AC_MSG_RESULT([ok]) |
734 | + else |
735 | + AC_MSG_ERROR([XML::Parser perl module is required for intltool]) |
736 | + fi |
737 | +fi |
738 | + |
739 | +# Substitute ALL_LINGUAS so we can use it in po/Makefile |
740 | +AC_SUBST(ALL_LINGUAS) |
741 | + |
742 | +# Set DATADIRNAME correctly if it is not set yet |
743 | +# (copied from glib-gettext.m4) |
744 | +if test -z "$DATADIRNAME"; then |
745 | + AC_LINK_IFELSE( |
746 | + [AC_LANG_PROGRAM([[]], |
747 | + [[extern int _nl_msg_cat_cntr; |
748 | + return _nl_msg_cat_cntr]])], |
749 | + [DATADIRNAME=share], |
750 | + [case $host in |
751 | + *-*-solaris*) |
752 | + dnl On Solaris, if bind_textdomain_codeset is in libc, |
753 | + dnl GNU format message catalog is always supported, |
754 | + dnl since both are added to the libc all together. |
755 | + dnl Hence, we'd like to go with DATADIRNAME=share |
756 | + dnl in this case. |
757 | + AC_CHECK_FUNC(bind_textdomain_codeset, |
758 | + [DATADIRNAME=share], [DATADIRNAME=lib]) |
759 | + ;; |
760 | + *) |
761 | + [DATADIRNAME=lib] |
762 | + ;; |
763 | + esac]) |
764 | +fi |
765 | +AC_SUBST(DATADIRNAME) |
766 | + |
767 | +IT_PO_SUBDIR([po]) |
768 | + |
769 | +]) |
770 | + |
771 | + |
772 | +# IT_PO_SUBDIR(DIRNAME) |
773 | +# --------------------- |
774 | +# All po subdirs have to be declared with this macro; the subdir "po" is |
775 | +# declared by IT_PROG_INTLTOOL. |
776 | +# |
777 | +AC_DEFUN([IT_PO_SUBDIR], |
778 | +[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS. |
779 | +dnl |
780 | +dnl The following CONFIG_COMMANDS should be executed at the very end |
781 | +dnl of config.status. |
782 | +AC_CONFIG_COMMANDS_PRE([ |
783 | + AC_CONFIG_COMMANDS([$1/stamp-it], [ |
784 | + if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then |
785 | + AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.]) |
786 | + fi |
787 | + rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp" |
788 | + >"$1/stamp-it.tmp" |
789 | + [sed '/^#/d |
790 | + s/^[[].*] *// |
791 | + /^[ ]*$/d |
792 | + '"s|^| $ac_top_srcdir/|" \ |
793 | + "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES" |
794 | + ] |
795 | + [sed '/^POTFILES =/,/[^\\]$/ { |
796 | + /^POTFILES =/!d |
797 | + r $1/POTFILES |
798 | + } |
799 | + ' "$1/Makefile.in" >"$1/Makefile"] |
800 | + rm -f "$1/Makefile.tmp" |
801 | + mv "$1/stamp-it.tmp" "$1/stamp-it" |
802 | + ]) |
803 | +])dnl |
804 | +]) |
805 | + |
806 | +# _IT_SUBST(VARIABLE) |
807 | +# ------------------- |
808 | +# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST |
809 | +# |
810 | +AC_DEFUN([_IT_SUBST], |
811 | +[ |
812 | +AC_SUBST([$1]) |
813 | +m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])]) |
814 | +] |
815 | +) |
816 | + |
817 | +# deprecated macros |
818 | +AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL]) |
819 | +# A hint is needed for aclocal from Automake <= 1.9.4: |
820 | +# AC_DEFUN([AC_PROG_INTLTOOL], ...) |
821 | + |
822 | + |
823 | +# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- |
824 | +# |
825 | +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, |
826 | +# 2006, 2007, 2008 Free Software Foundation, Inc. |
827 | +# Written by Gordon Matzigkeit, 1996 |
828 | +# |
829 | +# This file is free software; the Free Software Foundation gives |
830 | +# unlimited permission to copy and/or distribute it, with or without |
831 | +# modifications, as long as this notice is preserved. |
832 | + |
833 | +m4_define([_LT_COPYING], [dnl |
834 | +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, |
835 | +# 2006, 2007, 2008 Free Software Foundation, Inc. |
836 | +# Written by Gordon Matzigkeit, 1996 |
837 | +# |
838 | +# This file is part of GNU Libtool. |
839 | +# |
840 | +# GNU Libtool is free software; you can redistribute it and/or |
841 | +# modify it under the terms of the GNU General Public License as |
842 | +# published by the Free Software Foundation; either version 2 of |
843 | +# the License, or (at your option) any later version. |
844 | +# |
845 | +# As a special exception to the GNU General Public License, |
846 | +# if you distribute this file as part of a program or library that |
847 | +# is built using GNU Libtool, you may include this file under the |
848 | +# same distribution terms that you use for the rest of that program. |
849 | +# |
850 | +# GNU Libtool is distributed in the hope that it will be useful, |
851 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
852 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
853 | +# GNU General Public License for more details. |
854 | +# |
855 | +# You should have received a copy of the GNU General Public License |
856 | +# along with GNU Libtool; see the file COPYING. If not, a copy |
857 | +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or |
858 | +# obtained by writing to the Free Software Foundation, Inc., |
859 | +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
860 | +]) |
861 | + |
862 | +# serial 56 LT_INIT |
863 | + |
864 | + |
865 | +# LT_PREREQ(VERSION) |
866 | +# ------------------ |
867 | +# Complain and exit if this libtool version is less that VERSION. |
868 | +m4_defun([LT_PREREQ], |
869 | +[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, |
870 | + [m4_default([$3], |
871 | + [m4_fatal([Libtool version $1 or higher is required], |
872 | + 63)])], |
873 | + [$2])]) |
874 | + |
875 | + |
876 | +# _LT_CHECK_BUILDDIR |
877 | +# ------------------ |
878 | +# Complain if the absolute build directory name contains unusual characters |
879 | +m4_defun([_LT_CHECK_BUILDDIR], |
880 | +[case `pwd` in |
881 | + *\ * | *\ *) |
882 | + AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; |
883 | +esac |
884 | +]) |
885 | + |
886 | + |
887 | +# LT_INIT([OPTIONS]) |
888 | +# ------------------ |
889 | +AC_DEFUN([LT_INIT], |
890 | +[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT |
891 | +AC_BEFORE([$0], [LT_LANG])dnl |
892 | +AC_BEFORE([$0], [LT_OUTPUT])dnl |
893 | +AC_BEFORE([$0], [LTDL_INIT])dnl |
894 | +m4_require([_LT_CHECK_BUILDDIR])dnl |
895 | + |
896 | +dnl Autoconf doesn't catch unexpanded LT_ macros by default: |
897 | +m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl |
898 | +m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl |
899 | +dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 |
900 | +dnl unless we require an AC_DEFUNed macro: |
901 | +AC_REQUIRE([LTOPTIONS_VERSION])dnl |
902 | +AC_REQUIRE([LTSUGAR_VERSION])dnl |
903 | +AC_REQUIRE([LTVERSION_VERSION])dnl |
904 | +AC_REQUIRE([LTOBSOLETE_VERSION])dnl |
905 | +m4_require([_LT_PROG_LTMAIN])dnl |
906 | + |
907 | +dnl Parse OPTIONS |
908 | +_LT_SET_OPTIONS([$0], [$1]) |
909 | + |
910 | +# This can be used to rebuild libtool when needed |
911 | +LIBTOOL_DEPS="$ltmain" |
912 | + |
913 | +# Always use our own libtool. |
914 | +LIBTOOL='$(SHELL) $(top_builddir)/libtool' |
915 | +AC_SUBST(LIBTOOL)dnl |
916 | + |
917 | +_LT_SETUP |
918 | + |
919 | +# Only expand once: |
920 | +m4_define([LT_INIT]) |
921 | +])# LT_INIT |
922 | + |
923 | +# Old names: |
924 | +AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) |
925 | +AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) |
926 | +dnl aclocal-1.4 backwards compatibility: |
927 | +dnl AC_DEFUN([AC_PROG_LIBTOOL], []) |
928 | +dnl AC_DEFUN([AM_PROG_LIBTOOL], []) |
929 | + |
930 | + |
931 | +# _LT_CC_BASENAME(CC) |
932 | +# ------------------- |
933 | +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. |
934 | +m4_defun([_LT_CC_BASENAME], |
935 | +[for cc_temp in $1""; do |
936 | + case $cc_temp in |
937 | + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; |
938 | + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; |
939 | + \-*) ;; |
940 | + *) break;; |
941 | + esac |
942 | +done |
943 | +cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` |
944 | +]) |
945 | + |
946 | + |
947 | +# _LT_FILEUTILS_DEFAULTS |
948 | +# ---------------------- |
949 | +# It is okay to use these file commands and assume they have been set |
950 | +# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. |
951 | +m4_defun([_LT_FILEUTILS_DEFAULTS], |
952 | +[: ${CP="cp -f"} |
953 | +: ${MV="mv -f"} |
954 | +: ${RM="rm -f"} |
955 | +])# _LT_FILEUTILS_DEFAULTS |
956 | + |
957 | + |
958 | +# _LT_SETUP |
959 | +# --------- |
960 | +m4_defun([_LT_SETUP], |
961 | +[AC_REQUIRE([AC_CANONICAL_HOST])dnl |
962 | +AC_REQUIRE([AC_CANONICAL_BUILD])dnl |
963 | +_LT_DECL([], [host_alias], [0], [The host system])dnl |
964 | +_LT_DECL([], [host], [0])dnl |
965 | +_LT_DECL([], [host_os], [0])dnl |
966 | +dnl |
967 | +_LT_DECL([], [build_alias], [0], [The build system])dnl |
968 | +_LT_DECL([], [build], [0])dnl |
969 | +_LT_DECL([], [build_os], [0])dnl |
970 | +dnl |
971 | +AC_REQUIRE([AC_PROG_CC])dnl |
972 | +AC_REQUIRE([LT_PATH_LD])dnl |
973 | +AC_REQUIRE([LT_PATH_NM])dnl |
974 | +dnl |
975 | +AC_REQUIRE([AC_PROG_LN_S])dnl |
976 | +test -z "$LN_S" && LN_S="ln -s" |
977 | +_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl |
978 | +dnl |
979 | +AC_REQUIRE([LT_CMD_MAX_LEN])dnl |
980 | +_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl |
981 | +_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl |
982 | +dnl |
983 | +m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
984 | +m4_require([_LT_CHECK_SHELL_FEATURES])dnl |
985 | +m4_require([_LT_CMD_RELOAD])dnl |
986 | +m4_require([_LT_CHECK_MAGIC_METHOD])dnl |
987 | +m4_require([_LT_CMD_OLD_ARCHIVE])dnl |
988 | +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl |
989 | + |
990 | +_LT_CONFIG_LIBTOOL_INIT([ |
991 | +# See if we are running on zsh, and set the options which allow our |
992 | +# commands through without removal of \ escapes INIT. |
993 | +if test -n "\${ZSH_VERSION+set}" ; then |
994 | + setopt NO_GLOB_SUBST |
995 | +fi |
996 | +]) |
997 | +if test -n "${ZSH_VERSION+set}" ; then |
998 | + setopt NO_GLOB_SUBST |
999 | +fi |
1000 | + |
1001 | +_LT_CHECK_OBJDIR |
1002 | + |
1003 | +m4_require([_LT_TAG_COMPILER])dnl |
1004 | +_LT_PROG_ECHO_BACKSLASH |
1005 | + |
1006 | +case $host_os in |
1007 | +aix3*) |
1008 | + # AIX sometimes has problems with the GCC collect2 program. For some |
1009 | + # reason, if we set the COLLECT_NAMES environment variable, the problems |
1010 | + # vanish in a puff of smoke. |
1011 | + if test "X${COLLECT_NAMES+set}" != Xset; then |
1012 | + COLLECT_NAMES= |
1013 | + export COLLECT_NAMES |
1014 | + fi |
1015 | + ;; |
1016 | +esac |
1017 | + |
1018 | +# Sed substitution that helps us do robust quoting. It backslashifies |
1019 | +# metacharacters that are still active within double-quoted strings. |
1020 | +sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' |
1021 | + |
1022 | +# Same as above, but do not quote variable references. |
1023 | +double_quote_subst='s/\([["`\\]]\)/\\\1/g' |
1024 | + |
1025 | +# Sed substitution to delay expansion of an escaped shell variable in a |
1026 | +# double_quote_subst'ed string. |
1027 | +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' |
1028 | + |
1029 | +# Sed substitution to delay expansion of an escaped single quote. |
1030 | +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' |
1031 | + |
1032 | +# Sed substitution to avoid accidental globbing in evaled expressions |
1033 | +no_glob_subst='s/\*/\\\*/g' |
1034 | + |
1035 | +# Global variables: |
1036 | +ofile=libtool |
1037 | +can_build_shared=yes |
1038 | + |
1039 | +# All known linkers require a `.a' archive for static linking (except MSVC, |
1040 | +# which needs '.lib'). |
1041 | +libext=a |
1042 | + |
1043 | +with_gnu_ld="$lt_cv_prog_gnu_ld" |
1044 | + |
1045 | +old_CC="$CC" |
1046 | +old_CFLAGS="$CFLAGS" |
1047 | + |
1048 | +# Set sane defaults for various variables |
1049 | +test -z "$CC" && CC=cc |
1050 | +test -z "$LTCC" && LTCC=$CC |
1051 | +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS |
1052 | +test -z "$LD" && LD=ld |
1053 | +test -z "$ac_objext" && ac_objext=o |
1054 | + |
1055 | +_LT_CC_BASENAME([$compiler]) |
1056 | + |
1057 | +# Only perform the check for file, if the check method requires it |
1058 | +test -z "$MAGIC_CMD" && MAGIC_CMD=file |
1059 | +case $deplibs_check_method in |
1060 | +file_magic*) |
1061 | + if test "$file_magic_cmd" = '$MAGIC_CMD'; then |
1062 | + _LT_PATH_MAGIC |
1063 | + fi |
1064 | + ;; |
1065 | +esac |
1066 | + |
1067 | +# Use C for the default configuration in the libtool script |
1068 | +LT_SUPPORTED_TAG([CC]) |
1069 | +_LT_LANG_C_CONFIG |
1070 | +_LT_LANG_DEFAULT_CONFIG |
1071 | +_LT_CONFIG_COMMANDS |
1072 | +])# _LT_SETUP |
1073 | + |
1074 | + |
1075 | +# _LT_PROG_LTMAIN |
1076 | +# --------------- |
1077 | +# Note that this code is called both from `configure', and `config.status' |
1078 | +# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, |
1079 | +# `config.status' has no value for ac_aux_dir unless we are using Automake, |
1080 | +# so we pass a copy along to make sure it has a sensible value anyway. |
1081 | +m4_defun([_LT_PROG_LTMAIN], |
1082 | +[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl |
1083 | +_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) |
1084 | +ltmain="$ac_aux_dir/ltmain.sh" |
1085 | +])# _LT_PROG_LTMAIN |
1086 | + |
1087 | + |
1088 | + |
1089 | +# So that we can recreate a full libtool script including additional |
1090 | +# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS |
1091 | +# in macros and then make a single call at the end using the `libtool' |
1092 | +# label. |
1093 | + |
1094 | + |
1095 | +# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) |
1096 | +# ---------------------------------------- |
1097 | +# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. |
1098 | +m4_define([_LT_CONFIG_LIBTOOL_INIT], |
1099 | +[m4_ifval([$1], |
1100 | + [m4_append([_LT_OUTPUT_LIBTOOL_INIT], |
1101 | + [$1 |
1102 | +])])]) |
1103 | + |
1104 | +# Initialize. |
1105 | +m4_define([_LT_OUTPUT_LIBTOOL_INIT]) |
1106 | + |
1107 | + |
1108 | +# _LT_CONFIG_LIBTOOL([COMMANDS]) |
1109 | +# ------------------------------ |
1110 | +# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. |
1111 | +m4_define([_LT_CONFIG_LIBTOOL], |
1112 | +[m4_ifval([$1], |
1113 | + [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], |
1114 | + [$1 |
1115 | +])])]) |
1116 | + |
1117 | +# Initialize. |
1118 | +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) |
1119 | + |
1120 | + |
1121 | +# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) |
1122 | +# ----------------------------------------------------- |
1123 | +m4_defun([_LT_CONFIG_SAVE_COMMANDS], |
1124 | +[_LT_CONFIG_LIBTOOL([$1]) |
1125 | +_LT_CONFIG_LIBTOOL_INIT([$2]) |
1126 | +]) |
1127 | + |
1128 | + |
1129 | +# _LT_FORMAT_COMMENT([COMMENT]) |
1130 | +# ----------------------------- |
1131 | +# Add leading comment marks to the start of each line, and a trailing |
1132 | +# full-stop to the whole comment if one is not present already. |
1133 | +m4_define([_LT_FORMAT_COMMENT], |
1134 | +[m4_ifval([$1], [ |
1135 | +m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], |
1136 | + [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) |
1137 | +)]) |
1138 | + |
1139 | + |
1140 | + |
1141 | + |
1142 | + |
1143 | +# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) |
1144 | +# ------------------------------------------------------------------- |
1145 | +# CONFIGNAME is the name given to the value in the libtool script. |
1146 | +# VARNAME is the (base) name used in the configure script. |
1147 | +# VALUE may be 0, 1 or 2 for a computed quote escaped value based on |
1148 | +# VARNAME. Any other value will be used directly. |
1149 | +m4_define([_LT_DECL], |
1150 | +[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], |
1151 | + [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], |
1152 | + [m4_ifval([$1], [$1], [$2])]) |
1153 | + lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) |
1154 | + m4_ifval([$4], |
1155 | + [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) |
1156 | + lt_dict_add_subkey([lt_decl_dict], [$2], |
1157 | + [tagged?], [m4_ifval([$5], [yes], [no])])]) |
1158 | +]) |
1159 | + |
1160 | + |
1161 | +# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) |
1162 | +# -------------------------------------------------------- |
1163 | +m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) |
1164 | + |
1165 | + |
1166 | +# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) |
1167 | +# ------------------------------------------------ |
1168 | +m4_define([lt_decl_tag_varnames], |
1169 | +[_lt_decl_filter([tagged?], [yes], $@)]) |
1170 | + |
1171 | + |
1172 | +# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) |
1173 | +# --------------------------------------------------------- |
1174 | +m4_define([_lt_decl_filter], |
1175 | +[m4_case([$#], |
1176 | + [0], [m4_fatal([$0: too few arguments: $#])], |
1177 | + [1], [m4_fatal([$0: too few arguments: $#: $1])], |
1178 | + [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], |
1179 | + [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], |
1180 | + [lt_dict_filter([lt_decl_dict], $@)])[]dnl |
1181 | +]) |
1182 | + |
1183 | + |
1184 | +# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) |
1185 | +# -------------------------------------------------- |
1186 | +m4_define([lt_decl_quote_varnames], |
1187 | +[_lt_decl_filter([value], [1], $@)]) |
1188 | + |
1189 | + |
1190 | +# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) |
1191 | +# --------------------------------------------------- |
1192 | +m4_define([lt_decl_dquote_varnames], |
1193 | +[_lt_decl_filter([value], [2], $@)]) |
1194 | + |
1195 | + |
1196 | +# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) |
1197 | +# --------------------------------------------------- |
1198 | +m4_define([lt_decl_varnames_tagged], |
1199 | +[m4_assert([$# <= 2])dnl |
1200 | +_$0(m4_quote(m4_default([$1], [[, ]])), |
1201 | + m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), |
1202 | + m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) |
1203 | +m4_define([_lt_decl_varnames_tagged], |
1204 | +[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) |
1205 | + |
1206 | + |
1207 | +# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) |
1208 | +# ------------------------------------------------ |
1209 | +m4_define([lt_decl_all_varnames], |
1210 | +[_$0(m4_quote(m4_default([$1], [[, ]])), |
1211 | + m4_if([$2], [], |
1212 | + m4_quote(lt_decl_varnames), |
1213 | + m4_quote(m4_shift($@))))[]dnl |
1214 | +]) |
1215 | +m4_define([_lt_decl_all_varnames], |
1216 | +[lt_join($@, lt_decl_varnames_tagged([$1], |
1217 | + lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl |
1218 | +]) |
1219 | + |
1220 | + |
1221 | +# _LT_CONFIG_STATUS_DECLARE([VARNAME]) |
1222 | +# ------------------------------------ |
1223 | +# Quote a variable value, and forward it to `config.status' so that its |
1224 | +# declaration there will have the same value as in `configure'. VARNAME |
1225 | +# must have a single quote delimited value for this to work. |
1226 | +m4_define([_LT_CONFIG_STATUS_DECLARE], |
1227 | +[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`']) |
1228 | + |
1229 | + |
1230 | +# _LT_CONFIG_STATUS_DECLARATIONS |
1231 | +# ------------------------------ |
1232 | +# We delimit libtool config variables with single quotes, so when |
1233 | +# we write them to config.status, we have to be sure to quote all |
1234 | +# embedded single quotes properly. In configure, this macro expands |
1235 | +# each variable declared with _LT_DECL (and _LT_TAGDECL) into: |
1236 | +# |
1237 | +# <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`' |
1238 | +m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], |
1239 | +[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), |
1240 | + [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) |
1241 | + |
1242 | + |
1243 | +# _LT_LIBTOOL_TAGS |
1244 | +# ---------------- |
1245 | +# Output comment and list of tags supported by the script |
1246 | +m4_defun([_LT_LIBTOOL_TAGS], |
1247 | +[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl |
1248 | +available_tags="_LT_TAGS"dnl |
1249 | +]) |
1250 | + |
1251 | + |
1252 | +# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) |
1253 | +# ----------------------------------- |
1254 | +# Extract the dictionary values for VARNAME (optionally with TAG) and |
1255 | +# expand to a commented shell variable setting: |
1256 | +# |
1257 | +# # Some comment about what VAR is for. |
1258 | +# visible_name=$lt_internal_name |
1259 | +m4_define([_LT_LIBTOOL_DECLARE], |
1260 | +[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], |
1261 | + [description])))[]dnl |
1262 | +m4_pushdef([_libtool_name], |
1263 | + m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl |
1264 | +m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), |
1265 | + [0], [_libtool_name=[$]$1], |
1266 | + [1], [_libtool_name=$lt_[]$1], |
1267 | + [2], [_libtool_name=$lt_[]$1], |
1268 | + [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl |
1269 | +m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl |
1270 | +]) |
1271 | + |
1272 | + |
1273 | +# _LT_LIBTOOL_CONFIG_VARS |
1274 | +# ----------------------- |
1275 | +# Produce commented declarations of non-tagged libtool config variables |
1276 | +# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' |
1277 | +# script. Tagged libtool config variables (even for the LIBTOOL CONFIG |
1278 | +# section) are produced by _LT_LIBTOOL_TAG_VARS. |
1279 | +m4_defun([_LT_LIBTOOL_CONFIG_VARS], |
1280 | +[m4_foreach([_lt_var], |
1281 | + m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), |
1282 | + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) |
1283 | + |
1284 | + |
1285 | +# _LT_LIBTOOL_TAG_VARS(TAG) |
1286 | +# ------------------------- |
1287 | +m4_define([_LT_LIBTOOL_TAG_VARS], |
1288 | +[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), |
1289 | + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) |
1290 | + |
1291 | + |
1292 | +# _LT_TAGVAR(VARNAME, [TAGNAME]) |
1293 | +# ------------------------------ |
1294 | +m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) |
1295 | + |
1296 | + |
1297 | +# _LT_CONFIG_COMMANDS |
1298 | +# ------------------- |
1299 | +# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of |
1300 | +# variables for single and double quote escaping we saved from calls |
1301 | +# to _LT_DECL, we can put quote escaped variables declarations |
1302 | +# into `config.status', and then the shell code to quote escape them in |
1303 | +# for loops in `config.status'. Finally, any additional code accumulated |
1304 | +# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. |
1305 | +m4_defun([_LT_CONFIG_COMMANDS], |
1306 | +[AC_PROVIDE_IFELSE([LT_OUTPUT], |
1307 | + dnl If the libtool generation code has been placed in $CONFIG_LT, |
1308 | + dnl instead of duplicating it all over again into config.status, |
1309 | + dnl then we will have config.status run $CONFIG_LT later, so it |
1310 | + dnl needs to know what name is stored there: |
1311 | + [AC_CONFIG_COMMANDS([libtool], |
1312 | + [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], |
1313 | + dnl If the libtool generation code is destined for config.status, |
1314 | + dnl expand the accumulated commands and init code now: |
1315 | + [AC_CONFIG_COMMANDS([libtool], |
1316 | + [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) |
1317 | +])#_LT_CONFIG_COMMANDS |
1318 | + |
1319 | + |
1320 | +# Initialize. |
1321 | +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], |
1322 | +[ |
1323 | + |
1324 | +# The HP-UX ksh and POSIX shell print the target directory to stdout |
1325 | +# if CDPATH is set. |
1326 | +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
1327 | + |
1328 | +sed_quote_subst='$sed_quote_subst' |
1329 | +double_quote_subst='$double_quote_subst' |
1330 | +delay_variable_subst='$delay_variable_subst' |
1331 | +_LT_CONFIG_STATUS_DECLARATIONS |
1332 | +LTCC='$LTCC' |
1333 | +LTCFLAGS='$LTCFLAGS' |
1334 | +compiler='$compiler_DEFAULT' |
1335 | + |
1336 | +# Quote evaled strings. |
1337 | +for var in lt_decl_all_varnames([[ \ |
1338 | +]], lt_decl_quote_varnames); do |
1339 | + case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in |
1340 | + *[[\\\\\\\`\\"\\\$]]*) |
1341 | + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" |
1342 | + ;; |
1343 | + *) |
1344 | + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" |
1345 | + ;; |
1346 | + esac |
1347 | +done |
1348 | + |
1349 | +# Double-quote double-evaled strings. |
1350 | +for var in lt_decl_all_varnames([[ \ |
1351 | +]], lt_decl_dquote_varnames); do |
1352 | + case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in |
1353 | + *[[\\\\\\\`\\"\\\$]]*) |
1354 | + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" |
1355 | + ;; |
1356 | + *) |
1357 | + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" |
1358 | + ;; |
1359 | + esac |
1360 | +done |
1361 | + |
1362 | +# Fix-up fallback echo if it was mangled by the above quoting rules. |
1363 | +case \$lt_ECHO in |
1364 | +*'\\\[$]0 --fallback-echo"')dnl " |
1365 | + lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\` |
1366 | + ;; |
1367 | +esac |
1368 | + |
1369 | +_LT_OUTPUT_LIBTOOL_INIT |
1370 | +]) |
1371 | + |
1372 | + |
1373 | +# LT_OUTPUT |
1374 | +# --------- |
1375 | +# This macro allows early generation of the libtool script (before |
1376 | +# AC_OUTPUT is called), incase it is used in configure for compilation |
1377 | +# tests. |
1378 | +AC_DEFUN([LT_OUTPUT], |
1379 | +[: ${CONFIG_LT=./config.lt} |
1380 | +AC_MSG_NOTICE([creating $CONFIG_LT]) |
1381 | +cat >"$CONFIG_LT" <<_LTEOF |
1382 | +#! $SHELL |
1383 | +# Generated by $as_me. |
1384 | +# Run this file to recreate a libtool stub with the current configuration. |
1385 | + |
1386 | +lt_cl_silent=false |
1387 | +SHELL=\${CONFIG_SHELL-$SHELL} |
1388 | +_LTEOF |
1389 | + |
1390 | +cat >>"$CONFIG_LT" <<\_LTEOF |
1391 | +AS_SHELL_SANITIZE |
1392 | +_AS_PREPARE |
1393 | + |
1394 | +exec AS_MESSAGE_FD>&1 |
1395 | +exec AS_MESSAGE_LOG_FD>>config.log |
1396 | +{ |
1397 | + echo |
1398 | + AS_BOX([Running $as_me.]) |
1399 | +} >&AS_MESSAGE_LOG_FD |
1400 | + |
1401 | +lt_cl_help="\ |
1402 | +\`$as_me' creates a local libtool stub from the current configuration, |
1403 | +for use in further configure time tests before the real libtool is |
1404 | +generated. |
1405 | + |
1406 | +Usage: $[0] [[OPTIONS]] |
1407 | + |
1408 | + -h, --help print this help, then exit |
1409 | + -V, --version print version number, then exit |
1410 | + -q, --quiet do not print progress messages |
1411 | + -d, --debug don't remove temporary files |
1412 | + |
1413 | +Report bugs to <bug-libtool@gnu.org>." |
1414 | + |
1415 | +lt_cl_version="\ |
1416 | +m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl |
1417 | +m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) |
1418 | +configured by $[0], generated by m4_PACKAGE_STRING. |
1419 | + |
1420 | +Copyright (C) 2008 Free Software Foundation, Inc. |
1421 | +This config.lt script is free software; the Free Software Foundation |
1422 | +gives unlimited permision to copy, distribute and modify it." |
1423 | + |
1424 | +while test $[#] != 0 |
1425 | +do |
1426 | + case $[1] in |
1427 | + --version | --v* | -V ) |
1428 | + echo "$lt_cl_version"; exit 0 ;; |
1429 | + --help | --h* | -h ) |
1430 | + echo "$lt_cl_help"; exit 0 ;; |
1431 | + --debug | --d* | -d ) |
1432 | + debug=: ;; |
1433 | + --quiet | --q* | --silent | --s* | -q ) |
1434 | + lt_cl_silent=: ;; |
1435 | + |
1436 | + -*) AC_MSG_ERROR([unrecognized option: $[1] |
1437 | +Try \`$[0] --help' for more information.]) ;; |
1438 | + |
1439 | + *) AC_MSG_ERROR([unrecognized argument: $[1] |
1440 | +Try \`$[0] --help' for more information.]) ;; |
1441 | + esac |
1442 | + shift |
1443 | +done |
1444 | + |
1445 | +if $lt_cl_silent; then |
1446 | + exec AS_MESSAGE_FD>/dev/null |
1447 | +fi |
1448 | +_LTEOF |
1449 | + |
1450 | +cat >>"$CONFIG_LT" <<_LTEOF |
1451 | +_LT_OUTPUT_LIBTOOL_COMMANDS_INIT |
1452 | +_LTEOF |
1453 | + |
1454 | +cat >>"$CONFIG_LT" <<\_LTEOF |
1455 | +AC_MSG_NOTICE([creating $ofile]) |
1456 | +_LT_OUTPUT_LIBTOOL_COMMANDS |
1457 | +AS_EXIT(0) |
1458 | +_LTEOF |
1459 | +chmod +x "$CONFIG_LT" |
1460 | + |
1461 | +# configure is writing to config.log, but config.lt does its own redirection, |
1462 | +# appending to config.log, which fails on DOS, as config.log is still kept |
1463 | +# open by configure. Here we exec the FD to /dev/null, effectively closing |
1464 | +# config.log, so it can be properly (re)opened and appended to by config.lt. |
1465 | +if test "$no_create" != yes; then |
1466 | + lt_cl_success=: |
1467 | + test "$silent" = yes && |
1468 | + lt_config_lt_args="$lt_config_lt_args --quiet" |
1469 | + exec AS_MESSAGE_LOG_FD>/dev/null |
1470 | + $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false |
1471 | + exec AS_MESSAGE_LOG_FD>>config.log |
1472 | + $lt_cl_success || AS_EXIT(1) |
1473 | +fi |
1474 | +])# LT_OUTPUT |
1475 | + |
1476 | + |
1477 | +# _LT_CONFIG(TAG) |
1478 | +# --------------- |
1479 | +# If TAG is the built-in tag, create an initial libtool script with a |
1480 | +# default configuration from the untagged config vars. Otherwise add code |
1481 | +# to config.status for appending the configuration named by TAG from the |
1482 | +# matching tagged config vars. |
1483 | +m4_defun([_LT_CONFIG], |
1484 | +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
1485 | +_LT_CONFIG_SAVE_COMMANDS([ |
1486 | + m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl |
1487 | + m4_if(_LT_TAG, [C], [ |
1488 | + # See if we are running on zsh, and set the options which allow our |
1489 | + # commands through without removal of \ escapes. |
1490 | + if test -n "${ZSH_VERSION+set}" ; then |
1491 | + setopt NO_GLOB_SUBST |
1492 | + fi |
1493 | + |
1494 | + cfgfile="${ofile}T" |
1495 | + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 |
1496 | + $RM "$cfgfile" |
1497 | + |
1498 | + cat <<_LT_EOF >> "$cfgfile" |
1499 | +#! $SHELL |
1500 | + |
1501 | +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. |
1502 | +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION |
1503 | +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
1504 | +# NOTE: Changes made to this file will be lost: look at ltmain.sh. |
1505 | +# |
1506 | +_LT_COPYING |
1507 | +_LT_LIBTOOL_TAGS |
1508 | + |
1509 | +# ### BEGIN LIBTOOL CONFIG |
1510 | +_LT_LIBTOOL_CONFIG_VARS |
1511 | +_LT_LIBTOOL_TAG_VARS |
1512 | +# ### END LIBTOOL CONFIG |
1513 | + |
1514 | +_LT_EOF |
1515 | + |
1516 | + case $host_os in |
1517 | + aix3*) |
1518 | + cat <<\_LT_EOF >> "$cfgfile" |
1519 | +# AIX sometimes has problems with the GCC collect2 program. For some |
1520 | +# reason, if we set the COLLECT_NAMES environment variable, the problems |
1521 | +# vanish in a puff of smoke. |
1522 | +if test "X${COLLECT_NAMES+set}" != Xset; then |
1523 | + COLLECT_NAMES= |
1524 | + export COLLECT_NAMES |
1525 | +fi |
1526 | +_LT_EOF |
1527 | + ;; |
1528 | + esac |
1529 | + |
1530 | + _LT_PROG_LTMAIN |
1531 | + |
1532 | + # We use sed instead of cat because bash on DJGPP gets confused if |
1533 | + # if finds mixed CR/LF and LF-only lines. Since sed operates in |
1534 | + # text mode, it properly converts lines to CR/LF. This bash problem |
1535 | + # is reportedly fixed, but why not run on old versions too? |
1536 | + sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ |
1537 | + || (rm -f "$cfgfile"; exit 1) |
1538 | + |
1539 | + _LT_PROG_XSI_SHELLFNS |
1540 | + |
1541 | + sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ |
1542 | + || (rm -f "$cfgfile"; exit 1) |
1543 | + |
1544 | + mv -f "$cfgfile" "$ofile" || |
1545 | + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") |
1546 | + chmod +x "$ofile" |
1547 | +], |
1548 | +[cat <<_LT_EOF >> "$ofile" |
1549 | + |
1550 | +dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded |
1551 | +dnl in a comment (ie after a #). |
1552 | +# ### BEGIN LIBTOOL TAG CONFIG: $1 |
1553 | +_LT_LIBTOOL_TAG_VARS(_LT_TAG) |
1554 | +# ### END LIBTOOL TAG CONFIG: $1 |
1555 | +_LT_EOF |
1556 | +])dnl /m4_if |
1557 | +], |
1558 | +[m4_if([$1], [], [ |
1559 | + PACKAGE='$PACKAGE' |
1560 | + VERSION='$VERSION' |
1561 | + TIMESTAMP='$TIMESTAMP' |
1562 | + RM='$RM' |
1563 | + ofile='$ofile'], []) |
1564 | +])dnl /_LT_CONFIG_SAVE_COMMANDS |
1565 | +])# _LT_CONFIG |
1566 | + |
1567 | + |
1568 | +# LT_SUPPORTED_TAG(TAG) |
1569 | +# --------------------- |
1570 | +# Trace this macro to discover what tags are supported by the libtool |
1571 | +# --tag option, using: |
1572 | +# autoconf --trace 'LT_SUPPORTED_TAG:$1' |
1573 | +AC_DEFUN([LT_SUPPORTED_TAG], []) |
1574 | + |
1575 | + |
1576 | +# C support is built-in for now |
1577 | +m4_define([_LT_LANG_C_enabled], []) |
1578 | +m4_define([_LT_TAGS], []) |
1579 | + |
1580 | + |
1581 | +# LT_LANG(LANG) |
1582 | +# ------------- |
1583 | +# Enable libtool support for the given language if not already enabled. |
1584 | +AC_DEFUN([LT_LANG], |
1585 | +[AC_BEFORE([$0], [LT_OUTPUT])dnl |
1586 | +m4_case([$1], |
1587 | + [C], [_LT_LANG(C)], |
1588 | + [C++], [_LT_LANG(CXX)], |
1589 | + [Java], [_LT_LANG(GCJ)], |
1590 | + [Fortran 77], [_LT_LANG(F77)], |
1591 | + [Fortran], [_LT_LANG(FC)], |
1592 | + [Windows Resource], [_LT_LANG(RC)], |
1593 | + [m4_ifdef([_LT_LANG_]$1[_CONFIG], |
1594 | + [_LT_LANG($1)], |
1595 | + [m4_fatal([$0: unsupported language: "$1"])])])dnl |
1596 | +])# LT_LANG |
1597 | + |
1598 | + |
1599 | +# _LT_LANG(LANGNAME) |
1600 | +# ------------------ |
1601 | +m4_defun([_LT_LANG], |
1602 | +[m4_ifdef([_LT_LANG_]$1[_enabled], [], |
1603 | + [LT_SUPPORTED_TAG([$1])dnl |
1604 | + m4_append([_LT_TAGS], [$1 ])dnl |
1605 | + m4_define([_LT_LANG_]$1[_enabled], [])dnl |
1606 | + _LT_LANG_$1_CONFIG($1)])dnl |
1607 | +])# _LT_LANG |
1608 | + |
1609 | + |
1610 | +# _LT_LANG_DEFAULT_CONFIG |
1611 | +# ----------------------- |
1612 | +m4_defun([_LT_LANG_DEFAULT_CONFIG], |
1613 | +[AC_PROVIDE_IFELSE([AC_PROG_CXX], |
1614 | + [LT_LANG(CXX)], |
1615 | + [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) |
1616 | + |
1617 | +AC_PROVIDE_IFELSE([AC_PROG_F77], |
1618 | + [LT_LANG(F77)], |
1619 | + [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) |
1620 | + |
1621 | +AC_PROVIDE_IFELSE([AC_PROG_FC], |
1622 | + [LT_LANG(FC)], |
1623 | + [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) |
1624 | + |
1625 | +dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal |
1626 | +dnl pulling things in needlessly. |
1627 | +AC_PROVIDE_IFELSE([AC_PROG_GCJ], |
1628 | + [LT_LANG(GCJ)], |
1629 | + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], |
1630 | + [LT_LANG(GCJ)], |
1631 | + [AC_PROVIDE_IFELSE([LT_PROG_GCJ], |
1632 | + [LT_LANG(GCJ)], |
1633 | + [m4_ifdef([AC_PROG_GCJ], |
1634 | + [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) |
1635 | + m4_ifdef([A][M_PROG_GCJ], |
1636 | + [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) |
1637 | + m4_ifdef([LT_PROG_GCJ], |
1638 | + [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) |
1639 | + |
1640 | +AC_PROVIDE_IFELSE([LT_PROG_RC], |
1641 | + [LT_LANG(RC)], |
1642 | + [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) |
1643 | +])# _LT_LANG_DEFAULT_CONFIG |
1644 | + |
1645 | +# Obsolete macros: |
1646 | +AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) |
1647 | +AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) |
1648 | +AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) |
1649 | +AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) |
1650 | +dnl aclocal-1.4 backwards compatibility: |
1651 | +dnl AC_DEFUN([AC_LIBTOOL_CXX], []) |
1652 | +dnl AC_DEFUN([AC_LIBTOOL_F77], []) |
1653 | +dnl AC_DEFUN([AC_LIBTOOL_FC], []) |
1654 | +dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) |
1655 | + |
1656 | + |
1657 | +# _LT_TAG_COMPILER |
1658 | +# ---------------- |
1659 | +m4_defun([_LT_TAG_COMPILER], |
1660 | +[AC_REQUIRE([AC_PROG_CC])dnl |
1661 | + |
1662 | +_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl |
1663 | +_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl |
1664 | +_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl |
1665 | +_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl |
1666 | + |
1667 | +# If no C compiler was specified, use CC. |
1668 | +LTCC=${LTCC-"$CC"} |
1669 | + |
1670 | +# If no C compiler flags were specified, use CFLAGS. |
1671 | +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} |
1672 | + |
1673 | +# Allow CC to be a program name with arguments. |
1674 | +compiler=$CC |
1675 | +])# _LT_TAG_COMPILER |
1676 | + |
1677 | + |
1678 | +# _LT_COMPILER_BOILERPLATE |
1679 | +# ------------------------ |
1680 | +# Check for compiler boilerplate output or warnings with |
1681 | +# the simple compiler test code. |
1682 | +m4_defun([_LT_COMPILER_BOILERPLATE], |
1683 | +[m4_require([_LT_DECL_SED])dnl |
1684 | +ac_outfile=conftest.$ac_objext |
1685 | +echo "$lt_simple_compile_test_code" >conftest.$ac_ext |
1686 | +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err |
1687 | +_lt_compiler_boilerplate=`cat conftest.err` |
1688 | +$RM conftest* |
1689 | +])# _LT_COMPILER_BOILERPLATE |
1690 | + |
1691 | + |
1692 | +# _LT_LINKER_BOILERPLATE |
1693 | +# ---------------------- |
1694 | +# Check for linker boilerplate output or warnings with |
1695 | +# the simple link test code. |
1696 | +m4_defun([_LT_LINKER_BOILERPLATE], |
1697 | +[m4_require([_LT_DECL_SED])dnl |
1698 | +ac_outfile=conftest.$ac_objext |
1699 | +echo "$lt_simple_link_test_code" >conftest.$ac_ext |
1700 | +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err |
1701 | +_lt_linker_boilerplate=`cat conftest.err` |
1702 | +$RM -r conftest* |
1703 | +])# _LT_LINKER_BOILERPLATE |
1704 | + |
1705 | +# _LT_REQUIRED_DARWIN_CHECKS |
1706 | +# ------------------------- |
1707 | +m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ |
1708 | + case $host_os in |
1709 | + rhapsody* | darwin*) |
1710 | + AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) |
1711 | + AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) |
1712 | + AC_CHECK_TOOL([LIPO], [lipo], [:]) |
1713 | + AC_CHECK_TOOL([OTOOL], [otool], [:]) |
1714 | + AC_CHECK_TOOL([OTOOL64], [otool64], [:]) |
1715 | + _LT_DECL([], [DSYMUTIL], [1], |
1716 | + [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) |
1717 | + _LT_DECL([], [NMEDIT], [1], |
1718 | + [Tool to change global to local symbols on Mac OS X]) |
1719 | + _LT_DECL([], [LIPO], [1], |
1720 | + [Tool to manipulate fat objects and archives on Mac OS X]) |
1721 | + _LT_DECL([], [OTOOL], [1], |
1722 | + [ldd/readelf like tool for Mach-O binaries on Mac OS X]) |
1723 | + _LT_DECL([], [OTOOL64], [1], |
1724 | + [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) |
1725 | + |
1726 | + AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], |
1727 | + [lt_cv_apple_cc_single_mod=no |
1728 | + if test -z "${LT_MULTI_MODULE}"; then |
1729 | + # By default we will add the -single_module flag. You can override |
1730 | + # by either setting the environment variable LT_MULTI_MODULE |
1731 | + # non-empty at configure time, or by adding -multi_module to the |
1732 | + # link flags. |
1733 | + rm -rf libconftest.dylib* |
1734 | + echo "int foo(void){return 1;}" > conftest.c |
1735 | + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ |
1736 | +-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD |
1737 | + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ |
1738 | + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err |
1739 | + _lt_result=$? |
1740 | + if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then |
1741 | + lt_cv_apple_cc_single_mod=yes |
1742 | + else |
1743 | + cat conftest.err >&AS_MESSAGE_LOG_FD |
1744 | + fi |
1745 | + rm -rf libconftest.dylib* |
1746 | + rm -f conftest.* |
1747 | + fi]) |
1748 | + AC_CACHE_CHECK([for -exported_symbols_list linker flag], |
1749 | + [lt_cv_ld_exported_symbols_list], |
1750 | + [lt_cv_ld_exported_symbols_list=no |
1751 | + save_LDFLAGS=$LDFLAGS |
1752 | + echo "_main" > conftest.sym |
1753 | + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" |
1754 | + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], |
1755 | + [lt_cv_ld_exported_symbols_list=yes], |
1756 | + [lt_cv_ld_exported_symbols_list=no]) |
1757 | + LDFLAGS="$save_LDFLAGS" |
1758 | + ]) |
1759 | + case $host_os in |
1760 | + rhapsody* | darwin1.[[012]]) |
1761 | + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; |
1762 | + darwin1.*) |
1763 | + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; |
1764 | + darwin*) # darwin 5.x on |
1765 | + # if running on 10.5 or later, the deployment target defaults |
1766 | + # to the OS version, if on x86, and 10.4, the deployment |
1767 | + # target defaults to 10.4. Don't you love it? |
1768 | + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in |
1769 | + 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) |
1770 | + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; |
1771 | + 10.[[012]]*) |
1772 | + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; |
1773 | + 10.*) |
1774 | + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; |
1775 | + esac |
1776 | + ;; |
1777 | + esac |
1778 | + if test "$lt_cv_apple_cc_single_mod" = "yes"; then |
1779 | + _lt_dar_single_mod='$single_module' |
1780 | + fi |
1781 | + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then |
1782 | + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' |
1783 | + else |
1784 | + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' |
1785 | + fi |
1786 | + if test "$DSYMUTIL" != ":"; then |
1787 | + _lt_dsymutil='~$DSYMUTIL $lib || :' |
1788 | + else |
1789 | + _lt_dsymutil= |
1790 | + fi |
1791 | + ;; |
1792 | + esac |
1793 | +]) |
1794 | + |
1795 | + |
1796 | +# _LT_DARWIN_LINKER_FEATURES |
1797 | +# -------------------------- |
1798 | +# Checks for linker and compiler features on darwin |
1799 | +m4_defun([_LT_DARWIN_LINKER_FEATURES], |
1800 | +[ |
1801 | + m4_require([_LT_REQUIRED_DARWIN_CHECKS]) |
1802 | + _LT_TAGVAR(archive_cmds_need_lc, $1)=no |
1803 | + _LT_TAGVAR(hardcode_direct, $1)=no |
1804 | + _LT_TAGVAR(hardcode_automatic, $1)=yes |
1805 | + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported |
1806 | + _LT_TAGVAR(whole_archive_flag_spec, $1)='' |
1807 | + _LT_TAGVAR(link_all_deplibs, $1)=yes |
1808 | + _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" |
1809 | + case $cc_basename in |
1810 | + ifort*) _lt_dar_can_shared=yes ;; |
1811 | + *) _lt_dar_can_shared=$GCC ;; |
1812 | + esac |
1813 | + if test "$_lt_dar_can_shared" = "yes"; then |
1814 | + output_verbose_link_cmd=echo |
1815 | + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" |
1816 | + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" |
1817 | + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" |
1818 | + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" |
1819 | + m4_if([$1], [CXX], |
1820 | +[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then |
1821 | + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" |
1822 | + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" |
1823 | + fi |
1824 | +],[]) |
1825 | + else |
1826 | + _LT_TAGVAR(ld_shlibs, $1)=no |
1827 | + fi |
1828 | +]) |
1829 | + |
1830 | +# _LT_SYS_MODULE_PATH_AIX |
1831 | +# ----------------------- |
1832 | +# Links a minimal program and checks the executable |
1833 | +# for the system default hardcoded library path. In most cases, |
1834 | +# this is /usr/lib:/lib, but when the MPI compilers are used |
1835 | +# the location of the communication and MPI libs are included too. |
1836 | +# If we don't find anything, use the default library path according |
1837 | +# to the aix ld manual. |
1838 | +m4_defun([_LT_SYS_MODULE_PATH_AIX], |
1839 | +[m4_require([_LT_DECL_SED])dnl |
1840 | +AC_LINK_IFELSE(AC_LANG_PROGRAM,[ |
1841 | +lt_aix_libpath_sed=' |
1842 | + /Import File Strings/,/^$/ { |
1843 | + /^0/ { |
1844 | + s/^0 *\(.*\)$/\1/ |
1845 | + p |
1846 | + } |
1847 | + }' |
1848 | +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` |
1849 | +# Check for a 64-bit object if we didn't find anything. |
1850 | +if test -z "$aix_libpath"; then |
1851 | + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` |
1852 | +fi],[]) |
1853 | +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi |
1854 | +])# _LT_SYS_MODULE_PATH_AIX |
1855 | + |
1856 | + |
1857 | +# _LT_SHELL_INIT(ARG) |
1858 | +# ------------------- |
1859 | +m4_define([_LT_SHELL_INIT], |
1860 | +[ifdef([AC_DIVERSION_NOTICE], |
1861 | + [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], |
1862 | + [AC_DIVERT_PUSH(NOTICE)]) |
1863 | +$1 |
1864 | +AC_DIVERT_POP |
1865 | +])# _LT_SHELL_INIT |
1866 | + |
1867 | + |
1868 | +# _LT_PROG_ECHO_BACKSLASH |
1869 | +# ----------------------- |
1870 | +# Add some code to the start of the generated configure script which |
1871 | +# will find an echo command which doesn't interpret backslashes. |
1872 | +m4_defun([_LT_PROG_ECHO_BACKSLASH], |
1873 | +[_LT_SHELL_INIT([ |
1874 | +# Check that we are running under the correct shell. |
1875 | +SHELL=${CONFIG_SHELL-/bin/sh} |
1876 | + |
1877 | +case X$lt_ECHO in |
1878 | +X*--fallback-echo) |
1879 | + # Remove one level of quotation (which was required for Make). |
1880 | + ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` |
1881 | + ;; |
1882 | +esac |
1883 | + |
1884 | +ECHO=${lt_ECHO-echo} |
1885 | +if test "X[$]1" = X--no-reexec; then |
1886 | + # Discard the --no-reexec flag, and continue. |
1887 | + shift |
1888 | +elif test "X[$]1" = X--fallback-echo; then |
1889 | + # Avoid inline document here, it may be left over |
1890 | + : |
1891 | +elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then |
1892 | + # Yippee, $ECHO works! |
1893 | + : |
1894 | +else |
1895 | + # Restart under the correct shell. |
1896 | + exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} |
1897 | +fi |
1898 | + |
1899 | +if test "X[$]1" = X--fallback-echo; then |
1900 | + # used as fallback echo |
1901 | + shift |
1902 | + cat <<_LT_EOF |
1903 | +[$]* |
1904 | +_LT_EOF |
1905 | + exit 0 |
1906 | +fi |
1907 | + |
1908 | +# The HP-UX ksh and POSIX shell print the target directory to stdout |
1909 | +# if CDPATH is set. |
1910 | +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
1911 | + |
1912 | +if test -z "$lt_ECHO"; then |
1913 | + if test "X${echo_test_string+set}" != Xset; then |
1914 | + # find a string as large as possible, as long as the shell can cope with it |
1915 | + for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do |
1916 | + # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... |
1917 | + if { echo_test_string=`eval $cmd`; } 2>/dev/null && |
1918 | + { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null |
1919 | + then |
1920 | + break |
1921 | + fi |
1922 | + done |
1923 | + fi |
1924 | + |
1925 | + if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && |
1926 | + echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && |
1927 | + test "X$echo_testing_string" = "X$echo_test_string"; then |
1928 | + : |
1929 | + else |
1930 | + # The Solaris, AIX, and Digital Unix default echo programs unquote |
1931 | + # backslashes. This makes it impossible to quote backslashes using |
1932 | + # echo "$something" | sed 's/\\/\\\\/g' |
1933 | + # |
1934 | + # So, first we look for a working echo in the user's PATH. |
1935 | + |
1936 | + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR |
1937 | + for dir in $PATH /usr/ucb; do |
1938 | + IFS="$lt_save_ifs" |
1939 | + if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && |
1940 | + test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && |
1941 | + echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && |
1942 | + test "X$echo_testing_string" = "X$echo_test_string"; then |
1943 | + ECHO="$dir/echo" |
1944 | + break |
1945 | + fi |
1946 | + done |
1947 | + IFS="$lt_save_ifs" |
1948 | + |
1949 | + if test "X$ECHO" = Xecho; then |
1950 | + # We didn't find a better echo, so look for alternatives. |
1951 | + if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' && |
1952 | + echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` && |
1953 | + test "X$echo_testing_string" = "X$echo_test_string"; then |
1954 | + # This shell has a builtin print -r that does the trick. |
1955 | + ECHO='print -r' |
1956 | + elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } && |
1957 | + test "X$CONFIG_SHELL" != X/bin/ksh; then |
1958 | + # If we have ksh, try running configure again with it. |
1959 | + ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} |
1960 | + export ORIGINAL_CONFIG_SHELL |
1961 | + CONFIG_SHELL=/bin/ksh |
1962 | + export CONFIG_SHELL |
1963 | + exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} |
1964 | + else |
1965 | + # Try using printf. |
1966 | + ECHO='printf %s\n' |
1967 | + if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && |
1968 | + echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && |
1969 | + test "X$echo_testing_string" = "X$echo_test_string"; then |
1970 | + # Cool, printf works |
1971 | + : |
1972 | + elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && |
1973 | + test "X$echo_testing_string" = 'X\t' && |
1974 | + echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && |
1975 | + test "X$echo_testing_string" = "X$echo_test_string"; then |
1976 | + CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL |
1977 | + export CONFIG_SHELL |
1978 | + SHELL="$CONFIG_SHELL" |
1979 | + export SHELL |
1980 | + ECHO="$CONFIG_SHELL [$]0 --fallback-echo" |
1981 | + elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && |
1982 | + test "X$echo_testing_string" = 'X\t' && |
1983 | + echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && |
1984 | + test "X$echo_testing_string" = "X$echo_test_string"; then |
1985 | + ECHO="$CONFIG_SHELL [$]0 --fallback-echo" |
1986 | + else |
1987 | + # maybe with a smaller string... |
1988 | + prev=: |
1989 | + |
1990 | + for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do |
1991 | + if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null |
1992 | + then |
1993 | + break |
1994 | + fi |
1995 | + prev="$cmd" |
1996 | + done |
1997 | + |
1998 | + if test "$prev" != 'sed 50q "[$]0"'; then |
1999 | + echo_test_string=`eval $prev` |
2000 | + export echo_test_string |
2001 | + exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} |
2002 | + else |
2003 | + # Oops. We lost completely, so just stick with echo. |
2004 | + ECHO=echo |
2005 | + fi |
2006 | + fi |
2007 | + fi |
2008 | + fi |
2009 | + fi |
2010 | +fi |
2011 | + |
2012 | +# Copy echo and quote the copy suitably for passing to libtool from |
2013 | +# the Makefile, instead of quoting the original, which is used later. |
2014 | +lt_ECHO=$ECHO |
2015 | +if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then |
2016 | + lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" |
2017 | +fi |
2018 | + |
2019 | +AC_SUBST(lt_ECHO) |
2020 | +]) |
2021 | +_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) |
2022 | +_LT_DECL([], [ECHO], [1], |
2023 | + [An echo program that does not interpret backslashes]) |
2024 | +])# _LT_PROG_ECHO_BACKSLASH |
2025 | + |
2026 | + |
2027 | +# _LT_ENABLE_LOCK |
2028 | +# --------------- |
2029 | +m4_defun([_LT_ENABLE_LOCK], |
2030 | +[AC_ARG_ENABLE([libtool-lock], |
2031 | + [AS_HELP_STRING([--disable-libtool-lock], |
2032 | + [avoid locking (might break parallel builds)])]) |
2033 | +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes |
2034 | + |
2035 | +# Some flags need to be propagated to the compiler or linker for good |
2036 | +# libtool support. |
2037 | +case $host in |
2038 | +ia64-*-hpux*) |
2039 | + # Find out which ABI we are using. |
2040 | + echo 'int i;' > conftest.$ac_ext |
2041 | + if AC_TRY_EVAL(ac_compile); then |
2042 | + case `/usr/bin/file conftest.$ac_objext` in |
2043 | + *ELF-32*) |
2044 | + HPUX_IA64_MODE="32" |
2045 | + ;; |
2046 | + *ELF-64*) |
2047 | + HPUX_IA64_MODE="64" |
2048 | + ;; |
2049 | + esac |
2050 | + fi |
2051 | + rm -rf conftest* |
2052 | + ;; |
2053 | +*-*-irix6*) |
2054 | + # Find out which ABI we are using. |
2055 | + echo '[#]line __oline__ "configure"' > conftest.$ac_ext |
2056 | + if AC_TRY_EVAL(ac_compile); then |
2057 | + if test "$lt_cv_prog_gnu_ld" = yes; then |
2058 | + case `/usr/bin/file conftest.$ac_objext` in |
2059 | + *32-bit*) |
2060 | + LD="${LD-ld} -melf32bsmip" |
2061 | + ;; |
2062 | + *N32*) |
2063 | + LD="${LD-ld} -melf32bmipn32" |
2064 | + ;; |
2065 | + *64-bit*) |
2066 | + LD="${LD-ld} -melf64bmip" |
2067 | + ;; |
2068 | + esac |
2069 | + else |
2070 | + case `/usr/bin/file conftest.$ac_objext` in |
2071 | + *32-bit*) |
2072 | + LD="${LD-ld} -32" |
2073 | + ;; |
2074 | + *N32*) |
2075 | + LD="${LD-ld} -n32" |
2076 | + ;; |
2077 | + *64-bit*) |
2078 | + LD="${LD-ld} -64" |
2079 | + ;; |
2080 | + esac |
2081 | + fi |
2082 | + fi |
2083 | + rm -rf conftest* |
2084 | + ;; |
2085 | + |
2086 | +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ |
2087 | +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) |
2088 | + # Find out which ABI we are using. |
2089 | + echo 'int i;' > conftest.$ac_ext |
2090 | + if AC_TRY_EVAL(ac_compile); then |
2091 | + case `/usr/bin/file conftest.o` in |
2092 | + *32-bit*) |
2093 | + case $host in |
2094 | + x86_64-*kfreebsd*-gnu) |
2095 | + LD="${LD-ld} -m elf_i386_fbsd" |
2096 | + ;; |
2097 | + x86_64-*linux*) |
2098 | + LD="${LD-ld} -m elf_i386" |
2099 | + ;; |
2100 | + ppc64-*linux*|powerpc64-*linux*) |
2101 | + LD="${LD-ld} -m elf32ppclinux" |
2102 | + ;; |
2103 | + s390x-*linux*) |
2104 | + LD="${LD-ld} -m elf_s390" |
2105 | + ;; |
2106 | + sparc64-*linux*) |
2107 | + LD="${LD-ld} -m elf32_sparc" |
2108 | + ;; |
2109 | + esac |
2110 | + ;; |
2111 | + *64-bit*) |
2112 | + case $host in |
2113 | + x86_64-*kfreebsd*-gnu) |
2114 | + LD="${LD-ld} -m elf_x86_64_fbsd" |
2115 | + ;; |
2116 | + x86_64-*linux*) |
2117 | + LD="${LD-ld} -m elf_x86_64" |
2118 | + ;; |
2119 | + ppc*-*linux*|powerpc*-*linux*) |
2120 | + LD="${LD-ld} -m elf64ppc" |
2121 | + ;; |
2122 | + s390*-*linux*|s390*-*tpf*) |
2123 | + LD="${LD-ld} -m elf64_s390" |
2124 | + ;; |
2125 | + sparc*-*linux*) |
2126 | + LD="${LD-ld} -m elf64_sparc" |
2127 | + ;; |
2128 | + esac |
2129 | + ;; |
2130 | + esac |
2131 | + fi |
2132 | + rm -rf conftest* |
2133 | + ;; |
2134 | + |
2135 | +*-*-sco3.2v5*) |
2136 | + # On SCO OpenServer 5, we need -belf to get full-featured binaries. |
2137 | + SAVE_CFLAGS="$CFLAGS" |
2138 | + CFLAGS="$CFLAGS -belf" |
2139 | + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, |
2140 | + [AC_LANG_PUSH(C) |
2141 | + AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) |
2142 | + AC_LANG_POP]) |
2143 | + if test x"$lt_cv_cc_needs_belf" != x"yes"; then |
2144 | + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf |
2145 | + CFLAGS="$SAVE_CFLAGS" |
2146 | + fi |
2147 | + ;; |
2148 | +sparc*-*solaris*) |
2149 | + # Find out which ABI we are using. |
2150 | + echo 'int i;' > conftest.$ac_ext |
2151 | + if AC_TRY_EVAL(ac_compile); then |
2152 | + case `/usr/bin/file conftest.o` in |
2153 | + *64-bit*) |
2154 | + case $lt_cv_prog_gnu_ld in |
2155 | + yes*) LD="${LD-ld} -m elf64_sparc" ;; |
2156 | + *) |
2157 | + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then |
2158 | + LD="${LD-ld} -64" |
2159 | + fi |
2160 | + ;; |
2161 | + esac |
2162 | + ;; |
2163 | + esac |
2164 | + fi |
2165 | + rm -rf conftest* |
2166 | + ;; |
2167 | +esac |
2168 | + |
2169 | +need_locks="$enable_libtool_lock" |
2170 | +])# _LT_ENABLE_LOCK |
2171 | + |
2172 | + |
2173 | +# _LT_CMD_OLD_ARCHIVE |
2174 | +# ------------------- |
2175 | +m4_defun([_LT_CMD_OLD_ARCHIVE], |
2176 | +[AC_CHECK_TOOL(AR, ar, false) |
2177 | +test -z "$AR" && AR=ar |
2178 | +test -z "$AR_FLAGS" && AR_FLAGS=cru |
2179 | +_LT_DECL([], [AR], [1], [The archiver]) |
2180 | +_LT_DECL([], [AR_FLAGS], [1]) |
2181 | + |
2182 | +AC_CHECK_TOOL(STRIP, strip, :) |
2183 | +test -z "$STRIP" && STRIP=: |
2184 | +_LT_DECL([], [STRIP], [1], [A symbol stripping program]) |
2185 | + |
2186 | +AC_CHECK_TOOL(RANLIB, ranlib, :) |
2187 | +test -z "$RANLIB" && RANLIB=: |
2188 | +_LT_DECL([], [RANLIB], [1], |
2189 | + [Commands used to install an old-style archive]) |
2190 | + |
2191 | +# Determine commands to create old-style static archives. |
2192 | +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' |
2193 | +old_postinstall_cmds='chmod 644 $oldlib' |
2194 | +old_postuninstall_cmds= |
2195 | + |
2196 | +if test -n "$RANLIB"; then |
2197 | + case $host_os in |
2198 | + openbsd*) |
2199 | + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" |
2200 | + ;; |
2201 | + *) |
2202 | + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" |
2203 | + ;; |
2204 | + esac |
2205 | + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" |
2206 | +fi |
2207 | +_LT_DECL([], [old_postinstall_cmds], [2]) |
2208 | +_LT_DECL([], [old_postuninstall_cmds], [2]) |
2209 | +_LT_TAGDECL([], [old_archive_cmds], [2], |
2210 | + [Commands used to build an old-style archive]) |
2211 | +])# _LT_CMD_OLD_ARCHIVE |
2212 | + |
2213 | + |
2214 | +# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, |
2215 | +# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) |
2216 | +# ---------------------------------------------------------------- |
2217 | +# Check whether the given compiler option works |
2218 | +AC_DEFUN([_LT_COMPILER_OPTION], |
2219 | +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
2220 | +m4_require([_LT_DECL_SED])dnl |
2221 | +AC_CACHE_CHECK([$1], [$2], |
2222 | + [$2=no |
2223 | + m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) |
2224 | + echo "$lt_simple_compile_test_code" > conftest.$ac_ext |
2225 | + lt_compiler_flag="$3" |
2226 | + # Insert the option either (1) after the last *FLAGS variable, or |
2227 | + # (2) before a word containing "conftest.", or (3) at the end. |
2228 | + # Note that $ac_compile itself does not contain backslashes and begins |
2229 | + # with a dollar sign (not a hyphen), so the echo should work correctly. |
2230 | + # The option is referenced via a variable to avoid confusing sed. |
2231 | + lt_compile=`echo "$ac_compile" | $SED \ |
2232 | + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ |
2233 | + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ |
2234 | + -e 's:$: $lt_compiler_flag:'` |
2235 | + (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) |
2236 | + (eval "$lt_compile" 2>conftest.err) |
2237 | + ac_status=$? |
2238 | + cat conftest.err >&AS_MESSAGE_LOG_FD |
2239 | + echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD |
2240 | + if (exit $ac_status) && test -s "$ac_outfile"; then |
2241 | + # The compiler can only warn and ignore the option if not recognized |
2242 | + # So say no if there are warnings other than the usual output. |
2243 | + $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp |
2244 | + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
2245 | + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then |
2246 | + $2=yes |
2247 | + fi |
2248 | + fi |
2249 | + $RM conftest* |
2250 | +]) |
2251 | + |
2252 | +if test x"[$]$2" = xyes; then |
2253 | + m4_if([$5], , :, [$5]) |
2254 | +else |
2255 | + m4_if([$6], , :, [$6]) |
2256 | +fi |
2257 | +])# _LT_COMPILER_OPTION |
2258 | + |
2259 | +# Old name: |
2260 | +AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) |
2261 | +dnl aclocal-1.4 backwards compatibility: |
2262 | +dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) |
2263 | + |
2264 | + |
2265 | +# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, |
2266 | +# [ACTION-SUCCESS], [ACTION-FAILURE]) |
2267 | +# ---------------------------------------------------- |
2268 | +# Check whether the given linker option works |
2269 | +AC_DEFUN([_LT_LINKER_OPTION], |
2270 | +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
2271 | +m4_require([_LT_DECL_SED])dnl |
2272 | +AC_CACHE_CHECK([$1], [$2], |
2273 | + [$2=no |
2274 | + save_LDFLAGS="$LDFLAGS" |
2275 | + LDFLAGS="$LDFLAGS $3" |
2276 | + echo "$lt_simple_link_test_code" > conftest.$ac_ext |
2277 | + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then |
2278 | + # The linker can only warn and ignore the option if not recognized |
2279 | + # So say no if there are warnings |
2280 | + if test -s conftest.err; then |
2281 | + # Append any errors to the config.log. |
2282 | + cat conftest.err 1>&AS_MESSAGE_LOG_FD |
2283 | + $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp |
2284 | + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
2285 | + if diff conftest.exp conftest.er2 >/dev/null; then |
2286 | + $2=yes |
2287 | + fi |
2288 | + else |
2289 | + $2=yes |
2290 | + fi |
2291 | + fi |
2292 | + $RM -r conftest* |
2293 | + LDFLAGS="$save_LDFLAGS" |
2294 | +]) |
2295 | + |
2296 | +if test x"[$]$2" = xyes; then |
2297 | + m4_if([$4], , :, [$4]) |
2298 | +else |
2299 | + m4_if([$5], , :, [$5]) |
2300 | +fi |
2301 | +])# _LT_LINKER_OPTION |
2302 | + |
2303 | +# Old name: |
2304 | +AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) |
2305 | +dnl aclocal-1.4 backwards compatibility: |
2306 | +dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) |
2307 | + |
2308 | + |
2309 | +# LT_CMD_MAX_LEN |
2310 | +#--------------- |
2311 | +AC_DEFUN([LT_CMD_MAX_LEN], |
2312 | +[AC_REQUIRE([AC_CANONICAL_HOST])dnl |
2313 | +# find the maximum length of command line arguments |
2314 | +AC_MSG_CHECKING([the maximum length of command line arguments]) |
2315 | +AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl |
2316 | + i=0 |
2317 | + teststring="ABCD" |
2318 | + |
2319 | + case $build_os in |
2320 | + msdosdjgpp*) |
2321 | + # On DJGPP, this test can blow up pretty badly due to problems in libc |
2322 | + # (any single argument exceeding 2000 bytes causes a buffer overrun |
2323 | + # during glob expansion). Even if it were fixed, the result of this |
2324 | + # check would be larger than it should be. |
2325 | + lt_cv_sys_max_cmd_len=12288; # 12K is about right |
2326 | + ;; |
2327 | + |
2328 | + gnu*) |
2329 | + # Under GNU Hurd, this test is not required because there is |
2330 | + # no limit to the length of command line arguments. |
2331 | + # Libtool will interpret -1 as no limit whatsoever |
2332 | + lt_cv_sys_max_cmd_len=-1; |
2333 | + ;; |
2334 | + |
2335 | + cygwin* | mingw* | cegcc*) |
2336 | + # On Win9x/ME, this test blows up -- it succeeds, but takes |
2337 | + # about 5 minutes as the teststring grows exponentially. |
2338 | + # Worse, since 9x/ME are not pre-emptively multitasking, |
2339 | + # you end up with a "frozen" computer, even though with patience |
2340 | + # the test eventually succeeds (with a max line length of 256k). |
2341 | + # Instead, let's just punt: use the minimum linelength reported by |
2342 | + # all of the supported platforms: 8192 (on NT/2K/XP). |
2343 | + lt_cv_sys_max_cmd_len=8192; |
2344 | + ;; |
2345 | + |
2346 | + amigaos*) |
2347 | + # On AmigaOS with pdksh, this test takes hours, literally. |
2348 | + # So we just punt and use a minimum line length of 8192. |
2349 | + lt_cv_sys_max_cmd_len=8192; |
2350 | + ;; |
2351 | + |
2352 | + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) |
2353 | + # This has been around since 386BSD, at least. Likely further. |
2354 | + if test -x /sbin/sysctl; then |
2355 | + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` |
2356 | + elif test -x /usr/sbin/sysctl; then |
2357 | + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` |
2358 | + else |
2359 | + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs |
2360 | + fi |
2361 | + # And add a safety zone |
2362 | + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` |
2363 | + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` |
2364 | + ;; |
2365 | + |
2366 | + interix*) |
2367 | + # We know the value 262144 and hardcode it with a safety zone (like BSD) |
2368 | + lt_cv_sys_max_cmd_len=196608 |
2369 | + ;; |
2370 | + |
2371 | + osf*) |
2372 | + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure |
2373 | + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not |
2374 | + # nice to cause kernel panics so lets avoid the loop below. |
2375 | + # First set a reasonable default. |
2376 | + lt_cv_sys_max_cmd_len=16384 |
2377 | + # |
2378 | + if test -x /sbin/sysconfig; then |
2379 | + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in |
2380 | + *1*) lt_cv_sys_max_cmd_len=-1 ;; |
2381 | + esac |
2382 | + fi |
2383 | + ;; |
2384 | + sco3.2v5*) |
2385 | + lt_cv_sys_max_cmd_len=102400 |
2386 | + ;; |
2387 | + sysv5* | sco5v6* | sysv4.2uw2*) |
2388 | + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` |
2389 | + if test -n "$kargmax"; then |
2390 | + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` |
2391 | + else |
2392 | + lt_cv_sys_max_cmd_len=32768 |
2393 | + fi |
2394 | + ;; |
2395 | + *) |
2396 | + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` |
2397 | + if test -n "$lt_cv_sys_max_cmd_len"; then |
2398 | + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` |
2399 | + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` |
2400 | + else |
2401 | + # Make teststring a little bigger before we do anything with it. |
2402 | + # a 1K string should be a reasonable start. |
2403 | + for i in 1 2 3 4 5 6 7 8 ; do |
2404 | + teststring=$teststring$teststring |
2405 | + done |
2406 | + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} |
2407 | + # If test is not a shell built-in, we'll probably end up computing a |
2408 | + # maximum length that is only half of the actual maximum length, but |
2409 | + # we can't tell. |
2410 | + while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \ |
2411 | + = "XX$teststring$teststring"; } >/dev/null 2>&1 && |
2412 | + test $i != 17 # 1/2 MB should be enough |
2413 | + do |
2414 | + i=`expr $i + 1` |
2415 | + teststring=$teststring$teststring |
2416 | + done |
2417 | + # Only check the string length outside the loop. |
2418 | + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` |
2419 | + teststring= |
2420 | + # Add a significant safety factor because C++ compilers can tack on |
2421 | + # massive amounts of additional arguments before passing them to the |
2422 | + # linker. It appears as though 1/2 is a usable value. |
2423 | + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` |
2424 | + fi |
2425 | + ;; |
2426 | + esac |
2427 | +]) |
2428 | +if test -n $lt_cv_sys_max_cmd_len ; then |
2429 | + AC_MSG_RESULT($lt_cv_sys_max_cmd_len) |
2430 | +else |
2431 | + AC_MSG_RESULT(none) |
2432 | +fi |
2433 | +max_cmd_len=$lt_cv_sys_max_cmd_len |
2434 | +_LT_DECL([], [max_cmd_len], [0], |
2435 | + [What is the maximum length of a command?]) |
2436 | +])# LT_CMD_MAX_LEN |
2437 | + |
2438 | +# Old name: |
2439 | +AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) |
2440 | +dnl aclocal-1.4 backwards compatibility: |
2441 | +dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) |
2442 | + |
2443 | + |
2444 | +# _LT_HEADER_DLFCN |
2445 | +# ---------------- |
2446 | +m4_defun([_LT_HEADER_DLFCN], |
2447 | +[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl |
2448 | +])# _LT_HEADER_DLFCN |
2449 | + |
2450 | + |
2451 | +# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, |
2452 | +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) |
2453 | +# ---------------------------------------------------------------- |
2454 | +m4_defun([_LT_TRY_DLOPEN_SELF], |
2455 | +[m4_require([_LT_HEADER_DLFCN])dnl |
2456 | +if test "$cross_compiling" = yes; then : |
2457 | + [$4] |
2458 | +else |
2459 | + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 |
2460 | + lt_status=$lt_dlunknown |
2461 | + cat > conftest.$ac_ext <<_LT_EOF |
2462 | +[#line __oline__ "configure" |
2463 | +#include "confdefs.h" |
2464 | + |
2465 | +#if HAVE_DLFCN_H |
2466 | +#include <dlfcn.h> |
2467 | +#endif |
2468 | + |
2469 | +#include <stdio.h> |
2470 | + |
2471 | +#ifdef RTLD_GLOBAL |
2472 | +# define LT_DLGLOBAL RTLD_GLOBAL |
2473 | +#else |
2474 | +# ifdef DL_GLOBAL |
2475 | +# define LT_DLGLOBAL DL_GLOBAL |
2476 | +# else |
2477 | +# define LT_DLGLOBAL 0 |
2478 | +# endif |
2479 | +#endif |
2480 | + |
2481 | +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we |
2482 | + find out it does not work in some platform. */ |
2483 | +#ifndef LT_DLLAZY_OR_NOW |
2484 | +# ifdef RTLD_LAZY |
2485 | +# define LT_DLLAZY_OR_NOW RTLD_LAZY |
2486 | +# else |
2487 | +# ifdef DL_LAZY |
2488 | +# define LT_DLLAZY_OR_NOW DL_LAZY |
2489 | +# else |
2490 | +# ifdef RTLD_NOW |
2491 | +# define LT_DLLAZY_OR_NOW RTLD_NOW |
2492 | +# else |
2493 | +# ifdef DL_NOW |
2494 | +# define LT_DLLAZY_OR_NOW DL_NOW |
2495 | +# else |
2496 | +# define LT_DLLAZY_OR_NOW 0 |
2497 | +# endif |
2498 | +# endif |
2499 | +# endif |
2500 | +# endif |
2501 | +#endif |
2502 | + |
2503 | +void fnord() { int i=42;} |
2504 | +int main () |
2505 | +{ |
2506 | + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); |
2507 | + int status = $lt_dlunknown; |
2508 | + |
2509 | + if (self) |
2510 | + { |
2511 | + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; |
2512 | + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; |
2513 | + /* dlclose (self); */ |
2514 | + } |
2515 | + else |
2516 | + puts (dlerror ()); |
2517 | + |
2518 | + return status; |
2519 | +}] |
2520 | +_LT_EOF |
2521 | + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then |
2522 | + (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null |
2523 | + lt_status=$? |
2524 | + case x$lt_status in |
2525 | + x$lt_dlno_uscore) $1 ;; |
2526 | + x$lt_dlneed_uscore) $2 ;; |
2527 | + x$lt_dlunknown|x*) $3 ;; |
2528 | + esac |
2529 | + else : |
2530 | + # compilation failed |
2531 | + $3 |
2532 | + fi |
2533 | +fi |
2534 | +rm -fr conftest* |
2535 | +])# _LT_TRY_DLOPEN_SELF |
2536 | + |
2537 | + |
2538 | +# LT_SYS_DLOPEN_SELF |
2539 | +# ------------------ |
2540 | +AC_DEFUN([LT_SYS_DLOPEN_SELF], |
2541 | +[m4_require([_LT_HEADER_DLFCN])dnl |
2542 | +if test "x$enable_dlopen" != xyes; then |
2543 | + enable_dlopen=unknown |
2544 | + enable_dlopen_self=unknown |
2545 | + enable_dlopen_self_static=unknown |
2546 | +else |
2547 | + lt_cv_dlopen=no |
2548 | + lt_cv_dlopen_libs= |
2549 | + |
2550 | + case $host_os in |
2551 | + beos*) |
2552 | + lt_cv_dlopen="load_add_on" |
2553 | + lt_cv_dlopen_libs= |
2554 | + lt_cv_dlopen_self=yes |
2555 | + ;; |
2556 | + |
2557 | + mingw* | pw32* | cegcc*) |
2558 | + lt_cv_dlopen="LoadLibrary" |
2559 | + lt_cv_dlopen_libs= |
2560 | + ;; |
2561 | + |
2562 | + cygwin*) |
2563 | + lt_cv_dlopen="dlopen" |
2564 | + lt_cv_dlopen_libs= |
2565 | + ;; |
2566 | + |
2567 | + darwin*) |
2568 | + # if libdl is installed we need to link against it |
2569 | + AC_CHECK_LIB([dl], [dlopen], |
2570 | + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ |
2571 | + lt_cv_dlopen="dyld" |
2572 | + lt_cv_dlopen_libs= |
2573 | + lt_cv_dlopen_self=yes |
2574 | + ]) |
2575 | + ;; |
2576 | + |
2577 | + *) |
2578 | + AC_CHECK_FUNC([shl_load], |
2579 | + [lt_cv_dlopen="shl_load"], |
2580 | + [AC_CHECK_LIB([dld], [shl_load], |
2581 | + [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], |
2582 | + [AC_CHECK_FUNC([dlopen], |
2583 | + [lt_cv_dlopen="dlopen"], |
2584 | + [AC_CHECK_LIB([dl], [dlopen], |
2585 | + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], |
2586 | + [AC_CHECK_LIB([svld], [dlopen], |
2587 | + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], |
2588 | + [AC_CHECK_LIB([dld], [dld_link], |
2589 | + [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) |
2590 | + ]) |
2591 | + ]) |
2592 | + ]) |
2593 | + ]) |
2594 | + ]) |
2595 | + ;; |
2596 | + esac |
2597 | + |
2598 | + if test "x$lt_cv_dlopen" != xno; then |
2599 | + enable_dlopen=yes |
2600 | + else |
2601 | + enable_dlopen=no |
2602 | + fi |
2603 | + |
2604 | + case $lt_cv_dlopen in |
2605 | + dlopen) |
2606 | + save_CPPFLAGS="$CPPFLAGS" |
2607 | + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" |
2608 | + |
2609 | + save_LDFLAGS="$LDFLAGS" |
2610 | + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" |
2611 | + |
2612 | + save_LIBS="$LIBS" |
2613 | + LIBS="$lt_cv_dlopen_libs $LIBS" |
2614 | + |
2615 | + AC_CACHE_CHECK([whether a program can dlopen itself], |
2616 | + lt_cv_dlopen_self, [dnl |
2617 | + _LT_TRY_DLOPEN_SELF( |
2618 | + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, |
2619 | + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) |
2620 | + ]) |
2621 | + |
2622 | + if test "x$lt_cv_dlopen_self" = xyes; then |
2623 | + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" |
2624 | + AC_CACHE_CHECK([whether a statically linked program can dlopen itself], |
2625 | + lt_cv_dlopen_self_static, [dnl |
2626 | + _LT_TRY_DLOPEN_SELF( |
2627 | + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, |
2628 | + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) |
2629 | + ]) |
2630 | + fi |
2631 | + |
2632 | + CPPFLAGS="$save_CPPFLAGS" |
2633 | + LDFLAGS="$save_LDFLAGS" |
2634 | + LIBS="$save_LIBS" |
2635 | + ;; |
2636 | + esac |
2637 | + |
2638 | + case $lt_cv_dlopen_self in |
2639 | + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; |
2640 | + *) enable_dlopen_self=unknown ;; |
2641 | + esac |
2642 | + |
2643 | + case $lt_cv_dlopen_self_static in |
2644 | + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; |
2645 | + *) enable_dlopen_self_static=unknown ;; |
2646 | + esac |
2647 | +fi |
2648 | +_LT_DECL([dlopen_support], [enable_dlopen], [0], |
2649 | + [Whether dlopen is supported]) |
2650 | +_LT_DECL([dlopen_self], [enable_dlopen_self], [0], |
2651 | + [Whether dlopen of programs is supported]) |
2652 | +_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], |
2653 | + [Whether dlopen of statically linked programs is supported]) |
2654 | +])# LT_SYS_DLOPEN_SELF |
2655 | + |
2656 | +# Old name: |
2657 | +AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) |
2658 | +dnl aclocal-1.4 backwards compatibility: |
2659 | +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) |
2660 | + |
2661 | + |
2662 | +# _LT_COMPILER_C_O([TAGNAME]) |
2663 | +# --------------------------- |
2664 | +# Check to see if options -c and -o are simultaneously supported by compiler. |
2665 | +# This macro does not hard code the compiler like AC_PROG_CC_C_O. |
2666 | +m4_defun([_LT_COMPILER_C_O], |
2667 | +[m4_require([_LT_DECL_SED])dnl |
2668 | +m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
2669 | +m4_require([_LT_TAG_COMPILER])dnl |
2670 | +AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], |
2671 | + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], |
2672 | + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no |
2673 | + $RM -r conftest 2>/dev/null |
2674 | + mkdir conftest |
2675 | + cd conftest |
2676 | + mkdir out |
2677 | + echo "$lt_simple_compile_test_code" > conftest.$ac_ext |
2678 | + |
2679 | + lt_compiler_flag="-o out/conftest2.$ac_objext" |
2680 | + # Insert the option either (1) after the last *FLAGS variable, or |
2681 | + # (2) before a word containing "conftest.", or (3) at the end. |
2682 | + # Note that $ac_compile itself does not contain backslashes and begins |
2683 | + # with a dollar sign (not a hyphen), so the echo should work correctly. |
2684 | + lt_compile=`echo "$ac_compile" | $SED \ |
2685 | + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ |
2686 | + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ |
2687 | + -e 's:$: $lt_compiler_flag:'` |
2688 | + (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) |
2689 | + (eval "$lt_compile" 2>out/conftest.err) |
2690 | + ac_status=$? |
2691 | + cat out/conftest.err >&AS_MESSAGE_LOG_FD |
2692 | + echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD |
2693 | + if (exit $ac_status) && test -s out/conftest2.$ac_objext |
2694 | + then |
2695 | + # The compiler can only warn and ignore the option if not recognized |
2696 | + # So say no if there are warnings |
2697 | + $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp |
2698 | + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 |
2699 | + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then |
2700 | + _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes |
2701 | + fi |
2702 | + fi |
2703 | + chmod u+w . 2>&AS_MESSAGE_LOG_FD |
2704 | + $RM conftest* |
2705 | + # SGI C++ compiler will create directory out/ii_files/ for |
2706 | + # template instantiation |
2707 | + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files |
2708 | + $RM out/* && rmdir out |
2709 | + cd .. |
2710 | + $RM -r conftest |
2711 | + $RM conftest* |
2712 | +]) |
2713 | +_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], |
2714 | + [Does compiler simultaneously support -c and -o options?]) |
2715 | +])# _LT_COMPILER_C_O |
2716 | + |
2717 | + |
2718 | +# _LT_COMPILER_FILE_LOCKS([TAGNAME]) |
2719 | +# ---------------------------------- |
2720 | +# Check to see if we can do hard links to lock some files if needed |
2721 | +m4_defun([_LT_COMPILER_FILE_LOCKS], |
2722 | +[m4_require([_LT_ENABLE_LOCK])dnl |
2723 | +m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
2724 | +_LT_COMPILER_C_O([$1]) |
2725 | + |
2726 | +hard_links="nottested" |
2727 | +if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then |
2728 | + # do not overwrite the value of need_locks provided by the user |
2729 | + AC_MSG_CHECKING([if we can lock with hard links]) |
2730 | + hard_links=yes |
2731 | + $RM conftest* |
2732 | + ln conftest.a conftest.b 2>/dev/null && hard_links=no |
2733 | + touch conftest.a |
2734 | + ln conftest.a conftest.b 2>&5 || hard_links=no |
2735 | + ln conftest.a conftest.b 2>/dev/null && hard_links=no |
2736 | + AC_MSG_RESULT([$hard_links]) |
2737 | + if test "$hard_links" = no; then |
2738 | + AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) |
2739 | + need_locks=warn |
2740 | + fi |
2741 | +else |
2742 | + need_locks=no |
2743 | +fi |
2744 | +_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) |
2745 | +])# _LT_COMPILER_FILE_LOCKS |
2746 | + |
2747 | + |
2748 | +# _LT_CHECK_OBJDIR |
2749 | +# ---------------- |
2750 | +m4_defun([_LT_CHECK_OBJDIR], |
2751 | +[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], |
2752 | +[rm -f .libs 2>/dev/null |
2753 | +mkdir .libs 2>/dev/null |
2754 | +if test -d .libs; then |
2755 | + lt_cv_objdir=.libs |
2756 | +else |
2757 | + # MS-DOS does not allow filenames that begin with a dot. |
2758 | + lt_cv_objdir=_libs |
2759 | +fi |
2760 | +rmdir .libs 2>/dev/null]) |
2761 | +objdir=$lt_cv_objdir |
2762 | +_LT_DECL([], [objdir], [0], |
2763 | + [The name of the directory that contains temporary libtool files])dnl |
2764 | +m4_pattern_allow([LT_OBJDIR])dnl |
2765 | +AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", |
2766 | + [Define to the sub-directory in which libtool stores uninstalled libraries.]) |
2767 | +])# _LT_CHECK_OBJDIR |
2768 | + |
2769 | + |
2770 | +# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) |
2771 | +# -------------------------------------- |
2772 | +# Check hardcoding attributes. |
2773 | +m4_defun([_LT_LINKER_HARDCODE_LIBPATH], |
2774 | +[AC_MSG_CHECKING([how to hardcode library paths into programs]) |
2775 | +_LT_TAGVAR(hardcode_action, $1)= |
2776 | +if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || |
2777 | + test -n "$_LT_TAGVAR(runpath_var, $1)" || |
2778 | + test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then |
2779 | + |
2780 | + # We can hardcode non-existent directories. |
2781 | + if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && |
2782 | + # If the only mechanism to avoid hardcoding is shlibpath_var, we |
2783 | + # have to relink, otherwise we might link with an installed library |
2784 | + # when we should be linking with a yet-to-be-installed one |
2785 | + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && |
2786 | + test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then |
2787 | + # Linking always hardcodes the temporary library directory. |
2788 | + _LT_TAGVAR(hardcode_action, $1)=relink |
2789 | + else |
2790 | + # We can link without hardcoding, and we can hardcode nonexisting dirs. |
2791 | + _LT_TAGVAR(hardcode_action, $1)=immediate |
2792 | + fi |
2793 | +else |
2794 | + # We cannot hardcode anything, or else we can only hardcode existing |
2795 | + # directories. |
2796 | + _LT_TAGVAR(hardcode_action, $1)=unsupported |
2797 | +fi |
2798 | +AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) |
2799 | + |
2800 | +if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || |
2801 | + test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then |
2802 | + # Fast installation is not supported |
2803 | + enable_fast_install=no |
2804 | +elif test "$shlibpath_overrides_runpath" = yes || |
2805 | + test "$enable_shared" = no; then |
2806 | + # Fast installation is not necessary |
2807 | + enable_fast_install=needless |
2808 | +fi |
2809 | +_LT_TAGDECL([], [hardcode_action], [0], |
2810 | + [How to hardcode a shared library path into an executable]) |
2811 | +])# _LT_LINKER_HARDCODE_LIBPATH |
2812 | + |
2813 | + |
2814 | +# _LT_CMD_STRIPLIB |
2815 | +# ---------------- |
2816 | +m4_defun([_LT_CMD_STRIPLIB], |
2817 | +[m4_require([_LT_DECL_EGREP]) |
2818 | +striplib= |
2819 | +old_striplib= |
2820 | +AC_MSG_CHECKING([whether stripping libraries is possible]) |
2821 | +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then |
2822 | + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" |
2823 | + test -z "$striplib" && striplib="$STRIP --strip-unneeded" |
2824 | + AC_MSG_RESULT([yes]) |
2825 | +else |
2826 | +# FIXME - insert some real tests, host_os isn't really good enough |
2827 | + case $host_os in |
2828 | + darwin*) |
2829 | + if test -n "$STRIP" ; then |
2830 | + striplib="$STRIP -x" |
2831 | + old_striplib="$STRIP -S" |
2832 | + AC_MSG_RESULT([yes]) |
2833 | + else |
2834 | + AC_MSG_RESULT([no]) |
2835 | + fi |
2836 | + ;; |
2837 | + *) |
2838 | + AC_MSG_RESULT([no]) |
2839 | + ;; |
2840 | + esac |
2841 | +fi |
2842 | +_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) |
2843 | +_LT_DECL([], [striplib], [1]) |
2844 | +])# _LT_CMD_STRIPLIB |
2845 | + |
2846 | + |
2847 | +# _LT_SYS_DYNAMIC_LINKER([TAG]) |
2848 | +# ----------------------------- |
2849 | +# PORTME Fill in your ld.so characteristics |
2850 | +m4_defun([_LT_SYS_DYNAMIC_LINKER], |
2851 | +[AC_REQUIRE([AC_CANONICAL_HOST])dnl |
2852 | +m4_require([_LT_DECL_EGREP])dnl |
2853 | +m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
2854 | +m4_require([_LT_DECL_OBJDUMP])dnl |
2855 | +m4_require([_LT_DECL_SED])dnl |
2856 | +AC_MSG_CHECKING([dynamic linker characteristics]) |
2857 | +m4_if([$1], |
2858 | + [], [ |
2859 | +if test "$GCC" = yes; then |
2860 | + case $host_os in |
2861 | + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; |
2862 | + *) lt_awk_arg="/^libraries:/" ;; |
2863 | + esac |
2864 | + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` |
2865 | + if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then |
2866 | + # if the path contains ";" then we assume it to be the separator |
2867 | + # otherwise default to the standard path separator (i.e. ":") - it is |
2868 | + # assumed that no part of a normal pathname contains ";" but that should |
2869 | + # okay in the real world where ";" in dirpaths is itself problematic. |
2870 | + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'` |
2871 | + else |
2872 | + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` |
2873 | + fi |
2874 | + # Ok, now we have the path, separated by spaces, we can step through it |
2875 | + # and add multilib dir if necessary. |
2876 | + lt_tmp_lt_search_path_spec= |
2877 | + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` |
2878 | + for lt_sys_path in $lt_search_path_spec; do |
2879 | + if test -d "$lt_sys_path/$lt_multi_os_dir"; then |
2880 | + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" |
2881 | + else |
2882 | + test -d "$lt_sys_path" && \ |
2883 | + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" |
2884 | + fi |
2885 | + done |
2886 | + lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk ' |
2887 | +BEGIN {RS=" "; FS="/|\n";} { |
2888 | + lt_foo=""; |
2889 | + lt_count=0; |
2890 | + for (lt_i = NF; lt_i > 0; lt_i--) { |
2891 | + if ($lt_i != "" && $lt_i != ".") { |
2892 | + if ($lt_i == "..") { |
2893 | + lt_count++; |
2894 | + } else { |
2895 | + if (lt_count == 0) { |
2896 | + lt_foo="/" $lt_i lt_foo; |
2897 | + } else { |
2898 | + lt_count--; |
2899 | + } |
2900 | + } |
2901 | + } |
2902 | + } |
2903 | + if (lt_foo != "") { lt_freq[[lt_foo]]++; } |
2904 | + if (lt_freq[[lt_foo]] == 1) { print lt_foo; } |
2905 | +}'` |
2906 | + sys_lib_search_path_spec=`$ECHO $lt_search_path_spec` |
2907 | +else |
2908 | + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" |
2909 | +fi]) |
2910 | +library_names_spec= |
2911 | +libname_spec='lib$name' |
2912 | +soname_spec= |
2913 | +shrext_cmds=".so" |
2914 | +postinstall_cmds= |
2915 | +postuninstall_cmds= |
2916 | +finish_cmds= |
2917 | +finish_eval= |
2918 | +shlibpath_var= |
2919 | +shlibpath_overrides_runpath=unknown |
2920 | +version_type=none |
2921 | +dynamic_linker="$host_os ld.so" |
2922 | +sys_lib_dlsearch_path_spec="/lib /usr/lib" |
2923 | +need_lib_prefix=unknown |
2924 | +hardcode_into_libs=no |
2925 | + |
2926 | +# when you set need_version to no, make sure it does not cause -set_version |
2927 | +# flags to be left without arguments |
2928 | +need_version=unknown |
2929 | + |
2930 | +case $host_os in |
2931 | +aix3*) |
2932 | + version_type=linux |
2933 | + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' |
2934 | + shlibpath_var=LIBPATH |
2935 | + |
2936 | + # AIX 3 has no versioning support, so we append a major version to the name. |
2937 | + soname_spec='${libname}${release}${shared_ext}$major' |
2938 | + ;; |
2939 | + |
2940 | +aix[[4-9]]*) |
2941 | + version_type=linux |
2942 | + need_lib_prefix=no |
2943 | + need_version=no |
2944 | + hardcode_into_libs=yes |
2945 | + if test "$host_cpu" = ia64; then |
2946 | + # AIX 5 supports IA64 |
2947 | + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' |
2948 | + shlibpath_var=LD_LIBRARY_PATH |
2949 | + else |
2950 | + # With GCC up to 2.95.x, collect2 would create an import file |
2951 | + # for dependence libraries. The import file would start with |
2952 | + # the line `#! .'. This would cause the generated library to |
2953 | + # depend on `.', always an invalid library. This was fixed in |
2954 | + # development snapshots of GCC prior to 3.0. |
2955 | + case $host_os in |
2956 | + aix4 | aix4.[[01]] | aix4.[[01]].*) |
2957 | + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' |
2958 | + echo ' yes ' |
2959 | + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then |
2960 | + : |
2961 | + else |
2962 | + can_build_shared=no |
2963 | + fi |
2964 | + ;; |
2965 | + esac |
2966 | + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct |
2967 | + # soname into executable. Probably we can add versioning support to |
2968 | + # collect2, so additional links can be useful in future. |
2969 | + if test "$aix_use_runtimelinking" = yes; then |
2970 | + # If using run time linking (on AIX 4.2 or later) use lib<name>.so |
2971 | + # instead of lib<name>.a to let people know that these are not |
2972 | + # typical AIX shared libraries. |
2973 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
2974 | + else |
2975 | + # We preserve .a as extension for shared libraries through AIX4.2 |
2976 | + # and later when we are not doing run time linking. |
2977 | + library_names_spec='${libname}${release}.a $libname.a' |
2978 | + soname_spec='${libname}${release}${shared_ext}$major' |
2979 | + fi |
2980 | + shlibpath_var=LIBPATH |
2981 | + fi |
2982 | + ;; |
2983 | + |
2984 | +amigaos*) |
2985 | + case $host_cpu in |
2986 | + powerpc) |
2987 | + # Since July 2007 AmigaOS4 officially supports .so libraries. |
2988 | + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. |
2989 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
2990 | + ;; |
2991 | + m68k) |
2992 | + library_names_spec='$libname.ixlibrary $libname.a' |
2993 | + # Create ${libname}_ixlibrary.a entries in /sys/libs. |
2994 | + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' |
2995 | + ;; |
2996 | + esac |
2997 | + ;; |
2998 | + |
2999 | +beos*) |
3000 | + library_names_spec='${libname}${shared_ext}' |
3001 | + dynamic_linker="$host_os ld.so" |
3002 | + shlibpath_var=LIBRARY_PATH |
3003 | + ;; |
3004 | + |
3005 | +bsdi[[45]]*) |
3006 | + version_type=linux |
3007 | + need_version=no |
3008 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3009 | + soname_spec='${libname}${release}${shared_ext}$major' |
3010 | + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' |
3011 | + shlibpath_var=LD_LIBRARY_PATH |
3012 | + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" |
3013 | + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" |
3014 | + # the default ld.so.conf also contains /usr/contrib/lib and |
3015 | + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow |
3016 | + # libtool to hard-code these into programs |
3017 | + ;; |
3018 | + |
3019 | +cygwin* | mingw* | pw32* | cegcc*) |
3020 | + version_type=windows |
3021 | + shrext_cmds=".dll" |
3022 | + need_version=no |
3023 | + need_lib_prefix=no |
3024 | + |
3025 | + case $GCC,$host_os in |
3026 | + yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) |
3027 | + library_names_spec='$libname.dll.a' |
3028 | + # DLL is installed to $(libdir)/../bin by postinstall_cmds |
3029 | + postinstall_cmds='base_file=`basename \${file}`~ |
3030 | + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ |
3031 | + dldir=$destdir/`dirname \$dlpath`~ |
3032 | + test -d \$dldir || mkdir -p \$dldir~ |
3033 | + $install_prog $dir/$dlname \$dldir/$dlname~ |
3034 | + chmod a+x \$dldir/$dlname~ |
3035 | + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then |
3036 | + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; |
3037 | + fi' |
3038 | + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ |
3039 | + dlpath=$dir/\$dldll~ |
3040 | + $RM \$dlpath' |
3041 | + shlibpath_overrides_runpath=yes |
3042 | + |
3043 | + case $host_os in |
3044 | + cygwin*) |
3045 | + # Cygwin DLLs use 'cyg' prefix rather than 'lib' |
3046 | + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' |
3047 | + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" |
3048 | + ;; |
3049 | + mingw* | cegcc*) |
3050 | + # MinGW DLLs use traditional 'lib' prefix |
3051 | + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' |
3052 | + sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` |
3053 | + if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then |
3054 | + # It is most probably a Windows format PATH printed by |
3055 | + # mingw gcc, but we are running on Cygwin. Gcc prints its search |
3056 | + # path with ; separators, and with drive letters. We can handle the |
3057 | + # drive letters (cygwin fileutils understands them), so leave them, |
3058 | + # especially as we might pass files found there to a mingw objdump, |
3059 | + # which wouldn't understand a cygwinified path. Ahh. |
3060 | + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` |
3061 | + else |
3062 | + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` |
3063 | + fi |
3064 | + ;; |
3065 | + pw32*) |
3066 | + # pw32 DLLs use 'pw' prefix rather than 'lib' |
3067 | + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' |
3068 | + ;; |
3069 | + esac |
3070 | + ;; |
3071 | + |
3072 | + *) |
3073 | + library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' |
3074 | + ;; |
3075 | + esac |
3076 | + dynamic_linker='Win32 ld.exe' |
3077 | + # FIXME: first we should search . and the directory the executable is in |
3078 | + shlibpath_var=PATH |
3079 | + ;; |
3080 | + |
3081 | +darwin* | rhapsody*) |
3082 | + dynamic_linker="$host_os dyld" |
3083 | + version_type=darwin |
3084 | + need_lib_prefix=no |
3085 | + need_version=no |
3086 | + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' |
3087 | + soname_spec='${libname}${release}${major}$shared_ext' |
3088 | + shlibpath_overrides_runpath=yes |
3089 | + shlibpath_var=DYLD_LIBRARY_PATH |
3090 | + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' |
3091 | +m4_if([$1], [],[ |
3092 | + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) |
3093 | + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' |
3094 | + ;; |
3095 | + |
3096 | +dgux*) |
3097 | + version_type=linux |
3098 | + need_lib_prefix=no |
3099 | + need_version=no |
3100 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' |
3101 | + soname_spec='${libname}${release}${shared_ext}$major' |
3102 | + shlibpath_var=LD_LIBRARY_PATH |
3103 | + ;; |
3104 | + |
3105 | +freebsd1*) |
3106 | + dynamic_linker=no |
3107 | + ;; |
3108 | + |
3109 | +freebsd* | dragonfly*) |
3110 | + # DragonFly does not have aout. When/if they implement a new |
3111 | + # versioning mechanism, adjust this. |
3112 | + if test -x /usr/bin/objformat; then |
3113 | + objformat=`/usr/bin/objformat` |
3114 | + else |
3115 | + case $host_os in |
3116 | + freebsd[[123]]*) objformat=aout ;; |
3117 | + *) objformat=elf ;; |
3118 | + esac |
3119 | + fi |
3120 | + version_type=freebsd-$objformat |
3121 | + case $version_type in |
3122 | + freebsd-elf*) |
3123 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' |
3124 | + need_version=no |
3125 | + need_lib_prefix=no |
3126 | + ;; |
3127 | + freebsd-*) |
3128 | + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' |
3129 | + need_version=yes |
3130 | + ;; |
3131 | + esac |
3132 | + shlibpath_var=LD_LIBRARY_PATH |
3133 | + case $host_os in |
3134 | + freebsd2*) |
3135 | + shlibpath_overrides_runpath=yes |
3136 | + ;; |
3137 | + freebsd3.[[01]]* | freebsdelf3.[[01]]*) |
3138 | + shlibpath_overrides_runpath=yes |
3139 | + hardcode_into_libs=yes |
3140 | + ;; |
3141 | + freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ |
3142 | + freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) |
3143 | + shlibpath_overrides_runpath=no |
3144 | + hardcode_into_libs=yes |
3145 | + ;; |
3146 | + *) # from 4.6 on, and DragonFly |
3147 | + shlibpath_overrides_runpath=yes |
3148 | + hardcode_into_libs=yes |
3149 | + ;; |
3150 | + esac |
3151 | + ;; |
3152 | + |
3153 | +gnu*) |
3154 | + version_type=linux |
3155 | + need_lib_prefix=no |
3156 | + need_version=no |
3157 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' |
3158 | + soname_spec='${libname}${release}${shared_ext}$major' |
3159 | + shlibpath_var=LD_LIBRARY_PATH |
3160 | + hardcode_into_libs=yes |
3161 | + ;; |
3162 | + |
3163 | +hpux9* | hpux10* | hpux11*) |
3164 | + # Give a soname corresponding to the major version so that dld.sl refuses to |
3165 | + # link against other versions. |
3166 | + version_type=sunos |
3167 | + need_lib_prefix=no |
3168 | + need_version=no |
3169 | + case $host_cpu in |
3170 | + ia64*) |
3171 | + shrext_cmds='.so' |
3172 | + hardcode_into_libs=yes |
3173 | + dynamic_linker="$host_os dld.so" |
3174 | + shlibpath_var=LD_LIBRARY_PATH |
3175 | + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. |
3176 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3177 | + soname_spec='${libname}${release}${shared_ext}$major' |
3178 | + if test "X$HPUX_IA64_MODE" = X32; then |
3179 | + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" |
3180 | + else |
3181 | + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" |
3182 | + fi |
3183 | + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec |
3184 | + ;; |
3185 | + hppa*64*) |
3186 | + shrext_cmds='.sl' |
3187 | + hardcode_into_libs=yes |
3188 | + dynamic_linker="$host_os dld.sl" |
3189 | + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH |
3190 | + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. |
3191 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3192 | + soname_spec='${libname}${release}${shared_ext}$major' |
3193 | + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" |
3194 | + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec |
3195 | + ;; |
3196 | + *) |
3197 | + shrext_cmds='.sl' |
3198 | + dynamic_linker="$host_os dld.sl" |
3199 | + shlibpath_var=SHLIB_PATH |
3200 | + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH |
3201 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3202 | + soname_spec='${libname}${release}${shared_ext}$major' |
3203 | + ;; |
3204 | + esac |
3205 | + # HP-UX runs *really* slowly unless shared libraries are mode 555. |
3206 | + postinstall_cmds='chmod 555 $lib' |
3207 | + ;; |
3208 | + |
3209 | +interix[[3-9]]*) |
3210 | + version_type=linux |
3211 | + need_lib_prefix=no |
3212 | + need_version=no |
3213 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' |
3214 | + soname_spec='${libname}${release}${shared_ext}$major' |
3215 | + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' |
3216 | + shlibpath_var=LD_LIBRARY_PATH |
3217 | + shlibpath_overrides_runpath=no |
3218 | + hardcode_into_libs=yes |
3219 | + ;; |
3220 | + |
3221 | +irix5* | irix6* | nonstopux*) |
3222 | + case $host_os in |
3223 | + nonstopux*) version_type=nonstopux ;; |
3224 | + *) |
3225 | + if test "$lt_cv_prog_gnu_ld" = yes; then |
3226 | + version_type=linux |
3227 | + else |
3228 | + version_type=irix |
3229 | + fi ;; |
3230 | + esac |
3231 | + need_lib_prefix=no |
3232 | + need_version=no |
3233 | + soname_spec='${libname}${release}${shared_ext}$major' |
3234 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' |
3235 | + case $host_os in |
3236 | + irix5* | nonstopux*) |
3237 | + libsuff= shlibsuff= |
3238 | + ;; |
3239 | + *) |
3240 | + case $LD in # libtool.m4 will add one of these switches to LD |
3241 | + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") |
3242 | + libsuff= shlibsuff= libmagic=32-bit;; |
3243 | + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") |
3244 | + libsuff=32 shlibsuff=N32 libmagic=N32;; |
3245 | + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") |
3246 | + libsuff=64 shlibsuff=64 libmagic=64-bit;; |
3247 | + *) libsuff= shlibsuff= libmagic=never-match;; |
3248 | + esac |
3249 | + ;; |
3250 | + esac |
3251 | + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH |
3252 | + shlibpath_overrides_runpath=no |
3253 | + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" |
3254 | + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" |
3255 | + hardcode_into_libs=yes |
3256 | + ;; |
3257 | + |
3258 | +# No shared lib support for Linux oldld, aout, or coff. |
3259 | +linux*oldld* | linux*aout* | linux*coff*) |
3260 | + dynamic_linker=no |
3261 | + ;; |
3262 | + |
3263 | +# This must be Linux ELF. |
3264 | +linux* | k*bsd*-gnu | kopensolaris*-gnu) |
3265 | + version_type=linux |
3266 | + need_lib_prefix=no |
3267 | + need_version=no |
3268 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3269 | + soname_spec='${libname}${release}${shared_ext}$major' |
3270 | + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' |
3271 | + shlibpath_var=LD_LIBRARY_PATH |
3272 | + shlibpath_overrides_runpath=no |
3273 | + # Some binutils ld are patched to set DT_RUNPATH |
3274 | + save_LDFLAGS=$LDFLAGS |
3275 | + save_libdir=$libdir |
3276 | + eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ |
3277 | + LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" |
3278 | + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], |
3279 | + [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], |
3280 | + [shlibpath_overrides_runpath=yes])]) |
3281 | + LDFLAGS=$save_LDFLAGS |
3282 | + libdir=$save_libdir |
3283 | + |
3284 | + # This implies no fast_install, which is unacceptable. |
3285 | + # Some rework will be needed to allow for fast_install |
3286 | + # before this can be enabled. |
3287 | + hardcode_into_libs=yes |
3288 | + |
3289 | + # Append ld.so.conf contents to the search path |
3290 | + if test -f /etc/ld.so.conf; then |
3291 | + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` |
3292 | + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" |
3293 | + fi |
3294 | + |
3295 | + # We used to test for /lib/ld.so.1 and disable shared libraries on |
3296 | + # powerpc, because MkLinux only supported shared libraries with the |
3297 | + # GNU dynamic linker. Since this was broken with cross compilers, |
3298 | + # most powerpc-linux boxes support dynamic linking these days and |
3299 | + # people can always --disable-shared, the test was removed, and we |
3300 | + # assume the GNU/Linux dynamic linker is in use. |
3301 | + dynamic_linker='GNU/Linux ld.so' |
3302 | + ;; |
3303 | + |
3304 | +netbsdelf*-gnu) |
3305 | + version_type=linux |
3306 | + need_lib_prefix=no |
3307 | + need_version=no |
3308 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' |
3309 | + soname_spec='${libname}${release}${shared_ext}$major' |
3310 | + shlibpath_var=LD_LIBRARY_PATH |
3311 | + shlibpath_overrides_runpath=no |
3312 | + hardcode_into_libs=yes |
3313 | + dynamic_linker='NetBSD ld.elf_so' |
3314 | + ;; |
3315 | + |
3316 | +netbsd*) |
3317 | + version_type=sunos |
3318 | + need_lib_prefix=no |
3319 | + need_version=no |
3320 | + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then |
3321 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' |
3322 | + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' |
3323 | + dynamic_linker='NetBSD (a.out) ld.so' |
3324 | + else |
3325 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' |
3326 | + soname_spec='${libname}${release}${shared_ext}$major' |
3327 | + dynamic_linker='NetBSD ld.elf_so' |
3328 | + fi |
3329 | + shlibpath_var=LD_LIBRARY_PATH |
3330 | + shlibpath_overrides_runpath=yes |
3331 | + hardcode_into_libs=yes |
3332 | + ;; |
3333 | + |
3334 | +newsos6) |
3335 | + version_type=linux |
3336 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3337 | + shlibpath_var=LD_LIBRARY_PATH |
3338 | + shlibpath_overrides_runpath=yes |
3339 | + ;; |
3340 | + |
3341 | +*nto* | *qnx*) |
3342 | + version_type=qnx |
3343 | + need_lib_prefix=no |
3344 | + need_version=no |
3345 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3346 | + soname_spec='${libname}${release}${shared_ext}$major' |
3347 | + shlibpath_var=LD_LIBRARY_PATH |
3348 | + shlibpath_overrides_runpath=no |
3349 | + hardcode_into_libs=yes |
3350 | + dynamic_linker='ldqnx.so' |
3351 | + ;; |
3352 | + |
3353 | +openbsd*) |
3354 | + version_type=sunos |
3355 | + sys_lib_dlsearch_path_spec="/usr/lib" |
3356 | + need_lib_prefix=no |
3357 | + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. |
3358 | + case $host_os in |
3359 | + openbsd3.3 | openbsd3.3.*) need_version=yes ;; |
3360 | + *) need_version=no ;; |
3361 | + esac |
3362 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' |
3363 | + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' |
3364 | + shlibpath_var=LD_LIBRARY_PATH |
3365 | + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then |
3366 | + case $host_os in |
3367 | + openbsd2.[[89]] | openbsd2.[[89]].*) |
3368 | + shlibpath_overrides_runpath=no |
3369 | + ;; |
3370 | + *) |
3371 | + shlibpath_overrides_runpath=yes |
3372 | + ;; |
3373 | + esac |
3374 | + else |
3375 | + shlibpath_overrides_runpath=yes |
3376 | + fi |
3377 | + ;; |
3378 | + |
3379 | +os2*) |
3380 | + libname_spec='$name' |
3381 | + shrext_cmds=".dll" |
3382 | + need_lib_prefix=no |
3383 | + library_names_spec='$libname${shared_ext} $libname.a' |
3384 | + dynamic_linker='OS/2 ld.exe' |
3385 | + shlibpath_var=LIBPATH |
3386 | + ;; |
3387 | + |
3388 | +osf3* | osf4* | osf5*) |
3389 | + version_type=osf |
3390 | + need_lib_prefix=no |
3391 | + need_version=no |
3392 | + soname_spec='${libname}${release}${shared_ext}$major' |
3393 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3394 | + shlibpath_var=LD_LIBRARY_PATH |
3395 | + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" |
3396 | + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" |
3397 | + ;; |
3398 | + |
3399 | +rdos*) |
3400 | + dynamic_linker=no |
3401 | + ;; |
3402 | + |
3403 | +solaris*) |
3404 | + version_type=linux |
3405 | + need_lib_prefix=no |
3406 | + need_version=no |
3407 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3408 | + soname_spec='${libname}${release}${shared_ext}$major' |
3409 | + shlibpath_var=LD_LIBRARY_PATH |
3410 | + shlibpath_overrides_runpath=yes |
3411 | + hardcode_into_libs=yes |
3412 | + # ldd complains unless libraries are executable |
3413 | + postinstall_cmds='chmod +x $lib' |
3414 | + ;; |
3415 | + |
3416 | +sunos4*) |
3417 | + version_type=sunos |
3418 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' |
3419 | + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' |
3420 | + shlibpath_var=LD_LIBRARY_PATH |
3421 | + shlibpath_overrides_runpath=yes |
3422 | + if test "$with_gnu_ld" = yes; then |
3423 | + need_lib_prefix=no |
3424 | + fi |
3425 | + need_version=yes |
3426 | + ;; |
3427 | + |
3428 | +sysv4 | sysv4.3*) |
3429 | + version_type=linux |
3430 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3431 | + soname_spec='${libname}${release}${shared_ext}$major' |
3432 | + shlibpath_var=LD_LIBRARY_PATH |
3433 | + case $host_vendor in |
3434 | + sni) |
3435 | + shlibpath_overrides_runpath=no |
3436 | + need_lib_prefix=no |
3437 | + runpath_var=LD_RUN_PATH |
3438 | + ;; |
3439 | + siemens) |
3440 | + need_lib_prefix=no |
3441 | + ;; |
3442 | + motorola) |
3443 | + need_lib_prefix=no |
3444 | + need_version=no |
3445 | + shlibpath_overrides_runpath=no |
3446 | + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' |
3447 | + ;; |
3448 | + esac |
3449 | + ;; |
3450 | + |
3451 | +sysv4*MP*) |
3452 | + if test -d /usr/nec ;then |
3453 | + version_type=linux |
3454 | + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' |
3455 | + soname_spec='$libname${shared_ext}.$major' |
3456 | + shlibpath_var=LD_LIBRARY_PATH |
3457 | + fi |
3458 | + ;; |
3459 | + |
3460 | +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) |
3461 | + version_type=freebsd-elf |
3462 | + need_lib_prefix=no |
3463 | + need_version=no |
3464 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' |
3465 | + soname_spec='${libname}${release}${shared_ext}$major' |
3466 | + shlibpath_var=LD_LIBRARY_PATH |
3467 | + shlibpath_overrides_runpath=yes |
3468 | + hardcode_into_libs=yes |
3469 | + if test "$with_gnu_ld" = yes; then |
3470 | + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' |
3471 | + else |
3472 | + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' |
3473 | + case $host_os in |
3474 | + sco3.2v5*) |
3475 | + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" |
3476 | + ;; |
3477 | + esac |
3478 | + fi |
3479 | + sys_lib_dlsearch_path_spec='/usr/lib' |
3480 | + ;; |
3481 | + |
3482 | +tpf*) |
3483 | + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. |
3484 | + version_type=linux |
3485 | + need_lib_prefix=no |
3486 | + need_version=no |
3487 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3488 | + shlibpath_var=LD_LIBRARY_PATH |
3489 | + shlibpath_overrides_runpath=no |
3490 | + hardcode_into_libs=yes |
3491 | + ;; |
3492 | + |
3493 | +uts4*) |
3494 | + version_type=linux |
3495 | + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
3496 | + soname_spec='${libname}${release}${shared_ext}$major' |
3497 | + shlibpath_var=LD_LIBRARY_PATH |
3498 | + ;; |
3499 | + |
3500 | +*) |
3501 | + dynamic_linker=no |
3502 | + ;; |
3503 | +esac |
3504 | +AC_MSG_RESULT([$dynamic_linker]) |
3505 | +test "$dynamic_linker" = no && can_build_shared=no |
3506 | + |
3507 | +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" |
3508 | +if test "$GCC" = yes; then |
3509 | + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" |
3510 | +fi |
3511 | + |
3512 | +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then |
3513 | + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" |
3514 | +fi |
3515 | +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then |
3516 | + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" |
3517 | +fi |
3518 | + |
3519 | +_LT_DECL([], [variables_saved_for_relink], [1], |
3520 | + [Variables whose values should be saved in libtool wrapper scripts and |
3521 | + restored at link time]) |
3522 | +_LT_DECL([], [need_lib_prefix], [0], |
3523 | + [Do we need the "lib" prefix for modules?]) |
3524 | +_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) |
3525 | +_LT_DECL([], [version_type], [0], [Library versioning type]) |
3526 | +_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) |
3527 | +_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) |
3528 | +_LT_DECL([], [shlibpath_overrides_runpath], [0], |
3529 | + [Is shlibpath searched before the hard-coded library search path?]) |
3530 | +_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) |
3531 | +_LT_DECL([], [library_names_spec], [1], |
3532 | + [[List of archive names. First name is the real one, the rest are links. |
3533 | + The last name is the one that the linker finds with -lNAME]]) |
3534 | +_LT_DECL([], [soname_spec], [1], |
3535 | + [[The coded name of the library, if different from the real name]]) |
3536 | +_LT_DECL([], [postinstall_cmds], [2], |
3537 | + [Command to use after installation of a shared archive]) |
3538 | +_LT_DECL([], [postuninstall_cmds], [2], |
3539 | + [Command to use after uninstallation of a shared archive]) |
3540 | +_LT_DECL([], [finish_cmds], [2], |
3541 | + [Commands used to finish a libtool library installation in a directory]) |
3542 | +_LT_DECL([], [finish_eval], [1], |
3543 | + [[As "finish_cmds", except a single script fragment to be evaled but |
3544 | + not shown]]) |
3545 | +_LT_DECL([], [hardcode_into_libs], [0], |
3546 | + [Whether we should hardcode library paths into libraries]) |
3547 | +_LT_DECL([], [sys_lib_search_path_spec], [2], |
3548 | + [Compile-time system search path for libraries]) |
3549 | +_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], |
3550 | + [Run-time system search path for libraries]) |
3551 | +])# _LT_SYS_DYNAMIC_LINKER |
3552 | + |
3553 | + |
3554 | +# _LT_PATH_TOOL_PREFIX(TOOL) |
3555 | +# -------------------------- |
3556 | +# find a file program which can recognize shared library |
3557 | +AC_DEFUN([_LT_PATH_TOOL_PREFIX], |
3558 | +[m4_require([_LT_DECL_EGREP])dnl |
3559 | +AC_MSG_CHECKING([for $1]) |
3560 | +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, |
3561 | +[case $MAGIC_CMD in |
3562 | +[[\\/*] | ?:[\\/]*]) |
3563 | + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. |
3564 | + ;; |
3565 | +*) |
3566 | + lt_save_MAGIC_CMD="$MAGIC_CMD" |
3567 | + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR |
3568 | +dnl $ac_dummy forces splitting on constant user-supplied paths. |
3569 | +dnl POSIX.2 word splitting is done only on the output of word expansions, |
3570 | +dnl not every word. This closes a longstanding sh security hole. |
3571 | + ac_dummy="m4_if([$2], , $PATH, [$2])" |
3572 | + for ac_dir in $ac_dummy; do |
3573 | + IFS="$lt_save_ifs" |
3574 | + test -z "$ac_dir" && ac_dir=. |
3575 | + if test -f $ac_dir/$1; then |
3576 | + lt_cv_path_MAGIC_CMD="$ac_dir/$1" |
3577 | + if test -n "$file_magic_test_file"; then |
3578 | + case $deplibs_check_method in |
3579 | + "file_magic "*) |
3580 | + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` |
3581 | + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
3582 | + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | |
3583 | + $EGREP "$file_magic_regex" > /dev/null; then |
3584 | + : |
3585 | + else |
3586 | + cat <<_LT_EOF 1>&2 |
3587 | + |
3588 | +*** Warning: the command libtool uses to detect shared libraries, |
3589 | +*** $file_magic_cmd, produces output that libtool cannot recognize. |
3590 | +*** The result is that libtool may fail to recognize shared libraries |
3591 | +*** as such. This will affect the creation of libtool libraries that |
3592 | +*** depend on shared libraries, but programs linked with such libtool |
3593 | +*** libraries will work regardless of this problem. Nevertheless, you |
3594 | +*** may want to report the problem to your system manager and/or to |
3595 | +*** bug-libtool@gnu.org |
3596 | + |
3597 | +_LT_EOF |
3598 | + fi ;; |
3599 | + esac |
3600 | + fi |
3601 | + break |
3602 | + fi |
3603 | + done |
3604 | + IFS="$lt_save_ifs" |
3605 | + MAGIC_CMD="$lt_save_MAGIC_CMD" |
3606 | + ;; |
3607 | +esac]) |
3608 | +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
3609 | +if test -n "$MAGIC_CMD"; then |
3610 | + AC_MSG_RESULT($MAGIC_CMD) |
3611 | +else |
3612 | + AC_MSG_RESULT(no) |
3613 | +fi |
3614 | +_LT_DECL([], [MAGIC_CMD], [0], |
3615 | + [Used to examine libraries when file_magic_cmd begins with "file"])dnl |
3616 | +])# _LT_PATH_TOOL_PREFIX |
3617 | + |
3618 | +# Old name: |
3619 | +AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) |
3620 | +dnl aclocal-1.4 backwards compatibility: |
3621 | +dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) |
3622 | + |
3623 | + |
3624 | +# _LT_PATH_MAGIC |
3625 | +# -------------- |
3626 | +# find a file program which can recognize a shared library |
3627 | +m4_defun([_LT_PATH_MAGIC], |
3628 | +[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) |
3629 | +if test -z "$lt_cv_path_MAGIC_CMD"; then |
3630 | + if test -n "$ac_tool_prefix"; then |
3631 | + _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) |
3632 | + else |
3633 | + MAGIC_CMD=: |
3634 | + fi |
3635 | +fi |
3636 | +])# _LT_PATH_MAGIC |
3637 | + |
3638 | + |
3639 | +# LT_PATH_LD |
3640 | +# ---------- |
3641 | +# find the pathname to the GNU or non-GNU linker |
3642 | +AC_DEFUN([LT_PATH_LD], |
3643 | +[AC_REQUIRE([AC_PROG_CC])dnl |
3644 | +AC_REQUIRE([AC_CANONICAL_HOST])dnl |
3645 | +AC_REQUIRE([AC_CANONICAL_BUILD])dnl |
3646 | +m4_require([_LT_DECL_SED])dnl |
3647 | +m4_require([_LT_DECL_EGREP])dnl |
3648 | + |
3649 | +AC_ARG_WITH([gnu-ld], |
3650 | + [AS_HELP_STRING([--with-gnu-ld], |
3651 | + [assume the C compiler uses GNU ld @<:@default=no@:>@])], |
3652 | + [test "$withval" = no || with_gnu_ld=yes], |
3653 | + [with_gnu_ld=no])dnl |
3654 | + |
3655 | +ac_prog=ld |
3656 | +if test "$GCC" = yes; then |
3657 | + # Check if gcc -print-prog-name=ld gives a path. |
3658 | + AC_MSG_CHECKING([for ld used by $CC]) |
3659 | + case $host in |
3660 | + *-*-mingw*) |
3661 | + # gcc leaves a trailing carriage return which upsets mingw |
3662 | + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; |
3663 | + *) |
3664 | + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; |
3665 | + esac |
3666 | + case $ac_prog in |
3667 | + # Accept absolute paths. |
3668 | + [[\\/]]* | ?:[[\\/]]*) |
3669 | + re_direlt='/[[^/]][[^/]]*/\.\./' |
3670 | + # Canonicalize the pathname of ld |
3671 | + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` |
3672 | + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do |
3673 | + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` |
3674 | + done |
3675 | + test -z "$LD" && LD="$ac_prog" |
3676 | + ;; |
3677 | + "") |
3678 | + # If it fails, then pretend we aren't using GCC. |
3679 | + ac_prog=ld |
3680 | + ;; |
3681 | + *) |
3682 | + # If it is relative, then search for the first ld in PATH. |
3683 | + with_gnu_ld=unknown |
3684 | + ;; |
3685 | + esac |
3686 | +elif test "$with_gnu_ld" = yes; then |
3687 | + AC_MSG_CHECKING([for GNU ld]) |
3688 | +else |
3689 | + AC_MSG_CHECKING([for non-GNU ld]) |
3690 | +fi |
3691 | +AC_CACHE_VAL(lt_cv_path_LD, |
3692 | +[if test -z "$LD"; then |
3693 | + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR |
3694 | + for ac_dir in $PATH; do |
3695 | + IFS="$lt_save_ifs" |
3696 | + test -z "$ac_dir" && ac_dir=. |
3697 | + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then |
3698 | + lt_cv_path_LD="$ac_dir/$ac_prog" |
3699 | + # Check to see if the program is GNU ld. I'd rather use --version, |
3700 | + # but apparently some variants of GNU ld only accept -v. |
3701 | + # Break only if it was the GNU/non-GNU ld that we prefer. |
3702 | + case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in |
3703 | + *GNU* | *'with BFD'*) |
3704 | + test "$with_gnu_ld" != no && break |
3705 | + ;; |
3706 | + *) |
3707 | + test "$with_gnu_ld" != yes && break |
3708 | + ;; |
3709 | + esac |
3710 | + fi |
3711 | + done |
3712 | + IFS="$lt_save_ifs" |
3713 | +else |
3714 | + lt_cv_path_LD="$LD" # Let the user override the test with a path. |
3715 | +fi]) |
3716 | +LD="$lt_cv_path_LD" |
3717 | +if test -n "$LD"; then |
3718 | + AC_MSG_RESULT($LD) |
3719 | +else |
3720 | + AC_MSG_RESULT(no) |
3721 | +fi |
3722 | +test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) |
3723 | +_LT_PATH_LD_GNU |
3724 | +AC_SUBST([LD]) |
3725 | + |
3726 | +_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) |
3727 | +])# LT_PATH_LD |
3728 | + |
3729 | +# Old names: |
3730 | +AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) |
3731 | +AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) |
3732 | +dnl aclocal-1.4 backwards compatibility: |
3733 | +dnl AC_DEFUN([AM_PROG_LD], []) |
3734 | +dnl AC_DEFUN([AC_PROG_LD], []) |
3735 | + |
3736 | + |
3737 | +# _LT_PATH_LD_GNU |
3738 | +#- -------------- |
3739 | +m4_defun([_LT_PATH_LD_GNU], |
3740 | +[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, |
3741 | +[# I'd rather use --version here, but apparently some GNU lds only accept -v. |
3742 | +case `$LD -v 2>&1 </dev/null` in |
3743 | +*GNU* | *'with BFD'*) |
3744 | + lt_cv_prog_gnu_ld=yes |
3745 | + ;; |
3746 | +*) |
3747 | + lt_cv_prog_gnu_ld=no |
3748 | + ;; |
3749 | +esac]) |
3750 | +with_gnu_ld=$lt_cv_prog_gnu_ld |
3751 | +])# _LT_PATH_LD_GNU |
3752 | + |
3753 | + |
3754 | +# _LT_CMD_RELOAD |
3755 | +# -------------- |
3756 | +# find reload flag for linker |
3757 | +# -- PORTME Some linkers may need a different reload flag. |
3758 | +m4_defun([_LT_CMD_RELOAD], |
3759 | +[AC_CACHE_CHECK([for $LD option to reload object files], |
3760 | + lt_cv_ld_reload_flag, |
3761 | + [lt_cv_ld_reload_flag='-r']) |
3762 | +reload_flag=$lt_cv_ld_reload_flag |
3763 | +case $reload_flag in |
3764 | +"" | " "*) ;; |
3765 | +*) reload_flag=" $reload_flag" ;; |
3766 | +esac |
3767 | +reload_cmds='$LD$reload_flag -o $output$reload_objs' |
3768 | +case $host_os in |
3769 | + darwin*) |
3770 | + if test "$GCC" = yes; then |
3771 | + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' |
3772 | + else |
3773 | + reload_cmds='$LD$reload_flag -o $output$reload_objs' |
3774 | + fi |
3775 | + ;; |
3776 | +esac |
3777 | +_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl |
3778 | +_LT_DECL([], [reload_cmds], [2])dnl |
3779 | +])# _LT_CMD_RELOAD |
3780 | + |
3781 | + |
3782 | +# _LT_CHECK_MAGIC_METHOD |
3783 | +# ---------------------- |
3784 | +# how to check for library dependencies |
3785 | +# -- PORTME fill in with the dynamic library characteristics |
3786 | +m4_defun([_LT_CHECK_MAGIC_METHOD], |
3787 | +[m4_require([_LT_DECL_EGREP]) |
3788 | +m4_require([_LT_DECL_OBJDUMP]) |
3789 | +AC_CACHE_CHECK([how to recognize dependent libraries], |
3790 | +lt_cv_deplibs_check_method, |
3791 | +[lt_cv_file_magic_cmd='$MAGIC_CMD' |
3792 | +lt_cv_file_magic_test_file= |
3793 | +lt_cv_deplibs_check_method='unknown' |
3794 | +# Need to set the preceding variable on all platforms that support |
3795 | +# interlibrary dependencies. |
3796 | +# 'none' -- dependencies not supported. |
3797 | +# `unknown' -- same as none, but documents that we really don't know. |
3798 | +# 'pass_all' -- all dependencies passed with no checks. |
3799 | +# 'test_compile' -- check by making test program. |
3800 | +# 'file_magic [[regex]]' -- check by looking for files in library path |
3801 | +# which responds to the $file_magic_cmd with a given extended regex. |
3802 | +# If you have `file' or equivalent on your system and you're not sure |
3803 | +# whether `pass_all' will *always* work, you probably want this one. |
3804 | + |
3805 | +case $host_os in |
3806 | +aix[[4-9]]*) |
3807 | + lt_cv_deplibs_check_method=pass_all |
3808 | + ;; |
3809 | + |
3810 | +beos*) |
3811 | + lt_cv_deplibs_check_method=pass_all |
3812 | + ;; |
3813 | + |
3814 | +bsdi[[45]]*) |
3815 | + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' |
3816 | + lt_cv_file_magic_cmd='/usr/bin/file -L' |
3817 | + lt_cv_file_magic_test_file=/shlib/libc.so |
3818 | + ;; |
3819 | + |
3820 | +cygwin*) |
3821 | + # func_win32_libid is a shell function defined in ltmain.sh |
3822 | + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' |
3823 | + lt_cv_file_magic_cmd='func_win32_libid' |
3824 | + ;; |
3825 | + |
3826 | +mingw* | pw32*) |
3827 | + # Base MSYS/MinGW do not provide the 'file' command needed by |
3828 | + # func_win32_libid shell function, so use a weaker test based on 'objdump', |
3829 | + # unless we find 'file', for example because we are cross-compiling. |
3830 | + if ( file / ) >/dev/null 2>&1; then |
3831 | + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' |
3832 | + lt_cv_file_magic_cmd='func_win32_libid' |
3833 | + else |
3834 | + lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' |
3835 | + lt_cv_file_magic_cmd='$OBJDUMP -f' |
3836 | + fi |
3837 | + ;; |
3838 | + |
3839 | +cegcc) |
3840 | + # use the weaker test based on 'objdump'. See mingw*. |
3841 | + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' |
3842 | + lt_cv_file_magic_cmd='$OBJDUMP -f' |
3843 | + ;; |
3844 | + |
3845 | +darwin* | rhapsody*) |
3846 | + lt_cv_deplibs_check_method=pass_all |
3847 | + ;; |
3848 | + |
3849 | +freebsd* | dragonfly*) |
3850 | + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then |
3851 | + case $host_cpu in |
3852 | + i*86 ) |
3853 | + # Not sure whether the presence of OpenBSD here was a mistake. |
3854 | + # Let's accept both of them until this is cleared up. |
3855 | + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' |
3856 | + lt_cv_file_magic_cmd=/usr/bin/file |
3857 | + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` |
3858 | + ;; |
3859 | + esac |
3860 | + else |
3861 | + lt_cv_deplibs_check_method=pass_all |
3862 | + fi |
3863 | + ;; |
3864 | + |
3865 | +gnu*) |
3866 | + lt_cv_deplibs_check_method=pass_all |
3867 | + ;; |
3868 | + |
3869 | +hpux10.20* | hpux11*) |
3870 | + lt_cv_file_magic_cmd=/usr/bin/file |
3871 | + case $host_cpu in |
3872 | + ia64*) |
3873 | + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' |
3874 | + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so |
3875 | + ;; |
3876 | + hppa*64*) |
3877 | + [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] |
3878 | + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl |
3879 | + ;; |
3880 | + *) |
3881 | + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' |
3882 | + lt_cv_file_magic_test_file=/usr/lib/libc.sl |
3883 | + ;; |
3884 | + esac |
3885 | + ;; |
3886 | + |
3887 | +interix[[3-9]]*) |
3888 | + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here |
3889 | + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' |
3890 | + ;; |
3891 | + |
3892 | +irix5* | irix6* | nonstopux*) |
3893 | + case $LD in |
3894 | + *-32|*"-32 ") libmagic=32-bit;; |
3895 | + *-n32|*"-n32 ") libmagic=N32;; |
3896 | + *-64|*"-64 ") libmagic=64-bit;; |
3897 | + *) libmagic=never-match;; |
3898 | + esac |
3899 | + lt_cv_deplibs_check_method=pass_all |
3900 | + ;; |
3901 | + |
3902 | +# This must be Linux ELF. |
3903 | +linux* | k*bsd*-gnu | kopensolaris*-gnu) |
3904 | + lt_cv_deplibs_check_method=pass_all |
3905 | + ;; |
3906 | + |
3907 | +netbsd* | netbsdelf*-gnu) |
3908 | + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then |
3909 | + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' |
3910 | + else |
3911 | + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' |
3912 | + fi |
3913 | + ;; |
3914 | + |
3915 | +newos6*) |
3916 | + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' |
3917 | + lt_cv_file_magic_cmd=/usr/bin/file |
3918 | + lt_cv_file_magic_test_file=/usr/lib/libnls.so |
3919 | + ;; |
3920 | + |
3921 | +*nto* | *qnx*) |
3922 | + lt_cv_deplibs_check_method=pass_all |
3923 | + ;; |
3924 | + |
3925 | +openbsd*) |
3926 | + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then |
3927 | + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' |
3928 | + else |
3929 | + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' |
3930 | + fi |
3931 | + ;; |
3932 | + |
3933 | +osf3* | osf4* | osf5*) |
3934 | + lt_cv_deplibs_check_method=pass_all |
3935 | + ;; |
3936 | + |
3937 | +rdos*) |
3938 | + lt_cv_deplibs_check_method=pass_all |
3939 | + ;; |
3940 | + |
3941 | +solaris*) |
3942 | + lt_cv_deplibs_check_method=pass_all |
3943 | + ;; |
3944 | + |
3945 | +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) |
3946 | + lt_cv_deplibs_check_method=pass_all |
3947 | + ;; |
3948 | + |
3949 | +sysv4 | sysv4.3*) |
3950 | + case $host_vendor in |
3951 | + motorola) |
3952 | + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' |
3953 | + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` |
3954 | + ;; |
3955 | + ncr) |
3956 | + lt_cv_deplibs_check_method=pass_all |
3957 | + ;; |
3958 | + sequent) |
3959 | + lt_cv_file_magic_cmd='/bin/file' |
3960 | + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' |
3961 | + ;; |
3962 | + sni) |
3963 | + lt_cv_file_magic_cmd='/bin/file' |
3964 | + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" |
3965 | + lt_cv_file_magic_test_file=/lib/libc.so |
3966 | + ;; |
3967 | + siemens) |
3968 | + lt_cv_deplibs_check_method=pass_all |
3969 | + ;; |
3970 | + pc) |
3971 | + lt_cv_deplibs_check_method=pass_all |
3972 | + ;; |
3973 | + esac |
3974 | + ;; |
3975 | + |
3976 | +tpf*) |
3977 | + lt_cv_deplibs_check_method=pass_all |
3978 | + ;; |
3979 | +esac |
3980 | +]) |
3981 | +file_magic_cmd=$lt_cv_file_magic_cmd |
3982 | +deplibs_check_method=$lt_cv_deplibs_check_method |
3983 | +test -z "$deplibs_check_method" && deplibs_check_method=unknown |
3984 | + |
3985 | +_LT_DECL([], [deplibs_check_method], [1], |
3986 | + [Method to check whether dependent libraries are shared objects]) |
3987 | +_LT_DECL([], [file_magic_cmd], [1], |
3988 | + [Command to use when deplibs_check_method == "file_magic"]) |
3989 | +])# _LT_CHECK_MAGIC_METHOD |
3990 | + |
3991 | + |
3992 | +# LT_PATH_NM |
3993 | +# ---------- |
3994 | +# find the pathname to a BSD- or MS-compatible name lister |
3995 | +AC_DEFUN([LT_PATH_NM], |
3996 | +[AC_REQUIRE([AC_PROG_CC])dnl |
3997 | +AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, |
3998 | +[if test -n "$NM"; then |
3999 | + # Let the user override the test. |
4000 | + lt_cv_path_NM="$NM" |
4001 | +else |
4002 | + lt_nm_to_check="${ac_tool_prefix}nm" |
4003 | + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then |
4004 | + lt_nm_to_check="$lt_nm_to_check nm" |
4005 | + fi |
4006 | + for lt_tmp_nm in $lt_nm_to_check; do |
4007 | + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR |
4008 | + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do |
4009 | + IFS="$lt_save_ifs" |
4010 | + test -z "$ac_dir" && ac_dir=. |
4011 | + tmp_nm="$ac_dir/$lt_tmp_nm" |
4012 | + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then |
4013 | + # Check to see if the nm accepts a BSD-compat flag. |
4014 | + # Adding the `sed 1q' prevents false positives on HP-UX, which says: |
4015 | + # nm: unknown option "B" ignored |
4016 | + # Tru64's nm complains that /dev/null is an invalid object file |
4017 | + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in |
4018 | + */dev/null* | *'Invalid file or object type'*) |
4019 | + lt_cv_path_NM="$tmp_nm -B" |
4020 | + break |
4021 | + ;; |
4022 | + *) |
4023 | + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in |
4024 | + */dev/null*) |
4025 | + lt_cv_path_NM="$tmp_nm -p" |
4026 | + break |
4027 | + ;; |
4028 | + *) |
4029 | + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but |
4030 | + continue # so that we can try to find one that supports BSD flags |
4031 | + ;; |
4032 | + esac |
4033 | + ;; |
4034 | + esac |
4035 | + fi |
4036 | + done |
4037 | + IFS="$lt_save_ifs" |
4038 | + done |
4039 | + : ${lt_cv_path_NM=no} |
4040 | +fi]) |
4041 | +if test "$lt_cv_path_NM" != "no"; then |
4042 | + NM="$lt_cv_path_NM" |
4043 | +else |
4044 | + # Didn't find any BSD compatible name lister, look for dumpbin. |
4045 | + AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :) |
4046 | + AC_SUBST([DUMPBIN]) |
4047 | + if test "$DUMPBIN" != ":"; then |
4048 | + NM="$DUMPBIN" |
4049 | + fi |
4050 | +fi |
4051 | +test -z "$NM" && NM=nm |
4052 | +AC_SUBST([NM]) |
4053 | +_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl |
4054 | + |
4055 | +AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], |
4056 | + [lt_cv_nm_interface="BSD nm" |
4057 | + echo "int some_variable = 0;" > conftest.$ac_ext |
4058 | + (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD) |
4059 | + (eval "$ac_compile" 2>conftest.err) |
4060 | + cat conftest.err >&AS_MESSAGE_LOG_FD |
4061 | + (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) |
4062 | + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) |
4063 | + cat conftest.err >&AS_MESSAGE_LOG_FD |
4064 | + (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD) |
4065 | + cat conftest.out >&AS_MESSAGE_LOG_FD |
4066 | + if $GREP 'External.*some_variable' conftest.out > /dev/null; then |
4067 | + lt_cv_nm_interface="MS dumpbin" |
4068 | + fi |
4069 | + rm -f conftest*]) |
4070 | +])# LT_PATH_NM |
4071 | + |
4072 | +# Old names: |
4073 | +AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) |
4074 | +AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) |
4075 | +dnl aclocal-1.4 backwards compatibility: |
4076 | +dnl AC_DEFUN([AM_PROG_NM], []) |
4077 | +dnl AC_DEFUN([AC_PROG_NM], []) |
4078 | + |
4079 | + |
4080 | +# LT_LIB_M |
4081 | +# -------- |
4082 | +# check for math library |
4083 | +AC_DEFUN([LT_LIB_M], |
4084 | +[AC_REQUIRE([AC_CANONICAL_HOST])dnl |
4085 | +LIBM= |
4086 | +case $host in |
4087 | +*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) |
4088 | + # These system don't have libm, or don't need it |
4089 | + ;; |
4090 | +*-ncr-sysv4.3*) |
4091 | + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") |
4092 | + AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") |
4093 | + ;; |
4094 | +*) |
4095 | + AC_CHECK_LIB(m, cos, LIBM="-lm") |
4096 | + ;; |
4097 | +esac |
4098 | +AC_SUBST([LIBM]) |
4099 | +])# LT_LIB_M |
4100 | + |
4101 | +# Old name: |
4102 | +AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) |
4103 | +dnl aclocal-1.4 backwards compatibility: |
4104 | +dnl AC_DEFUN([AC_CHECK_LIBM], []) |
4105 | + |
4106 | + |
4107 | +# _LT_COMPILER_NO_RTTI([TAGNAME]) |
4108 | +# ------------------------------- |
4109 | +m4_defun([_LT_COMPILER_NO_RTTI], |
4110 | +[m4_require([_LT_TAG_COMPILER])dnl |
4111 | + |
4112 | +_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= |
4113 | + |
4114 | +if test "$GCC" = yes; then |
4115 | + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' |
4116 | + |
4117 | + _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], |
4118 | + lt_cv_prog_compiler_rtti_exceptions, |
4119 | + [-fno-rtti -fno-exceptions], [], |
4120 | + [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) |
4121 | +fi |
4122 | +_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], |
4123 | + [Compiler flag to turn off builtin functions]) |
4124 | +])# _LT_COMPILER_NO_RTTI |
4125 | + |
4126 | + |
4127 | +# _LT_CMD_GLOBAL_SYMBOLS |
4128 | +# ---------------------- |
4129 | +m4_defun([_LT_CMD_GLOBAL_SYMBOLS], |
4130 | +[AC_REQUIRE([AC_CANONICAL_HOST])dnl |
4131 | +AC_REQUIRE([AC_PROG_CC])dnl |
4132 | +AC_REQUIRE([LT_PATH_NM])dnl |
4133 | +AC_REQUIRE([LT_PATH_LD])dnl |
4134 | +m4_require([_LT_DECL_SED])dnl |
4135 | +m4_require([_LT_DECL_EGREP])dnl |
4136 | +m4_require([_LT_TAG_COMPILER])dnl |
4137 | + |
4138 | +# Check for command to grab the raw symbol name followed by C symbol from nm. |
4139 | +AC_MSG_CHECKING([command to parse $NM output from $compiler object]) |
4140 | +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], |
4141 | +[ |
4142 | +# These are sane defaults that work on at least a few old systems. |
4143 | +# [They come from Ultrix. What could be older than Ultrix?!! ;)] |
4144 | + |
4145 | +# Character class describing NM global symbol codes. |
4146 | +symcode='[[BCDEGRST]]' |
4147 | + |
4148 | +# Regexp to match symbols that can be accessed directly from C. |
4149 | +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' |
4150 | + |
4151 | +# Define system-specific variables. |
4152 | +case $host_os in |
4153 | +aix*) |
4154 | + symcode='[[BCDT]]' |
4155 | + ;; |
4156 | +cygwin* | mingw* | pw32* | cegcc*) |
4157 | + symcode='[[ABCDGISTW]]' |
4158 | + ;; |
4159 | +hpux*) |
4160 | + if test "$host_cpu" = ia64; then |
4161 | + symcode='[[ABCDEGRST]]' |
4162 | + fi |
4163 | + ;; |
4164 | +irix* | nonstopux*) |
4165 | + symcode='[[BCDEGRST]]' |
4166 | + ;; |
4167 | +osf*) |
4168 | + symcode='[[BCDEGQRST]]' |
4169 | + ;; |
4170 | +solaris*) |
4171 | + symcode='[[BDRT]]' |
4172 | + ;; |
4173 | +sco3.2v5*) |
4174 | + symcode='[[DT]]' |
4175 | + ;; |
4176 | +sysv4.2uw2*) |
4177 | + symcode='[[DT]]' |
4178 | + ;; |
4179 | +sysv5* | sco5v6* | unixware* | OpenUNIX*) |
4180 | + symcode='[[ABDT]]' |
4181 | + ;; |
4182 | +sysv4) |
4183 | + symcode='[[DFNSTU]]' |
4184 | + ;; |
4185 | +esac |
4186 | + |
4187 | +# If we're using GNU nm, then use its standard symbol codes. |
4188 | +case `$NM -V 2>&1` in |
4189 | +*GNU* | *'with BFD'*) |
4190 | + symcode='[[ABCDGIRSTW]]' ;; |
4191 | +esac |
4192 | + |
4193 | +# Transform an extracted symbol line into a proper C declaration. |
4194 | +# Some systems (esp. on ia64) link data and code symbols differently, |
4195 | +# so use this general approach. |
4196 | +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" |
4197 | + |
4198 | +# Transform an extracted symbol line into symbol name and symbol address |
4199 | +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" |
4200 | +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" |
4201 | + |
4202 | +# Handle CRLF in mingw tool chain |
4203 | +opt_cr= |
4204 | +case $build_os in |
4205 | +mingw*) |
4206 | + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp |
4207 | + ;; |
4208 | +esac |
4209 | + |
4210 | +# Try without a prefix underscore, then with it. |
4211 | +for ac_symprfx in "" "_"; do |
4212 | + |
4213 | + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. |
4214 | + symxfrm="\\1 $ac_symprfx\\2 \\2" |
4215 | + |
4216 | + # Write the raw and C identifiers. |
4217 | + if test "$lt_cv_nm_interface" = "MS dumpbin"; then |
4218 | + # Fake it for dumpbin and say T for any non-static function |
4219 | + # and D for any global variable. |
4220 | + # Also find C++ and __fastcall symbols from MSVC++, |
4221 | + # which start with @ or ?. |
4222 | + lt_cv_sys_global_symbol_pipe="$AWK ['"\ |
4223 | +" {last_section=section; section=\$ 3};"\ |
4224 | +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ |
4225 | +" \$ 0!~/External *\|/{next};"\ |
4226 | +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ |
4227 | +" {if(hide[section]) next};"\ |
4228 | +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ |
4229 | +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ |
4230 | +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ |
4231 | +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ |
4232 | +" ' prfx=^$ac_symprfx]" |
4233 | + else |
4234 | + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" |
4235 | + fi |
4236 | + |
4237 | + # Check to see that the pipe works correctly. |
4238 | + pipe_works=no |
4239 | + |
4240 | + rm -f conftest* |
4241 | + cat > conftest.$ac_ext <<_LT_EOF |
4242 | +#ifdef __cplusplus |
4243 | +extern "C" { |
4244 | +#endif |
4245 | +char nm_test_var; |
4246 | +void nm_test_func(void); |
4247 | +void nm_test_func(void){} |
4248 | +#ifdef __cplusplus |
4249 | +} |
4250 | +#endif |
4251 | +int main(){nm_test_var='a';nm_test_func();return(0);} |
4252 | +_LT_EOF |
4253 | + |
4254 | + if AC_TRY_EVAL(ac_compile); then |
4255 | + # Now try to grab the symbols. |
4256 | + nlist=conftest.nm |
4257 | + if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then |
4258 | + # Try sorting and uniquifying the output. |
4259 | + if sort "$nlist" | uniq > "$nlist"T; then |
4260 | + mv -f "$nlist"T "$nlist" |
4261 | + else |
4262 | + rm -f "$nlist"T |
4263 | + fi |
4264 | + |
4265 | + # Make sure that we snagged all the symbols we need. |
4266 | + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then |
4267 | + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then |
4268 | + cat <<_LT_EOF > conftest.$ac_ext |
4269 | +#ifdef __cplusplus |
4270 | +extern "C" { |
4271 | +#endif |
4272 | + |
4273 | +_LT_EOF |
4274 | + # Now generate the symbol file. |
4275 | + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' |
4276 | + |
4277 | + cat <<_LT_EOF >> conftest.$ac_ext |
4278 | + |
4279 | +/* The mapping between symbol names and symbols. */ |
4280 | +const struct { |
4281 | + const char *name; |
4282 | + void *address; |
4283 | +} |
4284 | +lt__PROGRAM__LTX_preloaded_symbols[[]] = |
4285 | +{ |
4286 | + { "@PROGRAM@", (void *) 0 }, |
4287 | +_LT_EOF |
4288 | + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext |
4289 | + cat <<\_LT_EOF >> conftest.$ac_ext |
4290 | + {0, (void *) 0} |
4291 | +}; |
4292 | + |
4293 | +/* This works around a problem in FreeBSD linker */ |
4294 | +#ifdef FREEBSD_WORKAROUND |
4295 | +static const void *lt_preloaded_setup() { |
4296 | + return lt__PROGRAM__LTX_preloaded_symbols; |
4297 | +} |
4298 | +#endif |
4299 | + |
4300 | +#ifdef __cplusplus |
4301 | +} |
4302 | +#endif |
4303 | +_LT_EOF |
4304 | + # Now try linking the two files. |
4305 | + mv conftest.$ac_objext conftstm.$ac_objext |
4306 | + lt_save_LIBS="$LIBS" |
4307 | + lt_save_CFLAGS="$CFLAGS" |
4308 | + LIBS="conftstm.$ac_objext" |
4309 | + CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" |
4310 | + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then |
4311 | + pipe_works=yes |
4312 | + fi |
4313 | + LIBS="$lt_save_LIBS" |
4314 | + CFLAGS="$lt_save_CFLAGS" |
4315 | + else |
4316 | + echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD |
4317 | + fi |
4318 | + else |
4319 | + echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD |
4320 | + fi |
4321 | + else |
4322 | + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD |
4323 | + fi |
4324 | + else |
4325 | + echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD |
4326 | + cat conftest.$ac_ext >&5 |
4327 | + fi |
4328 | + rm -rf conftest* conftst* |
4329 | + |
4330 | + # Do not use the global_symbol_pipe unless it works. |
4331 | + if test "$pipe_works" = yes; then |
4332 | + break |
4333 | + else |
4334 | + lt_cv_sys_global_symbol_pipe= |
4335 | + fi |
4336 | +done |
4337 | +]) |
4338 | +if test -z "$lt_cv_sys_global_symbol_pipe"; then |
4339 | + lt_cv_sys_global_symbol_to_cdecl= |
4340 | +fi |
4341 | +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then |
4342 | + AC_MSG_RESULT(failed) |
4343 | +else |
4344 | + AC_MSG_RESULT(ok) |
4345 | +fi |
4346 | + |
4347 | +_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], |
4348 | + [Take the output of nm and produce a listing of raw symbols and C names]) |
4349 | +_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], |
4350 | + [Transform the output of nm in a proper C declaration]) |
4351 | +_LT_DECL([global_symbol_to_c_name_address], |
4352 | + [lt_cv_sys_global_symbol_to_c_name_address], [1], |
4353 | + [Transform the output of nm in a C name address pair]) |
4354 | +_LT_DECL([global_symbol_to_c_name_address_lib_prefix], |
4355 | + [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], |
4356 | + [Transform the output of nm in a C name address pair when lib prefix is needed]) |
4357 | +]) # _LT_CMD_GLOBAL_SYMBOLS |
4358 | + |
4359 | + |
4360 | +# _LT_COMPILER_PIC([TAGNAME]) |
4361 | +# --------------------------- |
4362 | +m4_defun([_LT_COMPILER_PIC], |
4363 | +[m4_require([_LT_TAG_COMPILER])dnl |
4364 | +_LT_TAGVAR(lt_prog_compiler_wl, $1)= |
4365 | +_LT_TAGVAR(lt_prog_compiler_pic, $1)= |
4366 | +_LT_TAGVAR(lt_prog_compiler_static, $1)= |
4367 | + |
4368 | +AC_MSG_CHECKING([for $compiler option to produce PIC]) |
4369 | +m4_if([$1], [CXX], [ |
4370 | + # C++ specific cases for pic, static, wl, etc. |
4371 | + if test "$GXX" = yes; then |
4372 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4373 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' |
4374 | + |
4375 | + case $host_os in |
4376 | + aix*) |
4377 | + # All AIX code is PIC. |
4378 | + if test "$host_cpu" = ia64; then |
4379 | + # AIX 5 now supports IA64 processor |
4380 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4381 | + fi |
4382 | + ;; |
4383 | + |
4384 | + amigaos*) |
4385 | + case $host_cpu in |
4386 | + powerpc) |
4387 | + # see comment about AmigaOS4 .so support |
4388 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4389 | + ;; |
4390 | + m68k) |
4391 | + # FIXME: we need at least 68020 code to build shared libraries, but |
4392 | + # adding the `-m68020' flag to GCC prevents building anything better, |
4393 | + # like `-m68040'. |
4394 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' |
4395 | + ;; |
4396 | + esac |
4397 | + ;; |
4398 | + |
4399 | + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) |
4400 | + # PIC is the default for these OSes. |
4401 | + ;; |
4402 | + mingw* | cygwin* | os2* | pw32* | cegcc*) |
4403 | + # This hack is so that the source file can tell whether it is being |
4404 | + # built for inclusion in a dll (and should export symbols for example). |
4405 | + # Although the cygwin gcc ignores -fPIC, still need this for old-style |
4406 | + # (--disable-auto-import) libraries |
4407 | + m4_if([$1], [GCJ], [], |
4408 | + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) |
4409 | + ;; |
4410 | + darwin* | rhapsody*) |
4411 | + # PIC is the default on this platform |
4412 | + # Common symbols not allowed in MH_DYLIB files |
4413 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' |
4414 | + ;; |
4415 | + *djgpp*) |
4416 | + # DJGPP does not support shared libraries at all |
4417 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)= |
4418 | + ;; |
4419 | + interix[[3-9]]*) |
4420 | + # Interix 3.x gcc -fpic/-fPIC options generate broken code. |
4421 | + # Instead, we relocate shared libraries at runtime. |
4422 | + ;; |
4423 | + sysv4*MP*) |
4424 | + if test -d /usr/nec; then |
4425 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic |
4426 | + fi |
4427 | + ;; |
4428 | + hpux*) |
4429 | + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit |
4430 | + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag |
4431 | + # sets the default TLS model and affects inlining. |
4432 | + case $host_cpu in |
4433 | + hppa*64*) |
4434 | + ;; |
4435 | + *) |
4436 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4437 | + ;; |
4438 | + esac |
4439 | + ;; |
4440 | + *qnx* | *nto*) |
4441 | + # QNX uses GNU C++, but need to define -shared option too, otherwise |
4442 | + # it will coredump. |
4443 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' |
4444 | + ;; |
4445 | + *) |
4446 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4447 | + ;; |
4448 | + esac |
4449 | + else |
4450 | + case $host_os in |
4451 | + aix[[4-9]]*) |
4452 | + # All AIX code is PIC. |
4453 | + if test "$host_cpu" = ia64; then |
4454 | + # AIX 5 now supports IA64 processor |
4455 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4456 | + else |
4457 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' |
4458 | + fi |
4459 | + ;; |
4460 | + chorus*) |
4461 | + case $cc_basename in |
4462 | + cxch68*) |
4463 | + # Green Hills C++ Compiler |
4464 | + # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" |
4465 | + ;; |
4466 | + esac |
4467 | + ;; |
4468 | + dgux*) |
4469 | + case $cc_basename in |
4470 | + ec++*) |
4471 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4472 | + ;; |
4473 | + ghcx*) |
4474 | + # Green Hills C++ Compiler |
4475 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' |
4476 | + ;; |
4477 | + *) |
4478 | + ;; |
4479 | + esac |
4480 | + ;; |
4481 | + freebsd* | dragonfly*) |
4482 | + # FreeBSD uses GNU C++ |
4483 | + ;; |
4484 | + hpux9* | hpux10* | hpux11*) |
4485 | + case $cc_basename in |
4486 | + CC*) |
4487 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4488 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' |
4489 | + if test "$host_cpu" != ia64; then |
4490 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' |
4491 | + fi |
4492 | + ;; |
4493 | + aCC*) |
4494 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4495 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' |
4496 | + case $host_cpu in |
4497 | + hppa*64*|ia64*) |
4498 | + # +Z the default |
4499 | + ;; |
4500 | + *) |
4501 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' |
4502 | + ;; |
4503 | + esac |
4504 | + ;; |
4505 | + *) |
4506 | + ;; |
4507 | + esac |
4508 | + ;; |
4509 | + interix*) |
4510 | + # This is c89, which is MS Visual C++ (no shared libs) |
4511 | + # Anyone wants to do a port? |
4512 | + ;; |
4513 | + irix5* | irix6* | nonstopux*) |
4514 | + case $cc_basename in |
4515 | + CC*) |
4516 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4517 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4518 | + # CC pic flag -KPIC is the default. |
4519 | + ;; |
4520 | + *) |
4521 | + ;; |
4522 | + esac |
4523 | + ;; |
4524 | + linux* | k*bsd*-gnu | kopensolaris*-gnu) |
4525 | + case $cc_basename in |
4526 | + KCC*) |
4527 | + # KAI C++ Compiler |
4528 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' |
4529 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4530 | + ;; |
4531 | + ecpc* ) |
4532 | + # old Intel C++ for x86_64 which still supported -KPIC. |
4533 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4534 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4535 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' |
4536 | + ;; |
4537 | + icpc* ) |
4538 | + # Intel C++, used to be incompatible with GCC. |
4539 | + # ICC 10 doesn't accept -KPIC any more. |
4540 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4541 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4542 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' |
4543 | + ;; |
4544 | + pgCC* | pgcpp*) |
4545 | + # Portland Group C++ compiler |
4546 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4547 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' |
4548 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4549 | + ;; |
4550 | + cxx*) |
4551 | + # Compaq C++ |
4552 | + # Make sure the PIC flag is empty. It appears that all Alpha |
4553 | + # Linux and Compaq Tru64 Unix objects are PIC. |
4554 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)= |
4555 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4556 | + ;; |
4557 | + xlc* | xlC*) |
4558 | + # IBM XL 8.0 on PPC |
4559 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4560 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' |
4561 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' |
4562 | + ;; |
4563 | + *) |
4564 | + case `$CC -V 2>&1 | sed 5q` in |
4565 | + *Sun\ C*) |
4566 | + # Sun C++ 5.9 |
4567 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4568 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4569 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' |
4570 | + ;; |
4571 | + esac |
4572 | + ;; |
4573 | + esac |
4574 | + ;; |
4575 | + lynxos*) |
4576 | + ;; |
4577 | + m88k*) |
4578 | + ;; |
4579 | + mvs*) |
4580 | + case $cc_basename in |
4581 | + cxx*) |
4582 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' |
4583 | + ;; |
4584 | + *) |
4585 | + ;; |
4586 | + esac |
4587 | + ;; |
4588 | + netbsd* | netbsdelf*-gnu) |
4589 | + ;; |
4590 | + *qnx* | *nto*) |
4591 | + # QNX uses GNU C++, but need to define -shared option too, otherwise |
4592 | + # it will coredump. |
4593 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' |
4594 | + ;; |
4595 | + osf3* | osf4* | osf5*) |
4596 | + case $cc_basename in |
4597 | + KCC*) |
4598 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' |
4599 | + ;; |
4600 | + RCC*) |
4601 | + # Rational C++ 2.4.1 |
4602 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' |
4603 | + ;; |
4604 | + cxx*) |
4605 | + # Digital/Compaq C++ |
4606 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4607 | + # Make sure the PIC flag is empty. It appears that all Alpha |
4608 | + # Linux and Compaq Tru64 Unix objects are PIC. |
4609 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)= |
4610 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4611 | + ;; |
4612 | + *) |
4613 | + ;; |
4614 | + esac |
4615 | + ;; |
4616 | + psos*) |
4617 | + ;; |
4618 | + solaris*) |
4619 | + case $cc_basename in |
4620 | + CC*) |
4621 | + # Sun C++ 4.2, 5.x and Centerline C++ |
4622 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4623 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4624 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' |
4625 | + ;; |
4626 | + gcx*) |
4627 | + # Green Hills C++ Compiler |
4628 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' |
4629 | + ;; |
4630 | + *) |
4631 | + ;; |
4632 | + esac |
4633 | + ;; |
4634 | + sunos4*) |
4635 | + case $cc_basename in |
4636 | + CC*) |
4637 | + # Sun C++ 4.x |
4638 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' |
4639 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4640 | + ;; |
4641 | + lcc*) |
4642 | + # Lucid |
4643 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' |
4644 | + ;; |
4645 | + *) |
4646 | + ;; |
4647 | + esac |
4648 | + ;; |
4649 | + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) |
4650 | + case $cc_basename in |
4651 | + CC*) |
4652 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4653 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4654 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4655 | + ;; |
4656 | + esac |
4657 | + ;; |
4658 | + tandem*) |
4659 | + case $cc_basename in |
4660 | + NCC*) |
4661 | + # NonStop-UX NCC 3.20 |
4662 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4663 | + ;; |
4664 | + *) |
4665 | + ;; |
4666 | + esac |
4667 | + ;; |
4668 | + vxworks*) |
4669 | + ;; |
4670 | + *) |
4671 | + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no |
4672 | + ;; |
4673 | + esac |
4674 | + fi |
4675 | +], |
4676 | +[ |
4677 | + if test "$GCC" = yes; then |
4678 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4679 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' |
4680 | + |
4681 | + case $host_os in |
4682 | + aix*) |
4683 | + # All AIX code is PIC. |
4684 | + if test "$host_cpu" = ia64; then |
4685 | + # AIX 5 now supports IA64 processor |
4686 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4687 | + fi |
4688 | + ;; |
4689 | + |
4690 | + amigaos*) |
4691 | + case $host_cpu in |
4692 | + powerpc) |
4693 | + # see comment about AmigaOS4 .so support |
4694 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4695 | + ;; |
4696 | + m68k) |
4697 | + # FIXME: we need at least 68020 code to build shared libraries, but |
4698 | + # adding the `-m68020' flag to GCC prevents building anything better, |
4699 | + # like `-m68040'. |
4700 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' |
4701 | + ;; |
4702 | + esac |
4703 | + ;; |
4704 | + |
4705 | + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) |
4706 | + # PIC is the default for these OSes. |
4707 | + ;; |
4708 | + |
4709 | + mingw* | cygwin* | pw32* | os2* | cegcc*) |
4710 | + # This hack is so that the source file can tell whether it is being |
4711 | + # built for inclusion in a dll (and should export symbols for example). |
4712 | + # Although the cygwin gcc ignores -fPIC, still need this for old-style |
4713 | + # (--disable-auto-import) libraries |
4714 | + m4_if([$1], [GCJ], [], |
4715 | + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) |
4716 | + ;; |
4717 | + |
4718 | + darwin* | rhapsody*) |
4719 | + # PIC is the default on this platform |
4720 | + # Common symbols not allowed in MH_DYLIB files |
4721 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' |
4722 | + ;; |
4723 | + |
4724 | + hpux*) |
4725 | + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit |
4726 | + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag |
4727 | + # sets the default TLS model and affects inlining. |
4728 | + case $host_cpu in |
4729 | + hppa*64*) |
4730 | + # +Z the default |
4731 | + ;; |
4732 | + *) |
4733 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4734 | + ;; |
4735 | + esac |
4736 | + ;; |
4737 | + |
4738 | + interix[[3-9]]*) |
4739 | + # Interix 3.x gcc -fpic/-fPIC options generate broken code. |
4740 | + # Instead, we relocate shared libraries at runtime. |
4741 | + ;; |
4742 | + |
4743 | + msdosdjgpp*) |
4744 | + # Just because we use GCC doesn't mean we suddenly get shared libraries |
4745 | + # on systems that don't support them. |
4746 | + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no |
4747 | + enable_shared=no |
4748 | + ;; |
4749 | + |
4750 | + *nto* | *qnx*) |
4751 | + # QNX uses GNU C++, but need to define -shared option too, otherwise |
4752 | + # it will coredump. |
4753 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' |
4754 | + ;; |
4755 | + |
4756 | + sysv4*MP*) |
4757 | + if test -d /usr/nec; then |
4758 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic |
4759 | + fi |
4760 | + ;; |
4761 | + |
4762 | + *) |
4763 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4764 | + ;; |
4765 | + esac |
4766 | + else |
4767 | + # PORTME Check for flag to pass linker flags through the system compiler. |
4768 | + case $host_os in |
4769 | + aix*) |
4770 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4771 | + if test "$host_cpu" = ia64; then |
4772 | + # AIX 5 now supports IA64 processor |
4773 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4774 | + else |
4775 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' |
4776 | + fi |
4777 | + ;; |
4778 | + |
4779 | + mingw* | cygwin* | pw32* | os2* | cegcc*) |
4780 | + # This hack is so that the source file can tell whether it is being |
4781 | + # built for inclusion in a dll (and should export symbols for example). |
4782 | + m4_if([$1], [GCJ], [], |
4783 | + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) |
4784 | + ;; |
4785 | + |
4786 | + hpux9* | hpux10* | hpux11*) |
4787 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4788 | + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but |
4789 | + # not for PA HP-UX. |
4790 | + case $host_cpu in |
4791 | + hppa*64*|ia64*) |
4792 | + # +Z the default |
4793 | + ;; |
4794 | + *) |
4795 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' |
4796 | + ;; |
4797 | + esac |
4798 | + # Is there a better lt_prog_compiler_static that works with the bundled CC? |
4799 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' |
4800 | + ;; |
4801 | + |
4802 | + irix5* | irix6* | nonstopux*) |
4803 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4804 | + # PIC (with -KPIC) is the default. |
4805 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4806 | + ;; |
4807 | + |
4808 | + linux* | k*bsd*-gnu | kopensolaris*-gnu) |
4809 | + case $cc_basename in |
4810 | + # old Intel for x86_64 which still supported -KPIC. |
4811 | + ecc*) |
4812 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4813 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4814 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' |
4815 | + ;; |
4816 | + # icc used to be incompatible with GCC. |
4817 | + # ICC 10 doesn't accept -KPIC any more. |
4818 | + icc* | ifort*) |
4819 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4820 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' |
4821 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' |
4822 | + ;; |
4823 | + # Lahey Fortran 8.1. |
4824 | + lf95*) |
4825 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4826 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' |
4827 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' |
4828 | + ;; |
4829 | + pgcc* | pgf77* | pgf90* | pgf95*) |
4830 | + # Portland Group compilers (*not* the Pentium gcc compiler, |
4831 | + # which looks to be a dead project) |
4832 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4833 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' |
4834 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4835 | + ;; |
4836 | + ccc*) |
4837 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4838 | + # All Alpha code is PIC. |
4839 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4840 | + ;; |
4841 | + xl*) |
4842 | + # IBM XL C 8.0/Fortran 10.1 on PPC |
4843 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4844 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' |
4845 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' |
4846 | + ;; |
4847 | + *) |
4848 | + case `$CC -V 2>&1 | sed 5q` in |
4849 | + *Sun\ C*) |
4850 | + # Sun C 5.9 |
4851 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4852 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4853 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4854 | + ;; |
4855 | + *Sun\ F*) |
4856 | + # Sun Fortran 8.3 passes all unrecognized flags to the linker |
4857 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4858 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4859 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='' |
4860 | + ;; |
4861 | + esac |
4862 | + ;; |
4863 | + esac |
4864 | + ;; |
4865 | + |
4866 | + newsos6) |
4867 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4868 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4869 | + ;; |
4870 | + |
4871 | + *nto* | *qnx*) |
4872 | + # QNX uses GNU C++, but need to define -shared option too, otherwise |
4873 | + # it will coredump. |
4874 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' |
4875 | + ;; |
4876 | + |
4877 | + osf3* | osf4* | osf5*) |
4878 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4879 | + # All OSF/1 code is PIC. |
4880 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4881 | + ;; |
4882 | + |
4883 | + rdos*) |
4884 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' |
4885 | + ;; |
4886 | + |
4887 | + solaris*) |
4888 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4889 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4890 | + case $cc_basename in |
4891 | + f77* | f90* | f95*) |
4892 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; |
4893 | + *) |
4894 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; |
4895 | + esac |
4896 | + ;; |
4897 | + |
4898 | + sunos4*) |
4899 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' |
4900 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' |
4901 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4902 | + ;; |
4903 | + |
4904 | + sysv4 | sysv4.2uw2* | sysv4.3*) |
4905 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4906 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4907 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4908 | + ;; |
4909 | + |
4910 | + sysv4*MP*) |
4911 | + if test -d /usr/nec ;then |
4912 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' |
4913 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4914 | + fi |
4915 | + ;; |
4916 | + |
4917 | + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) |
4918 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4919 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' |
4920 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4921 | + ;; |
4922 | + |
4923 | + unicos*) |
4924 | + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' |
4925 | + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no |
4926 | + ;; |
4927 | + |
4928 | + uts4*) |
4929 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' |
4930 | + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' |
4931 | + ;; |
4932 | + |
4933 | + *) |
4934 | + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no |
4935 | + ;; |
4936 | + esac |
4937 | + fi |
4938 | +]) |
4939 | +case $host_os in |
4940 | + # For platforms which do not support PIC, -DPIC is meaningless: |
4941 | + *djgpp*) |
4942 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)= |
4943 | + ;; |
4944 | + *) |
4945 | + _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" |
4946 | + ;; |
4947 | +esac |
4948 | +AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) |
4949 | +_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], |
4950 | + [How to pass a linker flag through the compiler]) |
4951 | + |
4952 | +# |
4953 | +# Check to make sure the PIC flag actually works. |
4954 | +# |
4955 | +if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then |
4956 | + _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], |
4957 | + [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], |
4958 | + [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], |
4959 | + [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in |
4960 | + "" | " "*) ;; |
4961 | + *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; |
4962 | + esac], |
4963 | + [_LT_TAGVAR(lt_prog_compiler_pic, $1)= |
4964 | + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) |
4965 | +fi |
4966 | +_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], |
4967 | + [Additional compiler flags for building library objects]) |
4968 | + |
4969 | +# |
4970 | +# Check to make sure the static flag actually works. |
4971 | +# |
4972 | +wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" |
4973 | +_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], |
4974 | + _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), |
4975 | + $lt_tmp_static_flag, |
4976 | + [], |
4977 | + [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) |
4978 | +_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], |
4979 | + [Compiler flag to prevent dynamic linking]) |
4980 | +])# _LT_COMPILER_PIC |
4981 | + |
4982 | + |
4983 | +# _LT_LINKER_SHLIBS([TAGNAME]) |
4984 | +# ---------------------------- |
4985 | +# See if the linker supports building shared libraries. |
4986 | +m4_defun([_LT_LINKER_SHLIBS], |
4987 | +[AC_REQUIRE([LT_PATH_LD])dnl |
4988 | +AC_REQUIRE([LT_PATH_NM])dnl |
4989 | +m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
4990 | +m4_require([_LT_DECL_EGREP])dnl |
4991 | +m4_require([_LT_DECL_SED])dnl |
4992 | +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl |
4993 | +m4_require([_LT_TAG_COMPILER])dnl |
4994 | +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) |
4995 | +m4_if([$1], [CXX], [ |
4996 | + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' |
4997 | + case $host_os in |
4998 | + aix[[4-9]]*) |
4999 | + # If we're using GNU nm, then we don't want the "-C" option. |
5000 | + # -C means demangle to AIX nm, but means don't demangle with GNU nm |
The diff has been truncated for viewing.