Codebase list gpgme1.0 / cbcc1bb
Import upstream version 1.17.0 Debian Janitor 2 years ago
201 changed file(s) with 100196 addition(s) and 803 deletion(s). Raw diff Collapse all Expand all
0 2022-02-07 Werner Koch <wk@gnupg.org>
1
2 Release 1.17.0.
3 + commit 72bb46b34f5191f672a5356e2f152e6ad9440554
4
5
6 qt: Fix build for older Qt versions.
7 + commit 451a42f0d21c5a402d455c78d63eeaaa139e56cc
8 * lang/qt/src/util.cpp: Include <functional>.
9
10 2022-02-03 Ingo Klöcker <dev@ingo-kloecker.de>
11
12 qt: Add job to import keys given by key ids.
13 + commit ca1c30b6fa29a7a1f18ecda14375b47893a0c1a3
14 * lang/qt/src/receivekeysjob.h, lang/qt/src/qgpgmereceivekeysjob.h,
15 lang/qt/src/qgpgmereceivekeysjob.cpp: New.
16 * lang/qt/src/protocol.h (class Protocol): Add pure virtual member
17 function receiveKeysJob.
18 * lang/qt/src/protocol_p.h (Protocol::receiveKeysJob): Implement it.
19 * lang/qt/src/job.cpp, lang/qt/src/Makefile.am: Update accordingly.
20
21 * lang/qt/tests/run-receivekeysjob.cpp: New.
22 * lang/qt/tests/Makefile.am: Add new test runner.
23
24 qt: Add helper for converting QStringList to vector of strings.
25 + commit ec8d1ee13fce21a1f52b084212827914dfcd0db6
26 * lang/qt/src/util.h, lang/qt/src/util.cpp: New.
27 * lang/qt/src/Makefile.am (qgpgme_sources, private_qgpgme_headers):
28 Add new files.
29
30 cpp: Allow import of keys given by key ids.
31 + commit bbaeeb5b9d5cca99c332cb88c7ae5f14e8745427
32 * lang/cpp/src/context.h (class Context): Add overloads of member
33 functions importKeys and startKeyImport
34 * lang/cpp/src/context.cpp (class Context): ... and implement them.
35
36 cpp: Add internal adapter for passing a vector of strings to gpgme.
37 + commit 3d7810e8d940229435feb8f9811607ee831abf4b
38 * lang/cpp/src/util.h (class StringsToCStrings): New.
39 * lang/cpp/src/util.cpp: New.
40 * lang/cpp/src/Makefile.am: Add new file.
41
42 core: New function gpgme_op_receive_keys.
43 + commit 3c2cff74b535422532e1256ee8177fa9c03eaf18
44 * src/gpgme.h.in (gpgme_op_receive_keys_start, gpgme_op_receive_keys):
45 New.
46 * src/gpgme.def, src/libgpgme.vers: Add them.
47 * src/engine-backend.h (struct engine_ops): Add arg keyids to field
48 'import'.
49 * src/engine.h, src/engine.c (_gpgme_engine_op_import): Add arg keyids.
50 * src/engine.c (_gpgme_engine_op_import): Forward new arg keyids.
51 * src/import.c: (_gpgme_op_import_start, _gpgme_op_import_keys_start):
52 Pass NULL to new arg of _gpgme_op_import_start.
53 (_gpgme_op_receive_keys_start, gpgme_op_receive_keys_start,
54 gpgme_op_receive_keys): New.
55 * src/engine-gpg.c (gpg_import): Add arg keyids. Extend check for
56 valid arguments. Build command line if keyids are given.
57 * src/engine-gpgsm.c (gpgsm_import): Add arg keyids. Return error if
58 keyids is not NULL.
59
60 tests/run-receive-keys.c: New.
61 tests/Makefile.am (noinst_PROGRAMS): Add new test runner.
62
63 2022-01-17 Ingo Klöcker <dev@ingo-kloecker.de>
64
65 qt: Remove superfluous include.
66 + commit ec71eb1d7d9f1156cc48d1c9959b07981ecd16e5
67 * lang/qt/src/importjob.h: Remove include of QByteArray.
68
69 qt: Fix build without installed GpgME++ headers.
70 + commit 9c03bde06be97403a8c392a3befc6c203bcdce6d
71 * lang/qt/src/importjob.h, lang/qt/src/wkdlookupresult.h: Include
72 headers of GpgME++ without "gpgme++/" prefix when building QGpgme.
73 * lang/qt/src/qgpgmeimportjob.cpp, lang/qt/src/qgpgmewkdlookupjob.cpp,
74 lang/qt/src/wkdlookupresult.cpp, lang/qt/tests/t-import.cpp: Include
75 headers of GpgME++ without "gpgme++/" prefix.
76
77 2022-01-13 Ingo Klöcker <dev@ingo-kloecker.de>
78
79 tests: Fix generation of keys without expiration.
80 + commit e16729edcbdf2c35e3729b6d54c21b9b27250326
81 * tests/run-genkey.c (parse_expire_string): Support default expiration
82 and no expiration. Set flag for no expiration.
83 (main): Allow update of flags when generating new key.
84
85 tests: Remove unsupported option --status from usage help.
86 + commit e4625885a851112a15636727388f11146be17f15
87 * tests/run-swdb.c (show_usage): Remove option --status.
88
89 qt: Add job to add existing subkeys to other keys.
90 + commit 4d913a8aa5dad1327bed5987dada89e9d7c5d292
91 * lang/qt/src/addexistingsubkeyjob.h,
92 lang/qt/src/qgpgmeaddexistingsubkeyjob.cpp,
93 lang/qt/src/qgpgmeaddexistingsubkeyjob.h: New.
94 * lang/qt/src/protocol.h (class Protocol): Add pure virtual member
95 function addExistingSubkeyJob.
96 * lang/qt/src/protocol_p.h (Protocol::addExistingSubkeyJob): Implement.
97 * lang/qt/src/job.cpp, lang/qt/src/Makefile.am: Update accordingly.
98
99 * lang/qt/tests/Makefile.am (the_tests, moc_files, noinst_PROGRAMS):
100 Add new test.
101 (t_addexistingsubkey_SOURCES): New.
102 * lang/qt/tests/t-addexistingsubkey.cpp: New.
103 * lang/qt/tests/t-support.h (VERIFY_OR_RETURN_VALUE,
104 COMPARE_OR_RETURN_VALUE, VERIFY_OR_OBJECT, COMPARE_OR_OBJECT,
105 VERIFY_OR_FALSE, COMPARE_OR_FALSE): New.
106 * lang/qt/tests/t-support.h, lang/qt/tests/t-support.cpp
107 (class QQGpgMETest): New member function importSecretKeys.
108
109 qt,tests: Add helper to hook up the test passphrase provider.
110 + commit d308910cdfb31accae7cf790a956eb2f3cc6ae71
111 * lang/qt/tests/t-support.h, lang/qt/tests/t-support.cpp
112 (class QGpgMETest): Add member function hookUpPassphraseProvider.
113 Add member mPassphraseProvider.
114 * lang/qt/tests/t-changeexpiryjob.cpp,
115 lang/qt/tests/t-encrypt.cpp,
116 lang/qt/tests/t-remarks.cpp,
117 lang/qt/tests/t-tofuinfo.cpp,
118 lang/qt/tests/t-trustsignatures.cpp,
119 lang/qt/tests/t-various.cpp: Use new helper.
120
121 qt,tests: Add asyncDone signal to base class of all tests.
122 + commit a54402fc2d1c1364843d3c88b5b07dbb7fc007d1
123 * lang/qt/tests/t-support.h (class QGpgMETest): Add signal asyncDone.
124 * lang/qt/tests/t-changeexpiryjob.cpp,
125 lang/qt/tests/t-encrypt.cpp,
126 lang/qt/tests/t-import.cpp,
127 lang/qt/tests/t-keylist.cpp,
128 lang/qt/tests/t-keylocate.cpp,
129 lang/qt/tests/t-ownertrust.cpp,
130 lang/qt/tests/t-remarks.cpp,
131 lang/qt/tests/t-tofuinfo.cpp,
132 lang/qt/tests/t-trustsignatures.cpp,
133 lang/qt/tests/t-various.cpp,
134 lang/qt/tests/t-wkdlookup.cpp,
135 lang/qt/tests/t-wkspublish.cpp: Remove signal asyncDone from the test
136 classes.
137
138 2022-01-12 Ingo Klöcker <dev@ingo-kloecker.de>
139
140 cpp: Add interactor to add existing subkeys to other keys.
141 + commit a4dcb17486bb42890ffe6453eeb2c6f301dc1fae
142 * lang/cpp/src/gpgaddexistingsubkeyeditinteractor.cpp,
143 lang/cpp/src/gpgaddexistingsubkeyeditinteractor.h: New.
144 * lang/cpp/src/Makefile.am: Add new files.
145
146 2022-01-10 Ingo Klöcker <dev@ingo-kloecker.de>
147
148 core: Return an error for secret key export operations.
149 + commit a527bd7cf58563d07c89bec458c8967ab1b3e60f
150 src/export.c (export_status_handler): Handle "export_keys.secret".
151
152 2022-01-04 Ingo Klöcker <dev@ingo-kloecker.de>
153
154 qt: Add factory function for secret subkey export job.
155 + commit 04723a6e96be77dbc43bf71c54e268424a1823ba
156 * lang/qt/src/protocol.h (class Protocol): Add member function
157 secretSubkeyExportJob.
158 * lang/qt/src/protocol_p.h (Protocol::secretSubkeyExportJob): Implement.
159
160 * lang/qt/tests/run-exportjob.cpp (showUsageAndExitWithCode): Print
161 new option.
162 (createExportJob): Create secret subkey export job if requested.
163 (main): New option --secret-subkey.
164
165 cpp: Allow export of secret subkeys.
166 + commit e5c7fc3e022841be8f68fad8b9b64dd601b89ba7
167 * lang/cpp/src/context.h (enum Context::ExportMode): Add value
168 ExportSecretSubkey.
169 (class Context): Add member functions exportSecretSubkeys and
170 startSecretSubkeyExport.
171 * lang/cpp/src/context.cpp (Context::exportPublicKeys,
172 Context::startPublicKeyExport): Return error if ExportSecretSubkey
173 mode flag is set.
174 (Context::exportSecretSubkeys, Context::startSecretSubkeyExport):
175 Implement.
176
177 qt: Remove obsolete QGpgMESecretKeyExportJob.
178 + commit 88ad37ea96e4645a9e23aac9eae0d8da747559b8
179 * lang/qt/src/Makefile.am: Remove all occurrences of
180 qgpgmesecretkeyexportjob.*.
181 * lang/qt/src/qgpgmesecretkeyexportjob.cpp,
182 lang/qt/src/qgpgmesecretkeyexportjob.h: Remove.
183
184 qt: Use QGpgMEExportJob also for export of secret keys.
185 + commit 4e80563fabfdf1d1c136d65252e5353fdd1e9092
186 * lang/qt/src/protocol.h (Protocol::secretKeyExportJob): Document
187 charset argument as ignored.
188 * lang/qt/src/protocol_p.h (Protocol::secretKeyExportJob): Use
189 QGpgMEExportJob instead of QGpgMESecretKeyExportJob.
190 * lang/qt/src/qgpgmeexportjob.h (class QGpgMEExportJob): Add c'tor
191 taking an export mode. Add member m_exportMode. Rename member m_flags to
192 m_additionalExportModeFlags.
193 (QGpgMEExportJob::~QGpgMEExportJob): Mark as override.
194 * lang/qt/src/qgpgmeexportjob.cpp (QGpgMEExportJob::QGpgMEExportJob):
195 Delegate to new c'tor. Implement new c'tor.
196 (QGpgMEExportJob::~QGpgMEExportJob): Use default.
197 (export_qba): Rename argument flags to mode.
198 (QGpgMEExportJob::start): Pass combination of export mode and additional
199 mode flags to export_qba.
200 (QGpgMEExportJob::setExportFlags): Adapt to renaming of member.
201
202 * lang/qt/tests/run-exportjob.cpp: New.
203
204 cpp: Allow export of secret keys.
205 + commit 3da06d1096ee29d70656f07edcabc3bc4351104e
206 * lang/cpp/src/context.h (class Context): New member functions
207 exportSecretKeys, startSecretKeyExport, exportKeys, startKeyExport.
208 (Context::exportPublicKeys, Context::startPublicKeyExport): Rename
209 argument flags/export_mode to mode.
210 * lang/cpp/src/context.cpp (Context::exportPublicKeys): Return error if
211 ExportSecret mode flag is set. Call exportKeys().
212 (Context::startPublicKeyExport): Return error if
213 ExportSecret mode flag is set. Call startKeyExport().
214 (Context::exportSecretKeys, Context::startSecretKeyExport,
215 Context::exportKeys, Context::startKeyExport): Implement.
216
217 cpp: Mark ExportNoUID flag as obsolete.
218 + commit 4888191014c24d5954685814e06c9ff0ee38739f
219 * lang/cpp/src/context.h (enum Context::ExportMode): Mark value
220 ExportNoUID as obsolete
221
222 core: Add new option --secret-subkey to help texts.
223 + commit 2752e81f892568a9725fdd8d6a997a1cc80d2f88
224 * src/gpgme-tool.c (hlp_export): Add new option.
225 * tests/run-export.c (show_usage): Print new option.
226
227 cpp: Remove obsolete workaround.
228 + commit fa5f1b57cc12f9305d112f11c2c2d95751ed1a25
229 * lang/cpp/src/context.cpp (Context::startKeyListing,
230 Context::exportPublicKeys, Context::startPublicKeyExport): Remove
231 workaround.
232
233 core: New export mode to export secret subkeys.
234 + commit 0e19c4879193ed7fa61ad5d488f237b2b5b5d1d7
235 * src/gpgme.h.in (GPGME_EXPORT_MODE_SECRET_SUBKEY): New.
236 * src/export.c (check_mode): Allow new mode and check for invalid
237 combinations.
238 (export_keys_start): Return error if new mode flag is set.
239 * src/engine-gpg.c (export_common): Implement.
240 * src/gpgme-tool.c (cmd_export): New option --secret-subkey.
241 * tests/run-export.c (main): New option --secret-subkey.
242
243 doc: Remove documentation of obsolete export mode flag.
244 + commit 414bbdd53c380018621a2a5800e9a9c46869a56e
245 * doc/gpgme.texi: Remove GPGME_EXPORT_MODE_NOUID.
246
247 core: Check for unsupported export mode flags.
248 + commit c710af223cc2476d5f4d46c00d8e0521f6c13211
249 src/engine-gpgsm.c (gpgsm_export, gpgsm_export_ext): Return error if an
250 unsupported mode flag is set.
251
252 core: Check for combination of ssh mode with other mode flags.
253 + commit c0581adabe7f5f63c0b96dac449790aa6ac4c291
254 * src/export.c (check_mode): Return error if ssh mode is combined with
255 another mode flag.
256
257 core: Factor out the check for valid export mode flags.
258 + commit 326857511587fa7878757d3884f91bf7eb86771c
259 * src/export.c (check_mode): New.
260 (export_start, export_ext_start): Call check_mode.
261
262 2021-12-22 Ingo Klöcker <dev@ingo-kloecker.de>
263
264 qt: Detect an import error caused by a wrong password.
265 + commit 82f43455e9412d8b4792b35371e0b6704a619d07
266 * lang/qt/src/qgpgmeimportjob.cpp (import_qba): Check import statuses of
267 import result for bad passphrase errors.
268
269 qt,tests: Add test runner for testing the import job.
270 + commit f99451e20fd2f84ac653aa6021a475026a9d4dc9
271 * lang/qt/tests/Makefile.am (run_importjob_SOURCES): New.
272 (noinst_PROGRAMS): Add run-importjob.
273 * lang/qt/tests/run-importjob.cpp: New.
274
275 cpp: Check fpr of import status for NULL.
276 + commit 300776f39165da068757864e9cb3029f06f3be5b
277 * lang/cpp/src/importresult.cpp (GpgME::ImportResult::Private): Check
278 fpr for NULL.
279
280 core: Detect bad passphrase error on certificate import.
281 + commit 305d8668ca724982c50fe4e05315c48a20cc33e5
282 * src/import.c (gpgme_op_import_result): Check fpr for NULL.
283 (parse_error): New.
284 (import_status_handler): Handle error status line.
285
286 * doc/gpgme.texi (gpgme_import_status_t): Mention that fpr can be NULL.
287
288 * tests/gpg/t-import.c (check_result): Check fpr for NULL.
289 * tests/run-threaded.c (delete_impres): Check fpr for NULL.
290
291 2021-12-22 NIIBE Yutaka <gniibe@fsij.org>
292
293 build: Update for newer autoconf.
294 + commit 0636e229d7edfcb0a357ffcce62079488be32495
295 * configure.ac (AC_PREREQ): Require >= 2.69.
296 (AC_CONFIG_HEADERS): Use it instead of AC_CONFIG_HEADER.
297
298 2021-12-15 Ingo Klöcker <dev@ingo-kloecker.de>
299
300 qt: Allow specifying an import filter when importing keys.
301 + commit 619579bb172579d766956b5d1690d18934fd5986
302 * lang/qt/src/importjob.cpp (struct ImportJobPrivate): Add member
303 m_importFilter.
304 * lang/qt/src/importjob.cpp, lang/qt/src/importjob.h (class ImportJob):
305 Add member functions setImportFilter and importFilter.
306 * lang/qt/src/qgpgmeimportjob.cpp (import_qba): Add arg importFilter
307 and adjust the callers. Set import filter context flag.
308
309 * lang/qt/tests/t-import.cpp (ImportTest): Add member function
310 testImportWithImportFilter.
311
312 qt: Avoid test failure when test is run multiple times.
313 + commit 3e81a4a336e093d075f83afe3e1bd26493e64cac
314 * lang/qt/tests/t-import.cpp (ImportTest): Add member tempGpgHome and
315 member function initTestCase.
316 (keyFpr, keyData): Move to ImportTest::testImportWithKeyOrigin.
317
318 qt: Fix erroneous reuse of JobPrivate objects.
319 + commit 3c770013d7233cb0a803251af54c0a2c1fb61e35
320 * lang/qt/src/job.cpp (Job::~Job): Destroy JobPrivate object belonging
321 to destroyed job.
322
323 2021-12-14 Ingo Klöcker <dev@ingo-kloecker.de>
324
325 core: Allow setting import filters when importing keys.
326 + commit d35d44efaf72f90ee4f92af8382c4bcb9982da3f
327 * src/context.h (struct gpgme_context): New field import_filter.
328 * src/engine-backend.h (struct engine_ops): Add arg import_filter to
329 field 'import'.
330 * src/engine-gpg.c (gpg_import): Add arg import_filter and pass option
331 --import-filter with argument value to gpg. Adjust all callers.
332 * src/engine-gpgsm.c (gpgsm_import): Add dummy arg import_filter.
333 * src/gpgme.c (gpgme_release): Free 'import_filter'.
334 (gpgme_set_ctx_flag, gpgme_get_ctx_flag): New flag "import-filter".
335
336 * tests/run-import.c (main): Add option --import-filter.
337
338 qt: Add pattern used for WKD lookup to result.
339 + commit af820811ec7d0818f988cd728d745cede88ab45f
340 * lang/qt/src/qgpgmewkdlookupjob.cpp (run_wkd_get): Change type of
341 arg email.
342 (lookup_keys): Add pattern to result.
343 * lang/qt/src/wkdlookupresult.h (class WKDLookupResult): Add arg
344 pattern to c'tors. Add member function pattern.
345 * lang/qt/src/wkdlookupresult.cpp (class WKDLookupResult::Private):
346 Add field pattern.
347 (WKDLookupResult::WKDLookupResult): Pass pattern to pimpl.
348 (WKDLookupResult::pattern): New.
349
350 * lang/qt/tests/t-wkdlookup.cpp (testWKDLookupAsync, testWKDLookupSync,
351 testLookupWithNoResultAsync): Check pattern.
352
353 core: Set --key-origin option only if supported by gpg.
354 + commit fd680254dae58a6bf6fb83688bf7c849257688a4
355 * src/engine-gpg.c (gpg_import): Do not pass --key-origin option to
356 gpg if gpg is too old.
357
358 qt: Allow setting key origin when importing keys.
359 + commit fd6bec617d8fb6ddcbc622a5d8cf94594a7d5520
360 * lang/qt/src/Makefile.am (qgpgme_sources): Add importjob.cpp.
361 * lang/qt/src/importjob.cpp: New.
362 * lang/qt/src/importjob.h (class ImportJob): Add member functions
363 setKeyOrigin, keyOrigin, keyOriginUrl.
364 * lang/qt/src/qgpgmeimportjob.cpp (originToString): New.
365 (import_qba): Set key origin context flag.
366 (QGpgMEImportJob::start, QGpgMEImportJob::exec): Add options to call
367 of import_qba.
368
369 * lang/qt/tests/Makefile.am (the_tests, moc_files, noinst_PROGRAMS):
370 Add new test.
371 (t_import_SOURCES): New.
372 * lang/qt/tests/t-import.cpp: New.
373
374 qt,tests: Skip WKD lookup tests by default.
375 + commit 3a43d9dc67970db323c3e49eb964d52c4eb3ac6c
376 * lang/qt/tests/t-support.cpp, lang/qt/tests/t-support.h
377 (class QGpgMETest): Add member function doOnlineTests.
378 * lang/qt/tests/t-wkdlookup.cpp (testWKDLookupAsync, testWKDLookupSync,
379 testLookupWithNoResultAsync): Skip tests if online tests are not
380 enabled.
381
382 2021-12-13 Ingo Klöcker <dev@ingo-kloecker.de>
383
384 core: Allow specifiying a key origin when importing keys.
385 + commit 60880adafa93e1a1e8e9fecf03c14d56bbd55345
386 * src/context.h (struct gpgme_context): New field key_origin.
387 * src/engine-backend.h (struct engine_ops): Add arg key_origin to
388 field 'import'.
389 * src/engine-gpg.c (gpg_import): Add arg key_origin and pass option
390 --key-origin with argument value to gpg. Adjust all callers.
391 * src/engine-gpgsm.c (gpgsm_import): Add dummy arg key_origin.
392 * src/gpgme.c (gpgme_release): Free 'key_origin'.
393 (gpgme_set_ctx_flag, gpgme_get_ctx_flag): New flag "key-origin".
394
395 * tests/run-import.c (main): Add option --key-origin.
396 * tests/gpg/t-import.c (main): Set and verify key origin.
397
398 qt: Support WKD lookup without implicit import.
399 + commit ed7e7df2e14feb443e84d87e518ff61b1f7aa6d8
400 * lang/qt/src/Makefile.am (qgpgme_sources): Add qgpgmewkdlookupjob.cpp,
401 wkdlookupresult.cpp.
402 (qgpgme_headers): Add wkdlookupjob.h, wkdlookupresult.h.
403 (camelcase_headers): Add WKDLookupJob, WKDLookupResult.
404 (private_qgpgme_headers): Add qgpgmewkdlookupjob.h.
405 (qgpgme_moc_sources): Add qgpgmewkdlookupjob.moc, wkdlookupjob.moc.
406 * lang/qt/src/job.cpp: Define c'tor and d'tor of WKDLookupJob.
407 * lang/qt/src/protocol.h (Protocol::wkdLookupJob): New.
408 * lang/qt/src/protocol_p.h (Protocol::wkdLookupJob): New.
409 * lang/qt/src/qgpgmewkdlookupjob.cpp, lang/qt/src/qgpgmewkdlookupjob.h,
410 lang/qt/src/wkdlookupjob.h, lang/qt/src/wkdlookupresult.cpp,
411 lang/qt/src/wkdlookupresult.h: New.
412
413 * lang/qt/tests/Makefile.am (EXTRA_DIST): Add final.test.
414 (the_tests): New.
415 (TESTS): Remove all t-*. Add $(the_tests) and final.test.
416 (moc_files): Add t-wkdlookup.moc.
417 (t_wkdlookup_SOURCES): New.
418 (noinst_PROGRAMS): Add t-wkdlookup.
419 * lang/qt/tests/final.test: New.
420 * lang/qt/tests/t-support.h (QTest::toString): New template
421 specialization for std::string.
422 * lang/qt/tests/t-wkdlookup.cpp: New.
423
424 qt: Fix example for using the asynchronous job API.
425 + commit 0e70a2313afbbaaec6859a1edb478587ff82a6b5
426 * lang/qt/src/protocol.h (class Protocol): Fix API documentation.
427
428 2021-12-10 Ingo Klöcker <dev@ingo-kloecker.de>
429
430 cpp,tests: Add test runner for doing a WKD lookup without import.
431 + commit f3177d3ee0a1d30e15f33ff226b5e4c96b7610db
432 * lang/cpp/tests/Makefile.am (run_wkdlookup_SOURCES, programs_unix):
433 New.
434 (noinst_PROGRAMS): Add $(programs_unix).
435 * lang/cpp/tests/run-wkdlookup.cpp: New.
436
437 cpp: Add new supported components to API docs of dirInfo()
438 + commit 5f1ba40116199cd77987c3c2797d600f6df018c2
439 lang/cpp/src/global.h: Update API doc of dirInfo().
440
441 core: Support all components with dirinfo()
442 + commit 0ac3679a74505b782388402b3743ee65c271340f
443 * src/dirinfo.c (WANT_KEYBOXD_NAME, WANT_AGENT_NAME, WANT_SCDAEMON_NAME,
444 WANT_DIRMNGR_NAME, WANT_PINENTRY_NAME): New.
445 (dirinfo): Add fields keyboxd_name, agent_name, scdaemon_name,
446 dirmngr_name, pinentry_name.
447 (parse_output): Support "keyboxd", "gpg-agent", "scdaemon", "dirmngr",
448 "pinentry".
449 (get_gpgconf_item): Return new components.
450
451 tests/t-engine-info.c (main): Add new components to the output.
452
453 2021-12-07 Ingo Klöcker <dev@ingo-kloecker.de>
454
455 cpp: Return engine info for engine used by the context.
456 + commit 0eddc867c31dd7239a1a9c4196bf8dc1372ea4b1
457 lang/cpp/src/context.cpp (Context::engineInfo()): Return engine info
458 for protocol of context.
459
460 cpp: Factor out common code of GpgME::engineInfo() overloads.
461 + commit 1a1e9145877a60632346ae3ab68b1ae9d722a867
462 * lang/cpp/src/context.cpp (get_engine_info, get_static_engine_info):
463 New.
464 (GpgME::engineInfo(GpgME::Protocol), GpgME::engineInfo(GpgME::Engine)):
465 Use get_static_engine_info().
466
467 2021-11-25 Werner Koch <wk@gnupg.org>
468
469 core: Make the gpgconf option parsing of string types more robust.
470 + commit b8b49c11e95fd978a8a2eed23f191d087ab056da
471 * src/engine-gpgconf.c (gpgconf_parse_option): Skip the string
472 indicator if it is not the empty string.
473
474 tests: Silence libtool warning on Windows.
475 + commit 43de18a292b29436783127bd6c275817f0cd86b7
476 * tests/Makefile.am (AM_LDFLAGS): Use --no-fast-install on Windows.
477
478 core: Support dirinfo("socketdir")
479 + commit eb37d6469e722ae5ff187962c216474b5ec476de
480 * src/dirinfo.c (WANT_SOCKETDIR): New.
481 (dirinfo): Add field socketdir.
482 (parse_output): Support "socketdir".
483 (get_gpgconf_item): Return socketdir.
484
485 * tests/t-engine-info.c (main): Add socketdir to the output.
486
487 * src/w32-util.c (_gpgme_create_process_utf8): Fix indentation.
488
489 2021-11-25 NIIBE Yutaka <gniibe@fsij.org>
490
491 posix: Use poll instead, when available, removing use of select.
492 + commit 8148237cb4ae20755c06a44d71761c7030973c3d
493 * configure.ac (HAVE_POLL_H): Add the check.
494 * src/ath.c [!HAVE_POLL_H] (ath_select): Enable conditionally.
495 * src/posix-io.c [HAVE_POLL_H] (_gpgme_io_select_poll): Use poll.
496 * tests/gpg/t-cancel.c [HAVE_POLL_H] (do_select): Use poll.
497 * tests/gpg/t-eventloop.c [HAVE_POLL_H] (do_select): Use poll.
498
499 2021-11-12 NIIBE Yutaka <gniibe@fsij.org>
500
501 gpgme.pc: Fix library dependency and use of includedir, libdir.
502 + commit 4583ab77e5af3f0da5b307a169d07b58dddf652f
503 * src/gpgme.pc.in (Require): Move gpg-error, libassuan to...
504 (Requires.private): ... here.
505 (Cflags): Add -I${includedir}.
506 (Libs): Add -L${libdir}.
507
508 2021-11-12 NIIBE Yutaka <gniibe@fsij.org>
509 Ben Kibbey <bjk@luxsci.net>
510
511 tests: Build using GPG_ERROR_MT_LIBS for thread use.
512 + commit 1cedac2bba246ff411843aaef10ca8ea0a0756cf
513 * tests/gpg/Makefile.am (WITH_THREAD_CPPFLAGS): New.
514 (WITH_THREAD_LDADD): New.
515 (t_thread1_CPPFLAGS, t_thread_keylist_CPPFLAGS)
516 (t_thread_keylist_verify_CPPFLAGS)
517 (t_cancel_CPPFLAGS): Use WITH_THREAD_CPPFLAGS.
518 (t_thread1_LDADD, t_thread_keylist_LDADD)
519 (t_thread_keylist_verify_LDADD)
520 (t_cancel_LDADD): Use WITH_THREAD_LDADD.
521
522 2021-11-11 NIIBE Yutaka <gniibe@fsij.org>
523
524 tests: Use GPG_ERROR_MT_LIBS for a test with threads.
525 + commit 8cd2fe7b3de4abd2331bcb637b7e2c26ce4faa29
526 * tests/Makefile.am (run_threaded_CPPFLAGS): New.
527 (run_threaded_LDADD): Replace GPG_ERROR_LIBS to GPG_ERROR_MT_LIBS.
528
529 2021-11-10 NIIBE Yutaka <gniibe@fsij.org>
530
531 libtool: Link without -flat_namespace for macOS.
532 + commit 50daf3d75d666d34fecc0dbecc31c51a7989eda3
533 * m4/libtool.m4: Not setting 10.0 to MACOSX_DEPLOYMENT_TARGET when not
534 defined. Only specify -flat_namespace to linker for specific
535 (older) versions and hosts.
536
537 2021-09-13 Ingo Klöcker <dev@ingo-kloecker.de>
538
539 qt: Fix build against Qt 5.9.
540 + commit ab9bca09eb869b2013c85fee232f1e62aed925f6
541 * lang/qt/tests/t-keylist.cpp (KeyListTest::testListAllKeysSync):
542 Ensure same type for both arguments of QCOMPARE.
543 * lang/qt/tests/t-various.cpp (TestVarious::testSetExpire):
544 Ensure same type for both arguments of QCOMPARE.
545
546 2021-08-27 Werner Koch <wk@gnupg.org>
547
548 build: Fix make distcheck problem.
549 + commit aaf448b1e81e7421e539ac2deb9dc9d3d1459016
550 * tests/start-stop-agent: Use -f with rm. Also use cat instead of cp.
551
552 2021-08-27 Andre Heinecke <aheinecke@gnupg.org>
553
554 qt: Expect UTF-8 on stderr on Windows.
555 + commit 8fe15462829b5049137b3f631564b72c4f63c5e2
556 * lang/qt/src/threadedjobmixin.cpp (stringFromGpgOutput): Expect
557 UTF-8.
558
559 Add missing files for distribution.
560 + commit bc774104bbf461805f875c2bfd2d02aa6dd0945d
561 * lang/qt/src/Makefile.am (private_qgpgme_headers): Add job_p.h
562 * tests/gpg/Makefile.am (EXTRA_DIST): Add gpg.conf.in
563
564 2021-08-13 NIIBE Yutaka <gniibe@fsij.org>
565
566 core: Use flexible array member if compiler has support.
567 + commit 3c1c98a43413e429459ca7d3615659f8149534b8
568 * configure.ac (AC_C_FLEXIBLE_ARRAY_MEMBER): Add.
569 * src/engine-gpg.c (struct arg_and_data_s): Use FLEXIBLE_ARRAY_MEMBER.
570 (_add_arg): Use offsetof instead of sizeof.
571 (add_data): Likewise.
572
573 2021-08-03 Ingo Klöcker <dev@ingo-kloecker.de>
574
575 core: Fix results returned by gpgme_data_* functions.
576 + commit 7cfc93193d535ec5037e48b86544e1b4dbf949f6
577 src/debug.h (TRACE_SYSRES_OFF_T, _trace_sysres_off_t,
578 TRACE_SYSRES_SSIZE_T, _trace_sysres_ssize_t): New.
579 src/data.c (gpgme_data_read, gpgme_data_write, gpgme_data_seek): Use
580 appropriate new tracing macros instead of casting the results to int.
581
582 2021-07-27 Jiri Kucera <sanczes@gmail.com>
583
584 core: Support closefrom also for glibc.
585 + commit 4b64774b6d13ffa4f59dddf947a97d61bcfa2f2e
586 * src/posix-io.c (_gpgme_io_spawn): Use glibc's closefrom.
587
588 2021-07-08 Ingo Klöcker <dev@ingo-kloecker.de>
589
590 core: Ensure gpg.conf for tests is recreated if necessary.
591 + commit a5662a801fc11a533fb3b1a69a17e119064972a3
592 * tests/gpg/gpg.conf.in: New.
593 * tests/gpg/Makefile.am (gpg.conf): Copy gpg.conf.in instead of using
594 echo to fill gpg.conf.
595
596 Make sure expiration time is interpreted as unsigned number.
597 + commit 6a79e90dedc19877ae1c520fed875b57089a5425
598 * lang/qt/tests/t-various.cpp (testSignKeyWithExpiration): Convert
599 expiration time to uint_least32_t.
600
601 2021-06-29 Ingo Klöcker <dev@ingo-kloecker.de>
602
603 qt: Allow retrieving the default value of a config entry.
604 + commit 12006a782900687a7f0158a3f931528cfc5ff451
605 * lang/qt/src/cryptoconfig.cpp, lang/qt/src/cryptoconfig.h
606 (CryptoConfigEntry::defaultValue): New.
607 * lang/qt/src/qgpgmenewcryptoconfig.cpp,
608 lang/qt/src/qgpgmenewcryptoconfig.h
609 (QGpgMENewCryptoConfigEntry::defaultValue): New.
610 * lang/qt/tests/t-config.cpp (CryptoConfigTest::testDefault()):
611 Add test of CryptoConfigEntry::defaultValue(). Port away from deprecated
612 CryptoConfig::entry overload.
613
614 2021-06-28 Ingo Klöcker <dev@ingo-kloecker.de>
615
616 Update NEWS.
617 + commit d8638ed0aa5bf7f970787155a35d37a4f5d320f8
618 * NEWS: Add changes of ChangeExpiryJob.
619
620 qt: Fix filenames in copyright headers.
621 + commit 9d2b876093c25f604d9efe2775143c8f0361916d
622 * lang/qt/src/qgpgmechangeownertrustjob.h,
623 lang/qt/tests/t-trustsignatures.cpp: Use correct filenames.
624
625 qt: Add test for ChangeExpiryJob.
626 + commit 801acd89b234fcd7226f3fb39ec01634460cfa50
627 * lang/qt/tests/Makefile.am (TESTS, moc_files, noinst_PROGRAMS): Add
628 new test.
629 (t_changeexpiryjob_SOURCES): New.
630 * lang/qt/tests/t-changeexpiryjob.cpp: New.
631
632 qt: Allow changing expiration date of primary key and all subkeys.
633 + commit 144d580607dd0b70bb20542e2f457153b9cc4ecb
634 * lang/qt/src/Makefile.am (qgpgme_sources): Add changeexpiryjob.cpp.
635 * lang/qt/src/changeexpiryjob.cpp: New.
636 * lang/qt/src/changeexpiryjob.h (enum ChangeExpiryJob::Option,
637 typedef ChangeExpiryJob::Options, ChangeExpiryJob::setOptions,
638 ChangeExpiryJob::options): New.
639 * lang/qt/src/qgpgmechangeexpiryjob.cpp (change_expiry): Update the
640 expiration date of primary key and/or some/all subkeys.
641 (QGpgMEChangeExpiryJob::start): Add options to call of change_expiry.
642 (ChangeExpiryJob::start): Moved implementation to changeexpiryjob.cpp.
643
644 qt: Add mechanism for missing d-pointer in Job.
645 + commit 3503816570a19352e4b8a81d1cd0f3a9337b8c55
646 * lang/qt/src/job_p.h: New.
647 * lang/qt/src/job.cpp (typedef JobPrivateHash, d_func, setJobPrivate,
648 getJobPrivate): New.
649
650 2021-06-26 Ingo Klöcker <dev@ingo-kloecker.de>
651
652 qt: Remove superfluous trailing ';'
653 + commit ade95b25ce473a3c9ebcb77b7bd76a2fa6ed2805
654 lang/qt/src/signkeyjob.h (class SignKeyJob): Remove trailing ';' from
655 inline implemented member functions
656
657 core: Fix use-after-free issue in test.
658 + commit 81a33ea5e1b86d586b956e893a5b25c4cd41c969
659 * tests/gpg/t-edit-sign.c (sign_key, verify_key_signature): New.
660 (main): Factored out signing and verifying the result.
661
0662 2021-06-24 Werner Koch <wk@gnupg.org>
1663
2664 Release 1.16.0.
0 Installation Instructions
1 *************************
2
3 Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
4 2006, 2007 Free Software Foundation, Inc.
5
6 This file is free documentation; the Free Software Foundation gives
7 unlimited permission to copy, distribute and modify it.
8
9 Basic Installation
10 ==================
11
12 Briefly, the shell commands `./configure; make; make install' should
13 configure, build, and install this package. The following
14 more-detailed instructions are generic; see the `README' file for
15 instructions specific to this package.
16
17 The `configure' shell script attempts to guess correct values for
18 various system-dependent variables used during compilation. It uses
19 those values to create a `Makefile' in each directory of the package.
20 It may also create one or more `.h' files containing system-dependent
21 definitions. Finally, it creates a shell script `config.status' that
22 you can run in the future to recreate the current configuration, and a
23 file `config.log' containing compiler output (useful mainly for
24 debugging `configure').
25
26 It can also use an optional file (typically called `config.cache'
27 and enabled with `--cache-file=config.cache' or simply `-C') that saves
28 the results of its tests to speed up reconfiguring. Caching is
29 disabled by default to prevent problems with accidental use of stale
30 cache files.
31
32 If you need to do unusual things to compile the package, please try
33 to figure out how `configure' could check whether to do them, and mail
34 diffs or instructions to the address given in the `README' so they can
35 be considered for the next release. If you are using the cache, and at
36 some point `config.cache' contains results you don't want to keep, you
37 may remove or edit it.
38
39 The file `configure.ac' (or `configure.in') is used to create
40 `configure' by a program called `autoconf'. You need `configure.ac' if
41 you want to change it or regenerate `configure' using a newer version
42 of `autoconf'.
43
44 The simplest way to compile this package is:
45
46 1. `cd' to the directory containing the package's source code and type
47 `./configure' to configure the package for your system.
48
49 Running `configure' might take a while. While running, it prints
50 some messages telling which features it is checking for.
51
52 2. Type `make' to compile the package.
53
54 3. Optionally, type `make check' to run any self-tests that come with
55 the package.
56
57 4. Type `make install' to install the programs and any data files and
58 documentation.
59
60 5. You can remove the program binaries and object files from the
61 source code directory by typing `make clean'. To also remove the
62 files that `configure' created (so you can compile the package for
63 a different kind of computer), type `make distclean'. There is
64 also a `make maintainer-clean' target, but that is intended mainly
65 for the package's developers. If you use it, you may have to get
66 all sorts of other programs in order to regenerate files that came
67 with the distribution.
68
69 6. Often, you can also type `make uninstall' to remove the installed
70 files again.
71
72 Compilers and Options
73 =====================
74
75 Some systems require unusual options for compilation or linking that the
76 `configure' script does not know about. Run `./configure --help' for
77 details on some of the pertinent environment variables.
78
79 You can give `configure' initial values for configuration parameters
80 by setting variables in the command line or in the environment. Here
81 is an example:
82
83 ./configure CC=c99 CFLAGS=-g LIBS=-lposix
84
85 *Note Defining Variables::, for more details.
86
87 Compiling For Multiple Architectures
88 ====================================
89
90 You can compile the package for more than one kind of computer at the
91 same time, by placing the object files for each architecture in their
92 own directory. To do this, you can use GNU `make'. `cd' to the
93 directory where you want the object files and executables to go and run
94 the `configure' script. `configure' automatically checks for the
95 source code in the directory that `configure' is in and in `..'.
96
97 With a non-GNU `make', it is safer to compile the package for one
98 architecture at a time in the source code directory. After you have
99 installed the package for one architecture, use `make distclean' before
100 reconfiguring for another architecture.
101
102 Installation Names
103 ==================
104
105 By default, `make install' installs the package's commands under
106 `/usr/local/bin', include files under `/usr/local/include', etc. You
107 can specify an installation prefix other than `/usr/local' by giving
108 `configure' the option `--prefix=PREFIX'.
109
110 You can specify separate installation prefixes for
111 architecture-specific files and architecture-independent files. If you
112 pass the option `--exec-prefix=PREFIX' to `configure', the package uses
113 PREFIX as the prefix for installing programs and libraries.
114 Documentation and other data files still use the regular prefix.
115
116 In addition, if you use an unusual directory layout you can give
117 options like `--bindir=DIR' to specify different values for particular
118 kinds of files. Run `configure --help' for a list of the directories
119 you can set and what kinds of files go in them.
120
121 If the package supports it, you can cause programs to be installed
122 with an extra prefix or suffix on their names by giving `configure' the
123 option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
124
125 Optional Features
126 =================
127
128 Some packages pay attention to `--enable-FEATURE' options to
129 `configure', where FEATURE indicates an optional part of the package.
130 They may also pay attention to `--with-PACKAGE' options, where PACKAGE
131 is something like `gnu-as' or `x' (for the X Window System). The
132 `README' should mention any `--enable-' and `--with-' options that the
133 package recognizes.
134
135 For packages that use the X Window System, `configure' can usually
136 find the X include and library files automatically, but if it doesn't,
137 you can use the `configure' options `--x-includes=DIR' and
138 `--x-libraries=DIR' to specify their locations.
139
140 Specifying the System Type
141 ==========================
142
143 There may be some features `configure' cannot figure out automatically,
144 but needs to determine by the type of machine the package will run on.
145 Usually, assuming the package is built to be run on the _same_
146 architectures, `configure' can figure that out, but if it prints a
147 message saying it cannot guess the machine type, give it the
148 `--build=TYPE' option. TYPE can either be a short name for the system
149 type, such as `sun4', or a canonical name which has the form:
150
151 CPU-COMPANY-SYSTEM
152
153 where SYSTEM can have one of these forms:
154
155 OS KERNEL-OS
156
157 See the file `config.sub' for the possible values of each field. If
158 `config.sub' isn't included in this package, then this package doesn't
159 need to know the machine type.
160
161 If you are _building_ compiler tools for cross-compiling, you should
162 use the option `--target=TYPE' to select the type of system they will
163 produce code for.
164
165 If you want to _use_ a cross compiler, that generates code for a
166 platform different from the build platform, you should specify the
167 "host" platform (i.e., that on which the generated programs will
168 eventually be run) with `--host=TYPE'.
169
170 Sharing Defaults
171 ================
172
173 If you want to set default values for `configure' scripts to share, you
174 can create a site shell script called `config.site' that gives default
175 values for variables like `CC', `cache_file', and `prefix'.
176 `configure' looks for `PREFIX/share/config.site' if it exists, then
177 `PREFIX/etc/config.site' if it exists. Or, you can set the
178 `CONFIG_SITE' environment variable to the location of the site script.
179 A warning: not all `configure' scripts look for a site script.
180
181 Defining Variables
182 ==================
183
184 Variables not defined in a site shell script can be set in the
185 environment passed to `configure'. However, some packages may run
186 configure again during the build, and the customized values of these
187 variables may be lost. In order to avoid this problem, you should set
188 them in the `configure' command line, using `VAR=value'. For example:
189
190 ./configure CC=/usr/local2/bin/gcc
191
192 causes the specified `gcc' to be used as the C compiler (unless it is
193 overridden in the site shell script).
194
195 Unfortunately, this technique does not work for `CONFIG_SHELL' due to
196 an Autoconf bug. Until the bug is fixed you can use this workaround:
197
198 CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
199
200 `configure' Invocation
201 ======================
202
203 `configure' recognizes the following options to control how it operates.
204
205 `--help'
206 `-h'
207 Print a summary of the options to `configure', and exit.
208
209 `--version'
210 `-V'
211 Print the version of Autoconf used to generate the `configure'
212 script, and exit.
213
214 `--cache-file=FILE'
215 Enable the cache: use and save the results of the tests in FILE,
216 traditionally `config.cache'. FILE defaults to `/dev/null' to
217 disable caching.
218
219 `--config-cache'
220 `-C'
221 Alias for `--cache-file=config.cache'.
222
223 `--quiet'
224 `--silent'
225 `-q'
226 Do not print messages saying which checks are being made. To
227 suppress all normal output, redirect it to `/dev/null' (any error
228 messages will still be shown).
229
230 `--srcdir=DIR'
231 Look for the package's source code in directory DIR. Usually
232 `configure' can determine that directory automatically.
233
234 `configure' also accepts some other, not widely useful, options. Run
235 `configure --help' for more details.
236
106106
107107 sign-release:
108108 +(set -e; \
109 cd dist; \
109 test $$(pwd | sed 's,.*/,,') = dist || cd dist; \
110110 x=$$(grep '^RELEASE_ARCHIVE=' $$HOME/.gnupg-autogen.rc|cut -d= -f2);\
111111 if [ -z "$$x" ]; then \
112112 echo "error: RELEASE_ARCHIVE missing in ~/.gnupg-autogen.rc">&2; \
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am - Top level Makefile for GPGME.
17 # Copyright (C) 2000 Werner Koch (dd9jn)
18 # Copyright (C) 2001, 2002, 2004, 2005, 2008, 2009 g10 Code GmbH
19 #
20 # This file is part of GPGME.
21 #
22 # GPGME is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU Lesser General Public License as
24 # published by the Free Software Foundation; either version 2.1 of the
25 # License, or (at your option) any later version.
26 #
27 # GPGME is distributed in the hope that it will be useful, but WITHOUT
28 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
29 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
30 # Public License for more details.
31 #
32 # You should have received a copy of the GNU Lesser General Public
33 # License along with this program; if not, see <https://gnu.org/licenses/>.
34 # SPDX-License-Identifier: LGPL-2.1-or-later
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = .
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \
125 $(am__configure_deps) $(am__DIST_COMMON)
126 am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
127 configure.lineno config.status.lineno
128 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
129 CONFIG_HEADER = $(top_builddir)/conf/config.h
130 CONFIG_CLEAN_FILES =
131 CONFIG_CLEAN_VPATH_FILES =
132 AM_V_P = $(am__v_P_@AM_V@)
133 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
134 am__v_P_0 = false
135 am__v_P_1 = :
136 AM_V_GEN = $(am__v_GEN_@AM_V@)
137 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
138 am__v_GEN_0 = @echo " GEN " $@;
139 am__v_GEN_1 =
140 AM_V_at = $(am__v_at_@AM_V@)
141 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
142 am__v_at_0 = @
143 am__v_at_1 =
144 SOURCES =
145 DIST_SOURCES =
146 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
147 ctags-recursive dvi-recursive html-recursive info-recursive \
148 install-data-recursive install-dvi-recursive \
149 install-exec-recursive install-html-recursive \
150 install-info-recursive install-pdf-recursive \
151 install-ps-recursive install-recursive installcheck-recursive \
152 installdirs-recursive pdf-recursive ps-recursive \
153 tags-recursive uninstall-recursive
154 am__can_run_installinfo = \
155 case $$AM_UPDATE_INFO_DIR in \
156 n|no|NO) false;; \
157 *) (install-info --version) >/dev/null 2>&1;; \
158 esac
159 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
160 distclean-recursive maintainer-clean-recursive
161 am__recursive_targets = \
162 $(RECURSIVE_TARGETS) \
163 $(RECURSIVE_CLEAN_TARGETS) \
164 $(am__extra_recursive_targets)
165 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
166 cscope distdir distdir-am dist dist-all distcheck
167 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
168 # Read a list of newline-separated strings from the standard input,
169 # and print each of them once, without duplicates. Input order is
170 # *not* preserved.
171 am__uniquify_input = $(AWK) '\
172 BEGIN { nonempty = 0; } \
173 { items[$$0] = 1; nonempty = 1; } \
174 END { if (nonempty) { for (i in items) print i; }; } \
175 '
176 # Make sure the list of sources is unique. This is necessary because,
177 # e.g., the same source file might be shared among _SOURCES variables
178 # for different programs/libraries.
179 am__define_uniq_tagged_files = \
180 list='$(am__tagged_files)'; \
181 unique=`for i in $$list; do \
182 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
183 done | $(am__uniquify_input)`
184 ETAGS = etags
185 CTAGS = ctags
186 CSCOPE = cscope
187 DIST_SUBDIRS = src tests doc lang
188 am__DIST_COMMON = $(srcdir)/Makefile.in \
189 $(top_srcdir)/build-aux/compile \
190 $(top_srcdir)/build-aux/config.guess \
191 $(top_srcdir)/build-aux/config.sub \
192 $(top_srcdir)/build-aux/install-sh \
193 $(top_srcdir)/build-aux/ltmain.sh \
194 $(top_srcdir)/build-aux/missing \
195 $(top_srcdir)/build-aux/mkinstalldirs \
196 $(top_srcdir)/conf/config.h.in AUTHORS COPYING COPYING.LESSER \
197 ChangeLog INSTALL NEWS README THANKS TODO build-aux/compile \
198 build-aux/config.guess build-aux/config.sub build-aux/depcomp \
199 build-aux/install-sh build-aux/ltmain.sh build-aux/mdate-sh \
200 build-aux/missing build-aux/mkinstalldirs \
201 build-aux/texinfo.tex missing
202 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
203 distdir = $(PACKAGE)-$(VERSION)
204 top_distdir = $(distdir)
205 am__remove_distdir = \
206 if test -d "$(distdir)"; then \
207 find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
208 && rm -rf "$(distdir)" \
209 || { sleep 5 && rm -rf "$(distdir)"; }; \
210 else :; fi
211 am__post_remove_distdir = $(am__remove_distdir)
212 am__relativize = \
213 dir0=`pwd`; \
214 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
215 sed_rest='s,^[^/]*/*,,'; \
216 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
217 sed_butlast='s,/*[^/]*$$,,'; \
218 while test -n "$$dir1"; do \
219 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
220 if test "$$first" != "."; then \
221 if test "$$first" = ".."; then \
222 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
223 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
224 else \
225 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
226 if test "$$first2" = "$$first"; then \
227 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
228 else \
229 dir2="../$$dir2"; \
230 fi; \
231 dir0="$$dir0"/"$$first"; \
232 fi; \
233 fi; \
234 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
235 done; \
236 reldir="$$dir2"
237 GZIP_ENV = --best
238 DIST_ARCHIVES = $(distdir).tar.bz2
239 DIST_TARGETS = dist-bzip2
240 # Exists only to be overridden by the user if desired.
241 AM_DISTCHECK_DVI_TARGET = dvi
242 distuninstallcheck_listfiles = find . -type f -print
243 am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
244 | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
245 distcleancheck_listfiles = find . -type f -print
246 ACLOCAL = @ACLOCAL@
247 AMTAR = @AMTAR@
248 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
249 AR = @AR@
250 AS = @AS@
251 AUTOCONF = @AUTOCONF@
252 AUTOHEADER = @AUTOHEADER@
253 AUTOMAKE = @AUTOMAKE@
254 AWK = @AWK@
255 BUILD_FILEVERSION = @BUILD_FILEVERSION@
256 BUILD_REVISION = @BUILD_REVISION@
257 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
258 BUILD_VERSION = @BUILD_VERSION@
259 CC = @CC@
260 CCDEPMODE = @CCDEPMODE@
261 CC_FOR_BUILD = @CC_FOR_BUILD@
262 CFLAGS = @CFLAGS@
263 CPP = @CPP@
264 CPPFLAGS = @CPPFLAGS@
265 CXX = @CXX@
266 CXXCPP = @CXXCPP@
267 CXXDEPMODE = @CXXDEPMODE@
268 CXXFLAGS = @CXXFLAGS@
269 CYGPATH_W = @CYGPATH_W@
270 DEFS = @DEFS@
271 DEPDIR = @DEPDIR@
272 DLLTOOL = @DLLTOOL@
273 DOXYGEN = @DOXYGEN@
274 DSYMUTIL = @DSYMUTIL@
275 DUMPBIN = @DUMPBIN@
276 ECHO_C = @ECHO_C@
277 ECHO_N = @ECHO_N@
278 ECHO_T = @ECHO_T@
279 EGREP = @EGREP@
280 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
281 EXEEXT = @EXEEXT@
282 FGREP = @FGREP@
283 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
284 GLIBC21 = @GLIBC21@
285 GLIB_CFLAGS = @GLIB_CFLAGS@
286 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
287 GLIB_LIBS = @GLIB_LIBS@
288 GLIB_MKENUMS = @GLIB_MKENUMS@
289 GOBJECT_QUERY = @GOBJECT_QUERY@
290 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
291 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
292 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
293 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
294 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
295 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
296 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
297 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
298 GPGME_QT_LIBS = @GPGME_QT_LIBS@
299 GPGRT_CONFIG = @GPGRT_CONFIG@
300 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
301 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
302 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
303 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
304 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
305 GRAPHVIZ = @GRAPHVIZ@
306 GREP = @GREP@
307 HAVE_CXX11 = @HAVE_CXX11@
308 HAVE_DOT = @HAVE_DOT@
309 INSTALL = @INSTALL@
310 INSTALL_DATA = @INSTALL_DATA@
311 INSTALL_PROGRAM = @INSTALL_PROGRAM@
312 INSTALL_SCRIPT = @INSTALL_SCRIPT@
313 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
314 LD = @LD@
315 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
316 LDFLAGS = @LDFLAGS@
317 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
318 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
319 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
320 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
321 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
322 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
323 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
324 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
325 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
326 LIBOBJS = @LIBOBJS@
327 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
328 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
329 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
330 LIBS = @LIBS@
331 LIBTOOL = @LIBTOOL@
332 LIPO = @LIPO@
333 LN_S = @LN_S@
334 LTLIBOBJS = @LTLIBOBJS@
335 MAINT = @MAINT@
336 MAKEINFO = @MAKEINFO@
337 MANIFEST_TOOL = @MANIFEST_TOOL@
338 MKDIR_P = @MKDIR_P@
339 MOC = @MOC@
340 MOC2 = @MOC2@
341 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
342 NM = @NM@
343 NMEDIT = @NMEDIT@
344 OBJDUMP = @OBJDUMP@
345 OBJEXT = @OBJEXT@
346 OTOOL = @OTOOL@
347 OTOOL64 = @OTOOL64@
348 PACKAGE = @PACKAGE@
349 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
350 PACKAGE_NAME = @PACKAGE_NAME@
351 PACKAGE_STRING = @PACKAGE_STRING@
352 PACKAGE_TARNAME = @PACKAGE_TARNAME@
353 PACKAGE_URL = @PACKAGE_URL@
354 PACKAGE_VERSION = @PACKAGE_VERSION@
355 PATH_SEPARATOR = @PATH_SEPARATOR@
356 PKG_CONFIG = @PKG_CONFIG@
357 PYTHON = @PYTHON@
358 PYTHONS = @PYTHONS@
359 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
360 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
361 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
362 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
363 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
364 PYTHON_PLATFORM = @PYTHON_PLATFORM@
365 PYTHON_PREFIX = @PYTHON_PREFIX@
366 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
367 PYTHON_VERSION = @PYTHON_VERSION@
368 QTCHOOSER = @QTCHOOSER@
369 RANLIB = @RANLIB@
370 RC = @RC@
371 SED = @SED@
372 SET_MAKE = @SET_MAKE@
373 SHELL = @SHELL@
374 STRIP = @STRIP@
375 SWIG = @SWIG@
376 SWIG_LIB = @SWIG_LIB@
377 SYSROOT = @SYSROOT@
378 VERSION = @VERSION@
379 VERSION_MAJOR = @VERSION_MAJOR@
380 VERSION_MICRO = @VERSION_MICRO@
381 VERSION_MINOR = @VERSION_MINOR@
382 VERSION_NUMBER = @VERSION_NUMBER@
383 abs_builddir = @abs_builddir@
384 abs_srcdir = @abs_srcdir@
385 abs_top_builddir = @abs_top_builddir@
386 abs_top_srcdir = @abs_top_srcdir@
387 ac_ct_AR = @ac_ct_AR@
388 ac_ct_CC = @ac_ct_CC@
389 ac_ct_CXX = @ac_ct_CXX@
390 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
391 am__include = @am__include@
392 am__leading_dot = @am__leading_dot@
393 am__quote = @am__quote@
394 am__tar = @am__tar@
395 am__untar = @am__untar@
396 bindir = @bindir@
397 build = @build@
398 build_alias = @build_alias@
399 build_cpu = @build_cpu@
400 build_os = @build_os@
401 build_vendor = @build_vendor@
402 builddir = @builddir@
403 datadir = @datadir@
404 datarootdir = @datarootdir@
405 docdir = @docdir@
406 dvidir = @dvidir@
407 emacs_local_vars_begin = @emacs_local_vars_begin@
408 emacs_local_vars_end = @emacs_local_vars_end@
409 emacs_local_vars_read_only = @emacs_local_vars_read_only@
410 exec_prefix = @exec_prefix@
411 host = @host@
412 host_alias = @host_alias@
413 host_cpu = @host_cpu@
414 host_os = @host_os@
415 host_vendor = @host_vendor@
416 htmldir = @htmldir@
417 includedir = @includedir@
418 infodir = @infodir@
419 install_sh = @install_sh@
420 libdir = @libdir@
421 libexecdir = @libexecdir@
422 localedir = @localedir@
423 localstatedir = @localstatedir@
424 mandir = @mandir@
425 mkdir_p = @mkdir_p@
426 oldincludedir = @oldincludedir@
427 pdfdir = @pdfdir@
428 pkgpyexecdir = @pkgpyexecdir@
429 pkgpythondir = @pkgpythondir@
430 prefix = @prefix@
431 program_transform_name = @program_transform_name@
432 psdir = @psdir@
433 pyexecdir = @pyexecdir@
434 pythondir = @pythondir@
435 runstatedir = @runstatedir@
436 sbindir = @sbindir@
437 sharedstatedir = @sharedstatedir@
438 srcdir = @srcdir@
439 sysconfdir = @sysconfdir@
440 target_alias = @target_alias@
441 top_build_prefix = @top_build_prefix@
442 top_builddir = @top_builddir@
443 top_srcdir = @top_srcdir@
444
445 # Location of the released tarball archives. This is prefixed by
446 # the variable RELEASE_ARCHIVE in ~/.gnupg-autogen.rc. For example:
447 # RELEASE_ARCHIVE=user@host:archive/tarballs
448 RELEASE_ARCHIVE_SUFFIX = gpgme
449 # The variable RELEASE_SIGNKEY in ~/.gnupg-autogen.rc is used
450 # to specify the key for signing. For example:
451 # RELEASE_SIGNKEY=D8692123C4065DEA5E0F3AB5249B39D24F25E3B6
452
453 # Autoconf flags
454 ACLOCAL_AMFLAGS = -I m4
455 DISTCHECK_CONFIGURE_FLAGS =
456 EXTRA_DIST = autogen.sh autogen.rc gpgme.spec.in \
457 ChangeLog-2011 m4/ChangeLog-2011 \
458 conf/whatisthis VERSION LICENSES
459
460 @RUN_GPG_TESTS_FALSE@tests =
461 @RUN_GPG_TESTS_TRUE@tests = tests
462 SUBDIRS = src ${tests} doc lang
463 gen_start_date = 2011-12-01T00:00:00
464
465 # Macro to help the release target.
466 RELEASE_NAME = $(PACKAGE_TARNAME)-$(PACKAGE_VERSION)
467 all: all-recursive
468
469 .SUFFIXES:
470 am--refresh: Makefile
471 @:
472 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
473 @for dep in $?; do \
474 case '$(am__configure_deps)' in \
475 *$$dep*) \
476 echo ' cd $(srcdir) && $(AUTOMAKE) --gnu'; \
477 $(am__cd) $(srcdir) && $(AUTOMAKE) --gnu \
478 && exit 0; \
479 exit 1;; \
480 esac; \
481 done; \
482 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \
483 $(am__cd) $(top_srcdir) && \
484 $(AUTOMAKE) --gnu Makefile
485 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
486 @case '$?' in \
487 *config.status*) \
488 echo ' $(SHELL) ./config.status'; \
489 $(SHELL) ./config.status;; \
490 *) \
491 echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \
492 cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \
493 esac;
494
495 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
496 $(SHELL) ./config.status --recheck
497
498 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
499 $(am__cd) $(srcdir) && $(AUTOCONF)
500 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
501 $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
502 $(am__aclocal_m4_deps):
503
504 conf/config.h: conf/stamp-h1
505 @test -f $@ || rm -f conf/stamp-h1
506 @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) conf/stamp-h1
507
508 conf/stamp-h1: $(top_srcdir)/conf/config.h.in $(top_builddir)/config.status
509 @rm -f conf/stamp-h1
510 cd $(top_builddir) && $(SHELL) ./config.status conf/config.h
511 $(top_srcdir)/conf/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
512 ($(am__cd) $(top_srcdir) && $(AUTOHEADER))
513 rm -f conf/stamp-h1
514 touch $@
515
516 distclean-hdr:
517 -rm -f conf/config.h conf/stamp-h1
518
519 mostlyclean-libtool:
520 -rm -f *.lo
521
522 clean-libtool:
523 -rm -rf .libs _libs
524
525 distclean-libtool:
526 -rm -f libtool config.lt
527
528 # This directory's subdirectories are mostly independent; you can cd
529 # into them and run 'make' without going through this Makefile.
530 # To change the values of 'make' variables: instead of editing Makefiles,
531 # (1) if the variable is set in 'config.status', edit 'config.status'
532 # (which will cause the Makefiles to be regenerated when you run 'make');
533 # (2) otherwise, pass the desired values on the 'make' command line.
534 $(am__recursive_targets):
535 @fail=; \
536 if $(am__make_keepgoing); then \
537 failcom='fail=yes'; \
538 else \
539 failcom='exit 1'; \
540 fi; \
541 dot_seen=no; \
542 target=`echo $@ | sed s/-recursive//`; \
543 case "$@" in \
544 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
545 *) list='$(SUBDIRS)' ;; \
546 esac; \
547 for subdir in $$list; do \
548 echo "Making $$target in $$subdir"; \
549 if test "$$subdir" = "."; then \
550 dot_seen=yes; \
551 local_target="$$target-am"; \
552 else \
553 local_target="$$target"; \
554 fi; \
555 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
556 || eval $$failcom; \
557 done; \
558 if test "$$dot_seen" = "no"; then \
559 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
560 fi; test -z "$$fail"
561
562 ID: $(am__tagged_files)
563 $(am__define_uniq_tagged_files); mkid -fID $$unique
564 tags: tags-recursive
565 TAGS: tags
566
567 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
568 set x; \
569 here=`pwd`; \
570 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
571 include_option=--etags-include; \
572 empty_fix=.; \
573 else \
574 include_option=--include; \
575 empty_fix=; \
576 fi; \
577 list='$(SUBDIRS)'; for subdir in $$list; do \
578 if test "$$subdir" = .; then :; else \
579 test ! -f $$subdir/TAGS || \
580 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
581 fi; \
582 done; \
583 $(am__define_uniq_tagged_files); \
584 shift; \
585 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
586 test -n "$$unique" || unique=$$empty_fix; \
587 if test $$# -gt 0; then \
588 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
589 "$$@" $$unique; \
590 else \
591 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
592 $$unique; \
593 fi; \
594 fi
595 ctags: ctags-recursive
596
597 CTAGS: ctags
598 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
599 $(am__define_uniq_tagged_files); \
600 test -z "$(CTAGS_ARGS)$$unique" \
601 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
602 $$unique
603
604 GTAGS:
605 here=`$(am__cd) $(top_builddir) && pwd` \
606 && $(am__cd) $(top_srcdir) \
607 && gtags -i $(GTAGS_ARGS) "$$here"
608 cscope: cscope.files
609 test ! -s cscope.files \
610 || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
611 clean-cscope:
612 -rm -f cscope.files
613 cscope.files: clean-cscope cscopelist
614 cscopelist: cscopelist-recursive
615
616 cscopelist-am: $(am__tagged_files)
617 list='$(am__tagged_files)'; \
618 case "$(srcdir)" in \
619 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
620 *) sdir=$(subdir)/$(srcdir) ;; \
621 esac; \
622 for i in $$list; do \
623 if test -f "$$i"; then \
624 echo "$(subdir)/$$i"; \
625 else \
626 echo "$$sdir/$$i"; \
627 fi; \
628 done >> $(top_builddir)/cscope.files
629
630 distclean-tags:
631 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
632 -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
633
634 distdir: $(BUILT_SOURCES)
635 $(MAKE) $(AM_MAKEFLAGS) distdir-am
636
637 distdir-am: $(DISTFILES)
638 $(am__remove_distdir)
639 test -d "$(distdir)" || mkdir "$(distdir)"
640 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
641 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
642 list='$(DISTFILES)'; \
643 dist_files=`for file in $$list; do echo $$file; done | \
644 sed -e "s|^$$srcdirstrip/||;t" \
645 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
646 case $$dist_files in \
647 */*) $(MKDIR_P) `echo "$$dist_files" | \
648 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
649 sort -u` ;; \
650 esac; \
651 for file in $$dist_files; do \
652 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
653 if test -d $$d/$$file; then \
654 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
655 if test -d "$(distdir)/$$file"; then \
656 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
657 fi; \
658 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
659 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
660 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
661 fi; \
662 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
663 else \
664 test -f "$(distdir)/$$file" \
665 || cp -p $$d/$$file "$(distdir)/$$file" \
666 || exit 1; \
667 fi; \
668 done
669 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
670 if test "$$subdir" = .; then :; else \
671 $(am__make_dryrun) \
672 || test -d "$(distdir)/$$subdir" \
673 || $(MKDIR_P) "$(distdir)/$$subdir" \
674 || exit 1; \
675 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
676 $(am__relativize); \
677 new_distdir=$$reldir; \
678 dir1=$$subdir; dir2="$(top_distdir)"; \
679 $(am__relativize); \
680 new_top_distdir=$$reldir; \
681 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
682 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
683 ($(am__cd) $$subdir && \
684 $(MAKE) $(AM_MAKEFLAGS) \
685 top_distdir="$$new_top_distdir" \
686 distdir="$$new_distdir" \
687 am__remove_distdir=: \
688 am__skip_length_check=: \
689 am__skip_mode_fix=: \
690 distdir) \
691 || exit 1; \
692 fi; \
693 done
694 $(MAKE) $(AM_MAKEFLAGS) \
695 top_distdir="$(top_distdir)" distdir="$(distdir)" \
696 dist-hook
697 -test -n "$(am__skip_mode_fix)" \
698 || find "$(distdir)" -type d ! -perm -755 \
699 -exec chmod u+rwx,go+rx {} \; -o \
700 ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
701 ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
702 ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
703 || chmod -R a+r "$(distdir)"
704 dist-gzip: distdir
705 tardir=$(distdir) && $(am__tar) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).tar.gz
706 $(am__post_remove_distdir)
707 dist-bzip2: distdir
708 tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2
709 $(am__post_remove_distdir)
710
711 dist-lzip: distdir
712 tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz
713 $(am__post_remove_distdir)
714
715 dist-xz: distdir
716 tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
717 $(am__post_remove_distdir)
718
719 dist-zstd: distdir
720 tardir=$(distdir) && $(am__tar) | zstd -c $${ZSTD_CLEVEL-$${ZSTD_OPT--19}} >$(distdir).tar.zst
721 $(am__post_remove_distdir)
722
723 dist-tarZ: distdir
724 @echo WARNING: "Support for distribution archives compressed with" \
725 "legacy program 'compress' is deprecated." >&2
726 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2
727 tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
728 $(am__post_remove_distdir)
729
730 dist-shar: distdir
731 @echo WARNING: "Support for shar distribution archives is" \
732 "deprecated." >&2
733 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2
734 shar $(distdir) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).shar.gz
735 $(am__post_remove_distdir)
736
737 dist-zip: distdir
738 -rm -f $(distdir).zip
739 zip -rq $(distdir).zip $(distdir)
740 $(am__post_remove_distdir)
741
742 dist dist-all:
743 $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:'
744 $(am__post_remove_distdir)
745
746 # This target untars the dist file and tries a VPATH configuration. Then
747 # it guarantees that the distribution is self-contained by making another
748 # tarfile.
749 distcheck: dist
750 case '$(DIST_ARCHIVES)' in \
751 *.tar.gz*) \
752 eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\
753 *.tar.bz2*) \
754 bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
755 *.tar.lz*) \
756 lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
757 *.tar.xz*) \
758 xz -dc $(distdir).tar.xz | $(am__untar) ;;\
759 *.tar.Z*) \
760 uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
761 *.shar.gz*) \
762 eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\
763 *.zip*) \
764 unzip $(distdir).zip ;;\
765 *.tar.zst*) \
766 zstd -dc $(distdir).tar.zst | $(am__untar) ;;\
767 esac
768 chmod -R a-w $(distdir)
769 chmod u+w $(distdir)
770 mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst
771 chmod a-w $(distdir)
772 test -d $(distdir)/_build || exit 0; \
773 dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
774 && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
775 && $(MAKE) $(AM_MAKEFLAGS) distcheck-hook \
776 && am__cwd=`pwd` \
777 && $(am__cd) $(distdir)/_build/sub \
778 && ../../configure \
779 $(AM_DISTCHECK_CONFIGURE_FLAGS) \
780 $(DISTCHECK_CONFIGURE_FLAGS) \
781 --srcdir=../.. --prefix="$$dc_install_base" \
782 && $(MAKE) $(AM_MAKEFLAGS) \
783 && $(MAKE) $(AM_MAKEFLAGS) $(AM_DISTCHECK_DVI_TARGET) \
784 && $(MAKE) $(AM_MAKEFLAGS) check \
785 && $(MAKE) $(AM_MAKEFLAGS) install \
786 && $(MAKE) $(AM_MAKEFLAGS) installcheck \
787 && $(MAKE) $(AM_MAKEFLAGS) uninstall \
788 && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
789 distuninstallcheck \
790 && chmod -R a-w "$$dc_install_base" \
791 && ({ \
792 (cd ../.. && umask 077 && mkdir "$$dc_destdir") \
793 && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
794 && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
795 && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
796 distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
797 } || { rm -rf "$$dc_destdir"; exit 1; }) \
798 && rm -rf "$$dc_destdir" \
799 && $(MAKE) $(AM_MAKEFLAGS) dist \
800 && rm -rf $(DIST_ARCHIVES) \
801 && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
802 && cd "$$am__cwd" \
803 || exit 1
804 $(am__post_remove_distdir)
805 @(echo "$(distdir) archives ready for distribution: "; \
806 list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
807 sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
808 distuninstallcheck:
809 @test -n '$(distuninstallcheck_dir)' || { \
810 echo 'ERROR: trying to run $@ with an empty' \
811 '$$(distuninstallcheck_dir)' >&2; \
812 exit 1; \
813 }; \
814 $(am__cd) '$(distuninstallcheck_dir)' || { \
815 echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \
816 exit 1; \
817 }; \
818 test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \
819 || { echo "ERROR: files left after uninstall:" ; \
820 if test -n "$(DESTDIR)"; then \
821 echo " (check DESTDIR support)"; \
822 fi ; \
823 $(distuninstallcheck_listfiles) ; \
824 exit 1; } >&2
825 distcleancheck: distclean
826 @if test '$(srcdir)' = . ; then \
827 echo "ERROR: distcleancheck can only run from a VPATH build" ; \
828 exit 1 ; \
829 fi
830 @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
831 || { echo "ERROR: files left in build directory after distclean:" ; \
832 $(distcleancheck_listfiles) ; \
833 exit 1; } >&2
834 check-am: all-am
835 check: check-recursive
836 all-am: Makefile
837 installdirs: installdirs-recursive
838 installdirs-am:
839 install: install-recursive
840 install-exec: install-exec-recursive
841 install-data: install-data-recursive
842 uninstall: uninstall-recursive
843
844 install-am: all-am
845 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
846
847 installcheck: installcheck-recursive
848 install-strip:
849 if test -z '$(STRIP)'; then \
850 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
851 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
852 install; \
853 else \
854 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
855 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
856 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
857 fi
858 mostlyclean-generic:
859
860 clean-generic:
861
862 distclean-generic:
863 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
864 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
865
866 maintainer-clean-generic:
867 @echo "This command is intended for maintainers to use"
868 @echo "it deletes files that may require special tools to rebuild."
869 clean: clean-recursive
870
871 clean-am: clean-generic clean-libtool mostlyclean-am
872
873 distclean: distclean-recursive
874 -rm -f $(am__CONFIG_DISTCLEAN_FILES)
875 -rm -f Makefile
876 distclean-am: clean-am distclean-generic distclean-hdr \
877 distclean-libtool distclean-tags
878
879 dvi: dvi-recursive
880
881 dvi-am:
882
883 html: html-recursive
884
885 html-am:
886
887 info: info-recursive
888
889 info-am:
890
891 install-data-am:
892
893 install-dvi: install-dvi-recursive
894
895 install-dvi-am:
896
897 install-exec-am:
898
899 install-html: install-html-recursive
900
901 install-html-am:
902
903 install-info: install-info-recursive
904
905 install-info-am:
906
907 install-man:
908
909 install-pdf: install-pdf-recursive
910
911 install-pdf-am:
912
913 install-ps: install-ps-recursive
914
915 install-ps-am:
916
917 installcheck-am:
918
919 maintainer-clean: maintainer-clean-recursive
920 -rm -f $(am__CONFIG_DISTCLEAN_FILES)
921 -rm -rf $(top_srcdir)/autom4te.cache
922 -rm -f Makefile
923 maintainer-clean-am: distclean-am maintainer-clean-generic
924
925 mostlyclean: mostlyclean-recursive
926
927 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
928
929 pdf: pdf-recursive
930
931 pdf-am:
932
933 ps: ps-recursive
934
935 ps-am:
936
937 uninstall-am:
938
939 .MAKE: $(am__recursive_targets) install-am install-strip
940
941 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
942 am--refresh check check-am clean clean-cscope clean-generic \
943 clean-libtool cscope cscopelist-am ctags ctags-am dist \
944 dist-all dist-bzip2 dist-gzip dist-hook dist-lzip dist-shar \
945 dist-tarZ dist-xz dist-zip dist-zstd distcheck distclean \
946 distclean-generic distclean-hdr distclean-libtool \
947 distclean-tags distcleancheck distdir distuninstallcheck dvi \
948 dvi-am html html-am info info-am install install-am \
949 install-data install-data-am install-dvi install-dvi-am \
950 install-exec install-exec-am install-html install-html-am \
951 install-info install-info-am install-man install-pdf \
952 install-pdf-am install-ps install-ps-am install-strip \
953 installcheck installcheck-am installdirs installdirs-am \
954 maintainer-clean maintainer-clean-generic mostlyclean \
955 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
956 tags tags-am uninstall uninstall-am
957
958 .PRECIOUS: Makefile
959
960
961 # Fix the version of the spec file.
962 dist-hook: gen-ChangeLog
963 @set -e; \
964 sed -e 's/@pkg_version@/$(PACKAGE_VERSION)/g' \
965 $(top_srcdir)/gpgme.spec.in > $(distdir)/gpgme.spec
966
967 distcheck-hook:
968 set -e; ( \
969 pref="#+macro: gpgme_" ;\
970 reldate="$$(date -u +%Y-%m-%d)" ;\
971 echo "$${pref}ver $(PACKAGE_VERSION)" ;\
972 echo "$${pref}date $${reldate}" ;\
973 list='$(DIST_ARCHIVES)'; for i in $$list; do \
974 case "$$i" in *.tar.bz2) \
975 echo "$${pref}size $$(wc -c <$$i|awk '{print int($$1/1024)}')k" ;\
976 echo "$${pref}sha1 $$(sha1sum <$$i|cut -d' ' -f1)" ;\
977 echo "$${pref}sha2 $$(sha256sum <$$i|cut -d' ' -f1)" ;;\
978 esac;\
979 done ) | tee $(distdir).swdb
980
981 .PHONY: gen-ChangeLog release sign-release
982 gen-ChangeLog:
983 if test -d $(top_srcdir)/.git; then \
984 (cd $(top_srcdir) && \
985 $(GITLOG_TO_CHANGELOG) --append-dot --tear-off \
986 --amend=build-aux/git-log-fix \
987 --since=$(gen_start_date) ) > $(distdir)/cl-t; \
988 cat $(top_srcdir)/build-aux/git-log-footer >> $(distdir)/cl-t;\
989 rm -f $(distdir)/ChangeLog; \
990 mv $(distdir)/cl-t $(distdir)/ChangeLog; \
991 fi
992
993 release:
994 +(set -e;\
995 if [ "$(abs_top_builddir)" = "$(abs_top_srcdir)" ]; then \
996 echo "error: build directory must not be the source directory" >&2;\
997 exit 2;\
998 fi ;\
999 echo "/* Build started at $$(date -uIseconds) */" ;\
1000 cd $(top_srcdir); \
1001 ./autogen.sh --force; \
1002 cd $(abs_top_builddir); \
1003 rm -rf dist; mkdir dist ; cd dist ; \
1004 $(abs_top_srcdir)/configure --enable-maintainer-mode; \
1005 $(MAKE) distcheck; \
1006 echo "/* Build finished at $$(date -uIseconds) */" ;\
1007 echo "/*" ;\
1008 echo " * Please run the final step interactively:" ;\
1009 echo " * make sign-release" ;\
1010 echo " */" ;\
1011 ) 2>&1 | tee "$(RELEASE_NAME).buildlog"
1012
1013 sign-release:
1014 +(set -e; \
1015 test $$(pwd | sed 's,.*/,,') = dist || cd dist; \
1016 x=$$(grep '^RELEASE_ARCHIVE=' $$HOME/.gnupg-autogen.rc|cut -d= -f2);\
1017 if [ -z "$$x" ]; then \
1018 echo "error: RELEASE_ARCHIVE missing in ~/.gnupg-autogen.rc">&2; \
1019 exit 2;\
1020 fi;\
1021 myarchive="$$x/$(RELEASE_ARCHIVE_SUFFIX)";\
1022 x=$$(grep '^RELEASE_SIGNKEY=' $$HOME/.gnupg-autogen.rc|cut -d= -f2);\
1023 if [ -z "$$x" ]; then \
1024 echo "error: RELEASE_SIGNKEY missing in ~/.gnupg-autogen.rc">&2; \
1025 exit 2;\
1026 fi;\
1027 mysignkey="$$x";\
1028 files1="$(RELEASE_NAME).tar.bz2" ;\
1029 files2="$(RELEASE_NAME).tar.bz2.sig \
1030 $(RELEASE_NAME).swdb \
1031 $(RELEASE_NAME).buildlog" ;\
1032 echo "/* Signing the source tarball ..." ;\
1033 gpg -sbu $$mysignkey $(RELEASE_NAME).tar.bz2 ;\
1034 cat $(RELEASE_NAME).swdb >swdb.snippet;\
1035 echo >>swdb.snippet ;\
1036 sha1sum $${files1} >>swdb.snippet ;\
1037 cat "../$(RELEASE_NAME).buildlog" swdb.snippet \
1038 | gzip >$(RELEASE_NAME).buildlog ;\
1039 echo "Copying to local archive ..." ;\
1040 scp -p $${files1} $${files2} $$myarchive/ || true;\
1041 echo "Uploading documentation ..." ;\
1042 $(MAKE) -C doc online; \
1043 echo '/*' ;\
1044 echo ' * All done; for checksums see dist/swdb.snippet' ;\
1045 echo ' */' ;\
1046 )
1047
1048 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1049 # Otherwise a system limit (for SysV at least) may be exceeded.
1050 .NOEXPORT:
0 Noteworthy changes in version 1.17.0 (2022-02-07)
1 -------------------------------------------------
2
3 * New context flag "key-origin". [#5733]
4
5 * New context flag "import-filter". [#5739]
6
7 * New export mode to export secret subkeys. [#5757]
8
9 * Detect errors during the export of secret keys. [#5766]
10
11 * New function gpgme_op_receive_keys to import keys from a keyserver
12 without first running a key listing. [#5808]
13
14 * Detect bad passphrase error in certificate import. [T5713]
15
16 * Allow setting --key-origin when importing keys. [T5733]
17
18 * Support components "keyboxd", "gpg-agent", "scdaemon", "dirmngr",
19 "pinentry", and "socketdir" in gpgme_get_dirinfo. [T5727,T5613]
20
21 * Under Unix use poll(2) instead of select(2), when available.
22 [T2385]
23
24 * Do not use --flat_namespace when linking for macOS. [T5610]
25
26 * Fix results returned by gpgme_data_* functions. [T5481]
27
28 * Support closefrom also for glibc. [rM4b64774b6d]
29
30 * cpp,qt: Add support for export of secret keys and secret subkeys.
31 [#5757]
32
33 * cpp,qt: Support for adding existing subkeys to other keys. [#5770]
34
35 * qt: Extend ChangeExpiryJob to change expiration of primary key
36 and of subkeys at the same time. [#4717]
37
38 * qt: Expect UTF-8 on stderr on Windows. [rM8fe1546282]
39
40 * qt: Allow retrieving the default value of a config entry. [T5515]
41
42 * Interface changes relative to the 1.16.0 release:
43 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
44 gpgme_op_receive_keys NEW.
45 gpgme_op_receive_keys_start NEW.
46 qt: Protocol::secretSubkeyExportJob NEW.
47 cpp: Context::exportSecretSubkeys NEW.
48 cpp: Context::startSecretSubkeyExport NEW.
49 qt: Protocol::secretKeyExportJob CHANGED: Param 'charset' is ignored.
50 cpp: Context::exportKeys NEW.
51 cpp: Context::startKeyExport NEW.
52 cpp: Context::exportSecretKeys NEW.
53 cpp: Context::startSecretKeyExport NEW.
54 cpp: GpgAddExistingSubkeyEditInteractor NEW.
55 GPGME_EXPORT_MODE_SECRET_SUBKEY NEW.
56 gpgme_set_ctx_flag EXTENDED: New flag 'key-origin'.
57 gpgme_set_ctx_flag EXTENDED: New flag 'import-filter'.
58 qt: ChangeExpiryJob::Option NEW.
59 qt: ChangeExpiryJob::Options NEW.
60 qt: ChangeExpiryJob::setOptions NEW.
61 qt: ChangeExpiryJob::options NEW.
62 qt: AddExistingSubkeyJob NEW.
63 qt: Protocol::addExistingSubkeyJob NEW.
64
65 [c=C37/A26/R0 cpp=C20/A14/R0 qt=C14/A7/R0]
66
67 Release-info: https://dev.gnupg.org/T5819
68
69
070 Noteworthy changes in version 1.16.0 (2021-06-24)
171 -------------------------------------------------
272
0 1.17.0
0 # generated automatically by aclocal 1.16.3 -*- Autoconf -*-
1
2 # Copyright (C) 1996-2020 Free Software Foundation, Inc.
3
4 # This file is free software; the Free Software Foundation
5 # gives unlimited permission to copy and/or distribute it,
6 # with or without modifications, as long as this notice is preserved.
7
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
10 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
11 # PARTICULAR PURPOSE.
12
13 m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
14 m4_ifndef([AC_AUTOCONF_VERSION],
15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
17 [m4_warning([this file was generated for autoconf 2.69.
18 You have another version of autoconf. It may work, but is not guaranteed to.
19 If you have problems, you may need to regenerate the build system entirely.
20 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
21
22 # Copyright (C) 2002-2020 Free Software Foundation, Inc.
23 #
24 # This file is free software; the Free Software Foundation
25 # gives unlimited permission to copy and/or distribute it,
26 # with or without modifications, as long as this notice is preserved.
27
28 # AM_AUTOMAKE_VERSION(VERSION)
29 # ----------------------------
30 # Automake X.Y traces this macro to ensure aclocal.m4 has been
31 # generated from the m4 files accompanying Automake X.Y.
32 # (This private macro should not be called outside this file.)
33 AC_DEFUN([AM_AUTOMAKE_VERSION],
34 [am__api_version='1.16'
35 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
36 dnl require some minimum version. Point them to the right macro.
37 m4_if([$1], [1.16.3], [],
38 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
39 ])
40
41 # _AM_AUTOCONF_VERSION(VERSION)
42 # -----------------------------
43 # aclocal traces this macro to find the Autoconf version.
44 # This is a private macro too. Using m4_define simplifies
45 # the logic in aclocal, which can simply ignore this definition.
46 m4_define([_AM_AUTOCONF_VERSION], [])
47
48 # AM_SET_CURRENT_AUTOMAKE_VERSION
49 # -------------------------------
50 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
51 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
52 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
53 [AM_AUTOMAKE_VERSION([1.16.3])dnl
54 m4_ifndef([AC_AUTOCONF_VERSION],
55 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
56 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
57
58 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
59
60 # Copyright (C) 2001-2020 Free Software Foundation, Inc.
61 #
62 # This file is free software; the Free Software Foundation
63 # gives unlimited permission to copy and/or distribute it,
64 # with or without modifications, as long as this notice is preserved.
65
66 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
67 # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
68 # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
69 #
70 # Of course, Automake must honor this variable whenever it calls a
71 # tool from the auxiliary directory. The problem is that $srcdir (and
72 # therefore $ac_aux_dir as well) can be either absolute or relative,
73 # depending on how configure is run. This is pretty annoying, since
74 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
75 # source directory, any form will work fine, but in subdirectories a
76 # relative path needs to be adjusted first.
77 #
78 # $ac_aux_dir/missing
79 # fails when called from a subdirectory if $ac_aux_dir is relative
80 # $top_srcdir/$ac_aux_dir/missing
81 # fails if $ac_aux_dir is absolute,
82 # fails when called from a subdirectory in a VPATH build with
83 # a relative $ac_aux_dir
84 #
85 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
86 # are both prefixed by $srcdir. In an in-source build this is usually
87 # harmless because $srcdir is '.', but things will broke when you
88 # start a VPATH build or use an absolute $srcdir.
89 #
90 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
91 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
92 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
93 # and then we would define $MISSING as
94 # MISSING="\${SHELL} $am_aux_dir/missing"
95 # This will work as long as MISSING is not called from configure, because
96 # unfortunately $(top_srcdir) has no meaning in configure.
97 # However there are other variables, like CC, which are often used in
98 # configure, and could therefore not use this "fixed" $ac_aux_dir.
99 #
100 # Another solution, used here, is to always expand $ac_aux_dir to an
101 # absolute PATH. The drawback is that using absolute paths prevent a
102 # configured tree to be moved without reconfiguration.
103
104 AC_DEFUN([AM_AUX_DIR_EXPAND],
105 [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
106 # Expand $ac_aux_dir to an absolute path.
107 am_aux_dir=`cd "$ac_aux_dir" && pwd`
108 ])
109
110 # AM_COND_IF -*- Autoconf -*-
111
112 # Copyright (C) 2008-2020 Free Software Foundation, Inc.
113 #
114 # This file is free software; the Free Software Foundation
115 # gives unlimited permission to copy and/or distribute it,
116 # with or without modifications, as long as this notice is preserved.
117
118 # _AM_COND_IF
119 # _AM_COND_ELSE
120 # _AM_COND_ENDIF
121 # --------------
122 # These macros are only used for tracing.
123 m4_define([_AM_COND_IF])
124 m4_define([_AM_COND_ELSE])
125 m4_define([_AM_COND_ENDIF])
126
127 # AM_COND_IF(COND, [IF-TRUE], [IF-FALSE])
128 # ---------------------------------------
129 # If the shell condition COND is true, execute IF-TRUE, otherwise execute
130 # IF-FALSE. Allow automake to learn about conditional instantiating macros
131 # (the AC_CONFIG_FOOS).
132 AC_DEFUN([AM_COND_IF],
133 [m4_ifndef([_AM_COND_VALUE_$1],
134 [m4_fatal([$0: no such condition "$1"])])dnl
135 _AM_COND_IF([$1])dnl
136 if test -z "$$1_TRUE"; then :
137 m4_n([$2])[]dnl
138 m4_ifval([$3],
139 [_AM_COND_ELSE([$1])dnl
140 else
141 $3
142 ])dnl
143 _AM_COND_ENDIF([$1])dnl
144 fi[]dnl
145 ])
146
147 # AM_CONDITIONAL -*- Autoconf -*-
148
149 # Copyright (C) 1997-2020 Free Software Foundation, Inc.
150 #
151 # This file is free software; the Free Software Foundation
152 # gives unlimited permission to copy and/or distribute it,
153 # with or without modifications, as long as this notice is preserved.
154
155 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
156 # -------------------------------------
157 # Define a conditional.
158 AC_DEFUN([AM_CONDITIONAL],
159 [AC_PREREQ([2.52])dnl
160 m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
161 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
162 AC_SUBST([$1_TRUE])dnl
163 AC_SUBST([$1_FALSE])dnl
164 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
165 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
166 m4_define([_AM_COND_VALUE_$1], [$2])dnl
167 if $2; then
168 $1_TRUE=
169 $1_FALSE='#'
170 else
171 $1_TRUE='#'
172 $1_FALSE=
173 fi
174 AC_CONFIG_COMMANDS_PRE(
175 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
176 AC_MSG_ERROR([[conditional "$1" was never defined.
177 Usually this means the macro was only invoked conditionally.]])
178 fi])])
179
180 # Copyright (C) 1999-2020 Free Software Foundation, Inc.
181 #
182 # This file is free software; the Free Software Foundation
183 # gives unlimited permission to copy and/or distribute it,
184 # with or without modifications, as long as this notice is preserved.
185
186
187 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
188 # written in clear, in which case automake, when reading aclocal.m4,
189 # will think it sees a *use*, and therefore will trigger all it's
190 # C support machinery. Also note that it means that autoscan, seeing
191 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
192
193
194 # _AM_DEPENDENCIES(NAME)
195 # ----------------------
196 # See how the compiler implements dependency checking.
197 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
198 # We try a few techniques and use that to set a single cache variable.
199 #
200 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
201 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
202 # dependency, and given that the user is not expected to run this macro,
203 # just rely on AC_PROG_CC.
204 AC_DEFUN([_AM_DEPENDENCIES],
205 [AC_REQUIRE([AM_SET_DEPDIR])dnl
206 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
207 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
208 AC_REQUIRE([AM_DEP_TRACK])dnl
209
210 m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
211 [$1], [CXX], [depcc="$CXX" am_compiler_list=],
212 [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
213 [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
214 [$1], [UPC], [depcc="$UPC" am_compiler_list=],
215 [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
216 [depcc="$$1" am_compiler_list=])
217
218 AC_CACHE_CHECK([dependency style of $depcc],
219 [am_cv_$1_dependencies_compiler_type],
220 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
221 # We make a subdir and do the tests there. Otherwise we can end up
222 # making bogus files that we don't know about and never remove. For
223 # instance it was reported that on HP-UX the gcc test will end up
224 # making a dummy file named 'D' -- because '-MD' means "put the output
225 # in D".
226 rm -rf conftest.dir
227 mkdir conftest.dir
228 # Copy depcomp to subdir because otherwise we won't find it if we're
229 # using a relative directory.
230 cp "$am_depcomp" conftest.dir
231 cd conftest.dir
232 # We will build objects and dependencies in a subdirectory because
233 # it helps to detect inapplicable dependency modes. For instance
234 # both Tru64's cc and ICC support -MD to output dependencies as a
235 # side effect of compilation, but ICC will put the dependencies in
236 # the current directory while Tru64 will put them in the object
237 # directory.
238 mkdir sub
239
240 am_cv_$1_dependencies_compiler_type=none
241 if test "$am_compiler_list" = ""; then
242 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
243 fi
244 am__universal=false
245 m4_case([$1], [CC],
246 [case " $depcc " in #(
247 *\ -arch\ *\ -arch\ *) am__universal=true ;;
248 esac],
249 [CXX],
250 [case " $depcc " in #(
251 *\ -arch\ *\ -arch\ *) am__universal=true ;;
252 esac])
253
254 for depmode in $am_compiler_list; do
255 # Setup a source with many dependencies, because some compilers
256 # like to wrap large dependency lists on column 80 (with \), and
257 # we should not choose a depcomp mode which is confused by this.
258 #
259 # We need to recreate these files for each test, as the compiler may
260 # overwrite some of them when testing with obscure command lines.
261 # This happens at least with the AIX C compiler.
262 : > sub/conftest.c
263 for i in 1 2 3 4 5 6; do
264 echo '#include "conftst'$i'.h"' >> sub/conftest.c
265 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
266 # Solaris 10 /bin/sh.
267 echo '/* dummy */' > sub/conftst$i.h
268 done
269 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
270
271 # We check with '-c' and '-o' for the sake of the "dashmstdout"
272 # mode. It turns out that the SunPro C++ compiler does not properly
273 # handle '-M -o', and we need to detect this. Also, some Intel
274 # versions had trouble with output in subdirs.
275 am__obj=sub/conftest.${OBJEXT-o}
276 am__minus_obj="-o $am__obj"
277 case $depmode in
278 gcc)
279 # This depmode causes a compiler race in universal mode.
280 test "$am__universal" = false || continue
281 ;;
282 nosideeffect)
283 # After this tag, mechanisms are not by side-effect, so they'll
284 # only be used when explicitly requested.
285 if test "x$enable_dependency_tracking" = xyes; then
286 continue
287 else
288 break
289 fi
290 ;;
291 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
292 # This compiler won't grok '-c -o', but also, the minuso test has
293 # not run yet. These depmodes are late enough in the game, and
294 # so weak that their functioning should not be impacted.
295 am__obj=conftest.${OBJEXT-o}
296 am__minus_obj=
297 ;;
298 none) break ;;
299 esac
300 if depmode=$depmode \
301 source=sub/conftest.c object=$am__obj \
302 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
303 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
304 >/dev/null 2>conftest.err &&
305 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
306 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
307 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
308 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
309 # icc doesn't choke on unknown options, it will just issue warnings
310 # or remarks (even with -Werror). So we grep stderr for any message
311 # that says an option was ignored or not supported.
312 # When given -MP, icc 7.0 and 7.1 complain thusly:
313 # icc: Command line warning: ignoring option '-M'; no argument required
314 # The diagnosis changed in icc 8.0:
315 # icc: Command line remark: option '-MP' not supported
316 if (grep 'ignoring option' conftest.err ||
317 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
318 am_cv_$1_dependencies_compiler_type=$depmode
319 break
320 fi
321 fi
322 done
323
324 cd ..
325 rm -rf conftest.dir
326 else
327 am_cv_$1_dependencies_compiler_type=none
328 fi
329 ])
330 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
331 AM_CONDITIONAL([am__fastdep$1], [
332 test "x$enable_dependency_tracking" != xno \
333 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
334 ])
335
336
337 # AM_SET_DEPDIR
338 # -------------
339 # Choose a directory name for dependency files.
340 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
341 AC_DEFUN([AM_SET_DEPDIR],
342 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
343 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
344 ])
345
346
347 # AM_DEP_TRACK
348 # ------------
349 AC_DEFUN([AM_DEP_TRACK],
350 [AC_ARG_ENABLE([dependency-tracking], [dnl
351 AS_HELP_STRING(
352 [--enable-dependency-tracking],
353 [do not reject slow dependency extractors])
354 AS_HELP_STRING(
355 [--disable-dependency-tracking],
356 [speeds up one-time build])])
357 if test "x$enable_dependency_tracking" != xno; then
358 am_depcomp="$ac_aux_dir/depcomp"
359 AMDEPBACKSLASH='\'
360 am__nodep='_no'
361 fi
362 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
363 AC_SUBST([AMDEPBACKSLASH])dnl
364 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
365 AC_SUBST([am__nodep])dnl
366 _AM_SUBST_NOTMAKE([am__nodep])dnl
367 ])
368
369 # Generate code to set up dependency tracking. -*- Autoconf -*-
370
371 # Copyright (C) 1999-2020 Free Software Foundation, Inc.
372 #
373 # This file is free software; the Free Software Foundation
374 # gives unlimited permission to copy and/or distribute it,
375 # with or without modifications, as long as this notice is preserved.
376
377 # _AM_OUTPUT_DEPENDENCY_COMMANDS
378 # ------------------------------
379 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
380 [{
381 # Older Autoconf quotes --file arguments for eval, but not when files
382 # are listed without --file. Let's play safe and only enable the eval
383 # if we detect the quoting.
384 # TODO: see whether this extra hack can be removed once we start
385 # requiring Autoconf 2.70 or later.
386 AS_CASE([$CONFIG_FILES],
387 [*\'*], [eval set x "$CONFIG_FILES"],
388 [*], [set x $CONFIG_FILES])
389 shift
390 # Used to flag and report bootstrapping failures.
391 am_rc=0
392 for am_mf
393 do
394 # Strip MF so we end up with the name of the file.
395 am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'`
396 # Check whether this is an Automake generated Makefile which includes
397 # dependency-tracking related rules and includes.
398 # Grep'ing the whole file directly is not great: AIX grep has a line
399 # limit of 2048, but all sed's we know have understand at least 4000.
400 sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
401 || continue
402 am_dirpart=`AS_DIRNAME(["$am_mf"])`
403 am_filepart=`AS_BASENAME(["$am_mf"])`
404 AM_RUN_LOG([cd "$am_dirpart" \
405 && sed -e '/# am--include-marker/d' "$am_filepart" \
406 | $MAKE -f - am--depfiles]) || am_rc=$?
407 done
408 if test $am_rc -ne 0; then
409 AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments
410 for automatic dependency tracking. If GNU make was not used, consider
411 re-running the configure script with MAKE="gmake" (or whatever is
412 necessary). You can also try re-running configure with the
413 '--disable-dependency-tracking' option to at least be able to build
414 the package (albeit without support for automatic dependency tracking).])
415 fi
416 AS_UNSET([am_dirpart])
417 AS_UNSET([am_filepart])
418 AS_UNSET([am_mf])
419 AS_UNSET([am_rc])
420 rm -f conftest-deps.mk
421 }
422 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
423
424
425 # AM_OUTPUT_DEPENDENCY_COMMANDS
426 # -----------------------------
427 # This macro should only be invoked once -- use via AC_REQUIRE.
428 #
429 # This code is only required when automatic dependency tracking is enabled.
430 # This creates each '.Po' and '.Plo' makefile fragment that we'll need in
431 # order to bootstrap the dependency handling code.
432 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
433 [AC_CONFIG_COMMANDS([depfiles],
434 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
435 [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])])
436
437 # Do all the work for Automake. -*- Autoconf -*-
438
439 # Copyright (C) 1996-2020 Free Software Foundation, Inc.
440 #
441 # This file is free software; the Free Software Foundation
442 # gives unlimited permission to copy and/or distribute it,
443 # with or without modifications, as long as this notice is preserved.
444
445 # This macro actually does too much. Some checks are only needed if
446 # your package does certain things. But this isn't really a big deal.
447
448 dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
449 m4_define([AC_PROG_CC],
450 m4_defn([AC_PROG_CC])
451 [_AM_PROG_CC_C_O
452 ])
453
454 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
455 # AM_INIT_AUTOMAKE([OPTIONS])
456 # -----------------------------------------------
457 # The call with PACKAGE and VERSION arguments is the old style
458 # call (pre autoconf-2.50), which is being phased out. PACKAGE
459 # and VERSION should now be passed to AC_INIT and removed from
460 # the call to AM_INIT_AUTOMAKE.
461 # We support both call styles for the transition. After
462 # the next Automake release, Autoconf can make the AC_INIT
463 # arguments mandatory, and then we can depend on a new Autoconf
464 # release and drop the old call support.
465 AC_DEFUN([AM_INIT_AUTOMAKE],
466 [AC_PREREQ([2.65])dnl
467 dnl Autoconf wants to disallow AM_ names. We explicitly allow
468 dnl the ones we care about.
469 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
470 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
471 AC_REQUIRE([AC_PROG_INSTALL])dnl
472 if test "`cd $srcdir && pwd`" != "`pwd`"; then
473 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
474 # is not polluted with repeated "-I."
475 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
476 # test to see if srcdir already configured
477 if test -f $srcdir/config.status; then
478 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
479 fi
480 fi
481
482 # test whether we have cygpath
483 if test -z "$CYGPATH_W"; then
484 if (cygpath --version) >/dev/null 2>/dev/null; then
485 CYGPATH_W='cygpath -w'
486 else
487 CYGPATH_W=echo
488 fi
489 fi
490 AC_SUBST([CYGPATH_W])
491
492 # Define the identity of the package.
493 dnl Distinguish between old-style and new-style calls.
494 m4_ifval([$2],
495 [AC_DIAGNOSE([obsolete],
496 [$0: two- and three-arguments forms are deprecated.])
497 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
498 AC_SUBST([PACKAGE], [$1])dnl
499 AC_SUBST([VERSION], [$2])],
500 [_AM_SET_OPTIONS([$1])dnl
501 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
502 m4_if(
503 m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
504 [ok:ok],,
505 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
506 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
507 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
508
509 _AM_IF_OPTION([no-define],,
510 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
511 AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
512
513 # Some tools Automake needs.
514 AC_REQUIRE([AM_SANITY_CHECK])dnl
515 AC_REQUIRE([AC_ARG_PROGRAM])dnl
516 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
517 AM_MISSING_PROG([AUTOCONF], [autoconf])
518 AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
519 AM_MISSING_PROG([AUTOHEADER], [autoheader])
520 AM_MISSING_PROG([MAKEINFO], [makeinfo])
521 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
522 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
523 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
524 # For better backward compatibility. To be removed once Automake 1.9.x
525 # dies out for good. For more background, see:
526 # <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
527 # <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
528 AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
529 # We need awk for the "check" target (and possibly the TAP driver). The
530 # system "awk" is bad on some platforms.
531 AC_REQUIRE([AC_PROG_AWK])dnl
532 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
533 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
534 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
535 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
536 [_AM_PROG_TAR([v7])])])
537 _AM_IF_OPTION([no-dependencies],,
538 [AC_PROVIDE_IFELSE([AC_PROG_CC],
539 [_AM_DEPENDENCIES([CC])],
540 [m4_define([AC_PROG_CC],
541 m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
542 AC_PROVIDE_IFELSE([AC_PROG_CXX],
543 [_AM_DEPENDENCIES([CXX])],
544 [m4_define([AC_PROG_CXX],
545 m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
546 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
547 [_AM_DEPENDENCIES([OBJC])],
548 [m4_define([AC_PROG_OBJC],
549 m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
550 AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
551 [_AM_DEPENDENCIES([OBJCXX])],
552 [m4_define([AC_PROG_OBJCXX],
553 m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
554 ])
555 AC_REQUIRE([AM_SILENT_RULES])dnl
556 dnl The testsuite driver may need to know about EXEEXT, so add the
557 dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
558 dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
559 AC_CONFIG_COMMANDS_PRE(dnl
560 [m4_provide_if([_AM_COMPILER_EXEEXT],
561 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
562
563 # POSIX will say in a future version that running "rm -f" with no argument
564 # is OK; and we want to be able to make that assumption in our Makefile
565 # recipes. So use an aggressive probe to check that the usage we want is
566 # actually supported "in the wild" to an acceptable degree.
567 # See automake bug#10828.
568 # To make any issue more visible, cause the running configure to be aborted
569 # by default if the 'rm' program in use doesn't match our expectations; the
570 # user can still override this though.
571 if rm -f && rm -fr && rm -rf; then : OK; else
572 cat >&2 <<'END'
573 Oops!
574
575 Your 'rm' program seems unable to run without file operands specified
576 on the command line, even when the '-f' option is present. This is contrary
577 to the behaviour of most rm programs out there, and not conforming with
578 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
579
580 Please tell bug-automake@gnu.org about your system, including the value
581 of your $PATH and any error possibly output before this message. This
582 can help us improve future automake versions.
583
584 END
585 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
586 echo 'Configuration will proceed anyway, since you have set the' >&2
587 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
588 echo >&2
589 else
590 cat >&2 <<'END'
591 Aborting the configuration process, to ensure you take notice of the issue.
592
593 You can download and install GNU coreutils to get an 'rm' implementation
594 that behaves properly: <https://www.gnu.org/software/coreutils/>.
595
596 If you want to complete the configuration process using your problematic
597 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
598 to "yes", and re-run configure.
599
600 END
601 AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
602 fi
603 fi
604 dnl The trailing newline in this macro's definition is deliberate, for
605 dnl backward compatibility and to allow trailing 'dnl'-style comments
606 dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
607 ])
608
609 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
610 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
611 dnl mangled by Autoconf and run in a shell conditional statement.
612 m4_define([_AC_COMPILER_EXEEXT],
613 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
614
615 # When config.status generates a header, we must update the stamp-h file.
616 # This file resides in the same directory as the config header
617 # that is generated. The stamp files are numbered to have different names.
618
619 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
620 # loop where config.status creates the headers, so we can generate
621 # our stamp files there.
622 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
623 [# Compute $1's index in $config_headers.
624 _am_arg=$1
625 _am_stamp_count=1
626 for _am_header in $config_headers :; do
627 case $_am_header in
628 $_am_arg | $_am_arg:* )
629 break ;;
630 * )
631 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
632 esac
633 done
634 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
635
636 # Copyright (C) 2001-2020 Free Software Foundation, Inc.
637 #
638 # This file is free software; the Free Software Foundation
639 # gives unlimited permission to copy and/or distribute it,
640 # with or without modifications, as long as this notice is preserved.
641
642 # AM_PROG_INSTALL_SH
643 # ------------------
644 # Define $install_sh.
645 AC_DEFUN([AM_PROG_INSTALL_SH],
646 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
647 if test x"${install_sh+set}" != xset; then
648 case $am_aux_dir in
649 *\ * | *\ *)
650 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
651 *)
652 install_sh="\${SHELL} $am_aux_dir/install-sh"
653 esac
654 fi
655 AC_SUBST([install_sh])])
656
657 # Copyright (C) 2003-2020 Free Software Foundation, Inc.
658 #
659 # This file is free software; the Free Software Foundation
660 # gives unlimited permission to copy and/or distribute it,
661 # with or without modifications, as long as this notice is preserved.
662
663 # Check whether the underlying file-system supports filenames
664 # with a leading dot. For instance MS-DOS doesn't.
665 AC_DEFUN([AM_SET_LEADING_DOT],
666 [rm -rf .tst 2>/dev/null
667 mkdir .tst 2>/dev/null
668 if test -d .tst; then
669 am__leading_dot=.
670 else
671 am__leading_dot=_
672 fi
673 rmdir .tst 2>/dev/null
674 AC_SUBST([am__leading_dot])])
675
676 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
677 # From Jim Meyering
678
679 # Copyright (C) 1996-2020 Free Software Foundation, Inc.
680 #
681 # This file is free software; the Free Software Foundation
682 # gives unlimited permission to copy and/or distribute it,
683 # with or without modifications, as long as this notice is preserved.
684
685 # AM_MAINTAINER_MODE([DEFAULT-MODE])
686 # ----------------------------------
687 # Control maintainer-specific portions of Makefiles.
688 # Default is to disable them, unless 'enable' is passed literally.
689 # For symmetry, 'disable' may be passed as well. Anyway, the user
690 # can override the default with the --enable/--disable switch.
691 AC_DEFUN([AM_MAINTAINER_MODE],
692 [m4_case(m4_default([$1], [disable]),
693 [enable], [m4_define([am_maintainer_other], [disable])],
694 [disable], [m4_define([am_maintainer_other], [enable])],
695 [m4_define([am_maintainer_other], [enable])
696 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
697 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
698 dnl maintainer-mode's default is 'disable' unless 'enable' is passed
699 AC_ARG_ENABLE([maintainer-mode],
700 [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
701 am_maintainer_other[ make rules and dependencies not useful
702 (and sometimes confusing) to the casual installer])],
703 [USE_MAINTAINER_MODE=$enableval],
704 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
705 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
706 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
707 MAINT=$MAINTAINER_MODE_TRUE
708 AC_SUBST([MAINT])dnl
709 ]
710 )
711
712 # Check to see how 'make' treats includes. -*- Autoconf -*-
713
714 # Copyright (C) 2001-2020 Free Software Foundation, Inc.
715 #
716 # This file is free software; the Free Software Foundation
717 # gives unlimited permission to copy and/or distribute it,
718 # with or without modifications, as long as this notice is preserved.
719
720 # AM_MAKE_INCLUDE()
721 # -----------------
722 # Check whether make has an 'include' directive that can support all
723 # the idioms we need for our automatic dependency tracking code.
724 AC_DEFUN([AM_MAKE_INCLUDE],
725 [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive])
726 cat > confinc.mk << 'END'
727 am__doit:
728 @echo this is the am__doit target >confinc.out
729 .PHONY: am__doit
730 END
731 am__include="#"
732 am__quote=
733 # BSD make does it like this.
734 echo '.include "confinc.mk" # ignored' > confmf.BSD
735 # Other make implementations (GNU, Solaris 10, AIX) do it like this.
736 echo 'include confinc.mk # ignored' > confmf.GNU
737 _am_result=no
738 for s in GNU BSD; do
739 AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out])
740 AS_CASE([$?:`cat confinc.out 2>/dev/null`],
741 ['0:this is the am__doit target'],
742 [AS_CASE([$s],
743 [BSD], [am__include='.include' am__quote='"'],
744 [am__include='include' am__quote=''])])
745 if test "$am__include" != "#"; then
746 _am_result="yes ($s style)"
747 break
748 fi
749 done
750 rm -f confinc.* confmf.*
751 AC_MSG_RESULT([${_am_result}])
752 AC_SUBST([am__include])])
753 AC_SUBST([am__quote])])
754
755 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
756
757 # Copyright (C) 1997-2020 Free Software Foundation, Inc.
758 #
759 # This file is free software; the Free Software Foundation
760 # gives unlimited permission to copy and/or distribute it,
761 # with or without modifications, as long as this notice is preserved.
762
763 # AM_MISSING_PROG(NAME, PROGRAM)
764 # ------------------------------
765 AC_DEFUN([AM_MISSING_PROG],
766 [AC_REQUIRE([AM_MISSING_HAS_RUN])
767 $1=${$1-"${am_missing_run}$2"}
768 AC_SUBST($1)])
769
770 # AM_MISSING_HAS_RUN
771 # ------------------
772 # Define MISSING if not defined so far and test if it is modern enough.
773 # If it is, set am_missing_run to use it, otherwise, to nothing.
774 AC_DEFUN([AM_MISSING_HAS_RUN],
775 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
776 AC_REQUIRE_AUX_FILE([missing])dnl
777 if test x"${MISSING+set}" != xset; then
778 MISSING="\${SHELL} '$am_aux_dir/missing'"
779 fi
780 # Use eval to expand $SHELL
781 if eval "$MISSING --is-lightweight"; then
782 am_missing_run="$MISSING "
783 else
784 am_missing_run=
785 AC_MSG_WARN(['missing' script is too old or missing])
786 fi
787 ])
788
789 # Helper functions for option handling. -*- Autoconf -*-
790
791 # Copyright (C) 2001-2020 Free Software Foundation, Inc.
792 #
793 # This file is free software; the Free Software Foundation
794 # gives unlimited permission to copy and/or distribute it,
795 # with or without modifications, as long as this notice is preserved.
796
797 # _AM_MANGLE_OPTION(NAME)
798 # -----------------------
799 AC_DEFUN([_AM_MANGLE_OPTION],
800 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
801
802 # _AM_SET_OPTION(NAME)
803 # --------------------
804 # Set option NAME. Presently that only means defining a flag for this option.
805 AC_DEFUN([_AM_SET_OPTION],
806 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
807
808 # _AM_SET_OPTIONS(OPTIONS)
809 # ------------------------
810 # OPTIONS is a space-separated list of Automake options.
811 AC_DEFUN([_AM_SET_OPTIONS],
812 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
813
814 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
815 # -------------------------------------------
816 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
817 AC_DEFUN([_AM_IF_OPTION],
818 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
819
820 # Copyright (C) 1999-2020 Free Software Foundation, Inc.
821 #
822 # This file is free software; the Free Software Foundation
823 # gives unlimited permission to copy and/or distribute it,
824 # with or without modifications, as long as this notice is preserved.
825
826 # _AM_PROG_CC_C_O
827 # ---------------
828 # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
829 # to automatically call this.
830 AC_DEFUN([_AM_PROG_CC_C_O],
831 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
832 AC_REQUIRE_AUX_FILE([compile])dnl
833 AC_LANG_PUSH([C])dnl
834 AC_CACHE_CHECK(
835 [whether $CC understands -c and -o together],
836 [am_cv_prog_cc_c_o],
837 [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
838 # Make sure it works both with $CC and with simple cc.
839 # Following AC_PROG_CC_C_O, we do the test twice because some
840 # compilers refuse to overwrite an existing .o file with -o,
841 # though they will create one.
842 am_cv_prog_cc_c_o=yes
843 for am_i in 1 2; do
844 if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
845 && test -f conftest2.$ac_objext; then
846 : OK
847 else
848 am_cv_prog_cc_c_o=no
849 break
850 fi
851 done
852 rm -f core conftest*
853 unset am_i])
854 if test "$am_cv_prog_cc_c_o" != yes; then
855 # Losing compiler, so override with the script.
856 # FIXME: It is wrong to rewrite CC.
857 # But if we don't then we get into trouble of one sort or another.
858 # A longer-term fix would be to have automake use am__CC in this case,
859 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
860 CC="$am_aux_dir/compile $CC"
861 fi
862 AC_LANG_POP([C])])
863
864 # For backward compatibility.
865 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
866
867 # Copyright (C) 2001-2020 Free Software Foundation, Inc.
868 #
869 # This file is free software; the Free Software Foundation
870 # gives unlimited permission to copy and/or distribute it,
871 # with or without modifications, as long as this notice is preserved.
872
873 # AM_RUN_LOG(COMMAND)
874 # -------------------
875 # Run COMMAND, save the exit status in ac_status, and log it.
876 # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
877 AC_DEFUN([AM_RUN_LOG],
878 [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
879 ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
880 ac_status=$?
881 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
882 (exit $ac_status); }])
883
884 # Check to make sure that the build environment is sane. -*- Autoconf -*-
885
886 # Copyright (C) 1996-2020 Free Software Foundation, Inc.
887 #
888 # This file is free software; the Free Software Foundation
889 # gives unlimited permission to copy and/or distribute it,
890 # with or without modifications, as long as this notice is preserved.
891
892 # AM_SANITY_CHECK
893 # ---------------
894 AC_DEFUN([AM_SANITY_CHECK],
895 [AC_MSG_CHECKING([whether build environment is sane])
896 # Reject unsafe characters in $srcdir or the absolute working directory
897 # name. Accept space and tab only in the latter.
898 am_lf='
899 '
900 case `pwd` in
901 *[[\\\"\#\$\&\'\`$am_lf]]*)
902 AC_MSG_ERROR([unsafe absolute working directory name]);;
903 esac
904 case $srcdir in
905 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
906 AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
907 esac
908
909 # Do 'set' in a subshell so we don't clobber the current shell's
910 # arguments. Must try -L first in case configure is actually a
911 # symlink; some systems play weird games with the mod time of symlinks
912 # (eg FreeBSD returns the mod time of the symlink's containing
913 # directory).
914 if (
915 am_has_slept=no
916 for am_try in 1 2; do
917 echo "timestamp, slept: $am_has_slept" > conftest.file
918 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
919 if test "$[*]" = "X"; then
920 # -L didn't work.
921 set X `ls -t "$srcdir/configure" conftest.file`
922 fi
923 if test "$[*]" != "X $srcdir/configure conftest.file" \
924 && test "$[*]" != "X conftest.file $srcdir/configure"; then
925
926 # If neither matched, then we have a broken ls. This can happen
927 # if, for instance, CONFIG_SHELL is bash and it inherits a
928 # broken ls alias from the environment. This has actually
929 # happened. Such a system could not be considered "sane".
930 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
931 alias in your environment])
932 fi
933 if test "$[2]" = conftest.file || test $am_try -eq 2; then
934 break
935 fi
936 # Just in case.
937 sleep 1
938 am_has_slept=yes
939 done
940 test "$[2]" = conftest.file
941 )
942 then
943 # Ok.
944 :
945 else
946 AC_MSG_ERROR([newly created file is older than distributed files!
947 Check your system clock])
948 fi
949 AC_MSG_RESULT([yes])
950 # If we didn't sleep, we still need to ensure time stamps of config.status and
951 # generated files are strictly newer.
952 am_sleep_pid=
953 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
954 ( sleep 1 ) &
955 am_sleep_pid=$!
956 fi
957 AC_CONFIG_COMMANDS_PRE(
958 [AC_MSG_CHECKING([that generated files are newer than configure])
959 if test -n "$am_sleep_pid"; then
960 # Hide warnings about reused PIDs.
961 wait $am_sleep_pid 2>/dev/null
962 fi
963 AC_MSG_RESULT([done])])
964 rm -f conftest.file
965 ])
966
967 # Copyright (C) 2009-2020 Free Software Foundation, Inc.
968 #
969 # This file is free software; the Free Software Foundation
970 # gives unlimited permission to copy and/or distribute it,
971 # with or without modifications, as long as this notice is preserved.
972
973 # AM_SILENT_RULES([DEFAULT])
974 # --------------------------
975 # Enable less verbose build rules; with the default set to DEFAULT
976 # ("yes" being less verbose, "no" or empty being verbose).
977 AC_DEFUN([AM_SILENT_RULES],
978 [AC_ARG_ENABLE([silent-rules], [dnl
979 AS_HELP_STRING(
980 [--enable-silent-rules],
981 [less verbose build output (undo: "make V=1")])
982 AS_HELP_STRING(
983 [--disable-silent-rules],
984 [verbose build output (undo: "make V=0")])dnl
985 ])
986 case $enable_silent_rules in @%:@ (((
987 yes) AM_DEFAULT_VERBOSITY=0;;
988 no) AM_DEFAULT_VERBOSITY=1;;
989 *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
990 esac
991 dnl
992 dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
993 dnl do not support nested variable expansions.
994 dnl See automake bug#9928 and bug#10237.
995 am_make=${MAKE-make}
996 AC_CACHE_CHECK([whether $am_make supports nested variables],
997 [am_cv_make_support_nested_variables],
998 [if AS_ECHO([['TRUE=$(BAR$(V))
999 BAR0=false
1000 BAR1=true
1001 V=1
1002 am__doit:
1003 @$(TRUE)
1004 .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
1005 am_cv_make_support_nested_variables=yes
1006 else
1007 am_cv_make_support_nested_variables=no
1008 fi])
1009 if test $am_cv_make_support_nested_variables = yes; then
1010 dnl Using '$V' instead of '$(V)' breaks IRIX make.
1011 AM_V='$(V)'
1012 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
1013 else
1014 AM_V=$AM_DEFAULT_VERBOSITY
1015 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
1016 fi
1017 AC_SUBST([AM_V])dnl
1018 AM_SUBST_NOTMAKE([AM_V])dnl
1019 AC_SUBST([AM_DEFAULT_V])dnl
1020 AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
1021 AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
1022 AM_BACKSLASH='\'
1023 AC_SUBST([AM_BACKSLASH])dnl
1024 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
1025 ])
1026
1027 # Copyright (C) 2001-2020 Free Software Foundation, Inc.
1028 #
1029 # This file is free software; the Free Software Foundation
1030 # gives unlimited permission to copy and/or distribute it,
1031 # with or without modifications, as long as this notice is preserved.
1032
1033 # AM_PROG_INSTALL_STRIP
1034 # ---------------------
1035 # One issue with vendor 'install' (even GNU) is that you can't
1036 # specify the program used to strip binaries. This is especially
1037 # annoying in cross-compiling environments, where the build's strip
1038 # is unlikely to handle the host's binaries.
1039 # Fortunately install-sh will honor a STRIPPROG variable, so we
1040 # always use install-sh in "make install-strip", and initialize
1041 # STRIPPROG with the value of the STRIP variable (set by the user).
1042 AC_DEFUN([AM_PROG_INSTALL_STRIP],
1043 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
1044 # Installed binaries are usually stripped using 'strip' when the user
1045 # run "make install-strip". However 'strip' might not be the right
1046 # tool to use in cross-compilation environments, therefore Automake
1047 # will honor the 'STRIP' environment variable to overrule this program.
1048 dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
1049 if test "$cross_compiling" != no; then
1050 AC_CHECK_TOOL([STRIP], [strip], :)
1051 fi
1052 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
1053 AC_SUBST([INSTALL_STRIP_PROGRAM])])
1054
1055 # Copyright (C) 2006-2020 Free Software Foundation, Inc.
1056 #
1057 # This file is free software; the Free Software Foundation
1058 # gives unlimited permission to copy and/or distribute it,
1059 # with or without modifications, as long as this notice is preserved.
1060
1061 # _AM_SUBST_NOTMAKE(VARIABLE)
1062 # ---------------------------
1063 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
1064 # This macro is traced by Automake.
1065 AC_DEFUN([_AM_SUBST_NOTMAKE])
1066
1067 # AM_SUBST_NOTMAKE(VARIABLE)
1068 # --------------------------
1069 # Public sister of _AM_SUBST_NOTMAKE.
1070 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
1071
1072 # Check how to create a tarball. -*- Autoconf -*-
1073
1074 # Copyright (C) 2004-2020 Free Software Foundation, Inc.
1075 #
1076 # This file is free software; the Free Software Foundation
1077 # gives unlimited permission to copy and/or distribute it,
1078 # with or without modifications, as long as this notice is preserved.
1079
1080 # _AM_PROG_TAR(FORMAT)
1081 # --------------------
1082 # Check how to create a tarball in format FORMAT.
1083 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
1084 #
1085 # Substitute a variable $(am__tar) that is a command
1086 # writing to stdout a FORMAT-tarball containing the directory
1087 # $tardir.
1088 # tardir=directory && $(am__tar) > result.tar
1089 #
1090 # Substitute a variable $(am__untar) that extract such
1091 # a tarball read from stdin.
1092 # $(am__untar) < result.tar
1093 #
1094 AC_DEFUN([_AM_PROG_TAR],
1095 [# Always define AMTAR for backward compatibility. Yes, it's still used
1096 # in the wild :-( We should find a proper way to deprecate it ...
1097 AC_SUBST([AMTAR], ['$${TAR-tar}'])
1098
1099 # We'll loop over all known methods to create a tar archive until one works.
1100 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
1101
1102 m4_if([$1], [v7],
1103 [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
1104
1105 [m4_case([$1],
1106 [ustar],
1107 [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
1108 # There is notably a 21 bits limit for the UID and the GID. In fact,
1109 # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
1110 # and bug#13588).
1111 am_max_uid=2097151 # 2^21 - 1
1112 am_max_gid=$am_max_uid
1113 # The $UID and $GID variables are not portable, so we need to resort
1114 # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
1115 # below are definitely unexpected, so allow the users to see them
1116 # (that is, avoid stderr redirection).
1117 am_uid=`id -u || echo unknown`
1118 am_gid=`id -g || echo unknown`
1119 AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
1120 if test $am_uid -le $am_max_uid; then
1121 AC_MSG_RESULT([yes])
1122 else
1123 AC_MSG_RESULT([no])
1124 _am_tools=none
1125 fi
1126 AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
1127 if test $am_gid -le $am_max_gid; then
1128 AC_MSG_RESULT([yes])
1129 else
1130 AC_MSG_RESULT([no])
1131 _am_tools=none
1132 fi],
1133
1134 [pax],
1135 [],
1136
1137 [m4_fatal([Unknown tar format])])
1138
1139 AC_MSG_CHECKING([how to create a $1 tar archive])
1140
1141 # Go ahead even if we have the value already cached. We do so because we
1142 # need to set the values for the 'am__tar' and 'am__untar' variables.
1143 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
1144
1145 for _am_tool in $_am_tools; do
1146 case $_am_tool in
1147 gnutar)
1148 for _am_tar in tar gnutar gtar; do
1149 AM_RUN_LOG([$_am_tar --version]) && break
1150 done
1151 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
1152 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
1153 am__untar="$_am_tar -xf -"
1154 ;;
1155 plaintar)
1156 # Must skip GNU tar: if it does not support --format= it doesn't create
1157 # ustar tarball either.
1158 (tar --version) >/dev/null 2>&1 && continue
1159 am__tar='tar chf - "$$tardir"'
1160 am__tar_='tar chf - "$tardir"'
1161 am__untar='tar xf -'
1162 ;;
1163 pax)
1164 am__tar='pax -L -x $1 -w "$$tardir"'
1165 am__tar_='pax -L -x $1 -w "$tardir"'
1166 am__untar='pax -r'
1167 ;;
1168 cpio)
1169 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
1170 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
1171 am__untar='cpio -i -H $1 -d'
1172 ;;
1173 none)
1174 am__tar=false
1175 am__tar_=false
1176 am__untar=false
1177 ;;
1178 esac
1179
1180 # If the value was cached, stop now. We just wanted to have am__tar
1181 # and am__untar set.
1182 test -n "${am_cv_prog_tar_$1}" && break
1183
1184 # tar/untar a dummy directory, and stop if the command works.
1185 rm -rf conftest.dir
1186 mkdir conftest.dir
1187 echo GrepMe > conftest.dir/file
1188 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
1189 rm -rf conftest.dir
1190 if test -s conftest.tar; then
1191 AM_RUN_LOG([$am__untar <conftest.tar])
1192 AM_RUN_LOG([cat conftest.dir/file])
1193 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
1194 fi
1195 done
1196 rm -rf conftest.dir
1197
1198 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
1199 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
1200
1201 AC_SUBST([am__tar])
1202 AC_SUBST([am__untar])
1203 ]) # _AM_PROG_TAR
1204
1205 m4_include([m4/ax_cxx_compile_stdcxx.m4])
1206 m4_include([m4/ax_pkg_swig.m4])
1207 m4_include([m4/ax_python_devel.m4])
1208 m4_include([m4/glib-2.0.m4])
1209 m4_include([m4/glibc21.m4])
1210 m4_include([m4/gnupg-ttyname.m4])
1211 m4_include([m4/gpg-error.m4])
1212 m4_include([m4/libassuan.m4])
1213 m4_include([m4/libtool.m4])
1214 m4_include([m4/ltoptions.m4])
1215 m4_include([m4/ltsugar.m4])
1216 m4_include([m4/ltversion.m4])
1217 m4_include([m4/lt~obsolete.m4])
1218 m4_include([m4/pkg.m4])
1219 m4_include([m4/python.m4])
1220 m4_include([m4/qt.m4])
1221 m4_include([acinclude.m4])
0 #! /bin/sh
1 # Wrapper for compilers which do not understand '-c -o'.
2
3 scriptversion=2012-10-14.11; # UTC
4
5 # Copyright (C) 1999-2013 Free Software Foundation, Inc.
6 # Written by Tom Tromey <tromey@cygnus.com>.
7 #
8 # This program is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation; either version 2, or (at your option)
11 # any later version.
12 #
13 # This program is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
17 #
18 # You should have received a copy of the GNU General Public License
19 # along with this program. If not, see <https://www.gnu.org/licenses/>.
20
21 # As a special exception to the GNU General Public License, if you
22 # distribute this file as part of a program that contains a
23 # configuration script generated by Autoconf, you may include it under
24 # the same distribution terms that you use for the rest of that program.
25
26 # This file is maintained in Automake, please report
27 # bugs to <bug-automake@gnu.org> or send patches to
28 # <automake-patches@gnu.org>.
29
30 nl='
31 '
32
33 # We need space, tab and new line, in precisely that order. Quoting is
34 # there to prevent tools from complaining about whitespace usage.
35 IFS=" "" $nl"
36
37 file_conv=
38
39 # func_file_conv build_file lazy
40 # Convert a $build file to $host form and store it in $file
41 # Currently only supports Windows hosts. If the determined conversion
42 # type is listed in (the comma separated) LAZY, no conversion will
43 # take place.
44 func_file_conv ()
45 {
46 file=$1
47 case $file in
48 / | /[!/]*) # absolute file, and not a UNC file
49 if test -z "$file_conv"; then
50 # lazily determine how to convert abs files
51 case `uname -s` in
52 MINGW*)
53 file_conv=mingw
54 ;;
55 CYGWIN*)
56 file_conv=cygwin
57 ;;
58 *)
59 file_conv=wine
60 ;;
61 esac
62 fi
63 case $file_conv/,$2, in
64 *,$file_conv,*)
65 ;;
66 mingw/*)
67 file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
68 ;;
69 cygwin/*)
70 file=`cygpath -m "$file" || echo "$file"`
71 ;;
72 wine/*)
73 file=`winepath -w "$file" || echo "$file"`
74 ;;
75 esac
76 ;;
77 esac
78 }
79
80 # func_cl_dashL linkdir
81 # Make cl look for libraries in LINKDIR
82 func_cl_dashL ()
83 {
84 func_file_conv "$1"
85 if test -z "$lib_path"; then
86 lib_path=$file
87 else
88 lib_path="$lib_path;$file"
89 fi
90 linker_opts="$linker_opts -LIBPATH:$file"
91 }
92
93 # func_cl_dashl library
94 # Do a library search-path lookup for cl
95 func_cl_dashl ()
96 {
97 lib=$1
98 found=no
99 save_IFS=$IFS
100 IFS=';'
101 for dir in $lib_path $LIB
102 do
103 IFS=$save_IFS
104 if $shared && test -f "$dir/$lib.dll.lib"; then
105 found=yes
106 lib=$dir/$lib.dll.lib
107 break
108 fi
109 if test -f "$dir/$lib.lib"; then
110 found=yes
111 lib=$dir/$lib.lib
112 break
113 fi
114 if test -f "$dir/lib$lib.a"; then
115 found=yes
116 lib=$dir/lib$lib.a
117 break
118 fi
119 done
120 IFS=$save_IFS
121
122 if test "$found" != yes; then
123 lib=$lib.lib
124 fi
125 }
126
127 # func_cl_wrapper cl arg...
128 # Adjust compile command to suit cl
129 func_cl_wrapper ()
130 {
131 # Assume a capable shell
132 lib_path=
133 shared=:
134 linker_opts=
135 for arg
136 do
137 if test -n "$eat"; then
138 eat=
139 else
140 case $1 in
141 -o)
142 # configure might choose to run compile as 'compile cc -o foo foo.c'.
143 eat=1
144 case $2 in
145 *.o | *.[oO][bB][jJ])
146 func_file_conv "$2"
147 set x "$@" -Fo"$file"
148 shift
149 ;;
150 *)
151 func_file_conv "$2"
152 set x "$@" -Fe"$file"
153 shift
154 ;;
155 esac
156 ;;
157 -I)
158 eat=1
159 func_file_conv "$2" mingw
160 set x "$@" -I"$file"
161 shift
162 ;;
163 -I*)
164 func_file_conv "${1#-I}" mingw
165 set x "$@" -I"$file"
166 shift
167 ;;
168 -l)
169 eat=1
170 func_cl_dashl "$2"
171 set x "$@" "$lib"
172 shift
173 ;;
174 -l*)
175 func_cl_dashl "${1#-l}"
176 set x "$@" "$lib"
177 shift
178 ;;
179 -L)
180 eat=1
181 func_cl_dashL "$2"
182 ;;
183 -L*)
184 func_cl_dashL "${1#-L}"
185 ;;
186 -static)
187 shared=false
188 ;;
189 -Wl,*)
190 arg=${1#-Wl,}
191 save_ifs="$IFS"; IFS=','
192 for flag in $arg; do
193 IFS="$save_ifs"
194 linker_opts="$linker_opts $flag"
195 done
196 IFS="$save_ifs"
197 ;;
198 -Xlinker)
199 eat=1
200 linker_opts="$linker_opts $2"
201 ;;
202 -*)
203 set x "$@" "$1"
204 shift
205 ;;
206 *.cc | *.CC | *.cxx | *.CXX | *.[cC]++)
207 func_file_conv "$1"
208 set x "$@" -Tp"$file"
209 shift
210 ;;
211 *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO])
212 func_file_conv "$1" mingw
213 set x "$@" "$file"
214 shift
215 ;;
216 *)
217 set x "$@" "$1"
218 shift
219 ;;
220 esac
221 fi
222 shift
223 done
224 if test -n "$linker_opts"; then
225 linker_opts="-link$linker_opts"
226 fi
227 exec "$@" $linker_opts
228 exit 1
229 }
230
231 eat=
232
233 case $1 in
234 '')
235 echo "$0: No command. Try '$0 --help' for more information." 1>&2
236 exit 1;
237 ;;
238 -h | --h*)
239 cat <<\EOF
240 Usage: compile [--help] [--version] PROGRAM [ARGS]
241
242 Wrapper for compilers which do not understand '-c -o'.
243 Remove '-o dest.o' from ARGS, run PROGRAM with the remaining
244 arguments, and rename the output as expected.
245
246 If you are trying to build a whole package this is not the
247 right script to run: please start by reading the file 'INSTALL'.
248
249 Report bugs to <bug-automake@gnu.org>.
250 EOF
251 exit $?
252 ;;
253 -v | --v*)
254 echo "compile $scriptversion"
255 exit $?
256 ;;
257 cl | *[/\\]cl | cl.exe | *[/\\]cl.exe )
258 func_cl_wrapper "$@" # Doesn't return...
259 ;;
260 esac
261
262 ofile=
263 cfile=
264
265 for arg
266 do
267 if test -n "$eat"; then
268 eat=
269 else
270 case $1 in
271 -o)
272 # configure might choose to run compile as 'compile cc -o foo foo.c'.
273 # So we strip '-o arg' only if arg is an object.
274 eat=1
275 case $2 in
276 *.o | *.obj)
277 ofile=$2
278 ;;
279 *)
280 set x "$@" -o "$2"
281 shift
282 ;;
283 esac
284 ;;
285 *.c)
286 cfile=$1
287 set x "$@" "$1"
288 shift
289 ;;
290 *)
291 set x "$@" "$1"
292 shift
293 ;;
294 esac
295 fi
296 shift
297 done
298
299 if test -z "$ofile" || test -z "$cfile"; then
300 # If no '-o' option was seen then we might have been invoked from a
301 # pattern rule where we don't need one. That is ok -- this is a
302 # normal compilation that the losing compiler can handle. If no
303 # '.c' file was seen then we are probably linking. That is also
304 # ok.
305 exec "$@"
306 fi
307
308 # Name of file we expect compiler to create.
309 cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'`
310
311 # Create the lock directory.
312 # Note: use '[/\\:.-]' here to ensure that we don't use the same name
313 # that we are using for the .o file. Also, base the name on the expected
314 # object file name, since that is what matters with a parallel build.
315 lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d
316 while true; do
317 if mkdir "$lockdir" >/dev/null 2>&1; then
318 break
319 fi
320 sleep 1
321 done
322 # FIXME: race condition here if user kills between mkdir and trap.
323 trap "rmdir '$lockdir'; exit 1" 1 2 15
324
325 # Run the compile.
326 "$@"
327 ret=$?
328
329 if test -f "$cofile"; then
330 test "$cofile" = "$ofile" || mv "$cofile" "$ofile"
331 elif test -f "${cofile}bj"; then
332 test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile"
333 fi
334
335 rmdir "$lockdir"
336 exit $ret
337
338 # Local Variables:
339 # mode: shell-script
340 # sh-indentation: 2
341 # eval: (add-hook 'write-file-hooks 'time-stamp)
342 # time-stamp-start: "scriptversion="
343 # time-stamp-format: "%:y-%02m-%02d.%02H"
344 # time-stamp-time-zone: "UTC"
345 # time-stamp-end: "; # UTC"
346 # End:
0 #! /bin/sh
1 # depcomp - compile a program generating dependencies as side-effects
2
3 scriptversion=2013-05-30.07; # UTC
4
5 # Copyright (C) 1999-2013 Free Software Foundation, Inc.
6
7 # This program is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2, or (at your option)
10 # any later version.
11
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16
17 # You should have received a copy of the GNU General Public License
18 # along with this program. If not, see <https://www.gnu.org/licenses/>.
19
20 # As a special exception to the GNU General Public License, if you
21 # distribute this file as part of a program that contains a
22 # configuration script generated by Autoconf, you may include it under
23 # the same distribution terms that you use for the rest of that program.
24
25 # Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
26
27 case $1 in
28 '')
29 echo "$0: No command. Try '$0 --help' for more information." 1>&2
30 exit 1;
31 ;;
32 -h | --h*)
33 cat <<\EOF
34 Usage: depcomp [--help] [--version] PROGRAM [ARGS]
35
36 Run PROGRAMS ARGS to compile a file, generating dependencies
37 as side-effects.
38
39 Environment variables:
40 depmode Dependency tracking mode.
41 source Source file read by 'PROGRAMS ARGS'.
42 object Object file output by 'PROGRAMS ARGS'.
43 DEPDIR directory where to store dependencies.
44 depfile Dependency file to output.
45 tmpdepfile Temporary file to use when outputting dependencies.
46 libtool Whether libtool is used (yes/no).
47
48 Report bugs to <bug-automake@gnu.org>.
49 EOF
50 exit $?
51 ;;
52 -v | --v*)
53 echo "depcomp $scriptversion"
54 exit $?
55 ;;
56 esac
57
58 # Get the directory component of the given path, and save it in the
59 # global variables '$dir'. Note that this directory component will
60 # be either empty or ending with a '/' character. This is deliberate.
61 set_dir_from ()
62 {
63 case $1 in
64 */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;;
65 *) dir=;;
66 esac
67 }
68
69 # Get the suffix-stripped basename of the given path, and save it the
70 # global variable '$base'.
71 set_base_from ()
72 {
73 base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'`
74 }
75
76 # If no dependency file was actually created by the compiler invocation,
77 # we still have to create a dummy depfile, to avoid errors with the
78 # Makefile "include basename.Plo" scheme.
79 make_dummy_depfile ()
80 {
81 echo "#dummy" > "$depfile"
82 }
83
84 # Factor out some common post-processing of the generated depfile.
85 # Requires the auxiliary global variable '$tmpdepfile' to be set.
86 aix_post_process_depfile ()
87 {
88 # If the compiler actually managed to produce a dependency file,
89 # post-process it.
90 if test -f "$tmpdepfile"; then
91 # Each line is of the form 'foo.o: dependency.h'.
92 # Do two passes, one to just change these to
93 # $object: dependency.h
94 # and one to simply output
95 # dependency.h:
96 # which is needed to avoid the deleted-header problem.
97 { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile"
98 sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile"
99 } > "$depfile"
100 rm -f "$tmpdepfile"
101 else
102 make_dummy_depfile
103 fi
104 }
105
106 # A tabulation character.
107 tab=' '
108 # A newline character.
109 nl='
110 '
111 # Character ranges might be problematic outside the C locale.
112 # These definitions help.
113 upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ
114 lower=abcdefghijklmnopqrstuvwxyz
115 digits=0123456789
116 alpha=${upper}${lower}
117
118 if test -z "$depmode" || test -z "$source" || test -z "$object"; then
119 echo "depcomp: Variables source, object and depmode must be set" 1>&2
120 exit 1
121 fi
122
123 # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
124 depfile=${depfile-`echo "$object" |
125 sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
126 tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
127
128 rm -f "$tmpdepfile"
129
130 # Avoid interferences from the environment.
131 gccflag= dashmflag=
132
133 # Some modes work just like other modes, but use different flags. We
134 # parameterize here, but still list the modes in the big case below,
135 # to make depend.m4 easier to write. Note that we *cannot* use a case
136 # here, because this file can only contain one case statement.
137 if test "$depmode" = hp; then
138 # HP compiler uses -M and no extra arg.
139 gccflag=-M
140 depmode=gcc
141 fi
142
143 if test "$depmode" = dashXmstdout; then
144 # This is just like dashmstdout with a different argument.
145 dashmflag=-xM
146 depmode=dashmstdout
147 fi
148
149 cygpath_u="cygpath -u -f -"
150 if test "$depmode" = msvcmsys; then
151 # This is just like msvisualcpp but w/o cygpath translation.
152 # Just convert the backslash-escaped backslashes to single forward
153 # slashes to satisfy depend.m4
154 cygpath_u='sed s,\\\\,/,g'
155 depmode=msvisualcpp
156 fi
157
158 if test "$depmode" = msvc7msys; then
159 # This is just like msvc7 but w/o cygpath translation.
160 # Just convert the backslash-escaped backslashes to single forward
161 # slashes to satisfy depend.m4
162 cygpath_u='sed s,\\\\,/,g'
163 depmode=msvc7
164 fi
165
166 if test "$depmode" = xlc; then
167 # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information.
168 gccflag=-qmakedep=gcc,-MF
169 depmode=gcc
170 fi
171
172 case "$depmode" in
173 gcc3)
174 ## gcc 3 implements dependency tracking that does exactly what
175 ## we want. Yay! Note: for some reason libtool 1.4 doesn't like
176 ## it if -MD -MP comes after the -MF stuff. Hmm.
177 ## Unfortunately, FreeBSD c89 acceptance of flags depends upon
178 ## the command line argument order; so add the flags where they
179 ## appear in depend2.am. Note that the slowdown incurred here
180 ## affects only configure: in makefiles, %FASTDEP% shortcuts this.
181 for arg
182 do
183 case $arg in
184 -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;;
185 *) set fnord "$@" "$arg" ;;
186 esac
187 shift # fnord
188 shift # $arg
189 done
190 "$@"
191 stat=$?
192 if test $stat -ne 0; then
193 rm -f "$tmpdepfile"
194 exit $stat
195 fi
196 mv "$tmpdepfile" "$depfile"
197 ;;
198
199 gcc)
200 ## Note that this doesn't just cater to obsosete pre-3.x GCC compilers.
201 ## but also to in-use compilers like IMB xlc/xlC and the HP C compiler.
202 ## (see the conditional assignment to $gccflag above).
203 ## There are various ways to get dependency output from gcc. Here's
204 ## why we pick this rather obscure method:
205 ## - Don't want to use -MD because we'd like the dependencies to end
206 ## up in a subdir. Having to rename by hand is ugly.
207 ## (We might end up doing this anyway to support other compilers.)
208 ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
209 ## -MM, not -M (despite what the docs say). Also, it might not be
210 ## supported by the other compilers which use the 'gcc' depmode.
211 ## - Using -M directly means running the compiler twice (even worse
212 ## than renaming).
213 if test -z "$gccflag"; then
214 gccflag=-MD,
215 fi
216 "$@" -Wp,"$gccflag$tmpdepfile"
217 stat=$?
218 if test $stat -ne 0; then
219 rm -f "$tmpdepfile"
220 exit $stat
221 fi
222 rm -f "$depfile"
223 echo "$object : \\" > "$depfile"
224 # The second -e expression handles DOS-style file names with drive
225 # letters.
226 sed -e 's/^[^:]*: / /' \
227 -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
228 ## This next piece of magic avoids the "deleted header file" problem.
229 ## The problem is that when a header file which appears in a .P file
230 ## is deleted, the dependency causes make to die (because there is
231 ## typically no way to rebuild the header). We avoid this by adding
232 ## dummy dependencies for each header file. Too bad gcc doesn't do
233 ## this for us directly.
234 ## Some versions of gcc put a space before the ':'. On the theory
235 ## that the space means something, we add a space to the output as
236 ## well. hp depmode also adds that space, but also prefixes the VPATH
237 ## to the object. Take care to not repeat it in the output.
238 ## Some versions of the HPUX 10.20 sed can't process this invocation
239 ## correctly. Breaking it into two sed invocations is a workaround.
240 tr ' ' "$nl" < "$tmpdepfile" \
241 | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \
242 | sed -e 's/$/ :/' >> "$depfile"
243 rm -f "$tmpdepfile"
244 ;;
245
246 hp)
247 # This case exists only to let depend.m4 do its work. It works by
248 # looking at the text of this script. This case will never be run,
249 # since it is checked for above.
250 exit 1
251 ;;
252
253 sgi)
254 if test "$libtool" = yes; then
255 "$@" "-Wp,-MDupdate,$tmpdepfile"
256 else
257 "$@" -MDupdate "$tmpdepfile"
258 fi
259 stat=$?
260 if test $stat -ne 0; then
261 rm -f "$tmpdepfile"
262 exit $stat
263 fi
264 rm -f "$depfile"
265
266 if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
267 echo "$object : \\" > "$depfile"
268 # Clip off the initial element (the dependent). Don't try to be
269 # clever and replace this with sed code, as IRIX sed won't handle
270 # lines with more than a fixed number of characters (4096 in
271 # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
272 # the IRIX cc adds comments like '#:fec' to the end of the
273 # dependency line.
274 tr ' ' "$nl" < "$tmpdepfile" \
275 | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \
276 | tr "$nl" ' ' >> "$depfile"
277 echo >> "$depfile"
278 # The second pass generates a dummy entry for each header file.
279 tr ' ' "$nl" < "$tmpdepfile" \
280 | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
281 >> "$depfile"
282 else
283 make_dummy_depfile
284 fi
285 rm -f "$tmpdepfile"
286 ;;
287
288 xlc)
289 # This case exists only to let depend.m4 do its work. It works by
290 # looking at the text of this script. This case will never be run,
291 # since it is checked for above.
292 exit 1
293 ;;
294
295 aix)
296 # The C for AIX Compiler uses -M and outputs the dependencies
297 # in a .u file. In older versions, this file always lives in the
298 # current directory. Also, the AIX compiler puts '$object:' at the
299 # start of each line; $object doesn't have directory information.
300 # Version 6 uses the directory in both cases.
301 set_dir_from "$object"
302 set_base_from "$object"
303 if test "$libtool" = yes; then
304 tmpdepfile1=$dir$base.u
305 tmpdepfile2=$base.u
306 tmpdepfile3=$dir.libs/$base.u
307 "$@" -Wc,-M
308 else
309 tmpdepfile1=$dir$base.u
310 tmpdepfile2=$dir$base.u
311 tmpdepfile3=$dir$base.u
312 "$@" -M
313 fi
314 stat=$?
315 if test $stat -ne 0; then
316 rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
317 exit $stat
318 fi
319
320 for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
321 do
322 test -f "$tmpdepfile" && break
323 done
324 aix_post_process_depfile
325 ;;
326
327 tcc)
328 # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26
329 # FIXME: That version still under development at the moment of writing.
330 # Make that this statement remains true also for stable, released
331 # versions.
332 # It will wrap lines (doesn't matter whether long or short) with a
333 # trailing '\', as in:
334 #
335 # foo.o : \
336 # foo.c \
337 # foo.h \
338 #
339 # It will put a trailing '\' even on the last line, and will use leading
340 # spaces rather than leading tabs (at least since its commit 0394caf7
341 # "Emit spaces for -MD").
342 "$@" -MD -MF "$tmpdepfile"
343 stat=$?
344 if test $stat -ne 0; then
345 rm -f "$tmpdepfile"
346 exit $stat
347 fi
348 rm -f "$depfile"
349 # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'.
350 # We have to change lines of the first kind to '$object: \'.
351 sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile"
352 # And for each line of the second kind, we have to emit a 'dep.h:'
353 # dummy dependency, to avoid the deleted-header problem.
354 sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile"
355 rm -f "$tmpdepfile"
356 ;;
357
358 ## The order of this option in the case statement is important, since the
359 ## shell code in configure will try each of these formats in the order
360 ## listed in this file. A plain '-MD' option would be understood by many
361 ## compilers, so we must ensure this comes after the gcc and icc options.
362 pgcc)
363 # Portland's C compiler understands '-MD'.
364 # Will always output deps to 'file.d' where file is the root name of the
365 # source file under compilation, even if file resides in a subdirectory.
366 # The object file name does not affect the name of the '.d' file.
367 # pgcc 10.2 will output
368 # foo.o: sub/foo.c sub/foo.h
369 # and will wrap long lines using '\' :
370 # foo.o: sub/foo.c ... \
371 # sub/foo.h ... \
372 # ...
373 set_dir_from "$object"
374 # Use the source, not the object, to determine the base name, since
375 # that's sadly what pgcc will do too.
376 set_base_from "$source"
377 tmpdepfile=$base.d
378
379 # For projects that build the same source file twice into different object
380 # files, the pgcc approach of using the *source* file root name can cause
381 # problems in parallel builds. Use a locking strategy to avoid stomping on
382 # the same $tmpdepfile.
383 lockdir=$base.d-lock
384 trap "
385 echo '$0: caught signal, cleaning up...' >&2
386 rmdir '$lockdir'
387 exit 1
388 " 1 2 13 15
389 numtries=100
390 i=$numtries
391 while test $i -gt 0; do
392 # mkdir is a portable test-and-set.
393 if mkdir "$lockdir" 2>/dev/null; then
394 # This process acquired the lock.
395 "$@" -MD
396 stat=$?
397 # Release the lock.
398 rmdir "$lockdir"
399 break
400 else
401 # If the lock is being held by a different process, wait
402 # until the winning process is done or we timeout.
403 while test -d "$lockdir" && test $i -gt 0; do
404 sleep 1
405 i=`expr $i - 1`
406 done
407 fi
408 i=`expr $i - 1`
409 done
410 trap - 1 2 13 15
411 if test $i -le 0; then
412 echo "$0: failed to acquire lock after $numtries attempts" >&2
413 echo "$0: check lockdir '$lockdir'" >&2
414 exit 1
415 fi
416
417 if test $stat -ne 0; then
418 rm -f "$tmpdepfile"
419 exit $stat
420 fi
421 rm -f "$depfile"
422 # Each line is of the form `foo.o: dependent.h',
423 # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
424 # Do two passes, one to just change these to
425 # `$object: dependent.h' and one to simply `dependent.h:'.
426 sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
427 # Some versions of the HPUX 10.20 sed can't process this invocation
428 # correctly. Breaking it into two sed invocations is a workaround.
429 sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \
430 | sed -e 's/$/ :/' >> "$depfile"
431 rm -f "$tmpdepfile"
432 ;;
433
434 hp2)
435 # The "hp" stanza above does not work with aCC (C++) and HP's ia64
436 # compilers, which have integrated preprocessors. The correct option
437 # to use with these is +Maked; it writes dependencies to a file named
438 # 'foo.d', which lands next to the object file, wherever that
439 # happens to be.
440 # Much of this is similar to the tru64 case; see comments there.
441 set_dir_from "$object"
442 set_base_from "$object"
443 if test "$libtool" = yes; then
444 tmpdepfile1=$dir$base.d
445 tmpdepfile2=$dir.libs/$base.d
446 "$@" -Wc,+Maked
447 else
448 tmpdepfile1=$dir$base.d
449 tmpdepfile2=$dir$base.d
450 "$@" +Maked
451 fi
452 stat=$?
453 if test $stat -ne 0; then
454 rm -f "$tmpdepfile1" "$tmpdepfile2"
455 exit $stat
456 fi
457
458 for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2"
459 do
460 test -f "$tmpdepfile" && break
461 done
462 if test -f "$tmpdepfile"; then
463 sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile"
464 # Add 'dependent.h:' lines.
465 sed -ne '2,${
466 s/^ *//
467 s/ \\*$//
468 s/$/:/
469 p
470 }' "$tmpdepfile" >> "$depfile"
471 else
472 make_dummy_depfile
473 fi
474 rm -f "$tmpdepfile" "$tmpdepfile2"
475 ;;
476
477 tru64)
478 # The Tru64 compiler uses -MD to generate dependencies as a side
479 # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'.
480 # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
481 # dependencies in 'foo.d' instead, so we check for that too.
482 # Subdirectories are respected.
483 set_dir_from "$object"
484 set_base_from "$object"
485
486 if test "$libtool" = yes; then
487 # Libtool generates 2 separate objects for the 2 libraries. These
488 # two compilations output dependencies in $dir.libs/$base.o.d and
489 # in $dir$base.o.d. We have to check for both files, because
490 # one of the two compilations can be disabled. We should prefer
491 # $dir$base.o.d over $dir.libs/$base.o.d because the latter is
492 # automatically cleaned when .libs/ is deleted, while ignoring
493 # the former would cause a distcleancheck panic.
494 tmpdepfile1=$dir$base.o.d # libtool 1.5
495 tmpdepfile2=$dir.libs/$base.o.d # Likewise.
496 tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504
497 "$@" -Wc,-MD
498 else
499 tmpdepfile1=$dir$base.d
500 tmpdepfile2=$dir$base.d
501 tmpdepfile3=$dir$base.d
502 "$@" -MD
503 fi
504
505 stat=$?
506 if test $stat -ne 0; then
507 rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
508 exit $stat
509 fi
510
511 for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
512 do
513 test -f "$tmpdepfile" && break
514 done
515 # Same post-processing that is required for AIX mode.
516 aix_post_process_depfile
517 ;;
518
519 msvc7)
520 if test "$libtool" = yes; then
521 showIncludes=-Wc,-showIncludes
522 else
523 showIncludes=-showIncludes
524 fi
525 "$@" $showIncludes > "$tmpdepfile"
526 stat=$?
527 grep -v '^Note: including file: ' "$tmpdepfile"
528 if test $stat -ne 0; then
529 rm -f "$tmpdepfile"
530 exit $stat
531 fi
532 rm -f "$depfile"
533 echo "$object : \\" > "$depfile"
534 # The first sed program below extracts the file names and escapes
535 # backslashes for cygpath. The second sed program outputs the file
536 # name when reading, but also accumulates all include files in the
537 # hold buffer in order to output them again at the end. This only
538 # works with sed implementations that can handle large buffers.
539 sed < "$tmpdepfile" -n '
540 /^Note: including file: *\(.*\)/ {
541 s//\1/
542 s/\\/\\\\/g
543 p
544 }' | $cygpath_u | sort -u | sed -n '
545 s/ /\\ /g
546 s/\(.*\)/'"$tab"'\1 \\/p
547 s/.\(.*\) \\/\1:/
548 H
549 $ {
550 s/.*/'"$tab"'/
551 G
552 p
553 }' >> "$depfile"
554 echo >> "$depfile" # make sure the fragment doesn't end with a backslash
555 rm -f "$tmpdepfile"
556 ;;
557
558 msvc7msys)
559 # This case exists only to let depend.m4 do its work. It works by
560 # looking at the text of this script. This case will never be run,
561 # since it is checked for above.
562 exit 1
563 ;;
564
565 #nosideeffect)
566 # This comment above is used by automake to tell side-effect
567 # dependency tracking mechanisms from slower ones.
568
569 dashmstdout)
570 # Important note: in order to support this mode, a compiler *must*
571 # always write the preprocessed file to stdout, regardless of -o.
572 "$@" || exit $?
573
574 # Remove the call to Libtool.
575 if test "$libtool" = yes; then
576 while test "X$1" != 'X--mode=compile'; do
577 shift
578 done
579 shift
580 fi
581
582 # Remove '-o $object'.
583 IFS=" "
584 for arg
585 do
586 case $arg in
587 -o)
588 shift
589 ;;
590 $object)
591 shift
592 ;;
593 *)
594 set fnord "$@" "$arg"
595 shift # fnord
596 shift # $arg
597 ;;
598 esac
599 done
600
601 test -z "$dashmflag" && dashmflag=-M
602 # Require at least two characters before searching for ':'
603 # in the target name. This is to cope with DOS-style filenames:
604 # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise.
605 "$@" $dashmflag |
606 sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile"
607 rm -f "$depfile"
608 cat < "$tmpdepfile" > "$depfile"
609 # Some versions of the HPUX 10.20 sed can't process this sed invocation
610 # correctly. Breaking it into two sed invocations is a workaround.
611 tr ' ' "$nl" < "$tmpdepfile" \
612 | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \
613 | sed -e 's/$/ :/' >> "$depfile"
614 rm -f "$tmpdepfile"
615 ;;
616
617 dashXmstdout)
618 # This case only exists to satisfy depend.m4. It is never actually
619 # run, as this mode is specially recognized in the preamble.
620 exit 1
621 ;;
622
623 makedepend)
624 "$@" || exit $?
625 # Remove any Libtool call
626 if test "$libtool" = yes; then
627 while test "X$1" != 'X--mode=compile'; do
628 shift
629 done
630 shift
631 fi
632 # X makedepend
633 shift
634 cleared=no eat=no
635 for arg
636 do
637 case $cleared in
638 no)
639 set ""; shift
640 cleared=yes ;;
641 esac
642 if test $eat = yes; then
643 eat=no
644 continue
645 fi
646 case "$arg" in
647 -D*|-I*)
648 set fnord "$@" "$arg"; shift ;;
649 # Strip any option that makedepend may not understand. Remove
650 # the object too, otherwise makedepend will parse it as a source file.
651 -arch)
652 eat=yes ;;
653 -*|$object)
654 ;;
655 *)
656 set fnord "$@" "$arg"; shift ;;
657 esac
658 done
659 obj_suffix=`echo "$object" | sed 's/^.*\././'`
660 touch "$tmpdepfile"
661 ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
662 rm -f "$depfile"
663 # makedepend may prepend the VPATH from the source file name to the object.
664 # No need to regex-escape $object, excess matching of '.' is harmless.
665 sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile"
666 # Some versions of the HPUX 10.20 sed can't process the last invocation
667 # correctly. Breaking it into two sed invocations is a workaround.
668 sed '1,2d' "$tmpdepfile" \
669 | tr ' ' "$nl" \
670 | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \
671 | sed -e 's/$/ :/' >> "$depfile"
672 rm -f "$tmpdepfile" "$tmpdepfile".bak
673 ;;
674
675 cpp)
676 # Important note: in order to support this mode, a compiler *must*
677 # always write the preprocessed file to stdout.
678 "$@" || exit $?
679
680 # Remove the call to Libtool.
681 if test "$libtool" = yes; then
682 while test "X$1" != 'X--mode=compile'; do
683 shift
684 done
685 shift
686 fi
687
688 # Remove '-o $object'.
689 IFS=" "
690 for arg
691 do
692 case $arg in
693 -o)
694 shift
695 ;;
696 $object)
697 shift
698 ;;
699 *)
700 set fnord "$@" "$arg"
701 shift # fnord
702 shift # $arg
703 ;;
704 esac
705 done
706
707 "$@" -E \
708 | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
709 -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
710 | sed '$ s: \\$::' > "$tmpdepfile"
711 rm -f "$depfile"
712 echo "$object : \\" > "$depfile"
713 cat < "$tmpdepfile" >> "$depfile"
714 sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
715 rm -f "$tmpdepfile"
716 ;;
717
718 msvisualcpp)
719 # Important note: in order to support this mode, a compiler *must*
720 # always write the preprocessed file to stdout.
721 "$@" || exit $?
722
723 # Remove the call to Libtool.
724 if test "$libtool" = yes; then
725 while test "X$1" != 'X--mode=compile'; do
726 shift
727 done
728 shift
729 fi
730
731 IFS=" "
732 for arg
733 do
734 case "$arg" in
735 -o)
736 shift
737 ;;
738 $object)
739 shift
740 ;;
741 "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
742 set fnord "$@"
743 shift
744 shift
745 ;;
746 *)
747 set fnord "$@" "$arg"
748 shift
749 shift
750 ;;
751 esac
752 done
753 "$@" -E 2>/dev/null |
754 sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile"
755 rm -f "$depfile"
756 echo "$object : \\" > "$depfile"
757 sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile"
758 echo "$tab" >> "$depfile"
759 sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile"
760 rm -f "$tmpdepfile"
761 ;;
762
763 msvcmsys)
764 # This case exists only to let depend.m4 do its work. It works by
765 # looking at the text of this script. This case will never be run,
766 # since it is checked for above.
767 exit 1
768 ;;
769
770 none)
771 exec "$@"
772 ;;
773
774 *)
775 echo "Unknown depmode $depmode" 1>&2
776 exit 1
777 ;;
778 esac
779
780 exit 0
781
782 # Local Variables:
783 # mode: shell-script
784 # sh-indentation: 2
785 # eval: (add-hook 'write-file-hooks 'time-stamp)
786 # time-stamp-start: "scriptversion="
787 # time-stamp-format: "%:y-%02m-%02d.%02H"
788 # time-stamp-time-zone: "UTC"
789 # time-stamp-end: "; # UTC"
790 # End:
0 #!/bin/sh
1 # install - install a program, script, or datafile
2
3 scriptversion=2011-11-20.07; # UTC
4
5 # This originates from X11R5 (mit/util/scripts/install.sh), which was
6 # later released in X11R6 (xc/config/util/install.sh) with the
7 # following copyright and license.
8 #
9 # Copyright (C) 1994 X Consortium
10 #
11 # Permission is hereby granted, free of charge, to any person obtaining a copy
12 # of this software and associated documentation files (the "Software"), to
13 # deal in the Software without restriction, including without limitation the
14 # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
15 # sell copies of the Software, and to permit persons to whom the Software is
16 # furnished to do so, subject to the following conditions:
17 #
18 # The above copyright notice and this permission notice shall be included in
19 # all copies or substantial portions of the Software.
20 #
21 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
25 # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
26 # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27 #
28 # Except as contained in this notice, the name of the X Consortium shall not
29 # be used in advertising or otherwise to promote the sale, use or other deal-
30 # ings in this Software without prior written authorization from the X Consor-
31 # tium.
32 #
33 #
34 # FSF changes to this file are in the public domain.
35 #
36 # Calling this script install-sh is preferred over install.sh, to prevent
37 # 'make' implicit rules from creating a file called install from it
38 # when there is no Makefile.
39 #
40 # This script is compatible with the BSD install script, but was written
41 # from scratch.
42
43 nl='
44 '
45 IFS=" "" $nl"
46
47 # set DOITPROG to echo to test this script
48
49 # Don't use :- since 4.3BSD and earlier shells don't like it.
50 doit=${DOITPROG-}
51 if test -z "$doit"; then
52 doit_exec=exec
53 else
54 doit_exec=$doit
55 fi
56
57 # Put in absolute file names if you don't have them in your path;
58 # or use environment vars.
59
60 chgrpprog=${CHGRPPROG-chgrp}
61 chmodprog=${CHMODPROG-chmod}
62 chownprog=${CHOWNPROG-chown}
63 cmpprog=${CMPPROG-cmp}
64 cpprog=${CPPROG-cp}
65 mkdirprog=${MKDIRPROG-mkdir}
66 mvprog=${MVPROG-mv}
67 rmprog=${RMPROG-rm}
68 stripprog=${STRIPPROG-strip}
69
70 posix_glob='?'
71 initialize_posix_glob='
72 test "$posix_glob" != "?" || {
73 if (set -f) 2>/dev/null; then
74 posix_glob=
75 else
76 posix_glob=:
77 fi
78 }
79 '
80
81 posix_mkdir=
82
83 # Desired mode of installed file.
84 mode=0755
85
86 chgrpcmd=
87 chmodcmd=$chmodprog
88 chowncmd=
89 mvcmd=$mvprog
90 rmcmd="$rmprog -f"
91 stripcmd=
92
93 src=
94 dst=
95 dir_arg=
96 dst_arg=
97
98 copy_on_change=false
99 no_target_directory=
100
101 usage="\
102 Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
103 or: $0 [OPTION]... SRCFILES... DIRECTORY
104 or: $0 [OPTION]... -t DIRECTORY SRCFILES...
105 or: $0 [OPTION]... -d DIRECTORIES...
106
107 In the 1st form, copy SRCFILE to DSTFILE.
108 In the 2nd and 3rd, copy all SRCFILES to DIRECTORY.
109 In the 4th, create DIRECTORIES.
110
111 Options:
112 --help display this help and exit.
113 --version display version info and exit.
114
115 -c (ignored)
116 -C install only if different (preserve the last data modification time)
117 -d create directories instead of installing files.
118 -g GROUP $chgrpprog installed files to GROUP.
119 -m MODE $chmodprog installed files to MODE.
120 -o USER $chownprog installed files to USER.
121 -s $stripprog installed files.
122 -t DIRECTORY install into DIRECTORY.
123 -T report an error if DSTFILE is a directory.
124
125 Environment variables override the default commands:
126 CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG
127 RMPROG STRIPPROG
128 "
129
130 while test $# -ne 0; do
131 case $1 in
132 -c) ;;
133
134 -C) copy_on_change=true;;
135
136 -d) dir_arg=true;;
137
138 -g) chgrpcmd="$chgrpprog $2"
139 shift;;
140
141 --help) echo "$usage"; exit $?;;
142
143 -m) mode=$2
144 case $mode in
145 *' '* | *' '* | *'
146 '* | *'*'* | *'?'* | *'['*)
147 echo "$0: invalid mode: $mode" >&2
148 exit 1;;
149 esac
150 shift;;
151
152 -o) chowncmd="$chownprog $2"
153 shift;;
154
155 -s) stripcmd=$stripprog;;
156
157 -t) dst_arg=$2
158 # Protect names problematic for 'test' and other utilities.
159 case $dst_arg in
160 -* | [=\(\)!]) dst_arg=./$dst_arg;;
161 esac
162 shift;;
163
164 -T) no_target_directory=true;;
165
166 --version) echo "$0 $scriptversion"; exit $?;;
167
168 --) shift
169 break;;
170
171 -*) echo "$0: invalid option: $1" >&2
172 exit 1;;
173
174 *) break;;
175 esac
176 shift
177 done
178
179 if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
180 # When -d is used, all remaining arguments are directories to create.
181 # When -t is used, the destination is already specified.
182 # Otherwise, the last argument is the destination. Remove it from $@.
183 for arg
184 do
185 if test -n "$dst_arg"; then
186 # $@ is not empty: it contains at least $arg.
187 set fnord "$@" "$dst_arg"
188 shift # fnord
189 fi
190 shift # arg
191 dst_arg=$arg
192 # Protect names problematic for 'test' and other utilities.
193 case $dst_arg in
194 -* | [=\(\)!]) dst_arg=./$dst_arg;;
195 esac
196 done
197 fi
198
199 if test $# -eq 0; then
200 if test -z "$dir_arg"; then
201 echo "$0: no input file specified." >&2
202 exit 1
203 fi
204 # It's OK to call 'install-sh -d' without argument.
205 # This can happen when creating conditional directories.
206 exit 0
207 fi
208
209 if test -z "$dir_arg"; then
210 do_exit='(exit $ret); exit $ret'
211 trap "ret=129; $do_exit" 1
212 trap "ret=130; $do_exit" 2
213 trap "ret=141; $do_exit" 13
214 trap "ret=143; $do_exit" 15
215
216 # Set umask so as not to create temps with too-generous modes.
217 # However, 'strip' requires both read and write access to temps.
218 case $mode in
219 # Optimize common cases.
220 *644) cp_umask=133;;
221 *755) cp_umask=22;;
222
223 *[0-7])
224 if test -z "$stripcmd"; then
225 u_plus_rw=
226 else
227 u_plus_rw='% 200'
228 fi
229 cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;;
230 *)
231 if test -z "$stripcmd"; then
232 u_plus_rw=
233 else
234 u_plus_rw=,u+rw
235 fi
236 cp_umask=$mode$u_plus_rw;;
237 esac
238 fi
239
240 for src
241 do
242 # Protect names problematic for 'test' and other utilities.
243 case $src in
244 -* | [=\(\)!]) src=./$src;;
245 esac
246
247 if test -n "$dir_arg"; then
248 dst=$src
249 dstdir=$dst
250 test -d "$dstdir"
251 dstdir_status=$?
252 else
253
254 # Waiting for this to be detected by the "$cpprog $src $dsttmp" command
255 # might cause directories to be created, which would be especially bad
256 # if $src (and thus $dsttmp) contains '*'.
257 if test ! -f "$src" && test ! -d "$src"; then
258 echo "$0: $src does not exist." >&2
259 exit 1
260 fi
261
262 if test -z "$dst_arg"; then
263 echo "$0: no destination specified." >&2
264 exit 1
265 fi
266 dst=$dst_arg
267
268 # If destination is a directory, append the input filename; won't work
269 # if double slashes aren't ignored.
270 if test -d "$dst"; then
271 if test -n "$no_target_directory"; then
272 echo "$0: $dst_arg: Is a directory" >&2
273 exit 1
274 fi
275 dstdir=$dst
276 dst=$dstdir/`basename "$src"`
277 dstdir_status=0
278 else
279 # Prefer dirname, but fall back on a substitute if dirname fails.
280 dstdir=`
281 (dirname "$dst") 2>/dev/null ||
282 expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
283 X"$dst" : 'X\(//\)[^/]' \| \
284 X"$dst" : 'X\(//\)$' \| \
285 X"$dst" : 'X\(/\)' \| . 2>/dev/null ||
286 echo X"$dst" |
287 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
288 s//\1/
289 q
290 }
291 /^X\(\/\/\)[^/].*/{
292 s//\1/
293 q
294 }
295 /^X\(\/\/\)$/{
296 s//\1/
297 q
298 }
299 /^X\(\/\).*/{
300 s//\1/
301 q
302 }
303 s/.*/./; q'
304 `
305
306 test -d "$dstdir"
307 dstdir_status=$?
308 fi
309 fi
310
311 obsolete_mkdir_used=false
312
313 if test $dstdir_status != 0; then
314 case $posix_mkdir in
315 '')
316 # Create intermediate dirs using mode 755 as modified by the umask.
317 # This is like FreeBSD 'install' as of 1997-10-28.
318 umask=`umask`
319 case $stripcmd.$umask in
320 # Optimize common cases.
321 *[2367][2367]) mkdir_umask=$umask;;
322 .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
323
324 *[0-7])
325 mkdir_umask=`expr $umask + 22 \
326 - $umask % 100 % 40 + $umask % 20 \
327 - $umask % 10 % 4 + $umask % 2
328 `;;
329 *) mkdir_umask=$umask,go-w;;
330 esac
331
332 # With -d, create the new directory with the user-specified mode.
333 # Otherwise, rely on $mkdir_umask.
334 if test -n "$dir_arg"; then
335 mkdir_mode=-m$mode
336 else
337 mkdir_mode=
338 fi
339
340 posix_mkdir=false
341 case $umask in
342 *[123567][0-7][0-7])
343 # POSIX mkdir -p sets u+wx bits regardless of umask, which
344 # is incompatible with FreeBSD 'install' when (umask & 300) != 0.
345 ;;
346 *)
347 tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
348 trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
349
350 if (umask $mkdir_umask &&
351 exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
352 then
353 if test -z "$dir_arg" || {
354 # Check for POSIX incompatibilities with -m.
355 # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
356 # other-writable bit of parent directory when it shouldn't.
357 # FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
358 ls_ld_tmpdir=`ls -ld "$tmpdir"`
359 case $ls_ld_tmpdir in
360 d????-?r-*) different_mode=700;;
361 d????-?--*) different_mode=755;;
362 *) false;;
363 esac &&
364 $mkdirprog -m$different_mode -p -- "$tmpdir" && {
365 ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
366 test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
367 }
368 }
369 then posix_mkdir=:
370 fi
371 rmdir "$tmpdir/d" "$tmpdir"
372 else
373 # Remove any dirs left behind by ancient mkdir implementations.
374 rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
375 fi
376 trap '' 0;;
377 esac;;
378 esac
379
380 if
381 $posix_mkdir && (
382 umask $mkdir_umask &&
383 $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir"
384 )
385 then :
386 else
387
388 # The umask is ridiculous, or mkdir does not conform to POSIX,
389 # or it failed possibly due to a race condition. Create the
390 # directory the slow way, step by step, checking for races as we go.
391
392 case $dstdir in
393 /*) prefix='/';;
394 [-=\(\)!]*) prefix='./';;
395 *) prefix='';;
396 esac
397
398 eval "$initialize_posix_glob"
399
400 oIFS=$IFS
401 IFS=/
402 $posix_glob set -f
403 set fnord $dstdir
404 shift
405 $posix_glob set +f
406 IFS=$oIFS
407
408 prefixes=
409
410 for d
411 do
412 test X"$d" = X && continue
413
414 prefix=$prefix$d
415 if test -d "$prefix"; then
416 prefixes=
417 else
418 if $posix_mkdir; then
419 (umask=$mkdir_umask &&
420 $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
421 # Don't fail if two instances are running concurrently.
422 test -d "$prefix" || exit 1
423 else
424 case $prefix in
425 *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;;
426 *) qprefix=$prefix;;
427 esac
428 prefixes="$prefixes '$qprefix'"
429 fi
430 fi
431 prefix=$prefix/
432 done
433
434 if test -n "$prefixes"; then
435 # Don't fail if two instances are running concurrently.
436 (umask $mkdir_umask &&
437 eval "\$doit_exec \$mkdirprog $prefixes") ||
438 test -d "$dstdir" || exit 1
439 obsolete_mkdir_used=true
440 fi
441 fi
442 fi
443
444 if test -n "$dir_arg"; then
445 { test -z "$chowncmd" || $doit $chowncmd "$dst"; } &&
446 { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } &&
447 { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false ||
448 test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1
449 else
450
451 # Make a couple of temp file names in the proper directory.
452 dsttmp=$dstdir/_inst.$$_
453 rmtmp=$dstdir/_rm.$$_
454
455 # Trap to clean up those temp files at exit.
456 trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
457
458 # Copy the file name to the temp name.
459 (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") &&
460
461 # and set any options; do chmod last to preserve setuid bits.
462 #
463 # If any of these fail, we abort the whole thing. If we want to
464 # ignore errors from any of these, just make sure not to ignore
465 # errors from the above "$doit $cpprog $src $dsttmp" command.
466 #
467 { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } &&
468 { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } &&
469 { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } &&
470 { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } &&
471
472 # If -C, don't bother to copy if it wouldn't change the file.
473 if $copy_on_change &&
474 old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` &&
475 new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` &&
476
477 eval "$initialize_posix_glob" &&
478 $posix_glob set -f &&
479 set X $old && old=:$2:$4:$5:$6 &&
480 set X $new && new=:$2:$4:$5:$6 &&
481 $posix_glob set +f &&
482
483 test "$old" = "$new" &&
484 $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1
485 then
486 rm -f "$dsttmp"
487 else
488 # Rename the file to the real destination.
489 $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null ||
490
491 # The rename failed, perhaps because mv can't rename something else
492 # to itself, or perhaps because mv is so ancient that it does not
493 # support -f.
494 {
495 # Now remove or move aside any old file at destination location.
496 # We try this two ways since rm can't unlink itself on some
497 # systems and the destination file might be busy for other
498 # reasons. In this case, the final cleanup might fail but the new
499 # file should still install successfully.
500 {
501 test ! -f "$dst" ||
502 $doit $rmcmd -f "$dst" 2>/dev/null ||
503 { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
504 { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
505 } ||
506 { echo "$0: cannot unlink or rename $dst" >&2
507 (exit 1); exit 1
508 }
509 } &&
510
511 # Now rename the file to the real destination.
512 $doit $mvcmd "$dsttmp" "$dst"
513 }
514 fi || exit 1
515
516 trap '' 0
517 fi
518 done
519
520 # Local variables:
521 # eval: (add-hook 'write-file-hooks 'time-stamp)
522 # time-stamp-start: "scriptversion="
523 # time-stamp-format: "%:y-%02m-%02d.%02H"
524 # time-stamp-time-zone: "UTC"
525 # time-stamp-end: "; # UTC"
526 # End:
0
1 # libtool (GNU libtool) 2.4.2
2 # Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
3
4 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
5 # 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
6 # This is free software; see the source for copying conditions. There is NO
7 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
8
9 # GNU Libtool is free software; you can redistribute it and/or modify
10 # it under the terms of the GNU General Public License as published by
11 # the Free Software Foundation; either version 2 of the License, or
12 # (at your option) any later version.
13 #
14 # As a special exception to the GNU General Public License,
15 # if you distribute this file as part of a program or library that
16 # is built using GNU Libtool, you may include this file under the
17 # same distribution terms that you use for the rest of that program.
18 #
19 # GNU Libtool is distributed in the hope that it will be useful, but
20 # WITHOUT ANY WARRANTY; without even the implied warranty of
21 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
22 # General Public License for more details.
23 #
24 # You should have received a copy of the GNU General Public License
25 # along with GNU Libtool; see the file COPYING. If not, a copy
26 # can be downloaded from https://www.gnu.org/licenses/gpl.html,
27 # or obtained by writing to the Free Software Foundation, Inc.,
28 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
29
30 # Usage: $progname [OPTION]... [MODE-ARG]...
31 #
32 # Provide generalized library-building support services.
33 #
34 # --config show all configuration variables
35 # --debug enable verbose shell tracing
36 # -n, --dry-run display commands without modifying any files
37 # --features display basic configuration information and exit
38 # --mode=MODE use operation mode MODE
39 # --preserve-dup-deps don't remove duplicate dependency libraries
40 # --quiet, --silent don't print informational messages
41 # --no-quiet, --no-silent
42 # print informational messages (default)
43 # --no-warn don't display warning messages
44 # --tag=TAG use configuration variables from tag TAG
45 # -v, --verbose print more informational messages than default
46 # --no-verbose don't print the extra informational messages
47 # --version print version information
48 # -h, --help, --help-all print short, long, or detailed help message
49 #
50 # MODE must be one of the following:
51 #
52 # clean remove files from the build directory
53 # compile compile a source file into a libtool object
54 # execute automatically set library path, then run a program
55 # finish complete the installation of libtool libraries
56 # install install libraries or executables
57 # link create a library or an executable
58 # uninstall remove libraries from an installed directory
59 #
60 # MODE-ARGS vary depending on the MODE. When passed as first option,
61 # `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that.
62 # Try `$progname --help --mode=MODE' for a more detailed description of MODE.
63 #
64 # When reporting a bug, please describe a test case to reproduce it and
65 # include the following information:
66 #
67 # host-triplet: $host
68 # shell: $SHELL
69 # compiler: $LTCC
70 # compiler flags: $LTCFLAGS
71 # linker: $LD (gnu? $with_gnu_ld)
72 # $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1
73 # automake: $automake_version
74 # autoconf: $autoconf_version
75 #
76 # Report bugs to <bug-libtool@gnu.org>.
77 # GNU libtool home page: <https://www.gnu.org/software/libtool/>.
78 # General help using GNU software: <https://www.gnu.org/gethelp/>.
79
80 PROGRAM=libtool
81 PACKAGE=libtool
82 VERSION="2.4.2 Debian-2.4.2-1"
83 TIMESTAMP=""
84 package_revision=1.3337
85
86 # Be Bourne compatible
87 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
88 emulate sh
89 NULLCMD=:
90 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
91 # is contrary to our usage. Disable this feature.
92 alias -g '${1+"$@"}'='"$@"'
93 setopt NO_GLOB_SUBST
94 else
95 case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac
96 fi
97 BIN_SH=xpg4; export BIN_SH # for Tru64
98 DUALCASE=1; export DUALCASE # for MKS sh
99
100 # A function that is used when there is no print builtin or printf.
101 func_fallback_echo ()
102 {
103 eval 'cat <<_LTECHO_EOF
104 $1
105 _LTECHO_EOF'
106 }
107
108 # NLS nuisances: We save the old values to restore during execute mode.
109 lt_user_locale=
110 lt_safe_locale=
111 for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
112 do
113 eval "if test \"\${$lt_var+set}\" = set; then
114 save_$lt_var=\$$lt_var
115 $lt_var=C
116 export $lt_var
117 lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\"
118 lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\"
119 fi"
120 done
121 LC_ALL=C
122 LANGUAGE=C
123 export LANGUAGE LC_ALL
124
125 $lt_unset CDPATH
126
127
128 # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
129 # is ksh but when the shell is invoked as "sh" and the current value of
130 # the _XPG environment variable is not equal to 1 (one), the special
131 # positional parameter $0, within a function call, is the name of the
132 # function.
133 progpath="$0"
134
135
136
137 : ${CP="cp -f"}
138 test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'}
139 : ${MAKE="make"}
140 : ${MKDIR="mkdir"}
141 : ${MV="mv -f"}
142 : ${RM="rm -f"}
143 : ${SHELL="${CONFIG_SHELL-/bin/sh}"}
144 : ${Xsed="$SED -e 1s/^X//"}
145
146 # Global variables:
147 EXIT_SUCCESS=0
148 EXIT_FAILURE=1
149 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing.
150 EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake.
151
152 exit_status=$EXIT_SUCCESS
153
154 # Make sure IFS has a sensible default
155 lt_nl='
156 '
157 IFS=" $lt_nl"
158
159 dirname="s,/[^/]*$,,"
160 basename="s,^.*/,,"
161
162 # func_dirname file append nondir_replacement
163 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
164 # otherwise set result to NONDIR_REPLACEMENT.
165 func_dirname ()
166 {
167 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
168 if test "X$func_dirname_result" = "X${1}"; then
169 func_dirname_result="${3}"
170 else
171 func_dirname_result="$func_dirname_result${2}"
172 fi
173 } # func_dirname may be replaced by extended shell implementation
174
175
176 # func_basename file
177 func_basename ()
178 {
179 func_basename_result=`$ECHO "${1}" | $SED "$basename"`
180 } # func_basename may be replaced by extended shell implementation
181
182
183 # func_dirname_and_basename file append nondir_replacement
184 # perform func_basename and func_dirname in a single function
185 # call:
186 # dirname: Compute the dirname of FILE. If nonempty,
187 # add APPEND to the result, otherwise set result
188 # to NONDIR_REPLACEMENT.
189 # value returned in "$func_dirname_result"
190 # basename: Compute filename of FILE.
191 # value retuned in "$func_basename_result"
192 # Implementation must be kept synchronized with func_dirname
193 # and func_basename. For efficiency, we do not delegate to
194 # those functions but instead duplicate the functionality here.
195 func_dirname_and_basename ()
196 {
197 # Extract subdirectory from the argument.
198 func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"`
199 if test "X$func_dirname_result" = "X${1}"; then
200 func_dirname_result="${3}"
201 else
202 func_dirname_result="$func_dirname_result${2}"
203 fi
204 func_basename_result=`$ECHO "${1}" | $SED -e "$basename"`
205 } # func_dirname_and_basename may be replaced by extended shell implementation
206
207
208 # func_stripname prefix suffix name
209 # strip PREFIX and SUFFIX off of NAME.
210 # PREFIX and SUFFIX must not contain globbing or regex special
211 # characters, hashes, percent signs, but SUFFIX may contain a leading
212 # dot (in which case that matches only a dot).
213 # func_strip_suffix prefix name
214 func_stripname ()
215 {
216 case ${2} in
217 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
218 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
219 esac
220 } # func_stripname may be replaced by extended shell implementation
221
222
223 # These SED scripts presuppose an absolute path with a trailing slash.
224 pathcar='s,^/\([^/]*\).*$,\1,'
225 pathcdr='s,^/[^/]*,,'
226 removedotparts=':dotsl
227 s@/\./@/@g
228 t dotsl
229 s,/\.$,/,'
230 collapseslashes='s@/\{1,\}@/@g'
231 finalslash='s,/*$,/,'
232
233 # func_normal_abspath PATH
234 # Remove doubled-up and trailing slashes, "." path components,
235 # and cancel out any ".." path components in PATH after making
236 # it an absolute path.
237 # value returned in "$func_normal_abspath_result"
238 func_normal_abspath ()
239 {
240 # Start from root dir and reassemble the path.
241 func_normal_abspath_result=
242 func_normal_abspath_tpath=$1
243 func_normal_abspath_altnamespace=
244 case $func_normal_abspath_tpath in
245 "")
246 # Empty path, that just means $cwd.
247 func_stripname '' '/' "`pwd`"
248 func_normal_abspath_result=$func_stripname_result
249 return
250 ;;
251 # The next three entries are used to spot a run of precisely
252 # two leading slashes without using negated character classes;
253 # we take advantage of case's first-match behaviour.
254 ///*)
255 # Unusual form of absolute path, do nothing.
256 ;;
257 //*)
258 # Not necessarily an ordinary path; POSIX reserves leading '//'
259 # and for example Cygwin uses it to access remote file shares
260 # over CIFS/SMB, so we conserve a leading double slash if found.
261 func_normal_abspath_altnamespace=/
262 ;;
263 /*)
264 # Absolute path, do nothing.
265 ;;
266 *)
267 # Relative path, prepend $cwd.
268 func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath
269 ;;
270 esac
271 # Cancel out all the simple stuff to save iterations. We also want
272 # the path to end with a slash for ease of parsing, so make sure
273 # there is one (and only one) here.
274 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
275 -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"`
276 while :; do
277 # Processed it all yet?
278 if test "$func_normal_abspath_tpath" = / ; then
279 # If we ascended to the root using ".." the result may be empty now.
280 if test -z "$func_normal_abspath_result" ; then
281 func_normal_abspath_result=/
282 fi
283 break
284 fi
285 func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \
286 -e "$pathcar"`
287 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
288 -e "$pathcdr"`
289 # Figure out what to do with it
290 case $func_normal_abspath_tcomponent in
291 "")
292 # Trailing empty path component, ignore it.
293 ;;
294 ..)
295 # Parent dir; strip last assembled component from result.
296 func_dirname "$func_normal_abspath_result"
297 func_normal_abspath_result=$func_dirname_result
298 ;;
299 *)
300 # Actual path component, append it.
301 func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent
302 ;;
303 esac
304 done
305 # Restore leading double-slash if one was found on entry.
306 func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result
307 }
308
309 # func_relative_path SRCDIR DSTDIR
310 # generates a relative path from SRCDIR to DSTDIR, with a trailing
311 # slash if non-empty, suitable for immediately appending a filename
312 # without needing to append a separator.
313 # value returned in "$func_relative_path_result"
314 func_relative_path ()
315 {
316 func_relative_path_result=
317 func_normal_abspath "$1"
318 func_relative_path_tlibdir=$func_normal_abspath_result
319 func_normal_abspath "$2"
320 func_relative_path_tbindir=$func_normal_abspath_result
321
322 # Ascend the tree starting from libdir
323 while :; do
324 # check if we have found a prefix of bindir
325 case $func_relative_path_tbindir in
326 $func_relative_path_tlibdir)
327 # found an exact match
328 func_relative_path_tcancelled=
329 break
330 ;;
331 $func_relative_path_tlibdir*)
332 # found a matching prefix
333 func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir"
334 func_relative_path_tcancelled=$func_stripname_result
335 if test -z "$func_relative_path_result"; then
336 func_relative_path_result=.
337 fi
338 break
339 ;;
340 *)
341 func_dirname $func_relative_path_tlibdir
342 func_relative_path_tlibdir=${func_dirname_result}
343 if test "x$func_relative_path_tlibdir" = x ; then
344 # Have to descend all the way to the root!
345 func_relative_path_result=../$func_relative_path_result
346 func_relative_path_tcancelled=$func_relative_path_tbindir
347 break
348 fi
349 func_relative_path_result=../$func_relative_path_result
350 ;;
351 esac
352 done
353
354 # Now calculate path; take care to avoid doubling-up slashes.
355 func_stripname '' '/' "$func_relative_path_result"
356 func_relative_path_result=$func_stripname_result
357 func_stripname '/' '/' "$func_relative_path_tcancelled"
358 if test "x$func_stripname_result" != x ; then
359 func_relative_path_result=${func_relative_path_result}/${func_stripname_result}
360 fi
361
362 # Normalisation. If bindir is libdir, return empty string,
363 # else relative path ending with a slash; either way, target
364 # file name can be directly appended.
365 if test ! -z "$func_relative_path_result"; then
366 func_stripname './' '' "$func_relative_path_result/"
367 func_relative_path_result=$func_stripname_result
368 fi
369 }
370
371 # The name of this program:
372 func_dirname_and_basename "$progpath"
373 progname=$func_basename_result
374
375 # Make sure we have an absolute path for reexecution:
376 case $progpath in
377 [\\/]*|[A-Za-z]:\\*) ;;
378 *[\\/]*)
379 progdir=$func_dirname_result
380 progdir=`cd "$progdir" && pwd`
381 progpath="$progdir/$progname"
382 ;;
383 *)
384 save_IFS="$IFS"
385 IFS=${PATH_SEPARATOR-:}
386 for progdir in $PATH; do
387 IFS="$save_IFS"
388 test -x "$progdir/$progname" && break
389 done
390 IFS="$save_IFS"
391 test -n "$progdir" || progdir=`pwd`
392 progpath="$progdir/$progname"
393 ;;
394 esac
395
396 # Sed substitution that helps us do robust quoting. It backslashifies
397 # metacharacters that are still active within double-quoted strings.
398 Xsed="${SED}"' -e 1s/^X//'
399 sed_quote_subst='s/\([`"$\\]\)/\\\1/g'
400
401 # Same as above, but do not quote variable references.
402 double_quote_subst='s/\(["`\\]\)/\\\1/g'
403
404 # Sed substitution that turns a string into a regex matching for the
405 # string literally.
406 sed_make_literal_regex='s,[].[^$\\*\/],\\&,g'
407
408 # Sed substitution that converts a w32 file name or path
409 # which contains forward slashes, into one that contains
410 # (escaped) backslashes. A very naive implementation.
411 lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
412
413 # Sed substitution to remove simple comments and empty
414 # lines from a Windows .def file.
415 sed_uncomment_deffile='/^;/d; /^[ ]*$/d'
416
417 # Re-`\' parameter expansions in output of double_quote_subst that were
418 # `\'-ed in input to the same. If an odd number of `\' preceded a '$'
419 # in input to double_quote_subst, that '$' was protected from expansion.
420 # Since each input `\' is now two `\'s, look for any number of runs of
421 # four `\'s followed by two `\'s and then a '$'. `\' that '$'.
422 bs='\\'
423 bs2='\\\\'
424 bs4='\\\\\\\\'
425 dollar='\$'
426 sed_double_backslash="\
427 s/$bs4/&\\
428 /g
429 s/^$bs2$dollar/$bs&/
430 s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g
431 s/\n//g"
432
433 # Standard options:
434 opt_dry_run=false
435 opt_help=false
436 opt_quiet=false
437 opt_verbose=false
438 opt_warning=:
439
440 # func_echo arg...
441 # Echo program name prefixed message, along with the current mode
442 # name if it has been set yet.
443 func_echo ()
444 {
445 $ECHO "$progname: ${opt_mode+$opt_mode: }$*"
446 }
447
448 # func_verbose arg...
449 # Echo program name prefixed message in verbose mode only.
450 func_verbose ()
451 {
452 $opt_verbose && func_echo ${1+"$@"}
453
454 # A bug in bash halts the script if the last line of a function
455 # fails when set -e is in force, so we need another command to
456 # work around that:
457 :
458 }
459
460 # func_echo_all arg...
461 # Invoke $ECHO with all args, space-separated.
462 func_echo_all ()
463 {
464 $ECHO "$*"
465 }
466
467 # func_error arg...
468 # Echo program name prefixed message to standard error.
469 func_error ()
470 {
471 $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2
472 }
473
474 # func_warning arg...
475 # Echo program name prefixed warning message to standard error.
476 func_warning ()
477 {
478 $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2
479
480 # bash bug again:
481 :
482 }
483
484 # func_fatal_error arg...
485 # Echo program name prefixed message to standard error, and exit.
486 func_fatal_error ()
487 {
488 func_error ${1+"$@"}
489 exit $EXIT_FAILURE
490 }
491
492 # func_fatal_help arg...
493 # Echo program name prefixed message to standard error, followed by
494 # a help hint, and exit.
495 func_fatal_help ()
496 {
497 func_error ${1+"$@"}
498 func_fatal_error "$help"
499 }
500 help="Try \`$progname --help' for more information." ## default
501
502
503 # func_grep expression filename
504 # Check whether EXPRESSION matches any line of FILENAME, without output.
505 func_grep ()
506 {
507 $GREP "$1" "$2" >/dev/null 2>&1
508 }
509
510
511 # func_mkdir_p directory-path
512 # Make sure the entire path to DIRECTORY-PATH is available.
513 func_mkdir_p ()
514 {
515 my_directory_path="$1"
516 my_dir_list=
517
518 if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then
519
520 # Protect directory names starting with `-'
521 case $my_directory_path in
522 -*) my_directory_path="./$my_directory_path" ;;
523 esac
524
525 # While some portion of DIR does not yet exist...
526 while test ! -d "$my_directory_path"; do
527 # ...make a list in topmost first order. Use a colon delimited
528 # list incase some portion of path contains whitespace.
529 my_dir_list="$my_directory_path:$my_dir_list"
530
531 # If the last portion added has no slash in it, the list is done
532 case $my_directory_path in */*) ;; *) break ;; esac
533
534 # ...otherwise throw away the child directory and loop
535 my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"`
536 done
537 my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'`
538
539 save_mkdir_p_IFS="$IFS"; IFS=':'
540 for my_dir in $my_dir_list; do
541 IFS="$save_mkdir_p_IFS"
542 # mkdir can fail with a `File exist' error if two processes
543 # try to create one of the directories concurrently. Don't
544 # stop in that case!
545 $MKDIR "$my_dir" 2>/dev/null || :
546 done
547 IFS="$save_mkdir_p_IFS"
548
549 # Bail out if we (or some other process) failed to create a directory.
550 test -d "$my_directory_path" || \
551 func_fatal_error "Failed to create \`$1'"
552 fi
553 }
554
555
556 # func_mktempdir [string]
557 # Make a temporary directory that won't clash with other running
558 # libtool processes, and avoids race conditions if possible. If
559 # given, STRING is the basename for that directory.
560 func_mktempdir ()
561 {
562 my_template="${TMPDIR-/tmp}/${1-$progname}"
563
564 if test "$opt_dry_run" = ":"; then
565 # Return a directory name, but don't create it in dry-run mode
566 my_tmpdir="${my_template}-$$"
567 else
568
569 # If mktemp works, use that first and foremost
570 my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null`
571
572 if test ! -d "$my_tmpdir"; then
573 # Failing that, at least try and use $RANDOM to avoid a race
574 my_tmpdir="${my_template}-${RANDOM-0}$$"
575
576 save_mktempdir_umask=`umask`
577 umask 0077
578 $MKDIR "$my_tmpdir"
579 umask $save_mktempdir_umask
580 fi
581
582 # If we're not in dry-run mode, bomb out on failure
583 test -d "$my_tmpdir" || \
584 func_fatal_error "cannot create temporary directory \`$my_tmpdir'"
585 fi
586
587 $ECHO "$my_tmpdir"
588 }
589
590
591 # func_quote_for_eval arg
592 # Aesthetically quote ARG to be evaled later.
593 # This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT
594 # is double-quoted, suitable for a subsequent eval, whereas
595 # FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters
596 # which are still active within double quotes backslashified.
597 func_quote_for_eval ()
598 {
599 case $1 in
600 *[\\\`\"\$]*)
601 func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;;
602 *)
603 func_quote_for_eval_unquoted_result="$1" ;;
604 esac
605
606 case $func_quote_for_eval_unquoted_result in
607 # Double-quote args containing shell metacharacters to delay
608 # word splitting, command substitution and and variable
609 # expansion for a subsequent eval.
610 # Many Bourne shells cannot handle close brackets correctly
611 # in scan sets, so we specify it separately.
612 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
613 func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\""
614 ;;
615 *)
616 func_quote_for_eval_result="$func_quote_for_eval_unquoted_result"
617 esac
618 }
619
620
621 # func_quote_for_expand arg
622 # Aesthetically quote ARG to be evaled later; same as above,
623 # but do not quote variable references.
624 func_quote_for_expand ()
625 {
626 case $1 in
627 *[\\\`\"]*)
628 my_arg=`$ECHO "$1" | $SED \
629 -e "$double_quote_subst" -e "$sed_double_backslash"` ;;
630 *)
631 my_arg="$1" ;;
632 esac
633
634 case $my_arg in
635 # Double-quote args containing shell metacharacters to delay
636 # word splitting and command substitution for a subsequent eval.
637 # Many Bourne shells cannot handle close brackets correctly
638 # in scan sets, so we specify it separately.
639 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
640 my_arg="\"$my_arg\""
641 ;;
642 esac
643
644 func_quote_for_expand_result="$my_arg"
645 }
646
647
648 # func_show_eval cmd [fail_exp]
649 # Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
650 # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
651 # is given, then evaluate it.
652 func_show_eval ()
653 {
654 my_cmd="$1"
655 my_fail_exp="${2-:}"
656
657 ${opt_silent-false} || {
658 func_quote_for_expand "$my_cmd"
659 eval "func_echo $func_quote_for_expand_result"
660 }
661
662 if ${opt_dry_run-false}; then :; else
663 eval "$my_cmd"
664 my_status=$?
665 if test "$my_status" -eq 0; then :; else
666 eval "(exit $my_status); $my_fail_exp"
667 fi
668 fi
669 }
670
671
672 # func_show_eval_locale cmd [fail_exp]
673 # Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
674 # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
675 # is given, then evaluate it. Use the saved locale for evaluation.
676 func_show_eval_locale ()
677 {
678 my_cmd="$1"
679 my_fail_exp="${2-:}"
680
681 ${opt_silent-false} || {
682 func_quote_for_expand "$my_cmd"
683 eval "func_echo $func_quote_for_expand_result"
684 }
685
686 if ${opt_dry_run-false}; then :; else
687 eval "$lt_user_locale
688 $my_cmd"
689 my_status=$?
690 eval "$lt_safe_locale"
691 if test "$my_status" -eq 0; then :; else
692 eval "(exit $my_status); $my_fail_exp"
693 fi
694 fi
695 }
696
697 # func_tr_sh
698 # Turn $1 into a string suitable for a shell variable name.
699 # Result is stored in $func_tr_sh_result. All characters
700 # not in the set a-zA-Z0-9_ are replaced with '_'. Further,
701 # if $1 begins with a digit, a '_' is prepended as well.
702 func_tr_sh ()
703 {
704 case $1 in
705 [0-9]* | *[!a-zA-Z0-9_]*)
706 func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'`
707 ;;
708 * )
709 func_tr_sh_result=$1
710 ;;
711 esac
712 }
713
714
715 # func_version
716 # Echo version message to standard output and exit.
717 func_version ()
718 {
719 $opt_debug
720
721 $SED -n '/(C)/!b go
722 :more
723 /\./!{
724 N
725 s/\n# / /
726 b more
727 }
728 :go
729 /^# '$PROGRAM' (GNU /,/# warranty; / {
730 s/^# //
731 s/^# *$//
732 s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/
733 p
734 }' < "$progpath"
735 exit $?
736 }
737
738 # func_usage
739 # Echo short help message to standard output and exit.
740 func_usage ()
741 {
742 $opt_debug
743
744 $SED -n '/^# Usage:/,/^# *.*--help/ {
745 s/^# //
746 s/^# *$//
747 s/\$progname/'$progname'/
748 p
749 }' < "$progpath"
750 echo
751 $ECHO "run \`$progname --help | more' for full usage"
752 exit $?
753 }
754
755 # func_help [NOEXIT]
756 # Echo long help message to standard output and exit,
757 # unless 'noexit' is passed as argument.
758 func_help ()
759 {
760 $opt_debug
761
762 $SED -n '/^# Usage:/,/# Report bugs to/ {
763 :print
764 s/^# //
765 s/^# *$//
766 s*\$progname*'$progname'*
767 s*\$host*'"$host"'*
768 s*\$SHELL*'"$SHELL"'*
769 s*\$LTCC*'"$LTCC"'*
770 s*\$LTCFLAGS*'"$LTCFLAGS"'*
771 s*\$LD*'"$LD"'*
772 s/\$with_gnu_ld/'"$with_gnu_ld"'/
773 s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/
774 s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/
775 p
776 d
777 }
778 /^# .* home page:/b print
779 /^# General help using/b print
780 ' < "$progpath"
781 ret=$?
782 if test -z "$1"; then
783 exit $ret
784 fi
785 }
786
787 # func_missing_arg argname
788 # Echo program name prefixed message to standard error and set global
789 # exit_cmd.
790 func_missing_arg ()
791 {
792 $opt_debug
793
794 func_error "missing argument for $1."
795 exit_cmd=exit
796 }
797
798
799 # func_split_short_opt shortopt
800 # Set func_split_short_opt_name and func_split_short_opt_arg shell
801 # variables after splitting SHORTOPT after the 2nd character.
802 func_split_short_opt ()
803 {
804 my_sed_short_opt='1s/^\(..\).*$/\1/;q'
805 my_sed_short_rest='1s/^..\(.*\)$/\1/;q'
806
807 func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"`
808 func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"`
809 } # func_split_short_opt may be replaced by extended shell implementation
810
811
812 # func_split_long_opt longopt
813 # Set func_split_long_opt_name and func_split_long_opt_arg shell
814 # variables after splitting LONGOPT at the `=' sign.
815 func_split_long_opt ()
816 {
817 my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q'
818 my_sed_long_arg='1s/^--[^=]*=//'
819
820 func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"`
821 func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"`
822 } # func_split_long_opt may be replaced by extended shell implementation
823
824 exit_cmd=:
825
826
827
828
829
830 magic="%%%MAGIC variable%%%"
831 magic_exe="%%%MAGIC EXE variable%%%"
832
833 # Global variables.
834 nonopt=
835 preserve_args=
836 lo2o="s/\\.lo\$/.${objext}/"
837 o2lo="s/\\.${objext}\$/.lo/"
838 extracted_archives=
839 extracted_serial=0
840
841 # If this variable is set in any of the actions, the command in it
842 # will be execed at the end. This prevents here-documents from being
843 # left over by shells.
844 exec_cmd=
845
846 # func_append var value
847 # Append VALUE to the end of shell variable VAR.
848 func_append ()
849 {
850 eval "${1}=\$${1}\${2}"
851 } # func_append may be replaced by extended shell implementation
852
853 # func_append_quoted var value
854 # Quote VALUE and append to the end of shell variable VAR, separated
855 # by a space.
856 func_append_quoted ()
857 {
858 func_quote_for_eval "${2}"
859 eval "${1}=\$${1}\\ \$func_quote_for_eval_result"
860 } # func_append_quoted may be replaced by extended shell implementation
861
862
863 # func_arith arithmetic-term...
864 func_arith ()
865 {
866 func_arith_result=`expr "${@}"`
867 } # func_arith may be replaced by extended shell implementation
868
869
870 # func_len string
871 # STRING may not start with a hyphen.
872 func_len ()
873 {
874 func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len`
875 } # func_len may be replaced by extended shell implementation
876
877
878 # func_lo2o object
879 func_lo2o ()
880 {
881 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
882 } # func_lo2o may be replaced by extended shell implementation
883
884
885 # func_xform libobj-or-source
886 func_xform ()
887 {
888 func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
889 } # func_xform may be replaced by extended shell implementation
890
891
892 # func_fatal_configuration arg...
893 # Echo program name prefixed message to standard error, followed by
894 # a configuration failure hint, and exit.
895 func_fatal_configuration ()
896 {
897 func_error ${1+"$@"}
898 func_error "See the $PACKAGE documentation for more information."
899 func_fatal_error "Fatal configuration error."
900 }
901
902
903 # func_config
904 # Display the configuration for all the tags in this script.
905 func_config ()
906 {
907 re_begincf='^# ### BEGIN LIBTOOL'
908 re_endcf='^# ### END LIBTOOL'
909
910 # Default configuration.
911 $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath"
912
913 # Now print the configurations for the tags.
914 for tagname in $taglist; do
915 $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath"
916 done
917
918 exit $?
919 }
920
921 # func_features
922 # Display the features supported by this script.
923 func_features ()
924 {
925 echo "host: $host"
926 if test "$build_libtool_libs" = yes; then
927 echo "enable shared libraries"
928 else
929 echo "disable shared libraries"
930 fi
931 if test "$build_old_libs" = yes; then
932 echo "enable static libraries"
933 else
934 echo "disable static libraries"
935 fi
936
937 exit $?
938 }
939
940 # func_enable_tag tagname
941 # Verify that TAGNAME is valid, and either flag an error and exit, or
942 # enable the TAGNAME tag. We also add TAGNAME to the global $taglist
943 # variable here.
944 func_enable_tag ()
945 {
946 # Global variable:
947 tagname="$1"
948
949 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$"
950 re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$"
951 sed_extractcf="/$re_begincf/,/$re_endcf/p"
952
953 # Validate tagname.
954 case $tagname in
955 *[!-_A-Za-z0-9,/]*)
956 func_fatal_error "invalid tag name: $tagname"
957 ;;
958 esac
959
960 # Don't test for the "default" C tag, as we know it's
961 # there but not specially marked.
962 case $tagname in
963 CC) ;;
964 *)
965 if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then
966 taglist="$taglist $tagname"
967
968 # Evaluate the configuration. Be careful to quote the path
969 # and the sed script, to avoid splitting on whitespace, but
970 # also don't use non-portable quotes within backquotes within
971 # quotes we have to do it in 2 steps:
972 extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"`
973 eval "$extractedcf"
974 else
975 func_error "ignoring unknown tag $tagname"
976 fi
977 ;;
978 esac
979 }
980
981 # func_check_version_match
982 # Ensure that we are using m4 macros, and libtool script from the same
983 # release of libtool.
984 func_check_version_match ()
985 {
986 if test "$package_revision" != "$macro_revision"; then
987 if test "$VERSION" != "$macro_version"; then
988 if test -z "$macro_version"; then
989 cat >&2 <<_LT_EOF
990 $progname: Version mismatch error. This is $PACKAGE $VERSION, but the
991 $progname: definition of this LT_INIT comes from an older release.
992 $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
993 $progname: and run autoconf again.
994 _LT_EOF
995 else
996 cat >&2 <<_LT_EOF
997 $progname: Version mismatch error. This is $PACKAGE $VERSION, but the
998 $progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
999 $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
1000 $progname: and run autoconf again.
1001 _LT_EOF
1002 fi
1003 else
1004 cat >&2 <<_LT_EOF
1005 $progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision,
1006 $progname: but the definition of this LT_INIT comes from revision $macro_revision.
1007 $progname: You should recreate aclocal.m4 with macros from revision $package_revision
1008 $progname: of $PACKAGE $VERSION and run autoconf again.
1009 _LT_EOF
1010 fi
1011
1012 exit $EXIT_MISMATCH
1013 fi
1014 }
1015
1016
1017 # Shorthand for --mode=foo, only valid as the first argument
1018 case $1 in
1019 clean|clea|cle|cl)
1020 shift; set dummy --mode clean ${1+"$@"}; shift
1021 ;;
1022 compile|compil|compi|comp|com|co|c)
1023 shift; set dummy --mode compile ${1+"$@"}; shift
1024 ;;
1025 execute|execut|execu|exec|exe|ex|e)
1026 shift; set dummy --mode execute ${1+"$@"}; shift
1027 ;;
1028 finish|finis|fini|fin|fi|f)
1029 shift; set dummy --mode finish ${1+"$@"}; shift
1030 ;;
1031 install|instal|insta|inst|ins|in|i)
1032 shift; set dummy --mode install ${1+"$@"}; shift
1033 ;;
1034 link|lin|li|l)
1035 shift; set dummy --mode link ${1+"$@"}; shift
1036 ;;
1037 uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
1038 shift; set dummy --mode uninstall ${1+"$@"}; shift
1039 ;;
1040 esac
1041
1042
1043
1044 # Option defaults:
1045 opt_debug=:
1046 opt_dry_run=false
1047 opt_config=false
1048 opt_preserve_dup_deps=false
1049 opt_features=false
1050 opt_finish=false
1051 opt_help=false
1052 opt_help_all=false
1053 opt_silent=:
1054 opt_warning=:
1055 opt_verbose=:
1056 opt_silent=false
1057 opt_verbose=false
1058
1059
1060 # Parse options once, thoroughly. This comes as soon as possible in the
1061 # script to make things like `--version' happen as quickly as we can.
1062 {
1063 # this just eases exit handling
1064 while test $# -gt 0; do
1065 opt="$1"
1066 shift
1067 case $opt in
1068 --debug|-x) opt_debug='set -x'
1069 func_echo "enabling shell trace mode"
1070 $opt_debug
1071 ;;
1072 --dry-run|--dryrun|-n)
1073 opt_dry_run=:
1074 ;;
1075 --config)
1076 opt_config=:
1077 func_config
1078 ;;
1079 --dlopen|-dlopen)
1080 optarg="$1"
1081 opt_dlopen="${opt_dlopen+$opt_dlopen
1082 }$optarg"
1083 shift
1084 ;;
1085 --preserve-dup-deps)
1086 opt_preserve_dup_deps=:
1087 ;;
1088 --features)
1089 opt_features=:
1090 func_features
1091 ;;
1092 --finish)
1093 opt_finish=:
1094 set dummy --mode finish ${1+"$@"}; shift
1095 ;;
1096 --help)
1097 opt_help=:
1098 ;;
1099 --help-all)
1100 opt_help_all=:
1101 opt_help=': help-all'
1102 ;;
1103 --mode)
1104 test $# = 0 && func_missing_arg $opt && break
1105 optarg="$1"
1106 opt_mode="$optarg"
1107 case $optarg in
1108 # Valid mode arguments:
1109 clean|compile|execute|finish|install|link|relink|uninstall) ;;
1110
1111 # Catch anything else as an error
1112 *) func_error "invalid argument for $opt"
1113 exit_cmd=exit
1114 break
1115 ;;
1116 esac
1117 shift
1118 ;;
1119 --no-silent|--no-quiet)
1120 opt_silent=false
1121 func_append preserve_args " $opt"
1122 ;;
1123 --no-warning|--no-warn)
1124 opt_warning=false
1125 func_append preserve_args " $opt"
1126 ;;
1127 --no-verbose)
1128 opt_verbose=false
1129 func_append preserve_args " $opt"
1130 ;;
1131 --silent|--quiet)
1132 opt_silent=:
1133 func_append preserve_args " $opt"
1134 opt_verbose=false
1135 ;;
1136 --verbose|-v)
1137 opt_verbose=:
1138 func_append preserve_args " $opt"
1139 opt_silent=false
1140 ;;
1141 --tag)
1142 test $# = 0 && func_missing_arg $opt && break
1143 optarg="$1"
1144 opt_tag="$optarg"
1145 func_append preserve_args " $opt $optarg"
1146 func_enable_tag "$optarg"
1147 shift
1148 ;;
1149
1150 -\?|-h) func_usage ;;
1151 --help) func_help ;;
1152 --version) func_version ;;
1153
1154 # Separate optargs to long options:
1155 --*=*)
1156 func_split_long_opt "$opt"
1157 set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"}
1158 shift
1159 ;;
1160
1161 # Separate non-argument short options:
1162 -\?*|-h*|-n*|-v*)
1163 func_split_short_opt "$opt"
1164 set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"}
1165 shift
1166 ;;
1167
1168 --) break ;;
1169 -*) func_fatal_help "unrecognized option \`$opt'" ;;
1170 *) set dummy "$opt" ${1+"$@"}; shift; break ;;
1171 esac
1172 done
1173
1174 # Validate options:
1175
1176 # save first non-option argument
1177 if test "$#" -gt 0; then
1178 nonopt="$opt"
1179 shift
1180 fi
1181
1182 # preserve --debug
1183 test "$opt_debug" = : || func_append preserve_args " --debug"
1184
1185 case $host in
1186 *cygwin* | *mingw* | *pw32* | *cegcc*)
1187 # don't eliminate duplications in $postdeps and $predeps
1188 opt_duplicate_compiler_generated_deps=:
1189 ;;
1190 *)
1191 opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
1192 ;;
1193 esac
1194
1195 $opt_help || {
1196 # Sanity checks first:
1197 func_check_version_match
1198
1199 if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
1200 func_fatal_configuration "not configured to build any kind of library"
1201 fi
1202
1203 # Darwin sucks
1204 eval std_shrext=\"$shrext_cmds\"
1205
1206 # Only execute mode is allowed to have -dlopen flags.
1207 if test -n "$opt_dlopen" && test "$opt_mode" != execute; then
1208 func_error "unrecognized option \`-dlopen'"
1209 $ECHO "$help" 1>&2
1210 exit $EXIT_FAILURE
1211 fi
1212
1213 # Change the help message to a mode-specific one.
1214 generic_help="$help"
1215 help="Try \`$progname --help --mode=$opt_mode' for more information."
1216 }
1217
1218
1219 # Bail if the options were screwed
1220 $exit_cmd $EXIT_FAILURE
1221 }
1222
1223
1224
1225
1226 ## ----------- ##
1227 ## Main. ##
1228 ## ----------- ##
1229
1230 # func_lalib_p file
1231 # True iff FILE is a libtool `.la' library or `.lo' object file.
1232 # This function is only a basic sanity check; it will hardly flush out
1233 # determined imposters.
1234 func_lalib_p ()
1235 {
1236 test -f "$1" &&
1237 $SED -e 4q "$1" 2>/dev/null \
1238 | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1
1239 }
1240
1241 # func_lalib_unsafe_p file
1242 # True iff FILE is a libtool `.la' library or `.lo' object file.
1243 # This function implements the same check as func_lalib_p without
1244 # resorting to external programs. To this end, it redirects stdin and
1245 # closes it afterwards, without saving the original file descriptor.
1246 # As a safety measure, use it only where a negative result would be
1247 # fatal anyway. Works if `file' does not exist.
1248 func_lalib_unsafe_p ()
1249 {
1250 lalib_p=no
1251 if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then
1252 for lalib_p_l in 1 2 3 4
1253 do
1254 read lalib_p_line
1255 case "$lalib_p_line" in
1256 \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;;
1257 esac
1258 done
1259 exec 0<&5 5<&-
1260 fi
1261 test "$lalib_p" = yes
1262 }
1263
1264 # func_ltwrapper_script_p file
1265 # True iff FILE is a libtool wrapper script
1266 # This function is only a basic sanity check; it will hardly flush out
1267 # determined imposters.
1268 func_ltwrapper_script_p ()
1269 {
1270 func_lalib_p "$1"
1271 }
1272
1273 # func_ltwrapper_executable_p file
1274 # True iff FILE is a libtool wrapper executable
1275 # This function is only a basic sanity check; it will hardly flush out
1276 # determined imposters.
1277 func_ltwrapper_executable_p ()
1278 {
1279 func_ltwrapper_exec_suffix=
1280 case $1 in
1281 *.exe) ;;
1282 *) func_ltwrapper_exec_suffix=.exe ;;
1283 esac
1284 $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1
1285 }
1286
1287 # func_ltwrapper_scriptname file
1288 # Assumes file is an ltwrapper_executable
1289 # uses $file to determine the appropriate filename for a
1290 # temporary ltwrapper_script.
1291 func_ltwrapper_scriptname ()
1292 {
1293 func_dirname_and_basename "$1" "" "."
1294 func_stripname '' '.exe' "$func_basename_result"
1295 func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
1296 }
1297
1298 # func_ltwrapper_p file
1299 # True iff FILE is a libtool wrapper script or wrapper executable
1300 # This function is only a basic sanity check; it will hardly flush out
1301 # determined imposters.
1302 func_ltwrapper_p ()
1303 {
1304 func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1"
1305 }
1306
1307
1308 # func_execute_cmds commands fail_cmd
1309 # Execute tilde-delimited COMMANDS.
1310 # If FAIL_CMD is given, eval that upon failure.
1311 # FAIL_CMD may read-access the current command in variable CMD!
1312 func_execute_cmds ()
1313 {
1314 $opt_debug
1315 save_ifs=$IFS; IFS='~'
1316 for cmd in $1; do
1317 IFS=$save_ifs
1318 eval cmd=\"$cmd\"
1319 func_show_eval "$cmd" "${2-:}"
1320 done
1321 IFS=$save_ifs
1322 }
1323
1324
1325 # func_source file
1326 # Source FILE, adding directory component if necessary.
1327 # Note that it is not necessary on cygwin/mingw to append a dot to
1328 # FILE even if both FILE and FILE.exe exist: automatic-append-.exe
1329 # behavior happens only for exec(3), not for open(2)! Also, sourcing
1330 # `FILE.' does not work on cygwin managed mounts.
1331 func_source ()
1332 {
1333 $opt_debug
1334 case $1 in
1335 */* | *\\*) . "$1" ;;
1336 *) . "./$1" ;;
1337 esac
1338 }
1339
1340
1341 # func_resolve_sysroot PATH
1342 # Replace a leading = in PATH with a sysroot. Store the result into
1343 # func_resolve_sysroot_result
1344 func_resolve_sysroot ()
1345 {
1346 func_resolve_sysroot_result=$1
1347 case $func_resolve_sysroot_result in
1348 =*)
1349 func_stripname '=' '' "$func_resolve_sysroot_result"
1350 func_resolve_sysroot_result=$lt_sysroot$func_stripname_result
1351 ;;
1352 esac
1353 }
1354
1355 # func_replace_sysroot PATH
1356 # If PATH begins with the sysroot, replace it with = and
1357 # store the result into func_replace_sysroot_result.
1358 func_replace_sysroot ()
1359 {
1360 case "$lt_sysroot:$1" in
1361 ?*:"$lt_sysroot"*)
1362 func_stripname "$lt_sysroot" '' "$1"
1363 func_replace_sysroot_result="=$func_stripname_result"
1364 ;;
1365 *)
1366 # Including no sysroot.
1367 func_replace_sysroot_result=$1
1368 ;;
1369 esac
1370 }
1371
1372 # func_infer_tag arg
1373 # Infer tagged configuration to use if any are available and
1374 # if one wasn't chosen via the "--tag" command line option.
1375 # Only attempt this if the compiler in the base compile
1376 # command doesn't match the default compiler.
1377 # arg is usually of the form 'gcc ...'
1378 func_infer_tag ()
1379 {
1380 $opt_debug
1381 if test -n "$available_tags" && test -z "$tagname"; then
1382 CC_quoted=
1383 for arg in $CC; do
1384 func_append_quoted CC_quoted "$arg"
1385 done
1386 CC_expanded=`func_echo_all $CC`
1387 CC_quoted_expanded=`func_echo_all $CC_quoted`
1388 case $@ in
1389 # Blanks in the command may have been stripped by the calling shell,
1390 # but not from the CC environment variable when configure was run.
1391 " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \
1392 " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;;
1393 # Blanks at the start of $base_compile will cause this to fail
1394 # if we don't check for them as well.
1395 *)
1396 for z in $available_tags; do
1397 if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then
1398 # Evaluate the configuration.
1399 eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`"
1400 CC_quoted=
1401 for arg in $CC; do
1402 # Double-quote args containing other shell metacharacters.
1403 func_append_quoted CC_quoted "$arg"
1404 done
1405 CC_expanded=`func_echo_all $CC`
1406 CC_quoted_expanded=`func_echo_all $CC_quoted`
1407 case "$@ " in
1408 " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \
1409 " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*)
1410 # The compiler in the base compile command matches
1411 # the one in the tagged configuration.
1412 # Assume this is the tagged configuration we want.
1413 tagname=$z
1414 break
1415 ;;
1416 esac
1417 fi
1418 done
1419 # If $tagname still isn't set, then no tagged configuration
1420 # was found and let the user know that the "--tag" command
1421 # line option must be used.
1422 if test -z "$tagname"; then
1423 func_echo "unable to infer tagged configuration"
1424 func_fatal_error "specify a tag with \`--tag'"
1425 # else
1426 # func_verbose "using $tagname tagged configuration"
1427 fi
1428 ;;
1429 esac
1430 fi
1431 }
1432
1433
1434
1435 # func_write_libtool_object output_name pic_name nonpic_name
1436 # Create a libtool object file (analogous to a ".la" file),
1437 # but don't create it if we're doing a dry run.
1438 func_write_libtool_object ()
1439 {
1440 write_libobj=${1}
1441 if test "$build_libtool_libs" = yes; then
1442 write_lobj=\'${2}\'
1443 else
1444 write_lobj=none
1445 fi
1446
1447 if test "$build_old_libs" = yes; then
1448 write_oldobj=\'${3}\'
1449 else
1450 write_oldobj=none
1451 fi
1452
1453 $opt_dry_run || {
1454 cat >${write_libobj}T <<EOF
1455 # $write_libobj - a libtool object file
1456 # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
1457 #
1458 # Please DO NOT delete this file!
1459 # It is necessary for linking the library.
1460
1461 # Name of the PIC object.
1462 pic_object=$write_lobj
1463
1464 # Name of the non-PIC object
1465 non_pic_object=$write_oldobj
1466
1467 EOF
1468 $MV "${write_libobj}T" "${write_libobj}"
1469 }
1470 }
1471
1472
1473 ##################################################
1474 # FILE NAME AND PATH CONVERSION HELPER FUNCTIONS #
1475 ##################################################
1476
1477 # func_convert_core_file_wine_to_w32 ARG
1478 # Helper function used by file name conversion functions when $build is *nix,
1479 # and $host is mingw, cygwin, or some other w32 environment. Relies on a
1480 # correctly configured wine environment available, with the winepath program
1481 # in $build's $PATH.
1482 #
1483 # ARG is the $build file name to be converted to w32 format.
1484 # Result is available in $func_convert_core_file_wine_to_w32_result, and will
1485 # be empty on error (or when ARG is empty)
1486 func_convert_core_file_wine_to_w32 ()
1487 {
1488 $opt_debug
1489 func_convert_core_file_wine_to_w32_result="$1"
1490 if test -n "$1"; then
1491 # Unfortunately, winepath does not exit with a non-zero error code, so we
1492 # are forced to check the contents of stdout. On the other hand, if the
1493 # command is not found, the shell will set an exit code of 127 and print
1494 # *an error message* to stdout. So we must check for both error code of
1495 # zero AND non-empty stdout, which explains the odd construction:
1496 func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null`
1497 if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then
1498 func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" |
1499 $SED -e "$lt_sed_naive_backslashify"`
1500 else
1501 func_convert_core_file_wine_to_w32_result=
1502 fi
1503 fi
1504 }
1505 # end: func_convert_core_file_wine_to_w32
1506
1507
1508 # func_convert_core_path_wine_to_w32 ARG
1509 # Helper function used by path conversion functions when $build is *nix, and
1510 # $host is mingw, cygwin, or some other w32 environment. Relies on a correctly
1511 # configured wine environment available, with the winepath program in $build's
1512 # $PATH. Assumes ARG has no leading or trailing path separator characters.
1513 #
1514 # ARG is path to be converted from $build format to win32.
1515 # Result is available in $func_convert_core_path_wine_to_w32_result.
1516 # Unconvertible file (directory) names in ARG are skipped; if no directory names
1517 # are convertible, then the result may be empty.
1518 func_convert_core_path_wine_to_w32 ()
1519 {
1520 $opt_debug
1521 # unfortunately, winepath doesn't convert paths, only file names
1522 func_convert_core_path_wine_to_w32_result=""
1523 if test -n "$1"; then
1524 oldIFS=$IFS
1525 IFS=:
1526 for func_convert_core_path_wine_to_w32_f in $1; do
1527 IFS=$oldIFS
1528 func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f"
1529 if test -n "$func_convert_core_file_wine_to_w32_result" ; then
1530 if test -z "$func_convert_core_path_wine_to_w32_result"; then
1531 func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result"
1532 else
1533 func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result"
1534 fi
1535 fi
1536 done
1537 IFS=$oldIFS
1538 fi
1539 }
1540 # end: func_convert_core_path_wine_to_w32
1541
1542
1543 # func_cygpath ARGS...
1544 # Wrapper around calling the cygpath program via LT_CYGPATH. This is used when
1545 # when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2)
1546 # $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or
1547 # (2), returns the Cygwin file name or path in func_cygpath_result (input
1548 # file name or path is assumed to be in w32 format, as previously converted
1549 # from $build's *nix or MSYS format). In case (3), returns the w32 file name
1550 # or path in func_cygpath_result (input file name or path is assumed to be in
1551 # Cygwin format). Returns an empty string on error.
1552 #
1553 # ARGS are passed to cygpath, with the last one being the file name or path to
1554 # be converted.
1555 #
1556 # Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH
1557 # environment variable; do not put it in $PATH.
1558 func_cygpath ()
1559 {
1560 $opt_debug
1561 if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then
1562 func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null`
1563 if test "$?" -ne 0; then
1564 # on failure, ensure result is empty
1565 func_cygpath_result=
1566 fi
1567 else
1568 func_cygpath_result=
1569 func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'"
1570 fi
1571 }
1572 #end: func_cygpath
1573
1574
1575 # func_convert_core_msys_to_w32 ARG
1576 # Convert file name or path ARG from MSYS format to w32 format. Return
1577 # result in func_convert_core_msys_to_w32_result.
1578 func_convert_core_msys_to_w32 ()
1579 {
1580 $opt_debug
1581 # awkward: cmd appends spaces to result
1582 func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null |
1583 $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
1584 }
1585 #end: func_convert_core_msys_to_w32
1586
1587
1588 # func_convert_file_check ARG1 ARG2
1589 # Verify that ARG1 (a file name in $build format) was converted to $host
1590 # format in ARG2. Otherwise, emit an error message, but continue (resetting
1591 # func_to_host_file_result to ARG1).
1592 func_convert_file_check ()
1593 {
1594 $opt_debug
1595 if test -z "$2" && test -n "$1" ; then
1596 func_error "Could not determine host file name corresponding to"
1597 func_error " \`$1'"
1598 func_error "Continuing, but uninstalled executables may not work."
1599 # Fallback:
1600 func_to_host_file_result="$1"
1601 fi
1602 }
1603 # end func_convert_file_check
1604
1605
1606 # func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH
1607 # Verify that FROM_PATH (a path in $build format) was converted to $host
1608 # format in TO_PATH. Otherwise, emit an error message, but continue, resetting
1609 # func_to_host_file_result to a simplistic fallback value (see below).
1610 func_convert_path_check ()
1611 {
1612 $opt_debug
1613 if test -z "$4" && test -n "$3"; then
1614 func_error "Could not determine the host path corresponding to"
1615 func_error " \`$3'"
1616 func_error "Continuing, but uninstalled executables may not work."
1617 # Fallback. This is a deliberately simplistic "conversion" and
1618 # should not be "improved". See libtool.info.
1619 if test "x$1" != "x$2"; then
1620 lt_replace_pathsep_chars="s|$1|$2|g"
1621 func_to_host_path_result=`echo "$3" |
1622 $SED -e "$lt_replace_pathsep_chars"`
1623 else
1624 func_to_host_path_result="$3"
1625 fi
1626 fi
1627 }
1628 # end func_convert_path_check
1629
1630
1631 # func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG
1632 # Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT
1633 # and appending REPL if ORIG matches BACKPAT.
1634 func_convert_path_front_back_pathsep ()
1635 {
1636 $opt_debug
1637 case $4 in
1638 $1 ) func_to_host_path_result="$3$func_to_host_path_result"
1639 ;;
1640 esac
1641 case $4 in
1642 $2 ) func_append func_to_host_path_result "$3"
1643 ;;
1644 esac
1645 }
1646 # end func_convert_path_front_back_pathsep
1647
1648
1649 ##################################################
1650 # $build to $host FILE NAME CONVERSION FUNCTIONS #
1651 ##################################################
1652 # invoked via `$to_host_file_cmd ARG'
1653 #
1654 # In each case, ARG is the path to be converted from $build to $host format.
1655 # Result will be available in $func_to_host_file_result.
1656
1657
1658 # func_to_host_file ARG
1659 # Converts the file name ARG from $build format to $host format. Return result
1660 # in func_to_host_file_result.
1661 func_to_host_file ()
1662 {
1663 $opt_debug
1664 $to_host_file_cmd "$1"
1665 }
1666 # end func_to_host_file
1667
1668
1669 # func_to_tool_file ARG LAZY
1670 # converts the file name ARG from $build format to toolchain format. Return
1671 # result in func_to_tool_file_result. If the conversion in use is listed
1672 # in (the comma separated) LAZY, no conversion takes place.
1673 func_to_tool_file ()
1674 {
1675 $opt_debug
1676 case ,$2, in
1677 *,"$to_tool_file_cmd",*)
1678 func_to_tool_file_result=$1
1679 ;;
1680 *)
1681 $to_tool_file_cmd "$1"
1682 func_to_tool_file_result=$func_to_host_file_result
1683 ;;
1684 esac
1685 }
1686 # end func_to_tool_file
1687
1688
1689 # func_convert_file_noop ARG
1690 # Copy ARG to func_to_host_file_result.
1691 func_convert_file_noop ()
1692 {
1693 func_to_host_file_result="$1"
1694 }
1695 # end func_convert_file_noop
1696
1697
1698 # func_convert_file_msys_to_w32 ARG
1699 # Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic
1700 # conversion to w32 is not available inside the cwrapper. Returns result in
1701 # func_to_host_file_result.
1702 func_convert_file_msys_to_w32 ()
1703 {
1704 $opt_debug
1705 func_to_host_file_result="$1"
1706 if test -n "$1"; then
1707 func_convert_core_msys_to_w32 "$1"
1708 func_to_host_file_result="$func_convert_core_msys_to_w32_result"
1709 fi
1710 func_convert_file_check "$1" "$func_to_host_file_result"
1711 }
1712 # end func_convert_file_msys_to_w32
1713
1714
1715 # func_convert_file_cygwin_to_w32 ARG
1716 # Convert file name ARG from Cygwin to w32 format. Returns result in
1717 # func_to_host_file_result.
1718 func_convert_file_cygwin_to_w32 ()
1719 {
1720 $opt_debug
1721 func_to_host_file_result="$1"
1722 if test -n "$1"; then
1723 # because $build is cygwin, we call "the" cygpath in $PATH; no need to use
1724 # LT_CYGPATH in this case.
1725 func_to_host_file_result=`cygpath -m "$1"`
1726 fi
1727 func_convert_file_check "$1" "$func_to_host_file_result"
1728 }
1729 # end func_convert_file_cygwin_to_w32
1730
1731
1732 # func_convert_file_nix_to_w32 ARG
1733 # Convert file name ARG from *nix to w32 format. Requires a wine environment
1734 # and a working winepath. Returns result in func_to_host_file_result.
1735 func_convert_file_nix_to_w32 ()
1736 {
1737 $opt_debug
1738 func_to_host_file_result="$1"
1739 if test -n "$1"; then
1740 func_convert_core_file_wine_to_w32 "$1"
1741 func_to_host_file_result="$func_convert_core_file_wine_to_w32_result"
1742 fi
1743 func_convert_file_check "$1" "$func_to_host_file_result"
1744 }
1745 # end func_convert_file_nix_to_w32
1746
1747
1748 # func_convert_file_msys_to_cygwin ARG
1749 # Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set.
1750 # Returns result in func_to_host_file_result.
1751 func_convert_file_msys_to_cygwin ()
1752 {
1753 $opt_debug
1754 func_to_host_file_result="$1"
1755 if test -n "$1"; then
1756 func_convert_core_msys_to_w32 "$1"
1757 func_cygpath -u "$func_convert_core_msys_to_w32_result"
1758 func_to_host_file_result="$func_cygpath_result"
1759 fi
1760 func_convert_file_check "$1" "$func_to_host_file_result"
1761 }
1762 # end func_convert_file_msys_to_cygwin
1763
1764
1765 # func_convert_file_nix_to_cygwin ARG
1766 # Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed
1767 # in a wine environment, working winepath, and LT_CYGPATH set. Returns result
1768 # in func_to_host_file_result.
1769 func_convert_file_nix_to_cygwin ()
1770 {
1771 $opt_debug
1772 func_to_host_file_result="$1"
1773 if test -n "$1"; then
1774 # convert from *nix to w32, then use cygpath to convert from w32 to cygwin.
1775 func_convert_core_file_wine_to_w32 "$1"
1776 func_cygpath -u "$func_convert_core_file_wine_to_w32_result"
1777 func_to_host_file_result="$func_cygpath_result"
1778 fi
1779 func_convert_file_check "$1" "$func_to_host_file_result"
1780 }
1781 # end func_convert_file_nix_to_cygwin
1782
1783
1784 #############################################
1785 # $build to $host PATH CONVERSION FUNCTIONS #
1786 #############################################
1787 # invoked via `$to_host_path_cmd ARG'
1788 #
1789 # In each case, ARG is the path to be converted from $build to $host format.
1790 # The result will be available in $func_to_host_path_result.
1791 #
1792 # Path separators are also converted from $build format to $host format. If
1793 # ARG begins or ends with a path separator character, it is preserved (but
1794 # converted to $host format) on output.
1795 #
1796 # All path conversion functions are named using the following convention:
1797 # file name conversion function : func_convert_file_X_to_Y ()
1798 # path conversion function : func_convert_path_X_to_Y ()
1799 # where, for any given $build/$host combination the 'X_to_Y' value is the
1800 # same. If conversion functions are added for new $build/$host combinations,
1801 # the two new functions must follow this pattern, or func_init_to_host_path_cmd
1802 # will break.
1803
1804
1805 # func_init_to_host_path_cmd
1806 # Ensures that function "pointer" variable $to_host_path_cmd is set to the
1807 # appropriate value, based on the value of $to_host_file_cmd.
1808 to_host_path_cmd=
1809 func_init_to_host_path_cmd ()
1810 {
1811 $opt_debug
1812 if test -z "$to_host_path_cmd"; then
1813 func_stripname 'func_convert_file_' '' "$to_host_file_cmd"
1814 to_host_path_cmd="func_convert_path_${func_stripname_result}"
1815 fi
1816 }
1817
1818
1819 # func_to_host_path ARG
1820 # Converts the path ARG from $build format to $host format. Return result
1821 # in func_to_host_path_result.
1822 func_to_host_path ()
1823 {
1824 $opt_debug
1825 func_init_to_host_path_cmd
1826 $to_host_path_cmd "$1"
1827 }
1828 # end func_to_host_path
1829
1830
1831 # func_convert_path_noop ARG
1832 # Copy ARG to func_to_host_path_result.
1833 func_convert_path_noop ()
1834 {
1835 func_to_host_path_result="$1"
1836 }
1837 # end func_convert_path_noop
1838
1839
1840 # func_convert_path_msys_to_w32 ARG
1841 # Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic
1842 # conversion to w32 is not available inside the cwrapper. Returns result in
1843 # func_to_host_path_result.
1844 func_convert_path_msys_to_w32 ()
1845 {
1846 $opt_debug
1847 func_to_host_path_result="$1"
1848 if test -n "$1"; then
1849 # Remove leading and trailing path separator characters from ARG. MSYS
1850 # behavior is inconsistent here; cygpath turns them into '.;' and ';.';
1851 # and winepath ignores them completely.
1852 func_stripname : : "$1"
1853 func_to_host_path_tmp1=$func_stripname_result
1854 func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
1855 func_to_host_path_result="$func_convert_core_msys_to_w32_result"
1856 func_convert_path_check : ";" \
1857 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1858 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
1859 fi
1860 }
1861 # end func_convert_path_msys_to_w32
1862
1863
1864 # func_convert_path_cygwin_to_w32 ARG
1865 # Convert path ARG from Cygwin to w32 format. Returns result in
1866 # func_to_host_file_result.
1867 func_convert_path_cygwin_to_w32 ()
1868 {
1869 $opt_debug
1870 func_to_host_path_result="$1"
1871 if test -n "$1"; then
1872 # See func_convert_path_msys_to_w32:
1873 func_stripname : : "$1"
1874 func_to_host_path_tmp1=$func_stripname_result
1875 func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"`
1876 func_convert_path_check : ";" \
1877 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1878 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
1879 fi
1880 }
1881 # end func_convert_path_cygwin_to_w32
1882
1883
1884 # func_convert_path_nix_to_w32 ARG
1885 # Convert path ARG from *nix to w32 format. Requires a wine environment and
1886 # a working winepath. Returns result in func_to_host_file_result.
1887 func_convert_path_nix_to_w32 ()
1888 {
1889 $opt_debug
1890 func_to_host_path_result="$1"
1891 if test -n "$1"; then
1892 # See func_convert_path_msys_to_w32:
1893 func_stripname : : "$1"
1894 func_to_host_path_tmp1=$func_stripname_result
1895 func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
1896 func_to_host_path_result="$func_convert_core_path_wine_to_w32_result"
1897 func_convert_path_check : ";" \
1898 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1899 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
1900 fi
1901 }
1902 # end func_convert_path_nix_to_w32
1903
1904
1905 # func_convert_path_msys_to_cygwin ARG
1906 # Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set.
1907 # Returns result in func_to_host_file_result.
1908 func_convert_path_msys_to_cygwin ()
1909 {
1910 $opt_debug
1911 func_to_host_path_result="$1"
1912 if test -n "$1"; then
1913 # See func_convert_path_msys_to_w32:
1914 func_stripname : : "$1"
1915 func_to_host_path_tmp1=$func_stripname_result
1916 func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
1917 func_cygpath -u -p "$func_convert_core_msys_to_w32_result"
1918 func_to_host_path_result="$func_cygpath_result"
1919 func_convert_path_check : : \
1920 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1921 func_convert_path_front_back_pathsep ":*" "*:" : "$1"
1922 fi
1923 }
1924 # end func_convert_path_msys_to_cygwin
1925
1926
1927 # func_convert_path_nix_to_cygwin ARG
1928 # Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a
1929 # a wine environment, working winepath, and LT_CYGPATH set. Returns result in
1930 # func_to_host_file_result.
1931 func_convert_path_nix_to_cygwin ()
1932 {
1933 $opt_debug
1934 func_to_host_path_result="$1"
1935 if test -n "$1"; then
1936 # Remove leading and trailing path separator characters from
1937 # ARG. msys behavior is inconsistent here, cygpath turns them
1938 # into '.;' and ';.', and winepath ignores them completely.
1939 func_stripname : : "$1"
1940 func_to_host_path_tmp1=$func_stripname_result
1941 func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
1942 func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result"
1943 func_to_host_path_result="$func_cygpath_result"
1944 func_convert_path_check : : \
1945 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1946 func_convert_path_front_back_pathsep ":*" "*:" : "$1"
1947 fi
1948 }
1949 # end func_convert_path_nix_to_cygwin
1950
1951
1952 # func_mode_compile arg...
1953 func_mode_compile ()
1954 {
1955 $opt_debug
1956 # Get the compilation command and the source file.
1957 base_compile=
1958 srcfile="$nonopt" # always keep a non-empty value in "srcfile"
1959 suppress_opt=yes
1960 suppress_output=
1961 arg_mode=normal
1962 libobj=
1963 later=
1964 pie_flag=
1965
1966 for arg
1967 do
1968 case $arg_mode in
1969 arg )
1970 # do not "continue". Instead, add this to base_compile
1971 lastarg="$arg"
1972 arg_mode=normal
1973 ;;
1974
1975 target )
1976 libobj="$arg"
1977 arg_mode=normal
1978 continue
1979 ;;
1980
1981 normal )
1982 # Accept any command-line options.
1983 case $arg in
1984 -o)
1985 test -n "$libobj" && \
1986 func_fatal_error "you cannot specify \`-o' more than once"
1987 arg_mode=target
1988 continue
1989 ;;
1990
1991 -pie | -fpie | -fPIE)
1992 func_append pie_flag " $arg"
1993 continue
1994 ;;
1995
1996 -shared | -static | -prefer-pic | -prefer-non-pic)
1997 func_append later " $arg"
1998 continue
1999 ;;
2000
2001 -no-suppress)
2002 suppress_opt=no
2003 continue
2004 ;;
2005
2006 -Xcompiler)
2007 arg_mode=arg # the next one goes into the "base_compile" arg list
2008 continue # The current "srcfile" will either be retained or
2009 ;; # replaced later. I would guess that would be a bug.
2010
2011 -Wc,*)
2012 func_stripname '-Wc,' '' "$arg"
2013 args=$func_stripname_result
2014 lastarg=
2015 save_ifs="$IFS"; IFS=','
2016 for arg in $args; do
2017 IFS="$save_ifs"
2018 func_append_quoted lastarg "$arg"
2019 done
2020 IFS="$save_ifs"
2021 func_stripname ' ' '' "$lastarg"
2022 lastarg=$func_stripname_result
2023
2024 # Add the arguments to base_compile.
2025 func_append base_compile " $lastarg"
2026 continue
2027 ;;
2028
2029 *)
2030 # Accept the current argument as the source file.
2031 # The previous "srcfile" becomes the current argument.
2032 #
2033 lastarg="$srcfile"
2034 srcfile="$arg"
2035 ;;
2036 esac # case $arg
2037 ;;
2038 esac # case $arg_mode
2039
2040 # Aesthetically quote the previous argument.
2041 func_append_quoted base_compile "$lastarg"
2042 done # for arg
2043
2044 case $arg_mode in
2045 arg)
2046 func_fatal_error "you must specify an argument for -Xcompile"
2047 ;;
2048 target)
2049 func_fatal_error "you must specify a target with \`-o'"
2050 ;;
2051 *)
2052 # Get the name of the library object.
2053 test -z "$libobj" && {
2054 func_basename "$srcfile"
2055 libobj="$func_basename_result"
2056 }
2057 ;;
2058 esac
2059
2060 # Recognize several different file suffixes.
2061 # If the user specifies -o file.o, it is replaced with file.lo
2062 case $libobj in
2063 *.[cCFSifmso] | \
2064 *.ada | *.adb | *.ads | *.asm | \
2065 *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \
2066 *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup)
2067 func_xform "$libobj"
2068 libobj=$func_xform_result
2069 ;;
2070 esac
2071
2072 case $libobj in
2073 *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;;
2074 *)
2075 func_fatal_error "cannot determine name of library object from \`$libobj'"
2076 ;;
2077 esac
2078
2079 func_infer_tag $base_compile
2080
2081 for arg in $later; do
2082 case $arg in
2083 -shared)
2084 test "$build_libtool_libs" != yes && \
2085 func_fatal_configuration "can not build a shared library"
2086 build_old_libs=no
2087 continue
2088 ;;
2089
2090 -static)
2091 build_libtool_libs=no
2092 build_old_libs=yes
2093 continue
2094 ;;
2095
2096 -prefer-pic)
2097 pic_mode=yes
2098 continue
2099 ;;
2100
2101 -prefer-non-pic)
2102 pic_mode=no
2103 continue
2104 ;;
2105 esac
2106 done
2107
2108 func_quote_for_eval "$libobj"
2109 test "X$libobj" != "X$func_quote_for_eval_result" \
2110 && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \
2111 && func_warning "libobj name \`$libobj' may not contain shell special characters."
2112 func_dirname_and_basename "$obj" "/" ""
2113 objname="$func_basename_result"
2114 xdir="$func_dirname_result"
2115 lobj=${xdir}$objdir/$objname
2116
2117 test -z "$base_compile" && \
2118 func_fatal_help "you must specify a compilation command"
2119
2120 # Delete any leftover library objects.
2121 if test "$build_old_libs" = yes; then
2122 removelist="$obj $lobj $libobj ${libobj}T"
2123 else
2124 removelist="$lobj $libobj ${libobj}T"
2125 fi
2126
2127 # On Cygwin there's no "real" PIC flag so we must build both object types
2128 case $host_os in
2129 cygwin* | mingw* | pw32* | os2* | cegcc*)
2130 pic_mode=default
2131 ;;
2132 esac
2133 if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then
2134 # non-PIC code in shared libraries is not supported
2135 pic_mode=default
2136 fi
2137
2138 # Calculate the filename of the output object if compiler does
2139 # not support -o with -c
2140 if test "$compiler_c_o" = no; then
2141 output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext}
2142 lockfile="$output_obj.lock"
2143 else
2144 output_obj=
2145 need_locks=no
2146 lockfile=
2147 fi
2148
2149 # Lock this critical section if it is needed
2150 # We use this script file to make the link, it avoids creating a new file
2151 if test "$need_locks" = yes; then
2152 until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
2153 func_echo "Waiting for $lockfile to be removed"
2154 sleep 2
2155 done
2156 elif test "$need_locks" = warn; then
2157 if test -f "$lockfile"; then
2158 $ECHO "\
2159 *** ERROR, $lockfile exists and contains:
2160 `cat $lockfile 2>/dev/null`
2161
2162 This indicates that another process is trying to use the same
2163 temporary object file, and libtool could not work around it because
2164 your compiler does not support \`-c' and \`-o' together. If you
2165 repeat this compilation, it may succeed, by chance, but you had better
2166 avoid parallel builds (make -j) in this platform, or get a better
2167 compiler."
2168
2169 $opt_dry_run || $RM $removelist
2170 exit $EXIT_FAILURE
2171 fi
2172 func_append removelist " $output_obj"
2173 $ECHO "$srcfile" > "$lockfile"
2174 fi
2175
2176 $opt_dry_run || $RM $removelist
2177 func_append removelist " $lockfile"
2178 trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15
2179
2180 func_to_tool_file "$srcfile" func_convert_file_msys_to_w32
2181 srcfile=$func_to_tool_file_result
2182 func_quote_for_eval "$srcfile"
2183 qsrcfile=$func_quote_for_eval_result
2184
2185 # Only build a PIC object if we are building libtool libraries.
2186 if test "$build_libtool_libs" = yes; then
2187 # Without this assignment, base_compile gets emptied.
2188 fbsd_hideous_sh_bug=$base_compile
2189
2190 if test "$pic_mode" != no; then
2191 command="$base_compile $qsrcfile $pic_flag"
2192 else
2193 # Don't build PIC code
2194 command="$base_compile $qsrcfile"
2195 fi
2196
2197 func_mkdir_p "$xdir$objdir"
2198
2199 if test -z "$output_obj"; then
2200 # Place PIC objects in $objdir
2201 func_append command " -o $lobj"
2202 fi
2203
2204 func_show_eval_locale "$command" \
2205 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE'
2206
2207 if test "$need_locks" = warn &&
2208 test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
2209 $ECHO "\
2210 *** ERROR, $lockfile contains:
2211 `cat $lockfile 2>/dev/null`
2212
2213 but it should contain:
2214 $srcfile
2215
2216 This indicates that another process is trying to use the same
2217 temporary object file, and libtool could not work around it because
2218 your compiler does not support \`-c' and \`-o' together. If you
2219 repeat this compilation, it may succeed, by chance, but you had better
2220 avoid parallel builds (make -j) in this platform, or get a better
2221 compiler."
2222
2223 $opt_dry_run || $RM $removelist
2224 exit $EXIT_FAILURE
2225 fi
2226
2227 # Just move the object if needed, then go on to compile the next one
2228 if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then
2229 func_show_eval '$MV "$output_obj" "$lobj"' \
2230 'error=$?; $opt_dry_run || $RM $removelist; exit $error'
2231 fi
2232
2233 # Allow error messages only from the first compilation.
2234 if test "$suppress_opt" = yes; then
2235 suppress_output=' >/dev/null 2>&1'
2236 fi
2237 fi
2238
2239 # Only build a position-dependent object if we build old libraries.
2240 if test "$build_old_libs" = yes; then
2241 if test "$pic_mode" != yes; then
2242 # Don't build PIC code
2243 command="$base_compile $qsrcfile$pie_flag"
2244 else
2245 command="$base_compile $qsrcfile $pic_flag"
2246 fi
2247 if test "$compiler_c_o" = yes; then
2248 func_append command " -o $obj"
2249 fi
2250
2251 # Suppress compiler output if we already did a PIC compilation.
2252 func_append command "$suppress_output"
2253 func_show_eval_locale "$command" \
2254 '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE'
2255
2256 if test "$need_locks" = warn &&
2257 test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
2258 $ECHO "\
2259 *** ERROR, $lockfile contains:
2260 `cat $lockfile 2>/dev/null`
2261
2262 but it should contain:
2263 $srcfile
2264
2265 This indicates that another process is trying to use the same
2266 temporary object file, and libtool could not work around it because
2267 your compiler does not support \`-c' and \`-o' together. If you
2268 repeat this compilation, it may succeed, by chance, but you had better
2269 avoid parallel builds (make -j) in this platform, or get a better
2270 compiler."
2271
2272 $opt_dry_run || $RM $removelist
2273 exit $EXIT_FAILURE
2274 fi
2275
2276 # Just move the object if needed
2277 if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then
2278 func_show_eval '$MV "$output_obj" "$obj"' \
2279 'error=$?; $opt_dry_run || $RM $removelist; exit $error'
2280 fi
2281 fi
2282
2283 $opt_dry_run || {
2284 func_write_libtool_object "$libobj" "$objdir/$objname" "$objname"
2285
2286 # Unlock the critical section if it was locked
2287 if test "$need_locks" != no; then
2288 removelist=$lockfile
2289 $RM "$lockfile"
2290 fi
2291 }
2292
2293 exit $EXIT_SUCCESS
2294 }
2295
2296 $opt_help || {
2297 test "$opt_mode" = compile && func_mode_compile ${1+"$@"}
2298 }
2299
2300 func_mode_help ()
2301 {
2302 # We need to display help for each of the modes.
2303 case $opt_mode in
2304 "")
2305 # Generic help is extracted from the usage comments
2306 # at the start of this file.
2307 func_help
2308 ;;
2309
2310 clean)
2311 $ECHO \
2312 "Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE...
2313
2314 Remove files from the build directory.
2315
2316 RM is the name of the program to use to delete files associated with each FILE
2317 (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
2318 to RM.
2319
2320 If FILE is a libtool library, object or program, all the files associated
2321 with it are deleted. Otherwise, only FILE itself is deleted using RM."
2322 ;;
2323
2324 compile)
2325 $ECHO \
2326 "Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE
2327
2328 Compile a source file into a libtool library object.
2329
2330 This mode accepts the following additional options:
2331
2332 -o OUTPUT-FILE set the output file name to OUTPUT-FILE
2333 -no-suppress do not suppress compiler output for multiple passes
2334 -prefer-pic try to build PIC objects only
2335 -prefer-non-pic try to build non-PIC objects only
2336 -shared do not build a \`.o' file suitable for static linking
2337 -static only build a \`.o' file suitable for static linking
2338 -Wc,FLAG pass FLAG directly to the compiler
2339
2340 COMPILE-COMMAND is a command to be used in creating a \`standard' object file
2341 from the given SOURCEFILE.
2342
2343 The output file name is determined by removing the directory component from
2344 SOURCEFILE, then substituting the C source code suffix \`.c' with the
2345 library object suffix, \`.lo'."
2346 ;;
2347
2348 execute)
2349 $ECHO \
2350 "Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]...
2351
2352 Automatically set library path, then run a program.
2353
2354 This mode accepts the following additional options:
2355
2356 -dlopen FILE add the directory containing FILE to the library path
2357
2358 This mode sets the library path environment variable according to \`-dlopen'
2359 flags.
2360
2361 If any of the ARGS are libtool executable wrappers, then they are translated
2362 into their corresponding uninstalled binary, and any of their required library
2363 directories are added to the library path.
2364
2365 Then, COMMAND is executed, with ARGS as arguments."
2366 ;;
2367
2368 finish)
2369 $ECHO \
2370 "Usage: $progname [OPTION]... --mode=finish [LIBDIR]...
2371
2372 Complete the installation of libtool libraries.
2373
2374 Each LIBDIR is a directory that contains libtool libraries.
2375
2376 The commands that this mode executes may require superuser privileges. Use
2377 the \`--dry-run' option if you just want to see what would be executed."
2378 ;;
2379
2380 install)
2381 $ECHO \
2382 "Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND...
2383
2384 Install executables or libraries.
2385
2386 INSTALL-COMMAND is the installation command. The first component should be
2387 either the \`install' or \`cp' program.
2388
2389 The following components of INSTALL-COMMAND are treated specially:
2390
2391 -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation
2392
2393 The rest of the components are interpreted as arguments to that command (only
2394 BSD-compatible install options are recognized)."
2395 ;;
2396
2397 link)
2398 $ECHO \
2399 "Usage: $progname [OPTION]... --mode=link LINK-COMMAND...
2400
2401 Link object files or libraries together to form another library, or to
2402 create an executable program.
2403
2404 LINK-COMMAND is a command using the C compiler that you would use to create
2405 a program from several object files.
2406
2407 The following components of LINK-COMMAND are treated specially:
2408
2409 -all-static do not do any dynamic linking at all
2410 -avoid-version do not add a version suffix if possible
2411 -bindir BINDIR specify path to binaries directory (for systems where
2412 libraries must be found in the PATH setting at runtime)
2413 -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime
2414 -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols
2415 -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
2416 -export-symbols SYMFILE
2417 try to export only the symbols listed in SYMFILE
2418 -export-symbols-regex REGEX
2419 try to export only the symbols matching REGEX
2420 -LLIBDIR search LIBDIR for required installed libraries
2421 -lNAME OUTPUT-FILE requires the installed library libNAME
2422 -module build a library that can dlopened
2423 -no-fast-install disable the fast-install mode
2424 -no-install link a not-installable executable
2425 -no-undefined declare that a library does not refer to external symbols
2426 -o OUTPUT-FILE create OUTPUT-FILE from the specified objects
2427 -objectlist FILE Use a list of object files found in FILE to specify objects
2428 -precious-files-regex REGEX
2429 don't remove output files matching REGEX
2430 -release RELEASE specify package release information
2431 -rpath LIBDIR the created library will eventually be installed in LIBDIR
2432 -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries
2433 -shared only do dynamic linking of libtool libraries
2434 -shrext SUFFIX override the standard shared library file extension
2435 -static do not do any dynamic linking of uninstalled libtool libraries
2436 -static-libtool-libs
2437 do not do any dynamic linking of libtool libraries
2438 -version-info CURRENT[:REVISION[:AGE]]
2439 specify library version info [each variable defaults to 0]
2440 -weak LIBNAME declare that the target provides the LIBNAME interface
2441 -Wc,FLAG
2442 -Xcompiler FLAG pass linker-specific FLAG directly to the compiler
2443 -Wl,FLAG
2444 -Xlinker FLAG pass linker-specific FLAG directly to the linker
2445 -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC)
2446
2447 All other options (arguments beginning with \`-') are ignored.
2448
2449 Every other argument is treated as a filename. Files ending in \`.la' are
2450 treated as uninstalled libtool libraries, other files are standard or library
2451 object files.
2452
2453 If the OUTPUT-FILE ends in \`.la', then a libtool library is created,
2454 only library objects (\`.lo' files) may be specified, and \`-rpath' is
2455 required, except when creating a convenience library.
2456
2457 If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created
2458 using \`ar' and \`ranlib', or on Windows using \`lib'.
2459
2460 If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file
2461 is created, otherwise an executable program is created."
2462 ;;
2463
2464 uninstall)
2465 $ECHO \
2466 "Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE...
2467
2468 Remove libraries from an installation directory.
2469
2470 RM is the name of the program to use to delete files associated with each FILE
2471 (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
2472 to RM.
2473
2474 If FILE is a libtool library, all the files associated with it are deleted.
2475 Otherwise, only FILE itself is deleted using RM."
2476 ;;
2477
2478 *)
2479 func_fatal_help "invalid operation mode \`$opt_mode'"
2480 ;;
2481 esac
2482
2483 echo
2484 $ECHO "Try \`$progname --help' for more information about other modes."
2485 }
2486
2487 # Now that we've collected a possible --mode arg, show help if necessary
2488 if $opt_help; then
2489 if test "$opt_help" = :; then
2490 func_mode_help
2491 else
2492 {
2493 func_help noexit
2494 for opt_mode in compile link execute install finish uninstall clean; do
2495 func_mode_help
2496 done
2497 } | sed -n '1p; 2,$s/^Usage:/ or: /p'
2498 {
2499 func_help noexit
2500 for opt_mode in compile link execute install finish uninstall clean; do
2501 echo
2502 func_mode_help
2503 done
2504 } |
2505 sed '1d
2506 /^When reporting/,/^Report/{
2507 H
2508 d
2509 }
2510 $x
2511 /information about other modes/d
2512 /more detailed .*MODE/d
2513 s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/'
2514 fi
2515 exit $?
2516 fi
2517
2518
2519 # func_mode_execute arg...
2520 func_mode_execute ()
2521 {
2522 $opt_debug
2523 # The first argument is the command name.
2524 cmd="$nonopt"
2525 test -z "$cmd" && \
2526 func_fatal_help "you must specify a COMMAND"
2527
2528 # Handle -dlopen flags immediately.
2529 for file in $opt_dlopen; do
2530 test -f "$file" \
2531 || func_fatal_help "\`$file' is not a file"
2532
2533 dir=
2534 case $file in
2535 *.la)
2536 func_resolve_sysroot "$file"
2537 file=$func_resolve_sysroot_result
2538
2539 # Check to see that this really is a libtool archive.
2540 func_lalib_unsafe_p "$file" \
2541 || func_fatal_help "\`$lib' is not a valid libtool archive"
2542
2543 # Read the libtool library.
2544 dlname=
2545 library_names=
2546 func_source "$file"
2547
2548 # Skip this library if it cannot be dlopened.
2549 if test -z "$dlname"; then
2550 # Warn if it was a shared library.
2551 test -n "$library_names" && \
2552 func_warning "\`$file' was not linked with \`-export-dynamic'"
2553 continue
2554 fi
2555
2556 func_dirname "$file" "" "."
2557 dir="$func_dirname_result"
2558
2559 if test -f "$dir/$objdir/$dlname"; then
2560 func_append dir "/$objdir"
2561 else
2562 if test ! -f "$dir/$dlname"; then
2563 func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'"
2564 fi
2565 fi
2566 ;;
2567
2568 *.lo)
2569 # Just add the directory containing the .lo file.
2570 func_dirname "$file" "" "."
2571 dir="$func_dirname_result"
2572 ;;
2573
2574 *)
2575 func_warning "\`-dlopen' is ignored for non-libtool libraries and objects"
2576 continue
2577 ;;
2578 esac
2579
2580 # Get the absolute pathname.
2581 absdir=`cd "$dir" && pwd`
2582 test -n "$absdir" && dir="$absdir"
2583
2584 # Now add the directory to shlibpath_var.
2585 if eval "test -z \"\$$shlibpath_var\""; then
2586 eval "$shlibpath_var=\"\$dir\""
2587 else
2588 eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\""
2589 fi
2590 done
2591
2592 # This variable tells wrapper scripts just to set shlibpath_var
2593 # rather than running their programs.
2594 libtool_execute_magic="$magic"
2595
2596 # Check if any of the arguments is a wrapper script.
2597 args=
2598 for file
2599 do
2600 case $file in
2601 -* | *.la | *.lo ) ;;
2602 *)
2603 # Do a test to see if this is really a libtool program.
2604 if func_ltwrapper_script_p "$file"; then
2605 func_source "$file"
2606 # Transform arg to wrapped name.
2607 file="$progdir/$program"
2608 elif func_ltwrapper_executable_p "$file"; then
2609 func_ltwrapper_scriptname "$file"
2610 func_source "$func_ltwrapper_scriptname_result"
2611 # Transform arg to wrapped name.
2612 file="$progdir/$program"
2613 fi
2614 ;;
2615 esac
2616 # Quote arguments (to preserve shell metacharacters).
2617 func_append_quoted args "$file"
2618 done
2619
2620 if test "X$opt_dry_run" = Xfalse; then
2621 if test -n "$shlibpath_var"; then
2622 # Export the shlibpath_var.
2623 eval "export $shlibpath_var"
2624 fi
2625
2626 # Restore saved environment variables
2627 for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
2628 do
2629 eval "if test \"\${save_$lt_var+set}\" = set; then
2630 $lt_var=\$save_$lt_var; export $lt_var
2631 else
2632 $lt_unset $lt_var
2633 fi"
2634 done
2635
2636 # Now prepare to actually exec the command.
2637 exec_cmd="\$cmd$args"
2638 else
2639 # Display what would be done.
2640 if test -n "$shlibpath_var"; then
2641 eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
2642 echo "export $shlibpath_var"
2643 fi
2644 $ECHO "$cmd$args"
2645 exit $EXIT_SUCCESS
2646 fi
2647 }
2648
2649 test "$opt_mode" = execute && func_mode_execute ${1+"$@"}
2650
2651
2652 # func_mode_finish arg...
2653 func_mode_finish ()
2654 {
2655 $opt_debug
2656 libs=
2657 libdirs=
2658 admincmds=
2659
2660 for opt in "$nonopt" ${1+"$@"}
2661 do
2662 if test -d "$opt"; then
2663 func_append libdirs " $opt"
2664
2665 elif test -f "$opt"; then
2666 if func_lalib_unsafe_p "$opt"; then
2667 func_append libs " $opt"
2668 else
2669 func_warning "\`$opt' is not a valid libtool archive"
2670 fi
2671
2672 else
2673 func_fatal_error "invalid argument \`$opt'"
2674 fi
2675 done
2676
2677 if test -n "$libs"; then
2678 if test -n "$lt_sysroot"; then
2679 sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"`
2680 sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;"
2681 else
2682 sysroot_cmd=
2683 fi
2684
2685 # Remove sysroot references
2686 if $opt_dry_run; then
2687 for lib in $libs; do
2688 echo "removing references to $lt_sysroot and \`=' prefixes from $lib"
2689 done
2690 else
2691 tmpdir=`func_mktempdir`
2692 for lib in $libs; do
2693 sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \
2694 > $tmpdir/tmp-la
2695 mv -f $tmpdir/tmp-la $lib
2696 done
2697 ${RM}r "$tmpdir"
2698 fi
2699 fi
2700
2701 if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
2702 for libdir in $libdirs; do
2703 if test -n "$finish_cmds"; then
2704 # Do each command in the finish commands.
2705 func_execute_cmds "$finish_cmds" 'admincmds="$admincmds
2706 '"$cmd"'"'
2707 fi
2708 if test -n "$finish_eval"; then
2709 # Do the single finish_eval.
2710 eval cmds=\"$finish_eval\"
2711 $opt_dry_run || eval "$cmds" || func_append admincmds "
2712 $cmds"
2713 fi
2714 done
2715 fi
2716
2717 # Exit here if they wanted silent mode.
2718 $opt_silent && exit $EXIT_SUCCESS
2719
2720 if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
2721 echo "----------------------------------------------------------------------"
2722 echo "Libraries have been installed in:"
2723 for libdir in $libdirs; do
2724 $ECHO " $libdir"
2725 done
2726 echo
2727 echo "If you ever happen to want to link against installed libraries"
2728 echo "in a given directory, LIBDIR, you must either use libtool, and"
2729 echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
2730 echo "flag during linking and do at least one of the following:"
2731 if test -n "$shlibpath_var"; then
2732 echo " - add LIBDIR to the \`$shlibpath_var' environment variable"
2733 echo " during execution"
2734 fi
2735 if test -n "$runpath_var"; then
2736 echo " - add LIBDIR to the \`$runpath_var' environment variable"
2737 echo " during linking"
2738 fi
2739 if test -n "$hardcode_libdir_flag_spec"; then
2740 libdir=LIBDIR
2741 eval flag=\"$hardcode_libdir_flag_spec\"
2742
2743 $ECHO " - use the \`$flag' linker flag"
2744 fi
2745 if test -n "$admincmds"; then
2746 $ECHO " - have your system administrator run these commands:$admincmds"
2747 fi
2748 if test -f /etc/ld.so.conf; then
2749 echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
2750 fi
2751 echo
2752
2753 echo "See any operating system documentation about shared libraries for"
2754 case $host in
2755 solaris2.[6789]|solaris2.1[0-9])
2756 echo "more information, such as the ld(1), crle(1) and ld.so(8) manual"
2757 echo "pages."
2758 ;;
2759 *)
2760 echo "more information, such as the ld(1) and ld.so(8) manual pages."
2761 ;;
2762 esac
2763 echo "----------------------------------------------------------------------"
2764 fi
2765 exit $EXIT_SUCCESS
2766 }
2767
2768 test "$opt_mode" = finish && func_mode_finish ${1+"$@"}
2769
2770
2771 # func_mode_install arg...
2772 func_mode_install ()
2773 {
2774 $opt_debug
2775 # There may be an optional sh(1) argument at the beginning of
2776 # install_prog (especially on Windows NT).
2777 if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh ||
2778 # Allow the use of GNU shtool's install command.
2779 case $nonopt in *shtool*) :;; *) false;; esac; then
2780 # Aesthetically quote it.
2781 func_quote_for_eval "$nonopt"
2782 install_prog="$func_quote_for_eval_result "
2783 arg=$1
2784 shift
2785 else
2786 install_prog=
2787 arg=$nonopt
2788 fi
2789
2790 # The real first argument should be the name of the installation program.
2791 # Aesthetically quote it.
2792 func_quote_for_eval "$arg"
2793 func_append install_prog "$func_quote_for_eval_result"
2794 install_shared_prog=$install_prog
2795 case " $install_prog " in
2796 *[\\\ /]cp\ *) install_cp=: ;;
2797 *) install_cp=false ;;
2798 esac
2799
2800 # We need to accept at least all the BSD install flags.
2801 dest=
2802 files=
2803 opts=
2804 prev=
2805 install_type=
2806 isdir=no
2807 stripme=
2808 no_mode=:
2809 for arg
2810 do
2811 arg2=
2812 if test -n "$dest"; then
2813 func_append files " $dest"
2814 dest=$arg
2815 continue
2816 fi
2817
2818 case $arg in
2819 -d) isdir=yes ;;
2820 -f)
2821 if $install_cp; then :; else
2822 prev=$arg
2823 fi
2824 ;;
2825 -g | -m | -o)
2826 prev=$arg
2827 ;;
2828 -s)
2829 stripme=" -s"
2830 continue
2831 ;;
2832 -*)
2833 ;;
2834 *)
2835 # If the previous option needed an argument, then skip it.
2836 if test -n "$prev"; then
2837 if test "x$prev" = x-m && test -n "$install_override_mode"; then
2838 arg2=$install_override_mode
2839 no_mode=false
2840 fi
2841 prev=
2842 else
2843 dest=$arg
2844 continue
2845 fi
2846 ;;
2847 esac
2848
2849 # Aesthetically quote the argument.
2850 func_quote_for_eval "$arg"
2851 func_append install_prog " $func_quote_for_eval_result"
2852 if test -n "$arg2"; then
2853 func_quote_for_eval "$arg2"
2854 fi
2855 func_append install_shared_prog " $func_quote_for_eval_result"
2856 done
2857
2858 test -z "$install_prog" && \
2859 func_fatal_help "you must specify an install program"
2860
2861 test -n "$prev" && \
2862 func_fatal_help "the \`$prev' option requires an argument"
2863
2864 if test -n "$install_override_mode" && $no_mode; then
2865 if $install_cp; then :; else
2866 func_quote_for_eval "$install_override_mode"
2867 func_append install_shared_prog " -m $func_quote_for_eval_result"
2868 fi
2869 fi
2870
2871 if test -z "$files"; then
2872 if test -z "$dest"; then
2873 func_fatal_help "no file or destination specified"
2874 else
2875 func_fatal_help "you must specify a destination"
2876 fi
2877 fi
2878
2879 # Strip any trailing slash from the destination.
2880 func_stripname '' '/' "$dest"
2881 dest=$func_stripname_result
2882
2883 # Check to see that the destination is a directory.
2884 test -d "$dest" && isdir=yes
2885 if test "$isdir" = yes; then
2886 destdir="$dest"
2887 destname=
2888 else
2889 func_dirname_and_basename "$dest" "" "."
2890 destdir="$func_dirname_result"
2891 destname="$func_basename_result"
2892
2893 # Not a directory, so check to see that there is only one file specified.
2894 set dummy $files; shift
2895 test "$#" -gt 1 && \
2896 func_fatal_help "\`$dest' is not a directory"
2897 fi
2898 case $destdir in
2899 [\\/]* | [A-Za-z]:[\\/]*) ;;
2900 *)
2901 for file in $files; do
2902 case $file in
2903 *.lo) ;;
2904 *)
2905 func_fatal_help "\`$destdir' must be an absolute directory name"
2906 ;;
2907 esac
2908 done
2909 ;;
2910 esac
2911
2912 # This variable tells wrapper scripts just to set variables rather
2913 # than running their programs.
2914 libtool_install_magic="$magic"
2915
2916 staticlibs=
2917 future_libdirs=
2918 current_libdirs=
2919 for file in $files; do
2920
2921 # Do each installation.
2922 case $file in
2923 *.$libext)
2924 # Do the static libraries later.
2925 func_append staticlibs " $file"
2926 ;;
2927
2928 *.la)
2929 func_resolve_sysroot "$file"
2930 file=$func_resolve_sysroot_result
2931
2932 # Check to see that this really is a libtool archive.
2933 func_lalib_unsafe_p "$file" \
2934 || func_fatal_help "\`$file' is not a valid libtool archive"
2935
2936 library_names=
2937 old_library=
2938 relink_command=
2939 func_source "$file"
2940
2941 # Add the libdir to current_libdirs if it is the destination.
2942 if test "X$destdir" = "X$libdir"; then
2943 case "$current_libdirs " in
2944 *" $libdir "*) ;;
2945 *) func_append current_libdirs " $libdir" ;;
2946 esac
2947 else
2948 # Note the libdir as a future libdir.
2949 case "$future_libdirs " in
2950 *" $libdir "*) ;;
2951 *) func_append future_libdirs " $libdir" ;;
2952 esac
2953 fi
2954
2955 func_dirname "$file" "/" ""
2956 dir="$func_dirname_result"
2957 func_append dir "$objdir"
2958
2959 if test -n "$relink_command"; then
2960 # Determine the prefix the user has applied to our future dir.
2961 inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"`
2962
2963 # Don't allow the user to place us outside of our expected
2964 # location b/c this prevents finding dependent libraries that
2965 # are installed to the same prefix.
2966 # At present, this check doesn't affect windows .dll's that
2967 # are installed into $libdir/../bin (currently, that works fine)
2968 # but it's something to keep an eye on.
2969 test "$inst_prefix_dir" = "$destdir" && \
2970 func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir"
2971
2972 if test -n "$inst_prefix_dir"; then
2973 # Stick the inst_prefix_dir data into the link command.
2974 relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
2975 else
2976 relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"`
2977 fi
2978
2979 func_warning "relinking \`$file'"
2980 func_show_eval "$relink_command" \
2981 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"'
2982 fi
2983
2984 # See the names of the shared library.
2985 set dummy $library_names; shift
2986 if test -n "$1"; then
2987 realname="$1"
2988 shift
2989
2990 srcname="$realname"
2991 test -n "$relink_command" && srcname="$realname"T
2992
2993 # Install the shared library and build the symlinks.
2994 func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
2995 'exit $?'
2996 tstripme="$stripme"
2997 case $host_os in
2998 cygwin* | mingw* | pw32* | cegcc*)
2999 case $realname in
3000 *.dll.a)
3001 tstripme=""
3002 ;;
3003 esac
3004 ;;
3005 esac
3006 if test -n "$tstripme" && test -n "$striplib"; then
3007 func_show_eval "$striplib $destdir/$realname" 'exit $?'
3008 fi
3009
3010 if test "$#" -gt 0; then
3011 # Delete the old symlinks, and create new ones.
3012 # Try `ln -sf' first, because the `ln' binary might depend on
3013 # the symlink we replace! Solaris /bin/ln does not understand -f,
3014 # so we also need to try rm && ln -s.
3015 for linkname
3016 do
3017 test "$linkname" != "$realname" \
3018 && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })"
3019 done
3020 fi
3021
3022 # Do each command in the postinstall commands.
3023 lib="$destdir/$realname"
3024 func_execute_cmds "$postinstall_cmds" 'exit $?'
3025 fi
3026
3027 # Install the pseudo-library for information purposes.
3028 func_basename "$file"
3029 name="$func_basename_result"
3030 instname="$dir/$name"i
3031 func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
3032
3033 # Maybe install the static library, too.
3034 test -n "$old_library" && func_append staticlibs " $dir/$old_library"
3035 ;;
3036
3037 *.lo)
3038 # Install (i.e. copy) a libtool object.
3039
3040 # Figure out destination file name, if it wasn't already specified.
3041 if test -n "$destname"; then
3042 destfile="$destdir/$destname"
3043 else
3044 func_basename "$file"
3045 destfile="$func_basename_result"
3046 destfile="$destdir/$destfile"
3047 fi
3048
3049 # Deduce the name of the destination old-style object file.
3050 case $destfile in
3051 *.lo)
3052 func_lo2o "$destfile"
3053 staticdest=$func_lo2o_result
3054 ;;
3055 *.$objext)
3056 staticdest="$destfile"
3057 destfile=
3058 ;;
3059 *)
3060 func_fatal_help "cannot copy a libtool object to \`$destfile'"
3061 ;;
3062 esac
3063
3064 # Install the libtool object if requested.
3065 test -n "$destfile" && \
3066 func_show_eval "$install_prog $file $destfile" 'exit $?'
3067
3068 # Install the old object if enabled.
3069 if test "$build_old_libs" = yes; then
3070 # Deduce the name of the old-style object file.
3071 func_lo2o "$file"
3072 staticobj=$func_lo2o_result
3073 func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?'
3074 fi
3075 exit $EXIT_SUCCESS
3076 ;;
3077
3078 *)
3079 # Figure out destination file name, if it wasn't already specified.
3080 if test -n "$destname"; then
3081 destfile="$destdir/$destname"
3082 else
3083 func_basename "$file"
3084 destfile="$func_basename_result"
3085 destfile="$destdir/$destfile"
3086 fi
3087
3088 # If the file is missing, and there is a .exe on the end, strip it
3089 # because it is most likely a libtool script we actually want to
3090 # install
3091 stripped_ext=""
3092 case $file in
3093 *.exe)
3094 if test ! -f "$file"; then
3095 func_stripname '' '.exe' "$file"
3096 file=$func_stripname_result
3097 stripped_ext=".exe"
3098 fi
3099 ;;
3100 esac
3101
3102 # Do a test to see if this is really a libtool program.
3103 case $host in
3104 *cygwin* | *mingw*)
3105 if func_ltwrapper_executable_p "$file"; then
3106 func_ltwrapper_scriptname "$file"
3107 wrapper=$func_ltwrapper_scriptname_result
3108 else
3109 func_stripname '' '.exe' "$file"
3110 wrapper=$func_stripname_result
3111 fi
3112 ;;
3113 *)
3114 wrapper=$file
3115 ;;
3116 esac
3117 if func_ltwrapper_script_p "$wrapper"; then
3118 notinst_deplibs=
3119 relink_command=
3120
3121 func_source "$wrapper"
3122
3123 # Check the variables that should have been set.
3124 test -z "$generated_by_libtool_version" && \
3125 func_fatal_error "invalid libtool wrapper script \`$wrapper'"
3126
3127 finalize=yes
3128 for lib in $notinst_deplibs; do
3129 # Check to see that each library is installed.
3130 libdir=
3131 if test -f "$lib"; then
3132 func_source "$lib"
3133 fi
3134 libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test
3135 if test -n "$libdir" && test ! -f "$libfile"; then
3136 func_warning "\`$lib' has not been installed in \`$libdir'"
3137 finalize=no
3138 fi
3139 done
3140
3141 relink_command=
3142 func_source "$wrapper"
3143
3144 outputname=
3145 if test "$fast_install" = no && test -n "$relink_command"; then
3146 $opt_dry_run || {
3147 if test "$finalize" = yes; then
3148 tmpdir=`func_mktempdir`
3149 func_basename "$file$stripped_ext"
3150 file="$func_basename_result"
3151 outputname="$tmpdir/$file"
3152 # Replace the output file specification.
3153 relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'`
3154
3155 $opt_silent || {
3156 func_quote_for_expand "$relink_command"
3157 eval "func_echo $func_quote_for_expand_result"
3158 }
3159 if eval "$relink_command"; then :
3160 else
3161 func_error "error: relink \`$file' with the above command before installing it"
3162 $opt_dry_run || ${RM}r "$tmpdir"
3163 continue
3164 fi
3165 file="$outputname"
3166 else
3167 func_warning "cannot relink \`$file'"
3168 fi
3169 }
3170 else
3171 # Install the binary that we compiled earlier.
3172 file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"`
3173 fi
3174 fi
3175
3176 # remove .exe since cygwin /usr/bin/install will append another
3177 # one anyway
3178 case $install_prog,$host in
3179 */usr/bin/install*,*cygwin*)
3180 case $file:$destfile in
3181 *.exe:*.exe)
3182 # this is ok
3183 ;;
3184 *.exe:*)
3185 destfile=$destfile.exe
3186 ;;
3187 *:*.exe)
3188 func_stripname '' '.exe' "$destfile"
3189 destfile=$func_stripname_result
3190 ;;
3191 esac
3192 ;;
3193 esac
3194 func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?'
3195 $opt_dry_run || if test -n "$outputname"; then
3196 ${RM}r "$tmpdir"
3197 fi
3198 ;;
3199 esac
3200 done
3201
3202 for file in $staticlibs; do
3203 func_basename "$file"
3204 name="$func_basename_result"
3205
3206 # Set up the ranlib parameters.
3207 oldlib="$destdir/$name"
3208 func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
3209 tool_oldlib=$func_to_tool_file_result
3210
3211 func_show_eval "$install_prog \$file \$oldlib" 'exit $?'
3212
3213 if test -n "$stripme" && test -n "$old_striplib"; then
3214 func_show_eval "$old_striplib $tool_oldlib" 'exit $?'
3215 fi
3216
3217 # Do each command in the postinstall commands.
3218 func_execute_cmds "$old_postinstall_cmds" 'exit $?'
3219 done
3220
3221 test -n "$future_libdirs" && \
3222 func_warning "remember to run \`$progname --finish$future_libdirs'"
3223
3224 if test -n "$current_libdirs"; then
3225 # Maybe just do a dry run.
3226 $opt_dry_run && current_libdirs=" -n$current_libdirs"
3227 exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs'
3228 else
3229 exit $EXIT_SUCCESS
3230 fi
3231 }
3232
3233 test "$opt_mode" = install && func_mode_install ${1+"$@"}
3234
3235
3236 # func_generate_dlsyms outputname originator pic_p
3237 # Extract symbols from dlprefiles and create ${outputname}S.o with
3238 # a dlpreopen symbol table.
3239 func_generate_dlsyms ()
3240 {
3241 $opt_debug
3242 my_outputname="$1"
3243 my_originator="$2"
3244 my_pic_p="${3-no}"
3245 my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'`
3246 my_dlsyms=
3247
3248 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
3249 if test -n "$NM" && test -n "$global_symbol_pipe"; then
3250 my_dlsyms="${my_outputname}S.c"
3251 else
3252 func_error "not configured to extract global symbols from dlpreopened files"
3253 fi
3254 fi
3255
3256 if test -n "$my_dlsyms"; then
3257 case $my_dlsyms in
3258 "") ;;
3259 *.c)
3260 # Discover the nlist of each of the dlfiles.
3261 nlist="$output_objdir/${my_outputname}.nm"
3262
3263 func_show_eval "$RM $nlist ${nlist}S ${nlist}T"
3264
3265 # Parse the name list into a source file.
3266 func_verbose "creating $output_objdir/$my_dlsyms"
3267
3268 $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\
3269 /* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */
3270 /* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */
3271
3272 #ifdef __cplusplus
3273 extern \"C\" {
3274 #endif
3275
3276 #if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4))
3277 #pragma GCC diagnostic ignored \"-Wstrict-prototypes\"
3278 #endif
3279
3280 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3281 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3282 /* DATA imports from DLLs on WIN32 con't be const, because runtime
3283 relocations are performed -- see ld's documentation on pseudo-relocs. */
3284 # define LT_DLSYM_CONST
3285 #elif defined(__osf__)
3286 /* This system does not cope well with relocations in const data. */
3287 # define LT_DLSYM_CONST
3288 #else
3289 # define LT_DLSYM_CONST const
3290 #endif
3291
3292 /* External symbol declarations for the compiler. */\
3293 "
3294
3295 if test "$dlself" = yes; then
3296 func_verbose "generating symbol list for \`$output'"
3297
3298 $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist"
3299
3300 # Add our own program objects to the symbol list.
3301 progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP`
3302 for progfile in $progfiles; do
3303 func_to_tool_file "$progfile" func_convert_file_msys_to_w32
3304 func_verbose "extracting global C symbols from \`$func_to_tool_file_result'"
3305 $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'"
3306 done
3307
3308 if test -n "$exclude_expsyms"; then
3309 $opt_dry_run || {
3310 eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
3311 eval '$MV "$nlist"T "$nlist"'
3312 }
3313 fi
3314
3315 if test -n "$export_symbols_regex"; then
3316 $opt_dry_run || {
3317 eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T'
3318 eval '$MV "$nlist"T "$nlist"'
3319 }
3320 fi
3321
3322 # Prepare the list of exported symbols
3323 if test -z "$export_symbols"; then
3324 export_symbols="$output_objdir/$outputname.exp"
3325 $opt_dry_run || {
3326 $RM $export_symbols
3327 eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
3328 case $host in
3329 *cygwin* | *mingw* | *cegcc* )
3330 eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
3331 eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"'
3332 ;;
3333 esac
3334 }
3335 else
3336 $opt_dry_run || {
3337 eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
3338 eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
3339 eval '$MV "$nlist"T "$nlist"'
3340 case $host in
3341 *cygwin* | *mingw* | *cegcc* )
3342 eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
3343 eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
3344 ;;
3345 esac
3346 }
3347 fi
3348 fi
3349
3350 for dlprefile in $dlprefiles; do
3351 func_verbose "extracting global C symbols from \`$dlprefile'"
3352 func_basename "$dlprefile"
3353 name="$func_basename_result"
3354 case $host in
3355 *cygwin* | *mingw* | *cegcc* )
3356 # if an import library, we need to obtain dlname
3357 if func_win32_import_lib_p "$dlprefile"; then
3358 func_tr_sh "$dlprefile"
3359 eval "curr_lafile=\$libfile_$func_tr_sh_result"
3360 dlprefile_dlbasename=""
3361 if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then
3362 # Use subshell, to avoid clobbering current variable values
3363 dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"`
3364 if test -n "$dlprefile_dlname" ; then
3365 func_basename "$dlprefile_dlname"
3366 dlprefile_dlbasename="$func_basename_result"
3367 else
3368 # no lafile. user explicitly requested -dlpreopen <import library>.
3369 $sharedlib_from_linklib_cmd "$dlprefile"
3370 dlprefile_dlbasename=$sharedlib_from_linklib_result
3371 fi
3372 fi
3373 $opt_dry_run || {
3374 if test -n "$dlprefile_dlbasename" ; then
3375 eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"'
3376 else
3377 func_warning "Could not compute DLL name from $name"
3378 eval '$ECHO ": $name " >> "$nlist"'
3379 fi
3380 func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3381 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe |
3382 $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'"
3383 }
3384 else # not an import lib
3385 $opt_dry_run || {
3386 eval '$ECHO ": $name " >> "$nlist"'
3387 func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3388 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3389 }
3390 fi
3391 ;;
3392 *)
3393 $opt_dry_run || {
3394 eval '$ECHO ": $name " >> "$nlist"'
3395 func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3396 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3397 }
3398 ;;
3399 esac
3400 done
3401
3402 $opt_dry_run || {
3403 # Make sure we have at least an empty file.
3404 test -f "$nlist" || : > "$nlist"
3405
3406 if test -n "$exclude_expsyms"; then
3407 $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T
3408 $MV "$nlist"T "$nlist"
3409 fi
3410
3411 # Try sorting and uniquifying the output.
3412 if $GREP -v "^: " < "$nlist" |
3413 if sort -k 3 </dev/null >/dev/null 2>&1; then
3414 sort -k 3
3415 else
3416 sort +2
3417 fi |
3418 uniq > "$nlist"S; then
3419 :
3420 else
3421 $GREP -v "^: " < "$nlist" > "$nlist"S
3422 fi
3423
3424 if test -f "$nlist"S; then
3425 eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"'
3426 else
3427 echo '/* NONE */' >> "$output_objdir/$my_dlsyms"
3428 fi
3429
3430 echo >> "$output_objdir/$my_dlsyms" "\
3431
3432 /* The mapping between symbol names and symbols. */
3433 typedef struct {
3434 const char *name;
3435 void *address;
3436 } lt_dlsymlist;
3437 extern LT_DLSYM_CONST lt_dlsymlist
3438 lt_${my_prefix}_LTX_preloaded_symbols[];
3439 LT_DLSYM_CONST lt_dlsymlist
3440 lt_${my_prefix}_LTX_preloaded_symbols[] =
3441 {\
3442 { \"$my_originator\", (void *) 0 },"
3443
3444 case $need_lib_prefix in
3445 no)
3446 eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms"
3447 ;;
3448 *)
3449 eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms"
3450 ;;
3451 esac
3452 echo >> "$output_objdir/$my_dlsyms" "\
3453 {0, (void *) 0}
3454 };
3455
3456 /* This works around a problem in FreeBSD linker */
3457 #ifdef FREEBSD_WORKAROUND
3458 static const void *lt_preloaded_setup() {
3459 return lt_${my_prefix}_LTX_preloaded_symbols;
3460 }
3461 #endif
3462
3463 #ifdef __cplusplus
3464 }
3465 #endif\
3466 "
3467 } # !$opt_dry_run
3468
3469 pic_flag_for_symtable=
3470 case "$compile_command " in
3471 *" -static "*) ;;
3472 *)
3473 case $host in
3474 # compiling the symbol table file with pic_flag works around
3475 # a FreeBSD bug that causes programs to crash when -lm is
3476 # linked before any other PIC object. But we must not use
3477 # pic_flag when linking with -static. The problem exists in
3478 # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1.
3479 *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*)
3480 pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;;
3481 *-*-hpux*)
3482 pic_flag_for_symtable=" $pic_flag" ;;
3483 *)
3484 if test "X$my_pic_p" != Xno; then
3485 pic_flag_for_symtable=" $pic_flag"
3486 fi
3487 ;;
3488 esac
3489 ;;
3490 esac
3491 symtab_cflags=
3492 for arg in $LTCFLAGS; do
3493 case $arg in
3494 -pie | -fpie | -fPIE) ;;
3495 *) func_append symtab_cflags " $arg" ;;
3496 esac
3497 done
3498
3499 # Now compile the dynamic symbol file.
3500 func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?'
3501
3502 # Clean up the generated files.
3503 func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"'
3504
3505 # Transform the symbol file into the correct name.
3506 symfileobj="$output_objdir/${my_outputname}S.$objext"
3507 case $host in
3508 *cygwin* | *mingw* | *cegcc* )
3509 if test -f "$output_objdir/$my_outputname.def"; then
3510 compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
3511 finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
3512 else
3513 compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3514 finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3515 fi
3516 ;;
3517 *)
3518 compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3519 finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3520 ;;
3521 esac
3522 ;;
3523 *)
3524 func_fatal_error "unknown suffix for \`$my_dlsyms'"
3525 ;;
3526 esac
3527 else
3528 # We keep going just in case the user didn't refer to
3529 # lt_preloaded_symbols. The linker will fail if global_symbol_pipe
3530 # really was required.
3531
3532 # Nullify the symbol file.
3533 compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"`
3534 finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"`
3535 fi
3536 }
3537
3538 # func_win32_libid arg
3539 # return the library type of file 'arg'
3540 #
3541 # Need a lot of goo to handle *both* DLLs and import libs
3542 # Has to be a shell function in order to 'eat' the argument
3543 # that is supplied when $file_magic_command is called.
3544 # Despite the name, also deal with 64 bit binaries.
3545 func_win32_libid ()
3546 {
3547 $opt_debug
3548 win32_libid_type="unknown"
3549 win32_fileres=`file -L $1 2>/dev/null`
3550 case $win32_fileres in
3551 *ar\ archive\ import\ library*) # definitely import
3552 win32_libid_type="x86 archive import"
3553 ;;
3554 *ar\ archive*) # could be an import, or static
3555 # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD.
3556 if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
3557 $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then
3558 func_to_tool_file "$1" func_convert_file_msys_to_w32
3559 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" |
3560 $SED -n -e '
3561 1,100{
3562 / I /{
3563 s,.*,import,
3564 p
3565 q
3566 }
3567 }'`
3568 case $win32_nmres in
3569 import*) win32_libid_type="x86 archive import";;
3570 *) win32_libid_type="x86 archive static";;
3571 esac
3572 fi
3573 ;;
3574 *DLL*)
3575 win32_libid_type="x86 DLL"
3576 ;;
3577 *executable*) # but shell scripts are "executable" too...
3578 case $win32_fileres in
3579 *MS\ Windows\ PE\ Intel*)
3580 win32_libid_type="x86 DLL"
3581 ;;
3582 esac
3583 ;;
3584 esac
3585 $ECHO "$win32_libid_type"
3586 }
3587
3588 # func_cygming_dll_for_implib ARG
3589 #
3590 # Platform-specific function to extract the
3591 # name of the DLL associated with the specified
3592 # import library ARG.
3593 # Invoked by eval'ing the libtool variable
3594 # $sharedlib_from_linklib_cmd
3595 # Result is available in the variable
3596 # $sharedlib_from_linklib_result
3597 func_cygming_dll_for_implib ()
3598 {
3599 $opt_debug
3600 sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"`
3601 }
3602
3603 # func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs
3604 #
3605 # The is the core of a fallback implementation of a
3606 # platform-specific function to extract the name of the
3607 # DLL associated with the specified import library LIBNAME.
3608 #
3609 # SECTION_NAME is either .idata$6 or .idata$7, depending
3610 # on the platform and compiler that created the implib.
3611 #
3612 # Echos the name of the DLL associated with the
3613 # specified import library.
3614 func_cygming_dll_for_implib_fallback_core ()
3615 {
3616 $opt_debug
3617 match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"`
3618 $OBJDUMP -s --section "$1" "$2" 2>/dev/null |
3619 $SED '/^Contents of section '"$match_literal"':/{
3620 # Place marker at beginning of archive member dllname section
3621 s/.*/====MARK====/
3622 p
3623 d
3624 }
3625 # These lines can sometimes be longer than 43 characters, but
3626 # are always uninteresting
3627 /:[ ]*file format pe[i]\{,1\}-/d
3628 /^In archive [^:]*:/d
3629 # Ensure marker is printed
3630 /^====MARK====/p
3631 # Remove all lines with less than 43 characters
3632 /^.\{43\}/!d
3633 # From remaining lines, remove first 43 characters
3634 s/^.\{43\}//' |
3635 $SED -n '
3636 # Join marker and all lines until next marker into a single line
3637 /^====MARK====/ b para
3638 H
3639 $ b para
3640 b
3641 :para
3642 x
3643 s/\n//g
3644 # Remove the marker
3645 s/^====MARK====//
3646 # Remove trailing dots and whitespace
3647 s/[\. \t]*$//
3648 # Print
3649 /./p' |
3650 # we now have a list, one entry per line, of the stringified
3651 # contents of the appropriate section of all members of the
3652 # archive which possess that section. Heuristic: eliminate
3653 # all those which have a first or second character that is
3654 # a '.' (that is, objdump's representation of an unprintable
3655 # character.) This should work for all archives with less than
3656 # 0x302f exports -- but will fail for DLLs whose name actually
3657 # begins with a literal '.' or a single character followed by
3658 # a '.'.
3659 #
3660 # Of those that remain, print the first one.
3661 $SED -e '/^\./d;/^.\./d;q'
3662 }
3663
3664 # func_cygming_gnu_implib_p ARG
3665 # This predicate returns with zero status (TRUE) if
3666 # ARG is a GNU/binutils-style import library. Returns
3667 # with nonzero status (FALSE) otherwise.
3668 func_cygming_gnu_implib_p ()
3669 {
3670 $opt_debug
3671 func_to_tool_file "$1" func_convert_file_msys_to_w32
3672 func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'`
3673 test -n "$func_cygming_gnu_implib_tmp"
3674 }
3675
3676 # func_cygming_ms_implib_p ARG
3677 # This predicate returns with zero status (TRUE) if
3678 # ARG is an MS-style import library. Returns
3679 # with nonzero status (FALSE) otherwise.
3680 func_cygming_ms_implib_p ()
3681 {
3682 $opt_debug
3683 func_to_tool_file "$1" func_convert_file_msys_to_w32
3684 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'`
3685 test -n "$func_cygming_ms_implib_tmp"
3686 }
3687
3688 # func_cygming_dll_for_implib_fallback ARG
3689 # Platform-specific function to extract the
3690 # name of the DLL associated with the specified
3691 # import library ARG.
3692 #
3693 # This fallback implementation is for use when $DLLTOOL
3694 # does not support the --identify-strict option.
3695 # Invoked by eval'ing the libtool variable
3696 # $sharedlib_from_linklib_cmd
3697 # Result is available in the variable
3698 # $sharedlib_from_linklib_result
3699 func_cygming_dll_for_implib_fallback ()
3700 {
3701 $opt_debug
3702 if func_cygming_gnu_implib_p "$1" ; then
3703 # binutils import library
3704 sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"`
3705 elif func_cygming_ms_implib_p "$1" ; then
3706 # ms-generated import library
3707 sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"`
3708 else
3709 # unknown
3710 sharedlib_from_linklib_result=""
3711 fi
3712 }
3713
3714
3715 # func_extract_an_archive dir oldlib
3716 func_extract_an_archive ()
3717 {
3718 $opt_debug
3719 f_ex_an_ar_dir="$1"; shift
3720 f_ex_an_ar_oldlib="$1"
3721 if test "$lock_old_archive_extraction" = yes; then
3722 lockfile=$f_ex_an_ar_oldlib.lock
3723 until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
3724 func_echo "Waiting for $lockfile to be removed"
3725 sleep 2
3726 done
3727 fi
3728 func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \
3729 'stat=$?; rm -f "$lockfile"; exit $stat'
3730 if test "$lock_old_archive_extraction" = yes; then
3731 $opt_dry_run || rm -f "$lockfile"
3732 fi
3733 if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then
3734 :
3735 else
3736 func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib"
3737 fi
3738 }
3739
3740
3741 # func_extract_archives gentop oldlib ...
3742 func_extract_archives ()
3743 {
3744 $opt_debug
3745 my_gentop="$1"; shift
3746 my_oldlibs=${1+"$@"}
3747 my_oldobjs=""
3748 my_xlib=""
3749 my_xabs=""
3750 my_xdir=""
3751
3752 for my_xlib in $my_oldlibs; do
3753 # Extract the objects.
3754 case $my_xlib in
3755 [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;;
3756 *) my_xabs=`pwd`"/$my_xlib" ;;
3757 esac
3758 func_basename "$my_xlib"
3759 my_xlib="$func_basename_result"
3760 my_xlib_u=$my_xlib
3761 while :; do
3762 case " $extracted_archives " in
3763 *" $my_xlib_u "*)
3764 func_arith $extracted_serial + 1
3765 extracted_serial=$func_arith_result
3766 my_xlib_u=lt$extracted_serial-$my_xlib ;;
3767 *) break ;;
3768 esac
3769 done
3770 extracted_archives="$extracted_archives $my_xlib_u"
3771 my_xdir="$my_gentop/$my_xlib_u"
3772
3773 func_mkdir_p "$my_xdir"
3774
3775 case $host in
3776 *-darwin*)
3777 func_verbose "Extracting $my_xabs"
3778 # Do not bother doing anything if just a dry run
3779 $opt_dry_run || {
3780 darwin_orig_dir=`pwd`
3781 cd $my_xdir || exit $?
3782 darwin_archive=$my_xabs
3783 darwin_curdir=`pwd`
3784 darwin_base_archive=`basename "$darwin_archive"`
3785 darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true`
3786 if test -n "$darwin_arches"; then
3787 darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'`
3788 darwin_arch=
3789 func_verbose "$darwin_base_archive has multiple architectures $darwin_arches"
3790 for darwin_arch in $darwin_arches ; do
3791 func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}"
3792 $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}"
3793 cd "unfat-$$/${darwin_base_archive}-${darwin_arch}"
3794 func_extract_an_archive "`pwd`" "${darwin_base_archive}"
3795 cd "$darwin_curdir"
3796 $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}"
3797 done # $darwin_arches
3798 ## Okay now we've a bunch of thin objects, gotta fatten them up :)
3799 darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u`
3800 darwin_file=
3801 darwin_files=
3802 for darwin_file in $darwin_filelist; do
3803 darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP`
3804 $LIPO -create -output "$darwin_file" $darwin_files
3805 done # $darwin_filelist
3806 $RM -rf unfat-$$
3807 cd "$darwin_orig_dir"
3808 else
3809 cd $darwin_orig_dir
3810 func_extract_an_archive "$my_xdir" "$my_xabs"
3811 fi # $darwin_arches
3812 } # !$opt_dry_run
3813 ;;
3814 *)
3815 func_extract_an_archive "$my_xdir" "$my_xabs"
3816 ;;
3817 esac
3818 my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP`
3819 done
3820
3821 func_extract_archives_result="$my_oldobjs"
3822 }
3823
3824
3825 # func_emit_wrapper [arg=no]
3826 #
3827 # Emit a libtool wrapper script on stdout.
3828 # Don't directly open a file because we may want to
3829 # incorporate the script contents within a cygwin/mingw
3830 # wrapper executable. Must ONLY be called from within
3831 # func_mode_link because it depends on a number of variables
3832 # set therein.
3833 #
3834 # ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR
3835 # variable will take. If 'yes', then the emitted script
3836 # will assume that the directory in which it is stored is
3837 # the $objdir directory. This is a cygwin/mingw-specific
3838 # behavior.
3839 func_emit_wrapper ()
3840 {
3841 func_emit_wrapper_arg1=${1-no}
3842
3843 $ECHO "\
3844 #! $SHELL
3845
3846 # $output - temporary wrapper script for $objdir/$outputname
3847 # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
3848 #
3849 # The $output program cannot be directly executed until all the libtool
3850 # libraries that it depends on are installed.
3851 #
3852 # This wrapper script should never be moved out of the build directory.
3853 # If it is, it will not operate correctly.
3854
3855 # Sed substitution that helps us do robust quoting. It backslashifies
3856 # metacharacters that are still active within double-quoted strings.
3857 sed_quote_subst='$sed_quote_subst'
3858
3859 # Be Bourne compatible
3860 if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then
3861 emulate sh
3862 NULLCMD=:
3863 # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which
3864 # is contrary to our usage. Disable this feature.
3865 alias -g '\${1+\"\$@\"}'='\"\$@\"'
3866 setopt NO_GLOB_SUBST
3867 else
3868 case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac
3869 fi
3870 BIN_SH=xpg4; export BIN_SH # for Tru64
3871 DUALCASE=1; export DUALCASE # for MKS sh
3872
3873 # The HP-UX ksh and POSIX shell print the target directory to stdout
3874 # if CDPATH is set.
3875 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
3876
3877 relink_command=\"$relink_command\"
3878
3879 # This environment variable determines our operation mode.
3880 if test \"\$libtool_install_magic\" = \"$magic\"; then
3881 # install mode needs the following variables:
3882 generated_by_libtool_version='$macro_version'
3883 notinst_deplibs='$notinst_deplibs'
3884 else
3885 # When we are sourced in execute mode, \$file and \$ECHO are already set.
3886 if test \"\$libtool_execute_magic\" != \"$magic\"; then
3887 file=\"\$0\""
3888
3889 qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"`
3890 $ECHO "\
3891
3892 # A function that is used when there is no print builtin or printf.
3893 func_fallback_echo ()
3894 {
3895 eval 'cat <<_LTECHO_EOF
3896 \$1
3897 _LTECHO_EOF'
3898 }
3899 ECHO=\"$qECHO\"
3900 fi
3901
3902 # Very basic option parsing. These options are (a) specific to
3903 # the libtool wrapper, (b) are identical between the wrapper
3904 # /script/ and the wrapper /executable/ which is used only on
3905 # windows platforms, and (c) all begin with the string "--lt-"
3906 # (application programs are unlikely to have options which match
3907 # this pattern).
3908 #
3909 # There are only two supported options: --lt-debug and
3910 # --lt-dump-script. There is, deliberately, no --lt-help.
3911 #
3912 # The first argument to this parsing function should be the
3913 # script's $0 value, followed by "$@".
3914 lt_option_debug=
3915 func_parse_lt_options ()
3916 {
3917 lt_script_arg0=\$0
3918 shift
3919 for lt_opt
3920 do
3921 case \"\$lt_opt\" in
3922 --lt-debug) lt_option_debug=1 ;;
3923 --lt-dump-script)
3924 lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\`
3925 test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=.
3926 lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\`
3927 cat \"\$lt_dump_D/\$lt_dump_F\"
3928 exit 0
3929 ;;
3930 --lt-*)
3931 \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2
3932 exit 1
3933 ;;
3934 esac
3935 done
3936
3937 # Print the debug banner immediately:
3938 if test -n \"\$lt_option_debug\"; then
3939 echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2
3940 fi
3941 }
3942
3943 # Used when --lt-debug. Prints its arguments to stdout
3944 # (redirection is the responsibility of the caller)
3945 func_lt_dump_args ()
3946 {
3947 lt_dump_args_N=1;
3948 for lt_arg
3949 do
3950 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\"
3951 lt_dump_args_N=\`expr \$lt_dump_args_N + 1\`
3952 done
3953 }
3954
3955 # Core function for launching the target application
3956 func_exec_program_core ()
3957 {
3958 "
3959 case $host in
3960 # Backslashes separate directories on plain windows
3961 *-*-mingw | *-*-os2* | *-cegcc*)
3962 $ECHO "\
3963 if test -n \"\$lt_option_debug\"; then
3964 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2
3965 func_lt_dump_args \${1+\"\$@\"} 1>&2
3966 fi
3967 exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
3968 "
3969 ;;
3970
3971 *)
3972 $ECHO "\
3973 if test -n \"\$lt_option_debug\"; then
3974 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2
3975 func_lt_dump_args \${1+\"\$@\"} 1>&2
3976 fi
3977 exec \"\$progdir/\$program\" \${1+\"\$@\"}
3978 "
3979 ;;
3980 esac
3981 $ECHO "\
3982 \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
3983 exit 1
3984 }
3985
3986 # A function to encapsulate launching the target application
3987 # Strips options in the --lt-* namespace from \$@ and
3988 # launches target application with the remaining arguments.
3989 func_exec_program ()
3990 {
3991 case \" \$* \" in
3992 *\\ --lt-*)
3993 for lt_wr_arg
3994 do
3995 case \$lt_wr_arg in
3996 --lt-*) ;;
3997 *) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
3998 esac
3999 shift
4000 done ;;
4001 esac
4002 func_exec_program_core \${1+\"\$@\"}
4003 }
4004
4005 # Parse options
4006 func_parse_lt_options \"\$0\" \${1+\"\$@\"}
4007
4008 # Find the directory that this script lives in.
4009 thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\`
4010 test \"x\$thisdir\" = \"x\$file\" && thisdir=.
4011
4012 # Follow symbolic links until we get to the real thisdir.
4013 file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\`
4014 while test -n \"\$file\"; do
4015 destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\`
4016
4017 # If there was a directory component, then change thisdir.
4018 if test \"x\$destdir\" != \"x\$file\"; then
4019 case \"\$destdir\" in
4020 [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;;
4021 *) thisdir=\"\$thisdir/\$destdir\" ;;
4022 esac
4023 fi
4024
4025 file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\`
4026 file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\`
4027 done
4028
4029 # Usually 'no', except on cygwin/mingw when embedded into
4030 # the cwrapper.
4031 WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1
4032 if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then
4033 # special case for '.'
4034 if test \"\$thisdir\" = \".\"; then
4035 thisdir=\`pwd\`
4036 fi
4037 # remove .libs from thisdir
4038 case \"\$thisdir\" in
4039 *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;;
4040 $objdir ) thisdir=. ;;
4041 esac
4042 fi
4043
4044 # Try to get the absolute directory name.
4045 absdir=\`cd \"\$thisdir\" && pwd\`
4046 test -n \"\$absdir\" && thisdir=\"\$absdir\"
4047 "
4048
4049 if test "$fast_install" = yes; then
4050 $ECHO "\
4051 program=lt-'$outputname'$exeext
4052 progdir=\"\$thisdir/$objdir\"
4053
4054 if test ! -f \"\$progdir/\$program\" ||
4055 { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\
4056 test \"X\$file\" != \"X\$progdir/\$program\"; }; then
4057
4058 file=\"\$\$-\$program\"
4059
4060 if test ! -d \"\$progdir\"; then
4061 $MKDIR \"\$progdir\"
4062 else
4063 $RM \"\$progdir/\$file\"
4064 fi"
4065
4066 $ECHO "\
4067
4068 # relink executable if necessary
4069 if test -n \"\$relink_command\"; then
4070 if relink_command_output=\`eval \$relink_command 2>&1\`; then :
4071 else
4072 $ECHO \"\$relink_command_output\" >&2
4073 $RM \"\$progdir/\$file\"
4074 exit 1
4075 fi
4076 fi
4077
4078 $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null ||
4079 { $RM \"\$progdir/\$program\";
4080 $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; }
4081 $RM \"\$progdir/\$file\"
4082 fi"
4083 else
4084 $ECHO "\
4085 program='$outputname'
4086 progdir=\"\$thisdir/$objdir\"
4087 "
4088 fi
4089
4090 $ECHO "\
4091
4092 if test -f \"\$progdir/\$program\"; then"
4093
4094 # fixup the dll searchpath if we need to.
4095 #
4096 # Fix the DLL searchpath if we need to. Do this before prepending
4097 # to shlibpath, because on Windows, both are PATH and uninstalled
4098 # libraries must come first.
4099 if test -n "$dllsearchpath"; then
4100 $ECHO "\
4101 # Add the dll search path components to the executable PATH
4102 PATH=$dllsearchpath:\$PATH
4103 "
4104 fi
4105
4106 # Export our shlibpath_var if we have one.
4107 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
4108 $ECHO "\
4109 # Add our own library path to $shlibpath_var
4110 $shlibpath_var=\"$temp_rpath\$$shlibpath_var\"
4111
4112 # Some systems cannot cope with colon-terminated $shlibpath_var
4113 # The second colon is a workaround for a bug in BeOS R4 sed
4114 $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\`
4115
4116 export $shlibpath_var
4117 "
4118 fi
4119
4120 $ECHO "\
4121 if test \"\$libtool_execute_magic\" != \"$magic\"; then
4122 # Run the actual program with our arguments.
4123 func_exec_program \${1+\"\$@\"}
4124 fi
4125 else
4126 # The program doesn't exist.
4127 \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2
4128 \$ECHO \"This script is just a wrapper for \$program.\" 1>&2
4129 \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
4130 exit 1
4131 fi
4132 fi\
4133 "
4134 }
4135
4136
4137 # func_emit_cwrapperexe_src
4138 # emit the source code for a wrapper executable on stdout
4139 # Must ONLY be called from within func_mode_link because
4140 # it depends on a number of variable set therein.
4141 func_emit_cwrapperexe_src ()
4142 {
4143 cat <<EOF
4144
4145 /* $cwrappersource - temporary wrapper executable for $objdir/$outputname
4146 Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
4147
4148 The $output program cannot be directly executed until all the libtool
4149 libraries that it depends on are installed.
4150
4151 This wrapper executable should never be moved out of the build directory.
4152 If it is, it will not operate correctly.
4153 */
4154 EOF
4155 cat <<"EOF"
4156 #ifdef _MSC_VER
4157 # define _CRT_SECURE_NO_DEPRECATE 1
4158 #endif
4159 #include <stdio.h>
4160 #include <stdlib.h>
4161 #ifdef _MSC_VER
4162 # include <direct.h>
4163 # include <process.h>
4164 # include <io.h>
4165 #else
4166 # include <unistd.h>
4167 # include <stdint.h>
4168 # ifdef __CYGWIN__
4169 # include <io.h>
4170 # endif
4171 #endif
4172 #include <malloc.h>
4173 #include <stdarg.h>
4174 #include <assert.h>
4175 #include <string.h>
4176 #include <ctype.h>
4177 #include <errno.h>
4178 #include <fcntl.h>
4179 #include <sys/stat.h>
4180
4181 /* declarations of non-ANSI functions */
4182 #if defined(__MINGW32__)
4183 # ifdef __STRICT_ANSI__
4184 int _putenv (const char *);
4185 # endif
4186 #elif defined(__CYGWIN__)
4187 # ifdef __STRICT_ANSI__
4188 char *realpath (const char *, char *);
4189 int putenv (char *);
4190 int setenv (const char *, const char *, int);
4191 # endif
4192 /* #elif defined (other platforms) ... */
4193 #endif
4194
4195 /* portability defines, excluding path handling macros */
4196 #if defined(_MSC_VER)
4197 # define setmode _setmode
4198 # define stat _stat
4199 # define chmod _chmod
4200 # define getcwd _getcwd
4201 # define putenv _putenv
4202 # define S_IXUSR _S_IEXEC
4203 # ifndef _INTPTR_T_DEFINED
4204 # define _INTPTR_T_DEFINED
4205 # define intptr_t int
4206 # endif
4207 #elif defined(__MINGW32__)
4208 # define setmode _setmode
4209 # define stat _stat
4210 # define chmod _chmod
4211 # define getcwd _getcwd
4212 # define putenv _putenv
4213 #elif defined(__CYGWIN__)
4214 # define HAVE_SETENV
4215 # define FOPEN_WB "wb"
4216 /* #elif defined (other platforms) ... */
4217 #endif
4218
4219 #if defined(PATH_MAX)
4220 # define LT_PATHMAX PATH_MAX
4221 #elif defined(MAXPATHLEN)
4222 # define LT_PATHMAX MAXPATHLEN
4223 #else
4224 # define LT_PATHMAX 1024
4225 #endif
4226
4227 #ifndef S_IXOTH
4228 # define S_IXOTH 0
4229 #endif
4230 #ifndef S_IXGRP
4231 # define S_IXGRP 0
4232 #endif
4233
4234 /* path handling portability macros */
4235 #ifndef DIR_SEPARATOR
4236 # define DIR_SEPARATOR '/'
4237 # define PATH_SEPARATOR ':'
4238 #endif
4239
4240 #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \
4241 defined (__OS2__)
4242 # define HAVE_DOS_BASED_FILE_SYSTEM
4243 # define FOPEN_WB "wb"
4244 # ifndef DIR_SEPARATOR_2
4245 # define DIR_SEPARATOR_2 '\\'
4246 # endif
4247 # ifndef PATH_SEPARATOR_2
4248 # define PATH_SEPARATOR_2 ';'
4249 # endif
4250 #endif
4251
4252 #ifndef DIR_SEPARATOR_2
4253 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR)
4254 #else /* DIR_SEPARATOR_2 */
4255 # define IS_DIR_SEPARATOR(ch) \
4256 (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
4257 #endif /* DIR_SEPARATOR_2 */
4258
4259 #ifndef PATH_SEPARATOR_2
4260 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR)
4261 #else /* PATH_SEPARATOR_2 */
4262 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2)
4263 #endif /* PATH_SEPARATOR_2 */
4264
4265 #ifndef FOPEN_WB
4266 # define FOPEN_WB "w"
4267 #endif
4268 #ifndef _O_BINARY
4269 # define _O_BINARY 0
4270 #endif
4271
4272 #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type)))
4273 #define XFREE(stale) do { \
4274 if (stale) { free ((void *) stale); stale = 0; } \
4275 } while (0)
4276
4277 #if defined(LT_DEBUGWRAPPER)
4278 static int lt_debug = 1;
4279 #else
4280 static int lt_debug = 0;
4281 #endif
4282
4283 const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */
4284
4285 void *xmalloc (size_t num);
4286 char *xstrdup (const char *string);
4287 const char *base_name (const char *name);
4288 char *find_executable (const char *wrapper);
4289 char *chase_symlinks (const char *pathspec);
4290 int make_executable (const char *path);
4291 int check_executable (const char *path);
4292 char *strendzap (char *str, const char *pat);
4293 void lt_debugprintf (const char *file, int line, const char *fmt, ...);
4294 void lt_fatal (const char *file, int line, const char *message, ...);
4295 static const char *nonnull (const char *s);
4296 static const char *nonempty (const char *s);
4297 void lt_setenv (const char *name, const char *value);
4298 char *lt_extend_str (const char *orig_value, const char *add, int to_end);
4299 void lt_update_exe_path (const char *name, const char *value);
4300 void lt_update_lib_path (const char *name, const char *value);
4301 char **prepare_spawn (char **argv);
4302 void lt_dump_script (FILE *f);
4303 EOF
4304
4305 cat <<EOF
4306 volatile const char * MAGIC_EXE = "$magic_exe";
4307 const char * LIB_PATH_VARNAME = "$shlibpath_var";
4308 EOF
4309
4310 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
4311 func_to_host_path "$temp_rpath"
4312 cat <<EOF
4313 const char * LIB_PATH_VALUE = "$func_to_host_path_result";
4314 EOF
4315 else
4316 cat <<"EOF"
4317 const char * LIB_PATH_VALUE = "";
4318 EOF
4319 fi
4320
4321 if test -n "$dllsearchpath"; then
4322 func_to_host_path "$dllsearchpath:"
4323 cat <<EOF
4324 const char * EXE_PATH_VARNAME = "PATH";
4325 const char * EXE_PATH_VALUE = "$func_to_host_path_result";
4326 EOF
4327 else
4328 cat <<"EOF"
4329 const char * EXE_PATH_VARNAME = "";
4330 const char * EXE_PATH_VALUE = "";
4331 EOF
4332 fi
4333
4334 if test "$fast_install" = yes; then
4335 cat <<EOF
4336 const char * TARGET_PROGRAM_NAME = "lt-$outputname"; /* hopefully, no .exe */
4337 EOF
4338 else
4339 cat <<EOF
4340 const char * TARGET_PROGRAM_NAME = "$outputname"; /* hopefully, no .exe */
4341 EOF
4342 fi
4343
4344
4345 cat <<"EOF"
4346
4347 #define LTWRAPPER_OPTION_PREFIX "--lt-"
4348
4349 static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX;
4350 static const char *dumpscript_opt = LTWRAPPER_OPTION_PREFIX "dump-script";
4351 static const char *debug_opt = LTWRAPPER_OPTION_PREFIX "debug";
4352
4353 int
4354 main (int argc, char *argv[])
4355 {
4356 char **newargz;
4357 int newargc;
4358 char *tmp_pathspec;
4359 char *actual_cwrapper_path;
4360 char *actual_cwrapper_name;
4361 char *target_name;
4362 char *lt_argv_zero;
4363 intptr_t rval = 127;
4364
4365 int i;
4366
4367 program_name = (char *) xstrdup (base_name (argv[0]));
4368 newargz = XMALLOC (char *, argc + 1);
4369
4370 /* very simple arg parsing; don't want to rely on getopt
4371 * also, copy all non cwrapper options to newargz, except
4372 * argz[0], which is handled differently
4373 */
4374 newargc=0;
4375 for (i = 1; i < argc; i++)
4376 {
4377 if (strcmp (argv[i], dumpscript_opt) == 0)
4378 {
4379 EOF
4380 case "$host" in
4381 *mingw* | *cygwin* )
4382 # make stdout use "unix" line endings
4383 echo " setmode(1,_O_BINARY);"
4384 ;;
4385 esac
4386
4387 cat <<"EOF"
4388 lt_dump_script (stdout);
4389 return 0;
4390 }
4391 if (strcmp (argv[i], debug_opt) == 0)
4392 {
4393 lt_debug = 1;
4394 continue;
4395 }
4396 if (strcmp (argv[i], ltwrapper_option_prefix) == 0)
4397 {
4398 /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
4399 namespace, but it is not one of the ones we know about and
4400 have already dealt with, above (inluding dump-script), then
4401 report an error. Otherwise, targets might begin to believe
4402 they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
4403 namespace. The first time any user complains about this, we'll
4404 need to make LTWRAPPER_OPTION_PREFIX a configure-time option
4405 or a configure.ac-settable value.
4406 */
4407 lt_fatal (__FILE__, __LINE__,
4408 "unrecognized %s option: '%s'",
4409 ltwrapper_option_prefix, argv[i]);
4410 }
4411 /* otherwise ... */
4412 newargz[++newargc] = xstrdup (argv[i]);
4413 }
4414 newargz[++newargc] = NULL;
4415
4416 EOF
4417 cat <<EOF
4418 /* The GNU banner must be the first non-error debug message */
4419 lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n");
4420 EOF
4421 cat <<"EOF"
4422 lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]);
4423 lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name);
4424
4425 tmp_pathspec = find_executable (argv[0]);
4426 if (tmp_pathspec == NULL)
4427 lt_fatal (__FILE__, __LINE__, "couldn't find %s", argv[0]);
4428 lt_debugprintf (__FILE__, __LINE__,
4429 "(main) found exe (before symlink chase) at: %s\n",
4430 tmp_pathspec);
4431
4432 actual_cwrapper_path = chase_symlinks (tmp_pathspec);
4433 lt_debugprintf (__FILE__, __LINE__,
4434 "(main) found exe (after symlink chase) at: %s\n",
4435 actual_cwrapper_path);
4436 XFREE (tmp_pathspec);
4437
4438 actual_cwrapper_name = xstrdup (base_name (actual_cwrapper_path));
4439 strendzap (actual_cwrapper_path, actual_cwrapper_name);
4440
4441 /* wrapper name transforms */
4442 strendzap (actual_cwrapper_name, ".exe");
4443 tmp_pathspec = lt_extend_str (actual_cwrapper_name, ".exe", 1);
4444 XFREE (actual_cwrapper_name);
4445 actual_cwrapper_name = tmp_pathspec;
4446 tmp_pathspec = 0;
4447
4448 /* target_name transforms -- use actual target program name; might have lt- prefix */
4449 target_name = xstrdup (base_name (TARGET_PROGRAM_NAME));
4450 strendzap (target_name, ".exe");
4451 tmp_pathspec = lt_extend_str (target_name, ".exe", 1);
4452 XFREE (target_name);
4453 target_name = tmp_pathspec;
4454 tmp_pathspec = 0;
4455
4456 lt_debugprintf (__FILE__, __LINE__,
4457 "(main) libtool target name: %s\n",
4458 target_name);
4459 EOF
4460
4461 cat <<EOF
4462 newargz[0] =
4463 XMALLOC (char, (strlen (actual_cwrapper_path) +
4464 strlen ("$objdir") + 1 + strlen (actual_cwrapper_name) + 1));
4465 strcpy (newargz[0], actual_cwrapper_path);
4466 strcat (newargz[0], "$objdir");
4467 strcat (newargz[0], "/");
4468 EOF
4469
4470 cat <<"EOF"
4471 /* stop here, and copy so we don't have to do this twice */
4472 tmp_pathspec = xstrdup (newargz[0]);
4473
4474 /* do NOT want the lt- prefix here, so use actual_cwrapper_name */
4475 strcat (newargz[0], actual_cwrapper_name);
4476
4477 /* DO want the lt- prefix here if it exists, so use target_name */
4478 lt_argv_zero = lt_extend_str (tmp_pathspec, target_name, 1);
4479 XFREE (tmp_pathspec);
4480 tmp_pathspec = NULL;
4481 EOF
4482
4483 case $host_os in
4484 mingw*)
4485 cat <<"EOF"
4486 {
4487 char* p;
4488 while ((p = strchr (newargz[0], '\\')) != NULL)
4489 {
4490 *p = '/';
4491 }
4492 while ((p = strchr (lt_argv_zero, '\\')) != NULL)
4493 {
4494 *p = '/';
4495 }
4496 }
4497 EOF
4498 ;;
4499 esac
4500
4501 cat <<"EOF"
4502 XFREE (target_name);
4503 XFREE (actual_cwrapper_path);
4504 XFREE (actual_cwrapper_name);
4505
4506 lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */
4507 lt_setenv ("DUALCASE", "1"); /* for MSK sh */
4508 /* Update the DLL searchpath. EXE_PATH_VALUE ($dllsearchpath) must
4509 be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath)
4510 because on Windows, both *_VARNAMEs are PATH but uninstalled
4511 libraries must come first. */
4512 lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE);
4513 lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
4514
4515 lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n",
4516 nonnull (lt_argv_zero));
4517 for (i = 0; i < newargc; i++)
4518 {
4519 lt_debugprintf (__FILE__, __LINE__, "(main) newargz[%d]: %s\n",
4520 i, nonnull (newargz[i]));
4521 }
4522
4523 EOF
4524
4525 case $host_os in
4526 mingw*)
4527 cat <<"EOF"
4528 /* execv doesn't actually work on mingw as expected on unix */
4529 newargz = prepare_spawn (newargz);
4530 rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz);
4531 if (rval == -1)
4532 {
4533 /* failed to start process */
4534 lt_debugprintf (__FILE__, __LINE__,
4535 "(main) failed to launch target \"%s\": %s\n",
4536 lt_argv_zero, nonnull (strerror (errno)));
4537 return 127;
4538 }
4539 return rval;
4540 EOF
4541 ;;
4542 *)
4543 cat <<"EOF"
4544 execv (lt_argv_zero, newargz);
4545 return rval; /* =127, but avoids unused variable warning */
4546 EOF
4547 ;;
4548 esac
4549
4550 cat <<"EOF"
4551 }
4552
4553 void *
4554 xmalloc (size_t num)
4555 {
4556 void *p = (void *) malloc (num);
4557 if (!p)
4558 lt_fatal (__FILE__, __LINE__, "memory exhausted");
4559
4560 return p;
4561 }
4562
4563 char *
4564 xstrdup (const char *string)
4565 {
4566 return string ? strcpy ((char *) xmalloc (strlen (string) + 1),
4567 string) : NULL;
4568 }
4569
4570 const char *
4571 base_name (const char *name)
4572 {
4573 const char *base;
4574
4575 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
4576 /* Skip over the disk name in MSDOS pathnames. */
4577 if (isalpha ((unsigned char) name[0]) && name[1] == ':')
4578 name += 2;
4579 #endif
4580
4581 for (base = name; *name; name++)
4582 if (IS_DIR_SEPARATOR (*name))
4583 base = name + 1;
4584 return base;
4585 }
4586
4587 int
4588 check_executable (const char *path)
4589 {
4590 struct stat st;
4591
4592 lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n",
4593 nonempty (path));
4594 if ((!path) || (!*path))
4595 return 0;
4596
4597 if ((stat (path, &st) >= 0)
4598 && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH)))
4599 return 1;
4600 else
4601 return 0;
4602 }
4603
4604 int
4605 make_executable (const char *path)
4606 {
4607 int rval = 0;
4608 struct stat st;
4609
4610 lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n",
4611 nonempty (path));
4612 if ((!path) || (!*path))
4613 return 0;
4614
4615 if (stat (path, &st) >= 0)
4616 {
4617 rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR);
4618 }
4619 return rval;
4620 }
4621
4622 /* Searches for the full path of the wrapper. Returns
4623 newly allocated full path name if found, NULL otherwise
4624 Does not chase symlinks, even on platforms that support them.
4625 */
4626 char *
4627 find_executable (const char *wrapper)
4628 {
4629 int has_slash = 0;
4630 const char *p;
4631 const char *p_next;
4632 /* static buffer for getcwd */
4633 char tmp[LT_PATHMAX + 1];
4634 int tmp_len;
4635 char *concat_name;
4636
4637 lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n",
4638 nonempty (wrapper));
4639
4640 if ((wrapper == NULL) || (*wrapper == '\0'))
4641 return NULL;
4642
4643 /* Absolute path? */
4644 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
4645 if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':')
4646 {
4647 concat_name = xstrdup (wrapper);
4648 if (check_executable (concat_name))
4649 return concat_name;
4650 XFREE (concat_name);
4651 }
4652 else
4653 {
4654 #endif
4655 if (IS_DIR_SEPARATOR (wrapper[0]))
4656 {
4657 concat_name = xstrdup (wrapper);
4658 if (check_executable (concat_name))
4659 return concat_name;
4660 XFREE (concat_name);
4661 }
4662 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
4663 }
4664 #endif
4665
4666 for (p = wrapper; *p; p++)
4667 if (*p == '/')
4668 {
4669 has_slash = 1;
4670 break;
4671 }
4672 if (!has_slash)
4673 {
4674 /* no slashes; search PATH */
4675 const char *path = getenv ("PATH");
4676 if (path != NULL)
4677 {
4678 for (p = path; *p; p = p_next)
4679 {
4680 const char *q;
4681 size_t p_len;
4682 for (q = p; *q; q++)
4683 if (IS_PATH_SEPARATOR (*q))
4684 break;
4685 p_len = q - p;
4686 p_next = (*q == '\0' ? q : q + 1);
4687 if (p_len == 0)
4688 {
4689 /* empty path: current directory */
4690 if (getcwd (tmp, LT_PATHMAX) == NULL)
4691 lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
4692 nonnull (strerror (errno)));
4693 tmp_len = strlen (tmp);
4694 concat_name =
4695 XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
4696 memcpy (concat_name, tmp, tmp_len);
4697 concat_name[tmp_len] = '/';
4698 strcpy (concat_name + tmp_len + 1, wrapper);
4699 }
4700 else
4701 {
4702 concat_name =
4703 XMALLOC (char, p_len + 1 + strlen (wrapper) + 1);
4704 memcpy (concat_name, p, p_len);
4705 concat_name[p_len] = '/';
4706 strcpy (concat_name + p_len + 1, wrapper);
4707 }
4708 if (check_executable (concat_name))
4709 return concat_name;
4710 XFREE (concat_name);
4711 }
4712 }
4713 /* not found in PATH; assume curdir */
4714 }
4715 /* Relative path | not found in path: prepend cwd */
4716 if (getcwd (tmp, LT_PATHMAX) == NULL)
4717 lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
4718 nonnull (strerror (errno)));
4719 tmp_len = strlen (tmp);
4720 concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
4721 memcpy (concat_name, tmp, tmp_len);
4722 concat_name[tmp_len] = '/';
4723 strcpy (concat_name + tmp_len + 1, wrapper);
4724
4725 if (check_executable (concat_name))
4726 return concat_name;
4727 XFREE (concat_name);
4728 return NULL;
4729 }
4730
4731 char *
4732 chase_symlinks (const char *pathspec)
4733 {
4734 #ifndef S_ISLNK
4735 return xstrdup (pathspec);
4736 #else
4737 char buf[LT_PATHMAX];
4738 struct stat s;
4739 char *tmp_pathspec = xstrdup (pathspec);
4740 char *p;
4741 int has_symlinks = 0;
4742 while (strlen (tmp_pathspec) && !has_symlinks)
4743 {
4744 lt_debugprintf (__FILE__, __LINE__,
4745 "checking path component for symlinks: %s\n",
4746 tmp_pathspec);
4747 if (lstat (tmp_pathspec, &s) == 0)
4748 {
4749 if (S_ISLNK (s.st_mode) != 0)
4750 {
4751 has_symlinks = 1;
4752 break;
4753 }
4754
4755 /* search backwards for last DIR_SEPARATOR */
4756 p = tmp_pathspec + strlen (tmp_pathspec) - 1;
4757 while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p)))
4758 p--;
4759 if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p)))
4760 {
4761 /* no more DIR_SEPARATORS left */
4762 break;
4763 }
4764 *p = '\0';
4765 }
4766 else
4767 {
4768 lt_fatal (__FILE__, __LINE__,
4769 "error accessing file \"%s\": %s",
4770 tmp_pathspec, nonnull (strerror (errno)));
4771 }
4772 }
4773 XFREE (tmp_pathspec);
4774
4775 if (!has_symlinks)
4776 {
4777 return xstrdup (pathspec);
4778 }
4779
4780 tmp_pathspec = realpath (pathspec, buf);
4781 if (tmp_pathspec == 0)
4782 {
4783 lt_fatal (__FILE__, __LINE__,
4784 "could not follow symlinks for %s", pathspec);
4785 }
4786 return xstrdup (tmp_pathspec);
4787 #endif
4788 }
4789
4790 char *
4791 strendzap (char *str, const char *pat)
4792 {
4793 size_t len, patlen;
4794
4795 assert (str != NULL);
4796 assert (pat != NULL);
4797
4798 len = strlen (str);
4799 patlen = strlen (pat);
4800
4801 if (patlen <= len)
4802 {
4803 str += len - patlen;
4804 if (strcmp (str, pat) == 0)
4805 *str = '\0';
4806 }
4807 return str;
4808 }
4809
4810 void
4811 lt_debugprintf (const char *file, int line, const char *fmt, ...)
4812 {
4813 va_list args;
4814 if (lt_debug)
4815 {
4816 (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line);
4817 va_start (args, fmt);
4818 (void) vfprintf (stderr, fmt, args);
4819 va_end (args);
4820 }
4821 }
4822
4823 static void
4824 lt_error_core (int exit_status, const char *file,
4825 int line, const char *mode,
4826 const char *message, va_list ap)
4827 {
4828 fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode);
4829 vfprintf (stderr, message, ap);
4830 fprintf (stderr, ".\n");
4831
4832 if (exit_status >= 0)
4833 exit (exit_status);
4834 }
4835
4836 void
4837 lt_fatal (const char *file, int line, const char *message, ...)
4838 {
4839 va_list ap;
4840 va_start (ap, message);
4841 lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap);
4842 va_end (ap);
4843 }
4844
4845 static const char *
4846 nonnull (const char *s)
4847 {
4848 return s ? s : "(null)";
4849 }
4850
4851 static const char *
4852 nonempty (const char *s)
4853 {
4854 return (s && !*s) ? "(empty)" : nonnull (s);
4855 }
4856
4857 void
4858 lt_setenv (const char *name, const char *value)
4859 {
4860 lt_debugprintf (__FILE__, __LINE__,
4861 "(lt_setenv) setting '%s' to '%s'\n",
4862 nonnull (name), nonnull (value));
4863 {
4864 #ifdef HAVE_SETENV
4865 /* always make a copy, for consistency with !HAVE_SETENV */
4866 char *str = xstrdup (value);
4867 setenv (name, str, 1);
4868 #else
4869 int len = strlen (name) + 1 + strlen (value) + 1;
4870 char *str = XMALLOC (char, len);
4871 sprintf (str, "%s=%s", name, value);
4872 if (putenv (str) != EXIT_SUCCESS)
4873 {
4874 XFREE (str);
4875 }
4876 #endif
4877 }
4878 }
4879
4880 char *
4881 lt_extend_str (const char *orig_value, const char *add, int to_end)
4882 {
4883 char *new_value;
4884 if (orig_value && *orig_value)
4885 {
4886 int orig_value_len = strlen (orig_value);
4887 int add_len = strlen (add);
4888 new_value = XMALLOC (char, add_len + orig_value_len + 1);
4889 if (to_end)
4890 {
4891 strcpy (new_value, orig_value);
4892 strcpy (new_value + orig_value_len, add);
4893 }
4894 else
4895 {
4896 strcpy (new_value, add);
4897 strcpy (new_value + add_len, orig_value);
4898 }
4899 }
4900 else
4901 {
4902 new_value = xstrdup (add);
4903 }
4904 return new_value;
4905 }
4906
4907 void
4908 lt_update_exe_path (const char *name, const char *value)
4909 {
4910 lt_debugprintf (__FILE__, __LINE__,
4911 "(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
4912 nonnull (name), nonnull (value));
4913
4914 if (name && *name && value && *value)
4915 {
4916 char *new_value = lt_extend_str (getenv (name), value, 0);
4917 /* some systems can't cope with a ':'-terminated path #' */
4918 int len = strlen (new_value);
4919 while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1]))
4920 {
4921 new_value[len-1] = '\0';
4922 }
4923 lt_setenv (name, new_value);
4924 XFREE (new_value);
4925 }
4926 }
4927
4928 void
4929 lt_update_lib_path (const char *name, const char *value)
4930 {
4931 lt_debugprintf (__FILE__, __LINE__,
4932 "(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
4933 nonnull (name), nonnull (value));
4934
4935 if (name && *name && value && *value)
4936 {
4937 char *new_value = lt_extend_str (getenv (name), value, 0);
4938 lt_setenv (name, new_value);
4939 XFREE (new_value);
4940 }
4941 }
4942
4943 EOF
4944 case $host_os in
4945 mingw*)
4946 cat <<"EOF"
4947
4948 /* Prepares an argument vector before calling spawn().
4949 Note that spawn() does not by itself call the command interpreter
4950 (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") :
4951 ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
4952 GetVersionEx(&v);
4953 v.dwPlatformId == VER_PLATFORM_WIN32_NT;
4954 }) ? "cmd.exe" : "command.com").
4955 Instead it simply concatenates the arguments, separated by ' ', and calls
4956 CreateProcess(). We must quote the arguments since Win32 CreateProcess()
4957 interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a
4958 special way:
4959 - Space and tab are interpreted as delimiters. They are not treated as
4960 delimiters if they are surrounded by double quotes: "...".
4961 - Unescaped double quotes are removed from the input. Their only effect is
4962 that within double quotes, space and tab are treated like normal
4963 characters.
4964 - Backslashes not followed by double quotes are not special.
4965 - But 2*n+1 backslashes followed by a double quote become
4966 n backslashes followed by a double quote (n >= 0):
4967 \" -> "
4968 \\\" -> \"
4969 \\\\\" -> \\"
4970 */
4971 #define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
4972 #define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
4973 char **
4974 prepare_spawn (char **argv)
4975 {
4976 size_t argc;
4977 char **new_argv;
4978 size_t i;
4979
4980 /* Count number of arguments. */
4981 for (argc = 0; argv[argc] != NULL; argc++)
4982 ;
4983
4984 /* Allocate new argument vector. */
4985 new_argv = XMALLOC (char *, argc + 1);
4986
4987 /* Put quoted arguments into the new argument vector. */
4988 for (i = 0; i < argc; i++)
4989 {
4990 const char *string = argv[i];
4991
4992 if (string[0] == '\0')
4993 new_argv[i] = xstrdup ("\"\"");
4994 else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL)
4995 {
4996 int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL);
4997 size_t length;
4998 unsigned int backslashes;
4999 const char *s;
5000 char *quoted_string;
5001 char *p;
5002
5003 length = 0;
5004 backslashes = 0;
5005 if (quote_around)
5006 length++;
5007 for (s = string; *s != '\0'; s++)
5008 {
5009 char c = *s;
5010 if (c == '"')
5011 length += backslashes + 1;
5012 length++;
5013 if (c == '\\')
5014 backslashes++;
5015 else
5016 backslashes = 0;
5017 }
5018 if (quote_around)
5019 length += backslashes + 1;
5020
5021 quoted_string = XMALLOC (char, length + 1);
5022
5023 p = quoted_string;
5024 backslashes = 0;
5025 if (quote_around)
5026 *p++ = '"';
5027 for (s = string; *s != '\0'; s++)
5028 {
5029 char c = *s;
5030 if (c == '"')
5031 {
5032 unsigned int j;
5033 for (j = backslashes + 1; j > 0; j--)
5034 *p++ = '\\';
5035 }
5036 *p++ = c;
5037 if (c == '\\')
5038 backslashes++;
5039 else
5040 backslashes = 0;
5041 }
5042 if (quote_around)
5043 {
5044 unsigned int j;
5045 for (j = backslashes; j > 0; j--)
5046 *p++ = '\\';
5047 *p++ = '"';
5048 }
5049 *p = '\0';
5050
5051 new_argv[i] = quoted_string;
5052 }
5053 else
5054 new_argv[i] = (char *) string;
5055 }
5056 new_argv[argc] = NULL;
5057
5058 return new_argv;
5059 }
5060 EOF
5061 ;;
5062 esac
5063
5064 cat <<"EOF"
5065 void lt_dump_script (FILE* f)
5066 {
5067 EOF
5068 func_emit_wrapper yes |
5069 $SED -n -e '
5070 s/^\(.\{79\}\)\(..*\)/\1\
5071 \2/
5072 h
5073 s/\([\\"]\)/\\\1/g
5074 s/$/\\n/
5075 s/\([^\n]*\).*/ fputs ("\1", f);/p
5076 g
5077 D'
5078 cat <<"EOF"
5079 }
5080 EOF
5081 }
5082 # end: func_emit_cwrapperexe_src
5083
5084 # func_win32_import_lib_p ARG
5085 # True if ARG is an import lib, as indicated by $file_magic_cmd
5086 func_win32_import_lib_p ()
5087 {
5088 $opt_debug
5089 case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in
5090 *import*) : ;;
5091 *) false ;;
5092 esac
5093 }
5094
5095 # func_mode_link arg...
5096 func_mode_link ()
5097 {
5098 $opt_debug
5099 case $host in
5100 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
5101 # It is impossible to link a dll without this setting, and
5102 # we shouldn't force the makefile maintainer to figure out
5103 # which system we are compiling for in order to pass an extra
5104 # flag for every libtool invocation.
5105 # allow_undefined=no
5106
5107 # FIXME: Unfortunately, there are problems with the above when trying
5108 # to make a dll which has undefined symbols, in which case not
5109 # even a static library is built. For now, we need to specify
5110 # -no-undefined on the libtool link line when we can be certain
5111 # that all symbols are satisfied, otherwise we get a static library.
5112 allow_undefined=yes
5113 ;;
5114 *)
5115 allow_undefined=yes
5116 ;;
5117 esac
5118 libtool_args=$nonopt
5119 base_compile="$nonopt $@"
5120 compile_command=$nonopt
5121 finalize_command=$nonopt
5122
5123 compile_rpath=
5124 finalize_rpath=
5125 compile_shlibpath=
5126 finalize_shlibpath=
5127 convenience=
5128 old_convenience=
5129 deplibs=
5130 old_deplibs=
5131 compiler_flags=
5132 linker_flags=
5133 dllsearchpath=
5134 lib_search_path=`pwd`
5135 inst_prefix_dir=
5136 new_inherited_linker_flags=
5137
5138 avoid_version=no
5139 bindir=
5140 dlfiles=
5141 dlprefiles=
5142 dlself=no
5143 export_dynamic=no
5144 export_symbols=
5145 export_symbols_regex=
5146 generated=
5147 libobjs=
5148 ltlibs=
5149 module=no
5150 no_install=no
5151 objs=
5152 non_pic_objects=
5153 precious_files_regex=
5154 prefer_static_libs=no
5155 preload=no
5156 prev=
5157 prevarg=
5158 release=
5159 rpath=
5160 xrpath=
5161 perm_rpath=
5162 temp_rpath=
5163 thread_safe=no
5164 vinfo=
5165 vinfo_number=no
5166 weak_libs=
5167 single_module="${wl}-single_module"
5168 func_infer_tag $base_compile
5169
5170 # We need to know -static, to get the right output filenames.
5171 for arg
5172 do
5173 case $arg in
5174 -shared)
5175 test "$build_libtool_libs" != yes && \
5176 func_fatal_configuration "can not build a shared library"
5177 build_old_libs=no
5178 break
5179 ;;
5180 -all-static | -static | -static-libtool-libs)
5181 case $arg in
5182 -all-static)
5183 if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then
5184 func_warning "complete static linking is impossible in this configuration"
5185 fi
5186 if test -n "$link_static_flag"; then
5187 dlopen_self=$dlopen_self_static
5188 fi
5189 prefer_static_libs=yes
5190 ;;
5191 -static)
5192 if test -z "$pic_flag" && test -n "$link_static_flag"; then
5193 dlopen_self=$dlopen_self_static
5194 fi
5195 prefer_static_libs=built
5196 ;;
5197 -static-libtool-libs)
5198 if test -z "$pic_flag" && test -n "$link_static_flag"; then
5199 dlopen_self=$dlopen_self_static
5200 fi
5201 prefer_static_libs=yes
5202 ;;
5203 esac
5204 build_libtool_libs=no
5205 build_old_libs=yes
5206 break
5207 ;;
5208 esac
5209 done
5210
5211 # See if our shared archives depend on static archives.
5212 test -n "$old_archive_from_new_cmds" && build_old_libs=yes
5213
5214 # Go through the arguments, transforming them on the way.
5215 while test "$#" -gt 0; do
5216 arg="$1"
5217 shift
5218 func_quote_for_eval "$arg"
5219 qarg=$func_quote_for_eval_unquoted_result
5220 func_append libtool_args " $func_quote_for_eval_result"
5221
5222 # If the previous option needs an argument, assign it.
5223 if test -n "$prev"; then
5224 case $prev in
5225 output)
5226 func_append compile_command " @OUTPUT@"
5227 func_append finalize_command " @OUTPUT@"
5228 ;;
5229 esac
5230
5231 case $prev in
5232 bindir)
5233 bindir="$arg"
5234 prev=
5235 continue
5236 ;;
5237 dlfiles|dlprefiles)
5238 if test "$preload" = no; then
5239 # Add the symbol object into the linking commands.
5240 func_append compile_command " @SYMFILE@"
5241 func_append finalize_command " @SYMFILE@"
5242 preload=yes
5243 fi
5244 case $arg in
5245 *.la | *.lo) ;; # We handle these cases below.
5246 force)
5247 if test "$dlself" = no; then
5248 dlself=needless
5249 export_dynamic=yes
5250 fi
5251 prev=
5252 continue
5253 ;;
5254 self)
5255 if test "$prev" = dlprefiles; then
5256 dlself=yes
5257 elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then
5258 dlself=yes
5259 else
5260 dlself=needless
5261 export_dynamic=yes
5262 fi
5263 prev=
5264 continue
5265 ;;
5266 *)
5267 if test "$prev" = dlfiles; then
5268 func_append dlfiles " $arg"
5269 else
5270 func_append dlprefiles " $arg"
5271 fi
5272 prev=
5273 continue
5274 ;;
5275 esac
5276 ;;
5277 expsyms)
5278 export_symbols="$arg"
5279 test -f "$arg" \
5280 || func_fatal_error "symbol file \`$arg' does not exist"
5281 prev=
5282 continue
5283 ;;
5284 expsyms_regex)
5285 export_symbols_regex="$arg"
5286 prev=
5287 continue
5288 ;;
5289 framework)
5290 case $host in
5291 *-*-darwin*)
5292 case "$deplibs " in
5293 *" $qarg.ltframework "*) ;;
5294 *) func_append deplibs " $qarg.ltframework" # this is fixed later
5295 ;;
5296 esac
5297 ;;
5298 esac
5299 prev=
5300 continue
5301 ;;
5302 inst_prefix)
5303 inst_prefix_dir="$arg"
5304 prev=
5305 continue
5306 ;;
5307 objectlist)
5308 if test -f "$arg"; then
5309 save_arg=$arg
5310 moreargs=
5311 for fil in `cat "$save_arg"`
5312 do
5313 # func_append moreargs " $fil"
5314 arg=$fil
5315 # A libtool-controlled object.
5316
5317 # Check to see that this really is a libtool object.
5318 if func_lalib_unsafe_p "$arg"; then
5319 pic_object=
5320 non_pic_object=
5321
5322 # Read the .lo file
5323 func_source "$arg"
5324
5325 if test -z "$pic_object" ||
5326 test -z "$non_pic_object" ||
5327 test "$pic_object" = none &&
5328 test "$non_pic_object" = none; then
5329 func_fatal_error "cannot find name of object for \`$arg'"
5330 fi
5331
5332 # Extract subdirectory from the argument.
5333 func_dirname "$arg" "/" ""
5334 xdir="$func_dirname_result"
5335
5336 if test "$pic_object" != none; then
5337 # Prepend the subdirectory the object is found in.
5338 pic_object="$xdir$pic_object"
5339
5340 if test "$prev" = dlfiles; then
5341 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
5342 func_append dlfiles " $pic_object"
5343 prev=
5344 continue
5345 else
5346 # If libtool objects are unsupported, then we need to preload.
5347 prev=dlprefiles
5348 fi
5349 fi
5350
5351 # CHECK ME: I think I busted this. -Ossama
5352 if test "$prev" = dlprefiles; then
5353 # Preload the old-style object.
5354 func_append dlprefiles " $pic_object"
5355 prev=
5356 fi
5357
5358 # A PIC object.
5359 func_append libobjs " $pic_object"
5360 arg="$pic_object"
5361 fi
5362
5363 # Non-PIC object.
5364 if test "$non_pic_object" != none; then
5365 # Prepend the subdirectory the object is found in.
5366 non_pic_object="$xdir$non_pic_object"
5367
5368 # A standard non-PIC object
5369 func_append non_pic_objects " $non_pic_object"
5370 if test -z "$pic_object" || test "$pic_object" = none ; then
5371 arg="$non_pic_object"
5372 fi
5373 else
5374 # If the PIC object exists, use it instead.
5375 # $xdir was prepended to $pic_object above.
5376 non_pic_object="$pic_object"
5377 func_append non_pic_objects " $non_pic_object"
5378 fi
5379 else
5380 # Only an error if not doing a dry-run.
5381 if $opt_dry_run; then
5382 # Extract subdirectory from the argument.
5383 func_dirname "$arg" "/" ""
5384 xdir="$func_dirname_result"
5385
5386 func_lo2o "$arg"
5387 pic_object=$xdir$objdir/$func_lo2o_result
5388 non_pic_object=$xdir$func_lo2o_result
5389 func_append libobjs " $pic_object"
5390 func_append non_pic_objects " $non_pic_object"
5391 else
5392 func_fatal_error "\`$arg' is not a valid libtool object"
5393 fi
5394 fi
5395 done
5396 else
5397 func_fatal_error "link input file \`$arg' does not exist"
5398 fi
5399 arg=$save_arg
5400 prev=
5401 continue
5402 ;;
5403 precious_regex)
5404 precious_files_regex="$arg"
5405 prev=
5406 continue
5407 ;;
5408 release)
5409 release="-$arg"
5410 prev=
5411 continue
5412 ;;
5413 rpath | xrpath)
5414 # We need an absolute path.
5415 case $arg in
5416 [\\/]* | [A-Za-z]:[\\/]*) ;;
5417 *)
5418 func_fatal_error "only absolute run-paths are allowed"
5419 ;;
5420 esac
5421 if test "$prev" = rpath; then
5422 case "$rpath " in
5423 *" $arg "*) ;;
5424 *) func_append rpath " $arg" ;;
5425 esac
5426 else
5427 case "$xrpath " in
5428 *" $arg "*) ;;
5429 *) func_append xrpath " $arg" ;;
5430 esac
5431 fi
5432 prev=
5433 continue
5434 ;;
5435 shrext)
5436 shrext_cmds="$arg"
5437 prev=
5438 continue
5439 ;;
5440 weak)
5441 func_append weak_libs " $arg"
5442 prev=
5443 continue
5444 ;;
5445 xcclinker)
5446 func_append linker_flags " $qarg"
5447 func_append compiler_flags " $qarg"
5448 prev=
5449 func_append compile_command " $qarg"
5450 func_append finalize_command " $qarg"
5451 continue
5452 ;;
5453 xcompiler)
5454 func_append compiler_flags " $qarg"
5455 prev=
5456 func_append compile_command " $qarg"
5457 func_append finalize_command " $qarg"
5458 continue
5459 ;;
5460 xlinker)
5461 func_append linker_flags " $qarg"
5462 func_append compiler_flags " $wl$qarg"
5463 prev=
5464 func_append compile_command " $wl$qarg"
5465 func_append finalize_command " $wl$qarg"
5466 continue
5467 ;;
5468 *)
5469 eval "$prev=\"\$arg\""
5470 prev=
5471 continue
5472 ;;
5473 esac
5474 fi # test -n "$prev"
5475
5476 prevarg="$arg"
5477
5478 case $arg in
5479 -all-static)
5480 if test -n "$link_static_flag"; then
5481 # See comment for -static flag below, for more details.
5482 func_append compile_command " $link_static_flag"
5483 func_append finalize_command " $link_static_flag"
5484 fi
5485 continue
5486 ;;
5487
5488 -allow-undefined)
5489 # FIXME: remove this flag sometime in the future.
5490 func_fatal_error "\`-allow-undefined' must not be used because it is the default"
5491 ;;
5492
5493 -avoid-version)
5494 avoid_version=yes
5495 continue
5496 ;;
5497
5498 -bindir)
5499 prev=bindir
5500 continue
5501 ;;
5502
5503 -dlopen)
5504 prev=dlfiles
5505 continue
5506 ;;
5507
5508 -dlpreopen)
5509 prev=dlprefiles
5510 continue
5511 ;;
5512
5513 -export-dynamic)
5514 export_dynamic=yes
5515 continue
5516 ;;
5517
5518 -export-symbols | -export-symbols-regex)
5519 if test -n "$export_symbols" || test -n "$export_symbols_regex"; then
5520 func_fatal_error "more than one -exported-symbols argument is not allowed"
5521 fi
5522 if test "X$arg" = "X-export-symbols"; then
5523 prev=expsyms
5524 else
5525 prev=expsyms_regex
5526 fi
5527 continue
5528 ;;
5529
5530 -framework)
5531 prev=framework
5532 continue
5533 ;;
5534
5535 -inst-prefix-dir)
5536 prev=inst_prefix
5537 continue
5538 ;;
5539
5540 # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:*
5541 # so, if we see these flags be careful not to treat them like -L
5542 -L[A-Z][A-Z]*:*)
5543 case $with_gcc/$host in
5544 no/*-*-irix* | /*-*-irix*)
5545 func_append compile_command " $arg"
5546 func_append finalize_command " $arg"
5547 ;;
5548 esac
5549 continue
5550 ;;
5551
5552 -L*)
5553 func_stripname "-L" '' "$arg"
5554 if test -z "$func_stripname_result"; then
5555 if test "$#" -gt 0; then
5556 func_fatal_error "require no space between \`-L' and \`$1'"
5557 else
5558 func_fatal_error "need path for \`-L' option"
5559 fi
5560 fi
5561 func_resolve_sysroot "$func_stripname_result"
5562 dir=$func_resolve_sysroot_result
5563 # We need an absolute path.
5564 case $dir in
5565 [\\/]* | [A-Za-z]:[\\/]*) ;;
5566 *)
5567 absdir=`cd "$dir" && pwd`
5568 test -z "$absdir" && \
5569 func_fatal_error "cannot determine absolute directory name of \`$dir'"
5570 dir="$absdir"
5571 ;;
5572 esac
5573 case "$deplibs " in
5574 *" -L$dir "* | *" $arg "*)
5575 # Will only happen for absolute or sysroot arguments
5576 ;;
5577 *)
5578 # Preserve sysroot, but never include relative directories
5579 case $dir in
5580 [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;;
5581 *) func_append deplibs " -L$dir" ;;
5582 esac
5583 func_append lib_search_path " $dir"
5584 ;;
5585 esac
5586 case $host in
5587 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
5588 testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'`
5589 case :$dllsearchpath: in
5590 *":$dir:"*) ;;
5591 ::) dllsearchpath=$dir;;
5592 *) func_append dllsearchpath ":$dir";;
5593 esac
5594 case :$dllsearchpath: in
5595 *":$testbindir:"*) ;;
5596 ::) dllsearchpath=$testbindir;;
5597 *) func_append dllsearchpath ":$testbindir";;
5598 esac
5599 ;;
5600 esac
5601 continue
5602 ;;
5603
5604 -l*)
5605 if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
5606 case $host in
5607 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*)
5608 # These systems don't actually have a C or math library (as such)
5609 continue
5610 ;;
5611 *-*-os2*)
5612 # These systems don't actually have a C library (as such)
5613 test "X$arg" = "X-lc" && continue
5614 ;;
5615 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
5616 # Do not include libc due to us having libc/libc_r.
5617 test "X$arg" = "X-lc" && continue
5618 ;;
5619 *-*-rhapsody* | *-*-darwin1.[012])
5620 # Rhapsody C and math libraries are in the System framework
5621 func_append deplibs " System.ltframework"
5622 continue
5623 ;;
5624 *-*-sco3.2v5* | *-*-sco5v6*)
5625 # Causes problems with __ctype
5626 test "X$arg" = "X-lc" && continue
5627 ;;
5628 *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
5629 # Compiler inserts libc in the correct place for threads to work
5630 test "X$arg" = "X-lc" && continue
5631 ;;
5632 esac
5633 elif test "X$arg" = "X-lc_r"; then
5634 case $host in
5635 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
5636 # Do not include libc_r directly, use -pthread flag.
5637 continue
5638 ;;
5639 esac
5640 fi
5641 func_append deplibs " $arg"
5642 continue
5643 ;;
5644
5645 -module)
5646 module=yes
5647 continue
5648 ;;
5649
5650 # Tru64 UNIX uses -model [arg] to determine the layout of C++
5651 # classes, name mangling, and exception handling.
5652 # Darwin uses the -arch flag to determine output architecture.
5653 -model|-arch|-isysroot|--sysroot)
5654 func_append compiler_flags " $arg"
5655 func_append compile_command " $arg"
5656 func_append finalize_command " $arg"
5657 prev=xcompiler
5658 continue
5659 ;;
5660
5661 -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
5662 |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
5663 func_append compiler_flags " $arg"
5664 func_append compile_command " $arg"
5665 func_append finalize_command " $arg"
5666 case "$new_inherited_linker_flags " in
5667 *" $arg "*) ;;
5668 * ) func_append new_inherited_linker_flags " $arg" ;;
5669 esac
5670 continue
5671 ;;
5672
5673 -multi_module)
5674 single_module="${wl}-multi_module"
5675 continue
5676 ;;
5677
5678 -no-fast-install)
5679 fast_install=no
5680 continue
5681 ;;
5682
5683 -no-install)
5684 case $host in
5685 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*)
5686 # The PATH hackery in wrapper scripts is required on Windows
5687 # and Darwin in order for the loader to find any dlls it needs.
5688 func_warning "\`-no-install' is ignored for $host"
5689 func_warning "assuming \`-no-fast-install' instead"
5690 fast_install=no
5691 ;;
5692 *) no_install=yes ;;
5693 esac
5694 continue
5695 ;;
5696
5697 -no-undefined)
5698 allow_undefined=no
5699 continue
5700 ;;
5701
5702 -objectlist)
5703 prev=objectlist
5704 continue
5705 ;;
5706
5707 -o) prev=output ;;
5708
5709 -precious-files-regex)
5710 prev=precious_regex
5711 continue
5712 ;;
5713
5714 -release)
5715 prev=release
5716 continue
5717 ;;
5718
5719 -rpath)
5720 prev=rpath
5721 continue
5722 ;;
5723
5724 -R)
5725 prev=xrpath
5726 continue
5727 ;;
5728
5729 -R*)
5730 func_stripname '-R' '' "$arg"
5731 dir=$func_stripname_result
5732 # We need an absolute path.
5733 case $dir in
5734 [\\/]* | [A-Za-z]:[\\/]*) ;;
5735 =*)
5736 func_stripname '=' '' "$dir"
5737 dir=$lt_sysroot$func_stripname_result
5738 ;;
5739 *)
5740 func_fatal_error "only absolute run-paths are allowed"
5741 ;;
5742 esac
5743 case "$xrpath " in
5744 *" $dir "*) ;;
5745 *) func_append xrpath " $dir" ;;
5746 esac
5747 continue
5748 ;;
5749
5750 -shared)
5751 # The effects of -shared are defined in a previous loop.
5752 continue
5753 ;;
5754
5755 -shrext)
5756 prev=shrext
5757 continue
5758 ;;
5759
5760 -static | -static-libtool-libs)
5761 # The effects of -static are defined in a previous loop.
5762 # We used to do the same as -all-static on platforms that
5763 # didn't have a PIC flag, but the assumption that the effects
5764 # would be equivalent was wrong. It would break on at least
5765 # Digital Unix and AIX.
5766 continue
5767 ;;
5768
5769 -thread-safe)
5770 thread_safe=yes
5771 continue
5772 ;;
5773
5774 -version-info)
5775 prev=vinfo
5776 continue
5777 ;;
5778
5779 -version-number)
5780 prev=vinfo
5781 vinfo_number=yes
5782 continue
5783 ;;
5784
5785 -weak)
5786 prev=weak
5787 continue
5788 ;;
5789
5790 -Wc,*)
5791 func_stripname '-Wc,' '' "$arg"
5792 args=$func_stripname_result
5793 arg=
5794 save_ifs="$IFS"; IFS=','
5795 for flag in $args; do
5796 IFS="$save_ifs"
5797 func_quote_for_eval "$flag"
5798 func_append arg " $func_quote_for_eval_result"
5799 func_append compiler_flags " $func_quote_for_eval_result"
5800 done
5801 IFS="$save_ifs"
5802 func_stripname ' ' '' "$arg"
5803 arg=$func_stripname_result
5804 ;;
5805
5806 -Wl,*)
5807 func_stripname '-Wl,' '' "$arg"
5808 args=$func_stripname_result
5809 arg=
5810 save_ifs="$IFS"; IFS=','
5811 for flag in $args; do
5812 IFS="$save_ifs"
5813 func_quote_for_eval "$flag"
5814 func_append arg " $wl$func_quote_for_eval_result"
5815 func_append compiler_flags " $wl$func_quote_for_eval_result"
5816 func_append linker_flags " $func_quote_for_eval_result"
5817 done
5818 IFS="$save_ifs"
5819 func_stripname ' ' '' "$arg"
5820 arg=$func_stripname_result
5821 ;;
5822
5823 -Xcompiler)
5824 prev=xcompiler
5825 continue
5826 ;;
5827
5828 -Xlinker)
5829 prev=xlinker
5830 continue
5831 ;;
5832
5833 -XCClinker)
5834 prev=xcclinker
5835 continue
5836 ;;
5837
5838 # -msg_* for osf cc
5839 -msg_*)
5840 func_quote_for_eval "$arg"
5841 arg="$func_quote_for_eval_result"
5842 ;;
5843
5844 # Flags to be passed through unchanged, with rationale:
5845 # -64, -mips[0-9] enable 64-bit mode for the SGI compiler
5846 # -r[0-9][0-9]* specify processor for the SGI compiler
5847 # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler
5848 # +DA*, +DD* enable 64-bit mode for the HP compiler
5849 # -q* compiler args for the IBM compiler
5850 # -m*, -t[45]*, -txscale* architecture-specific flags for GCC
5851 # -F/path path to uninstalled frameworks, gcc on darwin
5852 # -p, -pg, --coverage, -fprofile-* profiling flags for GCC
5853 # @file GCC response files
5854 # -tp=* Portland pgcc target processor selection
5855 # --sysroot=* for sysroot support
5856 # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
5857 -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
5858 -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
5859 -O*|-flto*|-fwhopr*|-fuse-linker-plugin)
5860 func_quote_for_eval "$arg"
5861 arg="$func_quote_for_eval_result"
5862 func_append compile_command " $arg"
5863 func_append finalize_command " $arg"
5864 func_append compiler_flags " $arg"
5865 continue
5866 ;;
5867
5868 # Some other compiler flag.
5869 -* | +*)
5870 func_quote_for_eval "$arg"
5871 arg="$func_quote_for_eval_result"
5872 ;;
5873
5874 *.$objext)
5875 # A standard object.
5876 func_append objs " $arg"
5877 ;;
5878
5879 *.lo)
5880 # A libtool-controlled object.
5881
5882 # Check to see that this really is a libtool object.
5883 if func_lalib_unsafe_p "$arg"; then
5884 pic_object=
5885 non_pic_object=
5886
5887 # Read the .lo file
5888 func_source "$arg"
5889
5890 if test -z "$pic_object" ||
5891 test -z "$non_pic_object" ||
5892 test "$pic_object" = none &&
5893 test "$non_pic_object" = none; then
5894 func_fatal_error "cannot find name of object for \`$arg'"
5895 fi
5896
5897 # Extract subdirectory from the argument.
5898 func_dirname "$arg" "/" ""
5899 xdir="$func_dirname_result"
5900
5901 if test "$pic_object" != none; then
5902 # Prepend the subdirectory the object is found in.
5903 pic_object="$xdir$pic_object"
5904
5905 if test "$prev" = dlfiles; then
5906 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
5907 func_append dlfiles " $pic_object"
5908 prev=
5909 continue
5910 else
5911 # If libtool objects are unsupported, then we need to preload.
5912 prev=dlprefiles
5913 fi
5914 fi
5915
5916 # CHECK ME: I think I busted this. -Ossama
5917 if test "$prev" = dlprefiles; then
5918 # Preload the old-style object.
5919 func_append dlprefiles " $pic_object"
5920 prev=
5921 fi
5922
5923 # A PIC object.
5924 func_append libobjs " $pic_object"
5925 arg="$pic_object"
5926 fi
5927
5928 # Non-PIC object.
5929 if test "$non_pic_object" != none; then
5930 # Prepend the subdirectory the object is found in.
5931 non_pic_object="$xdir$non_pic_object"
5932
5933 # A standard non-PIC object
5934 func_append non_pic_objects " $non_pic_object"
5935 if test -z "$pic_object" || test "$pic_object" = none ; then
5936 arg="$non_pic_object"
5937 fi
5938 else
5939 # If the PIC object exists, use it instead.
5940 # $xdir was prepended to $pic_object above.
5941 non_pic_object="$pic_object"
5942 func_append non_pic_objects " $non_pic_object"
5943 fi
5944 else
5945 # Only an error if not doing a dry-run.
5946 if $opt_dry_run; then
5947 # Extract subdirectory from the argument.
5948 func_dirname "$arg" "/" ""
5949 xdir="$func_dirname_result"
5950
5951 func_lo2o "$arg"
5952 pic_object=$xdir$objdir/$func_lo2o_result
5953 non_pic_object=$xdir$func_lo2o_result
5954 func_append libobjs " $pic_object"
5955 func_append non_pic_objects " $non_pic_object"
5956 else
5957 func_fatal_error "\`$arg' is not a valid libtool object"
5958 fi
5959 fi
5960 ;;
5961
5962 *.$libext)
5963 # An archive.
5964 func_append deplibs " $arg"
5965 func_append old_deplibs " $arg"
5966 continue
5967 ;;
5968
5969 *.la)
5970 # A libtool-controlled library.
5971
5972 func_resolve_sysroot "$arg"
5973 if test "$prev" = dlfiles; then
5974 # This library was specified with -dlopen.
5975 func_append dlfiles " $func_resolve_sysroot_result"
5976 prev=
5977 elif test "$prev" = dlprefiles; then
5978 # The library was specified with -dlpreopen.
5979 func_append dlprefiles " $func_resolve_sysroot_result"
5980 prev=
5981 else
5982 func_append deplibs " $func_resolve_sysroot_result"
5983 fi
5984 continue
5985 ;;
5986
5987 # Some other compiler argument.
5988 *)
5989 # Unknown arguments in both finalize_command and compile_command need
5990 # to be aesthetically quoted because they are evaled later.
5991 func_quote_for_eval "$arg"
5992 arg="$func_quote_for_eval_result"
5993 ;;
5994 esac # arg
5995
5996 # Now actually substitute the argument into the commands.
5997 if test -n "$arg"; then
5998 func_append compile_command " $arg"
5999 func_append finalize_command " $arg"
6000 fi
6001 done # argument parsing loop
6002
6003 test -n "$prev" && \
6004 func_fatal_help "the \`$prevarg' option requires an argument"
6005
6006 if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then
6007 eval arg=\"$export_dynamic_flag_spec\"
6008 func_append compile_command " $arg"
6009 func_append finalize_command " $arg"
6010 fi
6011
6012 oldlibs=
6013 # calculate the name of the file, without its directory
6014 func_basename "$output"
6015 outputname="$func_basename_result"
6016 libobjs_save="$libobjs"
6017
6018 if test -n "$shlibpath_var"; then
6019 # get the directories listed in $shlibpath_var
6020 eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\`
6021 else
6022 shlib_search_path=
6023 fi
6024 eval sys_lib_search_path=\"$sys_lib_search_path_spec\"
6025 eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\"
6026
6027 func_dirname "$output" "/" ""
6028 output_objdir="$func_dirname_result$objdir"
6029 func_to_tool_file "$output_objdir/"
6030 tool_output_objdir=$func_to_tool_file_result
6031 # Create the object directory.
6032 func_mkdir_p "$output_objdir"
6033
6034 # Determine the type of output
6035 case $output in
6036 "")
6037 func_fatal_help "you must specify an output file"
6038 ;;
6039 *.$libext) linkmode=oldlib ;;
6040 *.lo | *.$objext) linkmode=obj ;;
6041 *.la) linkmode=lib ;;
6042 *) linkmode=prog ;; # Anything else should be a program.
6043 esac
6044
6045 specialdeplibs=
6046
6047 libs=
6048 # Find all interdependent deplibs by searching for libraries
6049 # that are linked more than once (e.g. -la -lb -la)
6050 for deplib in $deplibs; do
6051 if $opt_preserve_dup_deps ; then
6052 case "$libs " in
6053 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6054 esac
6055 fi
6056 func_append libs " $deplib"
6057 done
6058
6059 if test "$linkmode" = lib; then
6060 libs="$predeps $libs $compiler_lib_search_path $postdeps"
6061
6062 # Compute libraries that are listed more than once in $predeps
6063 # $postdeps and mark them as special (i.e., whose duplicates are
6064 # not to be eliminated).
6065 pre_post_deps=
6066 if $opt_duplicate_compiler_generated_deps; then
6067 for pre_post_dep in $predeps $postdeps; do
6068 case "$pre_post_deps " in
6069 *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;;
6070 esac
6071 func_append pre_post_deps " $pre_post_dep"
6072 done
6073 fi
6074 pre_post_deps=
6075 fi
6076
6077 deplibs=
6078 newdependency_libs=
6079 newlib_search_path=
6080 need_relink=no # whether we're linking any uninstalled libtool libraries
6081 notinst_deplibs= # not-installed libtool libraries
6082 notinst_path= # paths that contain not-installed libtool libraries
6083
6084 case $linkmode in
6085 lib)
6086 passes="conv dlpreopen link"
6087 for file in $dlfiles $dlprefiles; do
6088 case $file in
6089 *.la) ;;
6090 *)
6091 func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file"
6092 ;;
6093 esac
6094 done
6095 ;;
6096 prog)
6097 compile_deplibs=
6098 finalize_deplibs=
6099 alldeplibs=no
6100 newdlfiles=
6101 newdlprefiles=
6102 passes="conv scan dlopen dlpreopen link"
6103 ;;
6104 *) passes="conv"
6105 ;;
6106 esac
6107
6108 for pass in $passes; do
6109 # The preopen pass in lib mode reverses $deplibs; put it back here
6110 # so that -L comes before libs that need it for instance...
6111 if test "$linkmode,$pass" = "lib,link"; then
6112 ## FIXME: Find the place where the list is rebuilt in the wrong
6113 ## order, and fix it there properly
6114 tmp_deplibs=
6115 for deplib in $deplibs; do
6116 tmp_deplibs="$deplib $tmp_deplibs"
6117 done
6118 deplibs="$tmp_deplibs"
6119 fi
6120
6121 if test "$linkmode,$pass" = "lib,link" ||
6122 test "$linkmode,$pass" = "prog,scan"; then
6123 libs="$deplibs"
6124 deplibs=
6125 fi
6126 if test "$linkmode" = prog; then
6127 case $pass in
6128 dlopen) libs="$dlfiles" ;;
6129 dlpreopen) libs="$dlprefiles" ;;
6130 link)
6131 libs="$deplibs %DEPLIBS%"
6132 test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs"
6133 ;;
6134 esac
6135 fi
6136 if test "$linkmode,$pass" = "lib,dlpreopen"; then
6137 # Collect and forward deplibs of preopened libtool libs
6138 for lib in $dlprefiles; do
6139 # Ignore non-libtool-libs
6140 dependency_libs=
6141 func_resolve_sysroot "$lib"
6142 case $lib in
6143 *.la) func_source "$func_resolve_sysroot_result" ;;
6144 esac
6145
6146 # Collect preopened libtool deplibs, except any this library
6147 # has declared as weak libs
6148 for deplib in $dependency_libs; do
6149 func_basename "$deplib"
6150 deplib_base=$func_basename_result
6151 case " $weak_libs " in
6152 *" $deplib_base "*) ;;
6153 *) func_append deplibs " $deplib" ;;
6154 esac
6155 done
6156 done
6157 libs="$dlprefiles"
6158 fi
6159 if test "$pass" = dlopen; then
6160 # Collect dlpreopened libraries
6161 save_deplibs="$deplibs"
6162 deplibs=
6163 fi
6164
6165 for deplib in $libs; do
6166 lib=
6167 found=no
6168 case $deplib in
6169 -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
6170 |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
6171 if test "$linkmode,$pass" = "prog,link"; then
6172 compile_deplibs="$deplib $compile_deplibs"
6173 finalize_deplibs="$deplib $finalize_deplibs"
6174 else
6175 func_append compiler_flags " $deplib"
6176 if test "$linkmode" = lib ; then
6177 case "$new_inherited_linker_flags " in
6178 *" $deplib "*) ;;
6179 * ) func_append new_inherited_linker_flags " $deplib" ;;
6180 esac
6181 fi
6182 fi
6183 continue
6184 ;;
6185 -l*)
6186 if test "$linkmode" != lib && test "$linkmode" != prog; then
6187 func_warning "\`-l' is ignored for archives/objects"
6188 continue
6189 fi
6190 func_stripname '-l' '' "$deplib"
6191 name=$func_stripname_result
6192 if test "$linkmode" = lib; then
6193 searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path"
6194 else
6195 searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path"
6196 fi
6197 for searchdir in $searchdirs; do
6198 for search_ext in .la $std_shrext .so .a; do
6199 # Search the libtool library
6200 lib="$searchdir/lib${name}${search_ext}"
6201 if test -f "$lib"; then
6202 if test "$search_ext" = ".la"; then
6203 found=yes
6204 else
6205 found=no
6206 fi
6207 break 2
6208 fi
6209 done
6210 done
6211 if test "$found" != yes; then
6212 # deplib doesn't seem to be a libtool library
6213 if test "$linkmode,$pass" = "prog,link"; then
6214 compile_deplibs="$deplib $compile_deplibs"
6215 finalize_deplibs="$deplib $finalize_deplibs"
6216 else
6217 deplibs="$deplib $deplibs"
6218 test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
6219 fi
6220 continue
6221 else # deplib is a libtool library
6222 # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib,
6223 # We need to do some special things here, and not later.
6224 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
6225 case " $predeps $postdeps " in
6226 *" $deplib "*)
6227 if func_lalib_p "$lib"; then
6228 library_names=
6229 old_library=
6230 func_source "$lib"
6231 for l in $old_library $library_names; do
6232 ll="$l"
6233 done
6234 if test "X$ll" = "X$old_library" ; then # only static version available
6235 found=no
6236 func_dirname "$lib" "" "."
6237 ladir="$func_dirname_result"
6238 lib=$ladir/$old_library
6239 if test "$linkmode,$pass" = "prog,link"; then
6240 compile_deplibs="$deplib $compile_deplibs"
6241 finalize_deplibs="$deplib $finalize_deplibs"
6242 else
6243 deplibs="$deplib $deplibs"
6244 test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
6245 fi
6246 continue
6247 fi
6248 fi
6249 ;;
6250 *) ;;
6251 esac
6252 fi
6253 fi
6254 ;; # -l
6255 *.ltframework)
6256 if test "$linkmode,$pass" = "prog,link"; then
6257 compile_deplibs="$deplib $compile_deplibs"
6258 finalize_deplibs="$deplib $finalize_deplibs"
6259 else
6260 deplibs="$deplib $deplibs"
6261 if test "$linkmode" = lib ; then
6262 case "$new_inherited_linker_flags " in
6263 *" $deplib "*) ;;
6264 * ) func_append new_inherited_linker_flags " $deplib" ;;
6265 esac
6266 fi
6267 fi
6268 continue
6269 ;;
6270 -L*)
6271 case $linkmode in
6272 lib)
6273 deplibs="$deplib $deplibs"
6274 test "$pass" = conv && continue
6275 newdependency_libs="$deplib $newdependency_libs"
6276 func_stripname '-L' '' "$deplib"
6277 func_resolve_sysroot "$func_stripname_result"
6278 func_append newlib_search_path " $func_resolve_sysroot_result"
6279 ;;
6280 prog)
6281 if test "$pass" = conv; then
6282 deplibs="$deplib $deplibs"
6283 continue
6284 fi
6285 if test "$pass" = scan; then
6286 deplibs="$deplib $deplibs"
6287 else
6288 compile_deplibs="$deplib $compile_deplibs"
6289 finalize_deplibs="$deplib $finalize_deplibs"
6290 fi
6291 func_stripname '-L' '' "$deplib"
6292 func_resolve_sysroot "$func_stripname_result"
6293 func_append newlib_search_path " $func_resolve_sysroot_result"
6294 ;;
6295 *)
6296 func_warning "\`-L' is ignored for archives/objects"
6297 ;;
6298 esac # linkmode
6299 continue
6300 ;; # -L
6301 -R*)
6302 if test "$pass" = link; then
6303 func_stripname '-R' '' "$deplib"
6304 func_resolve_sysroot "$func_stripname_result"
6305 dir=$func_resolve_sysroot_result
6306 # Make sure the xrpath contains only unique directories.
6307 case "$xrpath " in
6308 *" $dir "*) ;;
6309 *) func_append xrpath " $dir" ;;
6310 esac
6311 fi
6312 deplibs="$deplib $deplibs"
6313 continue
6314 ;;
6315 *.la)
6316 func_resolve_sysroot "$deplib"
6317 lib=$func_resolve_sysroot_result
6318 ;;
6319 *.$libext)
6320 if test "$pass" = conv; then
6321 deplibs="$deplib $deplibs"
6322 continue
6323 fi
6324 case $linkmode in
6325 lib)
6326 # Linking convenience modules into shared libraries is allowed,
6327 # but linking other static libraries is non-portable.
6328 case " $dlpreconveniencelibs " in
6329 *" $deplib "*) ;;
6330 *)
6331 valid_a_lib=no
6332 case $deplibs_check_method in
6333 match_pattern*)
6334 set dummy $deplibs_check_method; shift
6335 match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
6336 if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \
6337 | $EGREP "$match_pattern_regex" > /dev/null; then
6338 valid_a_lib=yes
6339 fi
6340 ;;
6341 pass_all)
6342 valid_a_lib=yes
6343 ;;
6344 esac
6345 if test "$valid_a_lib" != yes; then
6346 echo
6347 $ECHO "*** Warning: Trying to link with static lib archive $deplib."
6348 echo "*** I have the capability to make that library automatically link in when"
6349 echo "*** you link to this library. But I can only do this if you have a"
6350 echo "*** shared version of the library, which you do not appear to have"
6351 echo "*** because the file extensions .$libext of this argument makes me believe"
6352 echo "*** that it is just a static archive that I should not use here."
6353 else
6354 echo
6355 $ECHO "*** Warning: Linking the shared library $output against the"
6356 $ECHO "*** static library $deplib is not portable!"
6357 deplibs="$deplib $deplibs"
6358 fi
6359 ;;
6360 esac
6361 continue
6362 ;;
6363 prog)
6364 if test "$pass" != link; then
6365 deplibs="$deplib $deplibs"
6366 else
6367 compile_deplibs="$deplib $compile_deplibs"
6368 finalize_deplibs="$deplib $finalize_deplibs"
6369 fi
6370 continue
6371 ;;
6372 esac # linkmode
6373 ;; # *.$libext
6374 *.lo | *.$objext)
6375 if test "$pass" = conv; then
6376 deplibs="$deplib $deplibs"
6377 elif test "$linkmode" = prog; then
6378 if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then
6379 # If there is no dlopen support or we're linking statically,
6380 # we need to preload.
6381 func_append newdlprefiles " $deplib"
6382 compile_deplibs="$deplib $compile_deplibs"
6383 finalize_deplibs="$deplib $finalize_deplibs"
6384 else
6385 func_append newdlfiles " $deplib"
6386 fi
6387 fi
6388 continue
6389 ;;
6390 %DEPLIBS%)
6391 alldeplibs=yes
6392 continue
6393 ;;
6394 esac # case $deplib
6395
6396 if test "$found" = yes || test -f "$lib"; then :
6397 else
6398 func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'"
6399 fi
6400
6401 # Check to see that this really is a libtool archive.
6402 func_lalib_unsafe_p "$lib" \
6403 || func_fatal_error "\`$lib' is not a valid libtool archive"
6404
6405 func_dirname "$lib" "" "."
6406 ladir="$func_dirname_result"
6407
6408 dlname=
6409 dlopen=
6410 dlpreopen=
6411 libdir=
6412 library_names=
6413 old_library=
6414 inherited_linker_flags=
6415 # If the library was installed with an old release of libtool,
6416 # it will not redefine variables installed, or shouldnotlink
6417 installed=yes
6418 shouldnotlink=no
6419 avoidtemprpath=
6420
6421
6422 # Read the .la file
6423 func_source "$lib"
6424
6425 # Convert "-framework foo" to "foo.ltframework"
6426 if test -n "$inherited_linker_flags"; then
6427 tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'`
6428 for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do
6429 case " $new_inherited_linker_flags " in
6430 *" $tmp_inherited_linker_flag "*) ;;
6431 *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";;
6432 esac
6433 done
6434 fi
6435 dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
6436 if test "$linkmode,$pass" = "lib,link" ||
6437 test "$linkmode,$pass" = "prog,scan" ||
6438 { test "$linkmode" != prog && test "$linkmode" != lib; }; then
6439 test -n "$dlopen" && func_append dlfiles " $dlopen"
6440 test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen"
6441 fi
6442
6443 if test "$pass" = conv; then
6444 # Only check for convenience libraries
6445 deplibs="$lib $deplibs"
6446 if test -z "$libdir"; then
6447 if test -z "$old_library"; then
6448 func_fatal_error "cannot find name of link library for \`$lib'"
6449 fi
6450 # It is a libtool convenience library, so add in its objects.
6451 func_append convenience " $ladir/$objdir/$old_library"
6452 func_append old_convenience " $ladir/$objdir/$old_library"
6453 tmp_libs=
6454 for deplib in $dependency_libs; do
6455 deplibs="$deplib $deplibs"
6456 if $opt_preserve_dup_deps ; then
6457 case "$tmp_libs " in
6458 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6459 esac
6460 fi
6461 func_append tmp_libs " $deplib"
6462 done
6463 elif test "$linkmode" != prog && test "$linkmode" != lib; then
6464 func_fatal_error "\`$lib' is not a convenience library"
6465 fi
6466 continue
6467 fi # $pass = conv
6468
6469
6470 # Get the name of the library we link against.
6471 linklib=
6472 if test -n "$old_library" &&
6473 { test "$prefer_static_libs" = yes ||
6474 test "$prefer_static_libs,$installed" = "built,no"; }; then
6475 linklib=$old_library
6476 else
6477 for l in $old_library $library_names; do
6478 linklib="$l"
6479 done
6480 fi
6481 if test -z "$linklib"; then
6482 func_fatal_error "cannot find name of link library for \`$lib'"
6483 fi
6484
6485 # This library was specified with -dlopen.
6486 if test "$pass" = dlopen; then
6487 if test -z "$libdir"; then
6488 func_fatal_error "cannot -dlopen a convenience library: \`$lib'"
6489 fi
6490 if test -z "$dlname" ||
6491 test "$dlopen_support" != yes ||
6492 test "$build_libtool_libs" = no; then
6493 # If there is no dlname, no dlopen support or we're linking
6494 # statically, we need to preload. We also need to preload any
6495 # dependent libraries so libltdl's deplib preloader doesn't
6496 # bomb out in the load deplibs phase.
6497 func_append dlprefiles " $lib $dependency_libs"
6498 else
6499 func_append newdlfiles " $lib"
6500 fi
6501 continue
6502 fi # $pass = dlopen
6503
6504 # We need an absolute path.
6505 case $ladir in
6506 [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;;
6507 *)
6508 abs_ladir=`cd "$ladir" && pwd`
6509 if test -z "$abs_ladir"; then
6510 func_warning "cannot determine absolute directory name of \`$ladir'"
6511 func_warning "passing it literally to the linker, although it might fail"
6512 abs_ladir="$ladir"
6513 fi
6514 ;;
6515 esac
6516 func_basename "$lib"
6517 laname="$func_basename_result"
6518
6519 # Find the relevant object directory and library name.
6520 if test "X$installed" = Xyes; then
6521 if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
6522 func_warning "library \`$lib' was moved."
6523 dir="$ladir"
6524 absdir="$abs_ladir"
6525 libdir="$abs_ladir"
6526 else
6527 dir="$lt_sysroot$libdir"
6528 absdir="$lt_sysroot$libdir"
6529 fi
6530 test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes
6531 else
6532 if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then
6533 dir="$ladir"
6534 absdir="$abs_ladir"
6535 # Remove this search path later
6536 func_append notinst_path " $abs_ladir"
6537 else
6538 dir="$ladir/$objdir"
6539 absdir="$abs_ladir/$objdir"
6540 # Remove this search path later
6541 func_append notinst_path " $abs_ladir"
6542 fi
6543 fi # $installed = yes
6544 func_stripname 'lib' '.la' "$laname"
6545 name=$func_stripname_result
6546
6547 # This library was specified with -dlpreopen.
6548 if test "$pass" = dlpreopen; then
6549 if test -z "$libdir" && test "$linkmode" = prog; then
6550 func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'"
6551 fi
6552 case "$host" in
6553 # special handling for platforms with PE-DLLs.
6554 *cygwin* | *mingw* | *cegcc* )
6555 # Linker will automatically link against shared library if both
6556 # static and shared are present. Therefore, ensure we extract
6557 # symbols from the import library if a shared library is present
6558 # (otherwise, the dlopen module name will be incorrect). We do
6559 # this by putting the import library name into $newdlprefiles.
6560 # We recover the dlopen module name by 'saving' the la file
6561 # name in a special purpose variable, and (later) extracting the
6562 # dlname from the la file.
6563 if test -n "$dlname"; then
6564 func_tr_sh "$dir/$linklib"
6565 eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname"
6566 func_append newdlprefiles " $dir/$linklib"
6567 else
6568 func_append newdlprefiles " $dir/$old_library"
6569 # Keep a list of preopened convenience libraries to check
6570 # that they are being used correctly in the link pass.
6571 test -z "$libdir" && \
6572 func_append dlpreconveniencelibs " $dir/$old_library"
6573 fi
6574 ;;
6575 * )
6576 # Prefer using a static library (so that no silly _DYNAMIC symbols
6577 # are required to link).
6578 if test -n "$old_library"; then
6579 func_append newdlprefiles " $dir/$old_library"
6580 # Keep a list of preopened convenience libraries to check
6581 # that they are being used correctly in the link pass.
6582 test -z "$libdir" && \
6583 func_append dlpreconveniencelibs " $dir/$old_library"
6584 # Otherwise, use the dlname, so that lt_dlopen finds it.
6585 elif test -n "$dlname"; then
6586 func_append newdlprefiles " $dir/$dlname"
6587 else
6588 func_append newdlprefiles " $dir/$linklib"
6589 fi
6590 ;;
6591 esac
6592 fi # $pass = dlpreopen
6593
6594 if test -z "$libdir"; then
6595 # Link the convenience library
6596 if test "$linkmode" = lib; then
6597 deplibs="$dir/$old_library $deplibs"
6598 elif test "$linkmode,$pass" = "prog,link"; then
6599 compile_deplibs="$dir/$old_library $compile_deplibs"
6600 finalize_deplibs="$dir/$old_library $finalize_deplibs"
6601 else
6602 deplibs="$lib $deplibs" # used for prog,scan pass
6603 fi
6604 continue
6605 fi
6606
6607
6608 if test "$linkmode" = prog && test "$pass" != link; then
6609 func_append newlib_search_path " $ladir"
6610 deplibs="$lib $deplibs"
6611
6612 linkalldeplibs=no
6613 if test "$link_all_deplibs" != no || test -z "$library_names" ||
6614 test "$build_libtool_libs" = no; then
6615 linkalldeplibs=yes
6616 fi
6617
6618 tmp_libs=
6619 for deplib in $dependency_libs; do
6620 case $deplib in
6621 -L*) func_stripname '-L' '' "$deplib"
6622 func_resolve_sysroot "$func_stripname_result"
6623 func_append newlib_search_path " $func_resolve_sysroot_result"
6624 ;;
6625 esac
6626 # Need to link against all dependency_libs?
6627 if test "$linkalldeplibs" = yes; then
6628 deplibs="$deplib $deplibs"
6629 else
6630 # Need to hardcode shared library paths
6631 # or/and link against static libraries
6632 newdependency_libs="$deplib $newdependency_libs"
6633 fi
6634 if $opt_preserve_dup_deps ; then
6635 case "$tmp_libs " in
6636 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6637 esac
6638 fi
6639 func_append tmp_libs " $deplib"
6640 done # for deplib
6641 continue
6642 fi # $linkmode = prog...
6643
6644 if test "$linkmode,$pass" = "prog,link"; then
6645 if test -n "$library_names" &&
6646 { { test "$prefer_static_libs" = no ||
6647 test "$prefer_static_libs,$installed" = "built,yes"; } ||
6648 test -z "$old_library"; }; then
6649 # We need to hardcode the library path
6650 if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then
6651 # Make sure the rpath contains only unique directories.
6652 case "$temp_rpath:" in
6653 *"$absdir:"*) ;;
6654 *) func_append temp_rpath "$absdir:" ;;
6655 esac
6656 fi
6657
6658 # Hardcode the library path.
6659 # Skip directories that are in the system default run-time
6660 # search path.
6661 case " $sys_lib_dlsearch_path " in
6662 *" $absdir "*) ;;
6663 *)
6664 case "$compile_rpath " in
6665 *" $absdir "*) ;;
6666 *) func_append compile_rpath " $absdir" ;;
6667 esac
6668 ;;
6669 esac
6670 case " $sys_lib_dlsearch_path " in
6671 *" $libdir "*) ;;
6672 *)
6673 case "$finalize_rpath " in
6674 *" $libdir "*) ;;
6675 *) func_append finalize_rpath " $libdir" ;;
6676 esac
6677 ;;
6678 esac
6679 fi # $linkmode,$pass = prog,link...
6680
6681 if test "$alldeplibs" = yes &&
6682 { test "$deplibs_check_method" = pass_all ||
6683 { test "$build_libtool_libs" = yes &&
6684 test -n "$library_names"; }; }; then
6685 # We only need to search for static libraries
6686 continue
6687 fi
6688 fi
6689
6690 link_static=no # Whether the deplib will be linked statically
6691 use_static_libs=$prefer_static_libs
6692 if test "$use_static_libs" = built && test "$installed" = yes; then
6693 use_static_libs=no
6694 fi
6695 if test -n "$library_names" &&
6696 { test "$use_static_libs" = no || test -z "$old_library"; }; then
6697 case $host in
6698 *cygwin* | *mingw* | *cegcc*)
6699 # No point in relinking DLLs because paths are not encoded
6700 func_append notinst_deplibs " $lib"
6701 need_relink=no
6702 ;;
6703 *)
6704 if test "$installed" = no; then
6705 func_append notinst_deplibs " $lib"
6706 need_relink=yes
6707 fi
6708 ;;
6709 esac
6710 # This is a shared library
6711
6712 # Warn about portability, can't link against -module's on some
6713 # systems (darwin). Don't bleat about dlopened modules though!
6714 dlopenmodule=""
6715 for dlpremoduletest in $dlprefiles; do
6716 if test "X$dlpremoduletest" = "X$lib"; then
6717 dlopenmodule="$dlpremoduletest"
6718 break
6719 fi
6720 done
6721 if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then
6722 echo
6723 if test "$linkmode" = prog; then
6724 $ECHO "*** Warning: Linking the executable $output against the loadable module"
6725 else
6726 $ECHO "*** Warning: Linking the shared library $output against the loadable module"
6727 fi
6728 $ECHO "*** $linklib is not portable!"
6729 fi
6730 if test "$linkmode" = lib &&
6731 test "$hardcode_into_libs" = yes; then
6732 # Hardcode the library path.
6733 # Skip directories that are in the system default run-time
6734 # search path.
6735 case " $sys_lib_dlsearch_path " in
6736 *" $absdir "*) ;;
6737 *)
6738 case "$compile_rpath " in
6739 *" $absdir "*) ;;
6740 *) func_append compile_rpath " $absdir" ;;
6741 esac
6742 ;;
6743 esac
6744 case " $sys_lib_dlsearch_path " in
6745 *" $libdir "*) ;;
6746 *)
6747 case "$finalize_rpath " in
6748 *" $libdir "*) ;;
6749 *) func_append finalize_rpath " $libdir" ;;
6750 esac
6751 ;;
6752 esac
6753 fi
6754
6755 if test -n "$old_archive_from_expsyms_cmds"; then
6756 # figure out the soname
6757 set dummy $library_names
6758 shift
6759 realname="$1"
6760 shift
6761 libname=`eval "\\$ECHO \"$libname_spec\""`
6762 # use dlname if we got it. it's perfectly good, no?
6763 if test -n "$dlname"; then
6764 soname="$dlname"
6765 elif test -n "$soname_spec"; then
6766 # bleh windows
6767 case $host in
6768 *cygwin* | mingw* | *cegcc*)
6769 func_arith $current - $age
6770 major=$func_arith_result
6771 versuffix="-$major"
6772 ;;
6773 esac
6774 eval soname=\"$soname_spec\"
6775 else
6776 soname="$realname"
6777 fi
6778
6779 # Make a new name for the extract_expsyms_cmds to use
6780 soroot="$soname"
6781 func_basename "$soroot"
6782 soname="$func_basename_result"
6783 func_stripname 'lib' '.dll' "$soname"
6784 newlib=libimp-$func_stripname_result.a
6785
6786 # If the library has no export list, then create one now
6787 if test -f "$output_objdir/$soname-def"; then :
6788 else
6789 func_verbose "extracting exported symbol list from \`$soname'"
6790 func_execute_cmds "$extract_expsyms_cmds" 'exit $?'
6791 fi
6792
6793 # Create $newlib
6794 if test -f "$output_objdir/$newlib"; then :; else
6795 func_verbose "generating import library for \`$soname'"
6796 func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?'
6797 fi
6798 # make sure the library variables are pointing to the new library
6799 dir=$output_objdir
6800 linklib=$newlib
6801 fi # test -n "$old_archive_from_expsyms_cmds"
6802
6803 if test "$linkmode" = prog || test "$opt_mode" != relink; then
6804 add_shlibpath=
6805 add_dir=
6806 add=
6807 lib_linked=yes
6808 case $hardcode_action in
6809 immediate | unsupported)
6810 if test "$hardcode_direct" = no; then
6811 add="$dir/$linklib"
6812 case $host in
6813 *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;;
6814 *-*-sysv4*uw2*) add_dir="-L$dir" ;;
6815 *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \
6816 *-*-unixware7*) add_dir="-L$dir" ;;
6817 *-*-darwin* )
6818 # if the lib is a (non-dlopened) module then we can not
6819 # link against it, someone is ignoring the earlier warnings
6820 if /usr/bin/file -L $add 2> /dev/null |
6821 $GREP ": [^:]* bundle" >/dev/null ; then
6822 if test "X$dlopenmodule" != "X$lib"; then
6823 $ECHO "*** Warning: lib $linklib is a module, not a shared library"
6824 if test -z "$old_library" ; then
6825 echo
6826 echo "*** And there doesn't seem to be a static archive available"
6827 echo "*** The link will probably fail, sorry"
6828 else
6829 add="$dir/$old_library"
6830 fi
6831 elif test -n "$old_library"; then
6832 add="$dir/$old_library"
6833 fi
6834 fi
6835 esac
6836 elif test "$hardcode_minus_L" = no; then
6837 case $host in
6838 *-*-sunos*) add_shlibpath="$dir" ;;
6839 esac
6840 add_dir="-L$dir"
6841 add="-l$name"
6842 elif test "$hardcode_shlibpath_var" = no; then
6843 add_shlibpath="$dir"
6844 add="-l$name"
6845 else
6846 lib_linked=no
6847 fi
6848 ;;
6849 relink)
6850 if test "$hardcode_direct" = yes &&
6851 test "$hardcode_direct_absolute" = no; then
6852 add="$dir/$linklib"
6853 elif test "$hardcode_minus_L" = yes; then
6854 add_dir="-L$absdir"
6855 # Try looking first in the location we're being installed to.
6856 if test -n "$inst_prefix_dir"; then
6857 case $libdir in
6858 [\\/]*)
6859 func_append add_dir " -L$inst_prefix_dir$libdir"
6860 ;;
6861 esac
6862 fi
6863 add="-l$name"
6864 elif test "$hardcode_shlibpath_var" = yes; then
6865 add_shlibpath="$dir"
6866 add="-l$name"
6867 else
6868 lib_linked=no
6869 fi
6870 ;;
6871 *) lib_linked=no ;;
6872 esac
6873
6874 if test "$lib_linked" != yes; then
6875 func_fatal_configuration "unsupported hardcode properties"
6876 fi
6877
6878 if test -n "$add_shlibpath"; then
6879 case :$compile_shlibpath: in
6880 *":$add_shlibpath:"*) ;;
6881 *) func_append compile_shlibpath "$add_shlibpath:" ;;
6882 esac
6883 fi
6884 if test "$linkmode" = prog; then
6885 test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs"
6886 test -n "$add" && compile_deplibs="$add $compile_deplibs"
6887 else
6888 test -n "$add_dir" && deplibs="$add_dir $deplibs"
6889 test -n "$add" && deplibs="$add $deplibs"
6890 if test "$hardcode_direct" != yes &&
6891 test "$hardcode_minus_L" != yes &&
6892 test "$hardcode_shlibpath_var" = yes; then
6893 case :$finalize_shlibpath: in
6894 *":$libdir:"*) ;;
6895 *) func_append finalize_shlibpath "$libdir:" ;;
6896 esac
6897 fi
6898 fi
6899 fi
6900
6901 if test "$linkmode" = prog || test "$opt_mode" = relink; then
6902 add_shlibpath=
6903 add_dir=
6904 add=
6905 # Finalize command for both is simple: just hardcode it.
6906 if test "$hardcode_direct" = yes &&
6907 test "$hardcode_direct_absolute" = no; then
6908 add="$libdir/$linklib"
6909 elif test "$hardcode_minus_L" = yes; then
6910 add_dir="-L$libdir"
6911 add="-l$name"
6912 elif test "$hardcode_shlibpath_var" = yes; then
6913 case :$finalize_shlibpath: in
6914 *":$libdir:"*) ;;
6915 *) func_append finalize_shlibpath "$libdir:" ;;
6916 esac
6917 add="-l$name"
6918 elif test "$hardcode_automatic" = yes; then
6919 if test -n "$inst_prefix_dir" &&
6920 test -f "$inst_prefix_dir$libdir/$linklib" ; then
6921 add="$inst_prefix_dir$libdir/$linklib"
6922 else
6923 add="$libdir/$linklib"
6924 fi
6925 else
6926 # We cannot seem to hardcode it, guess we'll fake it.
6927 add_dir="-L$libdir"
6928 # Try looking first in the location we're being installed to.
6929 if test -n "$inst_prefix_dir"; then
6930 case $libdir in
6931 [\\/]*)
6932 func_append add_dir " -L$inst_prefix_dir$libdir"
6933 ;;
6934 esac
6935 fi
6936 add="-l$name"
6937 fi
6938
6939 if test "$linkmode" = prog; then
6940 test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs"
6941 test -n "$add" && finalize_deplibs="$add $finalize_deplibs"
6942 else
6943 test -n "$add_dir" && deplibs="$add_dir $deplibs"
6944 test -n "$add" && deplibs="$add $deplibs"
6945 fi
6946 fi
6947 elif test "$linkmode" = prog; then
6948 # Here we assume that one of hardcode_direct or hardcode_minus_L
6949 # is not unsupported. This is valid on all known static and
6950 # shared platforms.
6951 if test "$hardcode_direct" != unsupported; then
6952 test -n "$old_library" && linklib="$old_library"
6953 compile_deplibs="$dir/$linklib $compile_deplibs"
6954 finalize_deplibs="$dir/$linklib $finalize_deplibs"
6955 else
6956 compile_deplibs="-l$name -L$dir $compile_deplibs"
6957 finalize_deplibs="-l$name -L$dir $finalize_deplibs"
6958 fi
6959 elif test "$build_libtool_libs" = yes; then
6960 # Not a shared library
6961 if test "$deplibs_check_method" != pass_all; then
6962 # We're trying link a shared library against a static one
6963 # but the system doesn't support it.
6964
6965 # Just print a warning and add the library to dependency_libs so
6966 # that the program can be linked against the static library.
6967 echo
6968 $ECHO "*** Warning: This system can not link to static lib archive $lib."
6969 echo "*** I have the capability to make that library automatically link in when"
6970 echo "*** you link to this library. But I can only do this if you have a"
6971 echo "*** shared version of the library, which you do not appear to have."
6972 if test "$module" = yes; then
6973 echo "*** But as you try to build a module library, libtool will still create "
6974 echo "*** a static module, that should work as long as the dlopening application"
6975 echo "*** is linked with the -dlopen flag to resolve symbols at runtime."
6976 if test -z "$global_symbol_pipe"; then
6977 echo
6978 echo "*** However, this would only work if libtool was able to extract symbol"
6979 echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
6980 echo "*** not find such a program. So, this module is probably useless."
6981 echo "*** \`nm' from GNU binutils and a full rebuild may help."
6982 fi
6983 if test "$build_old_libs" = no; then
6984 build_libtool_libs=module
6985 build_old_libs=yes
6986 else
6987 build_libtool_libs=no
6988 fi
6989 fi
6990 else
6991 deplibs="$dir/$old_library $deplibs"
6992 link_static=yes
6993 fi
6994 fi # link shared/static library?
6995
6996 if test "$linkmode" = lib; then
6997 if test -n "$dependency_libs" &&
6998 { test "$hardcode_into_libs" != yes ||
6999 test "$build_old_libs" = yes ||
7000 test "$link_static" = yes; }; then
7001 # Extract -R from dependency_libs
7002 temp_deplibs=
7003 for libdir in $dependency_libs; do
7004 case $libdir in
7005 -R*) func_stripname '-R' '' "$libdir"
7006 temp_xrpath=$func_stripname_result
7007 case " $xrpath " in
7008 *" $temp_xrpath "*) ;;
7009 *) func_append xrpath " $temp_xrpath";;
7010 esac;;
7011 *) func_append temp_deplibs " $libdir";;
7012 esac
7013 done
7014 dependency_libs="$temp_deplibs"
7015 fi
7016
7017 func_append newlib_search_path " $absdir"
7018 # Link against this library
7019 test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
7020 # ... and its dependency_libs
7021 tmp_libs=
7022 for deplib in $dependency_libs; do
7023 newdependency_libs="$deplib $newdependency_libs"
7024 case $deplib in
7025 -L*) func_stripname '-L' '' "$deplib"
7026 func_resolve_sysroot "$func_stripname_result";;
7027 *) func_resolve_sysroot "$deplib" ;;
7028 esac
7029 if $opt_preserve_dup_deps ; then
7030 case "$tmp_libs " in
7031 *" $func_resolve_sysroot_result "*)
7032 func_append specialdeplibs " $func_resolve_sysroot_result" ;;
7033 esac
7034 fi
7035 func_append tmp_libs " $func_resolve_sysroot_result"
7036 done
7037
7038 if test "$link_all_deplibs" != no; then
7039 # Add the search paths of all dependency libraries
7040 for deplib in $dependency_libs; do
7041 path=
7042 case $deplib in
7043 -L*) path="$deplib" ;;
7044 *.la)
7045 func_resolve_sysroot "$deplib"
7046 deplib=$func_resolve_sysroot_result
7047 func_dirname "$deplib" "" "."
7048 dir=$func_dirname_result
7049 # We need an absolute path.
7050 case $dir in
7051 [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;;
7052 *)
7053 absdir=`cd "$dir" && pwd`
7054 if test -z "$absdir"; then
7055 func_warning "cannot determine absolute directory name of \`$dir'"
7056 absdir="$dir"
7057 fi
7058 ;;
7059 esac
7060 if $GREP "^installed=no" $deplib > /dev/null; then
7061 case $host in
7062 *-*-darwin*)
7063 depdepl=
7064 eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
7065 if test -n "$deplibrary_names" ; then
7066 for tmp in $deplibrary_names ; do
7067 depdepl=$tmp
7068 done
7069 if test -f "$absdir/$objdir/$depdepl" ; then
7070 depdepl="$absdir/$objdir/$depdepl"
7071 darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
7072 if test -z "$darwin_install_name"; then
7073 darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
7074 fi
7075 func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
7076 func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}"
7077 path=
7078 fi
7079 fi
7080 ;;
7081 *)
7082 path="-L$absdir/$objdir"
7083 ;;
7084 esac
7085 else
7086 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
7087 test -z "$libdir" && \
7088 func_fatal_error "\`$deplib' is not a valid libtool archive"
7089 test "$absdir" != "$libdir" && \
7090 func_warning "\`$deplib' seems to be moved"
7091
7092 path="-L$absdir"
7093 fi
7094 ;;
7095 esac
7096 case " $deplibs " in
7097 *" $path "*) ;;
7098 *) deplibs="$path $deplibs" ;;
7099 esac
7100 done
7101 fi # link_all_deplibs != no
7102 fi # linkmode = lib
7103 done # for deplib in $libs
7104 if test "$pass" = link; then
7105 if test "$linkmode" = "prog"; then
7106 compile_deplibs="$new_inherited_linker_flags $compile_deplibs"
7107 finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs"
7108 else
7109 compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
7110 fi
7111 fi
7112 dependency_libs="$newdependency_libs"
7113 if test "$pass" = dlpreopen; then
7114 # Link the dlpreopened libraries before other libraries
7115 for deplib in $save_deplibs; do
7116 deplibs="$deplib $deplibs"
7117 done
7118 fi
7119 if test "$pass" != dlopen; then
7120 if test "$pass" != conv; then
7121 # Make sure lib_search_path contains only unique directories.
7122 lib_search_path=
7123 for dir in $newlib_search_path; do
7124 case "$lib_search_path " in
7125 *" $dir "*) ;;
7126 *) func_append lib_search_path " $dir" ;;
7127 esac
7128 done
7129 newlib_search_path=
7130 fi
7131
7132 if test "$linkmode,$pass" != "prog,link"; then
7133 vars="deplibs"
7134 else
7135 vars="compile_deplibs finalize_deplibs"
7136 fi
7137 for var in $vars dependency_libs; do
7138 # Add libraries to $var in reverse order
7139 eval tmp_libs=\"\$$var\"
7140 new_libs=
7141 for deplib in $tmp_libs; do
7142 # FIXME: Pedantically, this is the right thing to do, so
7143 # that some nasty dependency loop isn't accidentally
7144 # broken:
7145 #new_libs="$deplib $new_libs"
7146 # Pragmatically, this seems to cause very few problems in
7147 # practice:
7148 case $deplib in
7149 -L*) new_libs="$deplib $new_libs" ;;
7150 -R*) ;;
7151 *)
7152 # And here is the reason: when a library appears more
7153 # than once as an explicit dependence of a library, or
7154 # is implicitly linked in more than once by the
7155 # compiler, it is considered special, and multiple
7156 # occurrences thereof are not removed. Compare this
7157 # with having the same library being listed as a
7158 # dependency of multiple other libraries: in this case,
7159 # we know (pedantically, we assume) the library does not
7160 # need to be listed more than once, so we keep only the
7161 # last copy. This is not always right, but it is rare
7162 # enough that we require users that really mean to play
7163 # such unportable linking tricks to link the library
7164 # using -Wl,-lname, so that libtool does not consider it
7165 # for duplicate removal.
7166 case " $specialdeplibs " in
7167 *" $deplib "*) new_libs="$deplib $new_libs" ;;
7168 *)
7169 case " $new_libs " in
7170 *" $deplib "*) ;;
7171 *) new_libs="$deplib $new_libs" ;;
7172 esac
7173 ;;
7174 esac
7175 ;;
7176 esac
7177 done
7178 tmp_libs=
7179 for deplib in $new_libs; do
7180 case $deplib in
7181 -L*)
7182 case " $tmp_libs " in
7183 *" $deplib "*) ;;
7184 *) func_append tmp_libs " $deplib" ;;
7185 esac
7186 ;;
7187 *) func_append tmp_libs " $deplib" ;;
7188 esac
7189 done
7190 eval $var=\"$tmp_libs\"
7191 done # for var
7192 fi
7193 # Last step: remove runtime libs from dependency_libs
7194 # (they stay in deplibs)
7195 tmp_libs=
7196 for i in $dependency_libs ; do
7197 case " $predeps $postdeps $compiler_lib_search_path " in
7198 *" $i "*)
7199 i=""
7200 ;;
7201 esac
7202 if test -n "$i" ; then
7203 func_append tmp_libs " $i"
7204 fi
7205 done
7206 dependency_libs=$tmp_libs
7207 done # for pass
7208 if test "$linkmode" = prog; then
7209 dlfiles="$newdlfiles"
7210 fi
7211 if test "$linkmode" = prog || test "$linkmode" = lib; then
7212 dlprefiles="$newdlprefiles"
7213 fi
7214
7215 case $linkmode in
7216 oldlib)
7217 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
7218 func_warning "\`-dlopen' is ignored for archives"
7219 fi
7220
7221 case " $deplibs" in
7222 *\ -l* | *\ -L*)
7223 func_warning "\`-l' and \`-L' are ignored for archives" ;;
7224 esac
7225
7226 test -n "$rpath" && \
7227 func_warning "\`-rpath' is ignored for archives"
7228
7229 test -n "$xrpath" && \
7230 func_warning "\`-R' is ignored for archives"
7231
7232 test -n "$vinfo" && \
7233 func_warning "\`-version-info/-version-number' is ignored for archives"
7234
7235 test -n "$release" && \
7236 func_warning "\`-release' is ignored for archives"
7237
7238 test -n "$export_symbols$export_symbols_regex" && \
7239 func_warning "\`-export-symbols' is ignored for archives"
7240
7241 # Now set the variables for building old libraries.
7242 build_libtool_libs=no
7243 oldlibs="$output"
7244 func_append objs "$old_deplibs"
7245 ;;
7246
7247 lib)
7248 # Make sure we only generate libraries of the form `libNAME.la'.
7249 case $outputname in
7250 lib*)
7251 func_stripname 'lib' '.la' "$outputname"
7252 name=$func_stripname_result
7253 eval shared_ext=\"$shrext_cmds\"
7254 eval libname=\"$libname_spec\"
7255 ;;
7256 *)
7257 test "$module" = no && \
7258 func_fatal_help "libtool library \`$output' must begin with \`lib'"
7259
7260 if test "$need_lib_prefix" != no; then
7261 # Add the "lib" prefix for modules if required
7262 func_stripname '' '.la' "$outputname"
7263 name=$func_stripname_result
7264 eval shared_ext=\"$shrext_cmds\"
7265 eval libname=\"$libname_spec\"
7266 else
7267 func_stripname '' '.la' "$outputname"
7268 libname=$func_stripname_result
7269 fi
7270 ;;
7271 esac
7272
7273 if test -n "$objs"; then
7274 if test "$deplibs_check_method" != pass_all; then
7275 func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs"
7276 else
7277 echo
7278 $ECHO "*** Warning: Linking the shared library $output against the non-libtool"
7279 $ECHO "*** objects $objs is not portable!"
7280 func_append libobjs " $objs"
7281 fi
7282 fi
7283
7284 test "$dlself" != no && \
7285 func_warning "\`-dlopen self' is ignored for libtool libraries"
7286
7287 set dummy $rpath
7288 shift
7289 test "$#" -gt 1 && \
7290 func_warning "ignoring multiple \`-rpath's for a libtool library"
7291
7292 install_libdir="$1"
7293
7294 oldlibs=
7295 if test -z "$rpath"; then
7296 if test "$build_libtool_libs" = yes; then
7297 # Building a libtool convenience library.
7298 # Some compilers have problems with a `.al' extension so
7299 # convenience libraries should have the same extension an
7300 # archive normally would.
7301 oldlibs="$output_objdir/$libname.$libext $oldlibs"
7302 build_libtool_libs=convenience
7303 build_old_libs=yes
7304 fi
7305
7306 test -n "$vinfo" && \
7307 func_warning "\`-version-info/-version-number' is ignored for convenience libraries"
7308
7309 test -n "$release" && \
7310 func_warning "\`-release' is ignored for convenience libraries"
7311 else
7312
7313 # Parse the version information argument.
7314 save_ifs="$IFS"; IFS=':'
7315 set dummy $vinfo 0 0 0
7316 shift
7317 IFS="$save_ifs"
7318
7319 test -n "$7" && \
7320 func_fatal_help "too many parameters to \`-version-info'"
7321
7322 # convert absolute version numbers to libtool ages
7323 # this retains compatibility with .la files and attempts
7324 # to make the code below a bit more comprehensible
7325
7326 case $vinfo_number in
7327 yes)
7328 number_major="$1"
7329 number_minor="$2"
7330 number_revision="$3"
7331 #
7332 # There are really only two kinds -- those that
7333 # use the current revision as the major version
7334 # and those that subtract age and use age as
7335 # a minor version. But, then there is irix
7336 # which has an extra 1 added just for fun
7337 #
7338 case $version_type in
7339 # correct linux to gnu/linux during the next big refactor
7340 darwin|linux|osf|windows|none)
7341 func_arith $number_major + $number_minor
7342 current=$func_arith_result
7343 age="$number_minor"
7344 revision="$number_revision"
7345 ;;
7346 freebsd-aout|freebsd-elf|qnx|sunos)
7347 current="$number_major"
7348 revision="$number_minor"
7349 age="0"
7350 ;;
7351 irix|nonstopux)
7352 func_arith $number_major + $number_minor
7353 current=$func_arith_result
7354 age="$number_minor"
7355 revision="$number_minor"
7356 lt_irix_increment=no
7357 ;;
7358 *)
7359 func_fatal_configuration "$modename: unknown library version type \`$version_type'"
7360 ;;
7361 esac
7362 ;;
7363 no)
7364 current="$1"
7365 revision="$2"
7366 age="$3"
7367 ;;
7368 esac
7369
7370 # Check that each of the things are valid numbers.
7371 case $current in
7372 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
7373 *)
7374 func_error "CURRENT \`$current' must be a nonnegative integer"
7375 func_fatal_error "\`$vinfo' is not valid version information"
7376 ;;
7377 esac
7378
7379 case $revision in
7380 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
7381 *)
7382 func_error "REVISION \`$revision' must be a nonnegative integer"
7383 func_fatal_error "\`$vinfo' is not valid version information"
7384 ;;
7385 esac
7386
7387 case $age in
7388 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
7389 *)
7390 func_error "AGE \`$age' must be a nonnegative integer"
7391 func_fatal_error "\`$vinfo' is not valid version information"
7392 ;;
7393 esac
7394
7395 if test "$age" -gt "$current"; then
7396 func_error "AGE \`$age' is greater than the current interface number \`$current'"
7397 func_fatal_error "\`$vinfo' is not valid version information"
7398 fi
7399
7400 # Calculate the version variables.
7401 major=
7402 versuffix=
7403 verstring=
7404 case $version_type in
7405 none) ;;
7406
7407 darwin)
7408 # Like Linux, but with the current version available in
7409 # verstring for coding it into the library header
7410 func_arith $current - $age
7411 major=.$func_arith_result
7412 versuffix="$major.$age.$revision"
7413 # Darwin ld doesn't like 0 for these options...
7414 func_arith $current + 1
7415 minor_current=$func_arith_result
7416 xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision"
7417 verstring="-compatibility_version $minor_current -current_version $minor_current.$revision"
7418 ;;
7419
7420 freebsd-aout)
7421 major=".$current"
7422 versuffix=".$current.$revision";
7423 ;;
7424
7425 freebsd-elf)
7426 major=".$current"
7427 versuffix=".$current"
7428 ;;
7429
7430 irix | nonstopux)
7431 if test "X$lt_irix_increment" = "Xno"; then
7432 func_arith $current - $age
7433 else
7434 func_arith $current - $age + 1
7435 fi
7436 major=$func_arith_result
7437
7438 case $version_type in
7439 nonstopux) verstring_prefix=nonstopux ;;
7440 *) verstring_prefix=sgi ;;
7441 esac
7442 verstring="$verstring_prefix$major.$revision"
7443
7444 # Add in all the interfaces that we are compatible with.
7445 loop=$revision
7446 while test "$loop" -ne 0; do
7447 func_arith $revision - $loop
7448 iface=$func_arith_result
7449 func_arith $loop - 1
7450 loop=$func_arith_result
7451 verstring="$verstring_prefix$major.$iface:$verstring"
7452 done
7453
7454 # Before this point, $major must not contain `.'.
7455 major=.$major
7456 versuffix="$major.$revision"
7457 ;;
7458
7459 linux) # correct to gnu/linux during the next big refactor
7460 func_arith $current - $age
7461 major=.$func_arith_result
7462 versuffix="$major.$age.$revision"
7463 ;;
7464
7465 osf)
7466 func_arith $current - $age
7467 major=.$func_arith_result
7468 versuffix=".$current.$age.$revision"
7469 verstring="$current.$age.$revision"
7470
7471 # Add in all the interfaces that we are compatible with.
7472 loop=$age
7473 while test "$loop" -ne 0; do
7474 func_arith $current - $loop
7475 iface=$func_arith_result
7476 func_arith $loop - 1
7477 loop=$func_arith_result
7478 verstring="$verstring:${iface}.0"
7479 done
7480
7481 # Make executables depend on our current version.
7482 func_append verstring ":${current}.0"
7483 ;;
7484
7485 qnx)
7486 major=".$current"
7487 versuffix=".$current"
7488 ;;
7489
7490 sunos)
7491 major=".$current"
7492 versuffix=".$current.$revision"
7493 ;;
7494
7495 windows)
7496 # Use '-' rather than '.', since we only want one
7497 # extension on DOS 8.3 filesystems.
7498 func_arith $current - $age
7499 major=$func_arith_result
7500 versuffix="-$major"
7501 ;;
7502
7503 *)
7504 func_fatal_configuration "unknown library version type \`$version_type'"
7505 ;;
7506 esac
7507
7508 # Clear the version info if we defaulted, and they specified a release.
7509 if test -z "$vinfo" && test -n "$release"; then
7510 major=
7511 case $version_type in
7512 darwin)
7513 # we can't check for "0.0" in archive_cmds due to quoting
7514 # problems, so we reset it completely
7515 verstring=
7516 ;;
7517 *)
7518 verstring="0.0"
7519 ;;
7520 esac
7521 if test "$need_version" = no; then
7522 versuffix=
7523 else
7524 versuffix=".0.0"
7525 fi
7526 fi
7527
7528 # Remove version info from name if versioning should be avoided
7529 if test "$avoid_version" = yes && test "$need_version" = no; then
7530 major=
7531 versuffix=
7532 verstring=""
7533 fi
7534
7535 # Check to see if the archive will have undefined symbols.
7536 if test "$allow_undefined" = yes; then
7537 if test "$allow_undefined_flag" = unsupported; then
7538 func_warning "undefined symbols not allowed in $host shared libraries"
7539 build_libtool_libs=no
7540 build_old_libs=yes
7541 fi
7542 else
7543 # Don't allow undefined symbols.
7544 allow_undefined_flag="$no_undefined_flag"
7545 fi
7546
7547 fi
7548
7549 func_generate_dlsyms "$libname" "$libname" "yes"
7550 func_append libobjs " $symfileobj"
7551 test "X$libobjs" = "X " && libobjs=
7552
7553 if test "$opt_mode" != relink; then
7554 # Remove our outputs, but don't remove object files since they
7555 # may have been created when compiling PIC objects.
7556 removelist=
7557 tempremovelist=`$ECHO "$output_objdir/*"`
7558 for p in $tempremovelist; do
7559 case $p in
7560 *.$objext | *.gcno)
7561 ;;
7562 $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*)
7563 if test "X$precious_files_regex" != "X"; then
7564 if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1
7565 then
7566 continue
7567 fi
7568 fi
7569 func_append removelist " $p"
7570 ;;
7571 *) ;;
7572 esac
7573 done
7574 test -n "$removelist" && \
7575 func_show_eval "${RM}r \$removelist"
7576 fi
7577
7578 # Now set the variables for building old libraries.
7579 if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then
7580 func_append oldlibs " $output_objdir/$libname.$libext"
7581
7582 # Transform .lo files to .o files.
7583 oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP`
7584 fi
7585
7586 # Eliminate all temporary directories.
7587 #for path in $notinst_path; do
7588 # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"`
7589 # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"`
7590 # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"`
7591 #done
7592
7593 if test -n "$xrpath"; then
7594 # If the user specified any rpath flags, then add them.
7595 temp_xrpath=
7596 for libdir in $xrpath; do
7597 func_replace_sysroot "$libdir"
7598 func_append temp_xrpath " -R$func_replace_sysroot_result"
7599 case "$finalize_rpath " in
7600 *" $libdir "*) ;;
7601 *) func_append finalize_rpath " $libdir" ;;
7602 esac
7603 done
7604 if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then
7605 dependency_libs="$temp_xrpath $dependency_libs"
7606 fi
7607 fi
7608
7609 # Make sure dlfiles contains only unique files that won't be dlpreopened
7610 old_dlfiles="$dlfiles"
7611 dlfiles=
7612 for lib in $old_dlfiles; do
7613 case " $dlprefiles $dlfiles " in
7614 *" $lib "*) ;;
7615 *) func_append dlfiles " $lib" ;;
7616 esac
7617 done
7618
7619 # Make sure dlprefiles contains only unique files
7620 old_dlprefiles="$dlprefiles"
7621 dlprefiles=
7622 for lib in $old_dlprefiles; do
7623 case "$dlprefiles " in
7624 *" $lib "*) ;;
7625 *) func_append dlprefiles " $lib" ;;
7626 esac
7627 done
7628
7629 if test "$build_libtool_libs" = yes; then
7630 if test -n "$rpath"; then
7631 case $host in
7632 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*)
7633 # these systems don't actually have a c library (as such)!
7634 ;;
7635 *-*-rhapsody* | *-*-darwin1.[012])
7636 # Rhapsody C library is in the System framework
7637 func_append deplibs " System.ltframework"
7638 ;;
7639 *-*-netbsd*)
7640 # Don't link with libc until the a.out ld.so is fixed.
7641 ;;
7642 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
7643 # Do not include libc due to us having libc/libc_r.
7644 ;;
7645 *-*-sco3.2v5* | *-*-sco5v6*)
7646 # Causes problems with __ctype
7647 ;;
7648 *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
7649 # Compiler inserts libc in the correct place for threads to work
7650 ;;
7651 *)
7652 # Add libc to deplibs on all other systems if necessary.
7653 if test "$build_libtool_need_lc" = "yes"; then
7654 func_append deplibs " -lc"
7655 fi
7656 ;;
7657 esac
7658 fi
7659
7660 # Transform deplibs into only deplibs that can be linked in shared.
7661 name_save=$name
7662 libname_save=$libname
7663 release_save=$release
7664 versuffix_save=$versuffix
7665 major_save=$major
7666 # I'm not sure if I'm treating the release correctly. I think
7667 # release should show up in the -l (ie -lgmp5) so we don't want to
7668 # add it in twice. Is that correct?
7669 release=""
7670 versuffix=""
7671 major=""
7672 newdeplibs=
7673 droppeddeps=no
7674 case $deplibs_check_method in
7675 pass_all)
7676 # Don't check for shared/static. Everything works.
7677 # This might be a little naive. We might want to check
7678 # whether the library exists or not. But this is on
7679 # osf3 & osf4 and I'm not really sure... Just
7680 # implementing what was already the behavior.
7681 newdeplibs=$deplibs
7682 ;;
7683 test_compile)
7684 # This code stresses the "libraries are programs" paradigm to its
7685 # limits. Maybe even breaks it. We compile a program, linking it
7686 # against the deplibs as a proxy for the library. Then we can check
7687 # whether they linked in statically or dynamically with ldd.
7688 $opt_dry_run || $RM conftest.c
7689 cat > conftest.c <<EOF
7690 int main() { return 0; }
7691 EOF
7692 $opt_dry_run || $RM conftest
7693 if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then
7694 ldd_output=`ldd conftest`
7695 for i in $deplibs; do
7696 case $i in
7697 -l*)
7698 func_stripname -l '' "$i"
7699 name=$func_stripname_result
7700 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7701 case " $predeps $postdeps " in
7702 *" $i "*)
7703 func_append newdeplibs " $i"
7704 i=""
7705 ;;
7706 esac
7707 fi
7708 if test -n "$i" ; then
7709 libname=`eval "\\$ECHO \"$libname_spec\""`
7710 deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
7711 set dummy $deplib_matches; shift
7712 deplib_match=$1
7713 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
7714 func_append newdeplibs " $i"
7715 else
7716 droppeddeps=yes
7717 echo
7718 $ECHO "*** Warning: dynamic linker does not accept needed library $i."
7719 echo "*** I have the capability to make that library automatically link in when"
7720 echo "*** you link to this library. But I can only do this if you have a"
7721 echo "*** shared version of the library, which I believe you do not have"
7722 echo "*** because a test_compile did reveal that the linker did not use it for"
7723 echo "*** its dynamic dependency list that programs get resolved with at runtime."
7724 fi
7725 fi
7726 ;;
7727 *)
7728 func_append newdeplibs " $i"
7729 ;;
7730 esac
7731 done
7732 else
7733 # Error occurred in the first compile. Let's try to salvage
7734 # the situation: Compile a separate program for each library.
7735 for i in $deplibs; do
7736 case $i in
7737 -l*)
7738 func_stripname -l '' "$i"
7739 name=$func_stripname_result
7740 $opt_dry_run || $RM conftest
7741 if $LTCC $LTCFLAGS -o conftest conftest.c $i; then
7742 ldd_output=`ldd conftest`
7743 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7744 case " $predeps $postdeps " in
7745 *" $i "*)
7746 func_append newdeplibs " $i"
7747 i=""
7748 ;;
7749 esac
7750 fi
7751 if test -n "$i" ; then
7752 libname=`eval "\\$ECHO \"$libname_spec\""`
7753 deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
7754 set dummy $deplib_matches; shift
7755 deplib_match=$1
7756 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
7757 func_append newdeplibs " $i"
7758 else
7759 droppeddeps=yes
7760 echo
7761 $ECHO "*** Warning: dynamic linker does not accept needed library $i."
7762 echo "*** I have the capability to make that library automatically link in when"
7763 echo "*** you link to this library. But I can only do this if you have a"
7764 echo "*** shared version of the library, which you do not appear to have"
7765 echo "*** because a test_compile did reveal that the linker did not use this one"
7766 echo "*** as a dynamic dependency that programs can get resolved with at runtime."
7767 fi
7768 fi
7769 else
7770 droppeddeps=yes
7771 echo
7772 $ECHO "*** Warning! Library $i is needed by this library but I was not able to"
7773 echo "*** make it link in! You will probably need to install it or some"
7774 echo "*** library that it depends on before this library will be fully"
7775 echo "*** functional. Installing it before continuing would be even better."
7776 fi
7777 ;;
7778 *)
7779 func_append newdeplibs " $i"
7780 ;;
7781 esac
7782 done
7783 fi
7784 ;;
7785 file_magic*)
7786 set dummy $deplibs_check_method; shift
7787 file_magic_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
7788 for a_deplib in $deplibs; do
7789 case $a_deplib in
7790 -l*)
7791 func_stripname -l '' "$a_deplib"
7792 name=$func_stripname_result
7793 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7794 case " $predeps $postdeps " in
7795 *" $a_deplib "*)
7796 func_append newdeplibs " $a_deplib"
7797 a_deplib=""
7798 ;;
7799 esac
7800 fi
7801 if test -n "$a_deplib" ; then
7802 libname=`eval "\\$ECHO \"$libname_spec\""`
7803 if test -n "$file_magic_glob"; then
7804 libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob`
7805 else
7806 libnameglob=$libname
7807 fi
7808 test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob`
7809 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
7810 if test "$want_nocaseglob" = yes; then
7811 shopt -s nocaseglob
7812 potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
7813 $nocaseglob
7814 else
7815 potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
7816 fi
7817 for potent_lib in $potential_libs; do
7818 # Follow soft links.
7819 if ls -lLd "$potent_lib" 2>/dev/null |
7820 $GREP " -> " >/dev/null; then
7821 continue
7822 fi
7823 # The statement above tries to avoid entering an
7824 # endless loop below, in case of cyclic links.
7825 # We might still enter an endless loop, since a link
7826 # loop can be closed while we follow links,
7827 # but so what?
7828 potlib="$potent_lib"
7829 while test -h "$potlib" 2>/dev/null; do
7830 potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'`
7831 case $potliblink in
7832 [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";;
7833 *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";;
7834 esac
7835 done
7836 if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
7837 $SED -e 10q |
7838 $EGREP "$file_magic_regex" > /dev/null; then
7839 func_append newdeplibs " $a_deplib"
7840 a_deplib=""
7841 break 2
7842 fi
7843 done
7844 done
7845 fi
7846 if test -n "$a_deplib" ; then
7847 droppeddeps=yes
7848 echo
7849 $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
7850 echo "*** I have the capability to make that library automatically link in when"
7851 echo "*** you link to this library. But I can only do this if you have a"
7852 echo "*** shared version of the library, which you do not appear to have"
7853 echo "*** because I did check the linker path looking for a file starting"
7854 if test -z "$potlib" ; then
7855 $ECHO "*** with $libname but no candidates were found. (...for file magic test)"
7856 else
7857 $ECHO "*** with $libname and none of the candidates passed a file format test"
7858 $ECHO "*** using a file magic. Last file checked: $potlib"
7859 fi
7860 fi
7861 ;;
7862 *)
7863 # Add a -L argument.
7864 func_append newdeplibs " $a_deplib"
7865 ;;
7866 esac
7867 done # Gone through all deplibs.
7868 ;;
7869 match_pattern*)
7870 set dummy $deplibs_check_method; shift
7871 match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
7872 for a_deplib in $deplibs; do
7873 case $a_deplib in
7874 -l*)
7875 func_stripname -l '' "$a_deplib"
7876 name=$func_stripname_result
7877 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7878 case " $predeps $postdeps " in
7879 *" $a_deplib "*)
7880 func_append newdeplibs " $a_deplib"
7881 a_deplib=""
7882 ;;
7883 esac
7884 fi
7885 if test -n "$a_deplib" ; then
7886 libname=`eval "\\$ECHO \"$libname_spec\""`
7887 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
7888 potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
7889 for potent_lib in $potential_libs; do
7890 potlib="$potent_lib" # see symlink-check above in file_magic test
7891 if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \
7892 $EGREP "$match_pattern_regex" > /dev/null; then
7893 func_append newdeplibs " $a_deplib"
7894 a_deplib=""
7895 break 2
7896 fi
7897 done
7898 done
7899 fi
7900 if test -n "$a_deplib" ; then
7901 droppeddeps=yes
7902 echo
7903 $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
7904 echo "*** I have the capability to make that library automatically link in when"
7905 echo "*** you link to this library. But I can only do this if you have a"
7906 echo "*** shared version of the library, which you do not appear to have"
7907 echo "*** because I did check the linker path looking for a file starting"
7908 if test -z "$potlib" ; then
7909 $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)"
7910 else
7911 $ECHO "*** with $libname and none of the candidates passed a file format test"
7912 $ECHO "*** using a regex pattern. Last file checked: $potlib"
7913 fi
7914 fi
7915 ;;
7916 *)
7917 # Add a -L argument.
7918 func_append newdeplibs " $a_deplib"
7919 ;;
7920 esac
7921 done # Gone through all deplibs.
7922 ;;
7923 none | unknown | *)
7924 newdeplibs=""
7925 tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'`
7926 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7927 for i in $predeps $postdeps ; do
7928 # can't use Xsed below, because $i might contain '/'
7929 tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"`
7930 done
7931 fi
7932 case $tmp_deplibs in
7933 *[!\ \ ]*)
7934 echo
7935 if test "X$deplibs_check_method" = "Xnone"; then
7936 echo "*** Warning: inter-library dependencies are not supported in this platform."
7937 else
7938 echo "*** Warning: inter-library dependencies are not known to be supported."
7939 fi
7940 echo "*** All declared inter-library dependencies are being dropped."
7941 droppeddeps=yes
7942 ;;
7943 esac
7944 ;;
7945 esac
7946 versuffix=$versuffix_save
7947 major=$major_save
7948 release=$release_save
7949 libname=$libname_save
7950 name=$name_save
7951
7952 case $host in
7953 *-*-rhapsody* | *-*-darwin1.[012])
7954 # On Rhapsody replace the C library with the System framework
7955 newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'`
7956 ;;
7957 esac
7958
7959 if test "$droppeddeps" = yes; then
7960 if test "$module" = yes; then
7961 echo
7962 echo "*** Warning: libtool could not satisfy all declared inter-library"
7963 $ECHO "*** dependencies of module $libname. Therefore, libtool will create"
7964 echo "*** a static module, that should work as long as the dlopening"
7965 echo "*** application is linked with the -dlopen flag."
7966 if test -z "$global_symbol_pipe"; then
7967 echo
7968 echo "*** However, this would only work if libtool was able to extract symbol"
7969 echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
7970 echo "*** not find such a program. So, this module is probably useless."
7971 echo "*** \`nm' from GNU binutils and a full rebuild may help."
7972 fi
7973 if test "$build_old_libs" = no; then
7974 oldlibs="$output_objdir/$libname.$libext"
7975 build_libtool_libs=module
7976 build_old_libs=yes
7977 else
7978 build_libtool_libs=no
7979 fi
7980 else
7981 echo "*** The inter-library dependencies that have been dropped here will be"
7982 echo "*** automatically added whenever a program is linked with this library"
7983 echo "*** or is declared to -dlopen it."
7984
7985 if test "$allow_undefined" = no; then
7986 echo
7987 echo "*** Since this library must not contain undefined symbols,"
7988 echo "*** because either the platform does not support them or"
7989 echo "*** it was explicitly requested with -no-undefined,"
7990 echo "*** libtool will only create a static version of it."
7991 if test "$build_old_libs" = no; then
7992 oldlibs="$output_objdir/$libname.$libext"
7993 build_libtool_libs=module
7994 build_old_libs=yes
7995 else
7996 build_libtool_libs=no
7997 fi
7998 fi
7999 fi
8000 fi
8001 # Done checking deplibs!
8002 deplibs=$newdeplibs
8003 fi
8004 # Time to change all our "foo.ltframework" stuff back to "-framework foo"
8005 case $host in
8006 *-*-darwin*)
8007 newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8008 new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8009 deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8010 ;;
8011 esac
8012
8013 # move library search paths that coincide with paths to not yet
8014 # installed libraries to the beginning of the library search list
8015 new_libs=
8016 for path in $notinst_path; do
8017 case " $new_libs " in
8018 *" -L$path/$objdir "*) ;;
8019 *)
8020 case " $deplibs " in
8021 *" -L$path/$objdir "*)
8022 func_append new_libs " -L$path/$objdir" ;;
8023 esac
8024 ;;
8025 esac
8026 done
8027 for deplib in $deplibs; do
8028 case $deplib in
8029 -L*)
8030 case " $new_libs " in
8031 *" $deplib "*) ;;
8032 *) func_append new_libs " $deplib" ;;
8033 esac
8034 ;;
8035 *) func_append new_libs " $deplib" ;;
8036 esac
8037 done
8038 deplibs="$new_libs"
8039
8040 # All the library-specific variables (install_libdir is set above).
8041 library_names=
8042 old_library=
8043 dlname=
8044
8045 # Test again, we may have decided not to build it any more
8046 if test "$build_libtool_libs" = yes; then
8047 # Remove ${wl} instances when linking with ld.
8048 # FIXME: should test the right _cmds variable.
8049 case $archive_cmds in
8050 *\$LD\ *) wl= ;;
8051 esac
8052 if test "$hardcode_into_libs" = yes; then
8053 # Hardcode the library paths
8054 hardcode_libdirs=
8055 dep_rpath=
8056 rpath="$finalize_rpath"
8057 test "$opt_mode" != relink && rpath="$compile_rpath$rpath"
8058 for libdir in $rpath; do
8059 if test -n "$hardcode_libdir_flag_spec"; then
8060 if test -n "$hardcode_libdir_separator"; then
8061 func_replace_sysroot "$libdir"
8062 libdir=$func_replace_sysroot_result
8063 if test -z "$hardcode_libdirs"; then
8064 hardcode_libdirs="$libdir"
8065 else
8066 # Just accumulate the unique libdirs.
8067 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
8068 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
8069 ;;
8070 *)
8071 func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
8072 ;;
8073 esac
8074 fi
8075 else
8076 eval flag=\"$hardcode_libdir_flag_spec\"
8077 func_append dep_rpath " $flag"
8078 fi
8079 elif test -n "$runpath_var"; then
8080 case "$perm_rpath " in
8081 *" $libdir "*) ;;
8082 *) func_append perm_rpath " $libdir" ;;
8083 esac
8084 fi
8085 done
8086 # Substitute the hardcoded libdirs into the rpath.
8087 if test -n "$hardcode_libdir_separator" &&
8088 test -n "$hardcode_libdirs"; then
8089 libdir="$hardcode_libdirs"
8090 eval "dep_rpath=\"$hardcode_libdir_flag_spec\""
8091 fi
8092 if test -n "$runpath_var" && test -n "$perm_rpath"; then
8093 # We should set the runpath_var.
8094 rpath=
8095 for dir in $perm_rpath; do
8096 func_append rpath "$dir:"
8097 done
8098 eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var"
8099 fi
8100 test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs"
8101 fi
8102
8103 shlibpath="$finalize_shlibpath"
8104 test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
8105 if test -n "$shlibpath"; then
8106 eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var"
8107 fi
8108
8109 # Get the real and link names of the library.
8110 eval shared_ext=\"$shrext_cmds\"
8111 eval library_names=\"$library_names_spec\"
8112 set dummy $library_names
8113 shift
8114 realname="$1"
8115 shift
8116
8117 if test -n "$soname_spec"; then
8118 eval soname=\"$soname_spec\"
8119 else
8120 soname="$realname"
8121 fi
8122 if test -z "$dlname"; then
8123 dlname=$soname
8124 fi
8125
8126 lib="$output_objdir/$realname"
8127 linknames=
8128 for link
8129 do
8130 func_append linknames " $link"
8131 done
8132
8133 # Use standard objects if they are pic
8134 test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP`
8135 test "X$libobjs" = "X " && libobjs=
8136
8137 delfiles=
8138 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8139 $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp"
8140 export_symbols="$output_objdir/$libname.uexp"
8141 func_append delfiles " $export_symbols"
8142 fi
8143
8144 orig_export_symbols=
8145 case $host_os in
8146 cygwin* | mingw* | cegcc*)
8147 if test -n "$export_symbols" && test -z "$export_symbols_regex"; then
8148 # exporting using user supplied symfile
8149 if test "x`$SED "$sed_uncomment_deffile" $export_symbols | $SED 1q`" != xEXPORTS; then
8150 # and it's NOT already a .def file. Must figure out
8151 # which of the given symbols are data symbols and tag
8152 # them as such. So, trigger use of export_symbols_cmds.
8153 # export_symbols gets reassigned inside the "prepare
8154 # the list of exported symbols" if statement, so the
8155 # include_expsyms logic still works.
8156 orig_export_symbols="$export_symbols"
8157 export_symbols=
8158 always_export_symbols=yes
8159 fi
8160 fi
8161 ;;
8162 esac
8163
8164 # Prepare the list of exported symbols
8165 if test -z "$export_symbols"; then
8166 if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then
8167 func_verbose "generating symbol list for \`$libname.la'"
8168 export_symbols="$output_objdir/$libname.exp"
8169 $opt_dry_run || $RM $export_symbols
8170 cmds=$export_symbols_cmds
8171 save_ifs="$IFS"; IFS='~'
8172 for cmd1 in $cmds; do
8173 IFS="$save_ifs"
8174 # Take the normal branch if the nm_file_list_spec branch
8175 # doesn't work or if tool conversion is not needed.
8176 case $nm_file_list_spec~$to_tool_file_cmd in
8177 *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*)
8178 try_normal_branch=yes
8179 eval cmd=\"$cmd1\"
8180 func_len " $cmd"
8181 len=$func_len_result
8182 ;;
8183 *)
8184 try_normal_branch=no
8185 ;;
8186 esac
8187 if test "$try_normal_branch" = yes \
8188 && { test "$len" -lt "$max_cmd_len" \
8189 || test "$max_cmd_len" -le -1; }
8190 then
8191 func_show_eval "$cmd" 'exit $?'
8192 skipped_export=false
8193 elif test -n "$nm_file_list_spec"; then
8194 func_basename "$output"
8195 output_la=$func_basename_result
8196 save_libobjs=$libobjs
8197 save_output=$output
8198 output=${output_objdir}/${output_la}.nm
8199 func_to_tool_file "$output"
8200 libobjs=$nm_file_list_spec$func_to_tool_file_result
8201 func_append delfiles " $output"
8202 func_verbose "creating $NM input file list: $output"
8203 for obj in $save_libobjs; do
8204 func_to_tool_file "$obj"
8205 $ECHO "$func_to_tool_file_result"
8206 done > "$output"
8207 eval cmd=\"$cmd1\"
8208 func_show_eval "$cmd" 'exit $?'
8209 output=$save_output
8210 libobjs=$save_libobjs
8211 skipped_export=false
8212 else
8213 # The command line is too long to execute in one step.
8214 func_verbose "using reloadable object file for export list..."
8215 skipped_export=:
8216 # Break out early, otherwise skipped_export may be
8217 # set to false by a later but shorter cmd.
8218 break
8219 fi
8220 done
8221 IFS="$save_ifs"
8222 if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then
8223 func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
8224 func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
8225 fi
8226 fi
8227 fi
8228
8229 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8230 tmp_export_symbols="$export_symbols"
8231 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
8232 $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
8233 fi
8234
8235 if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
8236 # The given exports_symbols file has to be filtered, so filter it.
8237 func_verbose "filter symbol list for \`$libname.la' to tag DATA exports"
8238 # FIXME: $output_objdir/$libname.filter potentially contains lots of
8239 # 's' commands which not all seds can handle. GNU sed should be fine
8240 # though. Also, the filter scales superlinearly with the number of
8241 # global variables. join(1) would be nice here, but unfortunately
8242 # isn't a blessed tool.
8243 $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
8244 func_append delfiles " $export_symbols $output_objdir/$libname.filter"
8245 export_symbols=$output_objdir/$libname.def
8246 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
8247 fi
8248
8249 tmp_deplibs=
8250 for test_deplib in $deplibs; do
8251 case " $convenience " in
8252 *" $test_deplib "*) ;;
8253 *)
8254 func_append tmp_deplibs " $test_deplib"
8255 ;;
8256 esac
8257 done
8258 deplibs="$tmp_deplibs"
8259
8260 if test -n "$convenience"; then
8261 if test -n "$whole_archive_flag_spec" &&
8262 test "$compiler_needs_object" = yes &&
8263 test -z "$libobjs"; then
8264 # extract the archives, so we have objects to list.
8265 # TODO: could optimize this to just extract one archive.
8266 whole_archive_flag_spec=
8267 fi
8268 if test -n "$whole_archive_flag_spec"; then
8269 save_libobjs=$libobjs
8270 eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
8271 test "X$libobjs" = "X " && libobjs=
8272 else
8273 gentop="$output_objdir/${outputname}x"
8274 func_append generated " $gentop"
8275
8276 func_extract_archives $gentop $convenience
8277 func_append libobjs " $func_extract_archives_result"
8278 test "X$libobjs" = "X " && libobjs=
8279 fi
8280 fi
8281
8282 if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
8283 eval flag=\"$thread_safe_flag_spec\"
8284 func_append linker_flags " $flag"
8285 fi
8286
8287 # Make a backup of the uninstalled library when relinking
8288 if test "$opt_mode" = relink; then
8289 $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $?
8290 fi
8291
8292 # Do each of the archive commands.
8293 if test "$module" = yes && test -n "$module_cmds" ; then
8294 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
8295 eval test_cmds=\"$module_expsym_cmds\"
8296 cmds=$module_expsym_cmds
8297 else
8298 eval test_cmds=\"$module_cmds\"
8299 cmds=$module_cmds
8300 fi
8301 else
8302 if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
8303 eval test_cmds=\"$archive_expsym_cmds\"
8304 cmds=$archive_expsym_cmds
8305 else
8306 eval test_cmds=\"$archive_cmds\"
8307 cmds=$archive_cmds
8308 fi
8309 fi
8310
8311 if test "X$skipped_export" != "X:" &&
8312 func_len " $test_cmds" &&
8313 len=$func_len_result &&
8314 test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
8315 :
8316 else
8317 # The command line is too long to link in one step, link piecewise
8318 # or, if using GNU ld and skipped_export is not :, use a linker
8319 # script.
8320
8321 # Save the value of $output and $libobjs because we want to
8322 # use them later. If we have whole_archive_flag_spec, we
8323 # want to use save_libobjs as it was before
8324 # whole_archive_flag_spec was expanded, because we can't
8325 # assume the linker understands whole_archive_flag_spec.
8326 # This may have to be revisited, in case too many
8327 # convenience libraries get linked in and end up exceeding
8328 # the spec.
8329 if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then
8330 save_libobjs=$libobjs
8331 fi
8332 save_output=$output
8333 func_basename "$output"
8334 output_la=$func_basename_result
8335
8336 # Clear the reloadable object creation command queue and
8337 # initialize k to one.
8338 test_cmds=
8339 concat_cmds=
8340 objlist=
8341 last_robj=
8342 k=1
8343
8344 if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then
8345 output=${output_objdir}/${output_la}.lnkscript
8346 func_verbose "creating GNU ld script: $output"
8347 echo 'INPUT (' > $output
8348 for obj in $save_libobjs
8349 do
8350 func_to_tool_file "$obj"
8351 $ECHO "$func_to_tool_file_result" >> $output
8352 done
8353 echo ')' >> $output
8354 func_append delfiles " $output"
8355 func_to_tool_file "$output"
8356 output=$func_to_tool_file_result
8357 elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
8358 output=${output_objdir}/${output_la}.lnk
8359 func_verbose "creating linker input file list: $output"
8360 : > $output
8361 set x $save_libobjs
8362 shift
8363 firstobj=
8364 if test "$compiler_needs_object" = yes; then
8365 firstobj="$1 "
8366 shift
8367 fi
8368 for obj
8369 do
8370 func_to_tool_file "$obj"
8371 $ECHO "$func_to_tool_file_result" >> $output
8372 done
8373 func_append delfiles " $output"
8374 func_to_tool_file "$output"
8375 output=$firstobj\"$file_list_spec$func_to_tool_file_result\"
8376 else
8377 if test -n "$save_libobjs"; then
8378 func_verbose "creating reloadable object files..."
8379 output=$output_objdir/$output_la-${k}.$objext
8380 eval test_cmds=\"$reload_cmds\"
8381 func_len " $test_cmds"
8382 len0=$func_len_result
8383 len=$len0
8384
8385 # Loop over the list of objects to be linked.
8386 for obj in $save_libobjs
8387 do
8388 func_len " $obj"
8389 func_arith $len + $func_len_result
8390 len=$func_arith_result
8391 if test "X$objlist" = X ||
8392 test "$len" -lt "$max_cmd_len"; then
8393 func_append objlist " $obj"
8394 else
8395 # The command $test_cmds is almost too long, add a
8396 # command to the queue.
8397 if test "$k" -eq 1 ; then
8398 # The first file doesn't have a previous command to add.
8399 reload_objs=$objlist
8400 eval concat_cmds=\"$reload_cmds\"
8401 else
8402 # All subsequent reloadable object files will link in
8403 # the last one created.
8404 reload_objs="$objlist $last_robj"
8405 eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\"
8406 fi
8407 last_robj=$output_objdir/$output_la-${k}.$objext
8408 func_arith $k + 1
8409 k=$func_arith_result
8410 output=$output_objdir/$output_la-${k}.$objext
8411 objlist=" $obj"
8412 func_len " $last_robj"
8413 func_arith $len0 + $func_len_result
8414 len=$func_arith_result
8415 fi
8416 done
8417 # Handle the remaining objects by creating one last
8418 # reloadable object file. All subsequent reloadable object
8419 # files will link in the last one created.
8420 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
8421 reload_objs="$objlist $last_robj"
8422 eval concat_cmds=\"\${concat_cmds}$reload_cmds\"
8423 if test -n "$last_robj"; then
8424 eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\"
8425 fi
8426 func_append delfiles " $output"
8427
8428 else
8429 output=
8430 fi
8431
8432 if ${skipped_export-false}; then
8433 func_verbose "generating symbol list for \`$libname.la'"
8434 export_symbols="$output_objdir/$libname.exp"
8435 $opt_dry_run || $RM $export_symbols
8436 libobjs=$output
8437 # Append the command to create the export file.
8438 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
8439 eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\"
8440 if test -n "$last_robj"; then
8441 eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\"
8442 fi
8443 fi
8444
8445 test -n "$save_libobjs" &&
8446 func_verbose "creating a temporary reloadable object file: $output"
8447
8448 # Loop through the commands generated above and execute them.
8449 save_ifs="$IFS"; IFS='~'
8450 for cmd in $concat_cmds; do
8451 IFS="$save_ifs"
8452 $opt_silent || {
8453 func_quote_for_expand "$cmd"
8454 eval "func_echo $func_quote_for_expand_result"
8455 }
8456 $opt_dry_run || eval "$cmd" || {
8457 lt_exit=$?
8458
8459 # Restore the uninstalled library and exit
8460 if test "$opt_mode" = relink; then
8461 ( cd "$output_objdir" && \
8462 $RM "${realname}T" && \
8463 $MV "${realname}U" "$realname" )
8464 fi
8465
8466 exit $lt_exit
8467 }
8468 done
8469 IFS="$save_ifs"
8470
8471 if test -n "$export_symbols_regex" && ${skipped_export-false}; then
8472 func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
8473 func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
8474 fi
8475 fi
8476
8477 if ${skipped_export-false}; then
8478 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8479 tmp_export_symbols="$export_symbols"
8480 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
8481 $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
8482 fi
8483
8484 if test -n "$orig_export_symbols"; then
8485 # The given exports_symbols file has to be filtered, so filter it.
8486 func_verbose "filter symbol list for \`$libname.la' to tag DATA exports"
8487 # FIXME: $output_objdir/$libname.filter potentially contains lots of
8488 # 's' commands which not all seds can handle. GNU sed should be fine
8489 # though. Also, the filter scales superlinearly with the number of
8490 # global variables. join(1) would be nice here, but unfortunately
8491 # isn't a blessed tool.
8492 $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
8493 func_append delfiles " $export_symbols $output_objdir/$libname.filter"
8494 export_symbols=$output_objdir/$libname.def
8495 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
8496 fi
8497 fi
8498
8499 libobjs=$output
8500 # Restore the value of output.
8501 output=$save_output
8502
8503 if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then
8504 eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
8505 test "X$libobjs" = "X " && libobjs=
8506 fi
8507 # Expand the library linking commands again to reset the
8508 # value of $libobjs for piecewise linking.
8509
8510 # Do each of the archive commands.
8511 if test "$module" = yes && test -n "$module_cmds" ; then
8512 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
8513 cmds=$module_expsym_cmds
8514 else
8515 cmds=$module_cmds
8516 fi
8517 else
8518 if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
8519 cmds=$archive_expsym_cmds
8520 else
8521 cmds=$archive_cmds
8522 fi
8523 fi
8524 fi
8525
8526 if test -n "$delfiles"; then
8527 # Append the command to remove temporary files to $cmds.
8528 eval cmds=\"\$cmds~\$RM $delfiles\"
8529 fi
8530
8531 # Add any objects from preloaded convenience libraries
8532 if test -n "$dlprefiles"; then
8533 gentop="$output_objdir/${outputname}x"
8534 func_append generated " $gentop"
8535
8536 func_extract_archives $gentop $dlprefiles
8537 func_append libobjs " $func_extract_archives_result"
8538 test "X$libobjs" = "X " && libobjs=
8539 fi
8540
8541 save_ifs="$IFS"; IFS='~'
8542 for cmd in $cmds; do
8543 IFS="$save_ifs"
8544 eval cmd=\"$cmd\"
8545 $opt_silent || {
8546 func_quote_for_expand "$cmd"
8547 eval "func_echo $func_quote_for_expand_result"
8548 }
8549 $opt_dry_run || eval "$cmd" || {
8550 lt_exit=$?
8551
8552 # Restore the uninstalled library and exit
8553 if test "$opt_mode" = relink; then
8554 ( cd "$output_objdir" && \
8555 $RM "${realname}T" && \
8556 $MV "${realname}U" "$realname" )
8557 fi
8558
8559 exit $lt_exit
8560 }
8561 done
8562 IFS="$save_ifs"
8563
8564 # Restore the uninstalled library and exit
8565 if test "$opt_mode" = relink; then
8566 $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $?
8567
8568 if test -n "$convenience"; then
8569 if test -z "$whole_archive_flag_spec"; then
8570 func_show_eval '${RM}r "$gentop"'
8571 fi
8572 fi
8573
8574 exit $EXIT_SUCCESS
8575 fi
8576
8577 # Create links to the real library.
8578 for linkname in $linknames; do
8579 if test "$realname" != "$linkname"; then
8580 func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?'
8581 fi
8582 done
8583
8584 # If -module or -export-dynamic was specified, set the dlname.
8585 if test "$module" = yes || test "$export_dynamic" = yes; then
8586 # On all known operating systems, these are identical.
8587 dlname="$soname"
8588 fi
8589 fi
8590 ;;
8591
8592 obj)
8593 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
8594 func_warning "\`-dlopen' is ignored for objects"
8595 fi
8596
8597 case " $deplibs" in
8598 *\ -l* | *\ -L*)
8599 func_warning "\`-l' and \`-L' are ignored for objects" ;;
8600 esac
8601
8602 test -n "$rpath" && \
8603 func_warning "\`-rpath' is ignored for objects"
8604
8605 test -n "$xrpath" && \
8606 func_warning "\`-R' is ignored for objects"
8607
8608 test -n "$vinfo" && \
8609 func_warning "\`-version-info' is ignored for objects"
8610
8611 test -n "$release" && \
8612 func_warning "\`-release' is ignored for objects"
8613
8614 case $output in
8615 *.lo)
8616 test -n "$objs$old_deplibs" && \
8617 func_fatal_error "cannot build library object \`$output' from non-libtool objects"
8618
8619 libobj=$output
8620 func_lo2o "$libobj"
8621 obj=$func_lo2o_result
8622 ;;
8623 *)
8624 libobj=
8625 obj="$output"
8626 ;;
8627 esac
8628
8629 # Delete the old objects.
8630 $opt_dry_run || $RM $obj $libobj
8631
8632 # Objects from convenience libraries. This assumes
8633 # single-version convenience libraries. Whenever we create
8634 # different ones for PIC/non-PIC, this we'll have to duplicate
8635 # the extraction.
8636 reload_conv_objs=
8637 gentop=
8638 # reload_cmds runs $LD directly, so let us get rid of
8639 # -Wl from whole_archive_flag_spec and hope we can get by with
8640 # turning comma into space..
8641 wl=
8642
8643 if test -n "$convenience"; then
8644 if test -n "$whole_archive_flag_spec"; then
8645 eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
8646 reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'`
8647 else
8648 gentop="$output_objdir/${obj}x"
8649 func_append generated " $gentop"
8650
8651 func_extract_archives $gentop $convenience
8652 reload_conv_objs="$reload_objs $func_extract_archives_result"
8653 fi
8654 fi
8655
8656 # If we're not building shared, we need to use non_pic_objs
8657 test "$build_libtool_libs" != yes && libobjs="$non_pic_objects"
8658
8659 # Create the old-style object.
8660 reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
8661
8662 output="$obj"
8663 func_execute_cmds "$reload_cmds" 'exit $?'
8664
8665 # Exit if we aren't doing a library object file.
8666 if test -z "$libobj"; then
8667 if test -n "$gentop"; then
8668 func_show_eval '${RM}r "$gentop"'
8669 fi
8670
8671 exit $EXIT_SUCCESS
8672 fi
8673
8674 if test "$build_libtool_libs" != yes; then
8675 if test -n "$gentop"; then
8676 func_show_eval '${RM}r "$gentop"'
8677 fi
8678
8679 # Create an invalid libtool object if no PIC, so that we don't
8680 # accidentally link it into a program.
8681 # $show "echo timestamp > $libobj"
8682 # $opt_dry_run || eval "echo timestamp > $libobj" || exit $?
8683 exit $EXIT_SUCCESS
8684 fi
8685
8686 if test -n "$pic_flag" || test "$pic_mode" != default; then
8687 # Only do commands if we really have different PIC objects.
8688 reload_objs="$libobjs $reload_conv_objs"
8689 output="$libobj"
8690 func_execute_cmds "$reload_cmds" 'exit $?'
8691 fi
8692
8693 if test -n "$gentop"; then
8694 func_show_eval '${RM}r "$gentop"'
8695 fi
8696
8697 exit $EXIT_SUCCESS
8698 ;;
8699
8700 prog)
8701 case $host in
8702 *cygwin*) func_stripname '' '.exe' "$output"
8703 output=$func_stripname_result.exe;;
8704 esac
8705 test -n "$vinfo" && \
8706 func_warning "\`-version-info' is ignored for programs"
8707
8708 test -n "$release" && \
8709 func_warning "\`-release' is ignored for programs"
8710
8711 test "$preload" = yes \
8712 && test "$dlopen_support" = unknown \
8713 && test "$dlopen_self" = unknown \
8714 && test "$dlopen_self_static" = unknown && \
8715 func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support."
8716
8717 case $host in
8718 *-*-rhapsody* | *-*-darwin1.[012])
8719 # On Rhapsody replace the C library is the System framework
8720 compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'`
8721 finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'`
8722 ;;
8723 esac
8724
8725 case $host in
8726 *-*-darwin*)
8727 # Don't allow lazy linking, it breaks C++ global constructors
8728 # But is supposedly fixed on 10.4 or later (yay!).
8729 if test "$tagname" = CXX ; then
8730 case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
8731 10.[0123])
8732 func_append compile_command " ${wl}-bind_at_load"
8733 func_append finalize_command " ${wl}-bind_at_load"
8734 ;;
8735 esac
8736 fi
8737 # Time to change all our "foo.ltframework" stuff back to "-framework foo"
8738 compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8739 finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8740 ;;
8741 esac
8742
8743
8744 # move library search paths that coincide with paths to not yet
8745 # installed libraries to the beginning of the library search list
8746 new_libs=
8747 for path in $notinst_path; do
8748 case " $new_libs " in
8749 *" -L$path/$objdir "*) ;;
8750 *)
8751 case " $compile_deplibs " in
8752 *" -L$path/$objdir "*)
8753 func_append new_libs " -L$path/$objdir" ;;
8754 esac
8755 ;;
8756 esac
8757 done
8758 for deplib in $compile_deplibs; do
8759 case $deplib in
8760 -L*)
8761 case " $new_libs " in
8762 *" $deplib "*) ;;
8763 *) func_append new_libs " $deplib" ;;
8764 esac
8765 ;;
8766 *) func_append new_libs " $deplib" ;;
8767 esac
8768 done
8769 compile_deplibs="$new_libs"
8770
8771
8772 func_append compile_command " $compile_deplibs"
8773 func_append finalize_command " $finalize_deplibs"
8774
8775 if test -n "$rpath$xrpath"; then
8776 # If the user specified any rpath flags, then add them.
8777 for libdir in $rpath $xrpath; do
8778 # This is the magic to use -rpath.
8779 case "$finalize_rpath " in
8780 *" $libdir "*) ;;
8781 *) func_append finalize_rpath " $libdir" ;;
8782 esac
8783 done
8784 fi
8785
8786 # Now hardcode the library paths
8787 rpath=
8788 hardcode_libdirs=
8789 for libdir in $compile_rpath $finalize_rpath; do
8790 if test -n "$hardcode_libdir_flag_spec"; then
8791 if test -n "$hardcode_libdir_separator"; then
8792 if test -z "$hardcode_libdirs"; then
8793 hardcode_libdirs="$libdir"
8794 else
8795 # Just accumulate the unique libdirs.
8796 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
8797 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
8798 ;;
8799 *)
8800 func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
8801 ;;
8802 esac
8803 fi
8804 else
8805 eval flag=\"$hardcode_libdir_flag_spec\"
8806 func_append rpath " $flag"
8807 fi
8808 elif test -n "$runpath_var"; then
8809 case "$perm_rpath " in
8810 *" $libdir "*) ;;
8811 *) func_append perm_rpath " $libdir" ;;
8812 esac
8813 fi
8814 case $host in
8815 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
8816 testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'`
8817 case :$dllsearchpath: in
8818 *":$libdir:"*) ;;
8819 ::) dllsearchpath=$libdir;;
8820 *) func_append dllsearchpath ":$libdir";;
8821 esac
8822 case :$dllsearchpath: in
8823 *":$testbindir:"*) ;;
8824 ::) dllsearchpath=$testbindir;;
8825 *) func_append dllsearchpath ":$testbindir";;
8826 esac
8827 ;;
8828 esac
8829 done
8830 # Substitute the hardcoded libdirs into the rpath.
8831 if test -n "$hardcode_libdir_separator" &&
8832 test -n "$hardcode_libdirs"; then
8833 libdir="$hardcode_libdirs"
8834 eval rpath=\" $hardcode_libdir_flag_spec\"
8835 fi
8836 compile_rpath="$rpath"
8837
8838 rpath=
8839 hardcode_libdirs=
8840 for libdir in $finalize_rpath; do
8841 if test -n "$hardcode_libdir_flag_spec"; then
8842 if test -n "$hardcode_libdir_separator"; then
8843 if test -z "$hardcode_libdirs"; then
8844 hardcode_libdirs="$libdir"
8845 else
8846 # Just accumulate the unique libdirs.
8847 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
8848 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
8849 ;;
8850 *)
8851 func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
8852 ;;
8853 esac
8854 fi
8855 else
8856 eval flag=\"$hardcode_libdir_flag_spec\"
8857 func_append rpath " $flag"
8858 fi
8859 elif test -n "$runpath_var"; then
8860 case "$finalize_perm_rpath " in
8861 *" $libdir "*) ;;
8862 *) func_append finalize_perm_rpath " $libdir" ;;
8863 esac
8864 fi
8865 done
8866 # Substitute the hardcoded libdirs into the rpath.
8867 if test -n "$hardcode_libdir_separator" &&
8868 test -n "$hardcode_libdirs"; then
8869 libdir="$hardcode_libdirs"
8870 eval rpath=\" $hardcode_libdir_flag_spec\"
8871 fi
8872 finalize_rpath="$rpath"
8873
8874 if test -n "$libobjs" && test "$build_old_libs" = yes; then
8875 # Transform all the library objects into standard objects.
8876 compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
8877 finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
8878 fi
8879
8880 func_generate_dlsyms "$outputname" "@PROGRAM@" "no"
8881
8882 # template prelinking step
8883 if test -n "$prelink_cmds"; then
8884 func_execute_cmds "$prelink_cmds" 'exit $?'
8885 fi
8886
8887 wrappers_required=yes
8888 case $host in
8889 *cegcc* | *mingw32ce*)
8890 # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway.
8891 wrappers_required=no
8892 ;;
8893 *cygwin* | *mingw* )
8894 if test "$build_libtool_libs" != yes; then
8895 wrappers_required=no
8896 fi
8897 ;;
8898 *)
8899 if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
8900 wrappers_required=no
8901 fi
8902 ;;
8903 esac
8904 if test "$wrappers_required" = no; then
8905 # Replace the output file specification.
8906 compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
8907 link_command="$compile_command$compile_rpath"
8908
8909 # We have no uninstalled library dependencies, so finalize right now.
8910 exit_status=0
8911 func_show_eval "$link_command" 'exit_status=$?'
8912
8913 if test -n "$postlink_cmds"; then
8914 func_to_tool_file "$output"
8915 postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
8916 func_execute_cmds "$postlink_cmds" 'exit $?'
8917 fi
8918
8919 # Delete the generated files.
8920 if test -f "$output_objdir/${outputname}S.${objext}"; then
8921 func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"'
8922 fi
8923
8924 exit $exit_status
8925 fi
8926
8927 if test -n "$compile_shlibpath$finalize_shlibpath"; then
8928 compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command"
8929 fi
8930 if test -n "$finalize_shlibpath"; then
8931 finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command"
8932 fi
8933
8934 compile_var=
8935 finalize_var=
8936 if test -n "$runpath_var"; then
8937 if test -n "$perm_rpath"; then
8938 # We should set the runpath_var.
8939 rpath=
8940 for dir in $perm_rpath; do
8941 func_append rpath "$dir:"
8942 done
8943 compile_var="$runpath_var=\"$rpath\$$runpath_var\" "
8944 fi
8945 if test -n "$finalize_perm_rpath"; then
8946 # We should set the runpath_var.
8947 rpath=
8948 for dir in $finalize_perm_rpath; do
8949 func_append rpath "$dir:"
8950 done
8951 finalize_var="$runpath_var=\"$rpath\$$runpath_var\" "
8952 fi
8953 fi
8954
8955 if test "$no_install" = yes; then
8956 # We don't need to create a wrapper script.
8957 link_command="$compile_var$compile_command$compile_rpath"
8958 # Replace the output file specification.
8959 link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
8960 # Delete the old output file.
8961 $opt_dry_run || $RM $output
8962 # Link the executable and exit
8963 func_show_eval "$link_command" 'exit $?'
8964
8965 if test -n "$postlink_cmds"; then
8966 func_to_tool_file "$output"
8967 postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
8968 func_execute_cmds "$postlink_cmds" 'exit $?'
8969 fi
8970
8971 exit $EXIT_SUCCESS
8972 fi
8973
8974 if test "$hardcode_action" = relink; then
8975 # Fast installation is not supported
8976 link_command="$compile_var$compile_command$compile_rpath"
8977 relink_command="$finalize_var$finalize_command$finalize_rpath"
8978
8979 func_warning "this platform does not like uninstalled shared libraries"
8980 func_warning "\`$output' will be relinked during installation"
8981 else
8982 if test "$fast_install" != no; then
8983 link_command="$finalize_var$compile_command$finalize_rpath"
8984 if test "$fast_install" = yes; then
8985 relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'`
8986 else
8987 # fast_install is set to needless
8988 relink_command=
8989 fi
8990 else
8991 link_command="$compile_var$compile_command$compile_rpath"
8992 relink_command="$finalize_var$finalize_command$finalize_rpath"
8993 fi
8994 fi
8995
8996 # Replace the output file specification.
8997 link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
8998
8999 # Delete the old output files.
9000 $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname
9001
9002 func_show_eval "$link_command" 'exit $?'
9003
9004 if test -n "$postlink_cmds"; then
9005 func_to_tool_file "$output_objdir/$outputname"
9006 postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
9007 func_execute_cmds "$postlink_cmds" 'exit $?'
9008 fi
9009
9010 # Now create the wrapper script.
9011 func_verbose "creating $output"
9012
9013 # Quote the relink command for shipping.
9014 if test -n "$relink_command"; then
9015 # Preserve any variables that may affect compiler behavior
9016 for var in $variables_saved_for_relink; do
9017 if eval test -z \"\${$var+set}\"; then
9018 relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command"
9019 elif eval var_value=\$$var; test -z "$var_value"; then
9020 relink_command="$var=; export $var; $relink_command"
9021 else
9022 func_quote_for_eval "$var_value"
9023 relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command"
9024 fi
9025 done
9026 relink_command="(cd `pwd`; $relink_command)"
9027 relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
9028 fi
9029
9030 # Only actually do things if not in dry run mode.
9031 $opt_dry_run || {
9032 # win32 will think the script is a binary if it has
9033 # a .exe suffix, so we strip it off here.
9034 case $output in
9035 *.exe) func_stripname '' '.exe' "$output"
9036 output=$func_stripname_result ;;
9037 esac
9038 # test for cygwin because mv fails w/o .exe extensions
9039 case $host in
9040 *cygwin*)
9041 exeext=.exe
9042 func_stripname '' '.exe' "$outputname"
9043 outputname=$func_stripname_result ;;
9044 *) exeext= ;;
9045 esac
9046 case $host in
9047 *cygwin* | *mingw* )
9048 func_dirname_and_basename "$output" "" "."
9049 output_name=$func_basename_result
9050 output_path=$func_dirname_result
9051 cwrappersource="$output_path/$objdir/lt-$output_name.c"
9052 cwrapper="$output_path/$output_name.exe"
9053 $RM $cwrappersource $cwrapper
9054 trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15
9055
9056 func_emit_cwrapperexe_src > $cwrappersource
9057
9058 # The wrapper executable is built using the $host compiler,
9059 # because it contains $host paths and files. If cross-
9060 # compiling, it, like the target executable, must be
9061 # executed on the $host or under an emulation environment.
9062 $opt_dry_run || {
9063 $LTCC $LTCFLAGS -o $cwrapper $cwrappersource
9064 $STRIP $cwrapper
9065 }
9066
9067 # Now, create the wrapper script for func_source use:
9068 func_ltwrapper_scriptname $cwrapper
9069 $RM $func_ltwrapper_scriptname_result
9070 trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15
9071 $opt_dry_run || {
9072 # note: this script will not be executed, so do not chmod.
9073 if test "x$build" = "x$host" ; then
9074 $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result
9075 else
9076 func_emit_wrapper no > $func_ltwrapper_scriptname_result
9077 fi
9078 }
9079 ;;
9080 * )
9081 $RM $output
9082 trap "$RM $output; exit $EXIT_FAILURE" 1 2 15
9083
9084 func_emit_wrapper no > $output
9085 chmod +x $output
9086 ;;
9087 esac
9088 }
9089 exit $EXIT_SUCCESS
9090 ;;
9091 esac
9092
9093 # See if we need to build an old-fashioned archive.
9094 for oldlib in $oldlibs; do
9095
9096 if test "$build_libtool_libs" = convenience; then
9097 oldobjs="$libobjs_save $symfileobj"
9098 addlibs="$convenience"
9099 build_libtool_libs=no
9100 else
9101 if test "$build_libtool_libs" = module; then
9102 oldobjs="$libobjs_save"
9103 build_libtool_libs=no
9104 else
9105 oldobjs="$old_deplibs $non_pic_objects"
9106 if test "$preload" = yes && test -f "$symfileobj"; then
9107 func_append oldobjs " $symfileobj"
9108 fi
9109 fi
9110 addlibs="$old_convenience"
9111 fi
9112
9113 if test -n "$addlibs"; then
9114 gentop="$output_objdir/${outputname}x"
9115 func_append generated " $gentop"
9116
9117 func_extract_archives $gentop $addlibs
9118 func_append oldobjs " $func_extract_archives_result"
9119 fi
9120
9121 # Do each command in the archive commands.
9122 if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then
9123 cmds=$old_archive_from_new_cmds
9124 else
9125
9126 # Add any objects from preloaded convenience libraries
9127 if test -n "$dlprefiles"; then
9128 gentop="$output_objdir/${outputname}x"
9129 func_append generated " $gentop"
9130
9131 func_extract_archives $gentop $dlprefiles
9132 func_append oldobjs " $func_extract_archives_result"
9133 fi
9134
9135 # POSIX demands no paths to be encoded in archives. We have
9136 # to avoid creating archives with duplicate basenames if we
9137 # might have to extract them afterwards, e.g., when creating a
9138 # static archive out of a convenience library, or when linking
9139 # the entirety of a libtool archive into another (currently
9140 # not supported by libtool).
9141 if (for obj in $oldobjs
9142 do
9143 func_basename "$obj"
9144 $ECHO "$func_basename_result"
9145 done | sort | sort -uc >/dev/null 2>&1); then
9146 :
9147 else
9148 echo "copying selected object files to avoid basename conflicts..."
9149 gentop="$output_objdir/${outputname}x"
9150 func_append generated " $gentop"
9151 func_mkdir_p "$gentop"
9152 save_oldobjs=$oldobjs
9153 oldobjs=
9154 counter=1
9155 for obj in $save_oldobjs
9156 do
9157 func_basename "$obj"
9158 objbase="$func_basename_result"
9159 case " $oldobjs " in
9160 " ") oldobjs=$obj ;;
9161 *[\ /]"$objbase "*)
9162 while :; do
9163 # Make sure we don't pick an alternate name that also
9164 # overlaps.
9165 newobj=lt$counter-$objbase
9166 func_arith $counter + 1
9167 counter=$func_arith_result
9168 case " $oldobjs " in
9169 *[\ /]"$newobj "*) ;;
9170 *) if test ! -f "$gentop/$newobj"; then break; fi ;;
9171 esac
9172 done
9173 func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj"
9174 func_append oldobjs " $gentop/$newobj"
9175 ;;
9176 *) func_append oldobjs " $obj" ;;
9177 esac
9178 done
9179 fi
9180 func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
9181 tool_oldlib=$func_to_tool_file_result
9182 eval cmds=\"$old_archive_cmds\"
9183
9184 func_len " $cmds"
9185 len=$func_len_result
9186 if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
9187 cmds=$old_archive_cmds
9188 elif test -n "$archiver_list_spec"; then
9189 func_verbose "using command file archive linking..."
9190 for obj in $oldobjs
9191 do
9192 func_to_tool_file "$obj"
9193 $ECHO "$func_to_tool_file_result"
9194 done > $output_objdir/$libname.libcmd
9195 func_to_tool_file "$output_objdir/$libname.libcmd"
9196 oldobjs=" $archiver_list_spec$func_to_tool_file_result"
9197 cmds=$old_archive_cmds
9198 else
9199 # the command line is too long to link in one step, link in parts
9200 func_verbose "using piecewise archive linking..."
9201 save_RANLIB=$RANLIB
9202 RANLIB=:
9203 objlist=
9204 concat_cmds=
9205 save_oldobjs=$oldobjs
9206 oldobjs=
9207 # Is there a better way of finding the last object in the list?
9208 for obj in $save_oldobjs
9209 do
9210 last_oldobj=$obj
9211 done
9212 eval test_cmds=\"$old_archive_cmds\"
9213 func_len " $test_cmds"
9214 len0=$func_len_result
9215 len=$len0
9216 for obj in $save_oldobjs
9217 do
9218 func_len " $obj"
9219 func_arith $len + $func_len_result
9220 len=$func_arith_result
9221 func_append objlist " $obj"
9222 if test "$len" -lt "$max_cmd_len"; then
9223 :
9224 else
9225 # the above command should be used before it gets too long
9226 oldobjs=$objlist
9227 if test "$obj" = "$last_oldobj" ; then
9228 RANLIB=$save_RANLIB
9229 fi
9230 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
9231 eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\"
9232 objlist=
9233 len=$len0
9234 fi
9235 done
9236 RANLIB=$save_RANLIB
9237 oldobjs=$objlist
9238 if test "X$oldobjs" = "X" ; then
9239 eval cmds=\"\$concat_cmds\"
9240 else
9241 eval cmds=\"\$concat_cmds~\$old_archive_cmds\"
9242 fi
9243 fi
9244 fi
9245 func_execute_cmds "$cmds" 'exit $?'
9246 done
9247
9248 test -n "$generated" && \
9249 func_show_eval "${RM}r$generated"
9250
9251 # Now create the libtool archive.
9252 case $output in
9253 *.la)
9254 old_library=
9255 test "$build_old_libs" = yes && old_library="$libname.$libext"
9256 func_verbose "creating $output"
9257
9258 # Preserve any variables that may affect compiler behavior
9259 for var in $variables_saved_for_relink; do
9260 if eval test -z \"\${$var+set}\"; then
9261 relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command"
9262 elif eval var_value=\$$var; test -z "$var_value"; then
9263 relink_command="$var=; export $var; $relink_command"
9264 else
9265 func_quote_for_eval "$var_value"
9266 relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command"
9267 fi
9268 done
9269 # Quote the link command for shipping.
9270 relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
9271 relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
9272 if test "$hardcode_automatic" = yes ; then
9273 relink_command=
9274 fi
9275
9276 # Only create the output if not a dry run.
9277 $opt_dry_run || {
9278 for installed in no yes; do
9279 if test "$installed" = yes; then
9280 if test -z "$install_libdir"; then
9281 break
9282 fi
9283 output="$output_objdir/$outputname"i
9284 # Replace all uninstalled libtool libraries with the installed ones
9285 newdependency_libs=
9286 for deplib in $dependency_libs; do
9287 case $deplib in
9288 *.la)
9289 func_basename "$deplib"
9290 name="$func_basename_result"
9291 func_resolve_sysroot "$deplib"
9292 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
9293 test -z "$libdir" && \
9294 func_fatal_error "\`$deplib' is not a valid libtool archive"
9295 func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name"
9296 ;;
9297 -L*)
9298 func_stripname -L '' "$deplib"
9299 func_replace_sysroot "$func_stripname_result"
9300 func_append newdependency_libs " -L$func_replace_sysroot_result"
9301 ;;
9302 -R*)
9303 func_stripname -R '' "$deplib"
9304 func_replace_sysroot "$func_stripname_result"
9305 func_append newdependency_libs " -R$func_replace_sysroot_result"
9306 ;;
9307 *) func_append newdependency_libs " $deplib" ;;
9308 esac
9309 done
9310 dependency_libs="$newdependency_libs"
9311 newdlfiles=
9312
9313 for lib in $dlfiles; do
9314 case $lib in
9315 *.la)
9316 func_basename "$lib"
9317 name="$func_basename_result"
9318 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
9319 test -z "$libdir" && \
9320 func_fatal_error "\`$lib' is not a valid libtool archive"
9321 func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name"
9322 ;;
9323 *) func_append newdlfiles " $lib" ;;
9324 esac
9325 done
9326 dlfiles="$newdlfiles"
9327 newdlprefiles=
9328 for lib in $dlprefiles; do
9329 case $lib in
9330 *.la)
9331 # Only pass preopened files to the pseudo-archive (for
9332 # eventual linking with the app. that links it) if we
9333 # didn't already link the preopened objects directly into
9334 # the library:
9335 func_basename "$lib"
9336 name="$func_basename_result"
9337 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
9338 test -z "$libdir" && \
9339 func_fatal_error "\`$lib' is not a valid libtool archive"
9340 func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name"
9341 ;;
9342 esac
9343 done
9344 dlprefiles="$newdlprefiles"
9345 else
9346 newdlfiles=
9347 for lib in $dlfiles; do
9348 case $lib in
9349 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
9350 *) abs=`pwd`"/$lib" ;;
9351 esac
9352 func_append newdlfiles " $abs"
9353 done
9354 dlfiles="$newdlfiles"
9355 newdlprefiles=
9356 for lib in $dlprefiles; do
9357 case $lib in
9358 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
9359 *) abs=`pwd`"/$lib" ;;
9360 esac
9361 func_append newdlprefiles " $abs"
9362 done
9363 dlprefiles="$newdlprefiles"
9364 fi
9365 $RM $output
9366 # place dlname in correct position for cygwin
9367 # In fact, it would be nice if we could use this code for all target
9368 # systems that can't hard-code library paths into their executables
9369 # and that have no shared library path variable independent of PATH,
9370 # but it turns out we can't easily determine that from inspecting
9371 # libtool variables, so we have to hard-code the OSs to which it
9372 # applies here; at the moment, that means platforms that use the PE
9373 # object format with DLL files. See the long comment at the top of
9374 # tests/bindir.at for full details.
9375 tdlname=$dlname
9376 case $host,$output,$installed,$module,$dlname in
9377 *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll)
9378 # If a -bindir argument was supplied, place the dll there.
9379 if test "x$bindir" != x ;
9380 then
9381 func_relative_path "$install_libdir" "$bindir"
9382 tdlname=$func_relative_path_result$dlname
9383 else
9384 # Otherwise fall back on heuristic.
9385 tdlname=../bin/$dlname
9386 fi
9387 ;;
9388 esac
9389 $ECHO > $output "\
9390 # $outputname - a libtool library file
9391 # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
9392 #
9393 # Please DO NOT delete this file!
9394 # It is necessary for linking the library.
9395
9396 # The name that we can dlopen(3).
9397 dlname='$tdlname'
9398
9399 # Names of this library.
9400 library_names='$library_names'
9401
9402 # The name of the static archive.
9403 old_library='$old_library'
9404
9405 # Linker flags that can not go in dependency_libs.
9406 inherited_linker_flags='$new_inherited_linker_flags'
9407
9408 # Libraries that this one depends upon.
9409 dependency_libs='$dependency_libs'
9410
9411 # Names of additional weak libraries provided by this library
9412 weak_library_names='$weak_libs'
9413
9414 # Version information for $libname.
9415 current=$current
9416 age=$age
9417 revision=$revision
9418
9419 # Is this an already installed library?
9420 installed=$installed
9421
9422 # Should we warn about portability when linking against -modules?
9423 shouldnotlink=$module
9424
9425 # Files to dlopen/dlpreopen
9426 dlopen='$dlfiles'
9427 dlpreopen='$dlprefiles'
9428
9429 # Directory that this library needs to be installed in:
9430 libdir='$install_libdir'"
9431 if test "$installed" = no && test "$need_relink" = yes; then
9432 $ECHO >> $output "\
9433 relink_command=\"$relink_command\""
9434 fi
9435 done
9436 }
9437
9438 # Do a symbolic link so that the libtool archive can be found in
9439 # LD_LIBRARY_PATH before the program is installed.
9440 func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?'
9441 ;;
9442 esac
9443 exit $EXIT_SUCCESS
9444 }
9445
9446 { test "$opt_mode" = link || test "$opt_mode" = relink; } &&
9447 func_mode_link ${1+"$@"}
9448
9449
9450 # func_mode_uninstall arg...
9451 func_mode_uninstall ()
9452 {
9453 $opt_debug
9454 RM="$nonopt"
9455 files=
9456 rmforce=
9457 exit_status=0
9458
9459 # This variable tells wrapper scripts just to set variables rather
9460 # than running their programs.
9461 libtool_install_magic="$magic"
9462
9463 for arg
9464 do
9465 case $arg in
9466 -f) func_append RM " $arg"; rmforce=yes ;;
9467 -*) func_append RM " $arg" ;;
9468 *) func_append files " $arg" ;;
9469 esac
9470 done
9471
9472 test -z "$RM" && \
9473 func_fatal_help "you must specify an RM program"
9474
9475 rmdirs=
9476
9477 for file in $files; do
9478 func_dirname "$file" "" "."
9479 dir="$func_dirname_result"
9480 if test "X$dir" = X.; then
9481 odir="$objdir"
9482 else
9483 odir="$dir/$objdir"
9484 fi
9485 func_basename "$file"
9486 name="$func_basename_result"
9487 test "$opt_mode" = uninstall && odir="$dir"
9488
9489 # Remember odir for removal later, being careful to avoid duplicates
9490 if test "$opt_mode" = clean; then
9491 case " $rmdirs " in
9492 *" $odir "*) ;;
9493 *) func_append rmdirs " $odir" ;;
9494 esac
9495 fi
9496
9497 # Don't error if the file doesn't exist and rm -f was used.
9498 if { test -L "$file"; } >/dev/null 2>&1 ||
9499 { test -h "$file"; } >/dev/null 2>&1 ||
9500 test -f "$file"; then
9501 :
9502 elif test -d "$file"; then
9503 exit_status=1
9504 continue
9505 elif test "$rmforce" = yes; then
9506 continue
9507 fi
9508
9509 rmfiles="$file"
9510
9511 case $name in
9512 *.la)
9513 # Possibly a libtool archive, so verify it.
9514 if func_lalib_p "$file"; then
9515 func_source $dir/$name
9516
9517 # Delete the libtool libraries and symlinks.
9518 for n in $library_names; do
9519 func_append rmfiles " $odir/$n"
9520 done
9521 test -n "$old_library" && func_append rmfiles " $odir/$old_library"
9522
9523 case "$opt_mode" in
9524 clean)
9525 case " $library_names " in
9526 *" $dlname "*) ;;
9527 *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;;
9528 esac
9529 test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i"
9530 ;;
9531 uninstall)
9532 if test -n "$library_names"; then
9533 # Do each command in the postuninstall commands.
9534 func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
9535 fi
9536
9537 if test -n "$old_library"; then
9538 # Do each command in the old_postuninstall commands.
9539 func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
9540 fi
9541 # FIXME: should reinstall the best remaining shared library.
9542 ;;
9543 esac
9544 fi
9545 ;;
9546
9547 *.lo)
9548 # Possibly a libtool object, so verify it.
9549 if func_lalib_p "$file"; then
9550
9551 # Read the .lo file
9552 func_source $dir/$name
9553
9554 # Add PIC object to the list of files to remove.
9555 if test -n "$pic_object" &&
9556 test "$pic_object" != none; then
9557 func_append rmfiles " $dir/$pic_object"
9558 fi
9559
9560 # Add non-PIC object to the list of files to remove.
9561 if test -n "$non_pic_object" &&
9562 test "$non_pic_object" != none; then
9563 func_append rmfiles " $dir/$non_pic_object"
9564 fi
9565 fi
9566 ;;
9567
9568 *)
9569 if test "$opt_mode" = clean ; then
9570 noexename=$name
9571 case $file in
9572 *.exe)
9573 func_stripname '' '.exe' "$file"
9574 file=$func_stripname_result
9575 func_stripname '' '.exe' "$name"
9576 noexename=$func_stripname_result
9577 # $file with .exe has already been added to rmfiles,
9578 # add $file without .exe
9579 func_append rmfiles " $file"
9580 ;;
9581 esac
9582 # Do a test to see if this is a libtool program.
9583 if func_ltwrapper_p "$file"; then
9584 if func_ltwrapper_executable_p "$file"; then
9585 func_ltwrapper_scriptname "$file"
9586 relink_command=
9587 func_source $func_ltwrapper_scriptname_result
9588 func_append rmfiles " $func_ltwrapper_scriptname_result"
9589 else
9590 relink_command=
9591 func_source $dir/$noexename
9592 fi
9593
9594 # note $name still contains .exe if it was in $file originally
9595 # as does the version of $file that was added into $rmfiles
9596 func_append rmfiles " $odir/$name $odir/${name}S.${objext}"
9597 if test "$fast_install" = yes && test -n "$relink_command"; then
9598 func_append rmfiles " $odir/lt-$name"
9599 fi
9600 if test "X$noexename" != "X$name" ; then
9601 func_append rmfiles " $odir/lt-${noexename}.c"
9602 fi
9603 fi
9604 fi
9605 ;;
9606 esac
9607 func_show_eval "$RM $rmfiles" 'exit_status=1'
9608 done
9609
9610 # Try to remove the ${objdir}s in the directories where we deleted files
9611 for dir in $rmdirs; do
9612 if test -d "$dir"; then
9613 func_show_eval "rmdir $dir >/dev/null 2>&1"
9614 fi
9615 done
9616
9617 exit $exit_status
9618 }
9619
9620 { test "$opt_mode" = uninstall || test "$opt_mode" = clean; } &&
9621 func_mode_uninstall ${1+"$@"}
9622
9623 test -z "$opt_mode" && {
9624 help="$generic_help"
9625 func_fatal_help "you must specify a MODE"
9626 }
9627
9628 test -z "$exec_cmd" && \
9629 func_fatal_help "invalid operation mode \`$opt_mode'"
9630
9631 if test -n "$exec_cmd"; then
9632 eval exec "$exec_cmd"
9633 exit $EXIT_FAILURE
9634 fi
9635
9636 exit $exit_status
9637
9638
9639 # The TAGs below are defined such that we never get into a situation
9640 # in which we disable both kinds of libraries. Given conflicting
9641 # choices, we go for a static library, that is the most portable,
9642 # since we can't tell whether shared libraries were disabled because
9643 # the user asked for that or because the platform doesn't support
9644 # them. This is particularly important on AIX, because we don't
9645 # support having both static and shared libraries enabled at the same
9646 # time on that platform, so we default to a shared-only configuration.
9647 # If a disable-shared tag is given, we'll fallback to a static-only
9648 # configuration. But we'll never go from static-only to shared-only.
9649
9650 # ### BEGIN LIBTOOL TAG CONFIG: disable-shared
9651 build_libtool_libs=no
9652 build_old_libs=yes
9653 # ### END LIBTOOL TAG CONFIG: disable-shared
9654
9655 # ### BEGIN LIBTOOL TAG CONFIG: disable-static
9656 build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac`
9657 # ### END LIBTOOL TAG CONFIG: disable-static
9658
9659 # Local Variables:
9660 # mode:shell-script
9661 # sh-indentation:2
9662 # End:
9663 # vi:sw=2
0 #!/bin/sh
1 # Get modification time of a file or directory and pretty-print it.
2
3 scriptversion=2010-08-21.06; # UTC
4
5 # Copyright (C) 1995, 1996, 1997, 2003, 2004, 2005, 2007, 2009, 2010
6 # Free Software Foundation, Inc.
7 # written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, June 1995
8 #
9 # This program is free software; you can redistribute it and/or modify
10 # it under the terms of the GNU General Public License as published by
11 # the Free Software Foundation; either version 2, or (at your option)
12 # any later version.
13 #
14 # This program is distributed in the hope that it will be useful,
15 # but WITHOUT ANY WARRANTY; without even the implied warranty of
16 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 # GNU General Public License for more details.
18 #
19 # You should have received a copy of the GNU General Public License
20 # along with this program. If not, see <https://www.gnu.org/licenses/>.
21
22 # As a special exception to the GNU General Public License, if you
23 # distribute this file as part of a program that contains a
24 # configuration script generated by Autoconf, you may include it under
25 # the same distribution terms that you use for the rest of that program.
26
27 # This file is maintained in Automake, please report
28 # bugs to <bug-automake@gnu.org> or send patches to
29 # <automake-patches@gnu.org>.
30
31 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
32 emulate sh
33 NULLCMD=:
34 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
35 # is contrary to our usage. Disable this feature.
36 alias -g '${1+"$@"}'='"$@"'
37 setopt NO_GLOB_SUBST
38 fi
39
40 case $1 in
41 '')
42 echo "$0: No file. Try \`$0 --help' for more information." 1>&2
43 exit 1;
44 ;;
45 -h | --h*)
46 cat <<\EOF
47 Usage: mdate-sh [--help] [--version] FILE
48
49 Pretty-print the modification day of FILE, in the format:
50 1 January 1970
51
52 Report bugs to <bug-automake@gnu.org>.
53 EOF
54 exit $?
55 ;;
56 -v | --v*)
57 echo "mdate-sh $scriptversion"
58 exit $?
59 ;;
60 esac
61
62 error ()
63 {
64 echo "$0: $1" >&2
65 exit 1
66 }
67
68
69 # Prevent date giving response in another language.
70 LANG=C
71 export LANG
72 LC_ALL=C
73 export LC_ALL
74 LC_TIME=C
75 export LC_TIME
76
77 # GNU ls changes its time format in response to the TIME_STYLE
78 # variable. Since we cannot assume `unset' works, revert this
79 # variable to its documented default.
80 if test "${TIME_STYLE+set}" = set; then
81 TIME_STYLE=posix-long-iso
82 export TIME_STYLE
83 fi
84
85 save_arg1=$1
86
87 # Find out how to get the extended ls output of a file or directory.
88 if ls -L /dev/null 1>/dev/null 2>&1; then
89 ls_command='ls -L -l -d'
90 else
91 ls_command='ls -l -d'
92 fi
93 # Avoid user/group names that might have spaces, when possible.
94 if ls -n /dev/null 1>/dev/null 2>&1; then
95 ls_command="$ls_command -n"
96 fi
97
98 # A `ls -l' line looks as follows on OS/2.
99 # drwxrwx--- 0 Aug 11 2001 foo
100 # This differs from Unix, which adds ownership information.
101 # drwxrwx--- 2 root root 4096 Aug 11 2001 foo
102 #
103 # To find the date, we split the line on spaces and iterate on words
104 # until we find a month. This cannot work with files whose owner is a
105 # user named `Jan', or `Feb', etc. However, it's unlikely that `/'
106 # will be owned by a user whose name is a month. So we first look at
107 # the extended ls output of the root directory to decide how many
108 # words should be skipped to get the date.
109
110 # On HPUX /bin/sh, "set" interprets "-rw-r--r--" as options, so the "x" below.
111 set x`$ls_command /`
112
113 # Find which argument is the month.
114 month=
115 command=
116 until test $month
117 do
118 test $# -gt 0 || error "failed parsing \`$ls_command /' output"
119 shift
120 # Add another shift to the command.
121 command="$command shift;"
122 case $1 in
123 Jan) month=January; nummonth=1;;
124 Feb) month=February; nummonth=2;;
125 Mar) month=March; nummonth=3;;
126 Apr) month=April; nummonth=4;;
127 May) month=May; nummonth=5;;
128 Jun) month=June; nummonth=6;;
129 Jul) month=July; nummonth=7;;
130 Aug) month=August; nummonth=8;;
131 Sep) month=September; nummonth=9;;
132 Oct) month=October; nummonth=10;;
133 Nov) month=November; nummonth=11;;
134 Dec) month=December; nummonth=12;;
135 esac
136 done
137
138 test -n "$month" || error "failed parsing \`$ls_command /' output"
139
140 # Get the extended ls output of the file or directory.
141 set dummy x`eval "$ls_command \"\\\$save_arg1\""`
142
143 # Remove all preceding arguments
144 eval $command
145
146 # Because of the dummy argument above, month is in $2.
147 #
148 # On a POSIX system, we should have
149 #
150 # $# = 5
151 # $1 = file size
152 # $2 = month
153 # $3 = day
154 # $4 = year or time
155 # $5 = filename
156 #
157 # On Darwin 7.7.0 and 7.6.0, we have
158 #
159 # $# = 4
160 # $1 = day
161 # $2 = month
162 # $3 = year or time
163 # $4 = filename
164
165 # Get the month.
166 case $2 in
167 Jan) month=January; nummonth=1;;
168 Feb) month=February; nummonth=2;;
169 Mar) month=March; nummonth=3;;
170 Apr) month=April; nummonth=4;;
171 May) month=May; nummonth=5;;
172 Jun) month=June; nummonth=6;;
173 Jul) month=July; nummonth=7;;
174 Aug) month=August; nummonth=8;;
175 Sep) month=September; nummonth=9;;
176 Oct) month=October; nummonth=10;;
177 Nov) month=November; nummonth=11;;
178 Dec) month=December; nummonth=12;;
179 esac
180
181 case $3 in
182 ???*) day=$1;;
183 *) day=$3; shift;;
184 esac
185
186 # Here we have to deal with the problem that the ls output gives either
187 # the time of day or the year.
188 case $3 in
189 *:*) set `date`; eval year=\$$#
190 case $2 in
191 Jan) nummonthtod=1;;
192 Feb) nummonthtod=2;;
193 Mar) nummonthtod=3;;
194 Apr) nummonthtod=4;;
195 May) nummonthtod=5;;
196 Jun) nummonthtod=6;;
197 Jul) nummonthtod=7;;
198 Aug) nummonthtod=8;;
199 Sep) nummonthtod=9;;
200 Oct) nummonthtod=10;;
201 Nov) nummonthtod=11;;
202 Dec) nummonthtod=12;;
203 esac
204 # For the first six month of the year the time notation can also
205 # be used for files modified in the last year.
206 if (expr $nummonth \> $nummonthtod) > /dev/null;
207 then
208 year=`expr $year - 1`
209 fi;;
210 *) year=$3;;
211 esac
212
213 # The result.
214 echo $day $month $year
215
216 # Local Variables:
217 # mode: shell-script
218 # sh-indentation: 2
219 # eval: (add-hook 'write-file-hooks 'time-stamp)
220 # time-stamp-start: "scriptversion="
221 # time-stamp-format: "%:y-%02m-%02d.%02H"
222 # time-stamp-time-zone: "UTC"
223 # time-stamp-end: "; # UTC"
224 # End:
0 #! /bin/sh
1 # Common wrapper for a few potentially missing GNU programs.
2
3 scriptversion=2013-10-28.13; # UTC
4
5 # Copyright (C) 1996-2013 Free Software Foundation, Inc.
6 # Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
7
8 # This program is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation; either version 2, or (at your option)
11 # any later version.
12
13 # This program is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
17
18 # You should have received a copy of the GNU General Public License
19 # along with this program. If not, see <https://www.gnu.org/licenses/>.
20
21 # As a special exception to the GNU General Public License, if you
22 # distribute this file as part of a program that contains a
23 # configuration script generated by Autoconf, you may include it under
24 # the same distribution terms that you use for the rest of that program.
25
26 if test $# -eq 0; then
27 echo 1>&2 "Try '$0 --help' for more information"
28 exit 1
29 fi
30
31 case $1 in
32
33 --is-lightweight)
34 # Used by our autoconf macros to check whether the available missing
35 # script is modern enough.
36 exit 0
37 ;;
38
39 --run)
40 # Back-compat with the calling convention used by older automake.
41 shift
42 ;;
43
44 -h|--h|--he|--hel|--help)
45 echo "\
46 $0 [OPTION]... PROGRAM [ARGUMENT]...
47
48 Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due
49 to PROGRAM being missing or too old.
50
51 Options:
52 -h, --help display this help and exit
53 -v, --version output version information and exit
54
55 Supported PROGRAM values:
56 aclocal autoconf autoheader autom4te automake makeinfo
57 bison yacc flex lex help2man
58
59 Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and
60 'g' are ignored when checking the name.
61
62 Send bug reports to <bug-automake@gnu.org>."
63 exit $?
64 ;;
65
66 -v|--v|--ve|--ver|--vers|--versi|--versio|--version)
67 echo "missing $scriptversion (GNU Automake)"
68 exit $?
69 ;;
70
71 -*)
72 echo 1>&2 "$0: unknown '$1' option"
73 echo 1>&2 "Try '$0 --help' for more information"
74 exit 1
75 ;;
76
77 esac
78
79 # Run the given program, remember its exit status.
80 "$@"; st=$?
81
82 # If it succeeded, we are done.
83 test $st -eq 0 && exit 0
84
85 # Also exit now if we it failed (or wasn't found), and '--version' was
86 # passed; such an option is passed most likely to detect whether the
87 # program is present and works.
88 case $2 in --version|--help) exit $st;; esac
89
90 # Exit code 63 means version mismatch. This often happens when the user
91 # tries to use an ancient version of a tool on a file that requires a
92 # minimum version.
93 if test $st -eq 63; then
94 msg="probably too old"
95 elif test $st -eq 127; then
96 # Program was missing.
97 msg="missing on your system"
98 else
99 # Program was found and executed, but failed. Give up.
100 exit $st
101 fi
102
103 perl_URL=http://www.perl.org/
104 flex_URL=http://flex.sourceforge.net/
105 gnu_software_URL=https://www.gnu.org/software
106
107 program_details ()
108 {
109 case $1 in
110 aclocal|automake)
111 echo "The '$1' program is part of the GNU Automake package:"
112 echo "<$gnu_software_URL/automake>"
113 echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:"
114 echo "<$gnu_software_URL/autoconf>"
115 echo "<$gnu_software_URL/m4/>"
116 echo "<$perl_URL>"
117 ;;
118 autoconf|autom4te|autoheader)
119 echo "The '$1' program is part of the GNU Autoconf package:"
120 echo "<$gnu_software_URL/autoconf/>"
121 echo "It also requires GNU m4 and Perl in order to run:"
122 echo "<$gnu_software_URL/m4/>"
123 echo "<$perl_URL>"
124 ;;
125 esac
126 }
127
128 give_advice ()
129 {
130 # Normalize program name to check for.
131 normalized_program=`echo "$1" | sed '
132 s/^gnu-//; t
133 s/^gnu//; t
134 s/^g//; t'`
135
136 printf '%s\n' "'$1' is $msg."
137
138 configure_deps="'configure.ac' or m4 files included by 'configure.ac'"
139 case $normalized_program in
140 autoconf*)
141 echo "You should only need it if you modified 'configure.ac',"
142 echo "or m4 files included by it."
143 program_details 'autoconf'
144 ;;
145 autoheader*)
146 echo "You should only need it if you modified 'acconfig.h' or"
147 echo "$configure_deps."
148 program_details 'autoheader'
149 ;;
150 automake*)
151 echo "You should only need it if you modified 'Makefile.am' or"
152 echo "$configure_deps."
153 program_details 'automake'
154 ;;
155 aclocal*)
156 echo "You should only need it if you modified 'acinclude.m4' or"
157 echo "$configure_deps."
158 program_details 'aclocal'
159 ;;
160 autom4te*)
161 echo "You might have modified some maintainer files that require"
162 echo "the 'autom4te' program to be rebuilt."
163 program_details 'autom4te'
164 ;;
165 bison*|yacc*)
166 echo "You should only need it if you modified a '.y' file."
167 echo "You may want to install the GNU Bison package:"
168 echo "<$gnu_software_URL/bison/>"
169 ;;
170 lex*|flex*)
171 echo "You should only need it if you modified a '.l' file."
172 echo "You may want to install the Fast Lexical Analyzer package:"
173 echo "<$flex_URL>"
174 ;;
175 help2man*)
176 echo "You should only need it if you modified a dependency" \
177 "of a man page."
178 echo "You may want to install the GNU Help2man package:"
179 echo "<$gnu_software_URL/help2man/>"
180 ;;
181 makeinfo*)
182 echo "You should only need it if you modified a '.texi' file, or"
183 echo "any other file indirectly affecting the aspect of the manual."
184 echo "You might want to install the Texinfo package:"
185 echo "<$gnu_software_URL/texinfo/>"
186 echo "The spurious makeinfo call might also be the consequence of"
187 echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might"
188 echo "want to install GNU make:"
189 echo "<$gnu_software_URL/make/>"
190 ;;
191 *)
192 echo "You might have modified some files without having the proper"
193 echo "tools for further handling them. Check the 'README' file, it"
194 echo "often tells you about the needed prerequisites for installing"
195 echo "this package. You may also peek at any GNU archive site, in"
196 echo "case some other package contains this missing '$1' program."
197 ;;
198 esac
199 }
200
201 give_advice "$1" | sed -e '1s/^/WARNING: /' \
202 -e '2,$s/^/ /' >&2
203
204 # Propagate the correct exit status (expected to be 127 for a program
205 # not found, 63 for a program that failed due to version mismatch).
206 exit $st
207
208 # Local variables:
209 # eval: (add-hook 'write-file-hooks 'time-stamp)
210 # time-stamp-start: "scriptversion="
211 # time-stamp-format: "%:y-%02m-%02d.%02H"
212 # time-stamp-time-zone: "UTC"
213 # time-stamp-end: "; # UTC"
214 # End:
0 #! /bin/sh
1 # mkinstalldirs --- make directory hierarchy
2
3 scriptversion=2006-05-11.19
4
5 # Original author: Noah Friedman <friedman@prep.ai.mit.edu>
6 # Created: 1993-05-16
7 # Public domain.
8 #
9 # This file is maintained in Automake, please report
10 # bugs to <bug-automake@gnu.org> or send patches to
11 # <automake-patches@gnu.org>.
12
13 nl='
14 '
15 IFS=" "" $nl"
16 errstatus=0
17 dirmode=
18
19 usage="\
20 Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ...
21
22 Create each directory DIR (with mode MODE, if specified), including all
23 leading file name components.
24
25 Report bugs to <bug-automake@gnu.org>."
26
27 # process command line arguments
28 while test $# -gt 0 ; do
29 case $1 in
30 -h | --help | --h*) # -h for help
31 echo "$usage"
32 exit $?
33 ;;
34 -m) # -m PERM arg
35 shift
36 test $# -eq 0 && { echo "$usage" 1>&2; exit 1; }
37 dirmode=$1
38 shift
39 ;;
40 --version)
41 echo "$0 $scriptversion"
42 exit $?
43 ;;
44 --) # stop option processing
45 shift
46 break
47 ;;
48 -*) # unknown option
49 echo "$usage" 1>&2
50 exit 1
51 ;;
52 *) # first non-opt arg
53 break
54 ;;
55 esac
56 done
57
58 for file
59 do
60 if test -d "$file"; then
61 shift
62 else
63 break
64 fi
65 done
66
67 case $# in
68 0) exit 0 ;;
69 esac
70
71 # Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and
72 # mkdir -p a/c at the same time, both will detect that a is missing,
73 # one will create a, then the other will try to create a and die with
74 # a "File exists" error. This is a problem when calling mkinstalldirs
75 # from a parallel make. We use --version in the probe to restrict
76 # ourselves to GNU mkdir, which is thread-safe.
77 case $dirmode in
78 '')
79 if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
80 echo "mkdir -p -- $*"
81 exec mkdir -p -- "$@"
82 else
83 # On NextStep and OpenStep, the `mkdir' command does not
84 # recognize any option. It will interpret all options as
85 # directories to create, and then abort because `.' already
86 # exists.
87 test -d ./-p && rmdir ./-p
88 test -d ./--version && rmdir ./--version
89 fi
90 ;;
91 *)
92 if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 &&
93 test ! -d ./--version; then
94 echo "mkdir -m $dirmode -p -- $*"
95 exec mkdir -m "$dirmode" -p -- "$@"
96 else
97 # Clean up after NextStep and OpenStep mkdir.
98 for d in ./-m ./-p ./--version "./$dirmode";
99 do
100 test -d $d && rmdir $d
101 done
102 fi
103 ;;
104 esac
105
106 for file
107 do
108 case $file in
109 /*) pathcomp=/ ;;
110 *) pathcomp= ;;
111 esac
112 oIFS=$IFS
113 IFS=/
114 set fnord $file
115 shift
116 IFS=$oIFS
117
118 for d
119 do
120 test "x$d" = x && continue
121
122 pathcomp=$pathcomp$d
123 case $pathcomp in
124 -*) pathcomp=./$pathcomp ;;
125 esac
126
127 if test ! -d "$pathcomp"; then
128 echo "mkdir $pathcomp"
129
130 mkdir "$pathcomp" || lasterr=$?
131
132 if test ! -d "$pathcomp"; then
133 errstatus=$lasterr
134 else
135 if test ! -z "$dirmode"; then
136 echo "chmod $dirmode $pathcomp"
137 lasterr=
138 chmod "$dirmode" "$pathcomp" || lasterr=$?
139
140 if test ! -z "$lasterr"; then
141 errstatus=$lasterr
142 fi
143 fi
144 fi
145 fi
146
147 pathcomp=$pathcomp/
148 done
149 done
150
151 exit $errstatus
152
153 # Local Variables:
154 # mode: shell-script
155 # sh-indentation: 2
156 # eval: (add-hook 'write-file-hooks 'time-stamp)
157 # time-stamp-start: "scriptversion="
158 # time-stamp-format: "%:y-%02m-%02d.%02H"
159 # time-stamp-end: "$"
160 # End:
0 % texinfo.tex -- TeX macros to handle Texinfo files.
1 %
2 % Load plain if necessary, i.e., if running under initex.
3 \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
4 %
5 \def\texinfoversion{2013-02-25.14}
6 %
7 % Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
8 % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
9 % 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
10 %
11 % This texinfo.tex file is free software: you can redistribute it and/or
12 % modify it under the terms of the GNU General Public License as
13 % published by the Free Software Foundation, either version 3 of the
14 % License, or (at your option) any later version.
15 %
16 % This texinfo.tex file is distributed in the hope that it will be
17 % useful, but WITHOUT ANY WARRANTY; without even the implied warranty
18 % of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 % General Public License for more details.
20 %
21 % You should have received a copy of the GNU General Public License
22 % along with this program. If not, see <https://www.gnu.org/licenses/>.
23 %
24 % As a special exception, when this file is read by TeX when processing
25 % a Texinfo source document, you may use the result without
26 % restriction. This Exception is an additional permission under section 7
27 % of the GNU General Public License, version 3 ("GPLv3").
28 %
29 % Please try the latest version of texinfo.tex before submitting bug
30 % reports; you can get the latest version from:
31 % http://ftp.gnu.org/gnu/texinfo/ (the Texinfo release area), or
32 % http://ftpmirror.gnu.org/texinfo/ (same, via a mirror), or
33 % https://www.gnu.org/software/texinfo/ (the Texinfo home page)
34 % The texinfo.tex in any given distribution could well be out
35 % of date, so if that's what you're using, please check.
36 %
37 % Send bug reports to bug-texinfo@gnu.org. Please include including a
38 % complete document in each bug report with which we can reproduce the
39 % problem. Patches are, of course, greatly appreciated.
40 %
41 % To process a Texinfo manual with TeX, it's most reliable to use the
42 % texi2dvi shell script that comes with the distribution. For a simple
43 % manual foo.texi, however, you can get away with this:
44 % tex foo.texi
45 % texindex foo.??
46 % tex foo.texi
47 % tex foo.texi
48 % dvips foo.dvi -o # or whatever; this makes foo.ps.
49 % The extra TeX runs get the cross-reference information correct.
50 % Sometimes one run after texindex suffices, and sometimes you need more
51 % than two; texi2dvi does it as many times as necessary.
52 %
53 % It is possible to adapt texinfo.tex for other languages, to some
54 % extent. You can get the existing language-specific files from the
55 % full Texinfo distribution.
56 %
57 % The GNU Texinfo home page is https://www.gnu.org/software/texinfo.
58
59
60 \message{Loading texinfo [version \texinfoversion]:}
61
62 % If in a .fmt file, print the version number
63 % and turn on active characters that we couldn't do earlier because
64 % they might have appeared in the input file name.
65 \everyjob{\message{[Texinfo version \texinfoversion]}%
66 \catcode`+=\active \catcode`\_=\active}
67
68 \chardef\other=12
69
70 % We never want plain's \outer definition of \+ in Texinfo.
71 % For @tex, we can use \tabalign.
72 \let\+ = \relax
73
74 % Save some plain tex macros whose names we will redefine.
75 \let\ptexb=\b
76 \let\ptexbullet=\bullet
77 \let\ptexc=\c
78 \let\ptexcomma=\,
79 \let\ptexdot=\.
80 \let\ptexdots=\dots
81 \let\ptexend=\end
82 \let\ptexequiv=\equiv
83 \let\ptexexclam=\!
84 \let\ptexfootnote=\footnote
85 \let\ptexgtr=>
86 \let\ptexhat=^
87 \let\ptexi=\i
88 \let\ptexindent=\indent
89 \let\ptexinsert=\insert
90 \let\ptexlbrace=\{
91 \let\ptexless=<
92 \let\ptexnewwrite\newwrite
93 \let\ptexnoindent=\noindent
94 \let\ptexplus=+
95 \let\ptexraggedright=\raggedright
96 \let\ptexrbrace=\}
97 \let\ptexslash=\/
98 \let\ptexstar=\*
99 \let\ptext=\t
100 \let\ptextop=\top
101 {\catcode`\'=\active \global\let\ptexquoteright'}% active in plain's math mode
102
103 % If this character appears in an error message or help string, it
104 % starts a new line in the output.
105 \newlinechar = `^^J
106
107 % Use TeX 3.0's \inputlineno to get the line number, for better error
108 % messages, but if we're using an old version of TeX, don't do anything.
109 %
110 \ifx\inputlineno\thisisundefined
111 \let\linenumber = \empty % Pre-3.0.
112 \else
113 \def\linenumber{l.\the\inputlineno:\space}
114 \fi
115
116 % Set up fixed words for English if not already set.
117 \ifx\putwordAppendix\undefined \gdef\putwordAppendix{Appendix}\fi
118 \ifx\putwordChapter\undefined \gdef\putwordChapter{Chapter}\fi
119 \ifx\putworderror\undefined \gdef\putworderror{error}\fi
120 \ifx\putwordfile\undefined \gdef\putwordfile{file}\fi
121 \ifx\putwordin\undefined \gdef\putwordin{in}\fi
122 \ifx\putwordIndexIsEmpty\undefined \gdef\putwordIndexIsEmpty{(Index is empty)}\fi
123 \ifx\putwordIndexNonexistent\undefined \gdef\putwordIndexNonexistent{(Index is nonexistent)}\fi
124 \ifx\putwordInfo\undefined \gdef\putwordInfo{Info}\fi
125 \ifx\putwordInstanceVariableof\undefined \gdef\putwordInstanceVariableof{Instance Variable of}\fi
126 \ifx\putwordMethodon\undefined \gdef\putwordMethodon{Method on}\fi
127 \ifx\putwordNoTitle\undefined \gdef\putwordNoTitle{No Title}\fi
128 \ifx\putwordof\undefined \gdef\putwordof{of}\fi
129 \ifx\putwordon\undefined \gdef\putwordon{on}\fi
130 \ifx\putwordpage\undefined \gdef\putwordpage{page}\fi
131 \ifx\putwordsection\undefined \gdef\putwordsection{section}\fi
132 \ifx\putwordSection\undefined \gdef\putwordSection{Section}\fi
133 \ifx\putwordsee\undefined \gdef\putwordsee{see}\fi
134 \ifx\putwordSee\undefined \gdef\putwordSee{See}\fi
135 \ifx\putwordShortTOC\undefined \gdef\putwordShortTOC{Short Contents}\fi
136 \ifx\putwordTOC\undefined \gdef\putwordTOC{Table of Contents}\fi
137 %
138 \ifx\putwordMJan\undefined \gdef\putwordMJan{January}\fi
139 \ifx\putwordMFeb\undefined \gdef\putwordMFeb{February}\fi
140 \ifx\putwordMMar\undefined \gdef\putwordMMar{March}\fi
141 \ifx\putwordMApr\undefined \gdef\putwordMApr{April}\fi
142 \ifx\putwordMMay\undefined \gdef\putwordMMay{May}\fi
143 \ifx\putwordMJun\undefined \gdef\putwordMJun{June}\fi
144 \ifx\putwordMJul\undefined \gdef\putwordMJul{July}\fi
145 \ifx\putwordMAug\undefined \gdef\putwordMAug{August}\fi
146 \ifx\putwordMSep\undefined \gdef\putwordMSep{September}\fi
147 \ifx\putwordMOct\undefined \gdef\putwordMOct{October}\fi
148 \ifx\putwordMNov\undefined \gdef\putwordMNov{November}\fi
149 \ifx\putwordMDec\undefined \gdef\putwordMDec{December}\fi
150 %
151 \ifx\putwordDefmac\undefined \gdef\putwordDefmac{Macro}\fi
152 \ifx\putwordDefspec\undefined \gdef\putwordDefspec{Special Form}\fi
153 \ifx\putwordDefvar\undefined \gdef\putwordDefvar{Variable}\fi
154 \ifx\putwordDefopt\undefined \gdef\putwordDefopt{User Option}\fi
155 \ifx\putwordDeffunc\undefined \gdef\putwordDeffunc{Function}\fi
156
157 % Since the category of space is not known, we have to be careful.
158 \chardef\spacecat = 10
159 \def\spaceisspace{\catcode`\ =\spacecat}
160
161 % sometimes characters are active, so we need control sequences.
162 \chardef\ampChar = `\&
163 \chardef\colonChar = `\:
164 \chardef\commaChar = `\,
165 \chardef\dashChar = `\-
166 \chardef\dotChar = `\.
167 \chardef\exclamChar= `\!
168 \chardef\hashChar = `\#
169 \chardef\lquoteChar= `\`
170 \chardef\questChar = `\?
171 \chardef\rquoteChar= `\'
172 \chardef\semiChar = `\;
173 \chardef\slashChar = `\/
174 \chardef\underChar = `\_
175
176 % Ignore a token.
177 %
178 \def\gobble#1{}
179
180 % The following is used inside several \edef's.
181 \def\makecsname#1{\expandafter\noexpand\csname#1\endcsname}
182
183 % Hyphenation fixes.
184 \hyphenation{
185 Flor-i-da Ghost-script Ghost-view Mac-OS Post-Script
186 ap-pen-dix bit-map bit-maps
187 data-base data-bases eshell fall-ing half-way long-est man-u-script
188 man-u-scripts mini-buf-fer mini-buf-fers over-view par-a-digm
189 par-a-digms rath-er rec-tan-gu-lar ro-bot-ics se-vere-ly set-up spa-ces
190 spell-ing spell-ings
191 stand-alone strong-est time-stamp time-stamps which-ever white-space
192 wide-spread wrap-around
193 }
194
195 % Margin to add to right of even pages, to left of odd pages.
196 \newdimen\bindingoffset
197 \newdimen\normaloffset
198 \newdimen\pagewidth \newdimen\pageheight
199
200 % For a final copy, take out the rectangles
201 % that mark overfull boxes (in case you have decided
202 % that the text looks ok even though it passes the margin).
203 %
204 \def\finalout{\overfullrule=0pt }
205
206 % Sometimes it is convenient to have everything in the transcript file
207 % and nothing on the terminal. We don't just call \tracingall here,
208 % since that produces some useless output on the terminal. We also make
209 % some effort to order the tracing commands to reduce output in the log
210 % file; cf. trace.sty in LaTeX.
211 %
212 \def\gloggingall{\begingroup \globaldefs = 1 \loggingall \endgroup}%
213 \def\loggingall{%
214 \tracingstats2
215 \tracingpages1
216 \tracinglostchars2 % 2 gives us more in etex
217 \tracingparagraphs1
218 \tracingoutput1
219 \tracingmacros2
220 \tracingrestores1
221 \showboxbreadth\maxdimen \showboxdepth\maxdimen
222 \ifx\eTeXversion\thisisundefined\else % etex gives us more logging
223 \tracingscantokens1
224 \tracingifs1
225 \tracinggroups1
226 \tracingnesting2
227 \tracingassigns1
228 \fi
229 \tracingcommands3 % 3 gives us more in etex
230 \errorcontextlines16
231 }%
232
233 % @errormsg{MSG}. Do the index-like expansions on MSG, but if things
234 % aren't perfect, it's not the end of the world, being an error message,
235 % after all.
236 %
237 \def\errormsg{\begingroup \indexnofonts \doerrormsg}
238 \def\doerrormsg#1{\errmessage{#1}}
239
240 % add check for \lastpenalty to plain's definitions. If the last thing
241 % we did was a \nobreak, we don't want to insert more space.
242 %
243 \def\smallbreak{\ifnum\lastpenalty<10000\par\ifdim\lastskip<\smallskipamount
244 \removelastskip\penalty-50\smallskip\fi\fi}
245 \def\medbreak{\ifnum\lastpenalty<10000\par\ifdim\lastskip<\medskipamount
246 \removelastskip\penalty-100\medskip\fi\fi}
247 \def\bigbreak{\ifnum\lastpenalty<10000\par\ifdim\lastskip<\bigskipamount
248 \removelastskip\penalty-200\bigskip\fi\fi}
249
250 % Do @cropmarks to get crop marks.
251 %
252 \newif\ifcropmarks
253 \let\cropmarks = \cropmarkstrue
254 %
255 % Dimensions to add cropmarks at corners.
256 % Added by P. A. MacKay, 12 Nov. 1986
257 %
258 \newdimen\outerhsize \newdimen\outervsize % set by the paper size routines
259 \newdimen\cornerlong \cornerlong=1pc
260 \newdimen\cornerthick \cornerthick=.3pt
261 \newdimen\topandbottommargin \topandbottommargin=.75in
262
263 % Output a mark which sets \thischapter, \thissection and \thiscolor.
264 % We dump everything together because we only have one kind of mark.
265 % This works because we only use \botmark / \topmark, not \firstmark.
266 %
267 % A mark contains a subexpression of the \ifcase ... \fi construct.
268 % \get*marks macros below extract the needed part using \ifcase.
269 %
270 % Another complication is to let the user choose whether \thischapter
271 % (\thissection) refers to the chapter (section) in effect at the top
272 % of a page, or that at the bottom of a page. The solution is
273 % described on page 260 of The TeXbook. It involves outputting two
274 % marks for the sectioning macros, one before the section break, and
275 % one after. I won't pretend I can describe this better than DEK...
276 \def\domark{%
277 \toks0=\expandafter{\lastchapterdefs}%
278 \toks2=\expandafter{\lastsectiondefs}%
279 \toks4=\expandafter{\prevchapterdefs}%
280 \toks6=\expandafter{\prevsectiondefs}%
281 \toks8=\expandafter{\lastcolordefs}%
282 \mark{%
283 \the\toks0 \the\toks2
284 \noexpand\or \the\toks4 \the\toks6
285 \noexpand\else \the\toks8
286 }%
287 }
288 % \topmark doesn't work for the very first chapter (after the title
289 % page or the contents), so we use \firstmark there -- this gets us
290 % the mark with the chapter defs, unless the user sneaks in, e.g.,
291 % @setcolor (or @url, or @link, etc.) between @contents and the very
292 % first @chapter.
293 \def\gettopheadingmarks{%
294 \ifcase0\topmark\fi
295 \ifx\thischapter\empty \ifcase0\firstmark\fi \fi
296 }
297 \def\getbottomheadingmarks{\ifcase1\botmark\fi}
298 \def\getcolormarks{\ifcase2\topmark\fi}
299
300 % Avoid "undefined control sequence" errors.
301 \def\lastchapterdefs{}
302 \def\lastsectiondefs{}
303 \def\prevchapterdefs{}
304 \def\prevsectiondefs{}
305 \def\lastcolordefs{}
306
307 % Main output routine.
308 \chardef\PAGE = 255
309 \output = {\onepageout{\pagecontents\PAGE}}
310
311 \newbox\headlinebox
312 \newbox\footlinebox
313
314 % \onepageout takes a vbox as an argument. Note that \pagecontents
315 % does insertions, but you have to call it yourself.
316 \def\onepageout#1{%
317 \ifcropmarks \hoffset=0pt \else \hoffset=\normaloffset \fi
318 %
319 \ifodd\pageno \advance\hoffset by \bindingoffset
320 \else \advance\hoffset by -\bindingoffset\fi
321 %
322 % Do this outside of the \shipout so @code etc. will be expanded in
323 % the headline as they should be, not taken literally (outputting ''code).
324 \ifodd\pageno \getoddheadingmarks \else \getevenheadingmarks \fi
325 \setbox\headlinebox = \vbox{\let\hsize=\pagewidth \makeheadline}%
326 \ifodd\pageno \getoddfootingmarks \else \getevenfootingmarks \fi
327 \setbox\footlinebox = \vbox{\let\hsize=\pagewidth \makefootline}%
328 %
329 {%
330 % Have to do this stuff outside the \shipout because we want it to
331 % take effect in \write's, yet the group defined by the \vbox ends
332 % before the \shipout runs.
333 %
334 \indexdummies % don't expand commands in the output.
335 \normalturnoffactive % \ in index entries must not stay \, e.g., if
336 % the page break happens to be in the middle of an example.
337 % We don't want .vr (or whatever) entries like this:
338 % \entry{{\tt \indexbackslash }acronym}{32}{\code {\acronym}}
339 % "\acronym" won't work when it's read back in;
340 % it needs to be
341 % {\code {{\tt \backslashcurfont }acronym}
342 \shipout\vbox{%
343 % Do this early so pdf references go to the beginning of the page.
344 \ifpdfmakepagedest \pdfdest name{\the\pageno} xyz\fi
345 %
346 \ifcropmarks \vbox to \outervsize\bgroup
347 \hsize = \outerhsize
348 \vskip-\topandbottommargin
349 \vtop to0pt{%
350 \line{\ewtop\hfil\ewtop}%
351 \nointerlineskip
352 \line{%
353 \vbox{\moveleft\cornerthick\nstop}%
354 \hfill
355 \vbox{\moveright\cornerthick\nstop}%
356 }%
357 \vss}%
358 \vskip\topandbottommargin
359 \line\bgroup
360 \hfil % center the page within the outer (page) hsize.
361 \ifodd\pageno\hskip\bindingoffset\fi
362 \vbox\bgroup
363 \fi
364 %
365 \unvbox\headlinebox
366 \pagebody{#1}%
367 \ifdim\ht\footlinebox > 0pt
368 % Only leave this space if the footline is nonempty.
369 % (We lessened \vsize for it in \oddfootingyyy.)
370 % The \baselineskip=24pt in plain's \makefootline has no effect.
371 \vskip 24pt
372 \unvbox\footlinebox
373 \fi
374 %
375 \ifcropmarks
376 \egroup % end of \vbox\bgroup
377 \hfil\egroup % end of (centering) \line\bgroup
378 \vskip\topandbottommargin plus1fill minus1fill
379 \boxmaxdepth = \cornerthick
380 \vbox to0pt{\vss
381 \line{%
382 \vbox{\moveleft\cornerthick\nsbot}%
383 \hfill
384 \vbox{\moveright\cornerthick\nsbot}%
385 }%
386 \nointerlineskip
387 \line{\ewbot\hfil\ewbot}%
388 }%
389 \egroup % \vbox from first cropmarks clause
390 \fi
391 }% end of \shipout\vbox
392 }% end of group with \indexdummies
393 \advancepageno
394 \ifnum\outputpenalty>-20000 \else\dosupereject\fi
395 }
396
397 \newinsert\margin \dimen\margin=\maxdimen
398
399 \def\pagebody#1{\vbox to\pageheight{\boxmaxdepth=\maxdepth #1}}
400 {\catcode`\@ =11
401 \gdef\pagecontents#1{\ifvoid\topins\else\unvbox\topins\fi
402 % marginal hacks, juha@viisa.uucp (Juha Takala)
403 \ifvoid\margin\else % marginal info is present
404 \rlap{\kern\hsize\vbox to\z@{\kern1pt\box\margin \vss}}\fi
405 \dimen@=\dp#1\relax \unvbox#1\relax
406 \ifvoid\footins\else\vskip\skip\footins\footnoterule \unvbox\footins\fi
407 \ifr@ggedbottom \kern-\dimen@ \vfil \fi}
408 }
409
410 % Here are the rules for the cropmarks. Note that they are
411 % offset so that the space between them is truly \outerhsize or \outervsize
412 % (P. A. MacKay, 12 November, 1986)
413 %
414 \def\ewtop{\vrule height\cornerthick depth0pt width\cornerlong}
415 \def\nstop{\vbox
416 {\hrule height\cornerthick depth\cornerlong width\cornerthick}}
417 \def\ewbot{\vrule height0pt depth\cornerthick width\cornerlong}
418 \def\nsbot{\vbox
419 {\hrule height\cornerlong depth\cornerthick width\cornerthick}}
420
421 % Parse an argument, then pass it to #1. The argument is the rest of
422 % the input line (except we remove a trailing comment). #1 should be a
423 % macro which expects an ordinary undelimited TeX argument.
424 %
425 \def\parsearg{\parseargusing{}}
426 \def\parseargusing#1#2{%
427 \def\argtorun{#2}%
428 \begingroup
429 \obeylines
430 \spaceisspace
431 #1%
432 \parseargline\empty% Insert the \empty token, see \finishparsearg below.
433 }
434
435 {\obeylines %
436 \gdef\parseargline#1^^M{%
437 \endgroup % End of the group started in \parsearg.
438 \argremovecomment #1\comment\ArgTerm%
439 }%
440 }
441
442 % First remove any @comment, then any @c comment.
443 \def\argremovecomment#1\comment#2\ArgTerm{\argremovec #1\c\ArgTerm}
444 \def\argremovec#1\c#2\ArgTerm{\argcheckspaces#1\^^M\ArgTerm}
445
446 % Each occurrence of `\^^M' or `<space>\^^M' is replaced by a single space.
447 %
448 % \argremovec might leave us with trailing space, e.g.,
449 % @end itemize @c foo
450 % This space token undergoes the same procedure and is eventually removed
451 % by \finishparsearg.
452 %
453 \def\argcheckspaces#1\^^M{\argcheckspacesX#1\^^M \^^M}
454 \def\argcheckspacesX#1 \^^M{\argcheckspacesY#1\^^M}
455 \def\argcheckspacesY#1\^^M#2\^^M#3\ArgTerm{%
456 \def\temp{#3}%
457 \ifx\temp\empty
458 % Do not use \next, perhaps the caller of \parsearg uses it; reuse \temp:
459 \let\temp\finishparsearg
460 \else
461 \let\temp\argcheckspaces
462 \fi
463 % Put the space token in:
464 \temp#1 #3\ArgTerm
465 }
466
467 % If a _delimited_ argument is enclosed in braces, they get stripped; so
468 % to get _exactly_ the rest of the line, we had to prevent such situation.
469 % We prepended an \empty token at the very beginning and we expand it now,
470 % just before passing the control to \argtorun.
471 % (Similarly, we have to think about #3 of \argcheckspacesY above: it is
472 % either the null string, or it ends with \^^M---thus there is no danger
473 % that a pair of braces would be stripped.
474 %
475 % But first, we have to remove the trailing space token.
476 %
477 \def\finishparsearg#1 \ArgTerm{\expandafter\argtorun\expandafter{#1}}
478
479 % \parseargdef\foo{...}
480 % is roughly equivalent to
481 % \def\foo{\parsearg\Xfoo}
482 % \def\Xfoo#1{...}
483 %
484 % Actually, I use \csname\string\foo\endcsname, ie. \\foo, as it is my
485 % favourite TeX trick. --kasal, 16nov03
486
487 \def\parseargdef#1{%
488 \expandafter \doparseargdef \csname\string#1\endcsname #1%
489 }
490 \def\doparseargdef#1#2{%
491 \def#2{\parsearg#1}%
492 \def#1##1%
493 }
494
495 % Several utility definitions with active space:
496 {
497 \obeyspaces
498 \gdef\obeyedspace{ }
499
500 % Make each space character in the input produce a normal interword
501 % space in the output. Don't allow a line break at this space, as this
502 % is used only in environments like @example, where each line of input
503 % should produce a line of output anyway.
504 %
505 \gdef\sepspaces{\obeyspaces\let =\tie}
506
507 % If an index command is used in an @example environment, any spaces
508 % therein should become regular spaces in the raw index file, not the
509 % expansion of \tie (\leavevmode \penalty \@M \ ).
510 \gdef\unsepspaces{\let =\space}
511 }
512
513
514 \def\flushcr{\ifx\par\lisppar \def\next##1{}\else \let\next=\relax \fi \next}
515
516 % Define the framework for environments in texinfo.tex. It's used like this:
517 %
518 % \envdef\foo{...}
519 % \def\Efoo{...}
520 %
521 % It's the responsibility of \envdef to insert \begingroup before the
522 % actual body; @end closes the group after calling \Efoo. \envdef also
523 % defines \thisenv, so the current environment is known; @end checks
524 % whether the environment name matches. The \checkenv macro can also be
525 % used to check whether the current environment is the one expected.
526 %
527 % Non-false conditionals (@iftex, @ifset) don't fit into this, so they
528 % are not treated as environments; they don't open a group. (The
529 % implementation of @end takes care not to call \endgroup in this
530 % special case.)
531
532
533 % At run-time, environments start with this:
534 \def\startenvironment#1{\begingroup\def\thisenv{#1}}
535 % initialize
536 \let\thisenv\empty
537
538 % ... but they get defined via ``\envdef\foo{...}'':
539 \long\def\envdef#1#2{\def#1{\startenvironment#1#2}}
540 \def\envparseargdef#1#2{\parseargdef#1{\startenvironment#1#2}}
541
542 % Check whether we're in the right environment:
543 \def\checkenv#1{%
544 \def\temp{#1}%
545 \ifx\thisenv\temp
546 \else
547 \badenverr
548 \fi
549 }
550
551 % Environment mismatch, #1 expected:
552 \def\badenverr{%
553 \errhelp = \EMsimple
554 \errmessage{This command can appear only \inenvironment\temp,
555 not \inenvironment\thisenv}%
556 }
557 \def\inenvironment#1{%
558 \ifx#1\empty
559 outside of any environment%
560 \else
561 in environment \expandafter\string#1%
562 \fi
563 }
564
565 % @end foo executes the definition of \Efoo.
566 % But first, it executes a specialized version of \checkenv
567 %
568 \parseargdef\end{%
569 \if 1\csname iscond.#1\endcsname
570 \else
571 % The general wording of \badenverr may not be ideal.
572 \expandafter\checkenv\csname#1\endcsname
573 \csname E#1\endcsname
574 \endgroup
575 \fi
576 }
577
578 \newhelp\EMsimple{Press RETURN to continue.}
579
580
581 % Be sure we're in horizontal mode when doing a tie, since we make space
582 % equivalent to this in @example-like environments. Otherwise, a space
583 % at the beginning of a line will start with \penalty -- and
584 % since \penalty is valid in vertical mode, we'd end up putting the
585 % penalty on the vertical list instead of in the new paragraph.
586 {\catcode`@ = 11
587 % Avoid using \@M directly, because that causes trouble
588 % if the definition is written into an index file.
589 \global\let\tiepenalty = \@M
590 \gdef\tie{\leavevmode\penalty\tiepenalty\ }
591 }
592
593 % @: forces normal size whitespace following.
594 \def\:{\spacefactor=1000 }
595
596 % @* forces a line break.
597 \def\*{\unskip\hfil\break\hbox{}\ignorespaces}
598
599 % @/ allows a line break.
600 \let\/=\allowbreak
601
602 % @. is an end-of-sentence period.
603 \def\.{.\spacefactor=\endofsentencespacefactor\space}
604
605 % @! is an end-of-sentence bang.
606 \def\!{!\spacefactor=\endofsentencespacefactor\space}
607
608 % @? is an end-of-sentence query.
609 \def\?{?\spacefactor=\endofsentencespacefactor\space}
610
611 % @frenchspacing on|off says whether to put extra space after punctuation.
612 %
613 \def\onword{on}
614 \def\offword{off}
615 %
616 \parseargdef\frenchspacing{%
617 \def\temp{#1}%
618 \ifx\temp\onword \plainfrenchspacing
619 \else\ifx\temp\offword \plainnonfrenchspacing
620 \else
621 \errhelp = \EMsimple
622 \errmessage{Unknown @frenchspacing option `\temp', must be on|off}%
623 \fi\fi
624 }
625
626 % @w prevents a word break. Without the \leavevmode, @w at the
627 % beginning of a paragraph, when TeX is still in vertical mode, would
628 % produce a whole line of output instead of starting the paragraph.
629 \def\w#1{\leavevmode\hbox{#1}}
630
631 % @group ... @end group forces ... to be all on one page, by enclosing
632 % it in a TeX vbox. We use \vtop instead of \vbox to construct the box
633 % to keep its height that of a normal line. According to the rules for
634 % \topskip (p.114 of the TeXbook), the glue inserted is
635 % max (\topskip - \ht (first item), 0). If that height is large,
636 % therefore, no glue is inserted, and the space between the headline and
637 % the text is small, which looks bad.
638 %
639 % Another complication is that the group might be very large. This can
640 % cause the glue on the previous page to be unduly stretched, because it
641 % does not have much material. In this case, it's better to add an
642 % explicit \vfill so that the extra space is at the bottom. The
643 % threshold for doing this is if the group is more than \vfilllimit
644 % percent of a page (\vfilllimit can be changed inside of @tex).
645 %
646 \newbox\groupbox
647 \def\vfilllimit{0.7}
648 %
649 \envdef\group{%
650 \ifnum\catcode`\^^M=\active \else
651 \errhelp = \groupinvalidhelp
652 \errmessage{@group invalid in context where filling is enabled}%
653 \fi
654 \startsavinginserts
655 %
656 \setbox\groupbox = \vtop\bgroup
657 % Do @comment since we are called inside an environment such as
658 % @example, where each end-of-line in the input causes an
659 % end-of-line in the output. We don't want the end-of-line after
660 % the `@group' to put extra space in the output. Since @group
661 % should appear on a line by itself (according to the Texinfo
662 % manual), we don't worry about eating any user text.
663 \comment
664 }
665 %
666 % The \vtop produces a box with normal height and large depth; thus, TeX puts
667 % \baselineskip glue before it, and (when the next line of text is done)
668 % \lineskip glue after it. Thus, space below is not quite equal to space
669 % above. But it's pretty close.
670 \def\Egroup{%
671 % To get correct interline space between the last line of the group
672 % and the first line afterwards, we have to propagate \prevdepth.
673 \endgraf % Not \par, as it may have been set to \lisppar.
674 \global\dimen1 = \prevdepth
675 \egroup % End the \vtop.
676 % \dimen0 is the vertical size of the group's box.
677 \dimen0 = \ht\groupbox \advance\dimen0 by \dp\groupbox
678 % \dimen2 is how much space is left on the page (more or less).
679 \dimen2 = \pageheight \advance\dimen2 by -\pagetotal
680 % if the group doesn't fit on the current page, and it's a big big
681 % group, force a page break.
682 \ifdim \dimen0 > \dimen2
683 \ifdim \pagetotal < \vfilllimit\pageheight
684 \page
685 \fi
686 \fi
687 \box\groupbox
688 \prevdepth = \dimen1
689 \checkinserts
690 }
691 %
692 % TeX puts in an \escapechar (i.e., `@') at the beginning of the help
693 % message, so this ends up printing `@group can only ...'.
694 %
695 \newhelp\groupinvalidhelp{%
696 group can only be used in environments such as @example,^^J%
697 where each line of input produces a line of output.}
698
699 % @need space-in-mils
700 % forces a page break if there is not space-in-mils remaining.
701
702 \newdimen\mil \mil=0.001in
703
704 \parseargdef\need{%
705 % Ensure vertical mode, so we don't make a big box in the middle of a
706 % paragraph.
707 \par
708 %
709 % If the @need value is less than one line space, it's useless.
710 \dimen0 = #1\mil
711 \dimen2 = \ht\strutbox
712 \advance\dimen2 by \dp\strutbox
713 \ifdim\dimen0 > \dimen2
714 %
715 % Do a \strut just to make the height of this box be normal, so the
716 % normal leading is inserted relative to the preceding line.
717 % And a page break here is fine.
718 \vtop to #1\mil{\strut\vfil}%
719 %
720 % TeX does not even consider page breaks if a penalty added to the
721 % main vertical list is 10000 or more. But in order to see if the
722 % empty box we just added fits on the page, we must make it consider
723 % page breaks. On the other hand, we don't want to actually break the
724 % page after the empty box. So we use a penalty of 9999.
725 %
726 % There is an extremely small chance that TeX will actually break the
727 % page at this \penalty, if there are no other feasible breakpoints in
728 % sight. (If the user is using lots of big @group commands, which
729 % almost-but-not-quite fill up a page, TeX will have a hard time doing
730 % good page breaking, for example.) However, I could not construct an
731 % example where a page broke at this \penalty; if it happens in a real
732 % document, then we can reconsider our strategy.
733 \penalty9999
734 %
735 % Back up by the size of the box, whether we did a page break or not.
736 \kern -#1\mil
737 %
738 % Do not allow a page break right after this kern.
739 \nobreak
740 \fi
741 }
742
743 % @br forces paragraph break (and is undocumented).
744
745 \let\br = \par
746
747 % @page forces the start of a new page.
748 %
749 \def\page{\par\vfill\supereject}
750
751 % @exdent text....
752 % outputs text on separate line in roman font, starting at standard page margin
753
754 % This records the amount of indent in the innermost environment.
755 % That's how much \exdent should take out.
756 \newskip\exdentamount
757
758 % This defn is used inside fill environments such as @defun.
759 \parseargdef\exdent{\hfil\break\hbox{\kern -\exdentamount{\rm#1}}\hfil\break}
760
761 % This defn is used inside nofill environments such as @example.
762 \parseargdef\nofillexdent{{\advance \leftskip by -\exdentamount
763 \leftline{\hskip\leftskip{\rm#1}}}}
764
765 % @inmargin{WHICH}{TEXT} puts TEXT in the WHICH margin next to the current
766 % paragraph. For more general purposes, use the \margin insertion
767 % class. WHICH is `l' or `r'. Not documented, written for gawk manual.
768 %
769 \newskip\inmarginspacing \inmarginspacing=1cm
770 \def\strutdepth{\dp\strutbox}
771 %
772 \def\doinmargin#1#2{\strut\vadjust{%
773 \nobreak
774 \kern-\strutdepth
775 \vtop to \strutdepth{%
776 \baselineskip=\strutdepth
777 \vss
778 % if you have multiple lines of stuff to put here, you'll need to
779 % make the vbox yourself of the appropriate size.
780 \ifx#1l%
781 \llap{\ignorespaces #2\hskip\inmarginspacing}%
782 \else
783 \rlap{\hskip\hsize \hskip\inmarginspacing \ignorespaces #2}%
784 \fi
785 \null
786 }%
787 }}
788 \def\inleftmargin{\doinmargin l}
789 \def\inrightmargin{\doinmargin r}
790 %
791 % @inmargin{TEXT [, RIGHT-TEXT]}
792 % (if RIGHT-TEXT is given, use TEXT for left page, RIGHT-TEXT for right;
793 % else use TEXT for both).
794 %
795 \def\inmargin#1{\parseinmargin #1,,\finish}
796 \def\parseinmargin#1,#2,#3\finish{% not perfect, but better than nothing.
797 \setbox0 = \hbox{\ignorespaces #2}%
798 \ifdim\wd0 > 0pt
799 \def\lefttext{#1}% have both texts
800 \def\righttext{#2}%
801 \else
802 \def\lefttext{#1}% have only one text
803 \def\righttext{#1}%
804 \fi
805 %
806 \ifodd\pageno
807 \def\temp{\inrightmargin\righttext}% odd page -> outside is right margin
808 \else
809 \def\temp{\inleftmargin\lefttext}%
810 \fi
811 \temp
812 }
813
814 % @| inserts a changebar to the left of the current line. It should
815 % surround any changed text. This approach does *not* work if the
816 % change spans more than two lines of output. To handle that, we would
817 % have adopt a much more difficult approach (putting marks into the main
818 % vertical list for the beginning and end of each change). This command
819 % is not documented, not supported, and doesn't work.
820 %
821 \def\|{%
822 % \vadjust can only be used in horizontal mode.
823 \leavevmode
824 %
825 % Append this vertical mode material after the current line in the output.
826 \vadjust{%
827 % We want to insert a rule with the height and depth of the current
828 % leading; that is exactly what \strutbox is supposed to record.
829 \vskip-\baselineskip
830 %
831 % \vadjust-items are inserted at the left edge of the type. So
832 % the \llap here moves out into the left-hand margin.
833 \llap{%
834 %
835 % For a thicker or thinner bar, change the `1pt'.
836 \vrule height\baselineskip width1pt
837 %
838 % This is the space between the bar and the text.
839 \hskip 12pt
840 }%
841 }%
842 }
843
844 % @include FILE -- \input text of FILE.
845 %
846 \def\include{\parseargusing\filenamecatcodes\includezzz}
847 \def\includezzz#1{%
848 \pushthisfilestack
849 \def\thisfile{#1}%
850 {%
851 \makevalueexpandable % we want to expand any @value in FILE.
852 \turnoffactive % and allow special characters in the expansion
853 \indexnofonts % Allow `@@' and other weird things in file names.
854 \wlog{texinfo.tex: doing @include of #1^^J}%
855 \edef\temp{\noexpand\input #1 }%
856 %
857 % This trickery is to read FILE outside of a group, in case it makes
858 % definitions, etc.
859 \expandafter
860 }\temp
861 \popthisfilestack
862 }
863 \def\filenamecatcodes{%
864 \catcode`\\=\other
865 \catcode`~=\other
866 \catcode`^=\other
867 \catcode`_=\other
868 \catcode`|=\other
869 \catcode`<=\other
870 \catcode`>=\other
871 \catcode`+=\other
872 \catcode`-=\other
873 \catcode`\`=\other
874 \catcode`\'=\other
875 }
876
877 \def\pushthisfilestack{%
878 \expandafter\pushthisfilestackX\popthisfilestack\StackTerm
879 }
880 \def\pushthisfilestackX{%
881 \expandafter\pushthisfilestackY\thisfile\StackTerm
882 }
883 \def\pushthisfilestackY #1\StackTerm #2\StackTerm {%
884 \gdef\popthisfilestack{\gdef\thisfile{#1}\gdef\popthisfilestack{#2}}%
885 }
886
887 \def\popthisfilestack{\errthisfilestackempty}
888 \def\errthisfilestackempty{\errmessage{Internal error:
889 the stack of filenames is empty.}}
890 %
891 \def\thisfile{}
892
893 % @center line
894 % outputs that line, centered.
895 %
896 \parseargdef\center{%
897 \ifhmode
898 \let\centersub\centerH
899 \else
900 \let\centersub\centerV
901 \fi
902 \centersub{\hfil \ignorespaces#1\unskip \hfil}%
903 \let\centersub\relax % don't let the definition persist, just in case
904 }
905 \def\centerH#1{{%
906 \hfil\break
907 \advance\hsize by -\leftskip
908 \advance\hsize by -\rightskip
909 \line{#1}%
910 \break
911 }}
912 %
913 \newcount\centerpenalty
914 \def\centerV#1{%
915 % The idea here is the same as in \startdefun, \cartouche, etc.: if
916 % @center is the first thing after a section heading, we need to wipe
917 % out the negative parskip inserted by \sectionheading, but still
918 % prevent a page break here.
919 \centerpenalty = \lastpenalty
920 \ifnum\centerpenalty>10000 \vskip\parskip \fi
921 \ifnum\centerpenalty>9999 \penalty\centerpenalty \fi
922 \line{\kern\leftskip #1\kern\rightskip}%
923 }
924
925 % @sp n outputs n lines of vertical space
926 %
927 \parseargdef\sp{\vskip #1\baselineskip}
928
929 % @comment ...line which is ignored...
930 % @c is the same as @comment
931 % @ignore ... @end ignore is another way to write a comment
932 %
933 \def\comment{\begingroup \catcode`\^^M=\other%
934 \catcode`\@=\other \catcode`\{=\other \catcode`\}=\other%
935 \commentxxx}
936 {\catcode`\^^M=\other \gdef\commentxxx#1^^M{\endgroup}}
937 %
938 \let\c=\comment
939
940 % @paragraphindent NCHARS
941 % We'll use ems for NCHARS, close enough.
942 % NCHARS can also be the word `asis' or `none'.
943 % We cannot feasibly implement @paragraphindent asis, though.
944 %
945 \def\asisword{asis} % no translation, these are keywords
946 \def\noneword{none}
947 %
948 \parseargdef\paragraphindent{%
949 \def\temp{#1}%
950 \ifx\temp\asisword
951 \else
952 \ifx\temp\noneword
953 \defaultparindent = 0pt
954 \else
955 \defaultparindent = #1em
956 \fi
957 \fi
958 \parindent = \defaultparindent
959 }
960
961 % @exampleindent NCHARS
962 % We'll use ems for NCHARS like @paragraphindent.
963 % It seems @exampleindent asis isn't necessary, but
964 % I preserve it to make it similar to @paragraphindent.
965 \parseargdef\exampleindent{%
966 \def\temp{#1}%
967 \ifx\temp\asisword
968 \else
969 \ifx\temp\noneword
970 \lispnarrowing = 0pt
971 \else
972 \lispnarrowing = #1em
973 \fi
974 \fi
975 }
976
977 % @firstparagraphindent WORD
978 % If WORD is `none', then suppress indentation of the first paragraph
979 % after a section heading. If WORD is `insert', then do indent at such
980 % paragraphs.
981 %
982 % The paragraph indentation is suppressed or not by calling
983 % \suppressfirstparagraphindent, which the sectioning commands do.
984 % We switch the definition of this back and forth according to WORD.
985 % By default, we suppress indentation.
986 %
987 \def\suppressfirstparagraphindent{\dosuppressfirstparagraphindent}
988 \def\insertword{insert}
989 %
990 \parseargdef\firstparagraphindent{%
991 \def\temp{#1}%
992 \ifx\temp\noneword
993 \let\suppressfirstparagraphindent = \dosuppressfirstparagraphindent
994 \else\ifx\temp\insertword
995 \let\suppressfirstparagraphindent = \relax
996 \else
997 \errhelp = \EMsimple
998 \errmessage{Unknown @firstparagraphindent option `\temp'}%
999 \fi\fi
1000 }
1001
1002 % Here is how we actually suppress indentation. Redefine \everypar to
1003 % \kern backwards by \parindent, and then reset itself to empty.
1004 %
1005 % We also make \indent itself not actually do anything until the next
1006 % paragraph.
1007 %
1008 \gdef\dosuppressfirstparagraphindent{%
1009 \gdef\indent{%
1010 \restorefirstparagraphindent
1011 \indent
1012 }%
1013 \gdef\noindent{%
1014 \restorefirstparagraphindent
1015 \noindent
1016 }%
1017 \global\everypar = {%
1018 \kern -\parindent
1019 \restorefirstparagraphindent
1020 }%
1021 }
1022
1023 \gdef\restorefirstparagraphindent{%
1024 \global \let \indent = \ptexindent
1025 \global \let \noindent = \ptexnoindent
1026 \global \everypar = {}%
1027 }
1028
1029
1030 % @refill is a no-op.
1031 \let\refill=\relax
1032
1033 % If working on a large document in chapters, it is convenient to
1034 % be able to disable indexing, cross-referencing, and contents, for test runs.
1035 % This is done with @novalidate (before @setfilename).
1036 %
1037 \newif\iflinks \linkstrue % by default we want the aux files.
1038 \let\novalidate = \linksfalse
1039
1040 % @setfilename is done at the beginning of every texinfo file.
1041 % So open here the files we need to have open while reading the input.
1042 % This makes it possible to make a .fmt file for texinfo.
1043 \def\setfilename{%
1044 \fixbackslash % Turn off hack to swallow `\input texinfo'.
1045 \iflinks
1046 \tryauxfile
1047 % Open the new aux file. TeX will close it automatically at exit.
1048 \immediate\openout\auxfile=\jobname.aux
1049 \fi % \openindices needs to do some work in any case.
1050 \openindices
1051 \let\setfilename=\comment % Ignore extra @setfilename cmds.
1052 %
1053 % If texinfo.cnf is present on the system, read it.
1054 % Useful for site-wide @afourpaper, etc.
1055 \openin 1 texinfo.cnf
1056 \ifeof 1 \else \input texinfo.cnf \fi
1057 \closein 1
1058 %
1059 \comment % Ignore the actual filename.
1060 }
1061
1062 % Called from \setfilename.
1063 %
1064 \def\openindices{%
1065 \newindex{cp}%
1066 \newcodeindex{fn}%
1067 \newcodeindex{vr}%
1068 \newcodeindex{tp}%
1069 \newcodeindex{ky}%
1070 \newcodeindex{pg}%
1071 }
1072
1073 % @bye.
1074 \outer\def\bye{\pagealignmacro\tracingstats=1\ptexend}
1075
1076
1077 \message{pdf,}
1078 % adobe `portable' document format
1079 \newcount\tempnum
1080 \newcount\lnkcount
1081 \newtoks\filename
1082 \newcount\filenamelength
1083 \newcount\pgn
1084 \newtoks\toksA
1085 \newtoks\toksB
1086 \newtoks\toksC
1087 \newtoks\toksD
1088 \newbox\boxA
1089 \newcount\countA
1090 \newif\ifpdf
1091 \newif\ifpdfmakepagedest
1092
1093 % when pdftex is run in dvi mode, \pdfoutput is defined (so \pdfoutput=1
1094 % can be set). So we test for \relax and 0 as well as being undefined.
1095 \ifx\pdfoutput\thisisundefined
1096 \else
1097 \ifx\pdfoutput\relax
1098 \else
1099 \ifcase\pdfoutput
1100 \else
1101 \pdftrue
1102 \fi
1103 \fi
1104 \fi
1105
1106 % PDF uses PostScript string constants for the names of xref targets,
1107 % for display in the outlines, and in other places. Thus, we have to
1108 % double any backslashes. Otherwise, a name like "\node" will be
1109 % interpreted as a newline (\n), followed by o, d, e. Not good.
1110 %
1111 % See http://www.ntg.nl/pipermail/ntg-pdftex/2004-July/000654.html and
1112 % related messages. The final outcome is that it is up to the TeX user
1113 % to double the backslashes and otherwise make the string valid, so
1114 % that's what we do. pdftex 1.30.0 (ca.2005) introduced a primitive to
1115 % do this reliably, so we use it.
1116
1117 % #1 is a control sequence in which to do the replacements,
1118 % which we \xdef.
1119 \def\txiescapepdf#1{%
1120 \ifx\pdfescapestring\thisisundefined
1121 % No primitive available; should we give a warning or log?
1122 % Many times it won't matter.
1123 \else
1124 % The expandable \pdfescapestring primitive escapes parentheses,
1125 % backslashes, and other special chars.
1126 \xdef#1{\pdfescapestring{#1}}%
1127 \fi
1128 }
1129
1130 \newhelp\nopdfimagehelp{Texinfo supports .png, .jpg, .jpeg, and .pdf images
1131 with PDF output, and none of those formats could be found. (.eps cannot
1132 be supported due to the design of the PDF format; use regular TeX (DVI
1133 output) for that.)}
1134
1135 \ifpdf
1136 %
1137 % Color manipulation macros based on pdfcolor.tex,
1138 % except using rgb instead of cmyk; the latter is said to render as a
1139 % very dark gray on-screen and a very dark halftone in print, instead
1140 % of actual black.
1141 \def\rgbDarkRed{0.50 0.09 0.12}
1142 \def\rgbBlack{0 0 0}
1143 %
1144 % k sets the color for filling (usual text, etc.);
1145 % K sets the color for stroking (thin rules, e.g., normal _'s).
1146 \def\pdfsetcolor#1{\pdfliteral{#1 rg #1 RG}}
1147 %
1148 % Set color, and create a mark which defines \thiscolor accordingly,
1149 % so that \makeheadline knows which color to restore.
1150 \def\setcolor#1{%
1151 \xdef\lastcolordefs{\gdef\noexpand\thiscolor{#1}}%
1152 \domark
1153 \pdfsetcolor{#1}%
1154 }
1155 %
1156 \def\maincolor{\rgbBlack}
1157 \pdfsetcolor{\maincolor}
1158 \edef\thiscolor{\maincolor}
1159 \def\lastcolordefs{}
1160 %
1161 \def\makefootline{%
1162 \baselineskip24pt
1163 \line{\pdfsetcolor{\maincolor}\the\footline}%
1164 }
1165 %
1166 \def\makeheadline{%
1167 \vbox to 0pt{%
1168 \vskip-22.5pt
1169 \line{%
1170 \vbox to8.5pt{}%
1171 % Extract \thiscolor definition from the marks.
1172 \getcolormarks
1173 % Typeset the headline with \maincolor, then restore the color.
1174 \pdfsetcolor{\maincolor}\the\headline\pdfsetcolor{\thiscolor}%
1175 }%
1176 \vss
1177 }%
1178 \nointerlineskip
1179 }
1180 %
1181 %
1182 \pdfcatalog{/PageMode /UseOutlines}
1183 %
1184 % #1 is image name, #2 width (might be empty/whitespace), #3 height (ditto).
1185 \def\dopdfimage#1#2#3{%
1186 \def\pdfimagewidth{#2}\setbox0 = \hbox{\ignorespaces #2}%
1187 \def\pdfimageheight{#3}\setbox2 = \hbox{\ignorespaces #3}%
1188 %
1189 % pdftex (and the PDF format) support .pdf, .png, .jpg (among
1190 % others). Let's try in that order, PDF first since if
1191 % someone has a scalable image, presumably better to use that than a
1192 % bitmap.
1193 \let\pdfimgext=\empty
1194 \begingroup
1195 \openin 1 #1.pdf \ifeof 1
1196 \openin 1 #1.PDF \ifeof 1
1197 \openin 1 #1.png \ifeof 1
1198 \openin 1 #1.jpg \ifeof 1
1199 \openin 1 #1.jpeg \ifeof 1
1200 \openin 1 #1.JPG \ifeof 1
1201 \errhelp = \nopdfimagehelp
1202 \errmessage{Could not find image file #1 for pdf}%
1203 \else \gdef\pdfimgext{JPG}%
1204 \fi
1205 \else \gdef\pdfimgext{jpeg}%
1206 \fi
1207 \else \gdef\pdfimgext{jpg}%
1208 \fi
1209 \else \gdef\pdfimgext{png}%
1210 \fi
1211 \else \gdef\pdfimgext{PDF}%
1212 \fi
1213 \else \gdef\pdfimgext{pdf}%
1214 \fi
1215 \closein 1
1216 \endgroup
1217 %
1218 % without \immediate, ancient pdftex seg faults when the same image is
1219 % included twice. (Version 3.14159-pre-1.0-unofficial-20010704.)
1220 \ifnum\pdftexversion < 14
1221 \immediate\pdfimage
1222 \else
1223 \immediate\pdfximage
1224 \fi
1225 \ifdim \wd0 >0pt width \pdfimagewidth \fi
1226 \ifdim \wd2 >0pt height \pdfimageheight \fi
1227 \ifnum\pdftexversion<13
1228 #1.\pdfimgext
1229 \else
1230 {#1.\pdfimgext}%
1231 \fi
1232 \ifnum\pdftexversion < 14 \else
1233 \pdfrefximage \pdflastximage
1234 \fi}
1235 %
1236 \def\pdfmkdest#1{{%
1237 % We have to set dummies so commands such as @code, and characters
1238 % such as \, aren't expanded when present in a section title.
1239 \indexnofonts
1240 \turnoffactive
1241 \makevalueexpandable
1242 \def\pdfdestname{#1}%
1243 \txiescapepdf\pdfdestname
1244 \safewhatsit{\pdfdest name{\pdfdestname} xyz}%
1245 }}
1246 %
1247 % used to mark target names; must be expandable.
1248 \def\pdfmkpgn#1{#1}
1249 %
1250 % by default, use a color that is dark enough to print on paper as
1251 % nearly black, but still distinguishable for online viewing.
1252 \def\urlcolor{\rgbDarkRed}
1253 \def\linkcolor{\rgbDarkRed}
1254 \def\endlink{\setcolor{\maincolor}\pdfendlink}
1255 %
1256 % Adding outlines to PDF; macros for calculating structure of outlines
1257 % come from Petr Olsak
1258 \def\expnumber#1{\expandafter\ifx\csname#1\endcsname\relax 0%
1259 \else \csname#1\endcsname \fi}
1260 \def\advancenumber#1{\tempnum=\expnumber{#1}\relax
1261 \advance\tempnum by 1
1262 \expandafter\xdef\csname#1\endcsname{\the\tempnum}}
1263 %
1264 % #1 is the section text, which is what will be displayed in the
1265 % outline by the pdf viewer. #2 is the pdf expression for the number
1266 % of subentries (or empty, for subsubsections). #3 is the node text,
1267 % which might be empty if this toc entry had no corresponding node.
1268 % #4 is the page number
1269 %
1270 \def\dopdfoutline#1#2#3#4{%
1271 % Generate a link to the node text if that exists; else, use the
1272 % page number. We could generate a destination for the section
1273 % text in the case where a section has no node, but it doesn't
1274 % seem worth the trouble, since most documents are normally structured.
1275 \edef\pdfoutlinedest{#3}%
1276 \ifx\pdfoutlinedest\empty
1277 \def\pdfoutlinedest{#4}%
1278 \else
1279 \txiescapepdf\pdfoutlinedest
1280 \fi
1281 %
1282 % Also escape PDF chars in the display string.
1283 \edef\pdfoutlinetext{#1}%
1284 \txiescapepdf\pdfoutlinetext
1285 %
1286 \pdfoutline goto name{\pdfmkpgn{\pdfoutlinedest}}#2{\pdfoutlinetext}%
1287 }
1288 %
1289 \def\pdfmakeoutlines{%
1290 \begingroup
1291 % Read toc silently, to get counts of subentries for \pdfoutline.
1292 \def\partentry##1##2##3##4{}% ignore parts in the outlines
1293 \def\numchapentry##1##2##3##4{%
1294 \def\thischapnum{##2}%
1295 \def\thissecnum{0}%
1296 \def\thissubsecnum{0}%
1297 }%
1298 \def\numsecentry##1##2##3##4{%
1299 \advancenumber{chap\thischapnum}%
1300 \def\thissecnum{##2}%
1301 \def\thissubsecnum{0}%
1302 }%
1303 \def\numsubsecentry##1##2##3##4{%
1304 \advancenumber{sec\thissecnum}%
1305 \def\thissubsecnum{##2}%
1306 }%
1307 \def\numsubsubsecentry##1##2##3##4{%
1308 \advancenumber{subsec\thissubsecnum}%
1309 }%
1310 \def\thischapnum{0}%
1311 \def\thissecnum{0}%
1312 \def\thissubsecnum{0}%
1313 %
1314 % use \def rather than \let here because we redefine \chapentry et
1315 % al. a second time, below.
1316 \def\appentry{\numchapentry}%
1317 \def\appsecentry{\numsecentry}%
1318 \def\appsubsecentry{\numsubsecentry}%
1319 \def\appsubsubsecentry{\numsubsubsecentry}%
1320 \def\unnchapentry{\numchapentry}%
1321 \def\unnsecentry{\numsecentry}%
1322 \def\unnsubsecentry{\numsubsecentry}%
1323 \def\unnsubsubsecentry{\numsubsubsecentry}%
1324 \readdatafile{toc}%
1325 %
1326 % Read toc second time, this time actually producing the outlines.
1327 % The `-' means take the \expnumber as the absolute number of
1328 % subentries, which we calculated on our first read of the .toc above.
1329 %
1330 % We use the node names as the destinations.
1331 \def\numchapentry##1##2##3##4{%
1332 \dopdfoutline{##1}{count-\expnumber{chap##2}}{##3}{##4}}%
1333 \def\numsecentry##1##2##3##4{%
1334 \dopdfoutline{##1}{count-\expnumber{sec##2}}{##3}{##4}}%
1335 \def\numsubsecentry##1##2##3##4{%
1336 \dopdfoutline{##1}{count-\expnumber{subsec##2}}{##3}{##4}}%
1337 \def\numsubsubsecentry##1##2##3##4{% count is always zero
1338 \dopdfoutline{##1}{}{##3}{##4}}%
1339 %
1340 % PDF outlines are displayed using system fonts, instead of
1341 % document fonts. Therefore we cannot use special characters,
1342 % since the encoding is unknown. For example, the eogonek from
1343 % Latin 2 (0xea) gets translated to a | character. Info from
1344 % Staszek Wawrykiewicz, 19 Jan 2004 04:09:24 +0100.
1345 %
1346 % TODO this right, we have to translate 8-bit characters to
1347 % their "best" equivalent, based on the @documentencoding. Too
1348 % much work for too little return. Just use the ASCII equivalents
1349 % we use for the index sort strings.
1350 %
1351 \indexnofonts
1352 \setupdatafile
1353 % We can have normal brace characters in the PDF outlines, unlike
1354 % Texinfo index files. So set that up.
1355 \def\{{\lbracecharliteral}%
1356 \def\}{\rbracecharliteral}%
1357 \catcode`\\=\active \otherbackslash
1358 \input \tocreadfilename
1359 \endgroup
1360 }
1361 {\catcode`[=1 \catcode`]=2
1362 \catcode`{=\other \catcode`}=\other
1363 \gdef\lbracecharliteral[{]%
1364 \gdef\rbracecharliteral[}]%
1365 ]
1366 %
1367 \def\skipspaces#1{\def\PP{#1}\def\D{|}%
1368 \ifx\PP\D\let\nextsp\relax
1369 \else\let\nextsp\skipspaces
1370 \addtokens{\filename}{\PP}%
1371 \advance\filenamelength by 1
1372 \fi
1373 \nextsp}
1374 \def\getfilename#1{%
1375 \filenamelength=0
1376 % If we don't expand the argument now, \skipspaces will get
1377 % snagged on things like "@value{foo}".
1378 \edef\temp{#1}%
1379 \expandafter\skipspaces\temp|\relax
1380 }
1381 \ifnum\pdftexversion < 14
1382 \let \startlink \pdfannotlink
1383 \else
1384 \let \startlink \pdfstartlink
1385 \fi
1386 % make a live url in pdf output.
1387 \def\pdfurl#1{%
1388 \begingroup
1389 % it seems we really need yet another set of dummies; have not
1390 % tried to figure out what each command should do in the context
1391 % of @url. for now, just make @/ a no-op, that's the only one
1392 % people have actually reported a problem with.
1393 %
1394 \normalturnoffactive
1395 \def\@{@}%
1396 \let\/=\empty
1397 \makevalueexpandable
1398 % do we want to go so far as to use \indexnofonts instead of just
1399 % special-casing \var here?
1400 \def\var##1{##1}%
1401 %
1402 \leavevmode\setcolor{\urlcolor}%
1403 \startlink attr{/Border [0 0 0]}%
1404 user{/Subtype /Link /A << /S /URI /URI (#1) >>}%
1405 \endgroup}
1406 \def\pdfgettoks#1.{\setbox\boxA=\hbox{\toksA={#1.}\toksB={}\maketoks}}
1407 \def\addtokens#1#2{\edef\addtoks{\noexpand#1={\the#1#2}}\addtoks}
1408 \def\adn#1{\addtokens{\toksC}{#1}\global\countA=1\let\next=\maketoks}
1409 \def\poptoks#1#2|ENDTOKS|{\let\first=#1\toksD={#1}\toksA={#2}}
1410 \def\maketoks{%
1411 \expandafter\poptoks\the\toksA|ENDTOKS|\relax
1412 \ifx\first0\adn0
1413 \else\ifx\first1\adn1 \else\ifx\first2\adn2 \else\ifx\first3\adn3
1414 \else\ifx\first4\adn4 \else\ifx\first5\adn5 \else\ifx\first6\adn6
1415 \else\ifx\first7\adn7 \else\ifx\first8\adn8 \else\ifx\first9\adn9
1416 \else
1417 \ifnum0=\countA\else\makelink\fi
1418 \ifx\first.\let\next=\done\else
1419 \let\next=\maketoks
1420 \addtokens{\toksB}{\the\toksD}
1421 \ifx\first,\addtokens{\toksB}{\space}\fi
1422 \fi
1423 \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
1424 \next}
1425 \def\makelink{\addtokens{\toksB}%
1426 {\noexpand\pdflink{\the\toksC}}\toksC={}\global\countA=0}
1427 \def\pdflink#1{%
1428 \startlink attr{/Border [0 0 0]} goto name{\pdfmkpgn{#1}}
1429 \setcolor{\linkcolor}#1\endlink}
1430 \def\done{\edef\st{\global\noexpand\toksA={\the\toksB}}\st}
1431 \else
1432 % non-pdf mode
1433 \let\pdfmkdest = \gobble
1434 \let\pdfurl = \gobble
1435 \let\endlink = \relax
1436 \let\setcolor = \gobble
1437 \let\pdfsetcolor = \gobble
1438 \let\pdfmakeoutlines = \relax
1439 \fi % \ifx\pdfoutput
1440
1441
1442 \message{fonts,}
1443
1444 % Change the current font style to #1, remembering it in \curfontstyle.
1445 % For now, we do not accumulate font styles: @b{@i{foo}} prints foo in
1446 % italics, not bold italics.
1447 %
1448 \def\setfontstyle#1{%
1449 \def\curfontstyle{#1}% not as a control sequence, because we are \edef'd.
1450 \csname ten#1\endcsname % change the current font
1451 }
1452
1453 % Select #1 fonts with the current style.
1454 %
1455 \def\selectfonts#1{\csname #1fonts\endcsname \csname\curfontstyle\endcsname}
1456
1457 \def\rm{\fam=0 \setfontstyle{rm}}
1458 \def\it{\fam=\itfam \setfontstyle{it}}
1459 \def\sl{\fam=\slfam \setfontstyle{sl}}
1460 \def\bf{\fam=\bffam \setfontstyle{bf}}\def\bfstylename{bf}
1461 \def\tt{\fam=\ttfam \setfontstyle{tt}}
1462
1463 % Unfortunately, we have to override this for titles and the like, since
1464 % in those cases "rm" is bold. Sigh.
1465 \def\rmisbold{\rm\def\curfontstyle{bf}}
1466
1467 % Texinfo sort of supports the sans serif font style, which plain TeX does not.
1468 % So we set up a \sf.
1469 \newfam\sffam
1470 \def\sf{\fam=\sffam \setfontstyle{sf}}
1471 \let\li = \sf % Sometimes we call it \li, not \sf.
1472
1473 % We don't need math for this font style.
1474 \def\ttsl{\setfontstyle{ttsl}}
1475
1476
1477 % Set the baselineskip to #1, and the lineskip and strut size
1478 % correspondingly. There is no deep meaning behind these magic numbers
1479 % used as factors; they just match (closely enough) what Knuth defined.
1480 %
1481 \def\lineskipfactor{.08333}
1482 \def\strutheightpercent{.70833}
1483 \def\strutdepthpercent {.29167}
1484 %
1485 % can get a sort of poor man's double spacing by redefining this.
1486 \def\baselinefactor{1}
1487 %
1488 \newdimen\textleading
1489 \def\setleading#1{%
1490 \dimen0 = #1\relax
1491 \normalbaselineskip = \baselinefactor\dimen0
1492 \normallineskip = \lineskipfactor\normalbaselineskip
1493 \normalbaselines
1494 \setbox\strutbox =\hbox{%
1495 \vrule width0pt height\strutheightpercent\baselineskip
1496 depth \strutdepthpercent \baselineskip
1497 }%
1498 }
1499
1500 % PDF CMaps. See also LaTeX's t1.cmap.
1501 %
1502 % do nothing with this by default.
1503 \expandafter\let\csname cmapOT1\endcsname\gobble
1504 \expandafter\let\csname cmapOT1IT\endcsname\gobble
1505 \expandafter\let\csname cmapOT1TT\endcsname\gobble
1506
1507 % if we are producing pdf, and we have \pdffontattr, then define cmaps.
1508 % (\pdffontattr was introduced many years ago, but people still run
1509 % older pdftex's; it's easy to conditionalize, so we do.)
1510 \ifpdf \ifx\pdffontattr\thisisundefined \else
1511 \begingroup
1512 \catcode`\^^M=\active \def^^M{^^J}% Output line endings as the ^^J char.
1513 \catcode`\%=12 \immediate\pdfobj stream {%!PS-Adobe-3.0 Resource-CMap
1514 %%DocumentNeededResources: ProcSet (CIDInit)
1515 %%IncludeResource: ProcSet (CIDInit)
1516 %%BeginResource: CMap (TeX-OT1-0)
1517 %%Title: (TeX-OT1-0 TeX OT1 0)
1518 %%Version: 1.000
1519 %%EndComments
1520 /CIDInit /ProcSet findresource begin
1521 12 dict begin
1522 begincmap
1523 /CIDSystemInfo
1524 << /Registry (TeX)
1525 /Ordering (OT1)
1526 /Supplement 0
1527 >> def
1528 /CMapName /TeX-OT1-0 def
1529 /CMapType 2 def
1530 1 begincodespacerange
1531 <00> <7F>
1532 endcodespacerange
1533 8 beginbfrange
1534 <00> <01> <0393>
1535 <09> <0A> <03A8>
1536 <23> <26> <0023>
1537 <28> <3B> <0028>
1538 <3F> <5B> <003F>
1539 <5D> <5E> <005D>
1540 <61> <7A> <0061>
1541 <7B> <7C> <2013>
1542 endbfrange
1543 40 beginbfchar
1544 <02> <0398>
1545 <03> <039B>
1546 <04> <039E>
1547 <05> <03A0>
1548 <06> <03A3>
1549 <07> <03D2>
1550 <08> <03A6>
1551 <0B> <00660066>
1552 <0C> <00660069>
1553 <0D> <0066006C>
1554 <0E> <006600660069>
1555 <0F> <00660066006C>
1556 <10> <0131>
1557 <11> <0237>
1558 <12> <0060>
1559 <13> <00B4>
1560 <14> <02C7>
1561 <15> <02D8>
1562 <16> <00AF>
1563 <17> <02DA>
1564 <18> <00B8>
1565 <19> <00DF>
1566 <1A> <00E6>
1567 <1B> <0153>
1568 <1C> <00F8>
1569 <1D> <00C6>
1570 <1E> <0152>
1571 <1F> <00D8>
1572 <21> <0021>
1573 <22> <201D>
1574 <27> <2019>
1575 <3C> <00A1>
1576 <3D> <003D>
1577 <3E> <00BF>
1578 <5C> <201C>
1579 <5F> <02D9>
1580 <60> <2018>
1581 <7D> <02DD>
1582 <7E> <007E>
1583 <7F> <00A8>
1584 endbfchar
1585 endcmap
1586 CMapName currentdict /CMap defineresource pop
1587 end
1588 end
1589 %%EndResource
1590 %%EOF
1591 }\endgroup
1592 \expandafter\edef\csname cmapOT1\endcsname#1{%
1593 \pdffontattr#1{/ToUnicode \the\pdflastobj\space 0 R}%
1594 }%
1595 %
1596 % \cmapOT1IT
1597 \begingroup
1598 \catcode`\^^M=\active \def^^M{^^J}% Output line endings as the ^^J char.
1599 \catcode`\%=12 \immediate\pdfobj stream {%!PS-Adobe-3.0 Resource-CMap
1600 %%DocumentNeededResources: ProcSet (CIDInit)
1601 %%IncludeResource: ProcSet (CIDInit)
1602 %%BeginResource: CMap (TeX-OT1IT-0)
1603 %%Title: (TeX-OT1IT-0 TeX OT1IT 0)
1604 %%Version: 1.000
1605 %%EndComments
1606 /CIDInit /ProcSet findresource begin
1607 12 dict begin
1608 begincmap
1609 /CIDSystemInfo
1610 << /Registry (TeX)
1611 /Ordering (OT1IT)
1612 /Supplement 0
1613 >> def
1614 /CMapName /TeX-OT1IT-0 def
1615 /CMapType 2 def
1616 1 begincodespacerange
1617 <00> <7F>
1618 endcodespacerange
1619 8 beginbfrange
1620 <00> <01> <0393>
1621 <09> <0A> <03A8>
1622 <25> <26> <0025>
1623 <28> <3B> <0028>
1624 <3F> <5B> <003F>
1625 <5D> <5E> <005D>
1626 <61> <7A> <0061>
1627 <7B> <7C> <2013>
1628 endbfrange
1629 42 beginbfchar
1630 <02> <0398>
1631 <03> <039B>
1632 <04> <039E>
1633 <05> <03A0>
1634 <06> <03A3>
1635 <07> <03D2>
1636 <08> <03A6>
1637 <0B> <00660066>
1638 <0C> <00660069>
1639 <0D> <0066006C>
1640 <0E> <006600660069>
1641 <0F> <00660066006C>
1642 <10> <0131>
1643 <11> <0237>
1644 <12> <0060>
1645 <13> <00B4>
1646 <14> <02C7>
1647 <15> <02D8>
1648 <16> <00AF>
1649 <17> <02DA>
1650 <18> <00B8>
1651 <19> <00DF>
1652 <1A> <00E6>
1653 <1B> <0153>
1654 <1C> <00F8>
1655 <1D> <00C6>
1656 <1E> <0152>
1657 <1F> <00D8>
1658 <21> <0021>
1659 <22> <201D>
1660 <23> <0023>
1661 <24> <00A3>
1662 <27> <2019>
1663 <3C> <00A1>
1664 <3D> <003D>
1665 <3E> <00BF>
1666 <5C> <201C>
1667 <5F> <02D9>
1668 <60> <2018>
1669 <7D> <02DD>
1670 <7E> <007E>
1671 <7F> <00A8>
1672 endbfchar
1673 endcmap
1674 CMapName currentdict /CMap defineresource pop
1675 end
1676 end
1677 %%EndResource
1678 %%EOF
1679 }\endgroup
1680 \expandafter\edef\csname cmapOT1IT\endcsname#1{%
1681 \pdffontattr#1{/ToUnicode \the\pdflastobj\space 0 R}%
1682 }%
1683 %
1684 % \cmapOT1TT
1685 \begingroup
1686 \catcode`\^^M=\active \def^^M{^^J}% Output line endings as the ^^J char.
1687 \catcode`\%=12 \immediate\pdfobj stream {%!PS-Adobe-3.0 Resource-CMap
1688 %%DocumentNeededResources: ProcSet (CIDInit)
1689 %%IncludeResource: ProcSet (CIDInit)
1690 %%BeginResource: CMap (TeX-OT1TT-0)
1691 %%Title: (TeX-OT1TT-0 TeX OT1TT 0)
1692 %%Version: 1.000
1693 %%EndComments
1694 /CIDInit /ProcSet findresource begin
1695 12 dict begin
1696 begincmap
1697 /CIDSystemInfo
1698 << /Registry (TeX)
1699 /Ordering (OT1TT)
1700 /Supplement 0
1701 >> def
1702 /CMapName /TeX-OT1TT-0 def
1703 /CMapType 2 def
1704 1 begincodespacerange
1705 <00> <7F>
1706 endcodespacerange
1707 5 beginbfrange
1708 <00> <01> <0393>
1709 <09> <0A> <03A8>
1710 <21> <26> <0021>
1711 <28> <5F> <0028>
1712 <61> <7E> <0061>
1713 endbfrange
1714 32 beginbfchar
1715 <02> <0398>
1716 <03> <039B>
1717 <04> <039E>
1718 <05> <03A0>
1719 <06> <03A3>
1720 <07> <03D2>
1721 <08> <03A6>
1722 <0B> <2191>
1723 <0C> <2193>
1724 <0D> <0027>
1725 <0E> <00A1>
1726 <0F> <00BF>
1727 <10> <0131>
1728 <11> <0237>
1729 <12> <0060>
1730 <13> <00B4>
1731 <14> <02C7>
1732 <15> <02D8>
1733 <16> <00AF>
1734 <17> <02DA>
1735 <18> <00B8>
1736 <19> <00DF>
1737 <1A> <00E6>
1738 <1B> <0153>
1739 <1C> <00F8>
1740 <1D> <00C6>
1741 <1E> <0152>
1742 <1F> <00D8>
1743 <20> <2423>
1744 <27> <2019>
1745 <60> <2018>
1746 <7F> <00A8>
1747 endbfchar
1748 endcmap
1749 CMapName currentdict /CMap defineresource pop
1750 end
1751 end
1752 %%EndResource
1753 %%EOF
1754 }\endgroup
1755 \expandafter\edef\csname cmapOT1TT\endcsname#1{%
1756 \pdffontattr#1{/ToUnicode \the\pdflastobj\space 0 R}%
1757 }%
1758 \fi\fi
1759
1760
1761 % Set the font macro #1 to the font named \fontprefix#2.
1762 % #3 is the font's design size, #4 is a scale factor, #5 is the CMap
1763 % encoding (only OT1, OT1IT and OT1TT are allowed, or empty to omit).
1764 % Example:
1765 % #1 = \textrm
1766 % #2 = \rmshape
1767 % #3 = 10
1768 % #4 = \mainmagstep
1769 % #5 = OT1
1770 %
1771 \def\setfont#1#2#3#4#5{%
1772 \font#1=\fontprefix#2#3 scaled #4
1773 \csname cmap#5\endcsname#1%
1774 }
1775 % This is what gets called when #5 of \setfont is empty.
1776 \let\cmap\gobble
1777 %
1778 % (end of cmaps)
1779
1780 % Use cm as the default font prefix.
1781 % To specify the font prefix, you must define \fontprefix
1782 % before you read in texinfo.tex.
1783 \ifx\fontprefix\thisisundefined
1784 \def\fontprefix{cm}
1785 \fi
1786 % Support font families that don't use the same naming scheme as CM.
1787 \def\rmshape{r}
1788 \def\rmbshape{bx} % where the normal face is bold
1789 \def\bfshape{b}
1790 \def\bxshape{bx}
1791 \def\ttshape{tt}
1792 \def\ttbshape{tt}
1793 \def\ttslshape{sltt}
1794 \def\itshape{ti}
1795 \def\itbshape{bxti}
1796 \def\slshape{sl}
1797 \def\slbshape{bxsl}
1798 \def\sfshape{ss}
1799 \def\sfbshape{ss}
1800 \def\scshape{csc}
1801 \def\scbshape{csc}
1802
1803 % Definitions for a main text size of 11pt. (The default in Texinfo.)
1804 %
1805 \def\definetextfontsizexi{%
1806 % Text fonts (11.2pt, magstep1).
1807 \def\textnominalsize{11pt}
1808 \edef\mainmagstep{\magstephalf}
1809 \setfont\textrm\rmshape{10}{\mainmagstep}{OT1}
1810 \setfont\texttt\ttshape{10}{\mainmagstep}{OT1TT}
1811 \setfont\textbf\bfshape{10}{\mainmagstep}{OT1}
1812 \setfont\textit\itshape{10}{\mainmagstep}{OT1IT}
1813 \setfont\textsl\slshape{10}{\mainmagstep}{OT1}
1814 \setfont\textsf\sfshape{10}{\mainmagstep}{OT1}
1815 \setfont\textsc\scshape{10}{\mainmagstep}{OT1}
1816 \setfont\textttsl\ttslshape{10}{\mainmagstep}{OT1TT}
1817 \font\texti=cmmi10 scaled \mainmagstep
1818 \font\textsy=cmsy10 scaled \mainmagstep
1819 \def\textecsize{1095}
1820
1821 % A few fonts for @defun names and args.
1822 \setfont\defbf\bfshape{10}{\magstep1}{OT1}
1823 \setfont\deftt\ttshape{10}{\magstep1}{OT1TT}
1824 \setfont\defttsl\ttslshape{10}{\magstep1}{OT1TT}
1825 \def\df{\let\tentt=\deftt \let\tenbf = \defbf \let\tenttsl=\defttsl \bf}
1826
1827 % Fonts for indices, footnotes, small examples (9pt).
1828 \def\smallnominalsize{9pt}
1829 \setfont\smallrm\rmshape{9}{1000}{OT1}
1830 \setfont\smalltt\ttshape{9}{1000}{OT1TT}
1831 \setfont\smallbf\bfshape{10}{900}{OT1}
1832 \setfont\smallit\itshape{9}{1000}{OT1IT}
1833 \setfont\smallsl\slshape{9}{1000}{OT1}
1834 \setfont\smallsf\sfshape{9}{1000}{OT1}
1835 \setfont\smallsc\scshape{10}{900}{OT1}
1836 \setfont\smallttsl\ttslshape{10}{900}{OT1TT}
1837 \font\smalli=cmmi9
1838 \font\smallsy=cmsy9
1839 \def\smallecsize{0900}
1840
1841 % Fonts for small examples (8pt).
1842 \def\smallernominalsize{8pt}
1843 \setfont\smallerrm\rmshape{8}{1000}{OT1}
1844 \setfont\smallertt\ttshape{8}{1000}{OT1TT}
1845 \setfont\smallerbf\bfshape{10}{800}{OT1}
1846 \setfont\smallerit\itshape{8}{1000}{OT1IT}
1847 \setfont\smallersl\slshape{8}{1000}{OT1}
1848 \setfont\smallersf\sfshape{8}{1000}{OT1}
1849 \setfont\smallersc\scshape{10}{800}{OT1}
1850 \setfont\smallerttsl\ttslshape{10}{800}{OT1TT}
1851 \font\smalleri=cmmi8
1852 \font\smallersy=cmsy8
1853 \def\smallerecsize{0800}
1854
1855 % Fonts for title page (20.4pt):
1856 \def\titlenominalsize{20pt}
1857 \setfont\titlerm\rmbshape{12}{\magstep3}{OT1}
1858 \setfont\titleit\itbshape{10}{\magstep4}{OT1IT}
1859 \setfont\titlesl\slbshape{10}{\magstep4}{OT1}
1860 \setfont\titlett\ttbshape{12}{\magstep3}{OT1TT}
1861 \setfont\titlettsl\ttslshape{10}{\magstep4}{OT1TT}
1862 \setfont\titlesf\sfbshape{17}{\magstep1}{OT1}
1863 \let\titlebf=\titlerm
1864 \setfont\titlesc\scbshape{10}{\magstep4}{OT1}
1865 \font\titlei=cmmi12 scaled \magstep3
1866 \font\titlesy=cmsy10 scaled \magstep4
1867 \def\titleecsize{2074}
1868
1869 % Chapter (and unnumbered) fonts (17.28pt).
1870 \def\chapnominalsize{17pt}
1871 \setfont\chaprm\rmbshape{12}{\magstep2}{OT1}
1872 \setfont\chapit\itbshape{10}{\magstep3}{OT1IT}
1873 \setfont\chapsl\slbshape{10}{\magstep3}{OT1}
1874 \setfont\chaptt\ttbshape{12}{\magstep2}{OT1TT}
1875 \setfont\chapttsl\ttslshape{10}{\magstep3}{OT1TT}
1876 \setfont\chapsf\sfbshape{17}{1000}{OT1}
1877 \let\chapbf=\chaprm
1878 \setfont\chapsc\scbshape{10}{\magstep3}{OT1}
1879 \font\chapi=cmmi12 scaled \magstep2
1880 \font\chapsy=cmsy10 scaled \magstep3
1881 \def\chapecsize{1728}
1882
1883 % Section fonts (14.4pt).
1884 \def\secnominalsize{14pt}
1885 \setfont\secrm\rmbshape{12}{\magstep1}{OT1}
1886 \setfont\secit\itbshape{10}{\magstep2}{OT1IT}
1887 \setfont\secsl\slbshape{10}{\magstep2}{OT1}
1888 \setfont\sectt\ttbshape{12}{\magstep1}{OT1TT}
1889 \setfont\secttsl\ttslshape{10}{\magstep2}{OT1TT}
1890 \setfont\secsf\sfbshape{12}{\magstep1}{OT1}
1891 \let\secbf\secrm
1892 \setfont\secsc\scbshape{10}{\magstep2}{OT1}
1893 \font\seci=cmmi12 scaled \magstep1
1894 \font\secsy=cmsy10 scaled \magstep2
1895 \def\sececsize{1440}
1896
1897 % Subsection fonts (13.15pt).
1898 \def\ssecnominalsize{13pt}
1899 \setfont\ssecrm\rmbshape{12}{\magstephalf}{OT1}
1900 \setfont\ssecit\itbshape{10}{1315}{OT1IT}
1901 \setfont\ssecsl\slbshape{10}{1315}{OT1}
1902 \setfont\ssectt\ttbshape{12}{\magstephalf}{OT1TT}
1903 \setfont\ssecttsl\ttslshape{10}{1315}{OT1TT}
1904 \setfont\ssecsf\sfbshape{12}{\magstephalf}{OT1}
1905 \let\ssecbf\ssecrm
1906 \setfont\ssecsc\scbshape{10}{1315}{OT1}
1907 \font\sseci=cmmi12 scaled \magstephalf
1908 \font\ssecsy=cmsy10 scaled 1315
1909 \def\ssececsize{1200}
1910
1911 % Reduced fonts for @acro in text (10pt).
1912 \def\reducednominalsize{10pt}
1913 \setfont\reducedrm\rmshape{10}{1000}{OT1}
1914 \setfont\reducedtt\ttshape{10}{1000}{OT1TT}
1915 \setfont\reducedbf\bfshape{10}{1000}{OT1}
1916 \setfont\reducedit\itshape{10}{1000}{OT1IT}
1917 \setfont\reducedsl\slshape{10}{1000}{OT1}
1918 \setfont\reducedsf\sfshape{10}{1000}{OT1}
1919 \setfont\reducedsc\scshape{10}{1000}{OT1}
1920 \setfont\reducedttsl\ttslshape{10}{1000}{OT1TT}
1921 \font\reducedi=cmmi10
1922 \font\reducedsy=cmsy10
1923 \def\reducedecsize{1000}
1924
1925 \textleading = 13.2pt % line spacing for 11pt CM
1926 \textfonts % reset the current fonts
1927 \rm
1928 } % end of 11pt text font size definitions, \definetextfontsizexi
1929
1930
1931 % Definitions to make the main text be 10pt Computer Modern, with
1932 % section, chapter, etc., sizes following suit. This is for the GNU
1933 % Press printing of the Emacs 22 manual. Maybe other manuals in the
1934 % future. Used with @smallbook, which sets the leading to 12pt.
1935 %
1936 \def\definetextfontsizex{%
1937 % Text fonts (10pt).
1938 \def\textnominalsize{10pt}
1939 \edef\mainmagstep{1000}
1940 \setfont\textrm\rmshape{10}{\mainmagstep}{OT1}
1941 \setfont\texttt\ttshape{10}{\mainmagstep}{OT1TT}
1942 \setfont\textbf\bfshape{10}{\mainmagstep}{OT1}
1943 \setfont\textit\itshape{10}{\mainmagstep}{OT1IT}
1944 \setfont\textsl\slshape{10}{\mainmagstep}{OT1}
1945 \setfont\textsf\sfshape{10}{\mainmagstep}{OT1}
1946 \setfont\textsc\scshape{10}{\mainmagstep}{OT1}
1947 \setfont\textttsl\ttslshape{10}{\mainmagstep}{OT1TT}
1948 \font\texti=cmmi10 scaled \mainmagstep
1949 \font\textsy=cmsy10 scaled \mainmagstep
1950 \def\textecsize{1000}
1951
1952 % A few fonts for @defun names and args.
1953 \setfont\defbf\bfshape{10}{\magstephalf}{OT1}
1954 \setfont\deftt\ttshape{10}{\magstephalf}{OT1TT}
1955 \setfont\defttsl\ttslshape{10}{\magstephalf}{OT1TT}
1956 \def\df{\let\tentt=\deftt \let\tenbf = \defbf \let\tenttsl=\defttsl \bf}
1957
1958 % Fonts for indices, footnotes, small examples (9pt).
1959 \def\smallnominalsize{9pt}
1960 \setfont\smallrm\rmshape{9}{1000}{OT1}
1961 \setfont\smalltt\ttshape{9}{1000}{OT1TT}
1962 \setfont\smallbf\bfshape{10}{900}{OT1}
1963 \setfont\smallit\itshape{9}{1000}{OT1IT}
1964 \setfont\smallsl\slshape{9}{1000}{OT1}
1965 \setfont\smallsf\sfshape{9}{1000}{OT1}
1966 \setfont\smallsc\scshape{10}{900}{OT1}
1967 \setfont\smallttsl\ttslshape{10}{900}{OT1TT}
1968 \font\smalli=cmmi9
1969 \font\smallsy=cmsy9
1970 \def\smallecsize{0900}
1971
1972 % Fonts for small examples (8pt).
1973 \def\smallernominalsize{8pt}
1974 \setfont\smallerrm\rmshape{8}{1000}{OT1}
1975 \setfont\smallertt\ttshape{8}{1000}{OT1TT}
1976 \setfont\smallerbf\bfshape{10}{800}{OT1}
1977 \setfont\smallerit\itshape{8}{1000}{OT1IT}
1978 \setfont\smallersl\slshape{8}{1000}{OT1}
1979 \setfont\smallersf\sfshape{8}{1000}{OT1}
1980 \setfont\smallersc\scshape{10}{800}{OT1}
1981 \setfont\smallerttsl\ttslshape{10}{800}{OT1TT}
1982 \font\smalleri=cmmi8
1983 \font\smallersy=cmsy8
1984 \def\smallerecsize{0800}
1985
1986 % Fonts for title page (20.4pt):
1987 \def\titlenominalsize{20pt}
1988 \setfont\titlerm\rmbshape{12}{\magstep3}{OT1}
1989 \setfont\titleit\itbshape{10}{\magstep4}{OT1IT}
1990 \setfont\titlesl\slbshape{10}{\magstep4}{OT1}
1991 \setfont\titlett\ttbshape{12}{\magstep3}{OT1TT}
1992 \setfont\titlettsl\ttslshape{10}{\magstep4}{OT1TT}
1993 \setfont\titlesf\sfbshape{17}{\magstep1}{OT1}
1994 \let\titlebf=\titlerm
1995 \setfont\titlesc\scbshape{10}{\magstep4}{OT1}
1996 \font\titlei=cmmi12 scaled \magstep3
1997 \font\titlesy=cmsy10 scaled \magstep4
1998 \def\titleecsize{2074}
1999
2000 % Chapter fonts (14.4pt).
2001 \def\chapnominalsize{14pt}
2002 \setfont\chaprm\rmbshape{12}{\magstep1}{OT1}
2003 \setfont\chapit\itbshape{10}{\magstep2}{OT1IT}
2004 \setfont\chapsl\slbshape{10}{\magstep2}{OT1}
2005 \setfont\chaptt\ttbshape{12}{\magstep1}{OT1TT}
2006 \setfont\chapttsl\ttslshape{10}{\magstep2}{OT1TT}
2007 \setfont\chapsf\sfbshape{12}{\magstep1}{OT1}
2008 \let\chapbf\chaprm
2009 \setfont\chapsc\scbshape{10}{\magstep2}{OT1}
2010 \font\chapi=cmmi12 scaled \magstep1
2011 \font\chapsy=cmsy10 scaled \magstep2
2012 \def\chapecsize{1440}
2013
2014 % Section fonts (12pt).
2015 \def\secnominalsize{12pt}
2016 \setfont\secrm\rmbshape{12}{1000}{OT1}
2017 \setfont\secit\itbshape{10}{\magstep1}{OT1IT}
2018 \setfont\secsl\slbshape{10}{\magstep1}{OT1}
2019 \setfont\sectt\ttbshape{12}{1000}{OT1TT}
2020 \setfont\secttsl\ttslshape{10}{\magstep1}{OT1TT}
2021 \setfont\secsf\sfbshape{12}{1000}{OT1}
2022 \let\secbf\secrm
2023 \setfont\secsc\scbshape{10}{\magstep1}{OT1}
2024 \font\seci=cmmi12
2025 \font\secsy=cmsy10 scaled \magstep1
2026 \def\sececsize{1200}
2027
2028 % Subsection fonts (10pt).
2029 \def\ssecnominalsize{10pt}
2030 \setfont\ssecrm\rmbshape{10}{1000}{OT1}
2031 \setfont\ssecit\itbshape{10}{1000}{OT1IT}
2032 \setfont\ssecsl\slbshape{10}{1000}{OT1}
2033 \setfont\ssectt\ttbshape{10}{1000}{OT1TT}
2034 \setfont\ssecttsl\ttslshape{10}{1000}{OT1TT}
2035 \setfont\ssecsf\sfbshape{10}{1000}{OT1}
2036 \let\ssecbf\ssecrm
2037 \setfont\ssecsc\scbshape{10}{1000}{OT1}
2038 \font\sseci=cmmi10
2039 \font\ssecsy=cmsy10
2040 \def\ssececsize{1000}
2041
2042 % Reduced fonts for @acro in text (9pt).
2043 \def\reducednominalsize{9pt}
2044 \setfont\reducedrm\rmshape{9}{1000}{OT1}
2045 \setfont\reducedtt\ttshape{9}{1000}{OT1TT}
2046 \setfont\reducedbf\bfshape{10}{900}{OT1}
2047 \setfont\reducedit\itshape{9}{1000}{OT1IT}
2048 \setfont\reducedsl\slshape{9}{1000}{OT1}
2049 \setfont\reducedsf\sfshape{9}{1000}{OT1}
2050 \setfont\reducedsc\scshape{10}{900}{OT1}
2051 \setfont\reducedttsl\ttslshape{10}{900}{OT1TT}
2052 \font\reducedi=cmmi9
2053 \font\reducedsy=cmsy9
2054 \def\reducedecsize{0900}
2055
2056 \divide\parskip by 2 % reduce space between paragraphs
2057 \textleading = 12pt % line spacing for 10pt CM
2058 \textfonts % reset the current fonts
2059 \rm
2060 } % end of 10pt text font size definitions, \definetextfontsizex
2061
2062
2063 % We provide the user-level command
2064 % @fonttextsize 10
2065 % (or 11) to redefine the text font size. pt is assumed.
2066 %
2067 \def\xiword{11}
2068 \def\xword{10}
2069 \def\xwordpt{10pt}
2070 %
2071 \parseargdef\fonttextsize{%
2072 \def\textsizearg{#1}%
2073 %\wlog{doing @fonttextsize \textsizearg}%
2074 %
2075 % Set \globaldefs so that documents can use this inside @tex, since
2076 % makeinfo 4.8 does not support it, but we need it nonetheless.
2077 %
2078 \begingroup \globaldefs=1
2079 \ifx\textsizearg\xword \definetextfontsizex
2080 \else \ifx\textsizearg\xiword \definetextfontsizexi
2081 \else
2082 \errhelp=\EMsimple
2083 \errmessage{@fonttextsize only supports `10' or `11', not `\textsizearg'}
2084 \fi\fi
2085 \endgroup
2086 }
2087
2088
2089 % In order for the font changes to affect most math symbols and letters,
2090 % we have to define the \textfont of the standard families. Since
2091 % texinfo doesn't allow for producing subscripts and superscripts except
2092 % in the main text, we don't bother to reset \scriptfont and
2093 % \scriptscriptfont (which would also require loading a lot more fonts).
2094 %
2095 \def\resetmathfonts{%
2096 \textfont0=\tenrm \textfont1=\teni \textfont2=\tensy
2097 \textfont\itfam=\tenit \textfont\slfam=\tensl \textfont\bffam=\tenbf
2098 \textfont\ttfam=\tentt \textfont\sffam=\tensf
2099 }
2100
2101 % The font-changing commands redefine the meanings of \tenSTYLE, instead
2102 % of just \STYLE. We do this because \STYLE needs to also set the
2103 % current \fam for math mode. Our \STYLE (e.g., \rm) commands hardwire
2104 % \tenSTYLE to set the current font.
2105 %
2106 % Each font-changing command also sets the names \lsize (one size lower)
2107 % and \lllsize (three sizes lower). These relative commands are used in
2108 % the LaTeX logo and acronyms.
2109 %
2110 % This all needs generalizing, badly.
2111 %
2112 \def\textfonts{%
2113 \let\tenrm=\textrm \let\tenit=\textit \let\tensl=\textsl
2114 \let\tenbf=\textbf \let\tentt=\texttt \let\smallcaps=\textsc
2115 \let\tensf=\textsf \let\teni=\texti \let\tensy=\textsy
2116 \let\tenttsl=\textttsl
2117 \def\curfontsize{text}%
2118 \def\lsize{reduced}\def\lllsize{smaller}%
2119 \resetmathfonts \setleading{\textleading}}
2120 \def\titlefonts{%
2121 \let\tenrm=\titlerm \let\tenit=\titleit \let\tensl=\titlesl
2122 \let\tenbf=\titlebf \let\tentt=\titlett \let\smallcaps=\titlesc
2123 \let\tensf=\titlesf \let\teni=\titlei \let\tensy=\titlesy
2124 \let\tenttsl=\titlettsl
2125 \def\curfontsize{title}%
2126 \def\lsize{chap}\def\lllsize{subsec}%
2127 \resetmathfonts \setleading{27pt}}
2128 \def\titlefont#1{{\titlefonts\rmisbold #1}}
2129 \def\chapfonts{%
2130 \let\tenrm=\chaprm \let\tenit=\chapit \let\tensl=\chapsl
2131 \let\tenbf=\chapbf \let\tentt=\chaptt \let\smallcaps=\chapsc
2132 \let\tensf=\chapsf \let\teni=\chapi \let\tensy=\chapsy
2133 \let\tenttsl=\chapttsl
2134 \def\curfontsize{chap}%
2135 \def\lsize{sec}\def\lllsize{text}%
2136 \resetmathfonts \setleading{19pt}}
2137 \def\secfonts{%
2138 \let\tenrm=\secrm \let\tenit=\secit \let\tensl=\secsl
2139 \let\tenbf=\secbf \let\tentt=\sectt \let\smallcaps=\secsc
2140 \let\tensf=\secsf \let\teni=\seci \let\tensy=\secsy
2141 \let\tenttsl=\secttsl
2142 \def\curfontsize{sec}%
2143 \def\lsize{subsec}\def\lllsize{reduced}%
2144 \resetmathfonts \setleading{16pt}}
2145 \def\subsecfonts{%
2146 \let\tenrm=\ssecrm \let\tenit=\ssecit \let\tensl=\ssecsl
2147 \let\tenbf=\ssecbf \let\tentt=\ssectt \let\smallcaps=\ssecsc
2148 \let\tensf=\ssecsf \let\teni=\sseci \let\tensy=\ssecsy
2149 \let\tenttsl=\ssecttsl
2150 \def\curfontsize{ssec}%
2151 \def\lsize{text}\def\lllsize{small}%
2152 \resetmathfonts \setleading{15pt}}
2153 \let\subsubsecfonts = \subsecfonts
2154 \def\reducedfonts{%
2155 \let\tenrm=\reducedrm \let\tenit=\reducedit \let\tensl=\reducedsl
2156 \let\tenbf=\reducedbf \let\tentt=\reducedtt \let\reducedcaps=\reducedsc
2157 \let\tensf=\reducedsf \let\teni=\reducedi \let\tensy=\reducedsy
2158 \let\tenttsl=\reducedttsl
2159 \def\curfontsize{reduced}%
2160 \def\lsize{small}\def\lllsize{smaller}%
2161 \resetmathfonts \setleading{10.5pt}}
2162 \def\smallfonts{%
2163 \let\tenrm=\smallrm \let\tenit=\smallit \let\tensl=\smallsl
2164 \let\tenbf=\smallbf \let\tentt=\smalltt \let\smallcaps=\smallsc
2165 \let\tensf=\smallsf \let\teni=\smalli \let\tensy=\smallsy
2166 \let\tenttsl=\smallttsl
2167 \def\curfontsize{small}%
2168 \def\lsize{smaller}\def\lllsize{smaller}%
2169 \resetmathfonts \setleading{10.5pt}}
2170 \def\smallerfonts{%
2171 \let\tenrm=\smallerrm \let\tenit=\smallerit \let\tensl=\smallersl
2172 \let\tenbf=\smallerbf \let\tentt=\smallertt \let\smallcaps=\smallersc
2173 \let\tensf=\smallersf \let\teni=\smalleri \let\tensy=\smallersy
2174 \let\tenttsl=\smallerttsl
2175 \def\curfontsize{smaller}%
2176 \def\lsize{smaller}\def\lllsize{smaller}%
2177 \resetmathfonts \setleading{9.5pt}}
2178
2179 % Fonts for short table of contents.
2180 \setfont\shortcontrm\rmshape{12}{1000}{OT1}
2181 \setfont\shortcontbf\bfshape{10}{\magstep1}{OT1} % no cmb12
2182 \setfont\shortcontsl\slshape{12}{1000}{OT1}
2183 \setfont\shortconttt\ttshape{12}{1000}{OT1TT}
2184
2185 % Define these just so they can be easily changed for other fonts.
2186 \def\angleleft{$\langle$}
2187 \def\angleright{$\rangle$}
2188
2189 % Set the fonts to use with the @small... environments.
2190 \let\smallexamplefonts = \smallfonts
2191
2192 % About \smallexamplefonts. If we use \smallfonts (9pt), @smallexample
2193 % can fit this many characters:
2194 % 8.5x11=86 smallbook=72 a4=90 a5=69
2195 % If we use \scriptfonts (8pt), then we can fit this many characters:
2196 % 8.5x11=90+ smallbook=80 a4=90+ a5=77
2197 % For me, subjectively, the few extra characters that fit aren't worth
2198 % the additional smallness of 8pt. So I'm making the default 9pt.
2199 %
2200 % By the way, for comparison, here's what fits with @example (10pt):
2201 % 8.5x11=71 smallbook=60 a4=75 a5=58
2202 % --karl, 24jan03.
2203
2204 % Set up the default fonts, so we can use them for creating boxes.
2205 %
2206 \definetextfontsizexi
2207
2208
2209 \message{markup,}
2210
2211 % Check if we are currently using a typewriter font. Since all the
2212 % Computer Modern typewriter fonts have zero interword stretch (and
2213 % shrink), and it is reasonable to expect all typewriter fonts to have
2214 % this property, we can check that font parameter.
2215 %
2216 \def\ifmonospace{\ifdim\fontdimen3\font=0pt }
2217
2218 % Markup style infrastructure. \defmarkupstylesetup\INITMACRO will
2219 % define and register \INITMACRO to be called on markup style changes.
2220 % \INITMACRO can check \currentmarkupstyle for the innermost
2221 % style and the set of \ifmarkupSTYLE switches for all styles
2222 % currently in effect.
2223 \newif\ifmarkupvar
2224 \newif\ifmarkupsamp
2225 \newif\ifmarkupkey
2226 %\newif\ifmarkupfile % @file == @samp.
2227 %\newif\ifmarkupoption % @option == @samp.
2228 \newif\ifmarkupcode
2229 \newif\ifmarkupkbd
2230 %\newif\ifmarkupenv % @env == @code.
2231 %\newif\ifmarkupcommand % @command == @code.
2232 \newif\ifmarkuptex % @tex (and part of @math, for now).
2233 \newif\ifmarkupexample
2234 \newif\ifmarkupverb
2235 \newif\ifmarkupverbatim
2236
2237 \let\currentmarkupstyle\empty
2238
2239 \def\setupmarkupstyle#1{%
2240 \csname markup#1true\endcsname
2241 \def\currentmarkupstyle{#1}%
2242 \markupstylesetup
2243 }
2244
2245 \let\markupstylesetup\empty
2246
2247 \def\defmarkupstylesetup#1{%
2248 \expandafter\def\expandafter\markupstylesetup
2249 \expandafter{\markupstylesetup #1}%
2250 \def#1%
2251 }
2252
2253 % Markup style setup for left and right quotes.
2254 \defmarkupstylesetup\markupsetuplq{%
2255 \expandafter\let\expandafter \temp
2256 \csname markupsetuplq\currentmarkupstyle\endcsname
2257 \ifx\temp\relax \markupsetuplqdefault \else \temp \fi
2258 }
2259
2260 \defmarkupstylesetup\markupsetuprq{%
2261 \expandafter\let\expandafter \temp
2262 \csname markupsetuprq\currentmarkupstyle\endcsname
2263 \ifx\temp\relax \markupsetuprqdefault \else \temp \fi
2264 }
2265
2266 {
2267 \catcode`\'=\active
2268 \catcode`\`=\active
2269
2270 \gdef\markupsetuplqdefault{\let`\lq}
2271 \gdef\markupsetuprqdefault{\let'\rq}
2272
2273 \gdef\markupsetcodequoteleft{\let`\codequoteleft}
2274 \gdef\markupsetcodequoteright{\let'\codequoteright}
2275 }
2276
2277 \let\markupsetuplqcode \markupsetcodequoteleft
2278 \let\markupsetuprqcode \markupsetcodequoteright
2279 %
2280 \let\markupsetuplqexample \markupsetcodequoteleft
2281 \let\markupsetuprqexample \markupsetcodequoteright
2282 %
2283 \let\markupsetuplqkbd \markupsetcodequoteleft
2284 \let\markupsetuprqkbd \markupsetcodequoteright
2285 %
2286 \let\markupsetuplqsamp \markupsetcodequoteleft
2287 \let\markupsetuprqsamp \markupsetcodequoteright
2288 %
2289 \let\markupsetuplqverb \markupsetcodequoteleft
2290 \let\markupsetuprqverb \markupsetcodequoteright
2291 %
2292 \let\markupsetuplqverbatim \markupsetcodequoteleft
2293 \let\markupsetuprqverbatim \markupsetcodequoteright
2294
2295 % Allow an option to not use regular directed right quote/apostrophe
2296 % (char 0x27), but instead the undirected quote from cmtt (char 0x0d).
2297 % The undirected quote is ugly, so don't make it the default, but it
2298 % works for pasting with more pdf viewers (at least evince), the
2299 % lilypond developers report. xpdf does work with the regular 0x27.
2300 %
2301 \def\codequoteright{%
2302 \expandafter\ifx\csname SETtxicodequoteundirected\endcsname\relax
2303 \expandafter\ifx\csname SETcodequoteundirected\endcsname\relax
2304 '%
2305 \else \char'15 \fi
2306 \else \char'15 \fi
2307 }
2308 %
2309 % and a similar option for the left quote char vs. a grave accent.
2310 % Modern fonts display ASCII 0x60 as a grave accent, so some people like
2311 % the code environments to do likewise.
2312 %
2313 \def\codequoteleft{%
2314 \expandafter\ifx\csname SETtxicodequotebacktick\endcsname\relax
2315 \expandafter\ifx\csname SETcodequotebacktick\endcsname\relax
2316 % [Knuth] pp. 380,381,391
2317 % \relax disables Spanish ligatures ?` and !` of \tt font.
2318 \relax`%
2319 \else \char'22 \fi
2320 \else \char'22 \fi
2321 }
2322
2323 % Commands to set the quote options.
2324 %
2325 \parseargdef\codequoteundirected{%
2326 \def\temp{#1}%
2327 \ifx\temp\onword
2328 \expandafter\let\csname SETtxicodequoteundirected\endcsname
2329 = t%
2330 \else\ifx\temp\offword
2331 \expandafter\let\csname SETtxicodequoteundirected\endcsname
2332 = \relax
2333 \else
2334 \errhelp = \EMsimple
2335 \errmessage{Unknown @codequoteundirected value `\temp', must be on|off}%
2336 \fi\fi
2337 }
2338 %
2339 \parseargdef\codequotebacktick{%
2340 \def\temp{#1}%
2341 \ifx\temp\onword
2342 \expandafter\let\csname SETtxicodequotebacktick\endcsname
2343 = t%
2344 \else\ifx\temp\offword
2345 \expandafter\let\csname SETtxicodequotebacktick\endcsname
2346 = \relax
2347 \else
2348 \errhelp = \EMsimple
2349 \errmessage{Unknown @codequotebacktick value `\temp', must be on|off}%
2350 \fi\fi
2351 }
2352
2353 % [Knuth] pp. 380,381,391, disable Spanish ligatures ?` and !` of \tt font.
2354 \def\noligaturesquoteleft{\relax\lq}
2355
2356 % Count depth in font-changes, for error checks
2357 \newcount\fontdepth \fontdepth=0
2358
2359 % Font commands.
2360
2361 % #1 is the font command (\sl or \it), #2 is the text to slant.
2362 % If we are in a monospaced environment, however, 1) always use \ttsl,
2363 % and 2) do not add an italic correction.
2364 \def\dosmartslant#1#2{%
2365 \ifusingtt
2366 {{\ttsl #2}\let\next=\relax}%
2367 {\def\next{{#1#2}\futurelet\next\smartitaliccorrection}}%
2368 \next
2369 }
2370 \def\smartslanted{\dosmartslant\sl}
2371 \def\smartitalic{\dosmartslant\it}
2372
2373 % Output an italic correction unless \next (presumed to be the following
2374 % character) is such as not to need one.
2375 \def\smartitaliccorrection{%
2376 \ifx\next,%
2377 \else\ifx\next-%
2378 \else\ifx\next.%
2379 \else\ptexslash
2380 \fi\fi\fi
2381 \aftersmartic
2382 }
2383
2384 % Unconditional use \ttsl, and no ic. @var is set to this for defuns.
2385 \def\ttslanted#1{{\ttsl #1}}
2386
2387 % @cite is like \smartslanted except unconditionally use \sl. We never want
2388 % ttsl for book titles, do we?
2389 \def\cite#1{{\sl #1}\futurelet\next\smartitaliccorrection}
2390
2391 \def\aftersmartic{}
2392 \def\var#1{%
2393 \let\saveaftersmartic = \aftersmartic
2394 \def\aftersmartic{\null\let\aftersmartic=\saveaftersmartic}%
2395 \smartslanted{#1}%
2396 }
2397
2398 \let\i=\smartitalic
2399 \let\slanted=\smartslanted
2400 \let\dfn=\smartslanted
2401 \let\emph=\smartitalic
2402
2403 % Explicit font changes: @r, @sc, undocumented @ii.
2404 \def\r#1{{\rm #1}} % roman font
2405 \def\sc#1{{\smallcaps#1}} % smallcaps font
2406 \def\ii#1{{\it #1}} % italic font
2407
2408 % @b, explicit bold. Also @strong.
2409 \def\b#1{{\bf #1}}
2410 \let\strong=\b
2411
2412 % @sansserif, explicit sans.
2413 \def\sansserif#1{{\sf #1}}
2414
2415 % We can't just use \exhyphenpenalty, because that only has effect at
2416 % the end of a paragraph. Restore normal hyphenation at the end of the
2417 % group within which \nohyphenation is presumably called.
2418 %
2419 \def\nohyphenation{\hyphenchar\font = -1 \aftergroup\restorehyphenation}
2420 \def\restorehyphenation{\hyphenchar\font = `- }
2421
2422 % Set sfcode to normal for the chars that usually have another value.
2423 % Can't use plain's \frenchspacing because it uses the `\x notation, and
2424 % sometimes \x has an active definition that messes things up.
2425 %
2426 \catcode`@=11
2427 \def\plainfrenchspacing{%
2428 \sfcode\dotChar =\@m \sfcode\questChar=\@m \sfcode\exclamChar=\@m
2429 \sfcode\colonChar=\@m \sfcode\semiChar =\@m \sfcode\commaChar =\@m
2430 \def\endofsentencespacefactor{1000}% for @. and friends
2431 }
2432 \def\plainnonfrenchspacing{%
2433 \sfcode`\.3000\sfcode`\?3000\sfcode`\!3000
2434 \sfcode`\:2000\sfcode`\;1500\sfcode`\,1250
2435 \def\endofsentencespacefactor{3000}% for @. and friends
2436 }
2437 \catcode`@=\other
2438 \def\endofsentencespacefactor{3000}% default
2439
2440 % @t, explicit typewriter.
2441 \def\t#1{%
2442 {\tt \rawbackslash \plainfrenchspacing #1}%
2443 \null
2444 }
2445
2446 % @samp.
2447 \def\samp#1{{\setupmarkupstyle{samp}\lq\tclose{#1}\rq\null}}
2448
2449 % @indicateurl is \samp, that is, with quotes.
2450 \let\indicateurl=\samp
2451
2452 % @code (and similar) prints in typewriter, but with spaces the same
2453 % size as normal in the surrounding text, without hyphenation, etc.
2454 % This is a subroutine for that.
2455 \def\tclose#1{%
2456 {%
2457 % Change normal interword space to be same as for the current font.
2458 \spaceskip = \fontdimen2\font
2459 %
2460 % Switch to typewriter.
2461 \tt
2462 %
2463 % But `\ ' produces the large typewriter interword space.
2464 \def\ {{\spaceskip = 0pt{} }}%
2465 %
2466 % Turn off hyphenation.
2467 \nohyphenation
2468 %
2469 \rawbackslash
2470 \plainfrenchspacing
2471 #1%
2472 }%
2473 \null % reset spacefactor to 1000
2474 }
2475
2476 % We *must* turn on hyphenation at `-' and `_' in @code.
2477 % Otherwise, it is too hard to avoid overfull hboxes
2478 % in the Emacs manual, the Library manual, etc.
2479 %
2480 % Unfortunately, TeX uses one parameter (\hyphenchar) to control
2481 % both hyphenation at - and hyphenation within words.
2482 % We must therefore turn them both off (\tclose does that)
2483 % and arrange explicitly to hyphenate at a dash.
2484 % -- rms.
2485 {
2486 \catcode`\-=\active \catcode`\_=\active
2487 \catcode`\'=\active \catcode`\`=\active
2488 \global\let'=\rq \global\let`=\lq % default definitions
2489 %
2490 \global\def\code{\begingroup
2491 \setupmarkupstyle{code}%
2492 % The following should really be moved into \setupmarkupstyle handlers.
2493 \catcode\dashChar=\active \catcode\underChar=\active
2494 \ifallowcodebreaks
2495 \let-\codedash
2496 \let_\codeunder
2497 \else
2498 \let-\normaldash
2499 \let_\realunder
2500 \fi
2501 \codex
2502 }
2503 }
2504
2505 \def\codex #1{\tclose{#1}\endgroup}
2506
2507 \def\normaldash{-}
2508 \def\codedash{-\discretionary{}{}{}}
2509 \def\codeunder{%
2510 % this is all so @math{@code{var_name}+1} can work. In math mode, _
2511 % is "active" (mathcode"8000) and \normalunderscore (or \char95, etc.)
2512 % will therefore expand the active definition of _, which is us
2513 % (inside @code that is), therefore an endless loop.
2514 \ifusingtt{\ifmmode
2515 \mathchar"075F % class 0=ordinary, family 7=ttfam, pos 0x5F=_.
2516 \else\normalunderscore \fi
2517 \discretionary{}{}{}}%
2518 {\_}%
2519 }
2520
2521 % An additional complication: the above will allow breaks after, e.g.,
2522 % each of the four underscores in __typeof__. This is bad.
2523 % @allowcodebreaks provides a document-level way to turn breaking at -
2524 % and _ on and off.
2525 %
2526 \newif\ifallowcodebreaks \allowcodebreakstrue
2527
2528 \def\keywordtrue{true}
2529 \def\keywordfalse{false}
2530
2531 \parseargdef\allowcodebreaks{%
2532 \def\txiarg{#1}%
2533 \ifx\txiarg\keywordtrue
2534 \allowcodebreakstrue
2535 \else\ifx\txiarg\keywordfalse
2536 \allowcodebreaksfalse
2537 \else
2538 \errhelp = \EMsimple
2539 \errmessage{Unknown @allowcodebreaks option `\txiarg', must be true|false}%
2540 \fi\fi
2541 }
2542
2543 % For @command, @env, @file, @option quotes seem unnecessary,
2544 % so use \code rather than \samp.
2545 \let\command=\code
2546 \let\env=\code
2547 \let\file=\code
2548 \let\option=\code
2549
2550 % @uref (abbreviation for `urlref') takes an optional (comma-separated)
2551 % second argument specifying the text to display and an optional third
2552 % arg as text to display instead of (rather than in addition to) the url
2553 % itself. First (mandatory) arg is the url.
2554 % (This \urefnobreak definition isn't used now, leaving it for a while
2555 % for comparison.)
2556 \def\urefnobreak#1{\dourefnobreak #1,,,\finish}
2557 \def\dourefnobreak#1,#2,#3,#4\finish{\begingroup
2558 \unsepspaces
2559 \pdfurl{#1}%
2560 \setbox0 = \hbox{\ignorespaces #3}%
2561 \ifdim\wd0 > 0pt
2562 \unhbox0 % third arg given, show only that
2563 \else
2564 \setbox0 = \hbox{\ignorespaces #2}%
2565 \ifdim\wd0 > 0pt
2566 \ifpdf
2567 \unhbox0 % PDF: 2nd arg given, show only it
2568 \else
2569 \unhbox0\ (\code{#1})% DVI: 2nd arg given, show both it and url
2570 \fi
2571 \else
2572 \code{#1}% only url given, so show it
2573 \fi
2574 \fi
2575 \endlink
2576 \endgroup}
2577
2578 % This \urefbreak definition is the active one.
2579 \def\urefbreak{\begingroup \urefcatcodes \dourefbreak}
2580 \let\uref=\urefbreak
2581 \def\dourefbreak#1{\urefbreakfinish #1,,,\finish}
2582 \def\urefbreakfinish#1,#2,#3,#4\finish{% doesn't work in @example
2583 \unsepspaces
2584 \pdfurl{#1}%
2585 \setbox0 = \hbox{\ignorespaces #3}%
2586 \ifdim\wd0 > 0pt
2587 \unhbox0 % third arg given, show only that
2588 \else
2589 \setbox0 = \hbox{\ignorespaces #2}%
2590 \ifdim\wd0 > 0pt
2591 \ifpdf
2592 \unhbox0 % PDF: 2nd arg given, show only it
2593 \else
2594 \unhbox0\ (\urefcode{#1})% DVI: 2nd arg given, show both it and url
2595 \fi
2596 \else
2597 \urefcode{#1}% only url given, so show it
2598 \fi
2599 \fi
2600 \endlink
2601 \endgroup}
2602
2603 % Allow line breaks around only a few characters (only).
2604 \def\urefcatcodes{%
2605 \catcode\ampChar=\active \catcode\dotChar=\active
2606 \catcode\hashChar=\active \catcode\questChar=\active
2607 \catcode\slashChar=\active
2608 }
2609 {
2610 \urefcatcodes
2611 %
2612 \global\def\urefcode{\begingroup
2613 \setupmarkupstyle{code}%
2614 \urefcatcodes
2615 \let&\urefcodeamp
2616 \let.\urefcodedot
2617 \let#\urefcodehash
2618 \let?\urefcodequest
2619 \let/\urefcodeslash
2620 \codex
2621 }
2622 %
2623 % By default, they are just regular characters.
2624 \global\def&{\normalamp}
2625 \global\def.{\normaldot}
2626 \global\def#{\normalhash}
2627 \global\def?{\normalquest}
2628 \global\def/{\normalslash}
2629 }
2630
2631 % we put a little stretch before and after the breakable chars, to help
2632 % line breaking of long url's. The unequal skips make look better in
2633 % cmtt at least, especially for dots.
2634 \def\urefprestretch{\urefprebreak \hskip0pt plus.13em }
2635 \def\urefpoststretch{\urefpostbreak \hskip0pt plus.1em }
2636 %
2637 \def\urefcodeamp{\urefprestretch \&\urefpoststretch}
2638 \def\urefcodedot{\urefprestretch .\urefpoststretch}
2639 \def\urefcodehash{\urefprestretch \#\urefpoststretch}
2640 \def\urefcodequest{\urefprestretch ?\urefpoststretch}
2641 \def\urefcodeslash{\futurelet\next\urefcodeslashfinish}
2642 {
2643 \catcode`\/=\active
2644 \global\def\urefcodeslashfinish{%
2645 \urefprestretch \slashChar
2646 % Allow line break only after the final / in a sequence of
2647 % slashes, to avoid line break between the slashes in http://.
2648 \ifx\next/\else \urefpoststretch \fi
2649 }
2650 }
2651
2652 % One more complication: by default we'll break after the special
2653 % characters, but some people like to break before the special chars, so
2654 % allow that. Also allow no breaking at all, for manual control.
2655 %
2656 \parseargdef\urefbreakstyle{%
2657 \def\txiarg{#1}%
2658 \ifx\txiarg\wordnone
2659 \def\urefprebreak{\nobreak}\def\urefpostbreak{\nobreak}
2660 \else\ifx\txiarg\wordbefore
2661 \def\urefprebreak{\allowbreak}\def\urefpostbreak{\nobreak}
2662 \else\ifx\txiarg\wordafter
2663 \def\urefprebreak{\nobreak}\def\urefpostbreak{\allowbreak}
2664 \else
2665 \errhelp = \EMsimple
2666 \errmessage{Unknown @urefbreakstyle setting `\txiarg'}%
2667 \fi\fi\fi
2668 }
2669 \def\wordafter{after}
2670 \def\wordbefore{before}
2671 \def\wordnone{none}
2672
2673 \urefbreakstyle after
2674
2675 % @url synonym for @uref, since that's how everyone uses it.
2676 %
2677 \let\url=\uref
2678
2679 % rms does not like angle brackets --karl, 17may97.
2680 % So now @email is just like @uref, unless we are pdf.
2681 %
2682 %\def\email#1{\angleleft{\tt #1}\angleright}
2683 \ifpdf
2684 \def\email#1{\doemail#1,,\finish}
2685 \def\doemail#1,#2,#3\finish{\begingroup
2686 \unsepspaces
2687 \pdfurl{mailto:#1}%
2688 \setbox0 = \hbox{\ignorespaces #2}%
2689 \ifdim\wd0>0pt\unhbox0\else\code{#1}\fi
2690 \endlink
2691 \endgroup}
2692 \else
2693 \let\email=\uref
2694 \fi
2695
2696 % @kbdinputstyle -- arg is `distinct' (@kbd uses slanted tty font always),
2697 % `example' (@kbd uses ttsl only inside of @example and friends),
2698 % or `code' (@kbd uses normal tty font always).
2699 \parseargdef\kbdinputstyle{%
2700 \def\txiarg{#1}%
2701 \ifx\txiarg\worddistinct
2702 \gdef\kbdexamplefont{\ttsl}\gdef\kbdfont{\ttsl}%
2703 \else\ifx\txiarg\wordexample
2704 \gdef\kbdexamplefont{\ttsl}\gdef\kbdfont{\tt}%
2705 \else\ifx\txiarg\wordcode
2706 \gdef\kbdexamplefont{\tt}\gdef\kbdfont{\tt}%
2707 \else
2708 \errhelp = \EMsimple
2709 \errmessage{Unknown @kbdinputstyle setting `\txiarg'}%
2710 \fi\fi\fi
2711 }
2712 \def\worddistinct{distinct}
2713 \def\wordexample{example}
2714 \def\wordcode{code}
2715
2716 % Default is `distinct'.
2717 \kbdinputstyle distinct
2718
2719 % @kbd is like @code, except that if the argument is just one @key command,
2720 % then @kbd has no effect.
2721 \def\kbd#1{{\def\look{#1}\expandafter\kbdsub\look??\par}}
2722
2723 \def\xkey{\key}
2724 \def\kbdsub#1#2#3\par{%
2725 \def\one{#1}\def\three{#3}\def\threex{??}%
2726 \ifx\one\xkey\ifx\threex\three \key{#2}%
2727 \else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
2728 \else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
2729 }
2730
2731 % definition of @key that produces a lozenge. Doesn't adjust to text size.
2732 %\setfont\keyrm\rmshape{8}{1000}{OT1}
2733 %\font\keysy=cmsy9
2734 %\def\key#1{{\keyrm\textfont2=\keysy \leavevmode\hbox{%
2735 % \raise0.4pt\hbox{\angleleft}\kern-.08em\vtop{%
2736 % \vbox{\hrule\kern-0.4pt
2737 % \hbox{\raise0.4pt\hbox{\vphantom{\angleleft}}#1}}%
2738 % \kern-0.4pt\hrule}%
2739 % \kern-.06em\raise0.4pt\hbox{\angleright}}}}
2740
2741 % definition of @key with no lozenge. If the current font is already
2742 % monospace, don't change it; that way, we respect @kbdinputstyle. But
2743 % if it isn't monospace, then use \tt.
2744 %
2745 \def\key#1{{\setupmarkupstyle{key}%
2746 \nohyphenation
2747 \ifmonospace\else\tt\fi
2748 #1}\null}
2749
2750 % @clicksequence{File @click{} Open ...}
2751 \def\clicksequence#1{\begingroup #1\endgroup}
2752
2753 % @clickstyle @arrow (by default)
2754 \parseargdef\clickstyle{\def\click{#1}}
2755 \def\click{\arrow}
2756
2757 % Typeset a dimension, e.g., `in' or `pt'. The only reason for the
2758 % argument is to make the input look right: @dmn{pt} instead of @dmn{}pt.
2759 %
2760 \def\dmn#1{\thinspace #1}
2761
2762 % @l was never documented to mean ``switch to the Lisp font'',
2763 % and it is not used as such in any manual I can find. We need it for
2764 % Polish suppressed-l. --karl, 22sep96.
2765 %\def\l#1{{\li #1}\null}
2766
2767 % @acronym for "FBI", "NATO", and the like.
2768 % We print this one point size smaller, since it's intended for
2769 % all-uppercase.
2770 %
2771 \def\acronym#1{\doacronym #1,,\finish}
2772 \def\doacronym#1,#2,#3\finish{%
2773 {\selectfonts\lsize #1}%
2774 \def\temp{#2}%
2775 \ifx\temp\empty \else
2776 \space ({\unsepspaces \ignorespaces \temp \unskip})%
2777 \fi
2778 \null % reset \spacefactor=1000
2779 }
2780
2781 % @abbr for "Comput. J." and the like.
2782 % No font change, but don't do end-of-sentence spacing.
2783 %
2784 \def\abbr#1{\doabbr #1,,\finish}
2785 \def\doabbr#1,#2,#3\finish{%
2786 {\plainfrenchspacing #1}%
2787 \def\temp{#2}%
2788 \ifx\temp\empty \else
2789 \space ({\unsepspaces \ignorespaces \temp \unskip})%
2790 \fi
2791 \null % reset \spacefactor=1000
2792 }
2793
2794 % @asis just yields its argument. Used with @table, for example.
2795 %
2796 \def\asis#1{#1}
2797
2798 % @math outputs its argument in math mode.
2799 %
2800 % One complication: _ usually means subscripts, but it could also mean
2801 % an actual _ character, as in @math{@var{some_variable} + 1}. So make
2802 % _ active, and distinguish by seeing if the current family is \slfam,
2803 % which is what @var uses.
2804 {
2805 \catcode`\_ = \active
2806 \gdef\mathunderscore{%
2807 \catcode`\_=\active
2808 \def_{\ifnum\fam=\slfam \_\else\sb\fi}%
2809 }
2810 }
2811 % Another complication: we want \\ (and @\) to output a math (or tt) \.
2812 % FYI, plain.tex uses \\ as a temporary control sequence (for no
2813 % particular reason), but this is not advertised and we don't care.
2814 %
2815 % The \mathchar is class=0=ordinary, family=7=ttfam, position=5C=\.
2816 \def\mathbackslash{\ifnum\fam=\ttfam \mathchar"075C \else\backslash \fi}
2817 %
2818 \def\math{%
2819 \tex
2820 \mathunderscore
2821 \let\\ = \mathbackslash
2822 \mathactive
2823 % make the texinfo accent commands work in math mode
2824 \let\"=\ddot
2825 \let\'=\acute
2826 \let\==\bar
2827 \let\^=\hat
2828 \let\`=\grave
2829 \let\u=\breve
2830 \let\v=\check
2831 \let\~=\tilde
2832 \let\dotaccent=\dot
2833 $\finishmath
2834 }
2835 \def\finishmath#1{#1$\endgroup} % Close the group opened by \tex.
2836
2837 % Some active characters (such as <) are spaced differently in math.
2838 % We have to reset their definitions in case the @math was an argument
2839 % to a command which sets the catcodes (such as @item or @section).
2840 %
2841 {
2842 \catcode`^ = \active
2843 \catcode`< = \active
2844 \catcode`> = \active
2845 \catcode`+ = \active
2846 \catcode`' = \active
2847 \gdef\mathactive{%
2848 \let^ = \ptexhat
2849 \let< = \ptexless
2850 \let> = \ptexgtr
2851 \let+ = \ptexplus
2852 \let' = \ptexquoteright
2853 }
2854 }
2855
2856 % ctrl is no longer a Texinfo command, but leave this definition for fun.
2857 \def\ctrl #1{{\tt \rawbackslash \hat}#1}
2858
2859 % @inlinefmt{FMTNAME,PROCESSED-TEXT} and @inlineraw{FMTNAME,RAW-TEXT}.
2860 % Ignore unless FMTNAME == tex; then it is like @iftex and @tex,
2861 % except specified as a normal braced arg, so no newlines to worry about.
2862 %
2863 \def\outfmtnametex{tex}
2864 %
2865 \long\def\inlinefmt#1{\doinlinefmt #1,\finish}
2866 \long\def\doinlinefmt#1,#2,\finish{%
2867 \def\inlinefmtname{#1}%
2868 \ifx\inlinefmtname\outfmtnametex \ignorespaces #2\fi
2869 }
2870 % For raw, must switch into @tex before parsing the argument, to avoid
2871 % setting catcodes prematurely. Doing it this way means that, for
2872 % example, @inlineraw{html, foo{bar} gets a parse error instead of being
2873 % ignored. But this isn't important because if people want a literal
2874 % *right* brace they would have to use a command anyway, so they may as
2875 % well use a command to get a left brace too. We could re-use the
2876 % delimiter character idea from \verb, but it seems like overkill.
2877 %
2878 \long\def\inlineraw{\tex \doinlineraw}
2879 \long\def\doinlineraw#1{\doinlinerawtwo #1,\finish}
2880 \def\doinlinerawtwo#1,#2,\finish{%
2881 \def\inlinerawname{#1}%
2882 \ifx\inlinerawname\outfmtnametex \ignorespaces #2\fi
2883 \endgroup % close group opened by \tex.
2884 }
2885
2886
2887 \message{glyphs,}
2888 % and logos.
2889
2890 % @@ prints an @, as does @atchar{}.
2891 \def\@{\char64 }
2892 \let\atchar=\@
2893
2894 % @{ @} @lbracechar{} @rbracechar{} all generate brace characters.
2895 % Unless we're in typewriter, use \ecfont because the CM text fonts do
2896 % not have braces, and we don't want to switch into math.
2897 \def\mylbrace{{\ifmonospace\else\ecfont\fi \char123}}
2898 \def\myrbrace{{\ifmonospace\else\ecfont\fi \char125}}
2899 \let\{=\mylbrace \let\lbracechar=\{
2900 \let\}=\myrbrace \let\rbracechar=\}
2901 \begingroup
2902 % Definitions to produce \{ and \} commands for indices,
2903 % and @{ and @} for the aux/toc files.
2904 \catcode`\{ = \other \catcode`\} = \other
2905 \catcode`\[ = 1 \catcode`\] = 2
2906 \catcode`\! = 0 \catcode`\\ = \other
2907 !gdef!lbracecmd[\{]%
2908 !gdef!rbracecmd[\}]%
2909 !gdef!lbraceatcmd[@{]%
2910 !gdef!rbraceatcmd[@}]%
2911 !endgroup
2912
2913 % @comma{} to avoid , parsing problems.
2914 \let\comma = ,
2915
2916 % Accents: @, @dotaccent @ringaccent @ubaraccent @udotaccent
2917 % Others are defined by plain TeX: @` @' @" @^ @~ @= @u @v @H.
2918 \let\, = \ptexc
2919 \let\dotaccent = \ptexdot
2920 \def\ringaccent#1{{\accent23 #1}}
2921 \let\tieaccent = \ptext
2922 \let\ubaraccent = \ptexb
2923 \let\udotaccent = \d
2924
2925 % Other special characters: @questiondown @exclamdown @ordf @ordm
2926 % Plain TeX defines: @AA @AE @O @OE @L (plus lowercase versions) @ss.
2927 \def\questiondown{?`}
2928 \def\exclamdown{!`}
2929 \def\ordf{\leavevmode\raise1ex\hbox{\selectfonts\lllsize \underbar{a}}}
2930 \def\ordm{\leavevmode\raise1ex\hbox{\selectfonts\lllsize \underbar{o}}}
2931
2932 % Dotless i and dotless j, used for accents.
2933 \def\imacro{i}
2934 \def\jmacro{j}
2935 \def\dotless#1{%
2936 \def\temp{#1}%
2937 \ifx\temp\imacro \ifmmode\imath \else\ptexi \fi
2938 \else\ifx\temp\jmacro \ifmmode\jmath \else\j \fi
2939 \else \errmessage{@dotless can be used only with i or j}%
2940 \fi\fi
2941 }
2942
2943 % The \TeX{} logo, as in plain, but resetting the spacing so that a
2944 % period following counts as ending a sentence. (Idea found in latex.)
2945 %
2946 \edef\TeX{\TeX \spacefactor=1000 }
2947
2948 % @LaTeX{} logo. Not quite the same results as the definition in
2949 % latex.ltx, since we use a different font for the raised A; it's most
2950 % convenient for us to use an explicitly smaller font, rather than using
2951 % the \scriptstyle font (since we don't reset \scriptstyle and
2952 % \scriptscriptstyle).
2953 %
2954 \def\LaTeX{%
2955 L\kern-.36em
2956 {\setbox0=\hbox{T}%
2957 \vbox to \ht0{\hbox{%
2958 \ifx\textnominalsize\xwordpt
2959 % for 10pt running text, \lllsize (8pt) is too small for the A in LaTeX.
2960 % Revert to plain's \scriptsize, which is 7pt.
2961 \count255=\the\fam $\fam\count255 \scriptstyle A$%
2962 \else
2963 % For 11pt, we can use our lllsize.
2964 \selectfonts\lllsize A%
2965 \fi
2966 }%
2967 \vss
2968 }}%
2969 \kern-.15em
2970 \TeX
2971 }
2972
2973 % Some math mode symbols.
2974 \def\bullet{$\ptexbullet$}
2975 \def\geq{\ifmmode \ge\else $\ge$\fi}
2976 \def\leq{\ifmmode \le\else $\le$\fi}
2977 \def\minus{\ifmmode -\else $-$\fi}
2978
2979 % @dots{} outputs an ellipsis using the current font.
2980 % We do .5em per period so that it has the same spacing in the cm
2981 % typewriter fonts as three actual period characters; on the other hand,
2982 % in other typewriter fonts three periods are wider than 1.5em. So do
2983 % whichever is larger.
2984 %
2985 \def\dots{%
2986 \leavevmode
2987 \setbox0=\hbox{...}% get width of three periods
2988 \ifdim\wd0 > 1.5em
2989 \dimen0 = \wd0
2990 \else
2991 \dimen0 = 1.5em
2992 \fi
2993 \hbox to \dimen0{%
2994 \hskip 0pt plus.25fil
2995 .\hskip 0pt plus1fil
2996 .\hskip 0pt plus1fil
2997 .\hskip 0pt plus.5fil
2998 }%
2999 }
3000
3001 % @enddots{} is an end-of-sentence ellipsis.
3002 %
3003 \def\enddots{%
3004 \dots
3005 \spacefactor=\endofsentencespacefactor
3006 }
3007
3008 % @point{}, @result{}, @expansion{}, @print{}, @equiv{}.
3009 %
3010 % Since these characters are used in examples, they should be an even number of
3011 % \tt widths. Each \tt character is 1en, so two makes it 1em.
3012 %
3013 \def\point{$\star$}
3014 \def\arrow{\leavevmode\raise.05ex\hbox to 1em{\hfil$\rightarrow$\hfil}}
3015 \def\result{\leavevmode\raise.05ex\hbox to 1em{\hfil$\Rightarrow$\hfil}}
3016 \def\expansion{\leavevmode\hbox to 1em{\hfil$\mapsto$\hfil}}
3017 \def\print{\leavevmode\lower.1ex\hbox to 1em{\hfil$\dashv$\hfil}}
3018 \def\equiv{\leavevmode\hbox to 1em{\hfil$\ptexequiv$\hfil}}
3019
3020 % The @error{} command.
3021 % Adapted from the TeXbook's \boxit.
3022 %
3023 \newbox\errorbox
3024 %
3025 {\tentt \global\dimen0 = 3em}% Width of the box.
3026 \dimen2 = .55pt % Thickness of rules
3027 % The text. (`r' is open on the right, `e' somewhat less so on the left.)
3028 \setbox0 = \hbox{\kern-.75pt \reducedsf \putworderror\kern-1.5pt}
3029 %
3030 \setbox\errorbox=\hbox to \dimen0{\hfil
3031 \hsize = \dimen0 \advance\hsize by -5.8pt % Space to left+right.
3032 \advance\hsize by -2\dimen2 % Rules.
3033 \vbox{%
3034 \hrule height\dimen2
3035 \hbox{\vrule width\dimen2 \kern3pt % Space to left of text.
3036 \vtop{\kern2.4pt \box0 \kern2.4pt}% Space above/below.
3037 \kern3pt\vrule width\dimen2}% Space to right.
3038 \hrule height\dimen2}
3039 \hfil}
3040 %
3041 \def\error{\leavevmode\lower.7ex\copy\errorbox}
3042
3043 % @pounds{} is a sterling sign, which Knuth put in the CM italic font.
3044 %
3045 \def\pounds{{\it\$}}
3046
3047 % @euro{} comes from a separate font, depending on the current style.
3048 % We use the free feym* fonts from the eurosym package by Henrik
3049 % Theiling, which support regular, slanted, bold and bold slanted (and
3050 % "outlined" (blackboard board, sort of) versions, which we don't need).
3051 % It is available from http://www.ctan.org/tex-archive/fonts/eurosym.
3052 %
3053 % Although only regular is the truly official Euro symbol, we ignore
3054 % that. The Euro is designed to be slightly taller than the regular
3055 % font height.
3056 %
3057 % feymr - regular
3058 % feymo - slanted
3059 % feybr - bold
3060 % feybo - bold slanted
3061 %
3062 % There is no good (free) typewriter version, to my knowledge.
3063 % A feymr10 euro is ~7.3pt wide, while a normal cmtt10 char is ~5.25pt wide.
3064 % Hmm.
3065 %
3066 % Also doesn't work in math. Do we need to do math with euro symbols?
3067 % Hope not.
3068 %
3069 %
3070 \def\euro{{\eurofont e}}
3071 \def\eurofont{%
3072 % We set the font at each command, rather than predefining it in
3073 % \textfonts and the other font-switching commands, so that
3074 % installations which never need the symbol don't have to have the
3075 % font installed.
3076 %
3077 % There is only one designed size (nominal 10pt), so we always scale
3078 % that to the current nominal size.
3079 %
3080 % By the way, simply using "at 1em" works for cmr10 and the like, but
3081 % does not work for cmbx10 and other extended/shrunken fonts.
3082 %
3083 \def\eurosize{\csname\curfontsize nominalsize\endcsname}%
3084 %
3085 \ifx\curfontstyle\bfstylename
3086 % bold:
3087 \font\thiseurofont = \ifusingit{feybo10}{feybr10} at \eurosize
3088 \else
3089 % regular:
3090 \font\thiseurofont = \ifusingit{feymo10}{feymr10} at \eurosize
3091 \fi
3092 \thiseurofont
3093 }
3094
3095 % Glyphs from the EC fonts. We don't use \let for the aliases, because
3096 % sometimes we redefine the original macro, and the alias should reflect
3097 % the redefinition.
3098 %
3099 % Use LaTeX names for the Icelandic letters.
3100 \def\DH{{\ecfont \char"D0}} % Eth
3101 \def\dh{{\ecfont \char"F0}} % eth
3102 \def\TH{{\ecfont \char"DE}} % Thorn
3103 \def\th{{\ecfont \char"FE}} % thorn
3104 %
3105 \def\guillemetleft{{\ecfont \char"13}}
3106 \def\guillemotleft{\guillemetleft}
3107 \def\guillemetright{{\ecfont \char"14}}
3108 \def\guillemotright{\guillemetright}
3109 \def\guilsinglleft{{\ecfont \char"0E}}
3110 \def\guilsinglright{{\ecfont \char"0F}}
3111 \def\quotedblbase{{\ecfont \char"12}}
3112 \def\quotesinglbase{{\ecfont \char"0D}}
3113 %
3114 % This positioning is not perfect (see the ogonek LaTeX package), but
3115 % we have the precomposed glyphs for the most common cases. We put the
3116 % tests to use those glyphs in the single \ogonek macro so we have fewer
3117 % dummy definitions to worry about for index entries, etc.
3118 %
3119 % ogonek is also used with other letters in Lithuanian (IOU), but using
3120 % the precomposed glyphs for those is not so easy since they aren't in
3121 % the same EC font.
3122 \def\ogonek#1{{%
3123 \def\temp{#1}%
3124 \ifx\temp\macrocharA\Aogonek
3125 \else\ifx\temp\macrochara\aogonek
3126 \else\ifx\temp\macrocharE\Eogonek
3127 \else\ifx\temp\macrochare\eogonek
3128 \else
3129 \ecfont \setbox0=\hbox{#1}%
3130 \ifdim\ht0=1ex\accent"0C #1%
3131 \else\ooalign{\unhbox0\crcr\hidewidth\char"0C \hidewidth}%
3132 \fi
3133 \fi\fi\fi\fi
3134 }%
3135 }
3136 \def\Aogonek{{\ecfont \char"81}}\def\macrocharA{A}
3137 \def\aogonek{{\ecfont \char"A1}}\def\macrochara{a}
3138 \def\Eogonek{{\ecfont \char"86}}\def\macrocharE{E}
3139 \def\eogonek{{\ecfont \char"A6}}\def\macrochare{e}
3140 %
3141 % Use the ec* fonts (cm-super in outline format) for non-CM glyphs.
3142 \def\ecfont{%
3143 % We can't distinguish serif/sans and italic/slanted, but this
3144 % is used for crude hacks anyway (like adding French and German
3145 % quotes to documents typeset with CM, where we lose kerning), so
3146 % hopefully nobody will notice/care.
3147 \edef\ecsize{\csname\curfontsize ecsize\endcsname}%
3148 \edef\nominalsize{\csname\curfontsize nominalsize\endcsname}%
3149 \ifmonospace
3150 % typewriter:
3151 \font\thisecfont = ectt\ecsize \space at \nominalsize
3152 \else
3153 \ifx\curfontstyle\bfstylename
3154 % bold:
3155 \font\thisecfont = ecb\ifusingit{i}{x}\ecsize \space at \nominalsize
3156 \else
3157 % regular:
3158 \font\thisecfont = ec\ifusingit{ti}{rm}\ecsize \space at \nominalsize
3159 \fi
3160 \fi
3161 \thisecfont
3162 }
3163
3164 % @registeredsymbol - R in a circle. The font for the R should really
3165 % be smaller yet, but lllsize is the best we can do for now.
3166 % Adapted from the plain.tex definition of \copyright.
3167 %
3168 \def\registeredsymbol{%
3169 $^{{\ooalign{\hfil\raise.07ex\hbox{\selectfonts\lllsize R}%
3170 \hfil\crcr\Orb}}%
3171 }$%
3172 }
3173
3174 % @textdegree - the normal degrees sign.
3175 %
3176 \def\textdegree{$^\circ$}
3177
3178 % Laurent Siebenmann reports \Orb undefined with:
3179 % Textures 1.7.7 (preloaded format=plain 93.10.14) (68K) 16 APR 2004 02:38
3180 % so we'll define it if necessary.
3181 %
3182 \ifx\Orb\thisisundefined
3183 \def\Orb{\mathhexbox20D}
3184 \fi
3185
3186 % Quotes.
3187 \chardef\quotedblleft="5C
3188 \chardef\quotedblright=`\"
3189 \chardef\quoteleft=`\`
3190 \chardef\quoteright=`\'
3191
3192
3193 \message{page headings,}
3194
3195 \newskip\titlepagetopglue \titlepagetopglue = 1.5in
3196 \newskip\titlepagebottomglue \titlepagebottomglue = 2pc
3197
3198 % First the title page. Must do @settitle before @titlepage.
3199 \newif\ifseenauthor
3200 \newif\iffinishedtitlepage
3201
3202 % Do an implicit @contents or @shortcontents after @end titlepage if the
3203 % user says @setcontentsaftertitlepage or @setshortcontentsaftertitlepage.
3204 %
3205 \newif\ifsetcontentsaftertitlepage
3206 \let\setcontentsaftertitlepage = \setcontentsaftertitlepagetrue
3207 \newif\ifsetshortcontentsaftertitlepage
3208 \let\setshortcontentsaftertitlepage = \setshortcontentsaftertitlepagetrue
3209
3210 \parseargdef\shorttitlepage{%
3211 \begingroup \hbox{}\vskip 1.5in \chaprm \centerline{#1}%
3212 \endgroup\page\hbox{}\page}
3213
3214 \envdef\titlepage{%
3215 % Open one extra group, as we want to close it in the middle of \Etitlepage.
3216 \begingroup
3217 \parindent=0pt \textfonts
3218 % Leave some space at the very top of the page.
3219 \vglue\titlepagetopglue
3220 % No rule at page bottom unless we print one at the top with @title.
3221 \finishedtitlepagetrue
3222 %
3223 % Most title ``pages'' are actually two pages long, with space
3224 % at the top of the second. We don't want the ragged left on the second.
3225 \let\oldpage = \page
3226 \def\page{%
3227 \iffinishedtitlepage\else
3228 \finishtitlepage
3229 \fi
3230 \let\page = \oldpage
3231 \page
3232 \null
3233 }%
3234 }
3235
3236 \def\Etitlepage{%
3237 \iffinishedtitlepage\else
3238 \finishtitlepage
3239 \fi
3240 % It is important to do the page break before ending the group,
3241 % because the headline and footline are only empty inside the group.
3242 % If we use the new definition of \page, we always get a blank page
3243 % after the title page, which we certainly don't want.
3244 \oldpage
3245 \endgroup
3246 %
3247 % Need this before the \...aftertitlepage checks so that if they are
3248 % in effect the toc pages will come out with page numbers.
3249 \HEADINGSon
3250 %
3251 % If they want short, they certainly want long too.
3252 \ifsetshortcontentsaftertitlepage
3253 \shortcontents
3254 \contents
3255 \global\let\shortcontents = \relax
3256 \global\let\contents = \relax
3257 \fi
3258 %
3259 \ifsetcontentsaftertitlepage
3260 \contents
3261 \global\let\contents = \relax
3262 \global\let\shortcontents = \relax
3263 \fi
3264 }
3265
3266 \def\finishtitlepage{%
3267 \vskip4pt \hrule height 2pt width \hsize
3268 \vskip\titlepagebottomglue
3269 \finishedtitlepagetrue
3270 }
3271
3272 % Settings used for typesetting titles: no hyphenation, no indentation,
3273 % don't worry much about spacing, ragged right. This should be used
3274 % inside a \vbox, and fonts need to be set appropriately first. Because
3275 % it is always used for titles, nothing else, we call \rmisbold. \par
3276 % should be specified before the end of the \vbox, since a vbox is a group.
3277 %
3278 \def\raggedtitlesettings{%
3279 \rmisbold
3280 \hyphenpenalty=10000
3281 \parindent=0pt
3282 \tolerance=5000
3283 \ptexraggedright
3284 }
3285
3286 % Macros to be used within @titlepage:
3287
3288 \let\subtitlerm=\tenrm
3289 \def\subtitlefont{\subtitlerm \normalbaselineskip = 13pt \normalbaselines}
3290
3291 \parseargdef\title{%
3292 \checkenv\titlepage
3293 \vbox{\titlefonts \raggedtitlesettings #1\par}%
3294 % print a rule at the page bottom also.
3295 \finishedtitlepagefalse
3296 \vskip4pt \hrule height 4pt width \hsize \vskip4pt
3297 }
3298
3299 \parseargdef\subtitle{%
3300 \checkenv\titlepage
3301 {\subtitlefont \rightline{#1}}%
3302 }
3303
3304 % @author should come last, but may come many times.
3305 % It can also be used inside @quotation.
3306 %
3307 \parseargdef\author{%
3308 \def\temp{\quotation}%
3309 \ifx\thisenv\temp
3310 \def\quotationauthor{#1}% printed in \Equotation.
3311 \else
3312 \checkenv\titlepage
3313 \ifseenauthor\else \vskip 0pt plus 1filll \seenauthortrue \fi
3314 {\secfonts\rmisbold \leftline{#1}}%
3315 \fi
3316 }
3317
3318
3319 % Set up page headings and footings.
3320
3321 \let\thispage=\folio
3322
3323 \newtoks\evenheadline % headline on even pages
3324 \newtoks\oddheadline % headline on odd pages
3325 \newtoks\evenfootline % footline on even pages
3326 \newtoks\oddfootline % footline on odd pages
3327
3328 % Now make TeX use those variables
3329 \headline={{\textfonts\rm \ifodd\pageno \the\oddheadline
3330 \else \the\evenheadline \fi}}
3331 \footline={{\textfonts\rm \ifodd\pageno \the\oddfootline
3332 \else \the\evenfootline \fi}\HEADINGShook}
3333 \let\HEADINGShook=\relax
3334
3335 % Commands to set those variables.
3336 % For example, this is what @headings on does
3337 % @evenheading @thistitle|@thispage|@thischapter
3338 % @oddheading @thischapter|@thispage|@thistitle
3339 % @evenfooting @thisfile||
3340 % @oddfooting ||@thisfile
3341
3342
3343 \def\evenheading{\parsearg\evenheadingxxx}
3344 \def\evenheadingxxx #1{\evenheadingyyy #1\|\|\|\|\finish}
3345 \def\evenheadingyyy #1\|#2\|#3\|#4\finish{%
3346 \global\evenheadline={\rlap{\centerline{#2}}\line{#1\hfil#3}}}
3347
3348 \def\oddheading{\parsearg\oddheadingxxx}
3349 \def\oddheadingxxx #1{\oddheadingyyy #1\|\|\|\|\finish}
3350 \def\oddheadingyyy #1\|#2\|#3\|#4\finish{%
3351 \global\oddheadline={\rlap{\centerline{#2}}\line{#1\hfil#3}}}
3352
3353 \parseargdef\everyheading{\oddheadingxxx{#1}\evenheadingxxx{#1}}%
3354
3355 \def\evenfooting{\parsearg\evenfootingxxx}
3356 \def\evenfootingxxx #1{\evenfootingyyy #1\|\|\|\|\finish}
3357 \def\evenfootingyyy #1\|#2\|#3\|#4\finish{%
3358 \global\evenfootline={\rlap{\centerline{#2}}\line{#1\hfil#3}}}
3359
3360 \def\oddfooting{\parsearg\oddfootingxxx}
3361 \def\oddfootingxxx #1{\oddfootingyyy #1\|\|\|\|\finish}
3362 \def\oddfootingyyy #1\|#2\|#3\|#4\finish{%
3363 \global\oddfootline = {\rlap{\centerline{#2}}\line{#1\hfil#3}}%
3364 %
3365 % Leave some space for the footline. Hopefully ok to assume
3366 % @evenfooting will not be used by itself.
3367 \global\advance\pageheight by -12pt
3368 \global\advance\vsize by -12pt
3369 }
3370
3371 \parseargdef\everyfooting{\oddfootingxxx{#1}\evenfootingxxx{#1}}
3372
3373 % @evenheadingmarks top \thischapter <- chapter at the top of a page
3374 % @evenheadingmarks bottom \thischapter <- chapter at the bottom of a page
3375 %
3376 % The same set of arguments for:
3377 %
3378 % @oddheadingmarks
3379 % @evenfootingmarks
3380 % @oddfootingmarks
3381 % @everyheadingmarks
3382 % @everyfootingmarks
3383
3384 \def\evenheadingmarks{\headingmarks{even}{heading}}
3385 \def\oddheadingmarks{\headingmarks{odd}{heading}}
3386 \def\evenfootingmarks{\headingmarks{even}{footing}}
3387 \def\oddfootingmarks{\headingmarks{odd}{footing}}
3388 \def\everyheadingmarks#1 {\headingmarks{even}{heading}{#1}
3389 \headingmarks{odd}{heading}{#1} }
3390 \def\everyfootingmarks#1 {\headingmarks{even}{footing}{#1}
3391 \headingmarks{odd}{footing}{#1} }
3392 % #1 = even/odd, #2 = heading/footing, #3 = top/bottom.
3393 \def\headingmarks#1#2#3 {%
3394 \expandafter\let\expandafter\temp \csname get#3headingmarks\endcsname
3395 \global\expandafter\let\csname get#1#2marks\endcsname \temp
3396 }
3397
3398 \everyheadingmarks bottom
3399 \everyfootingmarks bottom
3400
3401 % @headings double turns headings on for double-sided printing.
3402 % @headings single turns headings on for single-sided printing.
3403 % @headings off turns them off.
3404 % @headings on same as @headings double, retained for compatibility.
3405 % @headings after turns on double-sided headings after this page.
3406 % @headings doubleafter turns on double-sided headings after this page.
3407 % @headings singleafter turns on single-sided headings after this page.
3408 % By default, they are off at the start of a document,
3409 % and turned `on' after @end titlepage.
3410
3411 \def\headings #1 {\csname HEADINGS#1\endcsname}
3412
3413 \def\headingsoff{% non-global headings elimination
3414 \evenheadline={\hfil}\evenfootline={\hfil}%
3415 \oddheadline={\hfil}\oddfootline={\hfil}%
3416 }
3417
3418 \def\HEADINGSoff{{\globaldefs=1 \headingsoff}} % global setting
3419 \HEADINGSoff % it's the default
3420
3421 % When we turn headings on, set the page number to 1.
3422 % For double-sided printing, put current file name in lower left corner,
3423 % chapter name on inside top of right hand pages, document
3424 % title on inside top of left hand pages, and page numbers on outside top
3425 % edge of all pages.
3426 \def\HEADINGSdouble{%
3427 \global\pageno=1
3428 \global\evenfootline={\hfil}
3429 \global\oddfootline={\hfil}
3430 \global\evenheadline={\line{\folio\hfil\thistitle}}
3431 \global\oddheadline={\line{\thischapter\hfil\folio}}
3432 \global\let\contentsalignmacro = \chapoddpage
3433 }
3434 \let\contentsalignmacro = \chappager
3435
3436 % For single-sided printing, chapter title goes across top left of page,
3437 % page number on top right.
3438 \def\HEADINGSsingle{%
3439 \global\pageno=1
3440 \global\evenfootline={\hfil}
3441 \global\oddfootline={\hfil}
3442 \global\evenheadline={\line{\thischapter\hfil\folio}}
3443 \global\oddheadline={\line{\thischapter\hfil\folio}}
3444 \global\let\contentsalignmacro = \chappager
3445 }
3446 \def\HEADINGSon{\HEADINGSdouble}
3447
3448 \def\HEADINGSafter{\let\HEADINGShook=\HEADINGSdoublex}
3449 \let\HEADINGSdoubleafter=\HEADINGSafter
3450 \def\HEADINGSdoublex{%
3451 \global\evenfootline={\hfil}
3452 \global\oddfootline={\hfil}
3453 \global\evenheadline={\line{\folio\hfil\thistitle}}
3454 \global\oddheadline={\line{\thischapter\hfil\folio}}
3455 \global\let\contentsalignmacro = \chapoddpage
3456 }
3457
3458 \def\HEADINGSsingleafter{\let\HEADINGShook=\HEADINGSsinglex}
3459 \def\HEADINGSsinglex{%
3460 \global\evenfootline={\hfil}
3461 \global\oddfootline={\hfil}
3462 \global\evenheadline={\line{\thischapter\hfil\folio}}
3463 \global\oddheadline={\line{\thischapter\hfil\folio}}
3464 \global\let\contentsalignmacro = \chappager
3465 }
3466
3467 % Subroutines used in generating headings
3468 % This produces Day Month Year style of output.
3469 % Only define if not already defined, in case a txi-??.tex file has set
3470 % up a different format (e.g., txi-cs.tex does this).
3471 \ifx\today\thisisundefined
3472 \def\today{%
3473 \number\day\space
3474 \ifcase\month
3475 \or\putwordMJan\or\putwordMFeb\or\putwordMMar\or\putwordMApr
3476 \or\putwordMMay\or\putwordMJun\or\putwordMJul\or\putwordMAug
3477 \or\putwordMSep\or\putwordMOct\or\putwordMNov\or\putwordMDec
3478 \fi
3479 \space\number\year}
3480 \fi
3481
3482 % @settitle line... specifies the title of the document, for headings.
3483 % It generates no output of its own.
3484 \def\thistitle{\putwordNoTitle}
3485 \def\settitle{\parsearg{\gdef\thistitle}}
3486
3487
3488 \message{tables,}
3489 % Tables -- @table, @ftable, @vtable, @item(x).
3490
3491 % default indentation of table text
3492 \newdimen\tableindent \tableindent=.8in
3493 % default indentation of @itemize and @enumerate text
3494 \newdimen\itemindent \itemindent=.3in
3495 % margin between end of table item and start of table text.
3496 \newdimen\itemmargin \itemmargin=.1in
3497
3498 % used internally for \itemindent minus \itemmargin
3499 \newdimen\itemmax
3500
3501 % Note @table, @ftable, and @vtable define @item, @itemx, etc., with
3502 % these defs.
3503 % They also define \itemindex
3504 % to index the item name in whatever manner is desired (perhaps none).
3505
3506 \newif\ifitemxneedsnegativevskip
3507
3508 \def\itemxpar{\par\ifitemxneedsnegativevskip\nobreak\vskip-\parskip\nobreak\fi}
3509
3510 \def\internalBitem{\smallbreak \parsearg\itemzzz}
3511 \def\internalBitemx{\itemxpar \parsearg\itemzzz}
3512
3513 \def\itemzzz #1{\begingroup %
3514 \advance\hsize by -\rightskip
3515 \advance\hsize by -\tableindent
3516 \setbox0=\hbox{\itemindicate{#1}}%
3517 \itemindex{#1}%
3518 \nobreak % This prevents a break before @itemx.
3519 %
3520 % If the item text does not fit in the space we have, put it on a line
3521 % by itself, and do not allow a page break either before or after that
3522 % line. We do not start a paragraph here because then if the next
3523 % command is, e.g., @kindex, the whatsit would get put into the
3524 % horizontal list on a line by itself, resulting in extra blank space.
3525 \ifdim \wd0>\itemmax
3526 %
3527 % Make this a paragraph so we get the \parskip glue and wrapping,
3528 % but leave it ragged-right.
3529 \begingroup
3530 \advance\leftskip by-\tableindent
3531 \advance\hsize by\tableindent
3532 \advance\rightskip by0pt plus1fil\relax
3533 \leavevmode\unhbox0\par
3534 \endgroup
3535 %
3536 % We're going to be starting a paragraph, but we don't want the
3537 % \parskip glue -- logically it's part of the @item we just started.
3538 \nobreak \vskip-\parskip
3539 %
3540 % Stop a page break at the \parskip glue coming up. However, if
3541 % what follows is an environment such as @example, there will be no
3542 % \parskip glue; then the negative vskip we just inserted would
3543 % cause the example and the item to crash together. So we use this
3544 % bizarre value of 10001 as a signal to \aboveenvbreak to insert
3545 % \parskip glue after all. Section titles are handled this way also.
3546 %
3547 \penalty 10001
3548 \endgroup
3549 \itemxneedsnegativevskipfalse
3550 \else
3551 % The item text fits into the space. Start a paragraph, so that the
3552 % following text (if any) will end up on the same line.
3553 \noindent
3554 % Do this with kerns and \unhbox so that if there is a footnote in
3555 % the item text, it can migrate to the main vertical list and
3556 % eventually be printed.
3557 \nobreak\kern-\tableindent
3558 \dimen0 = \itemmax \advance\dimen0 by \itemmargin \advance\dimen0 by -\wd0
3559 \unhbox0
3560 \nobreak\kern\dimen0
3561 \endgroup
3562 \itemxneedsnegativevskiptrue
3563 \fi
3564 }
3565
3566 \def\item{\errmessage{@item while not in a list environment}}
3567 \def\itemx{\errmessage{@itemx while not in a list environment}}
3568
3569 % @table, @ftable, @vtable.
3570 \envdef\table{%
3571 \let\itemindex\gobble
3572 \tablecheck{table}%
3573 }
3574 \envdef\ftable{%
3575 \def\itemindex ##1{\doind {fn}{\code{##1}}}%
3576 \tablecheck{ftable}%
3577 }
3578 \envdef\vtable{%
3579 \def\itemindex ##1{\doind {vr}{\code{##1}}}%
3580 \tablecheck{vtable}%
3581 }
3582 \def\tablecheck#1{%
3583 \ifnum \the\catcode`\^^M=\active
3584 \endgroup
3585 \errmessage{This command won't work in this context; perhaps the problem is
3586 that we are \inenvironment\thisenv}%
3587 \def\next{\doignore{#1}}%
3588 \else
3589 \let\next\tablex
3590 \fi
3591 \next
3592 }
3593 \def\tablex#1{%
3594 \def\itemindicate{#1}%
3595 \parsearg\tabley
3596 }
3597 \def\tabley#1{%
3598 {%
3599 \makevalueexpandable
3600 \edef\temp{\noexpand\tablez #1\space\space\space}%
3601 \expandafter
3602 }\temp \endtablez
3603 }
3604 \def\tablez #1 #2 #3 #4\endtablez{%
3605 \aboveenvbreak
3606 \ifnum 0#1>0 \advance \leftskip by #1\mil \fi
3607 \ifnum 0#2>0 \tableindent=#2\mil \fi
3608 \ifnum 0#3>0 \advance \rightskip by #3\mil \fi
3609 \itemmax=\tableindent
3610 \advance \itemmax by -\itemmargin
3611 \advance \leftskip by \tableindent
3612 \exdentamount=\tableindent
3613 \parindent = 0pt
3614 \parskip = \smallskipamount
3615 \ifdim \parskip=0pt \parskip=2pt \fi
3616 \let\item = \internalBitem
3617 \let\itemx = \internalBitemx
3618 }
3619 \def\Etable{\endgraf\afterenvbreak}
3620 \let\Eftable\Etable
3621 \let\Evtable\Etable
3622 \let\Eitemize\Etable
3623 \let\Eenumerate\Etable
3624
3625 % This is the counter used by @enumerate, which is really @itemize
3626
3627 \newcount \itemno
3628
3629 \envdef\itemize{\parsearg\doitemize}
3630
3631 \def\doitemize#1{%
3632 \aboveenvbreak
3633 \itemmax=\itemindent
3634 \advance\itemmax by -\itemmargin
3635 \advance\leftskip by \itemindent
3636 \exdentamount=\itemindent
3637 \parindent=0pt
3638 \parskip=\smallskipamount
3639 \ifdim\parskip=0pt \parskip=2pt \fi
3640 %
3641 % Try typesetting the item mark that if the document erroneously says
3642 % something like @itemize @samp (intending @table), there's an error
3643 % right away at the @itemize. It's not the best error message in the
3644 % world, but it's better than leaving it to the @item. This means if
3645 % the user wants an empty mark, they have to say @w{} not just @w.
3646 \def\itemcontents{#1}%
3647 \setbox0 = \hbox{\itemcontents}%
3648 %
3649 % @itemize with no arg is equivalent to @itemize @bullet.
3650 \ifx\itemcontents\empty\def\itemcontents{\bullet}\fi
3651 %
3652 \let\item=\itemizeitem
3653 }
3654
3655 % Definition of @item while inside @itemize and @enumerate.
3656 %
3657 \def\itemizeitem{%
3658 \advance\itemno by 1 % for enumerations
3659 {\let\par=\endgraf \smallbreak}% reasonable place to break
3660 {%
3661 % If the document has an @itemize directly after a section title, a
3662 % \nobreak will be last on the list, and \sectionheading will have
3663 % done a \vskip-\parskip. In that case, we don't want to zero
3664 % parskip, or the item text will crash with the heading. On the
3665 % other hand, when there is normal text preceding the item (as there
3666 % usually is), we do want to zero parskip, or there would be too much
3667 % space. In that case, we won't have a \nobreak before. At least
3668 % that's the theory.
3669 \ifnum\lastpenalty<10000 \parskip=0in \fi
3670 \noindent
3671 \hbox to 0pt{\hss \itemcontents \kern\itemmargin}%
3672 %
3673 \vadjust{\penalty 1200}}% not good to break after first line of item.
3674 \flushcr
3675 }
3676
3677 % \splitoff TOKENS\endmark defines \first to be the first token in
3678 % TOKENS, and \rest to be the remainder.
3679 %
3680 \def\splitoff#1#2\endmark{\def\first{#1}\def\rest{#2}}%
3681
3682 % Allow an optional argument of an uppercase letter, lowercase letter,
3683 % or number, to specify the first label in the enumerated list. No
3684 % argument is the same as `1'.
3685 %
3686 \envparseargdef\enumerate{\enumeratey #1 \endenumeratey}
3687 \def\enumeratey #1 #2\endenumeratey{%
3688 % If we were given no argument, pretend we were given `1'.
3689 \def\thearg{#1}%
3690 \ifx\thearg\empty \def\thearg{1}\fi
3691 %
3692 % Detect if the argument is a single token. If so, it might be a
3693 % letter. Otherwise, the only valid thing it can be is a number.
3694 % (We will always have one token, because of the test we just made.
3695 % This is a good thing, since \splitoff doesn't work given nothing at
3696 % all -- the first parameter is undelimited.)
3697 \expandafter\splitoff\thearg\endmark
3698 \ifx\rest\empty
3699 % Only one token in the argument. It could still be anything.
3700 % A ``lowercase letter'' is one whose \lccode is nonzero.
3701 % An ``uppercase letter'' is one whose \lccode is both nonzero, and
3702 % not equal to itself.
3703 % Otherwise, we assume it's a number.
3704 %
3705 % We need the \relax at the end of the \ifnum lines to stop TeX from
3706 % continuing to look for a <number>.
3707 %
3708 \ifnum\lccode\expandafter`\thearg=0\relax
3709 \numericenumerate % a number (we hope)
3710 \else
3711 % It's a letter.
3712 \ifnum\lccode\expandafter`\thearg=\expandafter`\thearg\relax
3713 \lowercaseenumerate % lowercase letter
3714 \else
3715 \uppercaseenumerate % uppercase letter
3716 \fi
3717 \fi
3718 \else
3719 % Multiple tokens in the argument. We hope it's a number.
3720 \numericenumerate
3721 \fi
3722 }
3723
3724 % An @enumerate whose labels are integers. The starting integer is
3725 % given in \thearg.
3726 %
3727 \def\numericenumerate{%
3728 \itemno = \thearg
3729 \startenumeration{\the\itemno}%
3730 }
3731
3732 % The starting (lowercase) letter is in \thearg.
3733 \def\lowercaseenumerate{%
3734 \itemno = \expandafter`\thearg
3735 \startenumeration{%
3736 % Be sure we're not beyond the end of the alphabet.
3737 \ifnum\itemno=0
3738 \errmessage{No more lowercase letters in @enumerate; get a bigger
3739 alphabet}%
3740 \fi
3741 \char\lccode\itemno
3742 }%
3743 }
3744
3745 % The starting (uppercase) letter is in \thearg.
3746 \def\uppercaseenumerate{%
3747 \itemno = \expandafter`\thearg
3748 \startenumeration{%
3749 % Be sure we're not beyond the end of the alphabet.
3750 \ifnum\itemno=0
3751 \errmessage{No more uppercase letters in @enumerate; get a bigger
3752 alphabet}
3753 \fi
3754 \char\uccode\itemno
3755 }%
3756 }
3757
3758 % Call \doitemize, adding a period to the first argument and supplying the
3759 % common last two arguments. Also subtract one from the initial value in
3760 % \itemno, since @item increments \itemno.
3761 %
3762 \def\startenumeration#1{%
3763 \advance\itemno by -1
3764 \doitemize{#1.}\flushcr
3765 }
3766
3767 % @alphaenumerate and @capsenumerate are abbreviations for giving an arg
3768 % to @enumerate.
3769 %
3770 \def\alphaenumerate{\enumerate{a}}
3771 \def\capsenumerate{\enumerate{A}}
3772 \def\Ealphaenumerate{\Eenumerate}
3773 \def\Ecapsenumerate{\Eenumerate}
3774
3775
3776 % @multitable macros
3777 % Amy Hendrickson, 8/18/94, 3/6/96
3778 %
3779 % @multitable ... @end multitable will make as many columns as desired.
3780 % Contents of each column will wrap at width given in preamble. Width
3781 % can be specified either with sample text given in a template line,
3782 % or in percent of \hsize, the current width of text on page.
3783
3784 % Table can continue over pages but will only break between lines.
3785
3786 % To make preamble:
3787 %
3788 % Either define widths of columns in terms of percent of \hsize:
3789 % @multitable @columnfractions .25 .3 .45
3790 % @item ...
3791 %
3792 % Numbers following @columnfractions are the percent of the total
3793 % current hsize to be used for each column. You may use as many
3794 % columns as desired.
3795
3796
3797 % Or use a template:
3798 % @multitable {Column 1 template} {Column 2 template} {Column 3 template}
3799 % @item ...
3800 % using the widest term desired in each column.
3801
3802 % Each new table line starts with @item, each subsequent new column
3803 % starts with @tab. Empty columns may be produced by supplying @tab's
3804 % with nothing between them for as many times as empty columns are needed,
3805 % ie, @tab@tab@tab will produce two empty columns.
3806
3807 % @item, @tab do not need to be on their own lines, but it will not hurt
3808 % if they are.
3809
3810 % Sample multitable:
3811
3812 % @multitable {Column 1 template} {Column 2 template} {Column 3 template}
3813 % @item first col stuff @tab second col stuff @tab third col
3814 % @item
3815 % first col stuff
3816 % @tab
3817 % second col stuff
3818 % @tab
3819 % third col
3820 % @item first col stuff @tab second col stuff
3821 % @tab Many paragraphs of text may be used in any column.
3822 %
3823 % They will wrap at the width determined by the template.
3824 % @item@tab@tab This will be in third column.
3825 % @end multitable
3826
3827 % Default dimensions may be reset by user.
3828 % @multitableparskip is vertical space between paragraphs in table.
3829 % @multitableparindent is paragraph indent in table.
3830 % @multitablecolmargin is horizontal space to be left between columns.
3831 % @multitablelinespace is space to leave between table items, baseline
3832 % to baseline.
3833 % 0pt means it depends on current normal line spacing.
3834 %
3835 \newskip\multitableparskip
3836 \newskip\multitableparindent
3837 \newdimen\multitablecolspace
3838 \newskip\multitablelinespace
3839 \multitableparskip=0pt
3840 \multitableparindent=6pt
3841 \multitablecolspace=12pt
3842 \multitablelinespace=0pt
3843
3844 % Macros used to set up halign preamble:
3845 %
3846 \let\endsetuptable\relax
3847 \def\xendsetuptable{\endsetuptable}
3848 \let\columnfractions\relax
3849 \def\xcolumnfractions{\columnfractions}
3850 \newif\ifsetpercent
3851
3852 % #1 is the @columnfraction, usually a decimal number like .5, but might
3853 % be just 1. We just use it, whatever it is.
3854 %
3855 \def\pickupwholefraction#1 {%
3856 \global\advance\colcount by 1
3857 \expandafter\xdef\csname col\the\colcount\endcsname{#1\hsize}%
3858 \setuptable
3859 }
3860
3861 \newcount\colcount
3862 \def\setuptable#1{%
3863 \def\firstarg{#1}%
3864 \ifx\firstarg\xendsetuptable
3865 \let\go = \relax
3866 \else
3867 \ifx\firstarg\xcolumnfractions
3868 \global\setpercenttrue
3869 \else
3870 \ifsetpercent
3871 \let\go\pickupwholefraction
3872 \else
3873 \global\advance\colcount by 1
3874 \setbox0=\hbox{#1\unskip\space}% Add a normal word space as a
3875 % separator; typically that is always in the input, anyway.
3876 \expandafter\xdef\csname col\the\colcount\endcsname{\the\wd0}%
3877 \fi
3878 \fi
3879 \ifx\go\pickupwholefraction
3880 % Put the argument back for the \pickupwholefraction call, so
3881 % we'll always have a period there to be parsed.
3882 \def\go{\pickupwholefraction#1}%
3883 \else
3884 \let\go = \setuptable
3885 \fi%
3886 \fi
3887 \go
3888 }
3889
3890 % multitable-only commands.
3891 %
3892 % @headitem starts a heading row, which we typeset in bold.
3893 % Assignments have to be global since we are inside the implicit group
3894 % of an alignment entry. \everycr resets \everytab so we don't have to
3895 % undo it ourselves.
3896 \def\headitemfont{\b}% for people to use in the template row; not changeable
3897 \def\headitem{%
3898 \checkenv\multitable
3899 \crcr
3900 \global\everytab={\bf}% can't use \headitemfont since the parsing differs
3901 \the\everytab % for the first item
3902 }%
3903 %
3904 % A \tab used to include \hskip1sp. But then the space in a template
3905 % line is not enough. That is bad. So let's go back to just `&' until
3906 % we again encounter the problem the 1sp was intended to solve.
3907 % --karl, nathan@acm.org, 20apr99.
3908 \def\tab{\checkenv\multitable &\the\everytab}%
3909
3910 % @multitable ... @end multitable definitions:
3911 %
3912 \newtoks\everytab % insert after every tab.
3913 %
3914 \envdef\multitable{%
3915 \vskip\parskip
3916 \startsavinginserts
3917 %
3918 % @item within a multitable starts a normal row.
3919 % We use \def instead of \let so that if one of the multitable entries
3920 % contains an @itemize, we don't choke on the \item (seen as \crcr aka
3921 % \endtemplate) expanding \doitemize.
3922 \def\item{\crcr}%
3923 %
3924 \tolerance=9500
3925 \hbadness=9500
3926 \setmultitablespacing
3927 \parskip=\multitableparskip
3928 \parindent=\multitableparindent
3929 \overfullrule=0pt
3930 \global\colcount=0
3931 %
3932 \everycr = {%
3933 \noalign{%
3934 \global\everytab={}%
3935 \global\colcount=0 % Reset the column counter.
3936 % Check for saved footnotes, etc.
3937 \checkinserts
3938 % Keeps underfull box messages off when table breaks over pages.
3939 %\filbreak
3940 % Maybe so, but it also creates really weird page breaks when the
3941 % table breaks over pages. Wouldn't \vfil be better? Wait until the
3942 % problem manifests itself, so it can be fixed for real --karl.
3943 }%
3944 }%
3945 %
3946 \parsearg\domultitable
3947 }
3948 \def\domultitable#1{%
3949 % To parse everything between @multitable and @item:
3950 \setuptable#1 \endsetuptable
3951 %
3952 % This preamble sets up a generic column definition, which will
3953 % be used as many times as user calls for columns.
3954 % \vtop will set a single line and will also let text wrap and
3955 % continue for many paragraphs if desired.
3956 \halign\bgroup &%
3957 \global\advance\colcount by 1
3958 \multistrut
3959 \vtop{%
3960 % Use the current \colcount to find the correct column width:
3961 \hsize=\expandafter\csname col\the\colcount\endcsname
3962 %
3963 % In order to keep entries from bumping into each other
3964 % we will add a \leftskip of \multitablecolspace to all columns after
3965 % the first one.
3966 %
3967 % If a template has been used, we will add \multitablecolspace
3968 % to the width of each template entry.
3969 %
3970 % If the user has set preamble in terms of percent of \hsize we will
3971 % use that dimension as the width of the column, and the \leftskip
3972 % will keep entries from bumping into each other. Table will start at
3973 % left margin and final column will justify at right margin.
3974 %
3975 % Make sure we don't inherit \rightskip from the outer environment.
3976 \rightskip=0pt
3977 \ifnum\colcount=1
3978 % The first column will be indented with the surrounding text.
3979 \advance\hsize by\leftskip
3980 \else
3981 \ifsetpercent \else
3982 % If user has not set preamble in terms of percent of \hsize
3983 % we will advance \hsize by \multitablecolspace.
3984 \advance\hsize by \multitablecolspace
3985 \fi
3986 % In either case we will make \leftskip=\multitablecolspace:
3987 \leftskip=\multitablecolspace
3988 \fi
3989 % Ignoring space at the beginning and end avoids an occasional spurious
3990 % blank line, when TeX decides to break the line at the space before the
3991 % box from the multistrut, so the strut ends up on a line by itself.
3992 % For example:
3993 % @multitable @columnfractions .11 .89
3994 % @item @code{#}
3995 % @tab Legal holiday which is valid in major parts of the whole country.
3996 % Is automatically provided with highlighting sequences respectively
3997 % marking characters.
3998 \noindent\ignorespaces##\unskip\multistrut
3999 }\cr
4000 }
4001 \def\Emultitable{%
4002 \crcr
4003 \egroup % end the \halign
4004 \global\setpercentfalse
4005 }
4006
4007 \def\setmultitablespacing{%
4008 \def\multistrut{\strut}% just use the standard line spacing
4009 %
4010 % Compute \multitablelinespace (if not defined by user) for use in
4011 % \multitableparskip calculation. We used define \multistrut based on
4012 % this, but (ironically) that caused the spacing to be off.
4013 % See bug-texinfo report from Werner Lemberg, 31 Oct 2004 12:52:20 +0100.
4014 \ifdim\multitablelinespace=0pt
4015 \setbox0=\vbox{X}\global\multitablelinespace=\the\baselineskip
4016 \global\advance\multitablelinespace by-\ht0
4017 \fi
4018 % Test to see if parskip is larger than space between lines of
4019 % table. If not, do nothing.
4020 % If so, set to same dimension as multitablelinespace.
4021 \ifdim\multitableparskip>\multitablelinespace
4022 \global\multitableparskip=\multitablelinespace
4023 \global\advance\multitableparskip-7pt % to keep parskip somewhat smaller
4024 % than skip between lines in the table.
4025 \fi%
4026 \ifdim\multitableparskip=0pt
4027 \global\multitableparskip=\multitablelinespace
4028 \global\advance\multitableparskip-7pt % to keep parskip somewhat smaller
4029 % than skip between lines in the table.
4030 \fi}
4031
4032
4033 \message{conditionals,}
4034
4035 % @iftex, @ifnotdocbook, @ifnothtml, @ifnotinfo, @ifnotplaintext,
4036 % @ifnotxml always succeed. They currently do nothing; we don't
4037 % attempt to check whether the conditionals are properly nested. But we
4038 % have to remember that they are conditionals, so that @end doesn't
4039 % attempt to close an environment group.
4040 %
4041 \def\makecond#1{%
4042 \expandafter\let\csname #1\endcsname = \relax
4043 \expandafter\let\csname iscond.#1\endcsname = 1
4044 }
4045 \makecond{iftex}
4046 \makecond{ifnotdocbook}
4047 \makecond{ifnothtml}
4048 \makecond{ifnotinfo}
4049 \makecond{ifnotplaintext}
4050 \makecond{ifnotxml}
4051
4052 % Ignore @ignore, @ifhtml, @ifinfo, and the like.
4053 %
4054 \def\direntry{\doignore{direntry}}
4055 \def\documentdescription{\doignore{documentdescription}}
4056 \def\docbook{\doignore{docbook}}
4057 \def\html{\doignore{html}}
4058 \def\ifdocbook{\doignore{ifdocbook}}
4059 \def\ifhtml{\doignore{ifhtml}}
4060 \def\ifinfo{\doignore{ifinfo}}
4061 \def\ifnottex{\doignore{ifnottex}}
4062 \def\ifplaintext{\doignore{ifplaintext}}
4063 \def\ifxml{\doignore{ifxml}}
4064 \def\ignore{\doignore{ignore}}
4065 \def\menu{\doignore{menu}}
4066 \def\xml{\doignore{xml}}
4067
4068 % Ignore text until a line `@end #1', keeping track of nested conditionals.
4069 %
4070 % A count to remember the depth of nesting.
4071 \newcount\doignorecount
4072
4073 \def\doignore#1{\begingroup
4074 % Scan in ``verbatim'' mode:
4075 \obeylines
4076 \catcode`\@ = \other
4077 \catcode`\{ = \other
4078 \catcode`\} = \other
4079 %
4080 % Make sure that spaces turn into tokens that match what \doignoretext wants.
4081 \spaceisspace
4082 %
4083 % Count number of #1's that we've seen.
4084 \doignorecount = 0
4085 %
4086 % Swallow text until we reach the matching `@end #1'.
4087 \dodoignore{#1}%
4088 }
4089
4090 { \catcode`_=11 % We want to use \_STOP_ which cannot appear in texinfo source.
4091 \obeylines %
4092 %
4093 \gdef\dodoignore#1{%
4094 % #1 contains the command name as a string, e.g., `ifinfo'.
4095 %
4096 % Define a command to find the next `@end #1'.
4097 \long\def\doignoretext##1^^M@end #1{%
4098 \doignoretextyyy##1^^M@#1\_STOP_}%
4099 %
4100 % And this command to find another #1 command, at the beginning of a
4101 % line. (Otherwise, we would consider a line `@c @ifset', for
4102 % example, to count as an @ifset for nesting.)
4103 \long\def\doignoretextyyy##1^^M@#1##2\_STOP_{\doignoreyyy{##2}\_STOP_}%
4104 %
4105 % And now expand that command.
4106 \doignoretext ^^M%
4107 }%
4108 }
4109
4110 \def\doignoreyyy#1{%
4111 \def\temp{#1}%
4112 \ifx\temp\empty % Nothing found.
4113 \let\next\doignoretextzzz
4114 \else % Found a nested condition, ...
4115 \advance\doignorecount by 1
4116 \let\next\doignoretextyyy % ..., look for another.
4117 % If we're here, #1 ends with ^^M\ifinfo (for example).
4118 \fi
4119 \next #1% the token \_STOP_ is present just after this macro.
4120 }
4121
4122 % We have to swallow the remaining "\_STOP_".
4123 %
4124 \def\doignoretextzzz#1{%
4125 \ifnum\doignorecount = 0 % We have just found the outermost @end.
4126 \let\next\enddoignore
4127 \else % Still inside a nested condition.
4128 \advance\doignorecount by -1
4129 \let\next\doignoretext % Look for the next @end.
4130 \fi
4131 \next
4132 }
4133
4134 % Finish off ignored text.
4135 { \obeylines%
4136 % Ignore anything after the last `@end #1'; this matters in verbatim
4137 % environments, where otherwise the newline after an ignored conditional
4138 % would result in a blank line in the output.
4139 \gdef\enddoignore#1^^M{\endgroup\ignorespaces}%
4140 }
4141
4142
4143 % @set VAR sets the variable VAR to an empty value.
4144 % @set VAR REST-OF-LINE sets VAR to the value REST-OF-LINE.
4145 %
4146 % Since we want to separate VAR from REST-OF-LINE (which might be
4147 % empty), we can't just use \parsearg; we have to insert a space of our
4148 % own to delimit the rest of the line, and then take it out again if we
4149 % didn't need it.
4150 % We rely on the fact that \parsearg sets \catcode`\ =10.
4151 %
4152 \parseargdef\set{\setyyy#1 \endsetyyy}
4153 \def\setyyy#1 #2\endsetyyy{%
4154 {%
4155 \makevalueexpandable
4156 \def\temp{#2}%
4157 \edef\next{\gdef\makecsname{SET#1}}%
4158 \ifx\temp\empty
4159 \next{}%
4160 \else
4161 \setzzz#2\endsetzzz
4162 \fi
4163 }%
4164 }
4165 % Remove the trailing space \setxxx inserted.
4166 \def\setzzz#1 \endsetzzz{\next{#1}}
4167
4168 % @clear VAR clears (i.e., unsets) the variable VAR.
4169 %
4170 \parseargdef\clear{%
4171 {%
4172 \makevalueexpandable
4173 \global\expandafter\let\csname SET#1\endcsname=\relax
4174 }%
4175 }
4176
4177 % @value{foo} gets the text saved in variable foo.
4178 \def\value{\begingroup\makevalueexpandable\valuexxx}
4179 \def\valuexxx#1{\expandablevalue{#1}\endgroup}
4180 {
4181 \catcode`\- = \active \catcode`\_ = \active
4182 %
4183 \gdef\makevalueexpandable{%
4184 \let\value = \expandablevalue
4185 % We don't want these characters active, ...
4186 \catcode`\-=\other \catcode`\_=\other
4187 % ..., but we might end up with active ones in the argument if
4188 % we're called from @code, as @code{@value{foo-bar_}}, though.
4189 % So \let them to their normal equivalents.
4190 \let-\normaldash \let_\normalunderscore
4191 }
4192 }
4193
4194 % We have this subroutine so that we can handle at least some @value's
4195 % properly in indexes (we call \makevalueexpandable in \indexdummies).
4196 % The command has to be fully expandable (if the variable is set), since
4197 % the result winds up in the index file. This means that if the
4198 % variable's value contains other Texinfo commands, it's almost certain
4199 % it will fail (although perhaps we could fix that with sufficient work
4200 % to do a one-level expansion on the result, instead of complete).
4201 %
4202 \def\expandablevalue#1{%
4203 \expandafter\ifx\csname SET#1\endcsname\relax
4204 {[No value for ``#1'']}%
4205 \message{Variable `#1', used in @value, is not set.}%
4206 \else
4207 \csname SET#1\endcsname
4208 \fi
4209 }
4210
4211 % @ifset VAR ... @end ifset reads the `...' iff VAR has been defined
4212 % with @set.
4213 %
4214 % To get special treatment of `@end ifset,' call \makeond and the redefine.
4215 %
4216 \makecond{ifset}
4217 \def\ifset{\parsearg{\doifset{\let\next=\ifsetfail}}}
4218 \def\doifset#1#2{%
4219 {%
4220 \makevalueexpandable
4221 \let\next=\empty
4222 \expandafter\ifx\csname SET#2\endcsname\relax
4223 #1% If not set, redefine \next.
4224 \fi
4225 \expandafter
4226 }\next
4227 }
4228 \def\ifsetfail{\doignore{ifset}}
4229
4230 % @ifclear VAR ... @end executes the `...' iff VAR has never been
4231 % defined with @set, or has been undefined with @clear.
4232 %
4233 % The `\else' inside the `\doifset' parameter is a trick to reuse the
4234 % above code: if the variable is not set, do nothing, if it is set,
4235 % then redefine \next to \ifclearfail.
4236 %
4237 \makecond{ifclear}
4238 \def\ifclear{\parsearg{\doifset{\else \let\next=\ifclearfail}}}
4239 \def\ifclearfail{\doignore{ifclear}}
4240
4241 % @ifcommandisdefined CMD ... @end executes the `...' if CMD (written
4242 % without the @) is in fact defined. We can only feasibly check at the
4243 % TeX level, so something like `mathcode' is going to considered
4244 % defined even though it is not a Texinfo command.
4245 %
4246 \makecond{ifcommanddefined}
4247 \def\ifcommanddefined{\parsearg{\doifcmddefined{\let\next=\ifcmddefinedfail}}}
4248 %
4249 \def\doifcmddefined#1#2{{%
4250 \makevalueexpandable
4251 \let\next=\empty
4252 \expandafter\ifx\csname #2\endcsname\relax
4253 #1% If not defined, \let\next as above.
4254 \fi
4255 \expandafter
4256 }\next
4257 }
4258 \def\ifcmddefinedfail{\doignore{ifcommanddefined}}
4259
4260 % @ifcommandnotdefined CMD ... handled similar to @ifclear above.
4261 \makecond{ifcommandnotdefined}
4262 \def\ifcommandnotdefined{%
4263 \parsearg{\doifcmddefined{\else \let\next=\ifcmdnotdefinedfail}}}
4264 \def\ifcmdnotdefinedfail{\doignore{ifcommandnotdefined}}
4265
4266 % Set the `txicommandconditionals' variable, so documents have a way to
4267 % test if the @ifcommand...defined conditionals are available.
4268 \set txicommandconditionals
4269
4270 % @dircategory CATEGORY -- specify a category of the dir file
4271 % which this file should belong to. Ignore this in TeX.
4272 \let\dircategory=\comment
4273
4274 % @defininfoenclose.
4275 \let\definfoenclose=\comment
4276
4277
4278 \message{indexing,}
4279 % Index generation facilities
4280
4281 % Define \newwrite to be identical to plain tex's \newwrite
4282 % except not \outer, so it can be used within macros and \if's.
4283 \edef\newwrite{\makecsname{ptexnewwrite}}
4284
4285 % \newindex {foo} defines an index named foo.
4286 % It automatically defines \fooindex such that
4287 % \fooindex ...rest of line... puts an entry in the index foo.
4288 % It also defines \fooindfile to be the number of the output channel for
4289 % the file that accumulates this index. The file's extension is foo.
4290 % The name of an index should be no more than 2 characters long
4291 % for the sake of vms.
4292 %
4293 \def\newindex#1{%
4294 \iflinks
4295 \expandafter\newwrite \csname#1indfile\endcsname
4296 \openout \csname#1indfile\endcsname \jobname.#1 % Open the file
4297 \fi
4298 \expandafter\xdef\csname#1index\endcsname{% % Define @#1index
4299 \noexpand\doindex{#1}}
4300 }
4301
4302 % @defindex foo == \newindex{foo}
4303 %
4304 \def\defindex{\parsearg\newindex}
4305
4306 % Define @defcodeindex, like @defindex except put all entries in @code.
4307 %
4308 \def\defcodeindex{\parsearg\newcodeindex}
4309 %
4310 \def\newcodeindex#1{%
4311 \iflinks
4312 \expandafter\newwrite \csname#1indfile\endcsname
4313 \openout \csname#1indfile\endcsname \jobname.#1
4314 \fi
4315 \expandafter\xdef\csname#1index\endcsname{%
4316 \noexpand\docodeindex{#1}}%
4317 }
4318
4319
4320 % @synindex foo bar makes index foo feed into index bar.
4321 % Do this instead of @defindex foo if you don't want it as a separate index.
4322 %
4323 % @syncodeindex foo bar similar, but put all entries made for index foo
4324 % inside @code.
4325 %
4326 \def\synindex#1 #2 {\dosynindex\doindex{#1}{#2}}
4327 \def\syncodeindex#1 #2 {\dosynindex\docodeindex{#1}{#2}}
4328
4329 % #1 is \doindex or \docodeindex, #2 the index getting redefined (foo),
4330 % #3 the target index (bar).
4331 \def\dosynindex#1#2#3{%
4332 % Only do \closeout if we haven't already done it, else we'll end up
4333 % closing the target index.
4334 \expandafter \ifx\csname donesynindex#2\endcsname \relax
4335 % The \closeout helps reduce unnecessary open files; the limit on the
4336 % Acorn RISC OS is a mere 16 files.
4337 \expandafter\closeout\csname#2indfile\endcsname
4338 \expandafter\let\csname donesynindex#2\endcsname = 1
4339 \fi
4340 % redefine \fooindfile:
4341 \expandafter\let\expandafter\temp\expandafter=\csname#3indfile\endcsname
4342 \expandafter\let\csname#2indfile\endcsname=\temp
4343 % redefine \fooindex:
4344 \expandafter\xdef\csname#2index\endcsname{\noexpand#1{#3}}%
4345 }
4346
4347 % Define \doindex, the driver for all \fooindex macros.
4348 % Argument #1 is generated by the calling \fooindex macro,
4349 % and it is "foo", the name of the index.
4350
4351 % \doindex just uses \parsearg; it calls \doind for the actual work.
4352 % This is because \doind is more useful to call from other macros.
4353
4354 % There is also \dosubind {index}{topic}{subtopic}
4355 % which makes an entry in a two-level index such as the operation index.
4356
4357 \def\doindex#1{\edef\indexname{#1}\parsearg\singleindexer}
4358 \def\singleindexer #1{\doind{\indexname}{#1}}
4359
4360 % like the previous two, but they put @code around the argument.
4361 \def\docodeindex#1{\edef\indexname{#1}\parsearg\singlecodeindexer}
4362 \def\singlecodeindexer #1{\doind{\indexname}{\code{#1}}}
4363
4364 % Take care of Texinfo commands that can appear in an index entry.
4365 % Since there are some commands we want to expand, and others we don't,
4366 % we have to laboriously prevent expansion for those that we don't.
4367 %
4368 \def\indexdummies{%
4369 \escapechar = `\\ % use backslash in output files.
4370 \def\@{@}% change to @@ when we switch to @ as escape char in index files.
4371 \def\ {\realbackslash\space }%
4372 %
4373 % Need these unexpandable (because we define \tt as a dummy)
4374 % definitions when @{ or @} appear in index entry text. Also, more
4375 % complicated, when \tex is in effect and \{ is a \delimiter again.
4376 % We can't use \lbracecmd and \rbracecmd because texindex assumes
4377 % braces and backslashes are used only as delimiters. Perhaps we
4378 % should define @lbrace and @rbrace commands a la @comma.
4379 \def\{{{\tt\char123}}%
4380 \def\}{{\tt\char125}}%
4381 %
4382 % I don't entirely understand this, but when an index entry is
4383 % generated from a macro call, the \endinput which \scanmacro inserts
4384 % causes processing to be prematurely terminated. This is,
4385 % apparently, because \indexsorttmp is fully expanded, and \endinput
4386 % is an expandable command. The redefinition below makes \endinput
4387 % disappear altogether for that purpose -- although logging shows that
4388 % processing continues to some further point. On the other hand, it
4389 % seems \endinput does not hurt in the printed index arg, since that
4390 % is still getting written without apparent harm.
4391 %
4392 % Sample source (mac-idx3.tex, reported by Graham Percival to
4393 % help-texinfo, 22may06):
4394 % @macro funindex {WORD}
4395 % @findex xyz
4396 % @end macro
4397 % ...
4398 % @funindex commtest
4399 %
4400 % The above is not enough to reproduce the bug, but it gives the flavor.
4401 %
4402 % Sample whatsit resulting:
4403 % .@write3{\entry{xyz}{@folio }{@code {xyz@endinput }}}
4404 %
4405 % So:
4406 \let\endinput = \empty
4407 %
4408 % Do the redefinitions.
4409 \commondummies
4410 }
4411
4412 % For the aux and toc files, @ is the escape character. So we want to
4413 % redefine everything using @ as the escape character (instead of
4414 % \realbackslash, still used for index files). When everything uses @,
4415 % this will be simpler.
4416 %
4417 \def\atdummies{%
4418 \def\@{@@}%
4419 \def\ {@ }%
4420 \let\{ = \lbraceatcmd
4421 \let\} = \rbraceatcmd
4422 %
4423 % Do the redefinitions.
4424 \commondummies
4425 \otherbackslash
4426 }
4427
4428 % Called from \indexdummies and \atdummies.
4429 %
4430 \def\commondummies{%
4431 %
4432 % \definedummyword defines \#1 as \string\#1\space, thus effectively
4433 % preventing its expansion. This is used only for control words,
4434 % not control letters, because the \space would be incorrect for
4435 % control characters, but is needed to separate the control word
4436 % from whatever follows.
4437 %
4438 % For control letters, we have \definedummyletter, which omits the
4439 % space.
4440 %
4441 % These can be used both for control words that take an argument and
4442 % those that do not. If it is followed by {arg} in the input, then
4443 % that will dutifully get written to the index (or wherever).
4444 %
4445 \def\definedummyword ##1{\def##1{\string##1\space}}%
4446 \def\definedummyletter##1{\def##1{\string##1}}%
4447 \let\definedummyaccent\definedummyletter
4448 %
4449 \commondummiesnofonts
4450 %
4451 \definedummyletter\_%
4452 \definedummyletter\-%
4453 %
4454 % Non-English letters.
4455 \definedummyword\AA
4456 \definedummyword\AE
4457 \definedummyword\DH
4458 \definedummyword\L
4459 \definedummyword\O
4460 \definedummyword\OE
4461 \definedummyword\TH
4462 \definedummyword\aa
4463 \definedummyword\ae
4464 \definedummyword\dh
4465 \definedummyword\exclamdown
4466 \definedummyword\l
4467 \definedummyword\o
4468 \definedummyword\oe
4469 \definedummyword\ordf
4470 \definedummyword\ordm
4471 \definedummyword\questiondown
4472 \definedummyword\ss
4473 \definedummyword\th
4474 %
4475 % Although these internal commands shouldn't show up, sometimes they do.
4476 \definedummyword\bf
4477 \definedummyword\gtr
4478 \definedummyword\hat
4479 \definedummyword\less
4480 \definedummyword\sf
4481 \definedummyword\sl
4482 \definedummyword\tclose
4483 \definedummyword\tt
4484 %
4485 \definedummyword\LaTeX
4486 \definedummyword\TeX
4487 %
4488 % Assorted special characters.
4489 \definedummyword\arrow
4490 \definedummyword\bullet
4491 \definedummyword\comma
4492 \definedummyword\copyright
4493 \definedummyword\registeredsymbol
4494 \definedummyword\dots
4495 \definedummyword\enddots
4496 \definedummyword\entrybreak
4497 \definedummyword\equiv
4498 \definedummyword\error
4499 \definedummyword\euro
4500 \definedummyword\expansion
4501 \definedummyword\geq
4502 \definedummyword\guillemetleft
4503 \definedummyword\guillemetright
4504 \definedummyword\guilsinglleft
4505 \definedummyword\guilsinglright
4506 \definedummyword\lbracechar
4507 \definedummyword\leq
4508 \definedummyword\minus
4509 \definedummyword\ogonek
4510 \definedummyword\pounds
4511 \definedummyword\point
4512 \definedummyword\print
4513 \definedummyword\quotedblbase
4514 \definedummyword\quotedblleft
4515 \definedummyword\quotedblright
4516 \definedummyword\quoteleft
4517 \definedummyword\quoteright
4518 \definedummyword\quotesinglbase
4519 \definedummyword\rbracechar
4520 \definedummyword\result
4521 \definedummyword\textdegree
4522 %
4523 % We want to disable all macros so that they are not expanded by \write.
4524 \macrolist
4525 %
4526 \normalturnoffactive
4527 %
4528 % Handle some cases of @value -- where it does not contain any
4529 % (non-fully-expandable) commands.
4530 \makevalueexpandable
4531 }
4532
4533 % \commondummiesnofonts: common to \commondummies and \indexnofonts.
4534 %
4535 \def\commondummiesnofonts{%
4536 % Control letters and accents.
4537 \definedummyletter\!%
4538 \definedummyaccent\"%
4539 \definedummyaccent\'%
4540 \definedummyletter\*%
4541 \definedummyaccent\,%
4542 \definedummyletter\.%
4543 \definedummyletter\/%
4544 \definedummyletter\:%
4545 \definedummyaccent\=%
4546 \definedummyletter\?%
4547 \definedummyaccent\^%
4548 \definedummyaccent\`%
4549 \definedummyaccent\~%
4550 \definedummyword\u
4551 \definedummyword\v
4552 \definedummyword\H
4553 \definedummyword\dotaccent
4554 \definedummyword\ogonek
4555 \definedummyword\ringaccent
4556 \definedummyword\tieaccent
4557 \definedummyword\ubaraccent
4558 \definedummyword\udotaccent
4559 \definedummyword\dotless
4560 %
4561 % Texinfo font commands.
4562 \definedummyword\b
4563 \definedummyword\i
4564 \definedummyword\r
4565 \definedummyword\sansserif
4566 \definedummyword\sc
4567 \definedummyword\slanted
4568 \definedummyword\t
4569 %
4570 % Commands that take arguments.
4571 \definedummyword\abbr
4572 \definedummyword\acronym
4573 \definedummyword\anchor
4574 \definedummyword\cite
4575 \definedummyword\code
4576 \definedummyword\command
4577 \definedummyword\dfn
4578 \definedummyword\dmn
4579 \definedummyword\email
4580 \definedummyword\emph
4581 \definedummyword\env
4582 \definedummyword\file
4583 \definedummyword\image
4584 \definedummyword\indicateurl
4585 \definedummyword\inforef
4586 \definedummyword\kbd
4587 \definedummyword\key
4588 \definedummyword\math
4589 \definedummyword\option
4590 \definedummyword\pxref
4591 \definedummyword\ref
4592 \definedummyword\samp
4593 \definedummyword\strong
4594 \definedummyword\tie
4595 \definedummyword\uref
4596 \definedummyword\url
4597 \definedummyword\var
4598 \definedummyword\verb
4599 \definedummyword\w
4600 \definedummyword\xref
4601 }
4602
4603 % \indexnofonts is used when outputting the strings to sort the index
4604 % by, and when constructing control sequence names. It eliminates all
4605 % control sequences and just writes whatever the best ASCII sort string
4606 % would be for a given command (usually its argument).
4607 %
4608 \def\indexnofonts{%
4609 % Accent commands should become @asis.
4610 \def\definedummyaccent##1{\let##1\asis}%
4611 % We can just ignore other control letters.
4612 \def\definedummyletter##1{\let##1\empty}%
4613 % All control words become @asis by default; overrides below.
4614 \let\definedummyword\definedummyaccent
4615 %
4616 \commondummiesnofonts
4617 %
4618 % Don't no-op \tt, since it isn't a user-level command
4619 % and is used in the definitions of the active chars like <, >, |, etc.
4620 % Likewise with the other plain tex font commands.
4621 %\let\tt=\asis
4622 %
4623 \def\ { }%
4624 \def\@{@}%
4625 \def\_{\normalunderscore}%
4626 \def\-{}% @- shouldn't affect sorting
4627 %
4628 % Unfortunately, texindex is not prepared to handle braces in the
4629 % content at all. So for index sorting, we map @{ and @} to strings
4630 % starting with |, since that ASCII character is between ASCII { and }.
4631 \def\{{|a}%
4632 \def\lbracechar{|a}%
4633 %
4634 \def\}{|b}%
4635 \def\rbracechar{|b}%
4636 %
4637 % Non-English letters.
4638 \def\AA{AA}%
4639 \def\AE{AE}%
4640 \def\DH{DZZ}%
4641 \def\L{L}%
4642 \def\OE{OE}%
4643 \def\O{O}%
4644 \def\TH{ZZZ}%
4645 \def\aa{aa}%
4646 \def\ae{ae}%
4647 \def\dh{dzz}%
4648 \def\exclamdown{!}%
4649 \def\l{l}%
4650 \def\oe{oe}%
4651 \def\ordf{a}%
4652 \def\ordm{o}%
4653 \def\o{o}%
4654 \def\questiondown{?}%
4655 \def\ss{ss}%
4656 \def\th{zzz}%
4657 %
4658 \def\LaTeX{LaTeX}%
4659 \def\TeX{TeX}%
4660 %
4661 % Assorted special characters.
4662 % (The following {} will end up in the sort string, but that's ok.)
4663 \def\arrow{->}%
4664 \def\bullet{bullet}%
4665 \def\comma{,}%
4666 \def\copyright{copyright}%
4667 \def\dots{...}%
4668 \def\enddots{...}%
4669 \def\equiv{==}%
4670 \def\error{error}%
4671 \def\euro{euro}%
4672 \def\expansion{==>}%
4673 \def\geq{>=}%
4674 \def\guillemetleft{<<}%
4675 \def\guillemetright{>>}%
4676 \def\guilsinglleft{<}%
4677 \def\guilsinglright{>}%
4678 \def\leq{<=}%
4679 \def\minus{-}%
4680 \def\point{.}%
4681 \def\pounds{pounds}%
4682 \def\print{-|}%
4683 \def\quotedblbase{"}%
4684 \def\quotedblleft{"}%
4685 \def\quotedblright{"}%
4686 \def\quoteleft{`}%
4687 \def\quoteright{'}%
4688 \def\quotesinglbase{,}%
4689 \def\registeredsymbol{R}%
4690 \def\result{=>}%
4691 \def\textdegree{o}%
4692 %
4693 \expandafter\ifx\csname SETtxiindexlquoteignore\endcsname\relax
4694 \else \indexlquoteignore \fi
4695 %
4696 % We need to get rid of all macros, leaving only the arguments (if present).
4697 % Of course this is not nearly correct, but it is the best we can do for now.
4698 % makeinfo does not expand macros in the argument to @deffn, which ends up
4699 % writing an index entry, and texindex isn't prepared for an index sort entry
4700 % that starts with \.
4701 %
4702 % Since macro invocations are followed by braces, we can just redefine them
4703 % to take a single TeX argument. The case of a macro invocation that
4704 % goes to end-of-line is not handled.
4705 %
4706 \macrolist
4707 }
4708
4709 % Undocumented (for FSFS 2nd ed.): @set txiindexlquoteignore makes us
4710 % ignore left quotes in the sort term.
4711 {\catcode`\`=\active
4712 \gdef\indexlquoteignore{\let`=\empty}}
4713
4714 \let\indexbackslash=0 %overridden during \printindex.
4715 \let\SETmarginindex=\relax % put index entries in margin (undocumented)?
4716
4717 % Most index entries go through here, but \dosubind is the general case.
4718 % #1 is the index name, #2 is the entry text.
4719 \def\doind#1#2{\dosubind{#1}{#2}{}}
4720
4721 % Workhorse for all \fooindexes.
4722 % #1 is name of index, #2 is stuff to put there, #3 is subentry --
4723 % empty if called from \doind, as we usually are (the main exception
4724 % is with most defuns, which call us directly).
4725 %
4726 \def\dosubind#1#2#3{%
4727 \iflinks
4728 {%
4729 % Store the main index entry text (including the third arg).
4730 \toks0 = {#2}%
4731 % If third arg is present, precede it with a space.
4732 \def\thirdarg{#3}%
4733 \ifx\thirdarg\empty \else
4734 \toks0 = \expandafter{\the\toks0 \space #3}%
4735 \fi
4736 %
4737 \edef\writeto{\csname#1indfile\endcsname}%
4738 %
4739 \safewhatsit\dosubindwrite
4740 }%
4741 \fi
4742 }
4743
4744 % Write the entry in \toks0 to the index file:
4745 %
4746 \def\dosubindwrite{%
4747 % Put the index entry in the margin if desired.
4748 \ifx\SETmarginindex\relax\else
4749 \insert\margin{\hbox{\vrule height8pt depth3pt width0pt \the\toks0}}%
4750 \fi
4751 %
4752 % Remember, we are within a group.
4753 \indexdummies % Must do this here, since \bf, etc expand at this stage
4754 \def\backslashcurfont{\indexbackslash}% \indexbackslash isn't defined now
4755 % so it will be output as is; and it will print as backslash.
4756 %
4757 % Process the index entry with all font commands turned off, to
4758 % get the string to sort by.
4759 {\indexnofonts
4760 \edef\temp{\the\toks0}% need full expansion
4761 \xdef\indexsorttmp{\temp}%
4762 }%
4763 %
4764 % Set up the complete index entry, with both the sort key and
4765 % the original text, including any font commands. We write
4766 % three arguments to \entry to the .?? file (four in the
4767 % subentry case), texindex reduces to two when writing the .??s
4768 % sorted result.
4769 \edef\temp{%
4770 \write\writeto{%
4771 \string\entry{\indexsorttmp}{\noexpand\folio}{\the\toks0}}%
4772 }%
4773 \temp
4774 }
4775
4776 % Take care of unwanted page breaks/skips around a whatsit:
4777 %
4778 % If a skip is the last thing on the list now, preserve it
4779 % by backing up by \lastskip, doing the \write, then inserting
4780 % the skip again. Otherwise, the whatsit generated by the
4781 % \write or \pdfdest will make \lastskip zero. The result is that
4782 % sequences like this:
4783 % @end defun
4784 % @tindex whatever
4785 % @defun ...
4786 % will have extra space inserted, because the \medbreak in the
4787 % start of the @defun won't see the skip inserted by the @end of
4788 % the previous defun.
4789 %
4790 % But don't do any of this if we're not in vertical mode. We
4791 % don't want to do a \vskip and prematurely end a paragraph.
4792 %
4793 % Avoid page breaks due to these extra skips, too.
4794 %
4795 % But wait, there is a catch there:
4796 % We'll have to check whether \lastskip is zero skip. \ifdim is not
4797 % sufficient for this purpose, as it ignores stretch and shrink parts
4798 % of the skip. The only way seems to be to check the textual
4799 % representation of the skip.
4800 %
4801 % The following is almost like \def\zeroskipmacro{0.0pt} except that
4802 % the ``p'' and ``t'' characters have catcode \other, not 11 (letter).
4803 %
4804 \edef\zeroskipmacro{\expandafter\the\csname z@skip\endcsname}
4805 %
4806 \newskip\whatsitskip
4807 \newcount\whatsitpenalty
4808 %
4809 % ..., ready, GO:
4810 %
4811 \def\safewhatsit#1{\ifhmode
4812 #1%
4813 \else
4814 % \lastskip and \lastpenalty cannot both be nonzero simultaneously.
4815 \whatsitskip = \lastskip
4816 \edef\lastskipmacro{\the\lastskip}%
4817 \whatsitpenalty = \lastpenalty
4818 %
4819 % If \lastskip is nonzero, that means the last item was a
4820 % skip. And since a skip is discardable, that means this
4821 % -\whatsitskip glue we're inserting is preceded by a
4822 % non-discardable item, therefore it is not a potential
4823 % breakpoint, therefore no \nobreak needed.
4824 \ifx\lastskipmacro\zeroskipmacro
4825 \else
4826 \vskip-\whatsitskip
4827 \fi
4828 %
4829 #1%
4830 %
4831 \ifx\lastskipmacro\zeroskipmacro
4832 % If \lastskip was zero, perhaps the last item was a penalty, and
4833 % perhaps it was >=10000, e.g., a \nobreak. In that case, we want
4834 % to re-insert the same penalty (values >10000 are used for various
4835 % signals); since we just inserted a non-discardable item, any
4836 % following glue (such as a \parskip) would be a breakpoint. For example:
4837 % @deffn deffn-whatever
4838 % @vindex index-whatever
4839 % Description.
4840 % would allow a break between the index-whatever whatsit
4841 % and the "Description." paragraph.
4842 \ifnum\whatsitpenalty>9999 \penalty\whatsitpenalty \fi
4843 \else
4844 % On the other hand, if we had a nonzero \lastskip,
4845 % this make-up glue would be preceded by a non-discardable item
4846 % (the whatsit from the \write), so we must insert a \nobreak.
4847 \nobreak\vskip\whatsitskip
4848 \fi
4849 \fi}
4850
4851 % The index entry written in the file actually looks like
4852 % \entry {sortstring}{page}{topic}
4853 % or
4854 % \entry {sortstring}{page}{topic}{subtopic}
4855 % The texindex program reads in these files and writes files
4856 % containing these kinds of lines:
4857 % \initial {c}
4858 % before the first topic whose initial is c
4859 % \entry {topic}{pagelist}
4860 % for a topic that is used without subtopics
4861 % \primary {topic}
4862 % for the beginning of a topic that is used with subtopics
4863 % \secondary {subtopic}{pagelist}
4864 % for each subtopic.
4865
4866 % Define the user-accessible indexing commands
4867 % @findex, @vindex, @kindex, @cindex.
4868
4869 \def\findex {\fnindex}
4870 \def\kindex {\kyindex}
4871 \def\cindex {\cpindex}
4872 \def\vindex {\vrindex}
4873 \def\tindex {\tpindex}
4874 \def\pindex {\pgindex}
4875
4876 \def\cindexsub {\begingroup\obeylines\cindexsub}
4877 {\obeylines %
4878 \gdef\cindexsub "#1" #2^^M{\endgroup %
4879 \dosubind{cp}{#2}{#1}}}
4880
4881 % Define the macros used in formatting output of the sorted index material.
4882
4883 % @printindex causes a particular index (the ??s file) to get printed.
4884 % It does not print any chapter heading (usually an @unnumbered).
4885 %
4886 \parseargdef\printindex{\begingroup
4887 \dobreak \chapheadingskip{10000}%
4888 %
4889 \smallfonts \rm
4890 \tolerance = 9500
4891 \plainfrenchspacing
4892 \everypar = {}% don't want the \kern\-parindent from indentation suppression.
4893 %
4894 % See if the index file exists and is nonempty.
4895 % Change catcode of @ here so that if the index file contains
4896 % \initial {@}
4897 % as its first line, TeX doesn't complain about mismatched braces
4898 % (because it thinks @} is a control sequence).
4899 \catcode`\@ = 11
4900 \openin 1 \jobname.#1s
4901 \ifeof 1
4902 % \enddoublecolumns gets confused if there is no text in the index,
4903 % and it loses the chapter title and the aux file entries for the
4904 % index. The easiest way to prevent this problem is to make sure
4905 % there is some text.
4906 \putwordIndexNonexistent
4907 \else
4908 %
4909 % If the index file exists but is empty, then \openin leaves \ifeof
4910 % false. We have to make TeX try to read something from the file, so
4911 % it can discover if there is anything in it.
4912 \read 1 to \temp
4913 \ifeof 1
4914 \putwordIndexIsEmpty
4915 \else
4916 % Index files are almost Texinfo source, but we use \ as the escape
4917 % character. It would be better to use @, but that's too big a change
4918 % to make right now.
4919 \def\indexbackslash{\backslashcurfont}%
4920 \catcode`\\ = 0
4921 \escapechar = `\\
4922 \begindoublecolumns
4923 \input \jobname.#1s
4924 \enddoublecolumns
4925 \fi
4926 \fi
4927 \closein 1
4928 \endgroup}
4929
4930 % These macros are used by the sorted index file itself.
4931 % Change them to control the appearance of the index.
4932
4933 \def\initial#1{{%
4934 % Some minor font changes for the special characters.
4935 \let\tentt=\sectt \let\tt=\sectt \let\sf=\sectt
4936 %
4937 % Remove any glue we may have, we'll be inserting our own.
4938 \removelastskip
4939 %
4940 % We like breaks before the index initials, so insert a bonus.
4941 \nobreak
4942 \vskip 0pt plus 3\baselineskip
4943 \penalty 0
4944 \vskip 0pt plus -3\baselineskip
4945 %
4946 % Typeset the initial. Making this add up to a whole number of
4947 % baselineskips increases the chance of the dots lining up from column
4948 % to column. It still won't often be perfect, because of the stretch
4949 % we need before each entry, but it's better.
4950 %
4951 % No shrink because it confuses \balancecolumns.
4952 \vskip 1.67\baselineskip plus .5\baselineskip
4953 \leftline{\secbf #1}%
4954 % Do our best not to break after the initial.
4955 \nobreak
4956 \vskip .33\baselineskip plus .1\baselineskip
4957 }}
4958
4959 % \entry typesets a paragraph consisting of the text (#1), dot leaders, and
4960 % then page number (#2) flushed to the right margin. It is used for index
4961 % and table of contents entries. The paragraph is indented by \leftskip.
4962 %
4963 % A straightforward implementation would start like this:
4964 % \def\entry#1#2{...
4965 % But this freezes the catcodes in the argument, and can cause problems to
4966 % @code, which sets - active. This problem was fixed by a kludge---
4967 % ``-'' was active throughout whole index, but this isn't really right.
4968 % The right solution is to prevent \entry from swallowing the whole text.
4969 % --kasal, 21nov03
4970 \def\entry{%
4971 \begingroup
4972 %
4973 % Start a new paragraph if necessary, so our assignments below can't
4974 % affect previous text.
4975 \par
4976 %
4977 % Do not fill out the last line with white space.
4978 \parfillskip = 0in
4979 %
4980 % No extra space above this paragraph.
4981 \parskip = 0in
4982 %
4983 % Do not prefer a separate line ending with a hyphen to fewer lines.
4984 \finalhyphendemerits = 0
4985 %
4986 % \hangindent is only relevant when the entry text and page number
4987 % don't both fit on one line. In that case, bob suggests starting the
4988 % dots pretty far over on the line. Unfortunately, a large
4989 % indentation looks wrong when the entry text itself is broken across
4990 % lines. So we use a small indentation and put up with long leaders.
4991 %
4992 % \hangafter is reset to 1 (which is the value we want) at the start
4993 % of each paragraph, so we need not do anything with that.
4994 \hangindent = 2em
4995 %
4996 % When the entry text needs to be broken, just fill out the first line
4997 % with blank space.
4998 \rightskip = 0pt plus1fil
4999 %
5000 % A bit of stretch before each entry for the benefit of balancing
5001 % columns.
5002 \vskip 0pt plus1pt
5003 %
5004 % When reading the text of entry, convert explicit line breaks
5005 % from @* into spaces. The user might give these in long section
5006 % titles, for instance.
5007 \def\*{\unskip\space\ignorespaces}%
5008 \def\entrybreak{\hfil\break}%
5009 %
5010 % Swallow the left brace of the text (first parameter):
5011 \afterassignment\doentry
5012 \let\temp =
5013 }
5014 \def\entrybreak{\unskip\space\ignorespaces}%
5015 \def\doentry{%
5016 \bgroup % Instead of the swallowed brace.
5017 \noindent
5018 \aftergroup\finishentry
5019 % And now comes the text of the entry.
5020 }
5021 \def\finishentry#1{%
5022 % #1 is the page number.
5023 %
5024 % The following is kludged to not output a line of dots in the index if
5025 % there are no page numbers. The next person who breaks this will be
5026 % cursed by a Unix daemon.
5027 \setbox\boxA = \hbox{#1}%
5028 \ifdim\wd\boxA = 0pt
5029 \ %
5030 \else
5031 %
5032 % If we must, put the page number on a line of its own, and fill out
5033 % this line with blank space. (The \hfil is overwhelmed with the
5034 % fill leaders glue in \indexdotfill if the page number does fit.)
5035 \hfil\penalty50
5036 \null\nobreak\indexdotfill % Have leaders before the page number.
5037 %
5038 % The `\ ' here is removed by the implicit \unskip that TeX does as
5039 % part of (the primitive) \par. Without it, a spurious underfull
5040 % \hbox ensues.
5041 \ifpdf
5042 \pdfgettoks#1.%
5043 \ \the\toksA
5044 \else
5045 \ #1%
5046 \fi
5047 \fi
5048 \par
5049 \endgroup
5050 }
5051
5052 % Like plain.tex's \dotfill, except uses up at least 1 em.
5053 \def\indexdotfill{\cleaders
5054 \hbox{$\mathsurround=0pt \mkern1.5mu.\mkern1.5mu$}\hskip 1em plus 1fill}
5055
5056 \def\primary #1{\line{#1\hfil}}
5057
5058 \newskip\secondaryindent \secondaryindent=0.5cm
5059 \def\secondary#1#2{{%
5060 \parfillskip=0in
5061 \parskip=0in
5062 \hangindent=1in
5063 \hangafter=1
5064 \noindent\hskip\secondaryindent\hbox{#1}\indexdotfill
5065 \ifpdf
5066 \pdfgettoks#2.\ \the\toksA % The page number ends the paragraph.
5067 \else
5068 #2
5069 \fi
5070 \par
5071 }}
5072
5073 % Define two-column mode, which we use to typeset indexes.
5074 % Adapted from the TeXbook, page 416, which is to say,
5075 % the manmac.tex format used to print the TeXbook itself.
5076 \catcode`\@=11
5077
5078 \newbox\partialpage
5079 \newdimen\doublecolumnhsize
5080
5081 \def\begindoublecolumns{\begingroup % ended by \enddoublecolumns
5082 % Grab any single-column material above us.
5083 \output = {%
5084 %
5085 % Here is a possibility not foreseen in manmac: if we accumulate a
5086 % whole lot of material, we might end up calling this \output
5087 % routine twice in a row (see the doublecol-lose test, which is
5088 % essentially a couple of indexes with @setchapternewpage off). In
5089 % that case we just ship out what is in \partialpage with the normal
5090 % output routine. Generally, \partialpage will be empty when this
5091 % runs and this will be a no-op. See the indexspread.tex test case.
5092 \ifvoid\partialpage \else
5093 \onepageout{\pagecontents\partialpage}%
5094 \fi
5095 %
5096 \global\setbox\partialpage = \vbox{%
5097 % Unvbox the main output page.
5098 \unvbox\PAGE
5099 \kern-\topskip \kern\baselineskip
5100 }%
5101 }%
5102 \eject % run that output routine to set \partialpage
5103 %
5104 % Use the double-column output routine for subsequent pages.
5105 \output = {\doublecolumnout}%
5106 %
5107 % Change the page size parameters. We could do this once outside this
5108 % routine, in each of @smallbook, @afourpaper, and the default 8.5x11
5109 % format, but then we repeat the same computation. Repeating a couple
5110 % of assignments once per index is clearly meaningless for the
5111 % execution time, so we may as well do it in one place.
5112 %
5113 % First we halve the line length, less a little for the gutter between
5114 % the columns. We compute the gutter based on the line length, so it
5115 % changes automatically with the paper format. The magic constant
5116 % below is chosen so that the gutter has the same value (well, +-<1pt)
5117 % as it did when we hard-coded it.
5118 %
5119 % We put the result in a separate register, \doublecolumhsize, so we
5120 % can restore it in \pagesofar, after \hsize itself has (potentially)
5121 % been clobbered.
5122 %
5123 \doublecolumnhsize = \hsize
5124 \advance\doublecolumnhsize by -.04154\hsize
5125 \divide\doublecolumnhsize by 2
5126 \hsize = \doublecolumnhsize
5127 %
5128 % Double the \vsize as well. (We don't need a separate register here,
5129 % since nobody clobbers \vsize.)
5130 \vsize = 2\vsize
5131 }
5132
5133 % The double-column output routine for all double-column pages except
5134 % the last.
5135 %
5136 \def\doublecolumnout{%
5137 \splittopskip=\topskip \splitmaxdepth=\maxdepth
5138 % Get the available space for the double columns -- the normal
5139 % (undoubled) page height minus any material left over from the
5140 % previous page.
5141 \dimen@ = \vsize
5142 \divide\dimen@ by 2
5143 \advance\dimen@ by -\ht\partialpage
5144 %
5145 % box0 will be the left-hand column, box2 the right.
5146 \setbox0=\vsplit255 to\dimen@ \setbox2=\vsplit255 to\dimen@
5147 \onepageout\pagesofar
5148 \unvbox255
5149 \penalty\outputpenalty
5150 }
5151 %
5152 % Re-output the contents of the output page -- any previous material,
5153 % followed by the two boxes we just split, in box0 and box2.
5154 \def\pagesofar{%
5155 \unvbox\partialpage
5156 %
5157 \hsize = \doublecolumnhsize
5158 \wd0=\hsize \wd2=\hsize
5159 \hbox to\pagewidth{\box0\hfil\box2}%
5160 }
5161 %
5162 % All done with double columns.
5163 \def\enddoublecolumns{%
5164 % The following penalty ensures that the page builder is exercised
5165 % _before_ we change the output routine. This is necessary in the
5166 % following situation:
5167 %
5168 % The last section of the index consists only of a single entry.
5169 % Before this section, \pagetotal is less than \pagegoal, so no
5170 % break occurs before the last section starts. However, the last
5171 % section, consisting of \initial and the single \entry, does not
5172 % fit on the page and has to be broken off. Without the following
5173 % penalty the page builder will not be exercised until \eject
5174 % below, and by that time we'll already have changed the output
5175 % routine to the \balancecolumns version, so the next-to-last
5176 % double-column page will be processed with \balancecolumns, which
5177 % is wrong: The two columns will go to the main vertical list, with
5178 % the broken-off section in the recent contributions. As soon as
5179 % the output routine finishes, TeX starts reconsidering the page
5180 % break. The two columns and the broken-off section both fit on the
5181 % page, because the two columns now take up only half of the page
5182 % goal. When TeX sees \eject from below which follows the final
5183 % section, it invokes the new output routine that we've set after
5184 % \balancecolumns below; \onepageout will try to fit the two columns
5185 % and the final section into the vbox of \pageheight (see
5186 % \pagebody), causing an overfull box.
5187 %
5188 % Note that glue won't work here, because glue does not exercise the
5189 % page builder, unlike penalties (see The TeXbook, pp. 280-281).
5190 \penalty0
5191 %
5192 \output = {%
5193 % Split the last of the double-column material. Leave it on the
5194 % current page, no automatic page break.
5195 \balancecolumns
5196 %
5197 % If we end up splitting too much material for the current page,
5198 % though, there will be another page break right after this \output
5199 % invocation ends. Having called \balancecolumns once, we do not
5200 % want to call it again. Therefore, reset \output to its normal
5201 % definition right away. (We hope \balancecolumns will never be
5202 % called on to balance too much material, but if it is, this makes
5203 % the output somewhat more palatable.)
5204 \global\output = {\onepageout{\pagecontents\PAGE}}%
5205 }%
5206 \eject
5207 \endgroup % started in \begindoublecolumns
5208 %
5209 % \pagegoal was set to the doubled \vsize above, since we restarted
5210 % the current page. We're now back to normal single-column
5211 % typesetting, so reset \pagegoal to the normal \vsize (after the
5212 % \endgroup where \vsize got restored).
5213 \pagegoal = \vsize
5214 }
5215 %
5216 % Called at the end of the double column material.
5217 \def\balancecolumns{%
5218 \setbox0 = \vbox{\unvbox255}% like \box255 but more efficient, see p.120.
5219 \dimen@ = \ht0
5220 \advance\dimen@ by \topskip
5221 \advance\dimen@ by-\baselineskip
5222 \divide\dimen@ by 2 % target to split to
5223 %debug\message{final 2-column material height=\the\ht0, target=\the\dimen@.}%
5224 \splittopskip = \topskip
5225 % Loop until we get a decent breakpoint.
5226 {%
5227 \vbadness = 10000
5228 \loop
5229 \global\setbox3 = \copy0
5230 \global\setbox1 = \vsplit3 to \dimen@
5231 \ifdim\ht3>\dimen@
5232 \global\advance\dimen@ by 1pt
5233 \repeat
5234 }%
5235 %debug\message{split to \the\dimen@, column heights: \the\ht1, \the\ht3.}%
5236 \setbox0=\vbox to\dimen@{\unvbox1}%
5237 \setbox2=\vbox to\dimen@{\unvbox3}%
5238 %
5239 \pagesofar
5240 }
5241 \catcode`\@ = \other
5242
5243
5244 \message{sectioning,}
5245 % Chapters, sections, etc.
5246
5247 % Let's start with @part.
5248 \outer\parseargdef\part{\partzzz{#1}}
5249 \def\partzzz#1{%
5250 \chapoddpage
5251 \null
5252 \vskip.3\vsize % move it down on the page a bit
5253 \begingroup
5254 \noindent \titlefonts\rmisbold #1\par % the text
5255 \let\lastnode=\empty % no node to associate with
5256 \writetocentry{part}{#1}{}% but put it in the toc
5257 \headingsoff % no headline or footline on the part page
5258 \chapoddpage
5259 \endgroup
5260 }
5261
5262 % \unnumberedno is an oxymoron. But we count the unnumbered
5263 % sections so that we can refer to them unambiguously in the pdf
5264 % outlines by their "section number". We avoid collisions with chapter
5265 % numbers by starting them at 10000. (If a document ever has 10000
5266 % chapters, we're in trouble anyway, I'm sure.)
5267 \newcount\unnumberedno \unnumberedno = 10000
5268 \newcount\chapno
5269 \newcount\secno \secno=0
5270 \newcount\subsecno \subsecno=0
5271 \newcount\subsubsecno \subsubsecno=0
5272
5273 % This counter is funny since it counts through charcodes of letters A, B, ...
5274 \newcount\appendixno \appendixno = `\@
5275 %
5276 % \def\appendixletter{\char\the\appendixno}
5277 % We do the following ugly conditional instead of the above simple
5278 % construct for the sake of pdftex, which needs the actual
5279 % letter in the expansion, not just typeset.
5280 %
5281 \def\appendixletter{%
5282 \ifnum\appendixno=`A A%
5283 \else\ifnum\appendixno=`B B%
5284 \else\ifnum\appendixno=`C C%
5285 \else\ifnum\appendixno=`D D%
5286 \else\ifnum\appendixno=`E E%
5287 \else\ifnum\appendixno=`F F%
5288 \else\ifnum\appendixno=`G G%
5289 \else\ifnum\appendixno=`H H%
5290 \else\ifnum\appendixno=`I I%
5291 \else\ifnum\appendixno=`J J%
5292 \else\ifnum\appendixno=`K K%
5293 \else\ifnum\appendixno=`L L%
5294 \else\ifnum\appendixno=`M M%
5295 \else\ifnum\appendixno=`N N%
5296 \else\ifnum\appendixno=`O O%
5297 \else\ifnum\appendixno=`P P%
5298 \else\ifnum\appendixno=`Q Q%
5299 \else\ifnum\appendixno=`R R%
5300 \else\ifnum\appendixno=`S S%
5301 \else\ifnum\appendixno=`T T%
5302 \else\ifnum\appendixno=`U U%
5303 \else\ifnum\appendixno=`V V%
5304 \else\ifnum\appendixno=`W W%
5305 \else\ifnum\appendixno=`X X%
5306 \else\ifnum\appendixno=`Y Y%
5307 \else\ifnum\appendixno=`Z Z%
5308 % The \the is necessary, despite appearances, because \appendixletter is
5309 % expanded while writing the .toc file. \char\appendixno is not
5310 % expandable, thus it is written literally, thus all appendixes come out
5311 % with the same letter (or @) in the toc without it.
5312 \else\char\the\appendixno
5313 \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
5314 \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi}
5315
5316 % Each @chapter defines these (using marks) as the number+name, number
5317 % and name of the chapter. Page headings and footings can use
5318 % these. @section does likewise.
5319 \def\thischapter{}
5320 \def\thischapternum{}
5321 \def\thischaptername{}
5322 \def\thissection{}
5323 \def\thissectionnum{}
5324 \def\thissectionname{}
5325
5326 \newcount\absseclevel % used to calculate proper heading level
5327 \newcount\secbase\secbase=0 % @raisesections/@lowersections modify this count
5328
5329 % @raisesections: treat @section as chapter, @subsection as section, etc.
5330 \def\raisesections{\global\advance\secbase by -1}
5331 \let\up=\raisesections % original BFox name
5332
5333 % @lowersections: treat @chapter as section, @section as subsection, etc.
5334 \def\lowersections{\global\advance\secbase by 1}
5335 \let\down=\lowersections % original BFox name
5336
5337 % we only have subsub.
5338 \chardef\maxseclevel = 3
5339 %
5340 % A numbered section within an unnumbered changes to unnumbered too.
5341 % To achieve this, remember the "biggest" unnum. sec. we are currently in:
5342 \chardef\unnlevel = \maxseclevel
5343 %
5344 % Trace whether the current chapter is an appendix or not:
5345 % \chapheadtype is "N" or "A", unnumbered chapters are ignored.
5346 \def\chapheadtype{N}
5347
5348 % Choose a heading macro
5349 % #1 is heading type
5350 % #2 is heading level
5351 % #3 is text for heading
5352 \def\genhead#1#2#3{%
5353 % Compute the abs. sec. level:
5354 \absseclevel=#2
5355 \advance\absseclevel by \secbase
5356 % Make sure \absseclevel doesn't fall outside the range:
5357 \ifnum \absseclevel < 0
5358 \absseclevel = 0
5359 \else
5360 \ifnum \absseclevel > 3
5361 \absseclevel = 3
5362 \fi
5363 \fi
5364 % The heading type:
5365 \def\headtype{#1}%
5366 \if \headtype U%
5367 \ifnum \absseclevel < \unnlevel
5368 \chardef\unnlevel = \absseclevel
5369 \fi
5370 \else
5371 % Check for appendix sections:
5372 \ifnum \absseclevel = 0
5373 \edef\chapheadtype{\headtype}%
5374 \else
5375 \if \headtype A\if \chapheadtype N%
5376 \errmessage{@appendix... within a non-appendix chapter}%
5377 \fi\fi
5378 \fi
5379 % Check for numbered within unnumbered:
5380 \ifnum \absseclevel > \unnlevel
5381 \def\headtype{U}%
5382 \else
5383 \chardef\unnlevel = 3
5384 \fi
5385 \fi
5386 % Now print the heading:
5387 \if \headtype U%
5388 \ifcase\absseclevel
5389 \unnumberedzzz{#3}%
5390 \or \unnumberedseczzz{#3}%
5391 \or \unnumberedsubseczzz{#3}%
5392 \or \unnumberedsubsubseczzz{#3}%
5393 \fi
5394 \else
5395 \if \headtype A%
5396 \ifcase\absseclevel
5397 \appendixzzz{#3}%
5398 \or \appendixsectionzzz{#3}%
5399 \or \appendixsubseczzz{#3}%
5400 \or \appendixsubsubseczzz{#3}%
5401 \fi
5402 \else
5403 \ifcase\absseclevel
5404 \chapterzzz{#3}%
5405 \or \seczzz{#3}%
5406 \or \numberedsubseczzz{#3}%
5407 \or \numberedsubsubseczzz{#3}%
5408 \fi
5409 \fi
5410 \fi
5411 \suppressfirstparagraphindent
5412 }
5413
5414 % an interface:
5415 \def\numhead{\genhead N}
5416 \def\apphead{\genhead A}
5417 \def\unnmhead{\genhead U}
5418
5419 % @chapter, @appendix, @unnumbered. Increment top-level counter, reset
5420 % all lower-level sectioning counters to zero.
5421 %
5422 % Also set \chaplevelprefix, which we prepend to @float sequence numbers
5423 % (e.g., figures), q.v. By default (before any chapter), that is empty.
5424 \let\chaplevelprefix = \empty
5425 %
5426 \outer\parseargdef\chapter{\numhead0{#1}} % normally numhead0 calls chapterzzz
5427 \def\chapterzzz#1{%
5428 % section resetting is \global in case the chapter is in a group, such
5429 % as an @include file.
5430 \global\secno=0 \global\subsecno=0 \global\subsubsecno=0
5431 \global\advance\chapno by 1
5432 %
5433 % Used for \float.
5434 \gdef\chaplevelprefix{\the\chapno.}%
5435 \resetallfloatnos
5436 %
5437 % \putwordChapter can contain complex things in translations.
5438 \toks0=\expandafter{\putwordChapter}%
5439 \message{\the\toks0 \space \the\chapno}%
5440 %
5441 % Write the actual heading.
5442 \chapmacro{#1}{Ynumbered}{\the\chapno}%
5443 %
5444 % So @section and the like are numbered underneath this chapter.
5445 \global\let\section = \numberedsec
5446 \global\let\subsection = \numberedsubsec
5447 \global\let\subsubsection = \numberedsubsubsec
5448 }
5449
5450 \outer\parseargdef\appendix{\apphead0{#1}} % normally calls appendixzzz
5451 %
5452 \def\appendixzzz#1{%
5453 \global\secno=0 \global\subsecno=0 \global\subsubsecno=0
5454 \global\advance\appendixno by 1
5455 \gdef\chaplevelprefix{\appendixletter.}%
5456 \resetallfloatnos
5457 %
5458 % \putwordAppendix can contain complex things in translations.
5459 \toks0=\expandafter{\putwordAppendix}%
5460 \message{\the\toks0 \space \appendixletter}%
5461 %
5462 \chapmacro{#1}{Yappendix}{\appendixletter}%
5463 %
5464 \global\let\section = \appendixsec
5465 \global\let\subsection = \appendixsubsec
5466 \global\let\subsubsection = \appendixsubsubsec
5467 }
5468
5469 % normally unnmhead0 calls unnumberedzzz:
5470 \outer\parseargdef\unnumbered{\unnmhead0{#1}}
5471 \def\unnumberedzzz#1{%
5472 \global\secno=0 \global\subsecno=0 \global\subsubsecno=0
5473 \global\advance\unnumberedno by 1
5474 %
5475 % Since an unnumbered has no number, no prefix for figures.
5476 \global\let\chaplevelprefix = \empty
5477 \resetallfloatnos
5478 %
5479 % This used to be simply \message{#1}, but TeX fully expands the
5480 % argument to \message. Therefore, if #1 contained @-commands, TeX
5481 % expanded them. For example, in `@unnumbered The @cite{Book}', TeX
5482 % expanded @cite (which turns out to cause errors because \cite is meant
5483 % to be executed, not expanded).
5484 %
5485 % Anyway, we don't want the fully-expanded definition of @cite to appear
5486 % as a result of the \message, we just want `@cite' itself. We use
5487 % \the<toks register> to achieve this: TeX expands \the<toks> only once,
5488 % simply yielding the contents of <toks register>. (We also do this for
5489 % the toc entries.)
5490 \toks0 = {#1}%
5491 \message{(\the\toks0)}%
5492 %
5493 \chapmacro{#1}{Ynothing}{\the\unnumberedno}%
5494 %
5495 \global\let\section = \unnumberedsec
5496 \global\let\subsection = \unnumberedsubsec
5497 \global\let\subsubsection = \unnumberedsubsubsec
5498 }
5499
5500 % @centerchap is like @unnumbered, but the heading is centered.
5501 \outer\parseargdef\centerchap{%
5502 % Well, we could do the following in a group, but that would break
5503 % an assumption that \chapmacro is called at the outermost level.
5504 % Thus we are safer this way: --kasal, 24feb04
5505 \let\centerparametersmaybe = \centerparameters
5506 \unnmhead0{#1}%
5507 \let\centerparametersmaybe = \relax
5508 }
5509
5510 % @top is like @unnumbered.
5511 \let\top\unnumbered
5512
5513 % Sections.
5514 %
5515 \outer\parseargdef\numberedsec{\numhead1{#1}} % normally calls seczzz
5516 \def\seczzz#1{%
5517 \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
5518 \sectionheading{#1}{sec}{Ynumbered}{\the\chapno.\the\secno}%
5519 }
5520
5521 % normally calls appendixsectionzzz:
5522 \outer\parseargdef\appendixsection{\apphead1{#1}}
5523 \def\appendixsectionzzz#1{%
5524 \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
5525 \sectionheading{#1}{sec}{Yappendix}{\appendixletter.\the\secno}%
5526 }
5527 \let\appendixsec\appendixsection
5528
5529 % normally calls unnumberedseczzz:
5530 \outer\parseargdef\unnumberedsec{\unnmhead1{#1}}
5531 \def\unnumberedseczzz#1{%
5532 \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
5533 \sectionheading{#1}{sec}{Ynothing}{\the\unnumberedno.\the\secno}%
5534 }
5535
5536 % Subsections.
5537 %
5538 % normally calls numberedsubseczzz:
5539 \outer\parseargdef\numberedsubsec{\numhead2{#1}}
5540 \def\numberedsubseczzz#1{%
5541 \global\subsubsecno=0 \global\advance\subsecno by 1
5542 \sectionheading{#1}{subsec}{Ynumbered}{\the\chapno.\the\secno.\the\subsecno}%
5543 }
5544
5545 % normally calls appendixsubseczzz:
5546 \outer\parseargdef\appendixsubsec{\apphead2{#1}}
5547 \def\appendixsubseczzz#1{%
5548 \global\subsubsecno=0 \global\advance\subsecno by 1
5549 \sectionheading{#1}{subsec}{Yappendix}%
5550 {\appendixletter.\the\secno.\the\subsecno}%
5551 }
5552
5553 % normally calls unnumberedsubseczzz:
5554 \outer\parseargdef\unnumberedsubsec{\unnmhead2{#1}}
5555 \def\unnumberedsubseczzz#1{%
5556 \global\subsubsecno=0 \global\advance\subsecno by 1
5557 \sectionheading{#1}{subsec}{Ynothing}%
5558 {\the\unnumberedno.\the\secno.\the\subsecno}%
5559 }
5560
5561 % Subsubsections.
5562 %
5563 % normally numberedsubsubseczzz:
5564 \outer\parseargdef\numberedsubsubsec{\numhead3{#1}}
5565 \def\numberedsubsubseczzz#1{%
5566 \global\advance\subsubsecno by 1
5567 \sectionheading{#1}{subsubsec}{Ynumbered}%
5568 {\the\chapno.\the\secno.\the\subsecno.\the\subsubsecno}%
5569 }
5570
5571 % normally appendixsubsubseczzz:
5572 \outer\parseargdef\appendixsubsubsec{\apphead3{#1}}
5573 \def\appendixsubsubseczzz#1{%
5574 \global\advance\subsubsecno by 1
5575 \sectionheading{#1}{subsubsec}{Yappendix}%
5576 {\appendixletter.\the\secno.\the\subsecno.\the\subsubsecno}%
5577 }
5578
5579 % normally unnumberedsubsubseczzz:
5580 \outer\parseargdef\unnumberedsubsubsec{\unnmhead3{#1}}
5581 \def\unnumberedsubsubseczzz#1{%
5582 \global\advance\subsubsecno by 1
5583 \sectionheading{#1}{subsubsec}{Ynothing}%
5584 {\the\unnumberedno.\the\secno.\the\subsecno.\the\subsubsecno}%
5585 }
5586
5587 % These macros control what the section commands do, according
5588 % to what kind of chapter we are in (ordinary, appendix, or unnumbered).
5589 % Define them by default for a numbered chapter.
5590 \let\section = \numberedsec
5591 \let\subsection = \numberedsubsec
5592 \let\subsubsection = \numberedsubsubsec
5593
5594 % Define @majorheading, @heading and @subheading
5595
5596 \def\majorheading{%
5597 {\advance\chapheadingskip by 10pt \chapbreak }%
5598 \parsearg\chapheadingzzz
5599 }
5600
5601 \def\chapheading{\chapbreak \parsearg\chapheadingzzz}
5602 \def\chapheadingzzz#1{%
5603 \vbox{\chapfonts \raggedtitlesettings #1\par}%
5604 \nobreak\bigskip \nobreak
5605 \suppressfirstparagraphindent
5606 }
5607
5608 % @heading, @subheading, @subsubheading.
5609 \parseargdef\heading{\sectionheading{#1}{sec}{Yomitfromtoc}{}
5610 \suppressfirstparagraphindent}
5611 \parseargdef\subheading{\sectionheading{#1}{subsec}{Yomitfromtoc}{}
5612 \suppressfirstparagraphindent}
5613 \parseargdef\subsubheading{\sectionheading{#1}{subsubsec}{Yomitfromtoc}{}
5614 \suppressfirstparagraphindent}
5615
5616 % These macros generate a chapter, section, etc. heading only
5617 % (including whitespace, linebreaking, etc. around it),
5618 % given all the information in convenient, parsed form.
5619
5620 % Args are the skip and penalty (usually negative)
5621 \def\dobreak#1#2{\par\ifdim\lastskip<#1\removelastskip\penalty#2\vskip#1\fi}
5622
5623 % Parameter controlling skip before chapter headings (if needed)
5624 \newskip\chapheadingskip
5625
5626 % Define plain chapter starts, and page on/off switching for it.
5627 \def\chapbreak{\dobreak \chapheadingskip {-4000}}
5628 \def\chappager{\par\vfill\supereject}
5629 % Because \domark is called before \chapoddpage, the filler page will
5630 % get the headings for the next chapter, which is wrong. But we don't
5631 % care -- we just disable all headings on the filler page.
5632 \def\chapoddpage{%
5633 \chappager
5634 \ifodd\pageno \else
5635 \begingroup
5636 \headingsoff
5637 \null
5638 \chappager
5639 \endgroup
5640 \fi
5641 }
5642
5643 \def\setchapternewpage #1 {\csname CHAPPAG#1\endcsname}
5644
5645 \def\CHAPPAGoff{%
5646 \global\let\contentsalignmacro = \chappager
5647 \global\let\pchapsepmacro=\chapbreak
5648 \global\let\pagealignmacro=\chappager}
5649
5650 \def\CHAPPAGon{%
5651 \global\let\contentsalignmacro = \chappager
5652 \global\let\pchapsepmacro=\chappager
5653 \global\let\pagealignmacro=\chappager
5654 \global\def\HEADINGSon{\HEADINGSsingle}}
5655
5656 \def\CHAPPAGodd{%
5657 \global\let\contentsalignmacro = \chapoddpage
5658 \global\let\pchapsepmacro=\chapoddpage
5659 \global\let\pagealignmacro=\chapoddpage
5660 \global\def\HEADINGSon{\HEADINGSdouble}}
5661
5662 \CHAPPAGon
5663
5664 % Chapter opening.
5665 %
5666 % #1 is the text, #2 is the section type (Ynumbered, Ynothing,
5667 % Yappendix, Yomitfromtoc), #3 the chapter number.
5668 %
5669 % To test against our argument.
5670 \def\Ynothingkeyword{Ynothing}
5671 \def\Yomitfromtockeyword{Yomitfromtoc}
5672 \def\Yappendixkeyword{Yappendix}
5673 %
5674 \def\chapmacro#1#2#3{%
5675 % Insert the first mark before the heading break (see notes for \domark).
5676 \let\prevchapterdefs=\lastchapterdefs
5677 \let\prevsectiondefs=\lastsectiondefs
5678 \gdef\lastsectiondefs{\gdef\thissectionname{}\gdef\thissectionnum{}%
5679 \gdef\thissection{}}%
5680 %
5681 \def\temptype{#2}%
5682 \ifx\temptype\Ynothingkeyword
5683 \gdef\lastchapterdefs{\gdef\thischaptername{#1}\gdef\thischapternum{}%
5684 \gdef\thischapter{\thischaptername}}%
5685 \else\ifx\temptype\Yomitfromtockeyword
5686 \gdef\lastchapterdefs{\gdef\thischaptername{#1}\gdef\thischapternum{}%
5687 \gdef\thischapter{}}%
5688 \else\ifx\temptype\Yappendixkeyword
5689 \toks0={#1}%
5690 \xdef\lastchapterdefs{%
5691 \gdef\noexpand\thischaptername{\the\toks0}%
5692 \gdef\noexpand\thischapternum{\appendixletter}%
5693 % \noexpand\putwordAppendix avoids expanding indigestible
5694 % commands in some of the translations.
5695 \gdef\noexpand\thischapter{\noexpand\putwordAppendix{}
5696 \noexpand\thischapternum:
5697 \noexpand\thischaptername}%
5698 }%
5699 \else
5700 \toks0={#1}%
5701 \xdef\lastchapterdefs{%
5702 \gdef\noexpand\thischaptername{\the\toks0}%
5703 \gdef\noexpand\thischapternum{\the\chapno}%
5704 % \noexpand\putwordChapter avoids expanding indigestible
5705 % commands in some of the translations.
5706 \gdef\noexpand\thischapter{\noexpand\putwordChapter{}
5707 \noexpand\thischapternum:
5708 \noexpand\thischaptername}%
5709 }%
5710 \fi\fi\fi
5711 %
5712 % Output the mark. Pass it through \safewhatsit, to take care of
5713 % the preceding space.
5714 \safewhatsit\domark
5715 %
5716 % Insert the chapter heading break.
5717 \pchapsepmacro
5718 %
5719 % Now the second mark, after the heading break. No break points
5720 % between here and the heading.
5721 \let\prevchapterdefs=\lastchapterdefs
5722 \let\prevsectiondefs=\lastsectiondefs
5723 \domark
5724 %
5725 {%
5726 \chapfonts \rmisbold
5727 %
5728 % Have to define \lastsection before calling \donoderef, because the
5729 % xref code eventually uses it. On the other hand, it has to be called
5730 % after \pchapsepmacro, or the headline will change too soon.
5731 \gdef\lastsection{#1}%
5732 %
5733 % Only insert the separating space if we have a chapter/appendix
5734 % number, and don't print the unnumbered ``number''.
5735 \ifx\temptype\Ynothingkeyword
5736 \setbox0 = \hbox{}%
5737 \def\toctype{unnchap}%
5738 \else\ifx\temptype\Yomitfromtockeyword
5739 \setbox0 = \hbox{}% contents like unnumbered, but no toc entry
5740 \def\toctype{omit}%
5741 \else\ifx\temptype\Yappendixkeyword
5742 \setbox0 = \hbox{\putwordAppendix{} #3\enspace}%
5743 \def\toctype{app}%
5744 \else
5745 \setbox0 = \hbox{#3\enspace}%
5746 \def\toctype{numchap}%
5747 \fi\fi\fi
5748 %
5749 % Write the toc entry for this chapter. Must come before the
5750 % \donoderef, because we include the current node name in the toc
5751 % entry, and \donoderef resets it to empty.
5752 \writetocentry{\toctype}{#1}{#3}%
5753 %
5754 % For pdftex, we have to write out the node definition (aka, make
5755 % the pdfdest) after any page break, but before the actual text has
5756 % been typeset. If the destination for the pdf outline is after the
5757 % text, then jumping from the outline may wind up with the text not
5758 % being visible, for instance under high magnification.
5759 \donoderef{#2}%
5760 %
5761 % Typeset the actual heading.
5762 \nobreak % Avoid page breaks at the interline glue.
5763 \vbox{\raggedtitlesettings \hangindent=\wd0 \centerparametersmaybe
5764 \unhbox0 #1\par}%
5765 }%
5766 \nobreak\bigskip % no page break after a chapter title
5767 \nobreak
5768 }
5769
5770 % @centerchap -- centered and unnumbered.
5771 \let\centerparametersmaybe = \relax
5772 \def\centerparameters{%
5773 \advance\rightskip by 3\rightskip
5774 \leftskip = \rightskip
5775 \parfillskip = 0pt
5776 }
5777
5778
5779 % I don't think this chapter style is supported any more, so I'm not
5780 % updating it with the new noderef stuff. We'll see. --karl, 11aug03.
5781 %
5782 \def\setchapterstyle #1 {\csname CHAPF#1\endcsname}
5783 %
5784 \def\unnchfopen #1{%
5785 \chapoddpage
5786 \vbox{\chapfonts \raggedtitlesettings #1\par}%
5787 \nobreak\bigskip\nobreak
5788 }
5789 \def\chfopen #1#2{\chapoddpage {\chapfonts
5790 \vbox to 3in{\vfil \hbox to\hsize{\hfil #2} \hbox to\hsize{\hfil #1} \vfil}}%
5791 \par\penalty 5000 %
5792 }
5793 \def\centerchfopen #1{%
5794 \chapoddpage
5795 \vbox{\chapfonts \raggedtitlesettings \hfill #1\hfill}%
5796 \nobreak\bigskip \nobreak
5797 }
5798 \def\CHAPFopen{%
5799 \global\let\chapmacro=\chfopen
5800 \global\let\centerchapmacro=\centerchfopen}
5801
5802
5803 % Section titles. These macros combine the section number parts and
5804 % call the generic \sectionheading to do the printing.
5805 %
5806 \newskip\secheadingskip
5807 \def\secheadingbreak{\dobreak \secheadingskip{-1000}}
5808
5809 % Subsection titles.
5810 \newskip\subsecheadingskip
5811 \def\subsecheadingbreak{\dobreak \subsecheadingskip{-500}}
5812
5813 % Subsubsection titles.
5814 \def\subsubsecheadingskip{\subsecheadingskip}
5815 \def\subsubsecheadingbreak{\subsecheadingbreak}
5816
5817
5818 % Print any size, any type, section title.
5819 %
5820 % #1 is the text, #2 is the section level (sec/subsec/subsubsec), #3 is
5821 % the section type for xrefs (Ynumbered, Ynothing, Yappendix), #4 is the
5822 % section number.
5823 %
5824 \def\seckeyword{sec}
5825 %
5826 \def\sectionheading#1#2#3#4{%
5827 {%
5828 \checkenv{}% should not be in an environment.
5829 %
5830 % Switch to the right set of fonts.
5831 \csname #2fonts\endcsname \rmisbold
5832 %
5833 \def\sectionlevel{#2}%
5834 \def\temptype{#3}%
5835 %
5836 % Insert first mark before the heading break (see notes for \domark).
5837 \let\prevsectiondefs=\lastsectiondefs
5838 \ifx\temptype\Ynothingkeyword
5839 \ifx\sectionlevel\seckeyword
5840 \gdef\lastsectiondefs{\gdef\thissectionname{#1}\gdef\thissectionnum{}%
5841 \gdef\thissection{\thissectionname}}%
5842 \fi
5843 \else\ifx\temptype\Yomitfromtockeyword
5844 % Don't redefine \thissection.
5845 \else\ifx\temptype\Yappendixkeyword
5846 \ifx\sectionlevel\seckeyword
5847 \toks0={#1}%
5848 \xdef\lastsectiondefs{%
5849 \gdef\noexpand\thissectionname{\the\toks0}%
5850 \gdef\noexpand\thissectionnum{#4}%
5851 % \noexpand\putwordSection avoids expanding indigestible
5852 % commands in some of the translations.
5853 \gdef\noexpand\thissection{\noexpand\putwordSection{}
5854 \noexpand\thissectionnum:
5855 \noexpand\thissectionname}%
5856 }%
5857 \fi
5858 \else
5859 \ifx\sectionlevel\seckeyword
5860 \toks0={#1}%
5861 \xdef\lastsectiondefs{%
5862 \gdef\noexpand\thissectionname{\the\toks0}%
5863 \gdef\noexpand\thissectionnum{#4}%
5864 % \noexpand\putwordSection avoids expanding indigestible
5865 % commands in some of the translations.
5866 \gdef\noexpand\thissection{\noexpand\putwordSection{}
5867 \noexpand\thissectionnum:
5868 \noexpand\thissectionname}%
5869 }%
5870 \fi
5871 \fi\fi\fi
5872 %
5873 % Go into vertical mode. Usually we'll already be there, but we
5874 % don't want the following whatsit to end up in a preceding paragraph
5875 % if the document didn't happen to have a blank line.
5876 \par
5877 %
5878 % Output the mark. Pass it through \safewhatsit, to take care of
5879 % the preceding space.
5880 \safewhatsit\domark
5881 %
5882 % Insert space above the heading.
5883 \csname #2headingbreak\endcsname
5884 %
5885 % Now the second mark, after the heading break. No break points
5886 % between here and the heading.
5887 \let\prevsectiondefs=\lastsectiondefs
5888 \domark
5889 %
5890 % Only insert the space after the number if we have a section number.
5891 \ifx\temptype\Ynothingkeyword
5892 \setbox0 = \hbox{}%
5893 \def\toctype{unn}%
5894 \gdef\lastsection{#1}%
5895 \else\ifx\temptype\Yomitfromtockeyword
5896 % for @headings -- no section number, don't include in toc,
5897 % and don't redefine \lastsection.
5898 \setbox0 = \hbox{}%
5899 \def\toctype{omit}%
5900 \let\sectionlevel=\empty
5901 \else\ifx\temptype\Yappendixkeyword
5902 \setbox0 = \hbox{#4\enspace}%
5903 \def\toctype{app}%
5904 \gdef\lastsection{#1}%
5905 \else
5906 \setbox0 = \hbox{#4\enspace}%
5907 \def\toctype{num}%
5908 \gdef\lastsection{#1}%
5909 \fi\fi\fi
5910 %
5911 % Write the toc entry (before \donoderef). See comments in \chapmacro.
5912 \writetocentry{\toctype\sectionlevel}{#1}{#4}%
5913 %
5914 % Write the node reference (= pdf destination for pdftex).
5915 % Again, see comments in \chapmacro.
5916 \donoderef{#3}%
5917 %
5918 % Interline glue will be inserted when the vbox is completed.
5919 % That glue will be a valid breakpoint for the page, since it'll be
5920 % preceded by a whatsit (usually from the \donoderef, or from the
5921 % \writetocentry if there was no node). We don't want to allow that
5922 % break, since then the whatsits could end up on page n while the
5923 % section is on page n+1, thus toc/etc. are wrong. Debian bug 276000.
5924 \nobreak
5925 %
5926 % Output the actual section heading.
5927 \vbox{\hyphenpenalty=10000 \tolerance=5000 \parindent=0pt \ptexraggedright
5928 \hangindent=\wd0 % zero if no section number
5929 \unhbox0 #1}%
5930 }%
5931 % Add extra space after the heading -- half of whatever came above it.
5932 % Don't allow stretch, though.
5933 \kern .5 \csname #2headingskip\endcsname
5934 %
5935 % Do not let the kern be a potential breakpoint, as it would be if it
5936 % was followed by glue.
5937 \nobreak
5938 %
5939 % We'll almost certainly start a paragraph next, so don't let that
5940 % glue accumulate. (Not a breakpoint because it's preceded by a
5941 % discardable item.) However, when a paragraph is not started next
5942 % (\startdefun, \cartouche, \center, etc.), this needs to be wiped out
5943 % or the negative glue will cause weirdly wrong output, typically
5944 % obscuring the section heading with something else.
5945 \vskip-\parskip
5946 %
5947 % This is so the last item on the main vertical list is a known
5948 % \penalty > 10000, so \startdefun, etc., can recognize the situation
5949 % and do the needful.
5950 \penalty 10001
5951 }
5952
5953
5954 \message{toc,}
5955 % Table of contents.
5956 \newwrite\tocfile
5957
5958 % Write an entry to the toc file, opening it if necessary.
5959 % Called from @chapter, etc.
5960 %
5961 % Example usage: \writetocentry{sec}{Section Name}{\the\chapno.\the\secno}
5962 % We append the current node name (if any) and page number as additional
5963 % arguments for the \{chap,sec,...}entry macros which will eventually
5964 % read this. The node name is used in the pdf outlines as the
5965 % destination to jump to.
5966 %
5967 % We open the .toc file for writing here instead of at @setfilename (or
5968 % any other fixed time) so that @contents can be anywhere in the document.
5969 % But if #1 is `omit', then we don't do anything. This is used for the
5970 % table of contents chapter openings themselves.
5971 %
5972 \newif\iftocfileopened
5973 \def\omitkeyword{omit}%
5974 %
5975 \def\writetocentry#1#2#3{%
5976 \edef\writetoctype{#1}%
5977 \ifx\writetoctype\omitkeyword \else
5978 \iftocfileopened\else
5979 \immediate\openout\tocfile = \jobname.toc
5980 \global\tocfileopenedtrue
5981 \fi
5982 %
5983 \iflinks
5984 {\atdummies
5985 \edef\temp{%
5986 \write\tocfile{@#1entry{#2}{#3}{\lastnode}{\noexpand\folio}}}%
5987 \temp
5988 }%
5989 \fi
5990 \fi
5991 %
5992 % Tell \shipout to create a pdf destination on each page, if we're
5993 % writing pdf. These are used in the table of contents. We can't
5994 % just write one on every page because the title pages are numbered
5995 % 1 and 2 (the page numbers aren't printed), and so are the first
5996 % two pages of the document. Thus, we'd have two destinations named
5997 % `1', and two named `2'.
5998 \ifpdf \global\pdfmakepagedesttrue \fi
5999 }
6000
6001
6002 % These characters do not print properly in the Computer Modern roman
6003 % fonts, so we must take special care. This is more or less redundant
6004 % with the Texinfo input format setup at the end of this file.
6005 %
6006 \def\activecatcodes{%
6007 \catcode`\"=\active
6008 \catcode`\$=\active
6009 \catcode`\<=\active
6010 \catcode`\>=\active
6011 \catcode`\\=\active
6012 \catcode`\^=\active
6013 \catcode`\_=\active
6014 \catcode`\|=\active
6015 \catcode`\~=\active
6016 }
6017
6018
6019 % Read the toc file, which is essentially Texinfo input.
6020 \def\readtocfile{%
6021 \setupdatafile
6022 \activecatcodes
6023 \input \tocreadfilename
6024 }
6025
6026 \newskip\contentsrightmargin \contentsrightmargin=1in
6027 \newcount\savepageno
6028 \newcount\lastnegativepageno \lastnegativepageno = -1
6029
6030 % Prepare to read what we've written to \tocfile.
6031 %
6032 \def\startcontents#1{%
6033 % If @setchapternewpage on, and @headings double, the contents should
6034 % start on an odd page, unlike chapters. Thus, we maintain
6035 % \contentsalignmacro in parallel with \pagealignmacro.
6036 % From: Torbjorn Granlund <tege@matematik.su.se>
6037 \contentsalignmacro
6038 \immediate\closeout\tocfile
6039 %
6040 % Don't need to put `Contents' or `Short Contents' in the headline.
6041 % It is abundantly clear what they are.
6042 \chapmacro{#1}{Yomitfromtoc}{}%
6043 %
6044 \savepageno = \pageno
6045 \begingroup % Set up to handle contents files properly.
6046 \raggedbottom % Worry more about breakpoints than the bottom.
6047 \advance\hsize by -\contentsrightmargin % Don't use the full line length.
6048 %
6049 % Roman numerals for page numbers.
6050 \ifnum \pageno>0 \global\pageno = \lastnegativepageno \fi
6051 }
6052
6053 % redefined for the two-volume lispref. We always output on
6054 % \jobname.toc even if this is redefined.
6055 %
6056 \def\tocreadfilename{\jobname.toc}
6057
6058 % Normal (long) toc.
6059 %
6060 \def\contents{%
6061 \startcontents{\putwordTOC}%
6062 \openin 1 \tocreadfilename\space
6063 \ifeof 1 \else
6064 \readtocfile
6065 \fi
6066 \vfill \eject
6067 \contentsalignmacro % in case @setchapternewpage odd is in effect
6068 \ifeof 1 \else
6069 \pdfmakeoutlines
6070 \fi
6071 \closein 1
6072 \endgroup
6073 \lastnegativepageno = \pageno
6074 \global\pageno = \savepageno
6075 }
6076
6077 % And just the chapters.
6078 \def\summarycontents{%
6079 \startcontents{\putwordShortTOC}%
6080 %
6081 \let\partentry = \shortpartentry
6082 \let\numchapentry = \shortchapentry
6083 \let\appentry = \shortchapentry
6084 \let\unnchapentry = \shortunnchapentry
6085 % We want a true roman here for the page numbers.
6086 \secfonts
6087 \let\rm=\shortcontrm \let\bf=\shortcontbf
6088 \let\sl=\shortcontsl \let\tt=\shortconttt
6089 \rm
6090 \hyphenpenalty = 10000
6091 \advance\baselineskip by 1pt % Open it up a little.
6092 \def\numsecentry##1##2##3##4{}
6093 \let\appsecentry = \numsecentry
6094 \let\unnsecentry = \numsecentry
6095 \let\numsubsecentry = \numsecentry
6096 \let\appsubsecentry = \numsecentry
6097 \let\unnsubsecentry = \numsecentry
6098 \let\numsubsubsecentry = \numsecentry
6099 \let\appsubsubsecentry = \numsecentry
6100 \let\unnsubsubsecentry = \numsecentry
6101 \openin 1 \tocreadfilename\space
6102 \ifeof 1 \else
6103 \readtocfile
6104 \fi
6105 \closein 1
6106 \vfill \eject
6107 \contentsalignmacro % in case @setchapternewpage odd is in effect
6108 \endgroup
6109 \lastnegativepageno = \pageno
6110 \global\pageno = \savepageno
6111 }
6112 \let\shortcontents = \summarycontents
6113
6114 % Typeset the label for a chapter or appendix for the short contents.
6115 % The arg is, e.g., `A' for an appendix, or `3' for a chapter.
6116 %
6117 \def\shortchaplabel#1{%
6118 % This space should be enough, since a single number is .5em, and the
6119 % widest letter (M) is 1em, at least in the Computer Modern fonts.
6120 % But use \hss just in case.
6121 % (This space doesn't include the extra space that gets added after
6122 % the label; that gets put in by \shortchapentry above.)
6123 %
6124 % We'd like to right-justify chapter numbers, but that looks strange
6125 % with appendix letters. And right-justifying numbers and
6126 % left-justifying letters looks strange when there is less than 10
6127 % chapters. Have to read the whole toc once to know how many chapters
6128 % there are before deciding ...
6129 \hbox to 1em{#1\hss}%
6130 }
6131
6132 % These macros generate individual entries in the table of contents.
6133 % The first argument is the chapter or section name.
6134 % The last argument is the page number.
6135 % The arguments in between are the chapter number, section number, ...
6136
6137 % Parts, in the main contents. Replace the part number, which doesn't
6138 % exist, with an empty box. Let's hope all the numbers have the same width.
6139 % Also ignore the page number, which is conventionally not printed.
6140 \def\numeralbox{\setbox0=\hbox{8}\hbox to \wd0{\hfil}}
6141 \def\partentry#1#2#3#4{\dochapentry{\numeralbox\labelspace#1}{}}
6142 %
6143 % Parts, in the short toc.
6144 \def\shortpartentry#1#2#3#4{%
6145 \penalty-300
6146 \vskip.5\baselineskip plus.15\baselineskip minus.1\baselineskip
6147 \shortchapentry{{\bf #1}}{\numeralbox}{}{}%
6148 }
6149
6150 % Chapters, in the main contents.
6151 \def\numchapentry#1#2#3#4{\dochapentry{#2\labelspace#1}{#4}}
6152 %
6153 % Chapters, in the short toc.
6154 % See comments in \dochapentry re vbox and related settings.
6155 \def\shortchapentry#1#2#3#4{%
6156 \tocentry{\shortchaplabel{#2}\labelspace #1}{\doshortpageno\bgroup#4\egroup}%
6157 }
6158
6159 % Appendices, in the main contents.
6160 % Need the word Appendix, and a fixed-size box.
6161 %
6162 \def\appendixbox#1{%
6163 % We use M since it's probably the widest letter.
6164 \setbox0 = \hbox{\putwordAppendix{} M}%
6165 \hbox to \wd0{\putwordAppendix{} #1\hss}}
6166 %
6167 \def\appentry#1#2#3#4{\dochapentry{\appendixbox{#2}\labelspace#1}{#4}}
6168
6169 % Unnumbered chapters.
6170 \def\unnchapentry#1#2#3#4{\dochapentry{#1}{#4}}
6171 \def\shortunnchapentry#1#2#3#4{\tocentry{#1}{\doshortpageno\bgroup#4\egroup}}
6172
6173 % Sections.
6174 \def\numsecentry#1#2#3#4{\dosecentry{#2\labelspace#1}{#4}}
6175 \let\appsecentry=\numsecentry
6176 \def\unnsecentry#1#2#3#4{\dosecentry{#1}{#4}}
6177
6178 % Subsections.
6179 \def\numsubsecentry#1#2#3#4{\dosubsecentry{#2\labelspace#1}{#4}}
6180 \let\appsubsecentry=\numsubsecentry
6181 \def\unnsubsecentry#1#2#3#4{\dosubsecentry{#1}{#4}}
6182
6183 % And subsubsections.
6184 \def\numsubsubsecentry#1#2#3#4{\dosubsubsecentry{#2\labelspace#1}{#4}}
6185 \let\appsubsubsecentry=\numsubsubsecentry
6186 \def\unnsubsubsecentry#1#2#3#4{\dosubsubsecentry{#1}{#4}}
6187
6188 % This parameter controls the indentation of the various levels.
6189 % Same as \defaultparindent.
6190 \newdimen\tocindent \tocindent = 15pt
6191
6192 % Now for the actual typesetting. In all these, #1 is the text and #2 is the
6193 % page number.
6194 %
6195 % If the toc has to be broken over pages, we want it to be at chapters
6196 % if at all possible; hence the \penalty.
6197 \def\dochapentry#1#2{%
6198 \penalty-300 \vskip1\baselineskip plus.33\baselineskip minus.25\baselineskip
6199 \begingroup
6200 \chapentryfonts
6201 \tocentry{#1}{\dopageno\bgroup#2\egroup}%
6202 \endgroup
6203 \nobreak\vskip .25\baselineskip plus.1\baselineskip
6204 }
6205
6206 \def\dosecentry#1#2{\begingroup
6207 \secentryfonts \leftskip=\tocindent
6208 \tocentry{#1}{\dopageno\bgroup#2\egroup}%
6209 \endgroup}
6210
6211 \def\dosubsecentry#1#2{\begingroup
6212 \subsecentryfonts \leftskip=2\tocindent
6213 \tocentry{#1}{\dopageno\bgroup#2\egroup}%
6214 \endgroup}
6215
6216 \def\dosubsubsecentry#1#2{\begingroup
6217 \subsubsecentryfonts \leftskip=3\tocindent
6218 \tocentry{#1}{\dopageno\bgroup#2\egroup}%
6219 \endgroup}
6220
6221 % We use the same \entry macro as for the index entries.
6222 \let\tocentry = \entry
6223
6224 % Space between chapter (or whatever) number and the title.
6225 \def\labelspace{\hskip1em \relax}
6226
6227 \def\dopageno#1{{\rm #1}}
6228 \def\doshortpageno#1{{\rm #1}}
6229
6230 \def\chapentryfonts{\secfonts \rm}
6231 \def\secentryfonts{\textfonts}
6232 \def\subsecentryfonts{\textfonts}
6233 \def\subsubsecentryfonts{\textfonts}
6234
6235
6236 \message{environments,}
6237 % @foo ... @end foo.
6238
6239 % @tex ... @end tex escapes into raw TeX temporarily.
6240 % One exception: @ is still an escape character, so that @end tex works.
6241 % But \@ or @@ will get a plain @ character.
6242
6243 \envdef\tex{%
6244 \setupmarkupstyle{tex}%
6245 \catcode `\\=0 \catcode `\{=1 \catcode `\}=2
6246 \catcode `\$=3 \catcode `\&=4 \catcode `\#=6
6247 \catcode `\^=7 \catcode `\_=8 \catcode `\~=\active \let~=\tie
6248 \catcode `\%=14
6249 \catcode `\+=\other
6250 \catcode `\"=\other
6251 \catcode `\|=\other
6252 \catcode `\<=\other
6253 \catcode `\>=\other
6254 \catcode`\`=\other
6255 \catcode`\'=\other
6256 \escapechar=`\\
6257 %
6258 % ' is active in math mode (mathcode"8000). So reset it, and all our
6259 % other math active characters (just in case), to plain's definitions.
6260 \mathactive
6261 %
6262 \let\b=\ptexb
6263 \let\bullet=\ptexbullet
6264 \let\c=\ptexc
6265 \let\,=\ptexcomma
6266 \let\.=\ptexdot
6267 \let\dots=\ptexdots
6268 \let\equiv=\ptexequiv
6269 \let\!=\ptexexclam
6270 \let\i=\ptexi
6271 \let\indent=\ptexindent
6272 \let\noindent=\ptexnoindent
6273 \let\{=\ptexlbrace
6274 \let\+=\tabalign
6275 \let\}=\ptexrbrace
6276 \let\/=\ptexslash
6277 \let\*=\ptexstar
6278 \let\t=\ptext
6279 \expandafter \let\csname top\endcsname=\ptextop % outer
6280 \let\frenchspacing=\plainfrenchspacing
6281 %
6282 \def\endldots{\mathinner{\ldots\ldots\ldots\ldots}}%
6283 \def\enddots{\relax\ifmmode\endldots\else$\mathsurround=0pt \endldots\,$\fi}%
6284 \def\@{@}%
6285 }
6286 % There is no need to define \Etex.
6287
6288 % Define @lisp ... @end lisp.
6289 % @lisp environment forms a group so it can rebind things,
6290 % including the definition of @end lisp (which normally is erroneous).
6291
6292 % Amount to narrow the margins by for @lisp.
6293 \newskip\lispnarrowing \lispnarrowing=0.4in
6294
6295 % This is the definition that ^^M gets inside @lisp, @example, and other
6296 % such environments. \null is better than a space, since it doesn't
6297 % have any width.
6298 \def\lisppar{\null\endgraf}
6299
6300 % This space is always present above and below environments.
6301 \newskip\envskipamount \envskipamount = 0pt
6302
6303 % Make spacing and below environment symmetrical. We use \parskip here
6304 % to help in doing that, since in @example-like environments \parskip
6305 % is reset to zero; thus the \afterenvbreak inserts no space -- but the
6306 % start of the next paragraph will insert \parskip.
6307 %
6308 \def\aboveenvbreak{{%
6309 % =10000 instead of <10000 because of a special case in \itemzzz and
6310 % \sectionheading, q.v.
6311 \ifnum \lastpenalty=10000 \else
6312 \advance\envskipamount by \parskip
6313 \endgraf
6314 \ifdim\lastskip<\envskipamount
6315 \removelastskip
6316 % it's not a good place to break if the last penalty was \nobreak
6317 % or better ...
6318 \ifnum\lastpenalty<10000 \penalty-50 \fi
6319 \vskip\envskipamount
6320 \fi
6321 \fi
6322 }}
6323
6324 \let\afterenvbreak = \aboveenvbreak
6325
6326 % \nonarrowing is a flag. If "set", @lisp etc don't narrow margins; it will
6327 % also clear it, so that its embedded environments do the narrowing again.
6328 \let\nonarrowing=\relax
6329
6330 % @cartouche ... @end cartouche: draw rectangle w/rounded corners around
6331 % environment contents.
6332 \font\circle=lcircle10
6333 \newdimen\circthick
6334 \newdimen\cartouter\newdimen\cartinner
6335 \newskip\normbskip\newskip\normpskip\newskip\normlskip
6336 \circthick=\fontdimen8\circle
6337 %
6338 \def\ctl{{\circle\char'013\hskip -6pt}}% 6pt from pl file: 1/2charwidth
6339 \def\ctr{{\hskip 6pt\circle\char'010}}
6340 \def\cbl{{\circle\char'012\hskip -6pt}}
6341 \def\cbr{{\hskip 6pt\circle\char'011}}
6342 \def\carttop{\hbox to \cartouter{\hskip\lskip
6343 \ctl\leaders\hrule height\circthick\hfil\ctr
6344 \hskip\rskip}}
6345 \def\cartbot{\hbox to \cartouter{\hskip\lskip
6346 \cbl\leaders\hrule height\circthick\hfil\cbr
6347 \hskip\rskip}}
6348 %
6349 \newskip\lskip\newskip\rskip
6350
6351 \envdef\cartouche{%
6352 \ifhmode\par\fi % can't be in the midst of a paragraph.
6353 \startsavinginserts
6354 \lskip=\leftskip \rskip=\rightskip
6355 \leftskip=0pt\rightskip=0pt % we want these *outside*.
6356 \cartinner=\hsize \advance\cartinner by-\lskip
6357 \advance\cartinner by-\rskip
6358 \cartouter=\hsize
6359 \advance\cartouter by 18.4pt % allow for 3pt kerns on either
6360 % side, and for 6pt waste from
6361 % each corner char, and rule thickness
6362 \normbskip=\baselineskip \normpskip=\parskip \normlskip=\lineskip
6363 % Flag to tell @lisp, etc., not to narrow margin.
6364 \let\nonarrowing = t%
6365 %
6366 % If this cartouche directly follows a sectioning command, we need the
6367 % \parskip glue (backspaced over by default) or the cartouche can
6368 % collide with the section heading.
6369 \ifnum\lastpenalty>10000 \vskip\parskip \penalty\lastpenalty \fi
6370 %
6371 \vbox\bgroup
6372 \baselineskip=0pt\parskip=0pt\lineskip=0pt
6373 \carttop
6374 \hbox\bgroup
6375 \hskip\lskip
6376 \vrule\kern3pt
6377 \vbox\bgroup
6378 \kern3pt
6379 \hsize=\cartinner
6380 \baselineskip=\normbskip
6381 \lineskip=\normlskip
6382 \parskip=\normpskip
6383 \vskip -\parskip
6384 \comment % For explanation, see the end of def\group.
6385 }
6386 \def\Ecartouche{%
6387 \ifhmode\par\fi
6388 \kern3pt
6389 \egroup
6390 \kern3pt\vrule
6391 \hskip\rskip
6392 \egroup
6393 \cartbot
6394 \egroup
6395 \checkinserts
6396 }
6397
6398
6399 % This macro is called at the beginning of all the @example variants,
6400 % inside a group.
6401 \newdimen\nonfillparindent
6402 \def\nonfillstart{%
6403 \aboveenvbreak
6404 \hfuzz = 12pt % Don't be fussy
6405 \sepspaces % Make spaces be word-separators rather than space tokens.
6406 \let\par = \lisppar % don't ignore blank lines
6407 \obeylines % each line of input is a line of output
6408 \parskip = 0pt
6409 % Turn off paragraph indentation but redefine \indent to emulate
6410 % the normal \indent.
6411 \nonfillparindent=\parindent
6412 \parindent = 0pt
6413 \let\indent\nonfillindent
6414 %
6415 \emergencystretch = 0pt % don't try to avoid overfull boxes
6416 \ifx\nonarrowing\relax
6417 \advance \leftskip by \lispnarrowing
6418 \exdentamount=\lispnarrowing
6419 \else
6420 \let\nonarrowing = \relax
6421 \fi
6422 \let\exdent=\nofillexdent
6423 }
6424
6425 \begingroup
6426 \obeyspaces
6427 % We want to swallow spaces (but not other tokens) after the fake
6428 % @indent in our nonfill-environments, where spaces are normally
6429 % active and set to @tie, resulting in them not being ignored after
6430 % @indent.
6431 \gdef\nonfillindent{\futurelet\temp\nonfillindentcheck}%
6432 \gdef\nonfillindentcheck{%
6433 \ifx\temp %
6434 \expandafter\nonfillindentgobble%
6435 \else%
6436 \leavevmode\nonfillindentbox%
6437 \fi%
6438 }%
6439 \endgroup
6440 \def\nonfillindentgobble#1{\nonfillindent}
6441 \def\nonfillindentbox{\hbox to \nonfillparindent{\hss}}
6442
6443 % If you want all examples etc. small: @set dispenvsize small.
6444 % If you want even small examples the full size: @set dispenvsize nosmall.
6445 % This affects the following displayed environments:
6446 % @example, @display, @format, @lisp
6447 %
6448 \def\smallword{small}
6449 \def\nosmallword{nosmall}
6450 \let\SETdispenvsize\relax
6451 \def\setnormaldispenv{%
6452 \ifx\SETdispenvsize\smallword
6453 % end paragraph for sake of leading, in case document has no blank
6454 % line. This is redundant with what happens in \aboveenvbreak, but
6455 % we need to do it before changing the fonts, and it's inconvenient
6456 % to change the fonts afterward.
6457 \ifnum \lastpenalty=10000 \else \endgraf \fi
6458 \smallexamplefonts \rm
6459 \fi
6460 }
6461 \def\setsmalldispenv{%
6462 \ifx\SETdispenvsize\nosmallword
6463 \else
6464 \ifnum \lastpenalty=10000 \else \endgraf \fi
6465 \smallexamplefonts \rm
6466 \fi
6467 }
6468
6469 % We often define two environments, @foo and @smallfoo.
6470 % Let's do it in one command. #1 is the env name, #2 the definition.
6471 \def\makedispenvdef#1#2{%
6472 \expandafter\envdef\csname#1\endcsname {\setnormaldispenv #2}%
6473 \expandafter\envdef\csname small#1\endcsname {\setsmalldispenv #2}%
6474 \expandafter\let\csname E#1\endcsname \afterenvbreak
6475 \expandafter\let\csname Esmall#1\endcsname \afterenvbreak
6476 }
6477
6478 % Define two environment synonyms (#1 and #2) for an environment.
6479 \def\maketwodispenvdef#1#2#3{%
6480 \makedispenvdef{#1}{#3}%
6481 \makedispenvdef{#2}{#3}%
6482 }
6483 %
6484 % @lisp: indented, narrowed, typewriter font;
6485 % @example: same as @lisp.
6486 %
6487 % @smallexample and @smalllisp: use smaller fonts.
6488 % Originally contributed by Pavel@xerox.
6489 %
6490 \maketwodispenvdef{lisp}{example}{%
6491 \nonfillstart
6492 \tt\setupmarkupstyle{example}%
6493 \let\kbdfont = \kbdexamplefont % Allow @kbd to do something special.
6494 \gobble % eat return
6495 }
6496 % @display/@smalldisplay: same as @lisp except keep current font.
6497 %
6498 \makedispenvdef{display}{%
6499 \nonfillstart
6500 \gobble
6501 }
6502
6503 % @format/@smallformat: same as @display except don't narrow margins.
6504 %
6505 \makedispenvdef{format}{%
6506 \let\nonarrowing = t%
6507 \nonfillstart
6508 \gobble
6509 }
6510
6511 % @flushleft: same as @format, but doesn't obey \SETdispenvsize.
6512 \envdef\flushleft{%
6513 \let\nonarrowing = t%
6514 \nonfillstart
6515 \gobble
6516 }
6517 \let\Eflushleft = \afterenvbreak
6518
6519 % @flushright.
6520 %
6521 \envdef\flushright{%
6522 \let\nonarrowing = t%
6523 \nonfillstart
6524 \advance\leftskip by 0pt plus 1fill\relax
6525 \gobble
6526 }
6527 \let\Eflushright = \afterenvbreak
6528
6529
6530 % @raggedright does more-or-less normal line breaking but no right
6531 % justification. From plain.tex.
6532 \envdef\raggedright{%
6533 \rightskip0pt plus2em \spaceskip.3333em \xspaceskip.5em\relax
6534 }
6535 \let\Eraggedright\par
6536
6537 \envdef\raggedleft{%
6538 \parindent=0pt \leftskip0pt plus2em
6539 \spaceskip.3333em \xspaceskip.5em \parfillskip=0pt
6540 \hbadness=10000 % Last line will usually be underfull, so turn off
6541 % badness reporting.
6542 }
6543 \let\Eraggedleft\par
6544
6545 \envdef\raggedcenter{%
6546 \parindent=0pt \rightskip0pt plus1em \leftskip0pt plus1em
6547 \spaceskip.3333em \xspaceskip.5em \parfillskip=0pt
6548 \hbadness=10000 % Last line will usually be underfull, so turn off
6549 % badness reporting.
6550 }
6551 \let\Eraggedcenter\par
6552
6553
6554 % @quotation does normal linebreaking (hence we can't use \nonfillstart)
6555 % and narrows the margins. We keep \parskip nonzero in general, since
6556 % we're doing normal filling. So, when using \aboveenvbreak and
6557 % \afterenvbreak, temporarily make \parskip 0.
6558 %
6559 \makedispenvdef{quotation}{\quotationstart}
6560 %
6561 \def\quotationstart{%
6562 \indentedblockstart % same as \indentedblock, but increase right margin too.
6563 \ifx\nonarrowing\relax
6564 \advance\rightskip by \lispnarrowing
6565 \fi
6566 \parsearg\quotationlabel
6567 }
6568
6569 % We have retained a nonzero parskip for the environment, since we're
6570 % doing normal filling.
6571 %
6572 \def\Equotation{%
6573 \par
6574 \ifx\quotationauthor\thisisundefined\else
6575 % indent a bit.
6576 \leftline{\kern 2\leftskip \sl ---\quotationauthor}%
6577 \fi
6578 {\parskip=0pt \afterenvbreak}%
6579 }
6580 \def\Esmallquotation{\Equotation}
6581
6582 % If we're given an argument, typeset it in bold with a colon after.
6583 \def\quotationlabel#1{%
6584 \def\temp{#1}%
6585 \ifx\temp\empty \else
6586 {\bf #1: }%
6587 \fi
6588 }
6589
6590 % @indentedblock is like @quotation, but indents only on the left and
6591 % has no optional argument.
6592 %
6593 \makedispenvdef{indentedblock}{\indentedblockstart}
6594 %
6595 \def\indentedblockstart{%
6596 {\parskip=0pt \aboveenvbreak}% because \aboveenvbreak inserts \parskip
6597 \parindent=0pt
6598 %
6599 % @cartouche defines \nonarrowing to inhibit narrowing at next level down.
6600 \ifx\nonarrowing\relax
6601 \advance\leftskip by \lispnarrowing
6602 \exdentamount = \lispnarrowing
6603 \else
6604 \let\nonarrowing = \relax
6605 \fi
6606 }
6607
6608 % Keep a nonzero parskip for the environment, since we're doing normal filling.
6609 %
6610 \def\Eindentedblock{%
6611 \par
6612 {\parskip=0pt \afterenvbreak}%
6613 }
6614 \def\Esmallindentedblock{\Eindentedblock}
6615
6616
6617 % LaTeX-like @verbatim...@end verbatim and @verb{<char>...<char>}
6618 % If we want to allow any <char> as delimiter,
6619 % we need the curly braces so that makeinfo sees the @verb command, eg:
6620 % `@verbx...x' would look like the '@verbx' command. --janneke@gnu.org
6621 %
6622 % [Knuth]: Donald Ervin Knuth, 1996. The TeXbook.
6623 %
6624 % [Knuth] p.344; only we need to do the other characters Texinfo sets
6625 % active too. Otherwise, they get lost as the first character on a
6626 % verbatim line.
6627 \def\dospecials{%
6628 \do\ \do\\\do\{\do\}\do\$\do\&%
6629 \do\#\do\^\do\^^K\do\_\do\^^A\do\%\do\~%
6630 \do\<\do\>\do\|\do\@\do+\do\"%
6631 % Don't do the quotes -- if we do, @set txicodequoteundirected and
6632 % @set txicodequotebacktick will not have effect on @verb and
6633 % @verbatim, and ?` and !` ligatures won't get disabled.
6634 %\do\`\do\'%
6635 }
6636 %
6637 % [Knuth] p. 380
6638 \def\uncatcodespecials{%
6639 \def\do##1{\catcode`##1=\other}\dospecials}
6640 %
6641 % Setup for the @verb command.
6642 %
6643 % Eight spaces for a tab
6644 \begingroup
6645 \catcode`\^^I=\active
6646 \gdef\tabeightspaces{\catcode`\^^I=\active\def^^I{\ \ \ \ \ \ \ \ }}
6647 \endgroup
6648 %
6649 \def\setupverb{%
6650 \tt % easiest (and conventionally used) font for verbatim
6651 \def\par{\leavevmode\endgraf}%
6652 \setupmarkupstyle{verb}%
6653 \tabeightspaces
6654 % Respect line breaks,
6655 % print special symbols as themselves, and
6656 % make each space count
6657 % must do in this order:
6658 \obeylines \uncatcodespecials \sepspaces
6659 }
6660
6661 % Setup for the @verbatim environment
6662 %
6663 % Real tab expansion.
6664 \newdimen\tabw \setbox0=\hbox{\tt\space} \tabw=8\wd0 % tab amount
6665 %
6666 % We typeset each line of the verbatim in an \hbox, so we can handle
6667 % tabs. The \global is in case the verbatim line starts with an accent,
6668 % or some other command that starts with a begin-group. Otherwise, the
6669 % entire \verbbox would disappear at the corresponding end-group, before
6670 % it is typeset. Meanwhile, we can't have nested verbatim commands
6671 % (can we?), so the \global won't be overwriting itself.
6672 \newbox\verbbox
6673 \def\starttabbox{\global\setbox\verbbox=\hbox\bgroup}
6674 %
6675 \begingroup
6676 \catcode`\^^I=\active
6677 \gdef\tabexpand{%
6678 \catcode`\^^I=\active
6679 \def^^I{\leavevmode\egroup
6680 \dimen\verbbox=\wd\verbbox % the width so far, or since the previous tab
6681 \divide\dimen\verbbox by\tabw
6682 \multiply\dimen\verbbox by\tabw % compute previous multiple of \tabw
6683 \advance\dimen\verbbox by\tabw % advance to next multiple of \tabw
6684 \wd\verbbox=\dimen\verbbox \box\verbbox \starttabbox
6685 }%
6686 }
6687 \endgroup
6688
6689 % start the verbatim environment.
6690 \def\setupverbatim{%
6691 \let\nonarrowing = t%
6692 \nonfillstart
6693 \tt % easiest (and conventionally used) font for verbatim
6694 % The \leavevmode here is for blank lines. Otherwise, we would
6695 % never \starttabox and the \egroup would end verbatim mode.
6696 \def\par{\leavevmode\egroup\box\verbbox\endgraf}%
6697 \tabexpand
6698 \setupmarkupstyle{verbatim}%
6699 % Respect line breaks,
6700 % print special symbols as themselves, and
6701 % make each space count.
6702 % Must do in this order:
6703 \obeylines \uncatcodespecials \sepspaces
6704 \everypar{\starttabbox}%
6705 }
6706
6707 % Do the @verb magic: verbatim text is quoted by unique
6708 % delimiter characters. Before first delimiter expect a
6709 % right brace, after last delimiter expect closing brace:
6710 %
6711 % \def\doverb'{'<char>#1<char>'}'{#1}
6712 %
6713 % [Knuth] p. 382; only eat outer {}
6714 \begingroup
6715 \catcode`[=1\catcode`]=2\catcode`\{=\other\catcode`\}=\other
6716 \gdef\doverb{#1[\def\next##1#1}[##1\endgroup]\next]
6717 \endgroup
6718 %
6719 \def\verb{\begingroup\setupverb\doverb}
6720 %
6721 %
6722 % Do the @verbatim magic: define the macro \doverbatim so that
6723 % the (first) argument ends when '@end verbatim' is reached, ie:
6724 %
6725 % \def\doverbatim#1@end verbatim{#1}
6726 %
6727 % For Texinfo it's a lot easier than for LaTeX,
6728 % because texinfo's \verbatim doesn't stop at '\end{verbatim}':
6729 % we need not redefine '\', '{' and '}'.
6730 %
6731 % Inspired by LaTeX's verbatim command set [latex.ltx]
6732 %
6733 \begingroup
6734 \catcode`\ =\active
6735 \obeylines %
6736 % ignore everything up to the first ^^M, that's the newline at the end
6737 % of the @verbatim input line itself. Otherwise we get an extra blank
6738 % line in the output.
6739 \xdef\doverbatim#1^^M#2@end verbatim{#2\noexpand\end\gobble verbatim}%
6740 % We really want {...\end verbatim} in the body of the macro, but
6741 % without the active space; thus we have to use \xdef and \gobble.
6742 \endgroup
6743 %
6744 \envdef\verbatim{%
6745 \setupverbatim\doverbatim
6746 }
6747 \let\Everbatim = \afterenvbreak
6748
6749
6750 % @verbatiminclude FILE - insert text of file in verbatim environment.
6751 %
6752 \def\verbatiminclude{\parseargusing\filenamecatcodes\doverbatiminclude}
6753 %
6754 \def\doverbatiminclude#1{%
6755 {%
6756 \makevalueexpandable
6757 \setupverbatim
6758 \indexnofonts % Allow `@@' and other weird things in file names.
6759 \wlog{texinfo.tex: doing @verbatiminclude of #1^^J}%
6760 \input #1
6761 \afterenvbreak
6762 }%
6763 }
6764
6765 % @copying ... @end copying.
6766 % Save the text away for @insertcopying later.
6767 %
6768 % We save the uninterpreted tokens, rather than creating a box.
6769 % Saving the text in a box would be much easier, but then all the
6770 % typesetting commands (@smallbook, font changes, etc.) have to be done
6771 % beforehand -- and a) we want @copying to be done first in the source
6772 % file; b) letting users define the frontmatter in as flexible order as
6773 % possible is very desirable.
6774 %
6775 \def\copying{\checkenv{}\begingroup\scanargctxt\docopying}
6776 \def\docopying#1@end copying{\endgroup\def\copyingtext{#1}}
6777 %
6778 \def\insertcopying{%
6779 \begingroup
6780 \parindent = 0pt % paragraph indentation looks wrong on title page
6781 \scanexp\copyingtext
6782 \endgroup
6783 }
6784
6785
6786 \message{defuns,}
6787 % @defun etc.
6788
6789 \newskip\defbodyindent \defbodyindent=.4in
6790 \newskip\defargsindent \defargsindent=50pt
6791 \newskip\deflastargmargin \deflastargmargin=18pt
6792 \newcount\defunpenalty
6793
6794 % Start the processing of @deffn:
6795 \def\startdefun{%
6796 \ifnum\lastpenalty<10000
6797 \medbreak
6798 \defunpenalty=10003 % Will keep this @deffn together with the
6799 % following @def command, see below.
6800 \else
6801 % If there are two @def commands in a row, we'll have a \nobreak,
6802 % which is there to keep the function description together with its
6803 % header. But if there's nothing but headers, we need to allow a
6804 % break somewhere. Check specifically for penalty 10002, inserted
6805 % by \printdefunline, instead of 10000, since the sectioning
6806 % commands also insert a nobreak penalty, and we don't want to allow
6807 % a break between a section heading and a defun.
6808 %
6809 % As a further refinement, we avoid "club" headers by signalling
6810 % with penalty of 10003 after the very first @deffn in the
6811 % sequence (see above), and penalty of 10002 after any following
6812 % @def command.
6813 \ifnum\lastpenalty=10002 \penalty2000 \else \defunpenalty=10002 \fi
6814 %
6815 % Similarly, after a section heading, do not allow a break.
6816 % But do insert the glue.
6817 \medskip % preceded by discardable penalty, so not a breakpoint
6818 \fi
6819 %
6820 \parindent=0in
6821 \advance\leftskip by \defbodyindent
6822 \exdentamount=\defbodyindent
6823 }
6824
6825 \def\dodefunx#1{%
6826 % First, check whether we are in the right environment:
6827 \checkenv#1%
6828 %
6829 % As above, allow line break if we have multiple x headers in a row.
6830 % It's not a great place, though.
6831 \ifnum\lastpenalty=10002 \penalty3000 \else \defunpenalty=10002 \fi
6832 %
6833 % And now, it's time to reuse the body of the original defun:
6834 \expandafter\gobbledefun#1%
6835 }
6836 \def\gobbledefun#1\startdefun{}
6837
6838 % \printdefunline \deffnheader{text}
6839 %
6840 \def\printdefunline#1#2{%
6841 \begingroup
6842 % call \deffnheader:
6843 #1#2 \endheader
6844 % common ending:
6845 \interlinepenalty = 10000
6846 \advance\rightskip by 0pt plus 1fil\relax
6847 \endgraf
6848 \nobreak\vskip -\parskip
6849 \penalty\defunpenalty % signal to \startdefun and \dodefunx
6850 % Some of the @defun-type tags do not enable magic parentheses,
6851 % rendering the following check redundant. But we don't optimize.
6852 \checkparencounts
6853 \endgroup
6854 }
6855
6856 \def\Edefun{\endgraf\medbreak}
6857
6858 % \makedefun{deffn} creates \deffn, \deffnx and \Edeffn;
6859 % the only thing remaining is to define \deffnheader.
6860 %
6861 \def\makedefun#1{%
6862 \expandafter\let\csname E#1\endcsname = \Edefun
6863 \edef\temp{\noexpand\domakedefun
6864 \makecsname{#1}\makecsname{#1x}\makecsname{#1header}}%
6865 \temp
6866 }
6867
6868 % \domakedefun \deffn \deffnx \deffnheader
6869 %
6870 % Define \deffn and \deffnx, without parameters.
6871 % \deffnheader has to be defined explicitly.
6872 %
6873 \def\domakedefun#1#2#3{%
6874 \envdef#1{%
6875 \startdefun
6876 \doingtypefnfalse % distinguish typed functions from all else
6877 \parseargusing\activeparens{\printdefunline#3}%
6878 }%
6879 \def#2{\dodefunx#1}%
6880 \def#3%
6881 }
6882
6883 \newif\ifdoingtypefn % doing typed function?
6884 \newif\ifrettypeownline % typeset return type on its own line?
6885
6886 % @deftypefnnewline on|off says whether the return type of typed functions
6887 % are printed on their own line. This affects @deftypefn, @deftypefun,
6888 % @deftypeop, and @deftypemethod.
6889 %
6890 \parseargdef\deftypefnnewline{%
6891 \def\temp{#1}%
6892 \ifx\temp\onword
6893 \expandafter\let\csname SETtxideftypefnnl\endcsname
6894 = \empty
6895 \else\ifx\temp\offword
6896 \expandafter\let\csname SETtxideftypefnnl\endcsname
6897 = \relax
6898 \else
6899 \errhelp = \EMsimple
6900 \errmessage{Unknown @txideftypefnnl value `\temp',
6901 must be on|off}%
6902 \fi\fi
6903 }
6904
6905 % Untyped functions:
6906
6907 % @deffn category name args
6908 \makedefun{deffn}{\deffngeneral{}}
6909
6910 % @deffn category class name args
6911 \makedefun{defop}#1 {\defopon{#1\ \putwordon}}
6912
6913 % \defopon {category on}class name args
6914 \def\defopon#1#2 {\deffngeneral{\putwordon\ \code{#2}}{#1\ \code{#2}} }
6915
6916 % \deffngeneral {subind}category name args
6917 %
6918 \def\deffngeneral#1#2 #3 #4\endheader{%
6919 % Remember that \dosubind{fn}{foo}{} is equivalent to \doind{fn}{foo}.
6920 \dosubind{fn}{\code{#3}}{#1}%
6921 \defname{#2}{}{#3}\magicamp\defunargs{#4\unskip}%
6922 }
6923
6924 % Typed functions:
6925
6926 % @deftypefn category type name args
6927 \makedefun{deftypefn}{\deftypefngeneral{}}
6928
6929 % @deftypeop category class type name args
6930 \makedefun{deftypeop}#1 {\deftypeopon{#1\ \putwordon}}
6931
6932 % \deftypeopon {category on}class type name args
6933 \def\deftypeopon#1#2 {\deftypefngeneral{\putwordon\ \code{#2}}{#1\ \code{#2}} }
6934
6935 % \deftypefngeneral {subind}category type name args
6936 %
6937 \def\deftypefngeneral#1#2 #3 #4 #5\endheader{%
6938 \dosubind{fn}{\code{#4}}{#1}%
6939 \doingtypefntrue
6940 \defname{#2}{#3}{#4}\defunargs{#5\unskip}%
6941 }
6942
6943 % Typed variables:
6944
6945 % @deftypevr category type var args
6946 \makedefun{deftypevr}{\deftypecvgeneral{}}
6947
6948 % @deftypecv category class type var args
6949 \makedefun{deftypecv}#1 {\deftypecvof{#1\ \putwordof}}
6950
6951 % \deftypecvof {category of}class type var args
6952 \def\deftypecvof#1#2 {\deftypecvgeneral{\putwordof\ \code{#2}}{#1\ \code{#2}} }
6953
6954 % \deftypecvgeneral {subind}category type var args
6955 %
6956 \def\deftypecvgeneral#1#2 #3 #4 #5\endheader{%
6957 \dosubind{vr}{\code{#4}}{#1}%
6958 \defname{#2}{#3}{#4}\defunargs{#5\unskip}%
6959 }
6960
6961 % Untyped variables:
6962
6963 % @defvr category var args
6964 \makedefun{defvr}#1 {\deftypevrheader{#1} {} }
6965
6966 % @defcv category class var args
6967 \makedefun{defcv}#1 {\defcvof{#1\ \putwordof}}
6968
6969 % \defcvof {category of}class var args
6970 \def\defcvof#1#2 {\deftypecvof{#1}#2 {} }
6971
6972 % Types:
6973
6974 % @deftp category name args
6975 \makedefun{deftp}#1 #2 #3\endheader{%
6976 \doind{tp}{\code{#2}}%
6977 \defname{#1}{}{#2}\defunargs{#3\unskip}%
6978 }
6979
6980 % Remaining @defun-like shortcuts:
6981 \makedefun{defun}{\deffnheader{\putwordDeffunc} }
6982 \makedefun{defmac}{\deffnheader{\putwordDefmac} }
6983 \makedefun{defspec}{\deffnheader{\putwordDefspec} }
6984 \makedefun{deftypefun}{\deftypefnheader{\putwordDeffunc} }
6985 \makedefun{defvar}{\defvrheader{\putwordDefvar} }
6986 \makedefun{defopt}{\defvrheader{\putwordDefopt} }
6987 \makedefun{deftypevar}{\deftypevrheader{\putwordDefvar} }
6988 \makedefun{defmethod}{\defopon\putwordMethodon}
6989 \makedefun{deftypemethod}{\deftypeopon\putwordMethodon}
6990 \makedefun{defivar}{\defcvof\putwordInstanceVariableof}
6991 \makedefun{deftypeivar}{\deftypecvof\putwordInstanceVariableof}
6992
6993 % \defname, which formats the name of the @def (not the args).
6994 % #1 is the category, such as "Function".
6995 % #2 is the return type, if any.
6996 % #3 is the function name.
6997 %
6998 % We are followed by (but not passed) the arguments, if any.
6999 %
7000 \def\defname#1#2#3{%
7001 \par
7002 % Get the values of \leftskip and \rightskip as they were outside the @def...
7003 \advance\leftskip by -\defbodyindent
7004 %
7005 % Determine if we are typesetting the return type of a typed function
7006 % on a line by itself.
7007 \rettypeownlinefalse
7008 \ifdoingtypefn % doing a typed function specifically?
7009 % then check user option for putting return type on its own line:
7010 \expandafter\ifx\csname SETtxideftypefnnl\endcsname\relax \else
7011 \rettypeownlinetrue
7012 \fi
7013 \fi
7014 %
7015 % How we'll format the category name. Putting it in brackets helps
7016 % distinguish it from the body text that may end up on the next line
7017 % just below it.
7018 \def\temp{#1}%
7019 \setbox0=\hbox{\kern\deflastargmargin \ifx\temp\empty\else [\rm\temp]\fi}
7020 %
7021 % Figure out line sizes for the paragraph shape. We'll always have at
7022 % least two.
7023 \tempnum = 2
7024 %
7025 % The first line needs space for \box0; but if \rightskip is nonzero,
7026 % we need only space for the part of \box0 which exceeds it:
7027 \dimen0=\hsize \advance\dimen0 by -\wd0 \advance\dimen0 by \rightskip
7028 %
7029 % If doing a return type on its own line, we'll have another line.
7030 \ifrettypeownline
7031 \advance\tempnum by 1
7032 \def\maybeshapeline{0in \hsize}%
7033 \else
7034 \def\maybeshapeline{}%
7035 \fi
7036 %
7037 % The continuations:
7038 \dimen2=\hsize \advance\dimen2 by -\defargsindent
7039 %
7040 % The final paragraph shape:
7041 \parshape \tempnum 0in \dimen0 \maybeshapeline \defargsindent \dimen2
7042 %
7043 % Put the category name at the right margin.
7044 \noindent
7045 \hbox to 0pt{%
7046 \hfil\box0 \kern-\hsize
7047 % \hsize has to be shortened this way:
7048 \kern\leftskip
7049 % Intentionally do not respect \rightskip, since we need the space.
7050 }%
7051 %
7052 % Allow all lines to be underfull without complaint:
7053 \tolerance=10000 \hbadness=10000
7054 \exdentamount=\defbodyindent
7055 {%
7056 % defun fonts. We use typewriter by default (used to be bold) because:
7057 % . we're printing identifiers, they should be in tt in principle.
7058 % . in languages with many accents, such as Czech or French, it's
7059 % common to leave accents off identifiers. The result looks ok in
7060 % tt, but exceedingly strange in rm.
7061 % . we don't want -- and --- to be treated as ligatures.
7062 % . this still does not fix the ?` and !` ligatures, but so far no
7063 % one has made identifiers using them :).
7064 \df \tt
7065 \def\temp{#2}% text of the return type
7066 \ifx\temp\empty\else
7067 \tclose{\temp}% typeset the return type
7068 \ifrettypeownline
7069 % put return type on its own line; prohibit line break following:
7070 \hfil\vadjust{\nobreak}\break
7071 \else
7072 \space % type on same line, so just followed by a space
7073 \fi
7074 \fi % no return type
7075 #3% output function name
7076 }%
7077 {\rm\enskip}% hskip 0.5 em of \tenrm
7078 %
7079 \boldbrax
7080 % arguments will be output next, if any.
7081 }
7082
7083 % Print arguments in slanted roman (not ttsl), inconsistently with using
7084 % tt for the name. This is because literal text is sometimes needed in
7085 % the argument list (groff manual), and ttsl and tt are not very
7086 % distinguishable. Prevent hyphenation at `-' chars.
7087 %
7088 \def\defunargs#1{%
7089 % use sl by default (not ttsl),
7090 % tt for the names.
7091 \df \sl \hyphenchar\font=0
7092 %
7093 % On the other hand, if an argument has two dashes (for instance), we
7094 % want a way to get ttsl. We used to recommend @var for that, so
7095 % leave the code in, but it's strange for @var to lead to typewriter.
7096 % Nowadays we recommend @code, since the difference between a ttsl hyphen
7097 % and a tt hyphen is pretty tiny. @code also disables ?` !`.
7098 \def\var##1{{\setupmarkupstyle{var}\ttslanted{##1}}}%
7099 #1%
7100 \sl\hyphenchar\font=45
7101 }
7102
7103 % We want ()&[] to print specially on the defun line.
7104 %
7105 \def\activeparens{%
7106 \catcode`\(=\active \catcode`\)=\active
7107 \catcode`\[=\active \catcode`\]=\active
7108 \catcode`\&=\active
7109 }
7110
7111 % Make control sequences which act like normal parenthesis chars.
7112 \let\lparen = ( \let\rparen = )
7113
7114 % Be sure that we always have a definition for `(', etc. For example,
7115 % if the fn name has parens in it, \boldbrax will not be in effect yet,
7116 % so TeX would otherwise complain about undefined control sequence.
7117 {
7118 \activeparens
7119 \global\let(=\lparen \global\let)=\rparen
7120 \global\let[=\lbrack \global\let]=\rbrack
7121 \global\let& = \&
7122
7123 \gdef\boldbrax{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb}
7124 \gdef\magicamp{\let&=\amprm}
7125 }
7126
7127 \newcount\parencount
7128
7129 % If we encounter &foo, then turn on ()-hacking afterwards
7130 \newif\ifampseen
7131 \def\amprm#1 {\ampseentrue{\bf\&#1 }}
7132
7133 \def\parenfont{%
7134 \ifampseen
7135 % At the first level, print parens in roman,
7136 % otherwise use the default font.
7137 \ifnum \parencount=1 \rm \fi
7138 \else
7139 % The \sf parens (in \boldbrax) actually are a little bolder than
7140 % the contained text. This is especially needed for [ and ] .
7141 \sf
7142 \fi
7143 }
7144 \def\infirstlevel#1{%
7145 \ifampseen
7146 \ifnum\parencount=1
7147 #1%
7148 \fi
7149 \fi
7150 }
7151 \def\bfafterword#1 {#1 \bf}
7152
7153 \def\opnr{%
7154 \global\advance\parencount by 1
7155 {\parenfont(}%
7156 \infirstlevel \bfafterword
7157 }
7158 \def\clnr{%
7159 {\parenfont)}%
7160 \infirstlevel \sl
7161 \global\advance\parencount by -1
7162 }
7163
7164 \newcount\brackcount
7165 \def\lbrb{%
7166 \global\advance\brackcount by 1
7167 {\bf[}%
7168 }
7169 \def\rbrb{%
7170 {\bf]}%
7171 \global\advance\brackcount by -1
7172 }
7173
7174 \def\checkparencounts{%
7175 \ifnum\parencount=0 \else \badparencount \fi
7176 \ifnum\brackcount=0 \else \badbrackcount \fi
7177 }
7178 % these should not use \errmessage; the glibc manual, at least, actually
7179 % has such constructs (when documenting function pointers).
7180 \def\badparencount{%
7181 \message{Warning: unbalanced parentheses in @def...}%
7182 \global\parencount=0
7183 }
7184 \def\badbrackcount{%
7185 \message{Warning: unbalanced square brackets in @def...}%
7186 \global\brackcount=0
7187 }
7188
7189
7190 \message{macros,}
7191 % @macro.
7192
7193 % To do this right we need a feature of e-TeX, \scantokens,
7194 % which we arrange to emulate with a temporary file in ordinary TeX.
7195 \ifx\eTeXversion\thisisundefined
7196 \newwrite\macscribble
7197 \def\scantokens#1{%
7198 \toks0={#1}%
7199 \immediate\openout\macscribble=\jobname.tmp
7200 \immediate\write\macscribble{\the\toks0}%
7201 \immediate\closeout\macscribble
7202 \input \jobname.tmp
7203 }
7204 \fi
7205
7206 \def\scanmacro#1{\begingroup
7207 \newlinechar`\^^M
7208 \let\xeatspaces\eatspaces
7209 %
7210 % Undo catcode changes of \startcontents and \doprintindex
7211 % When called from @insertcopying or (short)caption, we need active
7212 % backslash to get it printed correctly. Previously, we had
7213 % \catcode`\\=\other instead. We'll see whether a problem appears
7214 % with macro expansion. --kasal, 19aug04
7215 \catcode`\@=0 \catcode`\\=\active \escapechar=`\@
7216 %
7217 % ... and for \example:
7218 \spaceisspace
7219 %
7220 % The \empty here causes a following catcode 5 newline to be eaten as
7221 % part of reading whitespace after a control sequence. It does not
7222 % eat a catcode 13 newline. There's no good way to handle the two
7223 % cases (untried: maybe e-TeX's \everyeof could help, though plain TeX
7224 % would then have different behavior). See the Macro Details node in
7225 % the manual for the workaround we recommend for macros and
7226 % line-oriented commands.
7227 %
7228 \scantokens{#1\empty}%
7229 \endgroup}
7230
7231 \def\scanexp#1{%
7232 \edef\temp{\noexpand\scanmacro{#1}}%
7233 \temp
7234 }
7235
7236 \newcount\paramno % Count of parameters
7237 \newtoks\macname % Macro name
7238 \newif\ifrecursive % Is it recursive?
7239
7240 % List of all defined macros in the form
7241 % \definedummyword\macro1\definedummyword\macro2...
7242 % Currently is also contains all @aliases; the list can be split
7243 % if there is a need.
7244 \def\macrolist{}
7245
7246 % Add the macro to \macrolist
7247 \def\addtomacrolist#1{\expandafter \addtomacrolistxxx \csname#1\endcsname}
7248 \def\addtomacrolistxxx#1{%
7249 \toks0 = \expandafter{\macrolist\definedummyword#1}%
7250 \xdef\macrolist{\the\toks0}%
7251 }
7252
7253 % Utility routines.
7254 % This does \let #1 = #2, with \csnames; that is,
7255 % \let \csname#1\endcsname = \csname#2\endcsname
7256 % (except of course we have to play expansion games).
7257 %
7258 \def\cslet#1#2{%
7259 \expandafter\let
7260 \csname#1\expandafter\endcsname
7261 \csname#2\endcsname
7262 }
7263
7264 % Trim leading and trailing spaces off a string.
7265 % Concepts from aro-bend problem 15 (see CTAN).
7266 {\catcode`\@=11
7267 \gdef\eatspaces #1{\expandafter\trim@\expandafter{#1 }}
7268 \gdef\trim@ #1{\trim@@ @#1 @ #1 @ @@}
7269 \gdef\trim@@ #1@ #2@ #3@@{\trim@@@\empty #2 @}
7270 \def\unbrace#1{#1}
7271 \unbrace{\gdef\trim@@@ #1 } #2@{#1}
7272 }
7273
7274 % Trim a single trailing ^^M off a string.
7275 {\catcode`\^^M=\other \catcode`\Q=3%
7276 \gdef\eatcr #1{\eatcra #1Q^^MQ}%
7277 \gdef\eatcra#1^^MQ{\eatcrb#1Q}%
7278 \gdef\eatcrb#1Q#2Q{#1}%
7279 }
7280
7281 % Macro bodies are absorbed as an argument in a context where
7282 % all characters are catcode 10, 11 or 12, except \ which is active
7283 % (as in normal texinfo). It is necessary to change the definition of \
7284 % to recognize macro arguments; this is the job of \mbodybackslash.
7285 %
7286 % Non-ASCII encodings make 8-bit characters active, so un-activate
7287 % them to avoid their expansion. Must do this non-globally, to
7288 % confine the change to the current group.
7289 %
7290 % It's necessary to have hard CRs when the macro is executed. This is
7291 % done by making ^^M (\endlinechar) catcode 12 when reading the macro
7292 % body, and then making it the \newlinechar in \scanmacro.
7293 %
7294 \def\scanctxt{% used as subroutine
7295 \catcode`\"=\other
7296 \catcode`\+=\other
7297 \catcode`\<=\other
7298 \catcode`\>=\other
7299 \catcode`\@=\other
7300 \catcode`\^=\other
7301 \catcode`\_=\other
7302 \catcode`\|=\other
7303 \catcode`\~=\other
7304 \ifx\declaredencoding\ascii \else \setnonasciicharscatcodenonglobal\other \fi
7305 }
7306
7307 \def\scanargctxt{% used for copying and captions, not macros.
7308 \scanctxt
7309 \catcode`\\=\other
7310 \catcode`\^^M=\other
7311 }
7312
7313 \def\macrobodyctxt{% used for @macro definitions
7314 \scanctxt
7315 \catcode`\{=\other
7316 \catcode`\}=\other
7317 \catcode`\^^M=\other
7318 \usembodybackslash
7319 }
7320
7321 \def\macroargctxt{% used when scanning invocations
7322 \scanctxt
7323 \catcode`\\=0
7324 }
7325 % why catcode 0 for \ in the above? To recognize \\ \{ \} as "escapes"
7326 % for the single characters \ { }. Thus, we end up with the "commands"
7327 % that would be written @\ @{ @} in a Texinfo document.
7328 %
7329 % We already have @{ and @}. For @\, we define it here, and only for
7330 % this purpose, to produce a typewriter backslash (so, the @\ that we
7331 % define for @math can't be used with @macro calls):
7332 %
7333 \def\\{\normalbackslash}%
7334 %
7335 % We would like to do this for \, too, since that is what makeinfo does.
7336 % But it is not possible, because Texinfo already has a command @, for a
7337 % cedilla accent. Documents must use @comma{} instead.
7338 %
7339 % \anythingelse will almost certainly be an error of some kind.
7340
7341
7342 % \mbodybackslash is the definition of \ in @macro bodies.
7343 % It maps \foo\ => \csname macarg.foo\endcsname => #N
7344 % where N is the macro parameter number.
7345 % We define \csname macarg.\endcsname to be \realbackslash, so
7346 % \\ in macro replacement text gets you a backslash.
7347 %
7348 {\catcode`@=0 @catcode`@\=@active
7349 @gdef@usembodybackslash{@let\=@mbodybackslash}
7350 @gdef@mbodybackslash#1\{@csname macarg.#1@endcsname}
7351 }
7352 \expandafter\def\csname macarg.\endcsname{\realbackslash}
7353
7354 \def\margbackslash#1{\char`\#1 }
7355
7356 \def\macro{\recursivefalse\parsearg\macroxxx}
7357 \def\rmacro{\recursivetrue\parsearg\macroxxx}
7358
7359 \def\macroxxx#1{%
7360 \getargs{#1}% now \macname is the macname and \argl the arglist
7361 \ifx\argl\empty % no arguments
7362 \paramno=0\relax
7363 \else
7364 \expandafter\parsemargdef \argl;%
7365 \if\paramno>256\relax
7366 \ifx\eTeXversion\thisisundefined
7367 \errhelp = \EMsimple
7368 \errmessage{You need eTeX to compile a file with macros with more than 256 arguments}
7369 \fi
7370 \fi
7371 \fi
7372 \if1\csname ismacro.\the\macname\endcsname
7373 \message{Warning: redefining \the\macname}%
7374 \else
7375 \expandafter\ifx\csname \the\macname\endcsname \relax
7376 \else \errmessage{Macro name \the\macname\space already defined}\fi
7377 \global\cslet{macsave.\the\macname}{\the\macname}%
7378 \global\expandafter\let\csname ismacro.\the\macname\endcsname=1%
7379 \addtomacrolist{\the\macname}%
7380 \fi
7381 \begingroup \macrobodyctxt
7382 \ifrecursive \expandafter\parsermacbody
7383 \else \expandafter\parsemacbody
7384 \fi}
7385
7386 \parseargdef\unmacro{%
7387 \if1\csname ismacro.#1\endcsname
7388 \global\cslet{#1}{macsave.#1}%
7389 \global\expandafter\let \csname ismacro.#1\endcsname=0%
7390 % Remove the macro name from \macrolist:
7391 \begingroup
7392 \expandafter\let\csname#1\endcsname \relax
7393 \let\definedummyword\unmacrodo
7394 \xdef\macrolist{\macrolist}%
7395 \endgroup
7396 \else
7397 \errmessage{Macro #1 not defined}%
7398 \fi
7399 }
7400
7401 % Called by \do from \dounmacro on each macro. The idea is to omit any
7402 % macro definitions that have been changed to \relax.
7403 %
7404 \def\unmacrodo#1{%
7405 \ifx #1\relax
7406 % remove this
7407 \else
7408 \noexpand\definedummyword \noexpand#1%
7409 \fi
7410 }
7411
7412 % This makes use of the obscure feature that if the last token of a
7413 % <parameter list> is #, then the preceding argument is delimited by
7414 % an opening brace, and that opening brace is not consumed.
7415 \def\getargs#1{\getargsxxx#1{}}
7416 \def\getargsxxx#1#{\getmacname #1 \relax\getmacargs}
7417 \def\getmacname#1 #2\relax{\macname={#1}}
7418 \def\getmacargs#1{\def\argl{#1}}
7419
7420 % For macro processing make @ a letter so that we can make Texinfo private macro names.
7421 \edef\texiatcatcode{\the\catcode`\@}
7422 \catcode `@=11\relax
7423
7424 % Parse the optional {params} list. Set up \paramno and \paramlist
7425 % so \defmacro knows what to do. Define \macarg.BLAH for each BLAH
7426 % in the params list to some hook where the argument si to be expanded. If
7427 % there are less than 10 arguments that hook is to be replaced by ##N where N
7428 % is the position in that list, that is to say the macro arguments are to be
7429 % defined `a la TeX in the macro body.
7430 %
7431 % That gets used by \mbodybackslash (above).
7432 %
7433 % We need to get `macro parameter char #' into several definitions.
7434 % The technique used is stolen from LaTeX: let \hash be something
7435 % unexpandable, insert that wherever you need a #, and then redefine
7436 % it to # just before using the token list produced.
7437 %
7438 % The same technique is used to protect \eatspaces till just before
7439 % the macro is used.
7440 %
7441 % If there are 10 or more arguments, a different technique is used, where the
7442 % hook remains in the body, and when macro is to be expanded the body is
7443 % processed again to replace the arguments.
7444 %
7445 % In that case, the hook is \the\toks N-1, and we simply set \toks N-1 to the
7446 % argument N value and then \edef the body (nothing else will expand because of
7447 % the catcode regime underwhich the body was input).
7448 %
7449 % If you compile with TeX (not eTeX), and you have macros with 10 or more
7450 % arguments, you need that no macro has more than 256 arguments, otherwise an
7451 % error is produced.
7452 \def\parsemargdef#1;{%
7453 \paramno=0\def\paramlist{}%
7454 \let\hash\relax
7455 \let\xeatspaces\relax
7456 \parsemargdefxxx#1,;,%
7457 % In case that there are 10 or more arguments we parse again the arguments
7458 % list to set new definitions for the \macarg.BLAH macros corresponding to
7459 % each BLAH argument. It was anyhow needed to parse already once this list
7460 % in order to count the arguments, and as macros with at most 9 arguments
7461 % are by far more frequent than macro with 10 or more arguments, defining
7462 % twice the \macarg.BLAH macros does not cost too much processing power.
7463 \ifnum\paramno<10\relax\else
7464 \paramno0\relax
7465 \parsemmanyargdef@@#1,;,% 10 or more arguments
7466 \fi
7467 }
7468 \def\parsemargdefxxx#1,{%
7469 \if#1;\let\next=\relax
7470 \else \let\next=\parsemargdefxxx
7471 \advance\paramno by 1
7472 \expandafter\edef\csname macarg.\eatspaces{#1}\endcsname
7473 {\xeatspaces{\hash\the\paramno}}%
7474 \edef\paramlist{\paramlist\hash\the\paramno,}%
7475 \fi\next}
7476
7477 \def\parsemmanyargdef@@#1,{%
7478 \if#1;\let\next=\relax
7479 \else
7480 \let\next=\parsemmanyargdef@@
7481 \edef\tempb{\eatspaces{#1}}%
7482 \expandafter\def\expandafter\tempa
7483 \expandafter{\csname macarg.\tempb\endcsname}%
7484 % Note that we need some extra \noexpand\noexpand, this is because we
7485 % don't want \the to be expanded in the \parsermacbody as it uses an
7486 % \xdef .
7487 \expandafter\edef\tempa
7488 {\noexpand\noexpand\noexpand\the\toks\the\paramno}%
7489 \advance\paramno by 1\relax
7490 \fi\next}
7491
7492 % These two commands read recursive and nonrecursive macro bodies.
7493 % (They're different since rec and nonrec macros end differently.)
7494 %
7495
7496 \catcode `\@\texiatcatcode
7497 \long\def\parsemacbody#1@end macro%
7498 {\xdef\temp{\eatcr{#1}}\endgroup\defmacro}%
7499 \long\def\parsermacbody#1@end rmacro%
7500 {\xdef\temp{\eatcr{#1}}\endgroup\defmacro}%
7501 \catcode `\@=11\relax
7502
7503 \let\endargs@\relax
7504 \let\nil@\relax
7505 \def\nilm@{\nil@}%
7506 \long\def\nillm@{\nil@}%
7507
7508 % This macro is expanded during the Texinfo macro expansion, not during its
7509 % definition. It gets all the arguments values and assigns them to macros
7510 % macarg.ARGNAME
7511 %
7512 % #1 is the macro name
7513 % #2 is the list of argument names
7514 % #3 is the list of argument values
7515 \def\getargvals@#1#2#3{%
7516 \def\macargdeflist@{}%
7517 \def\saveparamlist@{#2}% Need to keep a copy for parameter expansion.
7518 \def\paramlist{#2,\nil@}%
7519 \def\macroname{#1}%
7520 \begingroup
7521 \macroargctxt
7522 \def\argvaluelist{#3,\nil@}%
7523 \def\@tempa{#3}%
7524 \ifx\@tempa\empty
7525 \setemptyargvalues@
7526 \else
7527 \getargvals@@
7528 \fi
7529 }
7530
7531 %
7532 \def\getargvals@@{%
7533 \ifx\paramlist\nilm@
7534 % Some sanity check needed here that \argvaluelist is also empty.
7535 \ifx\argvaluelist\nillm@
7536 \else
7537 \errhelp = \EMsimple
7538 \errmessage{Too many arguments in macro `\macroname'!}%
7539 \fi
7540 \let\next\macargexpandinbody@
7541 \else
7542 \ifx\argvaluelist\nillm@
7543 % No more arguments values passed to macro. Set remaining named-arg
7544 % macros to empty.
7545 \let\next\setemptyargvalues@
7546 \else
7547 % pop current arg name into \@tempb
7548 \def\@tempa##1{\pop@{\@tempb}{\paramlist}##1\endargs@}%
7549 \expandafter\@tempa\expandafter{\paramlist}%
7550 % pop current argument value into \@tempc
7551 \def\@tempa##1{\longpop@{\@tempc}{\argvaluelist}##1\endargs@}%
7552 \expandafter\@tempa\expandafter{\argvaluelist}%
7553 % Here \@tempb is the current arg name and \@tempc is the current arg value.
7554 % First place the new argument macro definition into \@tempd
7555 \expandafter\macname\expandafter{\@tempc}%
7556 \expandafter\let\csname macarg.\@tempb\endcsname\relax
7557 \expandafter\def\expandafter\@tempe\expandafter{%
7558 \csname macarg.\@tempb\endcsname}%
7559 \edef\@tempd{\long\def\@tempe{\the\macname}}%
7560 \push@\@tempd\macargdeflist@
7561 \let\next\getargvals@@
7562 \fi
7563 \fi
7564 \next
7565 }
7566
7567 \def\push@#1#2{%
7568 \expandafter\expandafter\expandafter\def
7569 \expandafter\expandafter\expandafter#2%
7570 \expandafter\expandafter\expandafter{%
7571 \expandafter#1#2}%
7572 }
7573
7574 % Replace arguments by their values in the macro body, and place the result
7575 % in macro \@tempa
7576 \def\macvalstoargs@{%
7577 % To do this we use the property that token registers that are \the'ed
7578 % within an \edef expand only once. So we are going to place all argument
7579 % values into respective token registers.
7580 %
7581 % First we save the token context, and initialize argument numbering.
7582 \begingroup
7583 \paramno0\relax
7584 % Then, for each argument number #N, we place the corresponding argument
7585 % value into a new token list register \toks#N
7586 \expandafter\putargsintokens@\saveparamlist@,;,%
7587 % Then, we expand the body so that argument are replaced by their
7588 % values. The trick for values not to be expanded themselves is that they
7589 % are within tokens and that tokens expand only once in an \edef .
7590 \edef\@tempc{\csname mac.\macroname .body\endcsname}%
7591 % Now we restore the token stack pointer to free the token list registers
7592 % which we have used, but we make sure that expanded body is saved after
7593 % group.
7594 \expandafter
7595 \endgroup
7596 \expandafter\def\expandafter\@tempa\expandafter{\@tempc}%
7597 }
7598
7599 \def\macargexpandinbody@{%
7600 %% Define the named-macro outside of this group and then close this group.
7601 \expandafter
7602 \endgroup
7603 \macargdeflist@
7604 % First the replace in body the macro arguments by their values, the result
7605 % is in \@tempa .
7606 \macvalstoargs@
7607 % Then we point at the \norecurse or \gobble (for recursive) macro value
7608 % with \@tempb .
7609 \expandafter\let\expandafter\@tempb\csname mac.\macroname .recurse\endcsname
7610 % Depending on whether it is recursive or not, we need some tailing
7611 % \egroup .
7612 \ifx\@tempb\gobble
7613 \let\@tempc\relax
7614 \else
7615 \let\@tempc\egroup
7616 \fi
7617 % And now we do the real job:
7618 \edef\@tempd{\noexpand\@tempb{\macroname}\noexpand\scanmacro{\@tempa}\@tempc}%
7619 \@tempd
7620 }
7621
7622 \def\putargsintokens@#1,{%
7623 \if#1;\let\next\relax
7624 \else
7625 \let\next\putargsintokens@
7626 % First we allocate the new token list register, and give it a temporary
7627 % alias \@tempb .
7628 \toksdef\@tempb\the\paramno
7629 % Then we place the argument value into that token list register.
7630 \expandafter\let\expandafter\@tempa\csname macarg.#1\endcsname
7631 \expandafter\@tempb\expandafter{\@tempa}%
7632 \advance\paramno by 1\relax
7633 \fi
7634 \next
7635 }
7636
7637 % Save the token stack pointer into macro #1
7638 \def\texisavetoksstackpoint#1{\edef#1{\the\@cclvi}}
7639 % Restore the token stack pointer from number in macro #1
7640 \def\texirestoretoksstackpoint#1{\expandafter\mathchardef\expandafter\@cclvi#1\relax}
7641 % newtoks that can be used non \outer .
7642 \def\texinonouternewtoks{\alloc@ 5\toks \toksdef \@cclvi}
7643
7644 % Tailing missing arguments are set to empty
7645 \def\setemptyargvalues@{%
7646 \ifx\paramlist\nilm@
7647 \let\next\macargexpandinbody@
7648 \else
7649 \expandafter\setemptyargvaluesparser@\paramlist\endargs@
7650 \let\next\setemptyargvalues@
7651 \fi
7652 \next
7653 }
7654
7655 \def\setemptyargvaluesparser@#1,#2\endargs@{%
7656 \expandafter\def\expandafter\@tempa\expandafter{%
7657 \expandafter\def\csname macarg.#1\endcsname{}}%
7658 \push@\@tempa\macargdeflist@
7659 \def\paramlist{#2}%
7660 }
7661
7662 % #1 is the element target macro
7663 % #2 is the list macro
7664 % #3,#4\endargs@ is the list value
7665 \def\pop@#1#2#3,#4\endargs@{%
7666 \def#1{#3}%
7667 \def#2{#4}%
7668 }
7669 \long\def\longpop@#1#2#3,#4\endargs@{%
7670 \long\def#1{#3}%
7671 \long\def#2{#4}%
7672 }
7673
7674 % This defines a Texinfo @macro. There are eight cases: recursive and
7675 % nonrecursive macros of zero, one, up to nine, and many arguments.
7676 % Much magic with \expandafter here.
7677 % \xdef is used so that macro definitions will survive the file
7678 % they're defined in; @include reads the file inside a group.
7679 %
7680 \def\defmacro{%
7681 \let\hash=##% convert placeholders to macro parameter chars
7682 \ifrecursive
7683 \ifcase\paramno
7684 % 0
7685 \expandafter\xdef\csname\the\macname\endcsname{%
7686 \noexpand\scanmacro{\temp}}%
7687 \or % 1
7688 \expandafter\xdef\csname\the\macname\endcsname{%
7689 \bgroup\noexpand\macroargctxt
7690 \noexpand\braceorline
7691 \expandafter\noexpand\csname\the\macname xxx\endcsname}%
7692 \expandafter\xdef\csname\the\macname xxx\endcsname##1{%
7693 \egroup\noexpand\scanmacro{\temp}}%
7694 \else
7695 \ifnum\paramno<10\relax % at most 9
7696 \expandafter\xdef\csname\the\macname\endcsname{%
7697 \bgroup\noexpand\macroargctxt
7698 \noexpand\csname\the\macname xx\endcsname}%
7699 \expandafter\xdef\csname\the\macname xx\endcsname##1{%
7700 \expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
7701 \expandafter\expandafter
7702 \expandafter\xdef
7703 \expandafter\expandafter
7704 \csname\the\macname xxx\endcsname
7705 \paramlist{\egroup\noexpand\scanmacro{\temp}}%
7706 \else % 10 or more
7707 \expandafter\xdef\csname\the\macname\endcsname{%
7708 \noexpand\getargvals@{\the\macname}{\argl}%
7709 }%
7710 \global\expandafter\let\csname mac.\the\macname .body\endcsname\temp
7711 \global\expandafter\let\csname mac.\the\macname .recurse\endcsname\gobble
7712 \fi
7713 \fi
7714 \else
7715 \ifcase\paramno
7716 % 0
7717 \expandafter\xdef\csname\the\macname\endcsname{%
7718 \noexpand\norecurse{\the\macname}%
7719 \noexpand\scanmacro{\temp}\egroup}%
7720 \or % 1
7721 \expandafter\xdef\csname\the\macname\endcsname{%
7722 \bgroup\noexpand\macroargctxt
7723 \noexpand\braceorline
7724 \expandafter\noexpand\csname\the\macname xxx\endcsname}%
7725 \expandafter\xdef\csname\the\macname xxx\endcsname##1{%
7726 \egroup
7727 \noexpand\norecurse{\the\macname}%
7728 \noexpand\scanmacro{\temp}\egroup}%
7729 \else % at most 9
7730 \ifnum\paramno<10\relax
7731 \expandafter\xdef\csname\the\macname\endcsname{%
7732 \bgroup\noexpand\macroargctxt
7733 \expandafter\noexpand\csname\the\macname xx\endcsname}%
7734 \expandafter\xdef\csname\the\macname xx\endcsname##1{%
7735 \expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
7736 \expandafter\expandafter
7737 \expandafter\xdef
7738 \expandafter\expandafter
7739 \csname\the\macname xxx\endcsname
7740 \paramlist{%
7741 \egroup
7742 \noexpand\norecurse{\the\macname}%
7743 \noexpand\scanmacro{\temp}\egroup}%
7744 \else % 10 or more:
7745 \expandafter\xdef\csname\the\macname\endcsname{%
7746 \noexpand\getargvals@{\the\macname}{\argl}%
7747 }%
7748 \global\expandafter\let\csname mac.\the\macname .body\endcsname\temp
7749 \global\expandafter\let\csname mac.\the\macname .recurse\endcsname\norecurse
7750 \fi
7751 \fi
7752 \fi}
7753
7754 \catcode `\@\texiatcatcode\relax
7755
7756 \def\norecurse#1{\bgroup\cslet{#1}{macsave.#1}}
7757
7758 % \braceorline decides whether the next nonwhitespace character is a
7759 % {. If so it reads up to the closing }, if not, it reads the whole
7760 % line. Whatever was read is then fed to the next control sequence
7761 % as an argument (by \parsebrace or \parsearg).
7762 %
7763 \def\braceorline#1{\let\macnamexxx=#1\futurelet\nchar\braceorlinexxx}
7764 \def\braceorlinexxx{%
7765 \ifx\nchar\bgroup\else
7766 \expandafter\parsearg
7767 \fi \macnamexxx}
7768
7769
7770 % @alias.
7771 % We need some trickery to remove the optional spaces around the equal
7772 % sign. Make them active and then expand them all to nothing.
7773 %
7774 \def\alias{\parseargusing\obeyspaces\aliasxxx}
7775 \def\aliasxxx #1{\aliasyyy#1\relax}
7776 \def\aliasyyy #1=#2\relax{%
7777 {%
7778 \expandafter\let\obeyedspace=\empty
7779 \addtomacrolist{#1}%
7780 \xdef\next{\global\let\makecsname{#1}=\makecsname{#2}}%
7781 }%
7782 \next
7783 }
7784
7785
7786 \message{cross references,}
7787
7788 \newwrite\auxfile
7789 \newif\ifhavexrefs % True if xref values are known.
7790 \newif\ifwarnedxrefs % True if we warned once that they aren't known.
7791
7792 % @inforef is relatively simple.
7793 \def\inforef #1{\inforefzzz #1,,,,**}
7794 \def\inforefzzz #1,#2,#3,#4**{%
7795 \putwordSee{} \putwordInfo{} \putwordfile{} \file{\ignorespaces #3{}},
7796 node \samp{\ignorespaces#1{}}}
7797
7798 % @node's only job in TeX is to define \lastnode, which is used in
7799 % cross-references. The @node line might or might not have commas, and
7800 % might or might not have spaces before the first comma, like:
7801 % @node foo , bar , ...
7802 % We don't want such trailing spaces in the node name.
7803 %
7804 \parseargdef\node{\checkenv{}\donode #1 ,\finishnodeparse}
7805 %
7806 % also remove a trailing comma, in case of something like this:
7807 % @node Help-Cross, , , Cross-refs
7808 \def\donode#1 ,#2\finishnodeparse{\dodonode #1,\finishnodeparse}
7809 \def\dodonode#1,#2\finishnodeparse{\gdef\lastnode{#1}}
7810
7811 \let\nwnode=\node
7812 \let\lastnode=\empty
7813
7814 % Write a cross-reference definition for the current node. #1 is the
7815 % type (Ynumbered, Yappendix, Ynothing).
7816 %
7817 \def\donoderef#1{%
7818 \ifx\lastnode\empty\else
7819 \setref{\lastnode}{#1}%
7820 \global\let\lastnode=\empty
7821 \fi
7822 }
7823
7824 % @anchor{NAME} -- define xref target at arbitrary point.
7825 %
7826 \newcount\savesfregister
7827 %
7828 \def\savesf{\relax \ifhmode \savesfregister=\spacefactor \fi}
7829 \def\restoresf{\relax \ifhmode \spacefactor=\savesfregister \fi}
7830 \def\anchor#1{\savesf \setref{#1}{Ynothing}\restoresf \ignorespaces}
7831
7832 % \setref{NAME}{SNT} defines a cross-reference point NAME (a node or an
7833 % anchor), which consists of three parts:
7834 % 1) NAME-title - the current sectioning name taken from \lastsection,
7835 % or the anchor name.
7836 % 2) NAME-snt - section number and type, passed as the SNT arg, or
7837 % empty for anchors.
7838 % 3) NAME-pg - the page number.
7839 %
7840 % This is called from \donoderef, \anchor, and \dofloat. In the case of
7841 % floats, there is an additional part, which is not written here:
7842 % 4) NAME-lof - the text as it should appear in a @listoffloats.
7843 %
7844 \def\setref#1#2{%
7845 \pdfmkdest{#1}%
7846 \iflinks
7847 {%
7848 \atdummies % preserve commands, but don't expand them
7849 \edef\writexrdef##1##2{%
7850 \write\auxfile{@xrdef{#1-% #1 of \setref, expanded by the \edef
7851 ##1}{##2}}% these are parameters of \writexrdef
7852 }%
7853 \toks0 = \expandafter{\lastsection}%
7854 \immediate \writexrdef{title}{\the\toks0 }%
7855 \immediate \writexrdef{snt}{\csname #2\endcsname}% \Ynumbered etc.
7856 \safewhatsit{\writexrdef{pg}{\folio}}% will be written later, at \shipout
7857 }%
7858 \fi
7859 }
7860
7861 % @xrefautosectiontitle on|off says whether @section(ing) names are used
7862 % automatically in xrefs, if the third arg is not explicitly specified.
7863 % This was provided as a "secret" @set xref-automatic-section-title
7864 % variable, now it's official.
7865 %
7866 \parseargdef\xrefautomaticsectiontitle{%
7867 \def\temp{#1}%
7868 \ifx\temp\onword
7869 \expandafter\let\csname SETxref-automatic-section-title\endcsname
7870 = \empty
7871 \else\ifx\temp\offword
7872 \expandafter\let\csname SETxref-automatic-section-title\endcsname
7873 = \relax
7874 \else
7875 \errhelp = \EMsimple
7876 \errmessage{Unknown @xrefautomaticsectiontitle value `\temp',
7877 must be on|off}%
7878 \fi\fi
7879 }
7880
7881 %
7882 % @xref, @pxref, and @ref generate cross-references. For \xrefX, #1 is
7883 % the node name, #2 the name of the Info cross-reference, #3 the printed
7884 % node name, #4 the name of the Info file, #5 the name of the printed
7885 % manual. All but the node name can be omitted.
7886 %
7887 \def\pxref#1{\putwordsee{} \xrefX[#1,,,,,,,]}
7888 \def\xref#1{\putwordSee{} \xrefX[#1,,,,,,,]}
7889 \def\ref#1{\xrefX[#1,,,,,,,]}
7890 %
7891 \newbox\toprefbox
7892 \newbox\printedrefnamebox
7893 \newbox\infofilenamebox
7894 \newbox\printedmanualbox
7895 %
7896 \def\xrefX[#1,#2,#3,#4,#5,#6]{\begingroup
7897 \unsepspaces
7898 %
7899 % Get args without leading/trailing spaces.
7900 \def\printedrefname{\ignorespaces #3}%
7901 \setbox\printedrefnamebox = \hbox{\printedrefname\unskip}%
7902 %
7903 \def\infofilename{\ignorespaces #4}%
7904 \setbox\infofilenamebox = \hbox{\infofilename\unskip}%
7905 %
7906 \def\printedmanual{\ignorespaces #5}%
7907 \setbox\printedmanualbox = \hbox{\printedmanual\unskip}%
7908 %
7909 % If the printed reference name (arg #3) was not explicitly given in
7910 % the @xref, figure out what we want to use.
7911 \ifdim \wd\printedrefnamebox = 0pt
7912 % No printed node name was explicitly given.
7913 \expandafter\ifx\csname SETxref-automatic-section-title\endcsname \relax
7914 % Not auto section-title: use node name inside the square brackets.
7915 \def\printedrefname{\ignorespaces #1}%
7916 \else
7917 % Auto section-title: use chapter/section title inside
7918 % the square brackets if we have it.
7919 \ifdim \wd\printedmanualbox > 0pt
7920 % It is in another manual, so we don't have it; use node name.
7921 \def\printedrefname{\ignorespaces #1}%
7922 \else
7923 \ifhavexrefs
7924 % We (should) know the real title if we have the xref values.
7925 \def\printedrefname{\refx{#1-title}{}}%
7926 \else
7927 % Otherwise just copy the Info node name.
7928 \def\printedrefname{\ignorespaces #1}%
7929 \fi%
7930 \fi
7931 \fi
7932 \fi
7933 %
7934 % Make link in pdf output.
7935 \ifpdf
7936 {\indexnofonts
7937 \turnoffactive
7938 \makevalueexpandable
7939 % This expands tokens, so do it after making catcode changes, so _
7940 % etc. don't get their TeX definitions. This ignores all spaces in
7941 % #4, including (wrongly) those in the middle of the filename.
7942 \getfilename{#4}%
7943 %
7944 % This (wrongly) does not take account of leading or trailing
7945 % spaces in #1, which should be ignored.
7946 \edef\pdfxrefdest{#1}%
7947 \ifx\pdfxrefdest\empty
7948 \def\pdfxrefdest{Top}% no empty targets
7949 \else
7950 \txiescapepdf\pdfxrefdest % escape PDF special chars
7951 \fi
7952 %
7953 \leavevmode
7954 \startlink attr{/Border [0 0 0]}%
7955 \ifnum\filenamelength>0
7956 goto file{\the\filename.pdf} name{\pdfxrefdest}%
7957 \else
7958 goto name{\pdfmkpgn{\pdfxrefdest}}%
7959 \fi
7960 }%
7961 \setcolor{\linkcolor}%
7962 \fi
7963 %
7964 % Float references are printed completely differently: "Figure 1.2"
7965 % instead of "[somenode], p.3". We distinguish them by the
7966 % LABEL-title being set to a magic string.
7967 {%
7968 % Have to otherify everything special to allow the \csname to
7969 % include an _ in the xref name, etc.
7970 \indexnofonts
7971 \turnoffactive
7972 \expandafter\global\expandafter\let\expandafter\Xthisreftitle
7973 \csname XR#1-title\endcsname
7974 }%
7975 \iffloat\Xthisreftitle
7976 % If the user specified the print name (third arg) to the ref,
7977 % print it instead of our usual "Figure 1.2".
7978 \ifdim\wd\printedrefnamebox = 0pt
7979 \refx{#1-snt}{}%
7980 \else
7981 \printedrefname
7982 \fi
7983 %
7984 % If the user also gave the printed manual name (fifth arg), append
7985 % "in MANUALNAME".
7986 \ifdim \wd\printedmanualbox > 0pt
7987 \space \putwordin{} \cite{\printedmanual}%
7988 \fi
7989 \else
7990 % node/anchor (non-float) references.
7991 %
7992 % If we use \unhbox to print the node names, TeX does not insert
7993 % empty discretionaries after hyphens, which means that it will not
7994 % find a line break at a hyphen in a node names. Since some manuals
7995 % are best written with fairly long node names, containing hyphens,
7996 % this is a loss. Therefore, we give the text of the node name
7997 % again, so it is as if TeX is seeing it for the first time.
7998 %
7999 \ifdim \wd\printedmanualbox > 0pt
8000 % Cross-manual reference with a printed manual name.
8001 %
8002 \crossmanualxref{\cite{\printedmanual\unskip}}%
8003 %
8004 \else\ifdim \wd\infofilenamebox > 0pt
8005 % Cross-manual reference with only an info filename (arg 4), no
8006 % printed manual name (arg 5). This is essentially the same as
8007 % the case above; we output the filename, since we have nothing else.
8008 %
8009 \crossmanualxref{\code{\infofilename\unskip}}%
8010 %
8011 \else
8012 % Reference within this manual.
8013 %
8014 % _ (for example) has to be the character _ for the purposes of the
8015 % control sequence corresponding to the node, but it has to expand
8016 % into the usual \leavevmode...\vrule stuff for purposes of
8017 % printing. So we \turnoffactive for the \refx-snt, back on for the
8018 % printing, back off for the \refx-pg.
8019 {\turnoffactive
8020 % Only output a following space if the -snt ref is nonempty; for
8021 % @unnumbered and @anchor, it won't be.
8022 \setbox2 = \hbox{\ignorespaces \refx{#1-snt}{}}%
8023 \ifdim \wd2 > 0pt \refx{#1-snt}\space\fi
8024 }%
8025 % output the `[mynode]' via the macro below so it can be overridden.
8026 \xrefprintnodename\printedrefname
8027 %
8028 % But we always want a comma and a space:
8029 ,\space
8030 %
8031 % output the `page 3'.
8032 \turnoffactive \putwordpage\tie\refx{#1-pg}{}%
8033 \fi\fi
8034 \fi
8035 \endlink
8036 \endgroup}
8037
8038 % Output a cross-manual xref to #1. Used just above (twice).
8039 %
8040 % Only include the text "Section ``foo'' in" if the foo is neither
8041 % missing or Top. Thus, @xref{,,,foo,The Foo Manual} outputs simply
8042 % "see The Foo Manual", the idea being to refer to the whole manual.
8043 %
8044 % But, this being TeX, we can't easily compare our node name against the
8045 % string "Top" while ignoring the possible spaces before and after in
8046 % the input. By adding the arbitrary 7sp below, we make it much less
8047 % likely that a real node name would have the same width as "Top" (e.g.,
8048 % in a monospaced font). Hopefully it will never happen in practice.
8049 %
8050 % For the same basic reason, we retypeset the "Top" at every
8051 % reference, since the current font is indeterminate.
8052 %
8053 \def\crossmanualxref#1{%
8054 \setbox\toprefbox = \hbox{Top\kern7sp}%
8055 \setbox2 = \hbox{\ignorespaces \printedrefname \unskip \kern7sp}%
8056 \ifdim \wd2 > 7sp % nonempty?
8057 \ifdim \wd2 = \wd\toprefbox \else % same as Top?
8058 \putwordSection{} ``\printedrefname'' \putwordin{}\space
8059 \fi
8060 \fi
8061 #1%
8062 }
8063
8064 % This macro is called from \xrefX for the `[nodename]' part of xref
8065 % output. It's a separate macro only so it can be changed more easily,
8066 % since square brackets don't work well in some documents. Particularly
8067 % one that Bob is working on :).
8068 %
8069 \def\xrefprintnodename#1{[#1]}
8070
8071 % Things referred to by \setref.
8072 %
8073 \def\Ynothing{}
8074 \def\Yomitfromtoc{}
8075 \def\Ynumbered{%
8076 \ifnum\secno=0
8077 \putwordChapter@tie \the\chapno
8078 \else \ifnum\subsecno=0
8079 \putwordSection@tie \the\chapno.\the\secno
8080 \else \ifnum\subsubsecno=0
8081 \putwordSection@tie \the\chapno.\the\secno.\the\subsecno
8082 \else
8083 \putwordSection@tie \the\chapno.\the\secno.\the\subsecno.\the\subsubsecno
8084 \fi\fi\fi
8085 }
8086 \def\Yappendix{%
8087 \ifnum\secno=0
8088 \putwordAppendix@tie @char\the\appendixno{}%
8089 \else \ifnum\subsecno=0
8090 \putwordSection@tie @char\the\appendixno.\the\secno
8091 \else \ifnum\subsubsecno=0
8092 \putwordSection@tie @char\the\appendixno.\the\secno.\the\subsecno
8093 \else
8094 \putwordSection@tie
8095 @char\the\appendixno.\the\secno.\the\subsecno.\the\subsubsecno
8096 \fi\fi\fi
8097 }
8098
8099 % Define \refx{NAME}{SUFFIX} to reference a cross-reference string named NAME.
8100 % If its value is nonempty, SUFFIX is output afterward.
8101 %
8102 \def\refx#1#2{%
8103 {%
8104 \indexnofonts
8105 \otherbackslash
8106 \expandafter\global\expandafter\let\expandafter\thisrefX
8107 \csname XR#1\endcsname
8108 }%
8109 \ifx\thisrefX\relax
8110 % If not defined, say something at least.
8111 \angleleft un\-de\-fined\angleright
8112 \iflinks
8113 \ifhavexrefs
8114 {\toks0 = {#1}% avoid expansion of possibly-complex value
8115 \message{\linenumber Undefined cross reference `\the\toks0'.}}%
8116 \else
8117 \ifwarnedxrefs\else
8118 \global\warnedxrefstrue
8119 \message{Cross reference values unknown; you must run TeX again.}%
8120 \fi
8121 \fi
8122 \fi
8123 \else
8124 % It's defined, so just use it.
8125 \thisrefX
8126 \fi
8127 #2% Output the suffix in any case.
8128 }
8129
8130 % This is the macro invoked by entries in the aux file. Usually it's
8131 % just a \def (we prepend XR to the control sequence name to avoid
8132 % collisions). But if this is a float type, we have more work to do.
8133 %
8134 \def\xrdef#1#2{%
8135 {% The node name might contain 8-bit characters, which in our current
8136 % implementation are changed to commands like @'e. Don't let these
8137 % mess up the control sequence name.
8138 \indexnofonts
8139 \turnoffactive
8140 \xdef\safexrefname{#1}%
8141 }%
8142 %
8143 \expandafter\gdef\csname XR\safexrefname\endcsname{#2}% remember this xref
8144 %
8145 % Was that xref control sequence that we just defined for a float?
8146 \expandafter\iffloat\csname XR\safexrefname\endcsname
8147 % it was a float, and we have the (safe) float type in \iffloattype.
8148 \expandafter\let\expandafter\floatlist
8149 \csname floatlist\iffloattype\endcsname
8150 %
8151 % Is this the first time we've seen this float type?
8152 \expandafter\ifx\floatlist\relax
8153 \toks0 = {\do}% yes, so just \do
8154 \else
8155 % had it before, so preserve previous elements in list.
8156 \toks0 = \expandafter{\floatlist\do}%
8157 \fi
8158 %
8159 % Remember this xref in the control sequence \floatlistFLOATTYPE,
8160 % for later use in \listoffloats.
8161 \expandafter\xdef\csname floatlist\iffloattype\endcsname{\the\toks0
8162 {\safexrefname}}%
8163 \fi
8164 }
8165
8166 % Read the last existing aux file, if any. No error if none exists.
8167 %
8168 \def\tryauxfile{%
8169 \openin 1 \jobname.aux
8170 \ifeof 1 \else
8171 \readdatafile{aux}%
8172 \global\havexrefstrue
8173 \fi
8174 \closein 1
8175 }
8176
8177 \def\setupdatafile{%
8178 \catcode`\^^@=\other
8179 \catcode`\^^A=\other
8180 \catcode`\^^B=\other
8181 \catcode`\^^C=\other
8182 \catcode`\^^D=\other
8183 \catcode`\^^E=\other
8184 \catcode`\^^F=\other
8185 \catcode`\^^G=\other
8186 \catcode`\^^H=\other
8187 \catcode`\^^K=\other
8188 \catcode`\^^L=\other
8189 \catcode`\^^N=\other
8190 \catcode`\^^P=\other
8191 \catcode`\^^Q=\other
8192 \catcode`\^^R=\other
8193 \catcode`\^^S=\other
8194 \catcode`\^^T=\other
8195 \catcode`\^^U=\other
8196 \catcode`\^^V=\other
8197 \catcode`\^^W=\other
8198 \catcode`\^^X=\other
8199 \catcode`\^^Z=\other
8200 \catcode`\^^[=\other
8201 \catcode`\^^\=\other
8202 \catcode`\^^]=\other
8203 \catcode`\^^^=\other
8204 \catcode`\^^_=\other
8205 % It was suggested to set the catcode of ^ to 7, which would allow ^^e4 etc.
8206 % in xref tags, i.e., node names. But since ^^e4 notation isn't
8207 % supported in the main text, it doesn't seem desirable. Furthermore,
8208 % that is not enough: for node names that actually contain a ^
8209 % character, we would end up writing a line like this: 'xrdef {'hat
8210 % b-title}{'hat b} and \xrdef does a \csname...\endcsname on the first
8211 % argument, and \hat is not an expandable control sequence. It could
8212 % all be worked out, but why? Either we support ^^ or we don't.
8213 %
8214 % The other change necessary for this was to define \auxhat:
8215 % \def\auxhat{\def^{'hat }}% extra space so ok if followed by letter
8216 % and then to call \auxhat in \setq.
8217 %
8218 \catcode`\^=\other
8219 %
8220 % Special characters. Should be turned off anyway, but...
8221 \catcode`\~=\other
8222 \catcode`\[=\other
8223 \catcode`\]=\other
8224 \catcode`\"=\other
8225 \catcode`\_=\other
8226 \catcode`\|=\other
8227 \catcode`\<=\other
8228 \catcode`\>=\other
8229 \catcode`\$=\other
8230 \catcode`\#=\other
8231 \catcode`\&=\other
8232 \catcode`\%=\other
8233 \catcode`+=\other % avoid \+ for paranoia even though we've turned it off
8234 %
8235 % This is to support \ in node names and titles, since the \
8236 % characters end up in a \csname. It's easier than
8237 % leaving it active and making its active definition an actual \
8238 % character. What I don't understand is why it works in the *value*
8239 % of the xrdef. Seems like it should be a catcode12 \, and that
8240 % should not typeset properly. But it works, so I'm moving on for
8241 % now. --karl, 15jan04.
8242 \catcode`\\=\other
8243 %
8244 % Make the characters 128-255 be printing characters.
8245 {%
8246 \count1=128
8247 \def\loop{%
8248 \catcode\count1=\other
8249 \advance\count1 by 1
8250 \ifnum \count1<256 \loop \fi
8251 }%
8252 }%
8253 %
8254 % @ is our escape character in .aux files, and we need braces.
8255 \catcode`\{=1
8256 \catcode`\}=2
8257 \catcode`\@=0
8258 }
8259
8260 \def\readdatafile#1{%
8261 \begingroup
8262 \setupdatafile
8263 \input\jobname.#1
8264 \endgroup}
8265
8266
8267 \message{insertions,}
8268 % including footnotes.
8269
8270 \newcount \footnoteno
8271
8272 % The trailing space in the following definition for supereject is
8273 % vital for proper filling; pages come out unaligned when you do a
8274 % pagealignmacro call if that space before the closing brace is
8275 % removed. (Generally, numeric constants should always be followed by a
8276 % space to prevent strange expansion errors.)
8277 \def\supereject{\par\penalty -20000\footnoteno =0 }
8278
8279 % @footnotestyle is meaningful for Info output only.
8280 \let\footnotestyle=\comment
8281
8282 {\catcode `\@=11
8283 %
8284 % Auto-number footnotes. Otherwise like plain.
8285 \gdef\footnote{%
8286 \let\indent=\ptexindent
8287 \let\noindent=\ptexnoindent
8288 \global\advance\footnoteno by \@ne
8289 \edef\thisfootno{$^{\the\footnoteno}$}%
8290 %
8291 % In case the footnote comes at the end of a sentence, preserve the
8292 % extra spacing after we do the footnote number.
8293 \let\@sf\empty
8294 \ifhmode\edef\@sf{\spacefactor\the\spacefactor}\ptexslash\fi
8295 %
8296 % Remove inadvertent blank space before typesetting the footnote number.
8297 \unskip
8298 \thisfootno\@sf
8299 \dofootnote
8300 }%
8301
8302 % Don't bother with the trickery in plain.tex to not require the
8303 % footnote text as a parameter. Our footnotes don't need to be so general.
8304 %
8305 % Oh yes, they do; otherwise, @ifset (and anything else that uses
8306 % \parseargline) fails inside footnotes because the tokens are fixed when
8307 % the footnote is read. --karl, 16nov96.
8308 %
8309 \gdef\dofootnote{%
8310 \insert\footins\bgroup
8311 % We want to typeset this text as a normal paragraph, even if the
8312 % footnote reference occurs in (for example) a display environment.
8313 % So reset some parameters.
8314 \hsize=\pagewidth
8315 \interlinepenalty\interfootnotelinepenalty
8316 \splittopskip\ht\strutbox % top baseline for broken footnotes
8317 \splitmaxdepth\dp\strutbox
8318 \floatingpenalty\@MM
8319 \leftskip\z@skip
8320 \rightskip\z@skip
8321 \spaceskip\z@skip
8322 \xspaceskip\z@skip
8323 \parindent\defaultparindent
8324 %
8325 \smallfonts \rm
8326 %
8327 % Because we use hanging indentation in footnotes, a @noindent appears
8328 % to exdent this text, so make it be a no-op. makeinfo does not use
8329 % hanging indentation so @noindent can still be needed within footnote
8330 % text after an @example or the like (not that this is good style).
8331 \let\noindent = \relax
8332 %
8333 % Hang the footnote text off the number. Use \everypar in case the
8334 % footnote extends for more than one paragraph.
8335 \everypar = {\hang}%
8336 \textindent{\thisfootno}%
8337 %
8338 % Don't crash into the line above the footnote text. Since this
8339 % expands into a box, it must come within the paragraph, lest it
8340 % provide a place where TeX can split the footnote.
8341 \footstrut
8342 %
8343 % Invoke rest of plain TeX footnote routine.
8344 \futurelet\next\fo@t
8345 }
8346 }%end \catcode `\@=11
8347
8348 % In case a @footnote appears in a vbox, save the footnote text and create
8349 % the real \insert just after the vbox finished. Otherwise, the insertion
8350 % would be lost.
8351 % Similarly, if a @footnote appears inside an alignment, save the footnote
8352 % text to a box and make the \insert when a row of the table is finished.
8353 % And the same can be done for other insert classes. --kasal, 16nov03.
8354
8355 % Replace the \insert primitive by a cheating macro.
8356 % Deeper inside, just make sure that the saved insertions are not spilled
8357 % out prematurely.
8358 %
8359 \def\startsavinginserts{%
8360 \ifx \insert\ptexinsert
8361 \let\insert\saveinsert
8362 \else
8363 \let\checkinserts\relax
8364 \fi
8365 }
8366
8367 % This \insert replacement works for both \insert\footins{foo} and
8368 % \insert\footins\bgroup foo\egroup, but it doesn't work for \insert27{foo}.
8369 %
8370 \def\saveinsert#1{%
8371 \edef\next{\noexpand\savetobox \makeSAVEname#1}%
8372 \afterassignment\next
8373 % swallow the left brace
8374 \let\temp =
8375 }
8376 \def\makeSAVEname#1{\makecsname{SAVE\expandafter\gobble\string#1}}
8377 \def\savetobox#1{\global\setbox#1 = \vbox\bgroup \unvbox#1}
8378
8379 \def\checksaveins#1{\ifvoid#1\else \placesaveins#1\fi}
8380
8381 \def\placesaveins#1{%
8382 \ptexinsert \csname\expandafter\gobblesave\string#1\endcsname
8383 {\box#1}%
8384 }
8385
8386 % eat @SAVE -- beware, all of them have catcode \other:
8387 {
8388 \def\dospecials{\do S\do A\do V\do E} \uncatcodespecials % ;-)
8389 \gdef\gobblesave @SAVE{}
8390 }
8391
8392 % initialization:
8393 \def\newsaveins #1{%
8394 \edef\next{\noexpand\newsaveinsX \makeSAVEname#1}%
8395 \next
8396 }
8397 \def\newsaveinsX #1{%
8398 \csname newbox\endcsname #1%
8399 \expandafter\def\expandafter\checkinserts\expandafter{\checkinserts
8400 \checksaveins #1}%
8401 }
8402
8403 % initialize:
8404 \let\checkinserts\empty
8405 \newsaveins\footins
8406 \newsaveins\margin
8407
8408
8409 % @image. We use the macros from epsf.tex to support this.
8410 % If epsf.tex is not installed and @image is used, we complain.
8411 %
8412 % Check for and read epsf.tex up front. If we read it only at @image
8413 % time, we might be inside a group, and then its definitions would get
8414 % undone and the next image would fail.
8415 \openin 1 = epsf.tex
8416 \ifeof 1 \else
8417 % Do not bother showing banner with epsf.tex v2.7k (available in
8418 % doc/epsf.tex and on ctan).
8419 \def\epsfannounce{\toks0 = }%
8420 \input epsf.tex
8421 \fi
8422 \closein 1
8423 %
8424 % We will only complain once about lack of epsf.tex.
8425 \newif\ifwarnednoepsf
8426 \newhelp\noepsfhelp{epsf.tex must be installed for images to
8427 work. It is also included in the Texinfo distribution, or you can get
8428 it from ftp://tug.org/tex/epsf.tex.}
8429 %
8430 \def\image#1{%
8431 \ifx\epsfbox\thisisundefined
8432 \ifwarnednoepsf \else
8433 \errhelp = \noepsfhelp
8434 \errmessage{epsf.tex not found, images will be ignored}%
8435 \global\warnednoepsftrue
8436 \fi
8437 \else
8438 \imagexxx #1,,,,,\finish
8439 \fi
8440 }
8441 %
8442 % Arguments to @image:
8443 % #1 is (mandatory) image filename; we tack on .eps extension.
8444 % #2 is (optional) width, #3 is (optional) height.
8445 % #4 is (ignored optional) html alt text.
8446 % #5 is (ignored optional) extension.
8447 % #6 is just the usual extra ignored arg for parsing stuff.
8448 \newif\ifimagevmode
8449 \def\imagexxx#1,#2,#3,#4,#5,#6\finish{\begingroup
8450 \catcode`\^^M = 5 % in case we're inside an example
8451 \normalturnoffactive % allow _ et al. in names
8452 % If the image is by itself, center it.
8453 \ifvmode
8454 \imagevmodetrue
8455 \else \ifx\centersub\centerV
8456 % for @center @image, we need a vbox so we can have our vertical space
8457 \imagevmodetrue
8458 \vbox\bgroup % vbox has better behavior than vtop herev
8459 \fi\fi
8460 %
8461 \ifimagevmode
8462 \nobreak\medskip
8463 % Usually we'll have text after the image which will insert
8464 % \parskip glue, so insert it here too to equalize the space
8465 % above and below.
8466 \nobreak\vskip\parskip
8467 \nobreak
8468 \fi
8469 %
8470 % Leave vertical mode so that indentation from an enclosing
8471 % environment such as @quotation is respected.
8472 % However, if we're at the top level, we don't want the
8473 % normal paragraph indentation.
8474 % On the other hand, if we are in the case of @center @image, we don't
8475 % want to start a paragraph, which will create a hsize-width box and
8476 % eradicate the centering.
8477 \ifx\centersub\centerV\else \noindent \fi
8478 %
8479 % Output the image.
8480 \ifpdf
8481 \dopdfimage{#1}{#2}{#3}%
8482 \else
8483 % \epsfbox itself resets \epsf?size at each figure.
8484 \setbox0 = \hbox{\ignorespaces #2}\ifdim\wd0 > 0pt \epsfxsize=#2\relax \fi
8485 \setbox0 = \hbox{\ignorespaces #3}\ifdim\wd0 > 0pt \epsfysize=#3\relax \fi
8486 \epsfbox{#1.eps}%
8487 \fi
8488 %
8489 \ifimagevmode
8490 \medskip % space after a standalone image
8491 \fi
8492 \ifx\centersub\centerV \egroup \fi
8493 \endgroup}
8494
8495
8496 % @float FLOATTYPE,LABEL,LOC ... @end float for displayed figures, tables,
8497 % etc. We don't actually implement floating yet, we always include the
8498 % float "here". But it seemed the best name for the future.
8499 %
8500 \envparseargdef\float{\eatcommaspace\eatcommaspace\dofloat#1, , ,\finish}
8501
8502 % There may be a space before second and/or third parameter; delete it.
8503 \def\eatcommaspace#1, {#1,}
8504
8505 % #1 is the optional FLOATTYPE, the text label for this float, typically
8506 % "Figure", "Table", "Example", etc. Can't contain commas. If omitted,
8507 % this float will not be numbered and cannot be referred to.
8508 %
8509 % #2 is the optional xref label. Also must be present for the float to
8510 % be referable.
8511 %
8512 % #3 is the optional positioning argument; for now, it is ignored. It
8513 % will somehow specify the positions allowed to float to (here, top, bottom).
8514 %
8515 % We keep a separate counter for each FLOATTYPE, which we reset at each
8516 % chapter-level command.
8517 \let\resetallfloatnos=\empty
8518 %
8519 \def\dofloat#1,#2,#3,#4\finish{%
8520 \let\thiscaption=\empty
8521 \let\thisshortcaption=\empty
8522 %
8523 % don't lose footnotes inside @float.
8524 %
8525 % BEWARE: when the floats start float, we have to issue warning whenever an
8526 % insert appears inside a float which could possibly float. --kasal, 26may04
8527 %
8528 \startsavinginserts
8529 %
8530 % We can't be used inside a paragraph.
8531 \par
8532 %
8533 \vtop\bgroup
8534 \def\floattype{#1}%
8535 \def\floatlabel{#2}%
8536 \def\floatloc{#3}% we do nothing with this yet.
8537 %
8538 \ifx\floattype\empty
8539 \let\safefloattype=\empty
8540 \else
8541 {%
8542 % the floattype might have accents or other special characters,
8543 % but we need to use it in a control sequence name.
8544 \indexnofonts
8545 \turnoffactive
8546 \xdef\safefloattype{\floattype}%
8547 }%
8548 \fi
8549 %
8550 % If label is given but no type, we handle that as the empty type.
8551 \ifx\floatlabel\empty \else
8552 % We want each FLOATTYPE to be numbered separately (Figure 1,
8553 % Table 1, Figure 2, ...). (And if no label, no number.)
8554 %
8555 \expandafter\getfloatno\csname\safefloattype floatno\endcsname
8556 \global\advance\floatno by 1
8557 %
8558 {%
8559 % This magic value for \lastsection is output by \setref as the
8560 % XREFLABEL-title value. \xrefX uses it to distinguish float
8561 % labels (which have a completely different output format) from
8562 % node and anchor labels. And \xrdef uses it to construct the
8563 % lists of floats.
8564 %
8565 \edef\lastsection{\floatmagic=\safefloattype}%
8566 \setref{\floatlabel}{Yfloat}%
8567 }%
8568 \fi
8569 %
8570 % start with \parskip glue, I guess.
8571 \vskip\parskip
8572 %
8573 % Don't suppress indentation if a float happens to start a section.
8574 \restorefirstparagraphindent
8575 }
8576
8577 % we have these possibilities:
8578 % @float Foo,lbl & @caption{Cap}: Foo 1.1: Cap
8579 % @float Foo,lbl & no caption: Foo 1.1
8580 % @float Foo & @caption{Cap}: Foo: Cap
8581 % @float Foo & no caption: Foo
8582 % @float ,lbl & Caption{Cap}: 1.1: Cap
8583 % @float ,lbl & no caption: 1.1
8584 % @float & @caption{Cap}: Cap
8585 % @float & no caption:
8586 %
8587 \def\Efloat{%
8588 \let\floatident = \empty
8589 %
8590 % In all cases, if we have a float type, it comes first.
8591 \ifx\floattype\empty \else \def\floatident{\floattype}\fi
8592 %
8593 % If we have an xref label, the number comes next.
8594 \ifx\floatlabel\empty \else
8595 \ifx\floattype\empty \else % if also had float type, need tie first.
8596 \appendtomacro\floatident{\tie}%
8597 \fi
8598 % the number.
8599 \appendtomacro\floatident{\chaplevelprefix\the\floatno}%
8600 \fi
8601 %
8602 % Start the printed caption with what we've constructed in
8603 % \floatident, but keep it separate; we need \floatident again.
8604 \let\captionline = \floatident
8605 %
8606 \ifx\thiscaption\empty \else
8607 \ifx\floatident\empty \else
8608 \appendtomacro\captionline{: }% had ident, so need a colon between
8609 \fi
8610 %
8611 % caption text.
8612 \appendtomacro\captionline{\scanexp\thiscaption}%
8613 \fi
8614 %
8615 % If we have anything to print, print it, with space before.
8616 % Eventually this needs to become an \insert.
8617 \ifx\captionline\empty \else
8618 \vskip.5\parskip
8619 \captionline
8620 %
8621 % Space below caption.
8622 \vskip\parskip
8623 \fi
8624 %
8625 % If have an xref label, write the list of floats info. Do this
8626 % after the caption, to avoid chance of it being a breakpoint.
8627 \ifx\floatlabel\empty \else
8628 % Write the text that goes in the lof to the aux file as
8629 % \floatlabel-lof. Besides \floatident, we include the short
8630 % caption if specified, else the full caption if specified, else nothing.
8631 {%
8632 \atdummies
8633 %
8634 % since we read the caption text in the macro world, where ^^M
8635 % is turned into a normal character, we have to scan it back, so
8636 % we don't write the literal three characters "^^M" into the aux file.
8637 \scanexp{%
8638 \xdef\noexpand\gtemp{%
8639 \ifx\thisshortcaption\empty
8640 \thiscaption
8641 \else
8642 \thisshortcaption
8643 \fi
8644 }%
8645 }%
8646 \immediate\write\auxfile{@xrdef{\floatlabel-lof}{\floatident
8647 \ifx\gtemp\empty \else : \gtemp \fi}}%
8648 }%
8649 \fi
8650 \egroup % end of \vtop
8651 %
8652 % place the captured inserts
8653 %
8654 % BEWARE: when the floats start floating, we have to issue warning
8655 % whenever an insert appears inside a float which could possibly
8656 % float. --kasal, 26may04
8657 %
8658 \checkinserts
8659 }
8660
8661 % Append the tokens #2 to the definition of macro #1, not expanding either.
8662 %
8663 \def\appendtomacro#1#2{%
8664 \expandafter\def\expandafter#1\expandafter{#1#2}%
8665 }
8666
8667 % @caption, @shortcaption
8668 %
8669 \def\caption{\docaption\thiscaption}
8670 \def\shortcaption{\docaption\thisshortcaption}
8671 \def\docaption{\checkenv\float \bgroup\scanargctxt\defcaption}
8672 \def\defcaption#1#2{\egroup \def#1{#2}}
8673
8674 % The parameter is the control sequence identifying the counter we are
8675 % going to use. Create it if it doesn't exist and assign it to \floatno.
8676 \def\getfloatno#1{%
8677 \ifx#1\relax
8678 % Haven't seen this figure type before.
8679 \csname newcount\endcsname #1%
8680 %
8681 % Remember to reset this floatno at the next chap.
8682 \expandafter\gdef\expandafter\resetallfloatnos
8683 \expandafter{\resetallfloatnos #1=0 }%
8684 \fi
8685 \let\floatno#1%
8686 }
8687
8688 % \setref calls this to get the XREFLABEL-snt value. We want an @xref
8689 % to the FLOATLABEL to expand to "Figure 3.1". We call \setref when we
8690 % first read the @float command.
8691 %
8692 \def\Yfloat{\floattype@tie \chaplevelprefix\the\floatno}%
8693
8694 % Magic string used for the XREFLABEL-title value, so \xrefX can
8695 % distinguish floats from other xref types.
8696 \def\floatmagic{!!float!!}
8697
8698 % #1 is the control sequence we are passed; we expand into a conditional
8699 % which is true if #1 represents a float ref. That is, the magic
8700 % \lastsection value which we \setref above.
8701 %
8702 \def\iffloat#1{\expandafter\doiffloat#1==\finish}
8703 %
8704 % #1 is (maybe) the \floatmagic string. If so, #2 will be the
8705 % (safe) float type for this float. We set \iffloattype to #2.
8706 %
8707 \def\doiffloat#1=#2=#3\finish{%
8708 \def\temp{#1}%
8709 \def\iffloattype{#2}%
8710 \ifx\temp\floatmagic
8711 }
8712
8713 % @listoffloats FLOATTYPE - print a list of floats like a table of contents.
8714 %
8715 \parseargdef\listoffloats{%
8716 \def\floattype{#1}% floattype
8717 {%
8718 % the floattype might have accents or other special characters,
8719 % but we need to use it in a control sequence name.
8720 \indexnofonts
8721 \turnoffactive
8722 \xdef\safefloattype{\floattype}%
8723 }%
8724 %
8725 % \xrdef saves the floats as a \do-list in \floatlistSAFEFLOATTYPE.
8726 \expandafter\ifx\csname floatlist\safefloattype\endcsname \relax
8727 \ifhavexrefs
8728 % if the user said @listoffloats foo but never @float foo.
8729 \message{\linenumber No `\safefloattype' floats to list.}%
8730 \fi
8731 \else
8732 \begingroup
8733 \leftskip=\tocindent % indent these entries like a toc
8734 \let\do=\listoffloatsdo
8735 \csname floatlist\safefloattype\endcsname
8736 \endgroup
8737 \fi
8738 }
8739
8740 % This is called on each entry in a list of floats. We're passed the
8741 % xref label, in the form LABEL-title, which is how we save it in the
8742 % aux file. We strip off the -title and look up \XRLABEL-lof, which
8743 % has the text we're supposed to typeset here.
8744 %
8745 % Figures without xref labels will not be included in the list (since
8746 % they won't appear in the aux file).
8747 %
8748 \def\listoffloatsdo#1{\listoffloatsdoentry#1\finish}
8749 \def\listoffloatsdoentry#1-title\finish{{%
8750 % Can't fully expand XR#1-lof because it can contain anything. Just
8751 % pass the control sequence. On the other hand, XR#1-pg is just the
8752 % page number, and we want to fully expand that so we can get a link
8753 % in pdf output.
8754 \toksA = \expandafter{\csname XR#1-lof\endcsname}%
8755 %
8756 % use the same \entry macro we use to generate the TOC and index.
8757 \edef\writeentry{\noexpand\entry{\the\toksA}{\csname XR#1-pg\endcsname}}%
8758 \writeentry
8759 }}
8760
8761
8762 \message{localization,}
8763
8764 % For single-language documents, @documentlanguage is usually given very
8765 % early, just after @documentencoding. Single argument is the language
8766 % (de) or locale (de_DE) abbreviation.
8767 %
8768 {
8769 \catcode`\_ = \active
8770 \globaldefs=1
8771 \parseargdef\documentlanguage{\begingroup
8772 \let_=\normalunderscore % normal _ character for filenames
8773 \tex % read txi-??.tex file in plain TeX.
8774 % Read the file by the name they passed if it exists.
8775 \openin 1 txi-#1.tex
8776 \ifeof 1
8777 \documentlanguagetrywithoutunderscore{#1_\finish}%
8778 \else
8779 \globaldefs = 1 % everything in the txi-LL files needs to persist
8780 \input txi-#1.tex
8781 \fi
8782 \closein 1
8783 \endgroup % end raw TeX
8784 \endgroup}
8785 %
8786 % If they passed de_DE, and txi-de_DE.tex doesn't exist,
8787 % try txi-de.tex.
8788 %
8789 \gdef\documentlanguagetrywithoutunderscore#1_#2\finish{%
8790 \openin 1 txi-#1.tex
8791 \ifeof 1
8792 \errhelp = \nolanghelp
8793 \errmessage{Cannot read language file txi-#1.tex}%
8794 \else
8795 \globaldefs = 1 % everything in the txi-LL files needs to persist
8796 \input txi-#1.tex
8797 \fi
8798 \closein 1
8799 }
8800 }% end of special _ catcode
8801 %
8802 \newhelp\nolanghelp{The given language definition file cannot be found or
8803 is empty. Maybe you need to install it? Putting it in the current
8804 directory should work if nowhere else does.}
8805
8806 % This macro is called from txi-??.tex files; the first argument is the
8807 % \language name to set (without the "\lang@" prefix), the second and
8808 % third args are \{left,right}hyphenmin.
8809 %
8810 % The language names to pass are determined when the format is built.
8811 % See the etex.log file created at that time, e.g.,
8812 % /usr/local/texlive/2008/texmf-var/web2c/pdftex/etex.log.
8813 %
8814 % With TeX Live 2008, etex now includes hyphenation patterns for all
8815 % available languages. This means we can support hyphenation in
8816 % Texinfo, at least to some extent. (This still doesn't solve the
8817 % accented characters problem.)
8818 %
8819 \catcode`@=11
8820 \def\txisetlanguage#1#2#3{%
8821 % do not set the language if the name is undefined in the current TeX.
8822 \expandafter\ifx\csname lang@#1\endcsname \relax
8823 \message{no patterns for #1}%
8824 \else
8825 \global\language = \csname lang@#1\endcsname
8826 \fi
8827 % but there is no harm in adjusting the hyphenmin values regardless.
8828 \global\lefthyphenmin = #2\relax
8829 \global\righthyphenmin = #3\relax
8830 }
8831
8832 % Helpers for encodings.
8833 % Set the catcode of characters 128 through 255 to the specified number.
8834 %
8835 \def\setnonasciicharscatcode#1{%
8836 \count255=128
8837 \loop\ifnum\count255<256
8838 \global\catcode\count255=#1\relax
8839 \advance\count255 by 1
8840 \repeat
8841 }
8842
8843 \def\setnonasciicharscatcodenonglobal#1{%
8844 \count255=128
8845 \loop\ifnum\count255<256
8846 \catcode\count255=#1\relax
8847 \advance\count255 by 1
8848 \repeat
8849 }
8850
8851 % @documentencoding sets the definition of non-ASCII characters
8852 % according to the specified encoding.
8853 %
8854 \parseargdef\documentencoding{%
8855 % Encoding being declared for the document.
8856 \def\declaredencoding{\csname #1.enc\endcsname}%
8857 %
8858 % Supported encodings: names converted to tokens in order to be able
8859 % to compare them with \ifx.
8860 \def\ascii{\csname US-ASCII.enc\endcsname}%
8861 \def\latnine{\csname ISO-8859-15.enc\endcsname}%
8862 \def\latone{\csname ISO-8859-1.enc\endcsname}%
8863 \def\lattwo{\csname ISO-8859-2.enc\endcsname}%
8864 \def\utfeight{\csname UTF-8.enc\endcsname}%
8865 %
8866 \ifx \declaredencoding \ascii
8867 \asciichardefs
8868 %
8869 \else \ifx \declaredencoding \lattwo
8870 \setnonasciicharscatcode\active
8871 \lattwochardefs
8872 %
8873 \else \ifx \declaredencoding \latone
8874 \setnonasciicharscatcode\active
8875 \latonechardefs
8876 %
8877 \else \ifx \declaredencoding \latnine
8878 \setnonasciicharscatcode\active
8879 \latninechardefs
8880 %
8881 \else \ifx \declaredencoding \utfeight
8882 \setnonasciicharscatcode\active
8883 \utfeightchardefs
8884 %
8885 \else
8886 \message{Unknown document encoding #1, ignoring.}%
8887 %
8888 \fi % utfeight
8889 \fi % latnine
8890 \fi % latone
8891 \fi % lattwo
8892 \fi % ascii
8893 }
8894
8895 % A message to be logged when using a character that isn't available
8896 % the default font encoding (OT1).
8897 %
8898 \def\missingcharmsg#1{\message{Character missing in OT1 encoding: #1.}}
8899
8900 % Take account of \c (plain) vs. \, (Texinfo) difference.
8901 \def\cedilla#1{\ifx\c\ptexc\c{#1}\else\,{#1}\fi}
8902
8903 % First, make active non-ASCII characters in order for them to be
8904 % correctly categorized when TeX reads the replacement text of
8905 % macros containing the character definitions.
8906 \setnonasciicharscatcode\active
8907 %
8908 % Latin1 (ISO-8859-1) character definitions.
8909 \def\latonechardefs{%
8910 \gdef^^a0{\tie}
8911 \gdef^^a1{\exclamdown}
8912 \gdef^^a2{\missingcharmsg{CENT SIGN}}
8913 \gdef^^a3{{\pounds}}
8914 \gdef^^a4{\missingcharmsg{CURRENCY SIGN}}
8915 \gdef^^a5{\missingcharmsg{YEN SIGN}}
8916 \gdef^^a6{\missingcharmsg{BROKEN BAR}}
8917 \gdef^^a7{\S}
8918 \gdef^^a8{\"{}}
8919 \gdef^^a9{\copyright}
8920 \gdef^^aa{\ordf}
8921 \gdef^^ab{\guillemetleft}
8922 \gdef^^ac{$\lnot$}
8923 \gdef^^ad{\-}
8924 \gdef^^ae{\registeredsymbol}
8925 \gdef^^af{\={}}
8926 %
8927 \gdef^^b0{\textdegree}
8928 \gdef^^b1{$\pm$}
8929 \gdef^^b2{$^2$}
8930 \gdef^^b3{$^3$}
8931 \gdef^^b4{\'{}}
8932 \gdef^^b5{$\mu$}
8933 \gdef^^b6{\P}
8934 %
8935 \gdef^^b7{$^.$}
8936 \gdef^^b8{\cedilla\ }
8937 \gdef^^b9{$^1$}
8938 \gdef^^ba{\ordm}
8939 %
8940 \gdef^^bb{\guillemetright}
8941 \gdef^^bc{$1\over4$}
8942 \gdef^^bd{$1\over2$}
8943 \gdef^^be{$3\over4$}
8944 \gdef^^bf{\questiondown}
8945 %
8946 \gdef^^c0{\`A}
8947 \gdef^^c1{\'A}
8948 \gdef^^c2{\^A}
8949 \gdef^^c3{\~A}
8950 \gdef^^c4{\"A}
8951 \gdef^^c5{\ringaccent A}
8952 \gdef^^c6{\AE}
8953 \gdef^^c7{\cedilla C}
8954 \gdef^^c8{\`E}
8955 \gdef^^c9{\'E}
8956 \gdef^^ca{\^E}
8957 \gdef^^cb{\"E}
8958 \gdef^^cc{\`I}
8959 \gdef^^cd{\'I}
8960 \gdef^^ce{\^I}
8961 \gdef^^cf{\"I}
8962 %
8963 \gdef^^d0{\DH}
8964 \gdef^^d1{\~N}
8965 \gdef^^d2{\`O}
8966 \gdef^^d3{\'O}
8967 \gdef^^d4{\^O}
8968 \gdef^^d5{\~O}
8969 \gdef^^d6{\"O}
8970 \gdef^^d7{$\times$}
8971 \gdef^^d8{\O}
8972 \gdef^^d9{\`U}
8973 \gdef^^da{\'U}
8974 \gdef^^db{\^U}
8975 \gdef^^dc{\"U}
8976 \gdef^^dd{\'Y}
8977 \gdef^^de{\TH}
8978 \gdef^^df{\ss}
8979 %
8980 \gdef^^e0{\`a}
8981 \gdef^^e1{\'a}
8982 \gdef^^e2{\^a}
8983 \gdef^^e3{\~a}
8984 \gdef^^e4{\"a}
8985 \gdef^^e5{\ringaccent a}
8986 \gdef^^e6{\ae}
8987 \gdef^^e7{\cedilla c}
8988 \gdef^^e8{\`e}
8989 \gdef^^e9{\'e}
8990 \gdef^^ea{\^e}
8991 \gdef^^eb{\"e}
8992 \gdef^^ec{\`{\dotless i}}
8993 \gdef^^ed{\'{\dotless i}}
8994 \gdef^^ee{\^{\dotless i}}
8995 \gdef^^ef{\"{\dotless i}}
8996 %
8997 \gdef^^f0{\dh}
8998 \gdef^^f1{\~n}
8999 \gdef^^f2{\`o}
9000 \gdef^^f3{\'o}
9001 \gdef^^f4{\^o}
9002 \gdef^^f5{\~o}
9003 \gdef^^f6{\"o}
9004 \gdef^^f7{$\div$}
9005 \gdef^^f8{\o}
9006 \gdef^^f9{\`u}
9007 \gdef^^fa{\'u}
9008 \gdef^^fb{\^u}
9009 \gdef^^fc{\"u}
9010 \gdef^^fd{\'y}
9011 \gdef^^fe{\th}
9012 \gdef^^ff{\"y}
9013 }
9014
9015 % Latin9 (ISO-8859-15) encoding character definitions.
9016 \def\latninechardefs{%
9017 % Encoding is almost identical to Latin1.
9018 \latonechardefs
9019 %
9020 \gdef^^a4{\euro}
9021 \gdef^^a6{\v S}
9022 \gdef^^a8{\v s}
9023 \gdef^^b4{\v Z}
9024 \gdef^^b8{\v z}
9025 \gdef^^bc{\OE}
9026 \gdef^^bd{\oe}
9027 \gdef^^be{\"Y}
9028 }
9029
9030 % Latin2 (ISO-8859-2) character definitions.
9031 \def\lattwochardefs{%
9032 \gdef^^a0{\tie}
9033 \gdef^^a1{\ogonek{A}}
9034 \gdef^^a2{\u{}}
9035 \gdef^^a3{\L}
9036 \gdef^^a4{\missingcharmsg{CURRENCY SIGN}}
9037 \gdef^^a5{\v L}
9038 \gdef^^a6{\'S}
9039 \gdef^^a7{\S}
9040 \gdef^^a8{\"{}}
9041 \gdef^^a9{\v S}
9042 \gdef^^aa{\cedilla S}
9043 \gdef^^ab{\v T}
9044 \gdef^^ac{\'Z}
9045 \gdef^^ad{\-}
9046 \gdef^^ae{\v Z}
9047 \gdef^^af{\dotaccent Z}
9048 %
9049 \gdef^^b0{\textdegree}
9050 \gdef^^b1{\ogonek{a}}
9051 \gdef^^b2{\ogonek{ }}
9052 \gdef^^b3{\l}
9053 \gdef^^b4{\'{}}
9054 \gdef^^b5{\v l}
9055 \gdef^^b6{\'s}
9056 \gdef^^b7{\v{}}
9057 \gdef^^b8{\cedilla\ }
9058 \gdef^^b9{\v s}
9059 \gdef^^ba{\cedilla s}
9060 \gdef^^bb{\v t}
9061 \gdef^^bc{\'z}
9062 \gdef^^bd{\H{}}
9063 \gdef^^be{\v z}
9064 \gdef^^bf{\dotaccent z}
9065 %
9066 \gdef^^c0{\'R}
9067 \gdef^^c1{\'A}
9068 \gdef^^c2{\^A}
9069 \gdef^^c3{\u A}
9070 \gdef^^c4{\"A}
9071 \gdef^^c5{\'L}
9072 \gdef^^c6{\'C}
9073 \gdef^^c7{\cedilla C}
9074 \gdef^^c8{\v C}
9075 \gdef^^c9{\'E}
9076 \gdef^^ca{\ogonek{E}}
9077 \gdef^^cb{\"E}
9078 \gdef^^cc{\v E}
9079 \gdef^^cd{\'I}
9080 \gdef^^ce{\^I}
9081 \gdef^^cf{\v D}
9082 %
9083 \gdef^^d0{\DH}
9084 \gdef^^d1{\'N}
9085 \gdef^^d2{\v N}
9086 \gdef^^d3{\'O}
9087 \gdef^^d4{\^O}
9088 \gdef^^d5{\H O}
9089 \gdef^^d6{\"O}
9090 \gdef^^d7{$\times$}
9091 \gdef^^d8{\v R}
9092 \gdef^^d9{\ringaccent U}
9093 \gdef^^da{\'U}
9094 \gdef^^db{\H U}
9095 \gdef^^dc{\"U}
9096 \gdef^^dd{\'Y}
9097 \gdef^^de{\cedilla T}
9098 \gdef^^df{\ss}
9099 %
9100 \gdef^^e0{\'r}
9101 \gdef^^e1{\'a}
9102 \gdef^^e2{\^a}
9103 \gdef^^e3{\u a}
9104 \gdef^^e4{\"a}
9105 \gdef^^e5{\'l}
9106 \gdef^^e6{\'c}
9107 \gdef^^e7{\cedilla c}
9108 \gdef^^e8{\v c}
9109 \gdef^^e9{\'e}
9110 \gdef^^ea{\ogonek{e}}
9111 \gdef^^eb{\"e}
9112 \gdef^^ec{\v e}
9113 \gdef^^ed{\'{\dotless{i}}}
9114 \gdef^^ee{\^{\dotless{i}}}
9115 \gdef^^ef{\v d}
9116 %
9117 \gdef^^f0{\dh}
9118 \gdef^^f1{\'n}
9119 \gdef^^f2{\v n}
9120 \gdef^^f3{\'o}
9121 \gdef^^f4{\^o}
9122 \gdef^^f5{\H o}
9123 \gdef^^f6{\"o}
9124 \gdef^^f7{$\div$}
9125 \gdef^^f8{\v r}
9126 \gdef^^f9{\ringaccent u}
9127 \gdef^^fa{\'u}
9128 \gdef^^fb{\H u}
9129 \gdef^^fc{\"u}
9130 \gdef^^fd{\'y}
9131 \gdef^^fe{\cedilla t}
9132 \gdef^^ff{\dotaccent{}}
9133 }
9134
9135 % UTF-8 character definitions.
9136 %
9137 % This code to support UTF-8 is based on LaTeX's utf8.def, with some
9138 % changes for Texinfo conventions. It is included here under the GPL by
9139 % permission from Frank Mittelbach and the LaTeX team.
9140 %
9141 \newcount\countUTFx
9142 \newcount\countUTFy
9143 \newcount\countUTFz
9144
9145 \gdef\UTFviiiTwoOctets#1#2{\expandafter
9146 \UTFviiiDefined\csname u8:#1\string #2\endcsname}
9147 %
9148 \gdef\UTFviiiThreeOctets#1#2#3{\expandafter
9149 \UTFviiiDefined\csname u8:#1\string #2\string #3\endcsname}
9150 %
9151 \gdef\UTFviiiFourOctets#1#2#3#4{\expandafter
9152 \UTFviiiDefined\csname u8:#1\string #2\string #3\string #4\endcsname}
9153
9154 \gdef\UTFviiiDefined#1{%
9155 \ifx #1\relax
9156 \message{\linenumber Unicode char \string #1 not defined for Texinfo}%
9157 \else
9158 \expandafter #1%
9159 \fi
9160 }
9161
9162 \begingroup
9163 \catcode`\~13
9164 \catcode`\"12
9165
9166 \def\UTFviiiLoop{%
9167 \global\catcode\countUTFx\active
9168 \uccode`\~\countUTFx
9169 \uppercase\expandafter{\UTFviiiTmp}%
9170 \advance\countUTFx by 1
9171 \ifnum\countUTFx < \countUTFy
9172 \expandafter\UTFviiiLoop
9173 \fi}
9174
9175 \countUTFx = "C2
9176 \countUTFy = "E0
9177 \def\UTFviiiTmp{%
9178 \xdef~{\noexpand\UTFviiiTwoOctets\string~}}
9179 \UTFviiiLoop
9180
9181 \countUTFx = "E0
9182 \countUTFy = "F0
9183 \def\UTFviiiTmp{%
9184 \xdef~{\noexpand\UTFviiiThreeOctets\string~}}
9185 \UTFviiiLoop
9186
9187 \countUTFx = "F0
9188 \countUTFy = "F4
9189 \def\UTFviiiTmp{%
9190 \xdef~{\noexpand\UTFviiiFourOctets\string~}}
9191 \UTFviiiLoop
9192 \endgroup
9193
9194 \begingroup
9195 \catcode`\"=12
9196 \catcode`\<=12
9197 \catcode`\.=12
9198 \catcode`\,=12
9199 \catcode`\;=12
9200 \catcode`\!=12
9201 \catcode`\~=13
9202
9203 \gdef\DeclareUnicodeCharacter#1#2{%
9204 \countUTFz = "#1\relax
9205 %\wlog{\space\space defining Unicode char U+#1 (decimal \the\countUTFz)}%
9206 \begingroup
9207 \parseXMLCharref
9208 \def\UTFviiiTwoOctets##1##2{%
9209 \csname u8:##1\string ##2\endcsname}%
9210 \def\UTFviiiThreeOctets##1##2##3{%
9211 \csname u8:##1\string ##2\string ##3\endcsname}%
9212 \def\UTFviiiFourOctets##1##2##3##4{%
9213 \csname u8:##1\string ##2\string ##3\string ##4\endcsname}%
9214 \expandafter\expandafter\expandafter\expandafter
9215 \expandafter\expandafter\expandafter
9216 \gdef\UTFviiiTmp{#2}%
9217 \endgroup}
9218
9219 \gdef\parseXMLCharref{%
9220 \ifnum\countUTFz < "A0\relax
9221 \errhelp = \EMsimple
9222 \errmessage{Cannot define Unicode char value < 00A0}%
9223 \else\ifnum\countUTFz < "800\relax
9224 \parseUTFviiiA,%
9225 \parseUTFviiiB C\UTFviiiTwoOctets.,%
9226 \else\ifnum\countUTFz < "10000\relax
9227 \parseUTFviiiA;%
9228 \parseUTFviiiA,%
9229 \parseUTFviiiB E\UTFviiiThreeOctets.{,;}%
9230 \else
9231 \parseUTFviiiA;%
9232 \parseUTFviiiA,%
9233 \parseUTFviiiA!%
9234 \parseUTFviiiB F\UTFviiiFourOctets.{!,;}%
9235 \fi\fi\fi
9236 }
9237
9238 \gdef\parseUTFviiiA#1{%
9239 \countUTFx = \countUTFz
9240 \divide\countUTFz by 64
9241 \countUTFy = \countUTFz
9242 \multiply\countUTFz by 64
9243 \advance\countUTFx by -\countUTFz
9244 \advance\countUTFx by 128
9245 \uccode `#1\countUTFx
9246 \countUTFz = \countUTFy}
9247
9248 \gdef\parseUTFviiiB#1#2#3#4{%
9249 \advance\countUTFz by "#10\relax
9250 \uccode `#3\countUTFz
9251 \uppercase{\gdef\UTFviiiTmp{#2#3#4}}}
9252 \endgroup
9253
9254 \def\utfeightchardefs{%
9255 \DeclareUnicodeCharacter{00A0}{\tie}
9256 \DeclareUnicodeCharacter{00A1}{\exclamdown}
9257 \DeclareUnicodeCharacter{00A3}{\pounds}
9258 \DeclareUnicodeCharacter{00A8}{\"{ }}
9259 \DeclareUnicodeCharacter{00A9}{\copyright}
9260 \DeclareUnicodeCharacter{00AA}{\ordf}
9261 \DeclareUnicodeCharacter{00AB}{\guillemetleft}
9262 \DeclareUnicodeCharacter{00AD}{\-}
9263 \DeclareUnicodeCharacter{00AE}{\registeredsymbol}
9264 \DeclareUnicodeCharacter{00AF}{\={ }}
9265
9266 \DeclareUnicodeCharacter{00B0}{\ringaccent{ }}
9267 \DeclareUnicodeCharacter{00B4}{\'{ }}
9268 \DeclareUnicodeCharacter{00B8}{\cedilla{ }}
9269 \DeclareUnicodeCharacter{00BA}{\ordm}
9270 \DeclareUnicodeCharacter{00BB}{\guillemetright}
9271 \DeclareUnicodeCharacter{00BF}{\questiondown}
9272
9273 \DeclareUnicodeCharacter{00C0}{\`A}
9274 \DeclareUnicodeCharacter{00C1}{\'A}
9275 \DeclareUnicodeCharacter{00C2}{\^A}
9276 \DeclareUnicodeCharacter{00C3}{\~A}
9277 \DeclareUnicodeCharacter{00C4}{\"A}
9278 \DeclareUnicodeCharacter{00C5}{\AA}
9279 \DeclareUnicodeCharacter{00C6}{\AE}
9280 \DeclareUnicodeCharacter{00C7}{\cedilla{C}}
9281 \DeclareUnicodeCharacter{00C8}{\`E}
9282 \DeclareUnicodeCharacter{00C9}{\'E}
9283 \DeclareUnicodeCharacter{00CA}{\^E}
9284 \DeclareUnicodeCharacter{00CB}{\"E}
9285 \DeclareUnicodeCharacter{00CC}{\`I}
9286 \DeclareUnicodeCharacter{00CD}{\'I}
9287 \DeclareUnicodeCharacter{00CE}{\^I}
9288 \DeclareUnicodeCharacter{00CF}{\"I}
9289
9290 \DeclareUnicodeCharacter{00D0}{\DH}
9291 \DeclareUnicodeCharacter{00D1}{\~N}
9292 \DeclareUnicodeCharacter{00D2}{\`O}
9293 \DeclareUnicodeCharacter{00D3}{\'O}
9294 \DeclareUnicodeCharacter{00D4}{\^O}
9295 \DeclareUnicodeCharacter{00D5}{\~O}
9296 \DeclareUnicodeCharacter{00D6}{\"O}
9297 \DeclareUnicodeCharacter{00D8}{\O}
9298 \DeclareUnicodeCharacter{00D9}{\`U}
9299 \DeclareUnicodeCharacter{00DA}{\'U}
9300 \DeclareUnicodeCharacter{00DB}{\^U}
9301 \DeclareUnicodeCharacter{00DC}{\"U}
9302 \DeclareUnicodeCharacter{00DD}{\'Y}
9303 \DeclareUnicodeCharacter{00DE}{\TH}
9304 \DeclareUnicodeCharacter{00DF}{\ss}
9305
9306 \DeclareUnicodeCharacter{00E0}{\`a}
9307 \DeclareUnicodeCharacter{00E1}{\'a}
9308 \DeclareUnicodeCharacter{00E2}{\^a}
9309 \DeclareUnicodeCharacter{00E3}{\~a}
9310 \DeclareUnicodeCharacter{00E4}{\"a}
9311 \DeclareUnicodeCharacter{00E5}{\aa}
9312 \DeclareUnicodeCharacter{00E6}{\ae}
9313 \DeclareUnicodeCharacter{00E7}{\cedilla{c}}
9314 \DeclareUnicodeCharacter{00E8}{\`e}
9315 \DeclareUnicodeCharacter{00E9}{\'e}
9316 \DeclareUnicodeCharacter{00EA}{\^e}
9317 \DeclareUnicodeCharacter{00EB}{\"e}
9318 \DeclareUnicodeCharacter{00EC}{\`{\dotless{i}}}
9319 \DeclareUnicodeCharacter{00ED}{\'{\dotless{i}}}
9320 \DeclareUnicodeCharacter{00EE}{\^{\dotless{i}}}
9321 \DeclareUnicodeCharacter{00EF}{\"{\dotless{i}}}
9322
9323 \DeclareUnicodeCharacter{00F0}{\dh}
9324 \DeclareUnicodeCharacter{00F1}{\~n}
9325 \DeclareUnicodeCharacter{00F2}{\`o}
9326 \DeclareUnicodeCharacter{00F3}{\'o}
9327 \DeclareUnicodeCharacter{00F4}{\^o}
9328 \DeclareUnicodeCharacter{00F5}{\~o}
9329 \DeclareUnicodeCharacter{00F6}{\"o}
9330 \DeclareUnicodeCharacter{00F8}{\o}
9331 \DeclareUnicodeCharacter{00F9}{\`u}
9332 \DeclareUnicodeCharacter{00FA}{\'u}
9333 \DeclareUnicodeCharacter{00FB}{\^u}
9334 \DeclareUnicodeCharacter{00FC}{\"u}
9335 \DeclareUnicodeCharacter{00FD}{\'y}
9336 \DeclareUnicodeCharacter{00FE}{\th}
9337 \DeclareUnicodeCharacter{00FF}{\"y}
9338
9339 \DeclareUnicodeCharacter{0100}{\=A}
9340 \DeclareUnicodeCharacter{0101}{\=a}
9341 \DeclareUnicodeCharacter{0102}{\u{A}}
9342 \DeclareUnicodeCharacter{0103}{\u{a}}
9343 \DeclareUnicodeCharacter{0104}{\ogonek{A}}
9344 \DeclareUnicodeCharacter{0105}{\ogonek{a}}
9345 \DeclareUnicodeCharacter{0106}{\'C}
9346 \DeclareUnicodeCharacter{0107}{\'c}
9347 \DeclareUnicodeCharacter{0108}{\^C}
9348 \DeclareUnicodeCharacter{0109}{\^c}
9349 \DeclareUnicodeCharacter{0118}{\ogonek{E}}
9350 \DeclareUnicodeCharacter{0119}{\ogonek{e}}
9351 \DeclareUnicodeCharacter{010A}{\dotaccent{C}}
9352 \DeclareUnicodeCharacter{010B}{\dotaccent{c}}
9353 \DeclareUnicodeCharacter{010C}{\v{C}}
9354 \DeclareUnicodeCharacter{010D}{\v{c}}
9355 \DeclareUnicodeCharacter{010E}{\v{D}}
9356
9357 \DeclareUnicodeCharacter{0112}{\=E}
9358 \DeclareUnicodeCharacter{0113}{\=e}
9359 \DeclareUnicodeCharacter{0114}{\u{E}}
9360 \DeclareUnicodeCharacter{0115}{\u{e}}
9361 \DeclareUnicodeCharacter{0116}{\dotaccent{E}}
9362 \DeclareUnicodeCharacter{0117}{\dotaccent{e}}
9363 \DeclareUnicodeCharacter{011A}{\v{E}}
9364 \DeclareUnicodeCharacter{011B}{\v{e}}
9365 \DeclareUnicodeCharacter{011C}{\^G}
9366 \DeclareUnicodeCharacter{011D}{\^g}
9367 \DeclareUnicodeCharacter{011E}{\u{G}}
9368 \DeclareUnicodeCharacter{011F}{\u{g}}
9369
9370 \DeclareUnicodeCharacter{0120}{\dotaccent{G}}
9371 \DeclareUnicodeCharacter{0121}{\dotaccent{g}}
9372 \DeclareUnicodeCharacter{0124}{\^H}
9373 \DeclareUnicodeCharacter{0125}{\^h}
9374 \DeclareUnicodeCharacter{0128}{\~I}
9375 \DeclareUnicodeCharacter{0129}{\~{\dotless{i}}}
9376 \DeclareUnicodeCharacter{012A}{\=I}
9377 \DeclareUnicodeCharacter{012B}{\={\dotless{i}}}
9378 \DeclareUnicodeCharacter{012C}{\u{I}}
9379 \DeclareUnicodeCharacter{012D}{\u{\dotless{i}}}
9380
9381 \DeclareUnicodeCharacter{0130}{\dotaccent{I}}
9382 \DeclareUnicodeCharacter{0131}{\dotless{i}}
9383 \DeclareUnicodeCharacter{0132}{IJ}
9384 \DeclareUnicodeCharacter{0133}{ij}
9385 \DeclareUnicodeCharacter{0134}{\^J}
9386 \DeclareUnicodeCharacter{0135}{\^{\dotless{j}}}
9387 \DeclareUnicodeCharacter{0139}{\'L}
9388 \DeclareUnicodeCharacter{013A}{\'l}
9389
9390 \DeclareUnicodeCharacter{0141}{\L}
9391 \DeclareUnicodeCharacter{0142}{\l}
9392 \DeclareUnicodeCharacter{0143}{\'N}
9393 \DeclareUnicodeCharacter{0144}{\'n}
9394 \DeclareUnicodeCharacter{0147}{\v{N}}
9395 \DeclareUnicodeCharacter{0148}{\v{n}}
9396 \DeclareUnicodeCharacter{014C}{\=O}
9397 \DeclareUnicodeCharacter{014D}{\=o}
9398 \DeclareUnicodeCharacter{014E}{\u{O}}
9399 \DeclareUnicodeCharacter{014F}{\u{o}}
9400
9401 \DeclareUnicodeCharacter{0150}{\H{O}}
9402 \DeclareUnicodeCharacter{0151}{\H{o}}
9403 \DeclareUnicodeCharacter{0152}{\OE}
9404 \DeclareUnicodeCharacter{0153}{\oe}
9405 \DeclareUnicodeCharacter{0154}{\'R}
9406 \DeclareUnicodeCharacter{0155}{\'r}
9407 \DeclareUnicodeCharacter{0158}{\v{R}}
9408 \DeclareUnicodeCharacter{0159}{\v{r}}
9409 \DeclareUnicodeCharacter{015A}{\'S}
9410 \DeclareUnicodeCharacter{015B}{\'s}
9411 \DeclareUnicodeCharacter{015C}{\^S}
9412 \DeclareUnicodeCharacter{015D}{\^s}
9413 \DeclareUnicodeCharacter{015E}{\cedilla{S}}
9414 \DeclareUnicodeCharacter{015F}{\cedilla{s}}
9415
9416 \DeclareUnicodeCharacter{0160}{\v{S}}
9417 \DeclareUnicodeCharacter{0161}{\v{s}}
9418 \DeclareUnicodeCharacter{0162}{\cedilla{t}}
9419 \DeclareUnicodeCharacter{0163}{\cedilla{T}}
9420 \DeclareUnicodeCharacter{0164}{\v{T}}
9421
9422 \DeclareUnicodeCharacter{0168}{\~U}
9423 \DeclareUnicodeCharacter{0169}{\~u}
9424 \DeclareUnicodeCharacter{016A}{\=U}
9425 \DeclareUnicodeCharacter{016B}{\=u}
9426 \DeclareUnicodeCharacter{016C}{\u{U}}
9427 \DeclareUnicodeCharacter{016D}{\u{u}}
9428 \DeclareUnicodeCharacter{016E}{\ringaccent{U}}
9429 \DeclareUnicodeCharacter{016F}{\ringaccent{u}}
9430
9431 \DeclareUnicodeCharacter{0170}{\H{U}}
9432 \DeclareUnicodeCharacter{0171}{\H{u}}
9433 \DeclareUnicodeCharacter{0174}{\^W}
9434 \DeclareUnicodeCharacter{0175}{\^w}
9435 \DeclareUnicodeCharacter{0176}{\^Y}
9436 \DeclareUnicodeCharacter{0177}{\^y}
9437 \DeclareUnicodeCharacter{0178}{\"Y}
9438 \DeclareUnicodeCharacter{0179}{\'Z}
9439 \DeclareUnicodeCharacter{017A}{\'z}
9440 \DeclareUnicodeCharacter{017B}{\dotaccent{Z}}
9441 \DeclareUnicodeCharacter{017C}{\dotaccent{z}}
9442 \DeclareUnicodeCharacter{017D}{\v{Z}}
9443 \DeclareUnicodeCharacter{017E}{\v{z}}
9444
9445 \DeclareUnicodeCharacter{01C4}{D\v{Z}}
9446 \DeclareUnicodeCharacter{01C5}{D\v{z}}
9447 \DeclareUnicodeCharacter{01C6}{d\v{z}}
9448 \DeclareUnicodeCharacter{01C7}{LJ}
9449 \DeclareUnicodeCharacter{01C8}{Lj}
9450 \DeclareUnicodeCharacter{01C9}{lj}
9451 \DeclareUnicodeCharacter{01CA}{NJ}
9452 \DeclareUnicodeCharacter{01CB}{Nj}
9453 \DeclareUnicodeCharacter{01CC}{nj}
9454 \DeclareUnicodeCharacter{01CD}{\v{A}}
9455 \DeclareUnicodeCharacter{01CE}{\v{a}}
9456 \DeclareUnicodeCharacter{01CF}{\v{I}}
9457
9458 \DeclareUnicodeCharacter{01D0}{\v{\dotless{i}}}
9459 \DeclareUnicodeCharacter{01D1}{\v{O}}
9460 \DeclareUnicodeCharacter{01D2}{\v{o}}
9461 \DeclareUnicodeCharacter{01D3}{\v{U}}
9462 \DeclareUnicodeCharacter{01D4}{\v{u}}
9463
9464 \DeclareUnicodeCharacter{01E2}{\={\AE}}
9465 \DeclareUnicodeCharacter{01E3}{\={\ae}}
9466 \DeclareUnicodeCharacter{01E6}{\v{G}}
9467 \DeclareUnicodeCharacter{01E7}{\v{g}}
9468 \DeclareUnicodeCharacter{01E8}{\v{K}}
9469 \DeclareUnicodeCharacter{01E9}{\v{k}}
9470
9471 \DeclareUnicodeCharacter{01F0}{\v{\dotless{j}}}
9472 \DeclareUnicodeCharacter{01F1}{DZ}
9473 \DeclareUnicodeCharacter{01F2}{Dz}
9474 \DeclareUnicodeCharacter{01F3}{dz}
9475 \DeclareUnicodeCharacter{01F4}{\'G}
9476 \DeclareUnicodeCharacter{01F5}{\'g}
9477 \DeclareUnicodeCharacter{01F8}{\`N}
9478 \DeclareUnicodeCharacter{01F9}{\`n}
9479 \DeclareUnicodeCharacter{01FC}{\'{\AE}}
9480 \DeclareUnicodeCharacter{01FD}{\'{\ae}}
9481 \DeclareUnicodeCharacter{01FE}{\'{\O}}
9482 \DeclareUnicodeCharacter{01FF}{\'{\o}}
9483
9484 \DeclareUnicodeCharacter{021E}{\v{H}}
9485 \DeclareUnicodeCharacter{021F}{\v{h}}
9486
9487 \DeclareUnicodeCharacter{0226}{\dotaccent{A}}
9488 \DeclareUnicodeCharacter{0227}{\dotaccent{a}}
9489 \DeclareUnicodeCharacter{0228}{\cedilla{E}}
9490 \DeclareUnicodeCharacter{0229}{\cedilla{e}}
9491 \DeclareUnicodeCharacter{022E}{\dotaccent{O}}
9492 \DeclareUnicodeCharacter{022F}{\dotaccent{o}}
9493
9494 \DeclareUnicodeCharacter{0232}{\=Y}
9495 \DeclareUnicodeCharacter{0233}{\=y}
9496 \DeclareUnicodeCharacter{0237}{\dotless{j}}
9497
9498 \DeclareUnicodeCharacter{02DB}{\ogonek{ }}
9499
9500 \DeclareUnicodeCharacter{1E02}{\dotaccent{B}}
9501 \DeclareUnicodeCharacter{1E03}{\dotaccent{b}}
9502 \DeclareUnicodeCharacter{1E04}{\udotaccent{B}}
9503 \DeclareUnicodeCharacter{1E05}{\udotaccent{b}}
9504 \DeclareUnicodeCharacter{1E06}{\ubaraccent{B}}
9505 \DeclareUnicodeCharacter{1E07}{\ubaraccent{b}}
9506 \DeclareUnicodeCharacter{1E0A}{\dotaccent{D}}
9507 \DeclareUnicodeCharacter{1E0B}{\dotaccent{d}}
9508 \DeclareUnicodeCharacter{1E0C}{\udotaccent{D}}
9509 \DeclareUnicodeCharacter{1E0D}{\udotaccent{d}}
9510 \DeclareUnicodeCharacter{1E0E}{\ubaraccent{D}}
9511 \DeclareUnicodeCharacter{1E0F}{\ubaraccent{d}}
9512
9513 \DeclareUnicodeCharacter{1E1E}{\dotaccent{F}}
9514 \DeclareUnicodeCharacter{1E1F}{\dotaccent{f}}
9515
9516 \DeclareUnicodeCharacter{1E20}{\=G}
9517 \DeclareUnicodeCharacter{1E21}{\=g}
9518 \DeclareUnicodeCharacter{1E22}{\dotaccent{H}}
9519 \DeclareUnicodeCharacter{1E23}{\dotaccent{h}}
9520 \DeclareUnicodeCharacter{1E24}{\udotaccent{H}}
9521 \DeclareUnicodeCharacter{1E25}{\udotaccent{h}}
9522 \DeclareUnicodeCharacter{1E26}{\"H}
9523 \DeclareUnicodeCharacter{1E27}{\"h}
9524
9525 \DeclareUnicodeCharacter{1E30}{\'K}
9526 \DeclareUnicodeCharacter{1E31}{\'k}
9527 \DeclareUnicodeCharacter{1E32}{\udotaccent{K}}
9528 \DeclareUnicodeCharacter{1E33}{\udotaccent{k}}
9529 \DeclareUnicodeCharacter{1E34}{\ubaraccent{K}}
9530 \DeclareUnicodeCharacter{1E35}{\ubaraccent{k}}
9531 \DeclareUnicodeCharacter{1E36}{\udotaccent{L}}
9532 \DeclareUnicodeCharacter{1E37}{\udotaccent{l}}
9533 \DeclareUnicodeCharacter{1E3A}{\ubaraccent{L}}
9534 \DeclareUnicodeCharacter{1E3B}{\ubaraccent{l}}
9535 \DeclareUnicodeCharacter{1E3E}{\'M}
9536 \DeclareUnicodeCharacter{1E3F}{\'m}
9537
9538 \DeclareUnicodeCharacter{1E40}{\dotaccent{M}}
9539 \DeclareUnicodeCharacter{1E41}{\dotaccent{m}}
9540 \DeclareUnicodeCharacter{1E42}{\udotaccent{M}}
9541 \DeclareUnicodeCharacter{1E43}{\udotaccent{m}}
9542 \DeclareUnicodeCharacter{1E44}{\dotaccent{N}}
9543 \DeclareUnicodeCharacter{1E45}{\dotaccent{n}}
9544 \DeclareUnicodeCharacter{1E46}{\udotaccent{N}}
9545 \DeclareUnicodeCharacter{1E47}{\udotaccent{n}}
9546 \DeclareUnicodeCharacter{1E48}{\ubaraccent{N}}
9547 \DeclareUnicodeCharacter{1E49}{\ubaraccent{n}}
9548
9549 \DeclareUnicodeCharacter{1E54}{\'P}
9550 \DeclareUnicodeCharacter{1E55}{\'p}
9551 \DeclareUnicodeCharacter{1E56}{\dotaccent{P}}
9552 \DeclareUnicodeCharacter{1E57}{\dotaccent{p}}
9553 \DeclareUnicodeCharacter{1E58}{\dotaccent{R}}
9554 \DeclareUnicodeCharacter{1E59}{\dotaccent{r}}
9555 \DeclareUnicodeCharacter{1E5A}{\udotaccent{R}}
9556 \DeclareUnicodeCharacter{1E5B}{\udotaccent{r}}
9557 \DeclareUnicodeCharacter{1E5E}{\ubaraccent{R}}
9558 \DeclareUnicodeCharacter{1E5F}{\ubaraccent{r}}
9559
9560 \DeclareUnicodeCharacter{1E60}{\dotaccent{S}}
9561 \DeclareUnicodeCharacter{1E61}{\dotaccent{s}}
9562 \DeclareUnicodeCharacter{1E62}{\udotaccent{S}}
9563 \DeclareUnicodeCharacter{1E63}{\udotaccent{s}}
9564 \DeclareUnicodeCharacter{1E6A}{\dotaccent{T}}
9565 \DeclareUnicodeCharacter{1E6B}{\dotaccent{t}}
9566 \DeclareUnicodeCharacter{1E6C}{\udotaccent{T}}
9567 \DeclareUnicodeCharacter{1E6D}{\udotaccent{t}}
9568 \DeclareUnicodeCharacter{1E6E}{\ubaraccent{T}}
9569 \DeclareUnicodeCharacter{1E6F}{\ubaraccent{t}}
9570
9571 \DeclareUnicodeCharacter{1E7C}{\~V}
9572 \DeclareUnicodeCharacter{1E7D}{\~v}
9573 \DeclareUnicodeCharacter{1E7E}{\udotaccent{V}}
9574 \DeclareUnicodeCharacter{1E7F}{\udotaccent{v}}
9575
9576 \DeclareUnicodeCharacter{1E80}{\`W}
9577 \DeclareUnicodeCharacter{1E81}{\`w}
9578 \DeclareUnicodeCharacter{1E82}{\'W}
9579 \DeclareUnicodeCharacter{1E83}{\'w}
9580 \DeclareUnicodeCharacter{1E84}{\"W}
9581 \DeclareUnicodeCharacter{1E85}{\"w}
9582 \DeclareUnicodeCharacter{1E86}{\dotaccent{W}}
9583 \DeclareUnicodeCharacter{1E87}{\dotaccent{w}}
9584 \DeclareUnicodeCharacter{1E88}{\udotaccent{W}}
9585 \DeclareUnicodeCharacter{1E89}{\udotaccent{w}}
9586 \DeclareUnicodeCharacter{1E8A}{\dotaccent{X}}
9587 \DeclareUnicodeCharacter{1E8B}{\dotaccent{x}}
9588 \DeclareUnicodeCharacter{1E8C}{\"X}
9589 \DeclareUnicodeCharacter{1E8D}{\"x}
9590 \DeclareUnicodeCharacter{1E8E}{\dotaccent{Y}}
9591 \DeclareUnicodeCharacter{1E8F}{\dotaccent{y}}
9592
9593 \DeclareUnicodeCharacter{1E90}{\^Z}
9594 \DeclareUnicodeCharacter{1E91}{\^z}
9595 \DeclareUnicodeCharacter{1E92}{\udotaccent{Z}}
9596 \DeclareUnicodeCharacter{1E93}{\udotaccent{z}}
9597 \DeclareUnicodeCharacter{1E94}{\ubaraccent{Z}}
9598 \DeclareUnicodeCharacter{1E95}{\ubaraccent{z}}
9599 \DeclareUnicodeCharacter{1E96}{\ubaraccent{h}}
9600 \DeclareUnicodeCharacter{1E97}{\"t}
9601 \DeclareUnicodeCharacter{1E98}{\ringaccent{w}}
9602 \DeclareUnicodeCharacter{1E99}{\ringaccent{y}}
9603
9604 \DeclareUnicodeCharacter{1EA0}{\udotaccent{A}}
9605 \DeclareUnicodeCharacter{1EA1}{\udotaccent{a}}
9606
9607 \DeclareUnicodeCharacter{1EB8}{\udotaccent{E}}
9608 \DeclareUnicodeCharacter{1EB9}{\udotaccent{e}}
9609 \DeclareUnicodeCharacter{1EBC}{\~E}
9610 \DeclareUnicodeCharacter{1EBD}{\~e}
9611
9612 \DeclareUnicodeCharacter{1ECA}{\udotaccent{I}}
9613 \DeclareUnicodeCharacter{1ECB}{\udotaccent{i}}
9614 \DeclareUnicodeCharacter{1ECC}{\udotaccent{O}}
9615 \DeclareUnicodeCharacter{1ECD}{\udotaccent{o}}
9616
9617 \DeclareUnicodeCharacter{1EE4}{\udotaccent{U}}
9618 \DeclareUnicodeCharacter{1EE5}{\udotaccent{u}}
9619
9620 \DeclareUnicodeCharacter{1EF2}{\`Y}
9621 \DeclareUnicodeCharacter{1EF3}{\`y}
9622 \DeclareUnicodeCharacter{1EF4}{\udotaccent{Y}}
9623
9624 \DeclareUnicodeCharacter{1EF8}{\~Y}
9625 \DeclareUnicodeCharacter{1EF9}{\~y}
9626
9627 \DeclareUnicodeCharacter{2013}{--}
9628 \DeclareUnicodeCharacter{2014}{---}
9629 \DeclareUnicodeCharacter{2018}{\quoteleft}
9630 \DeclareUnicodeCharacter{2019}{\quoteright}
9631 \DeclareUnicodeCharacter{201A}{\quotesinglbase}
9632 \DeclareUnicodeCharacter{201C}{\quotedblleft}
9633 \DeclareUnicodeCharacter{201D}{\quotedblright}
9634 \DeclareUnicodeCharacter{201E}{\quotedblbase}
9635 \DeclareUnicodeCharacter{2022}{\bullet}
9636 \DeclareUnicodeCharacter{2026}{\dots}
9637 \DeclareUnicodeCharacter{2039}{\guilsinglleft}
9638 \DeclareUnicodeCharacter{203A}{\guilsinglright}
9639 \DeclareUnicodeCharacter{20AC}{\euro}
9640
9641 \DeclareUnicodeCharacter{2192}{\expansion}
9642 \DeclareUnicodeCharacter{21D2}{\result}
9643
9644 \DeclareUnicodeCharacter{2212}{\minus}
9645 \DeclareUnicodeCharacter{2217}{\point}
9646 \DeclareUnicodeCharacter{2261}{\equiv}
9647 }% end of \utfeightchardefs
9648
9649
9650 % US-ASCII character definitions.
9651 \def\asciichardefs{% nothing need be done
9652 \relax
9653 }
9654
9655 % Make non-ASCII characters printable again for compatibility with
9656 % existing Texinfo documents that may use them, even without declaring a
9657 % document encoding.
9658 %
9659 \setnonasciicharscatcode \other
9660
9661
9662 \message{formatting,}
9663
9664 \newdimen\defaultparindent \defaultparindent = 15pt
9665
9666 \chapheadingskip = 15pt plus 4pt minus 2pt
9667 \secheadingskip = 12pt plus 3pt minus 2pt
9668 \subsecheadingskip = 9pt plus 2pt minus 2pt
9669
9670 % Prevent underfull vbox error messages.
9671 \vbadness = 10000
9672
9673 % Don't be very finicky about underfull hboxes, either.
9674 \hbadness = 6666
9675
9676 % Following George Bush, get rid of widows and orphans.
9677 \widowpenalty=10000
9678 \clubpenalty=10000
9679
9680 % Use TeX 3.0's \emergencystretch to help line breaking, but if we're
9681 % using an old version of TeX, don't do anything. We want the amount of
9682 % stretch added to depend on the line length, hence the dependence on
9683 % \hsize. We call this whenever the paper size is set.
9684 %
9685 \def\setemergencystretch{%
9686 \ifx\emergencystretch\thisisundefined
9687 % Allow us to assign to \emergencystretch anyway.
9688 \def\emergencystretch{\dimen0}%
9689 \else
9690 \emergencystretch = .15\hsize
9691 \fi
9692 }
9693
9694 % Parameters in order: 1) textheight; 2) textwidth;
9695 % 3) voffset; 4) hoffset; 5) binding offset; 6) topskip;
9696 % 7) physical page height; 8) physical page width.
9697 %
9698 % We also call \setleading{\textleading}, so the caller should define
9699 % \textleading. The caller should also set \parskip.
9700 %
9701 \def\internalpagesizes#1#2#3#4#5#6#7#8{%
9702 \voffset = #3\relax
9703 \topskip = #6\relax
9704 \splittopskip = \topskip
9705 %
9706 \vsize = #1\relax
9707 \advance\vsize by \topskip
9708 \outervsize = \vsize
9709 \advance\outervsize by 2\topandbottommargin
9710 \pageheight = \vsize
9711 %
9712 \hsize = #2\relax
9713 \outerhsize = \hsize
9714 \advance\outerhsize by 0.5in
9715 \pagewidth = \hsize
9716 %
9717 \normaloffset = #4\relax
9718 \bindingoffset = #5\relax
9719 %
9720 \ifpdf
9721 \pdfpageheight #7\relax
9722 \pdfpagewidth #8\relax
9723 % if we don't reset these, they will remain at "1 true in" of
9724 % whatever layout pdftex was dumped with.
9725 \pdfhorigin = 1 true in
9726 \pdfvorigin = 1 true in
9727 \fi
9728 %
9729 \setleading{\textleading}
9730 %
9731 \parindent = \defaultparindent
9732 \setemergencystretch
9733 }
9734
9735 % @letterpaper (the default).
9736 \def\letterpaper{{\globaldefs = 1
9737 \parskip = 3pt plus 2pt minus 1pt
9738 \textleading = 13.2pt
9739 %
9740 % If page is nothing but text, make it come out even.
9741 \internalpagesizes{607.2pt}{6in}% that's 46 lines
9742 {\voffset}{.25in}%
9743 {\bindingoffset}{36pt}%
9744 {11in}{8.5in}%
9745 }}
9746
9747 % Use @smallbook to reset parameters for 7x9.25 trim size.
9748 \def\smallbook{{\globaldefs = 1
9749 \parskip = 2pt plus 1pt
9750 \textleading = 12pt
9751 %
9752 \internalpagesizes{7.5in}{5in}%
9753 {-.2in}{0in}%
9754 {\bindingoffset}{16pt}%
9755 {9.25in}{7in}%
9756 %
9757 \lispnarrowing = 0.3in
9758 \tolerance = 700
9759 \hfuzz = 1pt
9760 \contentsrightmargin = 0pt
9761 \defbodyindent = .5cm
9762 }}
9763
9764 % Use @smallerbook to reset parameters for 6x9 trim size.
9765 % (Just testing, parameters still in flux.)
9766 \def\smallerbook{{\globaldefs = 1
9767 \parskip = 1.5pt plus 1pt
9768 \textleading = 12pt
9769 %
9770 \internalpagesizes{7.4in}{4.8in}%
9771 {-.2in}{-.4in}%
9772 {0pt}{14pt}%
9773 {9in}{6in}%
9774 %
9775 \lispnarrowing = 0.25in
9776 \tolerance = 700
9777 \hfuzz = 1pt
9778 \contentsrightmargin = 0pt
9779 \defbodyindent = .4cm
9780 }}
9781
9782 % Use @afourpaper to print on European A4 paper.
9783 \def\afourpaper{{\globaldefs = 1
9784 \parskip = 3pt plus 2pt minus 1pt
9785 \textleading = 13.2pt
9786 %
9787 % Double-side printing via postscript on Laserjet 4050
9788 % prints double-sided nicely when \bindingoffset=10mm and \hoffset=-6mm.
9789 % To change the settings for a different printer or situation, adjust
9790 % \normaloffset until the front-side and back-side texts align. Then
9791 % do the same for \bindingoffset. You can set these for testing in
9792 % your texinfo source file like this:
9793 % @tex
9794 % \global\normaloffset = -6mm
9795 % \global\bindingoffset = 10mm
9796 % @end tex
9797 \internalpagesizes{673.2pt}{160mm}% that's 51 lines
9798 {\voffset}{\hoffset}%
9799 {\bindingoffset}{44pt}%
9800 {297mm}{210mm}%
9801 %
9802 \tolerance = 700
9803 \hfuzz = 1pt
9804 \contentsrightmargin = 0pt
9805 \defbodyindent = 5mm
9806 }}
9807
9808 % Use @afivepaper to print on European A5 paper.
9809 % From romildo@urano.iceb.ufop.br, 2 July 2000.
9810 % He also recommends making @example and @lisp be small.
9811 \def\afivepaper{{\globaldefs = 1
9812 \parskip = 2pt plus 1pt minus 0.1pt
9813 \textleading = 12.5pt
9814 %
9815 \internalpagesizes{160mm}{120mm}%
9816 {\voffset}{\hoffset}%
9817 {\bindingoffset}{8pt}%
9818 {210mm}{148mm}%
9819 %
9820 \lispnarrowing = 0.2in
9821 \tolerance = 800
9822 \hfuzz = 1.2pt
9823 \contentsrightmargin = 0pt
9824 \defbodyindent = 2mm
9825 \tableindent = 12mm
9826 }}
9827
9828 % A specific text layout, 24x15cm overall, intended for A4 paper.
9829 \def\afourlatex{{\globaldefs = 1
9830 \afourpaper
9831 \internalpagesizes{237mm}{150mm}%
9832 {\voffset}{4.6mm}%
9833 {\bindingoffset}{7mm}%
9834 {297mm}{210mm}%
9835 %
9836 % Must explicitly reset to 0 because we call \afourpaper.
9837 \globaldefs = 0
9838 }}
9839
9840 % Use @afourwide to print on A4 paper in landscape format.
9841 \def\afourwide{{\globaldefs = 1
9842 \afourpaper
9843 \internalpagesizes{241mm}{165mm}%
9844 {\voffset}{-2.95mm}%
9845 {\bindingoffset}{7mm}%
9846 {297mm}{210mm}%
9847 \globaldefs = 0
9848 }}
9849
9850 % @pagesizes TEXTHEIGHT[,TEXTWIDTH]
9851 % Perhaps we should allow setting the margins, \topskip, \parskip,
9852 % and/or leading, also. Or perhaps we should compute them somehow.
9853 %
9854 \parseargdef\pagesizes{\pagesizesyyy #1,,\finish}
9855 \def\pagesizesyyy#1,#2,#3\finish{{%
9856 \setbox0 = \hbox{\ignorespaces #2}\ifdim\wd0 > 0pt \hsize=#2\relax \fi
9857 \globaldefs = 1
9858 %
9859 \parskip = 3pt plus 2pt minus 1pt
9860 \setleading{\textleading}%
9861 %
9862 \dimen0 = #1\relax
9863 \advance\dimen0 by \voffset
9864 %
9865 \dimen2 = \hsize
9866 \advance\dimen2 by \normaloffset
9867 %
9868 \internalpagesizes{#1}{\hsize}%
9869 {\voffset}{\normaloffset}%
9870 {\bindingoffset}{44pt}%
9871 {\dimen0}{\dimen2}%
9872 }}
9873
9874 % Set default to letter.
9875 %
9876 \letterpaper
9877
9878
9879 \message{and turning on texinfo input format.}
9880
9881 \def^^L{\par} % remove \outer, so ^L can appear in an @comment
9882
9883 % DEL is a comment character, in case @c does not suffice.
9884 \catcode`\^^? = 14
9885
9886 % Define macros to output various characters with catcode for normal text.
9887 \catcode`\"=\other \def\normaldoublequote{"}
9888 \catcode`\$=\other \def\normaldollar{$}%$ font-lock fix
9889 \catcode`\+=\other \def\normalplus{+}
9890 \catcode`\<=\other \def\normalless{<}
9891 \catcode`\>=\other \def\normalgreater{>}
9892 \catcode`\^=\other \def\normalcaret{^}
9893 \catcode`\_=\other \def\normalunderscore{_}
9894 \catcode`\|=\other \def\normalverticalbar{|}
9895 \catcode`\~=\other \def\normaltilde{~}
9896
9897 % This macro is used to make a character print one way in \tt
9898 % (where it can probably be output as-is), and another way in other fonts,
9899 % where something hairier probably needs to be done.
9900 %
9901 % #1 is what to print if we are indeed using \tt; #2 is what to print
9902 % otherwise. Since all the Computer Modern typewriter fonts have zero
9903 % interword stretch (and shrink), and it is reasonable to expect all
9904 % typewriter fonts to have this, we can check that font parameter.
9905 %
9906 \def\ifusingtt#1#2{\ifdim \fontdimen3\font=0pt #1\else #2\fi}
9907
9908 % Same as above, but check for italic font. Actually this also catches
9909 % non-italic slanted fonts since it is impossible to distinguish them from
9910 % italic fonts. But since this is only used by $ and it uses \sl anyway
9911 % this is not a problem.
9912 \def\ifusingit#1#2{\ifdim \fontdimen1\font>0pt #1\else #2\fi}
9913
9914 % Turn off all special characters except @
9915 % (and those which the user can use as if they were ordinary).
9916 % Most of these we simply print from the \tt font, but for some, we can
9917 % use math or other variants that look better in normal text.
9918
9919 \catcode`\"=\active
9920 \def\activedoublequote{{\tt\char34}}
9921 \let"=\activedoublequote
9922 \catcode`\~=\active
9923 \def~{{\tt\char126}}
9924 \chardef\hat=`\^
9925 \catcode`\^=\active
9926 \def^{{\tt \hat}}
9927
9928 \catcode`\_=\active
9929 \def_{\ifusingtt\normalunderscore\_}
9930 \let\realunder=_
9931 % Subroutine for the previous macro.
9932 \def\_{\leavevmode \kern.07em \vbox{\hrule width.3em height.1ex}\kern .07em }
9933
9934 \catcode`\|=\active
9935 \def|{{\tt\char124}}
9936 \chardef \less=`\<
9937 \catcode`\<=\active
9938 \def<{{\tt \less}}
9939 \chardef \gtr=`\>
9940 \catcode`\>=\active
9941 \def>{{\tt \gtr}}
9942 \catcode`\+=\active
9943 \def+{{\tt \char 43}}
9944 \catcode`\$=\active
9945 \def${\ifusingit{{\sl\$}}\normaldollar}%$ font-lock fix
9946
9947 % If a .fmt file is being used, characters that might appear in a file
9948 % name cannot be active until we have parsed the command line.
9949 % So turn them off again, and have \everyjob (or @setfilename) turn them on.
9950 % \otherifyactive is called near the end of this file.
9951 \def\otherifyactive{\catcode`+=\other \catcode`\_=\other}
9952
9953 % Used sometimes to turn off (effectively) the active characters even after
9954 % parsing them.
9955 \def\turnoffactive{%
9956 \normalturnoffactive
9957 \otherbackslash
9958 }
9959
9960 \catcode`\@=0
9961
9962 % \backslashcurfont outputs one backslash character in current font,
9963 % as in \char`\\.
9964 \global\chardef\backslashcurfont=`\\
9965 \global\let\rawbackslashxx=\backslashcurfont % let existing .??s files work
9966
9967 % \realbackslash is an actual character `\' with catcode other, and
9968 % \doublebackslash is two of them (for the pdf outlines).
9969 {\catcode`\\=\other @gdef@realbackslash{\} @gdef@doublebackslash{\\}}
9970
9971 % In texinfo, backslash is an active character; it prints the backslash
9972 % in fixed width font.
9973 \catcode`\\=\active % @ for escape char from now on.
9974
9975 % The story here is that in math mode, the \char of \backslashcurfont
9976 % ends up printing the roman \ from the math symbol font (because \char
9977 % in math mode uses the \mathcode, and plain.tex sets
9978 % \mathcode`\\="026E). It seems better for @backslashchar{} to always
9979 % print a typewriter backslash, hence we use an explicit \mathchar,
9980 % which is the decimal equivalent of "715c (class 7, e.g., use \fam;
9981 % ignored family value; char position "5C). We can't use " for the
9982 % usual hex value because it has already been made active.
9983 @def@normalbackslash{{@tt @ifmmode @mathchar29020 @else @backslashcurfont @fi}}
9984 @let@backslashchar = @normalbackslash % @backslashchar{} is for user documents.
9985
9986 % On startup, @fixbackslash assigns:
9987 % @let \ = @normalbackslash
9988 % \rawbackslash defines an active \ to do \backslashcurfont.
9989 % \otherbackslash defines an active \ to be a literal `\' character with
9990 % catcode other. We switch back and forth between these.
9991 @gdef@rawbackslash{@let\=@backslashcurfont}
9992 @gdef@otherbackslash{@let\=@realbackslash}
9993
9994 % Same as @turnoffactive except outputs \ as {\tt\char`\\} instead of
9995 % the literal character `\'. Also revert - to its normal character, in
9996 % case the active - from code has slipped in.
9997 %
9998 {@catcode`- = @active
9999 @gdef@normalturnoffactive{%
10000 @let-=@normaldash
10001 @let"=@normaldoublequote
10002 @let$=@normaldollar %$ font-lock fix
10003 @let+=@normalplus
10004 @let<=@normalless
10005 @let>=@normalgreater
10006 @let\=@normalbackslash
10007 @let^=@normalcaret
10008 @let_=@normalunderscore
10009 @let|=@normalverticalbar
10010 @let~=@normaltilde
10011 @markupsetuplqdefault
10012 @markupsetuprqdefault
10013 @unsepspaces
10014 }
10015 }
10016
10017 % Make _ and + \other characters, temporarily.
10018 % This is canceled by @fixbackslash.
10019 @otherifyactive
10020
10021 % If a .fmt file is being used, we don't want the `\input texinfo' to show up.
10022 % That is what \eatinput is for; after that, the `\' should revert to printing
10023 % a backslash.
10024 %
10025 @gdef@eatinput input texinfo{@fixbackslash}
10026 @global@let\ = @eatinput
10027
10028 % On the other hand, perhaps the file did not have a `\input texinfo'. Then
10029 % the first `\' in the file would cause an error. This macro tries to fix
10030 % that, assuming it is called before the first `\' could plausibly occur.
10031 % Also turn back on active characters that might appear in the input
10032 % file name, in case not using a pre-dumped format.
10033 %
10034 @gdef@fixbackslash{%
10035 @ifx\@eatinput @let\ = @normalbackslash @fi
10036 @catcode`+=@active
10037 @catcode`@_=@active
10038 }
10039
10040 % Say @foo, not \foo, in error messages.
10041 @escapechar = `@@
10042
10043 % These (along with & and #) are made active for url-breaking, so need
10044 % active definitions as the normal characters.
10045 @def@normaldot{.}
10046 @def@normalquest{?}
10047 @def@normalslash{/}
10048
10049 % These look ok in all fonts, so just make them not special.
10050 % @hashchar{} gets its own user-level command, because of #line.
10051 @catcode`@& = @other @def@normalamp{&}
10052 @catcode`@# = @other @def@normalhash{#}
10053 @catcode`@% = @other @def@normalpercent{%}
10054
10055 @let @hashchar = @normalhash
10056
10057 @c Finally, make ` and ' active, so that txicodequoteundirected and
10058 @c txicodequotebacktick work right in, e.g., @w{@code{`foo'}}. If we
10059 @c don't make ` and ' active, @code will not get them as active chars.
10060 @c Do this last of all since we use ` in the previous @catcode assignments.
10061 @catcode`@'=@active
10062 @catcode`@`=@active
10063 @markupsetuplqdefault
10064 @markupsetuprqdefault
10065
10066 @c Local variables:
10067 @c eval: (add-hook 'write-file-hooks 'time-stamp)
10068 @c page-delimiter: "^\\\\message"
10069 @c time-stamp-start: "def\\\\texinfoversion{"
10070 @c time-stamp-format: "%:y-%02m-%02d.%02H"
10071 @c time-stamp-end: "}"
10072 @c End:
10073
10074 @c vim:sw=2:
10075
10076 @ignore
10077 arch-tag: e1b36e32-c96e-4135-a41a-0b2efa2ea115
10078 @end ignore
0 /* conf/config.h.in. Generated from configure.ac by autoheader. */
1
2 /* GIT commit id revision used to build this package */
3 #undef BUILD_REVISION
4
5 /* The time this package was configured for a build */
6 #undef BUILD_TIMESTAMP
7
8 /* Defined if we are building with uiserver support. */
9 #undef ENABLE_UISERVER
10
11 /* Locate binaries only via this PATH */
12 #undef FIXED_SEARCH_PATH
13
14 /* Define to nothing if C supports flexible array members, and to 1 if it does
15 not. That way, with a declaration like `struct s { int n; double
16 d[FLEXIBLE_ARRAY_MEMBER]; };', the struct hack can be used with pre-C99
17 compilers. When computing the size of such an object, don't use 'sizeof
18 (struct s)' as it overestimates the size. Use 'offsetof (struct s, d)'
19 instead. Don't use 'offsetof (struct s, d[0])', as this doesn't work with
20 MSVC and with C++ compilers. */
21 #undef FLEXIBLE_ARRAY_MEMBER
22
23 /* version of the libassuan library */
24 #undef GPGME_LIBASSUAN_VERSION
25
26 /* The default error source for GPGME. */
27 #undef GPG_ERR_SOURCE_DEFAULT
28
29 /* Defined if we build for an Android system */
30 #undef HAVE_ANDROID_SYSTEM
31
32 /* Define to 1 if you have the <argp.h> header file. */
33 #undef HAVE_ARGP_H
34
35 /* Define if ttyname_r is does not work with small buffers */
36 #undef HAVE_BROKEN_TTYNAME_R
37
38 /* Define to 1 if you have the `closefrom' function. */
39 #undef HAVE_CLOSEFROM
40
41 /* define if the compiler supports basic C++11 syntax */
42 #undef HAVE_CXX11
43
44 /* Define to 1 if you have the declaration of `ttyname_r', and to 0 if you
45 don't. */
46 #undef HAVE_DECL_TTYNAME_R
47
48 /* Define to 1 if you have the <dlfcn.h> header file. */
49 #undef HAVE_DLFCN_H
50
51 /* Defined if we run on some of the PCDOS like systems (DOS, Windoze. OS/2)
52 with special properties like no file modes */
53 #undef HAVE_DOSISH_SYSTEM
54
55 /* Define to 1 if the system has the type `error_t'. */
56 #undef HAVE_ERROR_T
57
58 /* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
59 #undef HAVE_FSEEKO
60
61 /* Define to 1 if you have the `getegid' function. */
62 #undef HAVE_GETEGID
63
64 /* Define to 1 if you have the `getenv_r' function. */
65 #undef HAVE_GETENV_R
66
67 /* Define to 1 if you have the `getgid' function. */
68 #undef HAVE_GETGID
69
70 /* Define to 1 if you have the <inttypes.h> header file. */
71 #undef HAVE_INTTYPES_H
72
73 /* Define to 1 if you have the <locale.h> header file. */
74 #undef HAVE_LOCALE_H
75
76 /* Defined if we build for an MacOS system */
77 #undef HAVE_MACOS_SYSTEM
78
79 /* Define to 1 if you have the <memory.h> header file. */
80 #undef HAVE_MEMORY_H
81
82 /* Define to 1 if you have the <poll.h> header file. */
83 #undef HAVE_POLL_H
84
85 /* Define if the ttyname_r function has a POSIX compliant declaration. */
86 #undef HAVE_POSIXDECL_TTYNAME_R
87
88 /* Define to 1 if you have the `setenv' function. */
89 #undef HAVE_SETENV
90
91 /* Define to 1 if you have the `setlocale' function. */
92 #undef HAVE_SETLOCALE
93
94 /* Define to 1 if you have the <stdint.h> header file. */
95 #undef HAVE_STDINT_H
96
97 /* Define to 1 if you have the <stdlib.h> header file. */
98 #undef HAVE_STDLIB_H
99
100 /* Define to 1 if you have the `stpcpy' function. */
101 #undef HAVE_STPCPY
102
103 /* Define to 1 if you have the <strings.h> header file. */
104 #undef HAVE_STRINGS_H
105
106 /* Define to 1 if you have the <string.h> header file. */
107 #undef HAVE_STRING_H
108
109 /* Define to 1 if you have the <sys/select.h> header file. */
110 #undef HAVE_SYS_SELECT_H
111
112 /* Define to 1 if you have the <sys/stat.h> header file. */
113 #undef HAVE_SYS_STAT_H
114
115 /* Define to 1 if you have the <sys/time.h> header file. */
116 #undef HAVE_SYS_TIME_H
117
118 /* Define to 1 if you have the <sys/types.h> header file. */
119 #undef HAVE_SYS_TYPES_H
120
121 /* Define to 1 if you have the <sys/uio.h> header file. */
122 #undef HAVE_SYS_UIO_H
123
124 /* Define if getenv() is thread-safe */
125 #undef HAVE_THREAD_SAFE_GETENV
126
127 /* Define to 1 if you have the `timegm' function. */
128 #undef HAVE_TIMEGM
129
130 /* Define if __thread is supported */
131 #undef HAVE_TLS
132
133 /* Define to 1 if you have the `ttyname_r' function. */
134 #undef HAVE_TTYNAME_R
135
136 /* Define to 1 if the system has the type `uintptr_t'. */
137 #undef HAVE_UINTPTR_T
138
139 /* Define to 1 if you have the <unistd.h> header file. */
140 #undef HAVE_UNISTD_H
141
142 /* Defined if we run on any kind of W32 API based system */
143 #undef HAVE_W32_SYSTEM
144
145 /* Defined if we run on a 64 bit W32 API based system */
146 #undef HAVE_W64_SYSTEM
147
148 /* Define to the sub-directory in which libtool stores uninstalled libraries.
149 */
150 #undef LT_OBJDIR
151
152 /* Name of package */
153 #undef PACKAGE
154
155 /* Define to the address where bug reports for this package should be sent. */
156 #undef PACKAGE_BUGREPORT
157
158 /* Define to the full name of this package. */
159 #undef PACKAGE_NAME
160
161 /* Define to the full name and version of this package. */
162 #undef PACKAGE_STRING
163
164 /* Define to the one symbol short name of this package. */
165 #undef PACKAGE_TARNAME
166
167 /* Define to the home page for this package. */
168 #undef PACKAGE_URL
169
170 /* Define to the version of this package. */
171 #undef PACKAGE_VERSION
172
173 /* Define to 1 if ttyname_r is a replacement function. */
174 #undef REPLACE_TTYNAME_R
175
176
177 /* Separators as used in $PATH and file name. */
178 #ifdef HAVE_DOSISH_SYSTEM
179 #define PATHSEP_C ';'
180 #define DIRSEP_C '\\'
181 #define DIRSEP_S "\\"
182 #else
183 #define PATHSEP_C ':'
184 #define DIRSEP_C '/'
185 #define DIRSEP_S "/"
186 #endif
187
188
189 /* The size of `unsigned int', as computed by sizeof. */
190 #undef SIZEOF_UNSIGNED_INT
191
192 /* Define to 1 if you have the ANSI C header files. */
193 #undef STDC_HEADERS
194
195 /* Defined if descriptor passing is enabled and supported */
196 #undef USE_DESCRIPTOR_PASSING
197
198 /* Defined if SYS_getdents can be used on Linux */
199 #undef USE_LINUX_GETDENTS
200
201 /* Enable extensions on AIX 3, Interix. */
202 #ifndef _ALL_SOURCE
203 # undef _ALL_SOURCE
204 #endif
205 /* Enable GNU extensions on systems that have them. */
206 #ifndef _GNU_SOURCE
207 # undef _GNU_SOURCE
208 #endif
209 /* Enable threading extensions on Solaris. */
210 #ifndef _POSIX_PTHREAD_SEMANTICS
211 # undef _POSIX_PTHREAD_SEMANTICS
212 #endif
213 /* Enable extensions on HP NonStop. */
214 #ifndef _TANDEM_SOURCE
215 # undef _TANDEM_SOURCE
216 #endif
217 /* Enable general extensions on Solaris. */
218 #ifndef __EXTENSIONS__
219 # undef __EXTENSIONS__
220 #endif
221
222
223 /* Version number of package */
224 #undef VERSION
225
226 /* Expose all libc features (__DARWIN_C_FULL). */
227 #undef _DARWIN_C_SOURCE
228
229 /* Enable large inode numbers on Mac OS X 10.5. */
230 #ifndef _DARWIN_USE_64_BIT_INODE
231 # define _DARWIN_USE_64_BIT_INODE 1
232 #endif
233
234 /* Number of bits in a file offset, on hosts where this is settable. */
235 #undef _FILE_OFFSET_BITS
236
237 /* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
238 #undef _LARGEFILE_SOURCE
239
240 /* Define for large files, on AIX-style hosts. */
241 #undef _LARGE_FILES
242
243 /* Define to 1 if on MINIX. */
244 #undef _MINIX
245
246 /* Define to 2 if the system does not provide POSIX.1 features except with
247 this defined. */
248 #undef _POSIX_1_SOURCE
249
250 /* Define to 1 if you need to in order for `stat' and other things to work. */
251 #undef _POSIX_SOURCE
252
253 /* To allow the use of GPGME in multithreaded programs we have to use
254 special features from the library.
255 IMPORTANT: gpgme is not yet fully reentrant and you should use it
256 only from one thread. */
257 #ifndef _REENTRANT
258 # define _REENTRANT 1
259 #endif
260
261 /* Activate POSIX interface on MacOS X */
262 #undef _XOPEN_SOURCE
263
264 /* Define to a type to use for `error_t' if it is not otherwise available. */
265 #undef error_t
266
267 /* Define to `__inline__' or `__inline' if that's what the C compiler
268 calls it, or to nothing if 'inline' is not supported under any name. */
269 #ifndef __cplusplus
270 #undef inline
271 #endif
272
273 /* Define to `long int' if <sys/types.h> does not define. */
274 #undef off_t
275
276 /* Define to the type of an unsigned integer type wide enough to hold a
277 pointer, if such a type exists, and if the system does not define it. */
278 #undef uintptr_t
279
280
281 /* Definition of GCC specific attributes. */
282 #if __GNUC__ > 2
283 # define GPGME_GCC_A_PURE __attribute__ ((__pure__))
284 #else
285 # define GPGME_GCC_A_PURE
286 #endif
287
288 /* Under WindowsCE we need gpg-error's strerror macro. */
289 #define GPG_ERR_ENABLE_ERRNO_MACROS 1
290
291 #define CRIGHTBLURB "Copyright (C) 2000 Werner Koch\n" \
292 "Copyright (C) 2001--2021 g10 Code GmbH\n"
293
0 #! /bin/sh
1 # Guess values for system-dependent variables and create Makefiles.
2 # Generated by GNU Autoconf 2.69 for gpgme 1.17.0.
3 #
4 # Report bugs to <https://bugs.gnupg.org>.
5 #
6 #
7 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
8 #
9 #
10 # This configure script is free software; the Free Software Foundation
11 # gives unlimited permission to copy, distribute and modify it.
12 ## -------------------- ##
13 ## M4sh Initialization. ##
14 ## -------------------- ##
15
16 # Be more Bourne compatible
17 DUALCASE=1; export DUALCASE # for MKS sh
18 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
19 emulate sh
20 NULLCMD=:
21 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
22 # is contrary to our usage. Disable this feature.
23 alias -g '${1+"$@"}'='"$@"'
24 setopt NO_GLOB_SUBST
25 else
26 case `(set -o) 2>/dev/null` in #(
27 *posix*) :
28 set -o posix ;; #(
29 *) :
30 ;;
31 esac
32 fi
33
34
35 as_nl='
36 '
37 export as_nl
38 # Printing a long string crashes Solaris 7 /usr/bin/printf.
39 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
40 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
42 # Prefer a ksh shell builtin over an external printf program on Solaris,
43 # but without wasting forks for bash or zsh.
44 if test -z "$BASH_VERSION$ZSH_VERSION" \
45 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
46 as_echo='print -r --'
47 as_echo_n='print -rn --'
48 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
49 as_echo='printf %s\n'
50 as_echo_n='printf %s'
51 else
52 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
53 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
54 as_echo_n='/usr/ucb/echo -n'
55 else
56 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
57 as_echo_n_body='eval
58 arg=$1;
59 case $arg in #(
60 *"$as_nl"*)
61 expr "X$arg" : "X\\(.*\\)$as_nl";
62 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
63 esac;
64 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
65 '
66 export as_echo_n_body
67 as_echo_n='sh -c $as_echo_n_body as_echo'
68 fi
69 export as_echo_body
70 as_echo='sh -c $as_echo_body as_echo'
71 fi
72
73 # The user is always right.
74 if test "${PATH_SEPARATOR+set}" != set; then
75 PATH_SEPARATOR=:
76 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
77 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
78 PATH_SEPARATOR=';'
79 }
80 fi
81
82
83 # IFS
84 # We need space, tab and new line, in precisely that order. Quoting is
85 # there to prevent editors from complaining about space-tab.
86 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
87 # splitting by setting IFS to empty value.)
88 IFS=" "" $as_nl"
89
90 # Find who we are. Look in the path if we contain no directory separator.
91 as_myself=
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
96 do
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
102
103 ;;
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
109 fi
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
113 fi
114
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
126
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
132
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
136 # Use a proper internal environment variable to ensure we don't fall
137 # into an infinite loop, continuously re-executing ourselves.
138 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
139 _as_can_reexec=no; export _as_can_reexec;
140 # We cannot yet assume a decent shell, so we have to provide a
141 # neutralization value for shells without unset; and this also
142 # works around shells that cannot unset nonexistent variables.
143 # Preserve -v and -x to the replacement shell.
144 BASH_ENV=/dev/null
145 ENV=/dev/null
146 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
147 case $- in # ((((
148 *v*x* | *x*v* ) as_opts=-vx ;;
149 *v* ) as_opts=-v ;;
150 *x* ) as_opts=-x ;;
151 * ) as_opts= ;;
152 esac
153 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
154 # Admittedly, this is quite paranoid, since all the known shells bail
155 # out after a failed `exec'.
156 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
157 as_fn_exit 255
158 fi
159 # We don't want this to propagate to other subprocesses.
160 { _as_can_reexec=; unset _as_can_reexec;}
161 if test "x$CONFIG_SHELL" = x; then
162 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
163 emulate sh
164 NULLCMD=:
165 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
166 # is contrary to our usage. Disable this feature.
167 alias -g '\${1+\"\$@\"}'='\"\$@\"'
168 setopt NO_GLOB_SUBST
169 else
170 case \`(set -o) 2>/dev/null\` in #(
171 *posix*) :
172 set -o posix ;; #(
173 *) :
174 ;;
175 esac
176 fi
177 "
178 as_required="as_fn_return () { (exit \$1); }
179 as_fn_success () { as_fn_return 0; }
180 as_fn_failure () { as_fn_return 1; }
181 as_fn_ret_success () { return 0; }
182 as_fn_ret_failure () { return 1; }
183
184 exitcode=0
185 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
186 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
187 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
188 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
189 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
190
191 else
192 exitcode=1; echo positional parameters were not saved.
193 fi
194 test x\$exitcode = x0 || exit 1
195 test -x / || exit 1"
196 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
197 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
198 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
199 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
200 test \$(( 1 + 1 )) = 2 || exit 1
201
202 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
203 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
204 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
205 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
206 PATH=/empty FPATH=/empty; export PATH FPATH
207 test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
208 || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
209 if (eval "$as_required") 2>/dev/null; then :
210 as_have_required=yes
211 else
212 as_have_required=no
213 fi
214 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
215
216 else
217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
218 as_found=false
219 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
220 do
221 IFS=$as_save_IFS
222 test -z "$as_dir" && as_dir=.
223 as_found=:
224 case $as_dir in #(
225 /*)
226 for as_base in sh bash ksh sh5; do
227 # Try only shells that exist, to save several forks.
228 as_shell=$as_dir/$as_base
229 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
230 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
231 CONFIG_SHELL=$as_shell as_have_required=yes
232 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
233 break 2
234 fi
235 fi
236 done;;
237 esac
238 as_found=false
239 done
240 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
241 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
242 CONFIG_SHELL=$SHELL as_have_required=yes
243 fi; }
244 IFS=$as_save_IFS
245
246
247 if test "x$CONFIG_SHELL" != x; then :
248 export CONFIG_SHELL
249 # We cannot yet assume a decent shell, so we have to provide a
250 # neutralization value for shells without unset; and this also
251 # works around shells that cannot unset nonexistent variables.
252 # Preserve -v and -x to the replacement shell.
253 BASH_ENV=/dev/null
254 ENV=/dev/null
255 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
256 case $- in # ((((
257 *v*x* | *x*v* ) as_opts=-vx ;;
258 *v* ) as_opts=-v ;;
259 *x* ) as_opts=-x ;;
260 * ) as_opts= ;;
261 esac
262 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
263 # Admittedly, this is quite paranoid, since all the known shells bail
264 # out after a failed `exec'.
265 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
266 exit 255
267 fi
268
269 if test x$as_have_required = xno; then :
270 $as_echo "$0: This script requires a shell more modern than all"
271 $as_echo "$0: the shells that I found on your system."
272 if test x${ZSH_VERSION+set} = xset ; then
273 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
274 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
275 else
276 $as_echo "$0: Please tell bug-autoconf@gnu.org and
277 $0: https://bugs.gnupg.org about your system, including any
278 $0: error possibly output before this message. Then install
279 $0: a modern shell, or manually run the script under such a
280 $0: shell if you do have one."
281 fi
282 exit 1
283 fi
284 fi
285 fi
286 SHELL=${CONFIG_SHELL-/bin/sh}
287 export SHELL
288 # Unset more variables known to interfere with behavior of common tools.
289 CLICOLOR_FORCE= GREP_OPTIONS=
290 unset CLICOLOR_FORCE GREP_OPTIONS
291
292 ## --------------------- ##
293 ## M4sh Shell Functions. ##
294 ## --------------------- ##
295 # as_fn_unset VAR
296 # ---------------
297 # Portably unset VAR.
298 as_fn_unset ()
299 {
300 { eval $1=; unset $1;}
301 }
302 as_unset=as_fn_unset
303
304 # as_fn_set_status STATUS
305 # -----------------------
306 # Set $? to STATUS, without forking.
307 as_fn_set_status ()
308 {
309 return $1
310 } # as_fn_set_status
311
312 # as_fn_exit STATUS
313 # -----------------
314 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
315 as_fn_exit ()
316 {
317 set +e
318 as_fn_set_status $1
319 exit $1
320 } # as_fn_exit
321
322 # as_fn_mkdir_p
323 # -------------
324 # Create "$as_dir" as a directory, including parents if necessary.
325 as_fn_mkdir_p ()
326 {
327
328 case $as_dir in #(
329 -*) as_dir=./$as_dir;;
330 esac
331 test -d "$as_dir" || eval $as_mkdir_p || {
332 as_dirs=
333 while :; do
334 case $as_dir in #(
335 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
336 *) as_qdir=$as_dir;;
337 esac
338 as_dirs="'$as_qdir' $as_dirs"
339 as_dir=`$as_dirname -- "$as_dir" ||
340 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
341 X"$as_dir" : 'X\(//\)[^/]' \| \
342 X"$as_dir" : 'X\(//\)$' \| \
343 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
344 $as_echo X"$as_dir" |
345 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
346 s//\1/
347 q
348 }
349 /^X\(\/\/\)[^/].*/{
350 s//\1/
351 q
352 }
353 /^X\(\/\/\)$/{
354 s//\1/
355 q
356 }
357 /^X\(\/\).*/{
358 s//\1/
359 q
360 }
361 s/.*/./; q'`
362 test -d "$as_dir" && break
363 done
364 test -z "$as_dirs" || eval "mkdir $as_dirs"
365 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
366
367
368 } # as_fn_mkdir_p
369
370 # as_fn_executable_p FILE
371 # -----------------------
372 # Test if FILE is an executable regular file.
373 as_fn_executable_p ()
374 {
375 test -f "$1" && test -x "$1"
376 } # as_fn_executable_p
377 # as_fn_append VAR VALUE
378 # ----------------------
379 # Append the text in VALUE to the end of the definition contained in VAR. Take
380 # advantage of any shell optimizations that allow amortized linear growth over
381 # repeated appends, instead of the typical quadratic growth present in naive
382 # implementations.
383 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
384 eval 'as_fn_append ()
385 {
386 eval $1+=\$2
387 }'
388 else
389 as_fn_append ()
390 {
391 eval $1=\$$1\$2
392 }
393 fi # as_fn_append
394
395 # as_fn_arith ARG...
396 # ------------------
397 # Perform arithmetic evaluation on the ARGs, and store the result in the
398 # global $as_val. Take advantage of shells that can avoid forks. The arguments
399 # must be portable across $(()) and expr.
400 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
401 eval 'as_fn_arith ()
402 {
403 as_val=$(( $* ))
404 }'
405 else
406 as_fn_arith ()
407 {
408 as_val=`expr "$@" || test $? -eq 1`
409 }
410 fi # as_fn_arith
411
412
413 # as_fn_error STATUS ERROR [LINENO LOG_FD]
414 # ----------------------------------------
415 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
416 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
417 # script with STATUS, using 1 if that was 0.
418 as_fn_error ()
419 {
420 as_status=$1; test $as_status -eq 0 && as_status=1
421 if test "$4"; then
422 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
423 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
424 fi
425 $as_echo "$as_me: error: $2" >&2
426 as_fn_exit $as_status
427 } # as_fn_error
428
429 if expr a : '\(a\)' >/dev/null 2>&1 &&
430 test "X`expr 00001 : '.*\(...\)'`" = X001; then
431 as_expr=expr
432 else
433 as_expr=false
434 fi
435
436 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
437 as_basename=basename
438 else
439 as_basename=false
440 fi
441
442 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
443 as_dirname=dirname
444 else
445 as_dirname=false
446 fi
447
448 as_me=`$as_basename -- "$0" ||
449 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
450 X"$0" : 'X\(//\)$' \| \
451 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
452 $as_echo X/"$0" |
453 sed '/^.*\/\([^/][^/]*\)\/*$/{
454 s//\1/
455 q
456 }
457 /^X\/\(\/\/\)$/{
458 s//\1/
459 q
460 }
461 /^X\/\(\/\).*/{
462 s//\1/
463 q
464 }
465 s/.*/./; q'`
466
467 # Avoid depending upon Character Ranges.
468 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
469 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
470 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
471 as_cr_digits='0123456789'
472 as_cr_alnum=$as_cr_Letters$as_cr_digits
473
474
475 as_lineno_1=$LINENO as_lineno_1a=$LINENO
476 as_lineno_2=$LINENO as_lineno_2a=$LINENO
477 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
478 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
479 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
480 sed -n '
481 p
482 /[$]LINENO/=
483 ' <$as_myself |
484 sed '
485 s/[$]LINENO.*/&-/
486 t lineno
487 b
488 :lineno
489 N
490 :loop
491 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
492 t loop
493 s/-\n.*//
494 ' >$as_me.lineno &&
495 chmod +x "$as_me.lineno" ||
496 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
497
498 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
499 # already done that, so ensure we don't try to do so again and fall
500 # in an infinite loop. This has already happened in practice.
501 _as_can_reexec=no; export _as_can_reexec
502 # Don't try to exec as it changes $[0], causing all sort of problems
503 # (the dirname of $[0] is not the place where we might find the
504 # original and so on. Autoconf is especially sensitive to this).
505 . "./$as_me.lineno"
506 # Exit status is that of the last command.
507 exit
508 }
509
510 ECHO_C= ECHO_N= ECHO_T=
511 case `echo -n x` in #(((((
512 -n*)
513 case `echo 'xy\c'` in
514 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
515 xy) ECHO_C='\c';;
516 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
517 ECHO_T=' ';;
518 esac;;
519 *)
520 ECHO_N='-n';;
521 esac
522
523 rm -f conf$$ conf$$.exe conf$$.file
524 if test -d conf$$.dir; then
525 rm -f conf$$.dir/conf$$.file
526 else
527 rm -f conf$$.dir
528 mkdir conf$$.dir 2>/dev/null
529 fi
530 if (echo >conf$$.file) 2>/dev/null; then
531 if ln -s conf$$.file conf$$ 2>/dev/null; then
532 as_ln_s='ln -s'
533 # ... but there are two gotchas:
534 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
535 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
536 # In both cases, we have to default to `cp -pR'.
537 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
538 as_ln_s='cp -pR'
539 elif ln conf$$.file conf$$ 2>/dev/null; then
540 as_ln_s=ln
541 else
542 as_ln_s='cp -pR'
543 fi
544 else
545 as_ln_s='cp -pR'
546 fi
547 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
548 rmdir conf$$.dir 2>/dev/null
549
550 if mkdir -p . 2>/dev/null; then
551 as_mkdir_p='mkdir -p "$as_dir"'
552 else
553 test -d ./-p && rmdir ./-p
554 as_mkdir_p=false
555 fi
556
557 as_test_x='test -x'
558 as_executable_p=as_fn_executable_p
559
560 # Sed expression to map a string onto a valid CPP name.
561 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
562
563 # Sed expression to map a string onto a valid variable name.
564 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
565
566 SHELL=${CONFIG_SHELL-/bin/sh}
567
568
569 test -n "$DJDIR" || exec 7<&0 </dev/null
570 exec 6>&1
571
572 # Name of the host.
573 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
574 # so uname gets run too.
575 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
576
577 #
578 # Initializations.
579 #
580 ac_default_prefix=/usr/local
581 ac_clean_files=
582 ac_config_libobj_dir=.
583 LIBOBJS=
584 cross_compiling=no
585 subdirs=
586 MFLAGS=
587 MAKEFLAGS=
588
589 # Identity of this package.
590 PACKAGE_NAME='gpgme'
591 PACKAGE_TARNAME='gpgme'
592 PACKAGE_VERSION='1.17.0'
593 PACKAGE_STRING='gpgme 1.17.0'
594 PACKAGE_BUGREPORT='https://bugs.gnupg.org'
595 PACKAGE_URL=''
596
597 ac_unique_file="src/gpgme.h.in"
598 # Factoring default headers for most tests.
599 ac_includes_default="\
600 #include <stdio.h>
601 #ifdef HAVE_SYS_TYPES_H
602 # include <sys/types.h>
603 #endif
604 #ifdef HAVE_SYS_STAT_H
605 # include <sys/stat.h>
606 #endif
607 #ifdef STDC_HEADERS
608 # include <stdlib.h>
609 # include <stddef.h>
610 #else
611 # ifdef HAVE_STDLIB_H
612 # include <stdlib.h>
613 # endif
614 #endif
615 #ifdef HAVE_STRING_H
616 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
617 # include <memory.h>
618 # endif
619 # include <string.h>
620 #endif
621 #ifdef HAVE_STRINGS_H
622 # include <strings.h>
623 #endif
624 #ifdef HAVE_INTTYPES_H
625 # include <inttypes.h>
626 #endif
627 #ifdef HAVE_STDINT_H
628 # include <stdint.h>
629 #endif
630 #ifdef HAVE_UNISTD_H
631 # include <unistd.h>
632 #endif"
633
634 ac_header_list=
635 ac_subst_vars='am__EXEEXT_FALSE
636 am__EXEEXT_TRUE
637 emacs_local_vars_end
638 emacs_local_vars_read_only
639 emacs_local_vars_begin
640 LTLIBOBJS
641 GPGME_CONFIG_AVAIL_LANG
642 GPGME_CONFIG_HOST
643 GPGME_CONFIG_CFLAGS
644 GPGME_CONFIG_LIBS
645 GPGME_CONFIG_API_VERSION
646 HAVE_UISERVER_FALSE
647 HAVE_UISERVER_TRUE
648 USE_DESCRIPTOR_PASSING_FALSE
649 USE_DESCRIPTOR_PASSING_TRUE
650 LIBASSUAN_LIBS
651 LIBASSUAN_CFLAGS
652 LIBASSUAN_CONFIG
653 GPG_ERROR_MT_LIBS
654 GPG_ERROR_MT_CFLAGS
655 GPG_ERROR_LIBS
656 GPG_ERROR_CFLAGS
657 GPGRT_CONFIG
658 GPG_ERROR_CONFIG
659 GLIBC21
660 LIBOBJS
661 API__SSIZE_T
662 API__OFF_T
663 INSERT__TYPEDEFS_FOR_GPGME_H
664 NEED__FILE_OFFSET_BITS
665 RUN_G13_TESTS_FALSE
666 RUN_G13_TESTS_TRUE
667 RUN_GPGSM_TESTS_FALSE
668 RUN_GPGSM_TESTS_TRUE
669 RUN_GPG_TESTS_FALSE
670 RUN_GPG_TESTS_TRUE
671 RUN_GPGCONF_TESTS_FALSE
672 RUN_GPGCONF_TESTS_TRUE
673 BUILD_TIMESTAMP
674 BUILD_FILEVERSION
675 BUILD_VERSION
676 BUILD_REVISION
677 ENABLED_LANGUAGES
678 PYTHONS
679 PYTHON_EXTRA_LDFLAGS
680 PYTHON_EXTRA_LIBS
681 PYTHON_SITE_PKG
682 PYTHON_LDFLAGS
683 PYTHON_CPPFLAGS
684 pkgpyexecdir
685 pyexecdir
686 pkgpythondir
687 pythondir
688 PYTHON_PLATFORM
689 PYTHON_EXEC_PREFIX
690 PYTHON_PREFIX
691 PYTHON_VERSION
692 PYTHON
693 SWIG_LIB
694 SWIG
695 HAVE_DOT
696 HAVE_DOXYGEN_FALSE
697 HAVE_DOXYGEN_TRUE
698 GRAPHVIZ
699 DOXYGEN
700 QTCHOOSER
701 MOC2
702 MOC
703 GPGME_QTTEST_LIBS
704 GPGME_QTTEST_CFLAGS
705 GPGME_QT_LIBS
706 GPGME_QT_CFLAGS
707 HAVE_CXX11
708 BUILD_W32_GLIB_FALSE
709 BUILD_W32_GLIB_TRUE
710 HAVE_MACOS_SYSTEM_FALSE
711 HAVE_MACOS_SYSTEM_TRUE
712 HAVE_ANDROID_SYSTEM_FALSE
713 HAVE_ANDROID_SYSTEM_TRUE
714 HAVE_W64_SYSTEM_FALSE
715 HAVE_W64_SYSTEM_TRUE
716 HAVE_W32_SYSTEM_FALSE
717 HAVE_W32_SYSTEM_TRUE
718 HAVE_DOSISH_SYSTEM_FALSE
719 HAVE_DOSISH_SYSTEM_TRUE
720 GLIB_MKENUMS
721 GOBJECT_QUERY
722 GLIB_GENMARSHAL
723 GLIB_LIBS
724 GLIB_CFLAGS
725 PKG_CONFIG
726 HAVE_LD_VERSION_SCRIPT_FALSE
727 HAVE_LD_VERSION_SCRIPT_TRUE
728 RC
729 CXXCPP
730 OTOOL64
731 OTOOL
732 LIPO
733 NMEDIT
734 DSYMUTIL
735 MANIFEST_TOOL
736 RANLIB
737 ac_ct_AR
738 AR
739 LN_S
740 NM
741 ac_ct_DUMPBIN
742 DUMPBIN
743 LD
744 FGREP
745 SED
746 LIBTOOL
747 OBJDUMP
748 DLLTOOL
749 AS
750 CC_FOR_BUILD
751 VERSION_NUMBER
752 VERSION_MICRO
753 VERSION_MINOR
754 VERSION_MAJOR
755 GITLOG_TO_CHANGELOG
756 am__fastdepCXX_FALSE
757 am__fastdepCXX_TRUE
758 CXXDEPMODE
759 ac_ct_CXX
760 CXXFLAGS
761 CXX
762 LDADD_FOR_TESTS_KLUDGE
763 EGREP
764 GREP
765 CPP
766 am__fastdepCC_FALSE
767 am__fastdepCC_TRUE
768 CCDEPMODE
769 am__nodep
770 AMDEPBACKSLASH
771 AMDEP_FALSE
772 AMDEP_TRUE
773 am__include
774 DEPDIR
775 OBJEXT
776 EXEEXT
777 ac_ct_CC
778 CPPFLAGS
779 LDFLAGS
780 CFLAGS
781 CC
782 SYSROOT
783 host_os
784 host_vendor
785 host_cpu
786 host
787 build_os
788 build_vendor
789 build_cpu
790 build
791 MAINT
792 MAINTAINER_MODE_FALSE
793 MAINTAINER_MODE_TRUE
794 AM_BACKSLASH
795 AM_DEFAULT_VERBOSITY
796 AM_DEFAULT_V
797 AM_V
798 am__untar
799 am__tar
800 AMTAR
801 am__leading_dot
802 SET_MAKE
803 AWK
804 mkdir_p
805 MKDIR_P
806 INSTALL_STRIP_PROGRAM
807 STRIP
808 install_sh
809 MAKEINFO
810 AUTOHEADER
811 AUTOMAKE
812 AUTOCONF
813 ACLOCAL
814 VERSION
815 PACKAGE
816 CYGPATH_W
817 am__isrc
818 INSTALL_DATA
819 INSTALL_SCRIPT
820 INSTALL_PROGRAM
821 LIBQGPGME_LT_REVISION
822 LIBQGPGME_LT_AGE
823 LIBQGPGME_LT_CURRENT
824 LIBGPGMEPP_LT_REVISION
825 LIBGPGMEPP_LT_AGE
826 LIBGPGMEPP_LT_CURRENT
827 LIBGPGME_LT_REVISION
828 LIBGPGME_LT_AGE
829 LIBGPGME_LT_CURRENT
830 target_alias
831 host_alias
832 build_alias
833 LIBS
834 ECHO_T
835 ECHO_N
836 ECHO_C
837 DEFS
838 mandir
839 localedir
840 libdir
841 psdir
842 pdfdir
843 dvidir
844 htmldir
845 infodir
846 docdir
847 oldincludedir
848 includedir
849 runstatedir
850 localstatedir
851 sharedstatedir
852 sysconfdir
853 datadir
854 datarootdir
855 libexecdir
856 sbindir
857 bindir
858 program_transform_name
859 prefix
860 exec_prefix
861 PACKAGE_URL
862 PACKAGE_BUGREPORT
863 PACKAGE_STRING
864 PACKAGE_VERSION
865 PACKAGE_TARNAME
866 PACKAGE_NAME
867 PATH_SEPARATOR
868 SHELL
869 am__quote'
870 ac_subst_files=''
871 ac_user_opts='
872 enable_option_checking
873 enable_silent_rules
874 enable_maintainer_mode
875 enable_dependency_tracking
876 enable_static
877 enable_shared
878 with_pic
879 enable_fast_install
880 with_gnu_ld
881 with_sysroot
882 enable_libtool_lock
883 enable_glibtest
884 enable_w32_glib
885 enable_fixed_path
886 enable_languages
887 enable_build_timestamp
888 enable_gpgconf_test
889 enable_gpg_test
890 enable_gpgsm_test
891 enable_g13_test
892 enable_largefile
893 with_libgpg_error_prefix
894 with_gpg_error_prefix
895 with_libassuan_prefix
896 enable_fd_passing
897 enable_linux_getdents
898 '
899 ac_precious_vars='build_alias
900 host_alias
901 target_alias
902 SYSROOT
903 CC
904 CFLAGS
905 LDFLAGS
906 LIBS
907 CPPFLAGS
908 CPP
909 CXX
910 CXXFLAGS
911 CCC
912 CC_FOR_BUILD
913 CXXCPP
914 PKG_CONFIG
915 GPGME_QT_CFLAGS
916 GPGME_QT_LIBS
917 GPGME_QTTEST_CFLAGS
918 GPGME_QTTEST_LIBS
919 PYTHON
920 PYTHON_VERSION'
921
922
923 # Initialize some variables set by options.
924 ac_init_help=
925 ac_init_version=false
926 ac_unrecognized_opts=
927 ac_unrecognized_sep=
928 # The variables have the same names as the options, with
929 # dashes changed to underlines.
930 cache_file=/dev/null
931 exec_prefix=NONE
932 no_create=
933 no_recursion=
934 prefix=NONE
935 program_prefix=NONE
936 program_suffix=NONE
937 program_transform_name=s,x,x,
938 silent=
939 site=
940 srcdir=
941 verbose=
942 x_includes=NONE
943 x_libraries=NONE
944
945 # Installation directory options.
946 # These are left unexpanded so users can "make install exec_prefix=/foo"
947 # and all the variables that are supposed to be based on exec_prefix
948 # by default will actually change.
949 # Use braces instead of parens because sh, perl, etc. also accept them.
950 # (The list follows the same order as the GNU Coding Standards.)
951 bindir='${exec_prefix}/bin'
952 sbindir='${exec_prefix}/sbin'
953 libexecdir='${exec_prefix}/libexec'
954 datarootdir='${prefix}/share'
955 datadir='${datarootdir}'
956 sysconfdir='${prefix}/etc'
957 sharedstatedir='${prefix}/com'
958 localstatedir='${prefix}/var'
959 runstatedir='${localstatedir}/run'
960 includedir='${prefix}/include'
961 oldincludedir='/usr/include'
962 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
963 infodir='${datarootdir}/info'
964 htmldir='${docdir}'
965 dvidir='${docdir}'
966 pdfdir='${docdir}'
967 psdir='${docdir}'
968 libdir='${exec_prefix}/lib'
969 localedir='${datarootdir}/locale'
970 mandir='${datarootdir}/man'
971
972 ac_prev=
973 ac_dashdash=
974 for ac_option
975 do
976 # If the previous option needs an argument, assign it.
977 if test -n "$ac_prev"; then
978 eval $ac_prev=\$ac_option
979 ac_prev=
980 continue
981 fi
982
983 case $ac_option in
984 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
985 *=) ac_optarg= ;;
986 *) ac_optarg=yes ;;
987 esac
988
989 # Accept the important Cygnus configure options, so we can diagnose typos.
990
991 case $ac_dashdash$ac_option in
992 --)
993 ac_dashdash=yes ;;
994
995 -bindir | --bindir | --bindi | --bind | --bin | --bi)
996 ac_prev=bindir ;;
997 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
998 bindir=$ac_optarg ;;
999
1000 -build | --build | --buil | --bui | --bu)
1001 ac_prev=build_alias ;;
1002 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1003 build_alias=$ac_optarg ;;
1004
1005 -cache-file | --cache-file | --cache-fil | --cache-fi \
1006 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1007 ac_prev=cache_file ;;
1008 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1009 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1010 cache_file=$ac_optarg ;;
1011
1012 --config-cache | -C)
1013 cache_file=config.cache ;;
1014
1015 -datadir | --datadir | --datadi | --datad)
1016 ac_prev=datadir ;;
1017 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1018 datadir=$ac_optarg ;;
1019
1020 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1021 | --dataroo | --dataro | --datar)
1022 ac_prev=datarootdir ;;
1023 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1024 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1025 datarootdir=$ac_optarg ;;
1026
1027 -disable-* | --disable-*)
1028 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1029 # Reject names that are not valid shell variable names.
1030 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1031 as_fn_error $? "invalid feature name: $ac_useropt"
1032 ac_useropt_orig=$ac_useropt
1033 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1034 case $ac_user_opts in
1035 *"
1036 "enable_$ac_useropt"
1037 "*) ;;
1038 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1039 ac_unrecognized_sep=', ';;
1040 esac
1041 eval enable_$ac_useropt=no ;;
1042
1043 -docdir | --docdir | --docdi | --doc | --do)
1044 ac_prev=docdir ;;
1045 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1046 docdir=$ac_optarg ;;
1047
1048 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1049 ac_prev=dvidir ;;
1050 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1051 dvidir=$ac_optarg ;;
1052
1053 -enable-* | --enable-*)
1054 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1055 # Reject names that are not valid shell variable names.
1056 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1057 as_fn_error $? "invalid feature name: $ac_useropt"
1058 ac_useropt_orig=$ac_useropt
1059 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1060 case $ac_user_opts in
1061 *"
1062 "enable_$ac_useropt"
1063 "*) ;;
1064 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1065 ac_unrecognized_sep=', ';;
1066 esac
1067 eval enable_$ac_useropt=\$ac_optarg ;;
1068
1069 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1070 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1071 | --exec | --exe | --ex)
1072 ac_prev=exec_prefix ;;
1073 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1074 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1075 | --exec=* | --exe=* | --ex=*)
1076 exec_prefix=$ac_optarg ;;
1077
1078 -gas | --gas | --ga | --g)
1079 # Obsolete; use --with-gas.
1080 with_gas=yes ;;
1081
1082 -help | --help | --hel | --he | -h)
1083 ac_init_help=long ;;
1084 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1085 ac_init_help=recursive ;;
1086 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1087 ac_init_help=short ;;
1088
1089 -host | --host | --hos | --ho)
1090 ac_prev=host_alias ;;
1091 -host=* | --host=* | --hos=* | --ho=*)
1092 host_alias=$ac_optarg ;;
1093
1094 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1095 ac_prev=htmldir ;;
1096 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1097 | --ht=*)
1098 htmldir=$ac_optarg ;;
1099
1100 -includedir | --includedir | --includedi | --included | --include \
1101 | --includ | --inclu | --incl | --inc)
1102 ac_prev=includedir ;;
1103 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1104 | --includ=* | --inclu=* | --incl=* | --inc=*)
1105 includedir=$ac_optarg ;;
1106
1107 -infodir | --infodir | --infodi | --infod | --info | --inf)
1108 ac_prev=infodir ;;
1109 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1110 infodir=$ac_optarg ;;
1111
1112 -libdir | --libdir | --libdi | --libd)
1113 ac_prev=libdir ;;
1114 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1115 libdir=$ac_optarg ;;
1116
1117 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1118 | --libexe | --libex | --libe)
1119 ac_prev=libexecdir ;;
1120 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1121 | --libexe=* | --libex=* | --libe=*)
1122 libexecdir=$ac_optarg ;;
1123
1124 -localedir | --localedir | --localedi | --localed | --locale)
1125 ac_prev=localedir ;;
1126 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1127 localedir=$ac_optarg ;;
1128
1129 -localstatedir | --localstatedir | --localstatedi | --localstated \
1130 | --localstate | --localstat | --localsta | --localst | --locals)
1131 ac_prev=localstatedir ;;
1132 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1133 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1134 localstatedir=$ac_optarg ;;
1135
1136 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1137 ac_prev=mandir ;;
1138 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1139 mandir=$ac_optarg ;;
1140
1141 -nfp | --nfp | --nf)
1142 # Obsolete; use --without-fp.
1143 with_fp=no ;;
1144
1145 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1146 | --no-cr | --no-c | -n)
1147 no_create=yes ;;
1148
1149 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1150 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1151 no_recursion=yes ;;
1152
1153 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1154 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1155 | --oldin | --oldi | --old | --ol | --o)
1156 ac_prev=oldincludedir ;;
1157 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1158 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1159 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1160 oldincludedir=$ac_optarg ;;
1161
1162 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1163 ac_prev=prefix ;;
1164 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1165 prefix=$ac_optarg ;;
1166
1167 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1168 | --program-pre | --program-pr | --program-p)
1169 ac_prev=program_prefix ;;
1170 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1171 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1172 program_prefix=$ac_optarg ;;
1173
1174 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1175 | --program-suf | --program-su | --program-s)
1176 ac_prev=program_suffix ;;
1177 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1178 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1179 program_suffix=$ac_optarg ;;
1180
1181 -program-transform-name | --program-transform-name \
1182 | --program-transform-nam | --program-transform-na \
1183 | --program-transform-n | --program-transform- \
1184 | --program-transform | --program-transfor \
1185 | --program-transfo | --program-transf \
1186 | --program-trans | --program-tran \
1187 | --progr-tra | --program-tr | --program-t)
1188 ac_prev=program_transform_name ;;
1189 -program-transform-name=* | --program-transform-name=* \
1190 | --program-transform-nam=* | --program-transform-na=* \
1191 | --program-transform-n=* | --program-transform-=* \
1192 | --program-transform=* | --program-transfor=* \
1193 | --program-transfo=* | --program-transf=* \
1194 | --program-trans=* | --program-tran=* \
1195 | --progr-tra=* | --program-tr=* | --program-t=*)
1196 program_transform_name=$ac_optarg ;;
1197
1198 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1199 ac_prev=pdfdir ;;
1200 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1201 pdfdir=$ac_optarg ;;
1202
1203 -psdir | --psdir | --psdi | --psd | --ps)
1204 ac_prev=psdir ;;
1205 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1206 psdir=$ac_optarg ;;
1207
1208 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1209 | -silent | --silent | --silen | --sile | --sil)
1210 silent=yes ;;
1211
1212 -runstatedir | --runstatedir | --runstatedi | --runstated \
1213 | --runstate | --runstat | --runsta | --runst | --runs \
1214 | --run | --ru | --r)
1215 ac_prev=runstatedir ;;
1216 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1217 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1218 | --run=* | --ru=* | --r=*)
1219 runstatedir=$ac_optarg ;;
1220
1221 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1222 ac_prev=sbindir ;;
1223 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1224 | --sbi=* | --sb=*)
1225 sbindir=$ac_optarg ;;
1226
1227 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1228 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1229 | --sharedst | --shareds | --shared | --share | --shar \
1230 | --sha | --sh)
1231 ac_prev=sharedstatedir ;;
1232 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1233 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1234 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1235 | --sha=* | --sh=*)
1236 sharedstatedir=$ac_optarg ;;
1237
1238 -site | --site | --sit)
1239 ac_prev=site ;;
1240 -site=* | --site=* | --sit=*)
1241 site=$ac_optarg ;;
1242
1243 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1244 ac_prev=srcdir ;;
1245 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1246 srcdir=$ac_optarg ;;
1247
1248 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1249 | --syscon | --sysco | --sysc | --sys | --sy)
1250 ac_prev=sysconfdir ;;
1251 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1252 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1253 sysconfdir=$ac_optarg ;;
1254
1255 -target | --target | --targe | --targ | --tar | --ta | --t)
1256 ac_prev=target_alias ;;
1257 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1258 target_alias=$ac_optarg ;;
1259
1260 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1261 verbose=yes ;;
1262
1263 -version | --version | --versio | --versi | --vers | -V)
1264 ac_init_version=: ;;
1265
1266 -with-* | --with-*)
1267 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1268 # Reject names that are not valid shell variable names.
1269 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1270 as_fn_error $? "invalid package name: $ac_useropt"
1271 ac_useropt_orig=$ac_useropt
1272 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1273 case $ac_user_opts in
1274 *"
1275 "with_$ac_useropt"
1276 "*) ;;
1277 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1278 ac_unrecognized_sep=', ';;
1279 esac
1280 eval with_$ac_useropt=\$ac_optarg ;;
1281
1282 -without-* | --without-*)
1283 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1284 # Reject names that are not valid shell variable names.
1285 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1286 as_fn_error $? "invalid package name: $ac_useropt"
1287 ac_useropt_orig=$ac_useropt
1288 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1289 case $ac_user_opts in
1290 *"
1291 "with_$ac_useropt"
1292 "*) ;;
1293 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1294 ac_unrecognized_sep=', ';;
1295 esac
1296 eval with_$ac_useropt=no ;;
1297
1298 --x)
1299 # Obsolete; use --with-x.
1300 with_x=yes ;;
1301
1302 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1303 | --x-incl | --x-inc | --x-in | --x-i)
1304 ac_prev=x_includes ;;
1305 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1306 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1307 x_includes=$ac_optarg ;;
1308
1309 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1310 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1311 ac_prev=x_libraries ;;
1312 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1313 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1314 x_libraries=$ac_optarg ;;
1315
1316 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1317 Try \`$0 --help' for more information"
1318 ;;
1319
1320 *=*)
1321 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1322 # Reject names that are not valid shell variable names.
1323 case $ac_envvar in #(
1324 '' | [0-9]* | *[!_$as_cr_alnum]* )
1325 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1326 esac
1327 eval $ac_envvar=\$ac_optarg
1328 export $ac_envvar ;;
1329
1330 *)
1331 # FIXME: should be removed in autoconf 3.0.
1332 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1333 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1334 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1335 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1336 ;;
1337
1338 esac
1339 done
1340
1341 if test -n "$ac_prev"; then
1342 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1343 as_fn_error $? "missing argument to $ac_option"
1344 fi
1345
1346 if test -n "$ac_unrecognized_opts"; then
1347 case $enable_option_checking in
1348 no) ;;
1349 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1350 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1351 esac
1352 fi
1353
1354 # Check all directory arguments for consistency.
1355 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1356 datadir sysconfdir sharedstatedir localstatedir includedir \
1357 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1358 libdir localedir mandir runstatedir
1359 do
1360 eval ac_val=\$$ac_var
1361 # Remove trailing slashes.
1362 case $ac_val in
1363 */ )
1364 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1365 eval $ac_var=\$ac_val;;
1366 esac
1367 # Be sure to have absolute directory names.
1368 case $ac_val in
1369 [\\/$]* | ?:[\\/]* ) continue;;
1370 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1371 esac
1372 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1373 done
1374
1375 # There might be people who depend on the old broken behavior: `$host'
1376 # used to hold the argument of --host etc.
1377 # FIXME: To remove some day.
1378 build=$build_alias
1379 host=$host_alias
1380 target=$target_alias
1381
1382 # FIXME: To remove some day.
1383 if test "x$host_alias" != x; then
1384 if test "x$build_alias" = x; then
1385 cross_compiling=maybe
1386 elif test "x$build_alias" != "x$host_alias"; then
1387 cross_compiling=yes
1388 fi
1389 fi
1390
1391 ac_tool_prefix=
1392 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1393
1394 test "$silent" = yes && exec 6>/dev/null
1395
1396
1397 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1398 ac_ls_di=`ls -di .` &&
1399 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1400 as_fn_error $? "working directory cannot be determined"
1401 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1402 as_fn_error $? "pwd does not report name of working directory"
1403
1404
1405 # Find the source files, if location was not specified.
1406 if test -z "$srcdir"; then
1407 ac_srcdir_defaulted=yes
1408 # Try the directory containing this script, then the parent directory.
1409 ac_confdir=`$as_dirname -- "$as_myself" ||
1410 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1411 X"$as_myself" : 'X\(//\)[^/]' \| \
1412 X"$as_myself" : 'X\(//\)$' \| \
1413 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1414 $as_echo X"$as_myself" |
1415 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1416 s//\1/
1417 q
1418 }
1419 /^X\(\/\/\)[^/].*/{
1420 s//\1/
1421 q
1422 }
1423 /^X\(\/\/\)$/{
1424 s//\1/
1425 q
1426 }
1427 /^X\(\/\).*/{
1428 s//\1/
1429 q
1430 }
1431 s/.*/./; q'`
1432 srcdir=$ac_confdir
1433 if test ! -r "$srcdir/$ac_unique_file"; then
1434 srcdir=..
1435 fi
1436 else
1437 ac_srcdir_defaulted=no
1438 fi
1439 if test ! -r "$srcdir/$ac_unique_file"; then
1440 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1441 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1442 fi
1443 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1444 ac_abs_confdir=`(
1445 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1446 pwd)`
1447 # When building in place, set srcdir=.
1448 if test "$ac_abs_confdir" = "$ac_pwd"; then
1449 srcdir=.
1450 fi
1451 # Remove unnecessary trailing slashes from srcdir.
1452 # Double slashes in file names in object file debugging info
1453 # mess up M-x gdb in Emacs.
1454 case $srcdir in
1455 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1456 esac
1457 for ac_var in $ac_precious_vars; do
1458 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1459 eval ac_env_${ac_var}_value=\$${ac_var}
1460 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1461 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1462 done
1463
1464 #
1465 # Report the --help message.
1466 #
1467 if test "$ac_init_help" = "long"; then
1468 # Omit some internal or obsolete options to make the list less imposing.
1469 # This message is too long to be a string in the A/UX 3.1 sh.
1470 cat <<_ACEOF
1471 \`configure' configures gpgme 1.17.0 to adapt to many kinds of systems.
1472
1473 Usage: $0 [OPTION]... [VAR=VALUE]...
1474
1475 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1476 VAR=VALUE. See below for descriptions of some of the useful variables.
1477
1478 Defaults for the options are specified in brackets.
1479
1480 Configuration:
1481 -h, --help display this help and exit
1482 --help=short display options specific to this package
1483 --help=recursive display the short help of all the included packages
1484 -V, --version display version information and exit
1485 -q, --quiet, --silent do not print \`checking ...' messages
1486 --cache-file=FILE cache test results in FILE [disabled]
1487 -C, --config-cache alias for \`--cache-file=config.cache'
1488 -n, --no-create do not create output files
1489 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1490
1491 Installation directories:
1492 --prefix=PREFIX install architecture-independent files in PREFIX
1493 [$ac_default_prefix]
1494 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1495 [PREFIX]
1496
1497 By default, \`make install' will install all the files in
1498 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1499 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1500 for instance \`--prefix=\$HOME'.
1501
1502 For better control, use the options below.
1503
1504 Fine tuning of the installation directories:
1505 --bindir=DIR user executables [EPREFIX/bin]
1506 --sbindir=DIR system admin executables [EPREFIX/sbin]
1507 --libexecdir=DIR program executables [EPREFIX/libexec]
1508 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1509 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1510 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1511 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
1512 --libdir=DIR object code libraries [EPREFIX/lib]
1513 --includedir=DIR C header files [PREFIX/include]
1514 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1515 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1516 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1517 --infodir=DIR info documentation [DATAROOTDIR/info]
1518 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1519 --mandir=DIR man documentation [DATAROOTDIR/man]
1520 --docdir=DIR documentation root [DATAROOTDIR/doc/gpgme]
1521 --htmldir=DIR html documentation [DOCDIR]
1522 --dvidir=DIR dvi documentation [DOCDIR]
1523 --pdfdir=DIR pdf documentation [DOCDIR]
1524 --psdir=DIR ps documentation [DOCDIR]
1525 _ACEOF
1526
1527 cat <<\_ACEOF
1528
1529 Program names:
1530 --program-prefix=PREFIX prepend PREFIX to installed program names
1531 --program-suffix=SUFFIX append SUFFIX to installed program names
1532 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1533
1534 System types:
1535 --build=BUILD configure for building on BUILD [guessed]
1536 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1537 _ACEOF
1538 fi
1539
1540 if test -n "$ac_init_help"; then
1541 case $ac_init_help in
1542 short | recursive ) echo "Configuration of gpgme 1.17.0:";;
1543 esac
1544 cat <<\_ACEOF
1545
1546 Optional Features:
1547 --disable-option-checking ignore unrecognized --enable/--with options
1548 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1549 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1550 --enable-silent-rules less verbose build output (undo: "make V=1")
1551 --disable-silent-rules verbose build output (undo: "make V=0")
1552 --enable-maintainer-mode
1553 enable make rules and dependencies not useful (and
1554 sometimes confusing) to the casual installer
1555 --enable-dependency-tracking
1556 do not reject slow dependency extractors
1557 --disable-dependency-tracking
1558 speeds up one-time build
1559 --enable-static[=PKGS] build static libraries [default=no]
1560 --enable-shared[=PKGS] build shared libraries [default=yes]
1561 --enable-fast-install[=PKGS]
1562 optimize for fast installation [default=yes]
1563 --disable-libtool-lock avoid locking (might break parallel builds)
1564 --disable-glibtest do not try to compile and run a test GLIB program
1565 --enable-w32-glib build GPGME Glib for W32
1566 --enable-fixed-path=PATH
1567 locate binaries only via this PATH
1568 --enable-languages=languages
1569 enable only specific language bindings
1570 --enable-build-timestamp
1571 set an explicit build timestamp for reproducibility.
1572 (default is the current time in ISO-8601 format)
1573 --disable-gpgconf-test disable GPGCONF regression test
1574 --disable-gpg-test disable GPG regression test
1575 --disable-gpgsm-test disable GPGSM regression test
1576 --disable-g13-test disable G13 regression test
1577 --disable-largefile omit support for large files
1578 --disable-fd-passing do not use FD passing
1579 --disable-linux-getdents
1580 do not use SYS_getdents on Linux
1581
1582 Optional Packages:
1583 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1584 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1585 --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
1586 both]
1587 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1588 --with-sysroot=DIR Search for dependent libraries within DIR
1589 (or the compiler's sysroot if not specified).
1590 --with-libgpg-error-prefix=PFX
1591 prefix where GPG Error is installed (optional)
1592
1593 --with-libassuan-prefix=PFX
1594 prefix where LIBASSUAN is installed (optional)
1595
1596 Some influential environment variables:
1597 SYSROOT locate config scripts also below that directory
1598 CC C compiler command
1599 CFLAGS C compiler flags
1600 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1601 nonstandard directory <lib dir>
1602 LIBS libraries to pass to the linker, e.g. -l<library>
1603 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1604 you have headers in a nonstandard directory <include dir>
1605 CPP C preprocessor
1606 CXX C++ compiler command
1607 CXXFLAGS C++ compiler flags
1608 CC_FOR_BUILD
1609 build system C compiler
1610 CXXCPP C++ preprocessor
1611 PKG_CONFIG path to pkg-config utility
1612 GPGME_QT_CFLAGS
1613 C compiler flags for GPGME_QT, overriding pkg-config
1614 GPGME_QT_LIBS
1615 linker flags for GPGME_QT, overriding pkg-config
1616 GPGME_QTTEST_CFLAGS
1617 C compiler flags for GPGME_QTTEST, overriding pkg-config
1618 GPGME_QTTEST_LIBS
1619 linker flags for GPGME_QTTEST, overriding pkg-config
1620 PYTHON the Python interpreter
1621 PYTHON_VERSION
1622 The installed Python version to use, for example '2.3'. This
1623 string will be appended to the Python interpreter canonical
1624 name.
1625
1626 Use these variables to override the choices made by `configure' or to help
1627 it to find libraries and programs with nonstandard names/locations.
1628
1629 Report bugs to <https://bugs.gnupg.org>.
1630 _ACEOF
1631 ac_status=$?
1632 fi
1633
1634 if test "$ac_init_help" = "recursive"; then
1635 # If there are subdirs, report their specific --help.
1636 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1637 test -d "$ac_dir" ||
1638 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1639 continue
1640 ac_builddir=.
1641
1642 case "$ac_dir" in
1643 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1644 *)
1645 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1646 # A ".." for each directory in $ac_dir_suffix.
1647 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1648 case $ac_top_builddir_sub in
1649 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1650 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1651 esac ;;
1652 esac
1653 ac_abs_top_builddir=$ac_pwd
1654 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1655 # for backward compatibility:
1656 ac_top_builddir=$ac_top_build_prefix
1657
1658 case $srcdir in
1659 .) # We are building in place.
1660 ac_srcdir=.
1661 ac_top_srcdir=$ac_top_builddir_sub
1662 ac_abs_top_srcdir=$ac_pwd ;;
1663 [\\/]* | ?:[\\/]* ) # Absolute name.
1664 ac_srcdir=$srcdir$ac_dir_suffix;
1665 ac_top_srcdir=$srcdir
1666 ac_abs_top_srcdir=$srcdir ;;
1667 *) # Relative name.
1668 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1669 ac_top_srcdir=$ac_top_build_prefix$srcdir
1670 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1671 esac
1672 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1673
1674 cd "$ac_dir" || { ac_status=$?; continue; }
1675 # Check for guested configure.
1676 if test -f "$ac_srcdir/configure.gnu"; then
1677 echo &&
1678 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1679 elif test -f "$ac_srcdir/configure"; then
1680 echo &&
1681 $SHELL "$ac_srcdir/configure" --help=recursive
1682 else
1683 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1684 fi || ac_status=$?
1685 cd "$ac_pwd" || { ac_status=$?; break; }
1686 done
1687 fi
1688
1689 test -n "$ac_init_help" && exit $ac_status
1690 if $ac_init_version; then
1691 cat <<\_ACEOF
1692 gpgme configure 1.17.0
1693 generated by GNU Autoconf 2.69
1694
1695 Copyright (C) 2012 Free Software Foundation, Inc.
1696 This configure script is free software; the Free Software Foundation
1697 gives unlimited permission to copy, distribute and modify it.
1698 _ACEOF
1699 exit
1700 fi
1701
1702 ## ------------------------ ##
1703 ## Autoconf initialization. ##
1704 ## ------------------------ ##
1705
1706 # ac_fn_c_try_compile LINENO
1707 # --------------------------
1708 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1709 ac_fn_c_try_compile ()
1710 {
1711 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1712 rm -f conftest.$ac_objext
1713 if { { ac_try="$ac_compile"
1714 case "(($ac_try" in
1715 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1716 *) ac_try_echo=$ac_try;;
1717 esac
1718 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1719 $as_echo "$ac_try_echo"; } >&5
1720 (eval "$ac_compile") 2>conftest.err
1721 ac_status=$?
1722 if test -s conftest.err; then
1723 grep -v '^ *+' conftest.err >conftest.er1
1724 cat conftest.er1 >&5
1725 mv -f conftest.er1 conftest.err
1726 fi
1727 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1728 test $ac_status = 0; } && {
1729 test -z "$ac_c_werror_flag" ||
1730 test ! -s conftest.err
1731 } && test -s conftest.$ac_objext; then :
1732 ac_retval=0
1733 else
1734 $as_echo "$as_me: failed program was:" >&5
1735 sed 's/^/| /' conftest.$ac_ext >&5
1736
1737 ac_retval=1
1738 fi
1739 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1740 as_fn_set_status $ac_retval
1741
1742 } # ac_fn_c_try_compile
1743
1744 # ac_fn_c_try_cpp LINENO
1745 # ----------------------
1746 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1747 ac_fn_c_try_cpp ()
1748 {
1749 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1750 if { { ac_try="$ac_cpp conftest.$ac_ext"
1751 case "(($ac_try" in
1752 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1753 *) ac_try_echo=$ac_try;;
1754 esac
1755 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1756 $as_echo "$ac_try_echo"; } >&5
1757 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1758 ac_status=$?
1759 if test -s conftest.err; then
1760 grep -v '^ *+' conftest.err >conftest.er1
1761 cat conftest.er1 >&5
1762 mv -f conftest.er1 conftest.err
1763 fi
1764 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1765 test $ac_status = 0; } > conftest.i && {
1766 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1767 test ! -s conftest.err
1768 }; then :
1769 ac_retval=0
1770 else
1771 $as_echo "$as_me: failed program was:" >&5
1772 sed 's/^/| /' conftest.$ac_ext >&5
1773
1774 ac_retval=1
1775 fi
1776 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1777 as_fn_set_status $ac_retval
1778
1779 } # ac_fn_c_try_cpp
1780
1781 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1782 # -------------------------------------------------------
1783 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1784 # the include files in INCLUDES and setting the cache variable VAR
1785 # accordingly.
1786 ac_fn_c_check_header_mongrel ()
1787 {
1788 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1789 if eval \${$3+:} false; then :
1790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1791 $as_echo_n "checking for $2... " >&6; }
1792 if eval \${$3+:} false; then :
1793 $as_echo_n "(cached) " >&6
1794 fi
1795 eval ac_res=\$$3
1796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1797 $as_echo "$ac_res" >&6; }
1798 else
1799 # Is the header compilable?
1800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1801 $as_echo_n "checking $2 usability... " >&6; }
1802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1803 /* end confdefs.h. */
1804 $4
1805 #include <$2>
1806 _ACEOF
1807 if ac_fn_c_try_compile "$LINENO"; then :
1808 ac_header_compiler=yes
1809 else
1810 ac_header_compiler=no
1811 fi
1812 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1814 $as_echo "$ac_header_compiler" >&6; }
1815
1816 # Is the header present?
1817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1818 $as_echo_n "checking $2 presence... " >&6; }
1819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1820 /* end confdefs.h. */
1821 #include <$2>
1822 _ACEOF
1823 if ac_fn_c_try_cpp "$LINENO"; then :
1824 ac_header_preproc=yes
1825 else
1826 ac_header_preproc=no
1827 fi
1828 rm -f conftest.err conftest.i conftest.$ac_ext
1829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1830 $as_echo "$ac_header_preproc" >&6; }
1831
1832 # So? What about this header?
1833 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1834 yes:no: )
1835 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1836 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1837 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1838 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1839 ;;
1840 no:yes:* )
1841 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1842 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1843 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1844 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1845 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1846 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1847 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1848 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1849 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1850 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1851 ( $as_echo "## ------------------------------------- ##
1852 ## Report this to https://bugs.gnupg.org ##
1853 ## ------------------------------------- ##"
1854 ) | sed "s/^/$as_me: WARNING: /" >&2
1855 ;;
1856 esac
1857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1858 $as_echo_n "checking for $2... " >&6; }
1859 if eval \${$3+:} false; then :
1860 $as_echo_n "(cached) " >&6
1861 else
1862 eval "$3=\$ac_header_compiler"
1863 fi
1864 eval ac_res=\$$3
1865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1866 $as_echo "$ac_res" >&6; }
1867 fi
1868 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1869
1870 } # ac_fn_c_check_header_mongrel
1871
1872 # ac_fn_c_try_run LINENO
1873 # ----------------------
1874 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1875 # that executables *can* be run.
1876 ac_fn_c_try_run ()
1877 {
1878 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1879 if { { ac_try="$ac_link"
1880 case "(($ac_try" in
1881 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1882 *) ac_try_echo=$ac_try;;
1883 esac
1884 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1885 $as_echo "$ac_try_echo"; } >&5
1886 (eval "$ac_link") 2>&5
1887 ac_status=$?
1888 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1889 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1890 { { case "(($ac_try" in
1891 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1892 *) ac_try_echo=$ac_try;;
1893 esac
1894 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1895 $as_echo "$ac_try_echo"; } >&5
1896 (eval "$ac_try") 2>&5
1897 ac_status=$?
1898 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1899 test $ac_status = 0; }; }; then :
1900 ac_retval=0
1901 else
1902 $as_echo "$as_me: program exited with status $ac_status" >&5
1903 $as_echo "$as_me: failed program was:" >&5
1904 sed 's/^/| /' conftest.$ac_ext >&5
1905
1906 ac_retval=$ac_status
1907 fi
1908 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1909 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1910 as_fn_set_status $ac_retval
1911
1912 } # ac_fn_c_try_run
1913
1914 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1915 # -------------------------------------------------------
1916 # Tests whether HEADER exists and can be compiled using the include files in
1917 # INCLUDES, setting the cache variable VAR accordingly.
1918 ac_fn_c_check_header_compile ()
1919 {
1920 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1922 $as_echo_n "checking for $2... " >&6; }
1923 if eval \${$3+:} false; then :
1924 $as_echo_n "(cached) " >&6
1925 else
1926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1927 /* end confdefs.h. */
1928 $4
1929 #include <$2>
1930 _ACEOF
1931 if ac_fn_c_try_compile "$LINENO"; then :
1932 eval "$3=yes"
1933 else
1934 eval "$3=no"
1935 fi
1936 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1937 fi
1938 eval ac_res=\$$3
1939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1940 $as_echo "$ac_res" >&6; }
1941 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1942
1943 } # ac_fn_c_check_header_compile
1944
1945 # ac_fn_c_try_link LINENO
1946 # -----------------------
1947 # Try to link conftest.$ac_ext, and return whether this succeeded.
1948 ac_fn_c_try_link ()
1949 {
1950 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1951 rm -f conftest.$ac_objext conftest$ac_exeext
1952 if { { ac_try="$ac_link"
1953 case "(($ac_try" in
1954 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1955 *) ac_try_echo=$ac_try;;
1956 esac
1957 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1958 $as_echo "$ac_try_echo"; } >&5
1959 (eval "$ac_link") 2>conftest.err
1960 ac_status=$?
1961 if test -s conftest.err; then
1962 grep -v '^ *+' conftest.err >conftest.er1
1963 cat conftest.er1 >&5
1964 mv -f conftest.er1 conftest.err
1965 fi
1966 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1967 test $ac_status = 0; } && {
1968 test -z "$ac_c_werror_flag" ||
1969 test ! -s conftest.err
1970 } && test -s conftest$ac_exeext && {
1971 test "$cross_compiling" = yes ||
1972 test -x conftest$ac_exeext
1973 }; then :
1974 ac_retval=0
1975 else
1976 $as_echo "$as_me: failed program was:" >&5
1977 sed 's/^/| /' conftest.$ac_ext >&5
1978
1979 ac_retval=1
1980 fi
1981 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1982 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1983 # interfere with the next link command; also delete a directory that is
1984 # left behind by Apple's compiler. We do this before executing the actions.
1985 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1986 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1987 as_fn_set_status $ac_retval
1988
1989 } # ac_fn_c_try_link
1990
1991 # ac_fn_cxx_try_compile LINENO
1992 # ----------------------------
1993 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1994 ac_fn_cxx_try_compile ()
1995 {
1996 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1997 rm -f conftest.$ac_objext
1998 if { { ac_try="$ac_compile"
1999 case "(($ac_try" in
2000 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2001 *) ac_try_echo=$ac_try;;
2002 esac
2003 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2004 $as_echo "$ac_try_echo"; } >&5
2005 (eval "$ac_compile") 2>conftest.err
2006 ac_status=$?
2007 if test -s conftest.err; then
2008 grep -v '^ *+' conftest.err >conftest.er1
2009 cat conftest.er1 >&5
2010 mv -f conftest.er1 conftest.err
2011 fi
2012 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2013 test $ac_status = 0; } && {
2014 test -z "$ac_cxx_werror_flag" ||
2015 test ! -s conftest.err
2016 } && test -s conftest.$ac_objext; then :
2017 ac_retval=0
2018 else
2019 $as_echo "$as_me: failed program was:" >&5
2020 sed 's/^/| /' conftest.$ac_ext >&5
2021
2022 ac_retval=1
2023 fi
2024 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2025 as_fn_set_status $ac_retval
2026
2027 } # ac_fn_cxx_try_compile
2028
2029 # ac_fn_c_check_func LINENO FUNC VAR
2030 # ----------------------------------
2031 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2032 ac_fn_c_check_func ()
2033 {
2034 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2036 $as_echo_n "checking for $2... " >&6; }
2037 if eval \${$3+:} false; then :
2038 $as_echo_n "(cached) " >&6
2039 else
2040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2041 /* end confdefs.h. */
2042 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2043 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2044 #define $2 innocuous_$2
2045
2046 /* System header to define __stub macros and hopefully few prototypes,
2047 which can conflict with char $2 (); below.
2048 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2049 <limits.h> exists even on freestanding compilers. */
2050
2051 #ifdef __STDC__
2052 # include <limits.h>
2053 #else
2054 # include <assert.h>
2055 #endif
2056
2057 #undef $2
2058
2059 /* Override any GCC internal prototype to avoid an error.
2060 Use char because int might match the return type of a GCC
2061 builtin and then its argument prototype would still apply. */
2062 #ifdef __cplusplus
2063 extern "C"
2064 #endif
2065 char $2 ();
2066 /* The GNU C library defines this for functions which it implements
2067 to always fail with ENOSYS. Some functions are actually named
2068 something starting with __ and the normal name is an alias. */
2069 #if defined __stub_$2 || defined __stub___$2
2070 choke me
2071 #endif
2072
2073 int
2074 main ()
2075 {
2076 return $2 ();
2077 ;
2078 return 0;
2079 }
2080 _ACEOF
2081 if ac_fn_c_try_link "$LINENO"; then :
2082 eval "$3=yes"
2083 else
2084 eval "$3=no"
2085 fi
2086 rm -f core conftest.err conftest.$ac_objext \
2087 conftest$ac_exeext conftest.$ac_ext
2088 fi
2089 eval ac_res=\$$3
2090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2091 $as_echo "$ac_res" >&6; }
2092 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2093
2094 } # ac_fn_c_check_func
2095
2096 # ac_fn_cxx_try_cpp LINENO
2097 # ------------------------
2098 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2099 ac_fn_cxx_try_cpp ()
2100 {
2101 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2102 if { { ac_try="$ac_cpp conftest.$ac_ext"
2103 case "(($ac_try" in
2104 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2105 *) ac_try_echo=$ac_try;;
2106 esac
2107 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2108 $as_echo "$ac_try_echo"; } >&5
2109 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2110 ac_status=$?
2111 if test -s conftest.err; then
2112 grep -v '^ *+' conftest.err >conftest.er1
2113 cat conftest.er1 >&5
2114 mv -f conftest.er1 conftest.err
2115 fi
2116 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2117 test $ac_status = 0; } > conftest.i && {
2118 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2119 test ! -s conftest.err
2120 }; then :
2121 ac_retval=0
2122 else
2123 $as_echo "$as_me: failed program was:" >&5
2124 sed 's/^/| /' conftest.$ac_ext >&5
2125
2126 ac_retval=1
2127 fi
2128 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2129 as_fn_set_status $ac_retval
2130
2131 } # ac_fn_cxx_try_cpp
2132
2133 # ac_fn_cxx_try_link LINENO
2134 # -------------------------
2135 # Try to link conftest.$ac_ext, and return whether this succeeded.
2136 ac_fn_cxx_try_link ()
2137 {
2138 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2139 rm -f conftest.$ac_objext conftest$ac_exeext
2140 if { { ac_try="$ac_link"
2141 case "(($ac_try" in
2142 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2143 *) ac_try_echo=$ac_try;;
2144 esac
2145 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2146 $as_echo "$ac_try_echo"; } >&5
2147 (eval "$ac_link") 2>conftest.err
2148 ac_status=$?
2149 if test -s conftest.err; then
2150 grep -v '^ *+' conftest.err >conftest.er1
2151 cat conftest.er1 >&5
2152 mv -f conftest.er1 conftest.err
2153 fi
2154 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2155 test $ac_status = 0; } && {
2156 test -z "$ac_cxx_werror_flag" ||
2157 test ! -s conftest.err
2158 } && test -s conftest$ac_exeext && {
2159 test "$cross_compiling" = yes ||
2160 test -x conftest$ac_exeext
2161 }; then :
2162 ac_retval=0
2163 else
2164 $as_echo "$as_me: failed program was:" >&5
2165 sed 's/^/| /' conftest.$ac_ext >&5
2166
2167 ac_retval=1
2168 fi
2169 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2170 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2171 # interfere with the next link command; also delete a directory that is
2172 # left behind by Apple's compiler. We do this before executing the actions.
2173 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2174 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2175 as_fn_set_status $ac_retval
2176
2177 } # ac_fn_cxx_try_link
2178
2179 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2180 # --------------------------------------------
2181 # Tries to find the compile-time value of EXPR in a program that includes
2182 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2183 # computed
2184 ac_fn_c_compute_int ()
2185 {
2186 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2187 if test "$cross_compiling" = yes; then
2188 # Depending upon the size, compute the lo and hi bounds.
2189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2190 /* end confdefs.h. */
2191 $4
2192 int
2193 main ()
2194 {
2195 static int test_array [1 - 2 * !(($2) >= 0)];
2196 test_array [0] = 0;
2197 return test_array [0];
2198
2199 ;
2200 return 0;
2201 }
2202 _ACEOF
2203 if ac_fn_c_try_compile "$LINENO"; then :
2204 ac_lo=0 ac_mid=0
2205 while :; do
2206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2207 /* end confdefs.h. */
2208 $4
2209 int
2210 main ()
2211 {
2212 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2213 test_array [0] = 0;
2214 return test_array [0];
2215
2216 ;
2217 return 0;
2218 }
2219 _ACEOF
2220 if ac_fn_c_try_compile "$LINENO"; then :
2221 ac_hi=$ac_mid; break
2222 else
2223 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2224 if test $ac_lo -le $ac_mid; then
2225 ac_lo= ac_hi=
2226 break
2227 fi
2228 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2229 fi
2230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2231 done
2232 else
2233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2234 /* end confdefs.h. */
2235 $4
2236 int
2237 main ()
2238 {
2239 static int test_array [1 - 2 * !(($2) < 0)];
2240 test_array [0] = 0;
2241 return test_array [0];
2242
2243 ;
2244 return 0;
2245 }
2246 _ACEOF
2247 if ac_fn_c_try_compile "$LINENO"; then :
2248 ac_hi=-1 ac_mid=-1
2249 while :; do
2250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2251 /* end confdefs.h. */
2252 $4
2253 int
2254 main ()
2255 {
2256 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2257 test_array [0] = 0;
2258 return test_array [0];
2259
2260 ;
2261 return 0;
2262 }
2263 _ACEOF
2264 if ac_fn_c_try_compile "$LINENO"; then :
2265 ac_lo=$ac_mid; break
2266 else
2267 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2268 if test $ac_mid -le $ac_hi; then
2269 ac_lo= ac_hi=
2270 break
2271 fi
2272 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2273 fi
2274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2275 done
2276 else
2277 ac_lo= ac_hi=
2278 fi
2279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2280 fi
2281 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2282 # Binary search between lo and hi bounds.
2283 while test "x$ac_lo" != "x$ac_hi"; do
2284 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2286 /* end confdefs.h. */
2287 $4
2288 int
2289 main ()
2290 {
2291 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2292 test_array [0] = 0;
2293 return test_array [0];
2294
2295 ;
2296 return 0;
2297 }
2298 _ACEOF
2299 if ac_fn_c_try_compile "$LINENO"; then :
2300 ac_hi=$ac_mid
2301 else
2302 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2303 fi
2304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2305 done
2306 case $ac_lo in #((
2307 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2308 '') ac_retval=1 ;;
2309 esac
2310 else
2311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2312 /* end confdefs.h. */
2313 $4
2314 static long int longval () { return $2; }
2315 static unsigned long int ulongval () { return $2; }
2316 #include <stdio.h>
2317 #include <stdlib.h>
2318 int
2319 main ()
2320 {
2321
2322 FILE *f = fopen ("conftest.val", "w");
2323 if (! f)
2324 return 1;
2325 if (($2) < 0)
2326 {
2327 long int i = longval ();
2328 if (i != ($2))
2329 return 1;
2330 fprintf (f, "%ld", i);
2331 }
2332 else
2333 {
2334 unsigned long int i = ulongval ();
2335 if (i != ($2))
2336 return 1;
2337 fprintf (f, "%lu", i);
2338 }
2339 /* Do not output a trailing newline, as this causes \r\n confusion
2340 on some platforms. */
2341 return ferror (f) || fclose (f) != 0;
2342
2343 ;
2344 return 0;
2345 }
2346 _ACEOF
2347 if ac_fn_c_try_run "$LINENO"; then :
2348 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2349 else
2350 ac_retval=1
2351 fi
2352 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2353 conftest.$ac_objext conftest.beam conftest.$ac_ext
2354 rm -f conftest.val
2355
2356 fi
2357 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2358 as_fn_set_status $ac_retval
2359
2360 } # ac_fn_c_compute_int
2361
2362 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2363 # -------------------------------------------
2364 # Tests whether TYPE exists after having included INCLUDES, setting cache
2365 # variable VAR accordingly.
2366 ac_fn_c_check_type ()
2367 {
2368 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2370 $as_echo_n "checking for $2... " >&6; }
2371 if eval \${$3+:} false; then :
2372 $as_echo_n "(cached) " >&6
2373 else
2374 eval "$3=no"
2375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2376 /* end confdefs.h. */
2377 $4
2378 int
2379 main ()
2380 {
2381 if (sizeof ($2))
2382 return 0;
2383 ;
2384 return 0;
2385 }
2386 _ACEOF
2387 if ac_fn_c_try_compile "$LINENO"; then :
2388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2389 /* end confdefs.h. */
2390 $4
2391 int
2392 main ()
2393 {
2394 if (sizeof (($2)))
2395 return 0;
2396 ;
2397 return 0;
2398 }
2399 _ACEOF
2400 if ac_fn_c_try_compile "$LINENO"; then :
2401
2402 else
2403 eval "$3=yes"
2404 fi
2405 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2406 fi
2407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2408 fi
2409 eval ac_res=\$$3
2410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2411 $as_echo "$ac_res" >&6; }
2412 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2413
2414 } # ac_fn_c_check_type
2415
2416 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2417 # ---------------------------------------------
2418 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2419 # accordingly.
2420 ac_fn_c_check_decl ()
2421 {
2422 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2423 as_decl_name=`echo $2|sed 's/ *(.*//'`
2424 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2426 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2427 if eval \${$3+:} false; then :
2428 $as_echo_n "(cached) " >&6
2429 else
2430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2431 /* end confdefs.h. */
2432 $4
2433 int
2434 main ()
2435 {
2436 #ifndef $as_decl_name
2437 #ifdef __cplusplus
2438 (void) $as_decl_use;
2439 #else
2440 (void) $as_decl_name;
2441 #endif
2442 #endif
2443
2444 ;
2445 return 0;
2446 }
2447 _ACEOF
2448 if ac_fn_c_try_compile "$LINENO"; then :
2449 eval "$3=yes"
2450 else
2451 eval "$3=no"
2452 fi
2453 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2454 fi
2455 eval ac_res=\$$3
2456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2457 $as_echo "$ac_res" >&6; }
2458 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2459
2460 } # ac_fn_c_check_decl
2461
2462 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2463 # ----------------------------------------------------
2464 # Tries to find if the field MEMBER exists in type AGGR, after including
2465 # INCLUDES, setting cache variable VAR accordingly.
2466 ac_fn_c_check_member ()
2467 {
2468 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2470 $as_echo_n "checking for $2.$3... " >&6; }
2471 if eval \${$4+:} false; then :
2472 $as_echo_n "(cached) " >&6
2473 else
2474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2475 /* end confdefs.h. */
2476 $5
2477 int
2478 main ()
2479 {
2480 static $2 ac_aggr;
2481 if (ac_aggr.$3)
2482 return 0;
2483 ;
2484 return 0;
2485 }
2486 _ACEOF
2487 if ac_fn_c_try_compile "$LINENO"; then :
2488 eval "$4=yes"
2489 else
2490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2491 /* end confdefs.h. */
2492 $5
2493 int
2494 main ()
2495 {
2496 static $2 ac_aggr;
2497 if (sizeof ac_aggr.$3)
2498 return 0;
2499 ;
2500 return 0;
2501 }
2502 _ACEOF
2503 if ac_fn_c_try_compile "$LINENO"; then :
2504 eval "$4=yes"
2505 else
2506 eval "$4=no"
2507 fi
2508 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2509 fi
2510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2511 fi
2512 eval ac_res=\$$4
2513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2514 $as_echo "$ac_res" >&6; }
2515 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2516
2517 } # ac_fn_c_check_member
2518 cat >config.log <<_ACEOF
2519 This file contains any messages produced by compilers while
2520 running configure, to aid debugging if configure makes a mistake.
2521
2522 It was created by gpgme $as_me 1.17.0, which was
2523 generated by GNU Autoconf 2.69. Invocation command line was
2524
2525 $ $0 $@
2526
2527 _ACEOF
2528 exec 5>>config.log
2529 {
2530 cat <<_ASUNAME
2531 ## --------- ##
2532 ## Platform. ##
2533 ## --------- ##
2534
2535 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2536 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2537 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2538 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2539 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2540
2541 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2542 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2543
2544 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2545 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2546 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2547 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2548 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2549 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2550 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2551
2552 _ASUNAME
2553
2554 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2555 for as_dir in $PATH
2556 do
2557 IFS=$as_save_IFS
2558 test -z "$as_dir" && as_dir=.
2559 $as_echo "PATH: $as_dir"
2560 done
2561 IFS=$as_save_IFS
2562
2563 } >&5
2564
2565 cat >&5 <<_ACEOF
2566
2567
2568 ## ----------- ##
2569 ## Core tests. ##
2570 ## ----------- ##
2571
2572 _ACEOF
2573
2574
2575 # Keep a trace of the command line.
2576 # Strip out --no-create and --no-recursion so they do not pile up.
2577 # Strip out --silent because we don't want to record it for future runs.
2578 # Also quote any args containing shell meta-characters.
2579 # Make two passes to allow for proper duplicate-argument suppression.
2580 ac_configure_args=
2581 ac_configure_args0=
2582 ac_configure_args1=
2583 ac_must_keep_next=false
2584 for ac_pass in 1 2
2585 do
2586 for ac_arg
2587 do
2588 case $ac_arg in
2589 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2590 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2591 | -silent | --silent | --silen | --sile | --sil)
2592 continue ;;
2593 *\'*)
2594 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2595 esac
2596 case $ac_pass in
2597 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2598 2)
2599 as_fn_append ac_configure_args1 " '$ac_arg'"
2600 if test $ac_must_keep_next = true; then
2601 ac_must_keep_next=false # Got value, back to normal.
2602 else
2603 case $ac_arg in
2604 *=* | --config-cache | -C | -disable-* | --disable-* \
2605 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2606 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2607 | -with-* | --with-* | -without-* | --without-* | --x)
2608 case "$ac_configure_args0 " in
2609 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2610 esac
2611 ;;
2612 -* ) ac_must_keep_next=true ;;
2613 esac
2614 fi
2615 as_fn_append ac_configure_args " '$ac_arg'"
2616 ;;
2617 esac
2618 done
2619 done
2620 { ac_configure_args0=; unset ac_configure_args0;}
2621 { ac_configure_args1=; unset ac_configure_args1;}
2622
2623 # When interrupted or exit'd, cleanup temporary files, and complete
2624 # config.log. We remove comments because anyway the quotes in there
2625 # would cause problems or look ugly.
2626 # WARNING: Use '\'' to represent an apostrophe within the trap.
2627 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2628 trap 'exit_status=$?
2629 # Save into config.log some information that might help in debugging.
2630 {
2631 echo
2632
2633 $as_echo "## ---------------- ##
2634 ## Cache variables. ##
2635 ## ---------------- ##"
2636 echo
2637 # The following way of writing the cache mishandles newlines in values,
2638 (
2639 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2640 eval ac_val=\$$ac_var
2641 case $ac_val in #(
2642 *${as_nl}*)
2643 case $ac_var in #(
2644 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2645 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2646 esac
2647 case $ac_var in #(
2648 _ | IFS | as_nl) ;; #(
2649 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2650 *) { eval $ac_var=; unset $ac_var;} ;;
2651 esac ;;
2652 esac
2653 done
2654 (set) 2>&1 |
2655 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2656 *${as_nl}ac_space=\ *)
2657 sed -n \
2658 "s/'\''/'\''\\\\'\'''\''/g;
2659 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2660 ;; #(
2661 *)
2662 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2663 ;;
2664 esac |
2665 sort
2666 )
2667 echo
2668
2669 $as_echo "## ----------------- ##
2670 ## Output variables. ##
2671 ## ----------------- ##"
2672 echo
2673 for ac_var in $ac_subst_vars
2674 do
2675 eval ac_val=\$$ac_var
2676 case $ac_val in
2677 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2678 esac
2679 $as_echo "$ac_var='\''$ac_val'\''"
2680 done | sort
2681 echo
2682
2683 if test -n "$ac_subst_files"; then
2684 $as_echo "## ------------------- ##
2685 ## File substitutions. ##
2686 ## ------------------- ##"
2687 echo
2688 for ac_var in $ac_subst_files
2689 do
2690 eval ac_val=\$$ac_var
2691 case $ac_val in
2692 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2693 esac
2694 $as_echo "$ac_var='\''$ac_val'\''"
2695 done | sort
2696 echo
2697 fi
2698
2699 if test -s confdefs.h; then
2700 $as_echo "## ----------- ##
2701 ## confdefs.h. ##
2702 ## ----------- ##"
2703 echo
2704 cat confdefs.h
2705 echo
2706 fi
2707 test "$ac_signal" != 0 &&
2708 $as_echo "$as_me: caught signal $ac_signal"
2709 $as_echo "$as_me: exit $exit_status"
2710 } >&5
2711 rm -f core *.core core.conftest.* &&
2712 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2713 exit $exit_status
2714 ' 0
2715 for ac_signal in 1 2 13 15; do
2716 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2717 done
2718 ac_signal=0
2719
2720 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2721 rm -f -r conftest* confdefs.h
2722
2723 $as_echo "/* confdefs.h */" > confdefs.h
2724
2725 # Predefined preprocessor variables.
2726
2727 cat >>confdefs.h <<_ACEOF
2728 #define PACKAGE_NAME "$PACKAGE_NAME"
2729 _ACEOF
2730
2731 cat >>confdefs.h <<_ACEOF
2732 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2733 _ACEOF
2734
2735 cat >>confdefs.h <<_ACEOF
2736 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2737 _ACEOF
2738
2739 cat >>confdefs.h <<_ACEOF
2740 #define PACKAGE_STRING "$PACKAGE_STRING"
2741 _ACEOF
2742
2743 cat >>confdefs.h <<_ACEOF
2744 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2745 _ACEOF
2746
2747 cat >>confdefs.h <<_ACEOF
2748 #define PACKAGE_URL "$PACKAGE_URL"
2749 _ACEOF
2750
2751
2752 # Let the site file select an alternate cache file if it wants to.
2753 # Prefer an explicitly selected file to automatically selected ones.
2754 ac_site_file1=NONE
2755 ac_site_file2=NONE
2756 if test -n "$CONFIG_SITE"; then
2757 # We do not want a PATH search for config.site.
2758 case $CONFIG_SITE in #((
2759 -*) ac_site_file1=./$CONFIG_SITE;;
2760 */*) ac_site_file1=$CONFIG_SITE;;
2761 *) ac_site_file1=./$CONFIG_SITE;;
2762 esac
2763 elif test "x$prefix" != xNONE; then
2764 ac_site_file1=$prefix/share/config.site
2765 ac_site_file2=$prefix/etc/config.site
2766 else
2767 ac_site_file1=$ac_default_prefix/share/config.site
2768 ac_site_file2=$ac_default_prefix/etc/config.site
2769 fi
2770 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2771 do
2772 test "x$ac_site_file" = xNONE && continue
2773 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2774 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2775 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2776 sed 's/^/| /' "$ac_site_file" >&5
2777 . "$ac_site_file" \
2778 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2779 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2780 as_fn_error $? "failed to load site script $ac_site_file
2781 See \`config.log' for more details" "$LINENO" 5; }
2782 fi
2783 done
2784
2785 if test -r "$cache_file"; then
2786 # Some versions of bash will fail to source /dev/null (special files
2787 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2788 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2789 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2790 $as_echo "$as_me: loading cache $cache_file" >&6;}
2791 case $cache_file in
2792 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2793 *) . "./$cache_file";;
2794 esac
2795 fi
2796 else
2797 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2798 $as_echo "$as_me: creating cache $cache_file" >&6;}
2799 >$cache_file
2800 fi
2801
2802 as_fn_append ac_header_list " locale.h"
2803 as_fn_append ac_header_list " sys/select.h"
2804 as_fn_append ac_header_list " sys/uio.h"
2805 as_fn_append ac_header_list " argp.h"
2806 as_fn_append ac_header_list " stdint.h"
2807 as_fn_append ac_header_list " unistd.h"
2808 as_fn_append ac_header_list " poll.h"
2809 as_fn_append ac_header_list " sys/time.h"
2810 as_fn_append ac_header_list " sys/types.h"
2811 as_fn_append ac_header_list " sys/stat.h"
2812 # Check that the precious variables saved in the cache have kept the same
2813 # value.
2814 ac_cache_corrupted=false
2815 for ac_var in $ac_precious_vars; do
2816 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2817 eval ac_new_set=\$ac_env_${ac_var}_set
2818 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2819 eval ac_new_val=\$ac_env_${ac_var}_value
2820 case $ac_old_set,$ac_new_set in
2821 set,)
2822 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2823 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2824 ac_cache_corrupted=: ;;
2825 ,set)
2826 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2827 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2828 ac_cache_corrupted=: ;;
2829 ,);;
2830 *)
2831 if test "x$ac_old_val" != "x$ac_new_val"; then
2832 # differences in whitespace do not lead to failure.
2833 ac_old_val_w=`echo x $ac_old_val`
2834 ac_new_val_w=`echo x $ac_new_val`
2835 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2836 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2837 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2838 ac_cache_corrupted=:
2839 else
2840 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2841 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2842 eval $ac_var=\$ac_old_val
2843 fi
2844 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2845 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2846 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2847 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2848 fi;;
2849 esac
2850 # Pass precious variables to config.status.
2851 if test "$ac_new_set" = set; then
2852 case $ac_new_val in
2853 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2854 *) ac_arg=$ac_var=$ac_new_val ;;
2855 esac
2856 case " $ac_configure_args " in
2857 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2858 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2859 esac
2860 fi
2861 done
2862 if $ac_cache_corrupted; then
2863 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2864 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2865 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2866 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2867 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2868 fi
2869 ## -------------------- ##
2870 ## Main body of script. ##
2871 ## -------------------- ##
2872
2873 ac_ext=c
2874 ac_cpp='$CPP $CPPFLAGS'
2875 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2876 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2877 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2878
2879
2880
2881 # LT Version numbers, remember to change them just *before* a release.
2882 # (Code changed: REVISION++)
2883 # (Interfaces added/removed/changed: CURRENT++, REVISION=0)
2884 # (Interfaces added: AGE++)
2885 # (Interfaces removed: AGE=0)
2886 #
2887 LIBGPGME_LT_CURRENT=37
2888 LIBGPGME_LT_AGE=26
2889 LIBGPGME_LT_REVISION=0
2890
2891 # If there is an ABI break in gpgmepp or qgpgme also bump the
2892 # version in IMPORTED_LOCATION in the GpgmeppConfig-w32.cmake.in.in
2893
2894 LIBGPGMEPP_LT_CURRENT=20
2895 LIBGPGMEPP_LT_AGE=14
2896 LIBGPGMEPP_LT_REVISION=0
2897
2898 LIBQGPGME_LT_CURRENT=14
2899 LIBQGPGME_LT_AGE=7
2900 LIBQGPGME_LT_REVISION=0
2901 ################################################
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915 # If the API is changed in an incompatible way: increment the next counter.
2916 GPGME_CONFIG_API_VERSION=1
2917 ##############################################
2918
2919 NEED_GPG_ERROR_VERSION=1.36
2920 NEED_LIBASSUAN_API=2
2921 NEED_LIBASSUAN_VERSION=2.4.2
2922
2923
2924 VERSION_MAJOR=1
2925 VERSION_MINOR=17
2926 VERSION_MICRO=0
2927
2928 ac_aux_dir=
2929 for ac_dir in build-aux "$srcdir"/build-aux; do
2930 if test -f "$ac_dir/install-sh"; then
2931 ac_aux_dir=$ac_dir
2932 ac_install_sh="$ac_aux_dir/install-sh -c"
2933 break
2934 elif test -f "$ac_dir/install.sh"; then
2935 ac_aux_dir=$ac_dir
2936 ac_install_sh="$ac_aux_dir/install.sh -c"
2937 break
2938 elif test -f "$ac_dir/shtool"; then
2939 ac_aux_dir=$ac_dir
2940 ac_install_sh="$ac_aux_dir/shtool install -c"
2941 break
2942 fi
2943 done
2944 if test -z "$ac_aux_dir"; then
2945 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
2946 fi
2947
2948 # These three variables are undocumented and unsupported,
2949 # and are intended to be withdrawn in a future Autoconf release.
2950 # They can cause serious problems if a builder's source tree is in a directory
2951 # whose full name contains unusual characters.
2952 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2953 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2954 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2955
2956
2957
2958
2959 ac_config_headers="$ac_config_headers conf/config.h"
2960
2961 am__api_version='1.16'
2962
2963 # Find a good install program. We prefer a C program (faster),
2964 # so one script is as good as another. But avoid the broken or
2965 # incompatible versions:
2966 # SysV /etc/install, /usr/sbin/install
2967 # SunOS /usr/etc/install
2968 # IRIX /sbin/install
2969 # AIX /bin/install
2970 # AmigaOS /C/install, which installs bootblocks on floppy discs
2971 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2972 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2973 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2974 # OS/2's system install, which has a completely different semantic
2975 # ./install, which can be erroneously created by make from ./install.sh.
2976 # Reject install programs that cannot install multiple files.
2977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
2978 $as_echo_n "checking for a BSD-compatible install... " >&6; }
2979 if test -z "$INSTALL"; then
2980 if ${ac_cv_path_install+:} false; then :
2981 $as_echo_n "(cached) " >&6
2982 else
2983 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2984 for as_dir in $PATH
2985 do
2986 IFS=$as_save_IFS
2987 test -z "$as_dir" && as_dir=.
2988 # Account for people who put trailing slashes in PATH elements.
2989 case $as_dir/ in #((
2990 ./ | .// | /[cC]/* | \
2991 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2992 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
2993 /usr/ucb/* ) ;;
2994 *)
2995 # OSF1 and SCO ODT 3.0 have their own names for install.
2996 # Don't use installbsd from OSF since it installs stuff as root
2997 # by default.
2998 for ac_prog in ginstall scoinst install; do
2999 for ac_exec_ext in '' $ac_executable_extensions; do
3000 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3001 if test $ac_prog = install &&
3002 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3003 # AIX install. It has an incompatible calling convention.
3004 :
3005 elif test $ac_prog = install &&
3006 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3007 # program-specific install script used by HP pwplus--don't use.
3008 :
3009 else
3010 rm -rf conftest.one conftest.two conftest.dir
3011 echo one > conftest.one
3012 echo two > conftest.two
3013 mkdir conftest.dir
3014 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3015 test -s conftest.one && test -s conftest.two &&
3016 test -s conftest.dir/conftest.one &&
3017 test -s conftest.dir/conftest.two
3018 then
3019 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3020 break 3
3021 fi
3022 fi
3023 fi
3024 done
3025 done
3026 ;;
3027 esac
3028
3029 done
3030 IFS=$as_save_IFS
3031
3032 rm -rf conftest.one conftest.two conftest.dir
3033
3034 fi
3035 if test "${ac_cv_path_install+set}" = set; then
3036 INSTALL=$ac_cv_path_install
3037 else
3038 # As a last resort, use the slow shell script. Don't cache a
3039 # value for INSTALL within a source directory, because that will
3040 # break other packages using the cache if that directory is
3041 # removed, or if the value is a relative name.
3042 INSTALL=$ac_install_sh
3043 fi
3044 fi
3045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3046 $as_echo "$INSTALL" >&6; }
3047
3048 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3049 # It thinks the first close brace ends the variable substitution.
3050 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3051
3052 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3053
3054 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3055
3056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3057 $as_echo_n "checking whether build environment is sane... " >&6; }
3058 # Reject unsafe characters in $srcdir or the absolute working directory
3059 # name. Accept space and tab only in the latter.
3060 am_lf='
3061 '
3062 case `pwd` in
3063 *[\\\"\#\$\&\'\`$am_lf]*)
3064 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3065 esac
3066 case $srcdir in
3067 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3068 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
3069 esac
3070
3071 # Do 'set' in a subshell so we don't clobber the current shell's
3072 # arguments. Must try -L first in case configure is actually a
3073 # symlink; some systems play weird games with the mod time of symlinks
3074 # (eg FreeBSD returns the mod time of the symlink's containing
3075 # directory).
3076 if (
3077 am_has_slept=no
3078 for am_try in 1 2; do
3079 echo "timestamp, slept: $am_has_slept" > conftest.file
3080 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3081 if test "$*" = "X"; then
3082 # -L didn't work.
3083 set X `ls -t "$srcdir/configure" conftest.file`
3084 fi
3085 if test "$*" != "X $srcdir/configure conftest.file" \
3086 && test "$*" != "X conftest.file $srcdir/configure"; then
3087
3088 # If neither matched, then we have a broken ls. This can happen
3089 # if, for instance, CONFIG_SHELL is bash and it inherits a
3090 # broken ls alias from the environment. This has actually
3091 # happened. Such a system could not be considered "sane".
3092 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
3093 alias in your environment" "$LINENO" 5
3094 fi
3095 if test "$2" = conftest.file || test $am_try -eq 2; then
3096 break
3097 fi
3098 # Just in case.
3099 sleep 1
3100 am_has_slept=yes
3101 done
3102 test "$2" = conftest.file
3103 )
3104 then
3105 # Ok.
3106 :
3107 else
3108 as_fn_error $? "newly created file is older than distributed files!
3109 Check your system clock" "$LINENO" 5
3110 fi
3111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3112 $as_echo "yes" >&6; }
3113 # If we didn't sleep, we still need to ensure time stamps of config.status and
3114 # generated files are strictly newer.
3115 am_sleep_pid=
3116 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
3117 ( sleep 1 ) &
3118 am_sleep_pid=$!
3119 fi
3120
3121 rm -f conftest.file
3122
3123 test "$program_prefix" != NONE &&
3124 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3125 # Use a double $ so make ignores it.
3126 test "$program_suffix" != NONE &&
3127 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3128 # Double any \ or $.
3129 # By default was `s,x,x', remove it if useless.
3130 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3131 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3132
3133 # Expand $ac_aux_dir to an absolute path.
3134 am_aux_dir=`cd "$ac_aux_dir" && pwd`
3135
3136 if test x"${MISSING+set}" != xset; then
3137 MISSING="\${SHELL} '$am_aux_dir/missing'"
3138 fi
3139 # Use eval to expand $SHELL
3140 if eval "$MISSING --is-lightweight"; then
3141 am_missing_run="$MISSING "
3142 else
3143 am_missing_run=
3144 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
3145 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
3146 fi
3147
3148 if test x"${install_sh+set}" != xset; then
3149 case $am_aux_dir in
3150 *\ * | *\ *)
3151 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3152 *)
3153 install_sh="\${SHELL} $am_aux_dir/install-sh"
3154 esac
3155 fi
3156
3157 # Installed binaries are usually stripped using 'strip' when the user
3158 # run "make install-strip". However 'strip' might not be the right
3159 # tool to use in cross-compilation environments, therefore Automake
3160 # will honor the 'STRIP' environment variable to overrule this program.
3161 if test "$cross_compiling" != no; then
3162 if test -n "$ac_tool_prefix"; then
3163 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3164 set dummy ${ac_tool_prefix}strip; ac_word=$2
3165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3166 $as_echo_n "checking for $ac_word... " >&6; }
3167 if ${ac_cv_prog_STRIP+:} false; then :
3168 $as_echo_n "(cached) " >&6
3169 else
3170 if test -n "$STRIP"; then
3171 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3172 else
3173 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3174 for as_dir in $PATH
3175 do
3176 IFS=$as_save_IFS
3177 test -z "$as_dir" && as_dir=.
3178 for ac_exec_ext in '' $ac_executable_extensions; do
3179 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3180 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3181 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3182 break 2
3183 fi
3184 done
3185 done
3186 IFS=$as_save_IFS
3187
3188 fi
3189 fi
3190 STRIP=$ac_cv_prog_STRIP
3191 if test -n "$STRIP"; then
3192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3193 $as_echo "$STRIP" >&6; }
3194 else
3195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3196 $as_echo "no" >&6; }
3197 fi
3198
3199
3200 fi
3201 if test -z "$ac_cv_prog_STRIP"; then
3202 ac_ct_STRIP=$STRIP
3203 # Extract the first word of "strip", so it can be a program name with args.
3204 set dummy strip; ac_word=$2
3205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3206 $as_echo_n "checking for $ac_word... " >&6; }
3207 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3208 $as_echo_n "(cached) " >&6
3209 else
3210 if test -n "$ac_ct_STRIP"; then
3211 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3212 else
3213 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3214 for as_dir in $PATH
3215 do
3216 IFS=$as_save_IFS
3217 test -z "$as_dir" && as_dir=.
3218 for ac_exec_ext in '' $ac_executable_extensions; do
3219 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3220 ac_cv_prog_ac_ct_STRIP="strip"
3221 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3222 break 2
3223 fi
3224 done
3225 done
3226 IFS=$as_save_IFS
3227
3228 fi
3229 fi
3230 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3231 if test -n "$ac_ct_STRIP"; then
3232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3233 $as_echo "$ac_ct_STRIP" >&6; }
3234 else
3235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3236 $as_echo "no" >&6; }
3237 fi
3238
3239 if test "x$ac_ct_STRIP" = x; then
3240 STRIP=":"
3241 else
3242 case $cross_compiling:$ac_tool_warned in
3243 yes:)
3244 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3245 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3246 ac_tool_warned=yes ;;
3247 esac
3248 STRIP=$ac_ct_STRIP
3249 fi
3250 else
3251 STRIP="$ac_cv_prog_STRIP"
3252 fi
3253
3254 fi
3255 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3256
3257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3258 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3259 if test -z "$MKDIR_P"; then
3260 if ${ac_cv_path_mkdir+:} false; then :
3261 $as_echo_n "(cached) " >&6
3262 else
3263 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3264 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3265 do
3266 IFS=$as_save_IFS
3267 test -z "$as_dir" && as_dir=.
3268 for ac_prog in mkdir gmkdir; do
3269 for ac_exec_ext in '' $ac_executable_extensions; do
3270 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
3271 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3272 'mkdir (GNU coreutils) '* | \
3273 'mkdir (coreutils) '* | \
3274 'mkdir (fileutils) '4.1*)
3275 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3276 break 3;;
3277 esac
3278 done
3279 done
3280 done
3281 IFS=$as_save_IFS
3282
3283 fi
3284
3285 test -d ./--version && rmdir ./--version
3286 if test "${ac_cv_path_mkdir+set}" = set; then
3287 MKDIR_P="$ac_cv_path_mkdir -p"
3288 else
3289 # As a last resort, use the slow shell script. Don't cache a
3290 # value for MKDIR_P within a source directory, because that will
3291 # break other packages using the cache if that directory is
3292 # removed, or if the value is a relative name.
3293 MKDIR_P="$ac_install_sh -d"
3294 fi
3295 fi
3296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3297 $as_echo "$MKDIR_P" >&6; }
3298
3299 for ac_prog in gawk mawk nawk awk
3300 do
3301 # Extract the first word of "$ac_prog", so it can be a program name with args.
3302 set dummy $ac_prog; ac_word=$2
3303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3304 $as_echo_n "checking for $ac_word... " >&6; }
3305 if ${ac_cv_prog_AWK+:} false; then :
3306 $as_echo_n "(cached) " >&6
3307 else
3308 if test -n "$AWK"; then
3309 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3310 else
3311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3312 for as_dir in $PATH
3313 do
3314 IFS=$as_save_IFS
3315 test -z "$as_dir" && as_dir=.
3316 for ac_exec_ext in '' $ac_executable_extensions; do
3317 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3318 ac_cv_prog_AWK="$ac_prog"
3319 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3320 break 2
3321 fi
3322 done
3323 done
3324 IFS=$as_save_IFS
3325
3326 fi
3327 fi
3328 AWK=$ac_cv_prog_AWK
3329 if test -n "$AWK"; then
3330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3331 $as_echo "$AWK" >&6; }
3332 else
3333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3334 $as_echo "no" >&6; }
3335 fi
3336
3337
3338 test -n "$AWK" && break
3339 done
3340
3341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3342 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3343 set x ${MAKE-make}
3344 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3345 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
3346 $as_echo_n "(cached) " >&6
3347 else
3348 cat >conftest.make <<\_ACEOF
3349 SHELL = /bin/sh
3350 all:
3351 @echo '@@@%%%=$(MAKE)=@@@%%%'
3352 _ACEOF
3353 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3354 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3355 *@@@%%%=?*=@@@%%%*)
3356 eval ac_cv_prog_make_${ac_make}_set=yes;;
3357 *)
3358 eval ac_cv_prog_make_${ac_make}_set=no;;
3359 esac
3360 rm -f conftest.make
3361 fi
3362 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3364 $as_echo "yes" >&6; }
3365 SET_MAKE=
3366 else
3367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3368 $as_echo "no" >&6; }
3369 SET_MAKE="MAKE=${MAKE-make}"
3370 fi
3371
3372 rm -rf .tst 2>/dev/null
3373 mkdir .tst 2>/dev/null
3374 if test -d .tst; then
3375 am__leading_dot=.
3376 else
3377 am__leading_dot=_
3378 fi
3379 rmdir .tst 2>/dev/null
3380
3381 # Check whether --enable-silent-rules was given.
3382 if test "${enable_silent_rules+set}" = set; then :
3383 enableval=$enable_silent_rules;
3384 fi
3385
3386 case $enable_silent_rules in # (((
3387 yes) AM_DEFAULT_VERBOSITY=0;;
3388 no) AM_DEFAULT_VERBOSITY=1;;
3389 *) AM_DEFAULT_VERBOSITY=1;;
3390 esac
3391 am_make=${MAKE-make}
3392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3393 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3394 if ${am_cv_make_support_nested_variables+:} false; then :
3395 $as_echo_n "(cached) " >&6
3396 else
3397 if $as_echo 'TRUE=$(BAR$(V))
3398 BAR0=false
3399 BAR1=true
3400 V=1
3401 am__doit:
3402 @$(TRUE)
3403 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3404 am_cv_make_support_nested_variables=yes
3405 else
3406 am_cv_make_support_nested_variables=no
3407 fi
3408 fi
3409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3410 $as_echo "$am_cv_make_support_nested_variables" >&6; }
3411 if test $am_cv_make_support_nested_variables = yes; then
3412 AM_V='$(V)'
3413 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3414 else
3415 AM_V=$AM_DEFAULT_VERBOSITY
3416 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3417 fi
3418 AM_BACKSLASH='\'
3419
3420 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3421 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3422 # is not polluted with repeated "-I."
3423 am__isrc=' -I$(srcdir)'
3424 # test to see if srcdir already configured
3425 if test -f $srcdir/config.status; then
3426 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3427 fi
3428 fi
3429
3430 # test whether we have cygpath
3431 if test -z "$CYGPATH_W"; then
3432 if (cygpath --version) >/dev/null 2>/dev/null; then
3433 CYGPATH_W='cygpath -w'
3434 else
3435 CYGPATH_W=echo
3436 fi
3437 fi
3438
3439
3440 # Define the identity of the package.
3441 PACKAGE='gpgme'
3442 VERSION='1.17.0'
3443
3444
3445 cat >>confdefs.h <<_ACEOF
3446 #define PACKAGE "$PACKAGE"
3447 _ACEOF
3448
3449
3450 cat >>confdefs.h <<_ACEOF
3451 #define VERSION "$VERSION"
3452 _ACEOF
3453
3454 # Some tools Automake needs.
3455
3456 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3457
3458
3459 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3460
3461
3462 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3463
3464
3465 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3466
3467
3468 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3469
3470 # For better backward compatibility. To be removed once Automake 1.9.x
3471 # dies out for good. For more background, see:
3472 # <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
3473 # <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
3474 mkdir_p='$(MKDIR_P)'
3475
3476 # We need awk for the "check" target (and possibly the TAP driver). The
3477 # system "awk" is bad on some platforms.
3478 # Always define AMTAR for backward compatibility. Yes, it's still used
3479 # in the wild :-( We should find a proper way to deprecate it ...
3480 AMTAR='$${TAR-tar}'
3481
3482
3483 # We'll loop over all known methods to create a tar archive until one works.
3484 _am_tools='gnutar pax cpio none'
3485
3486 am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
3487
3488
3489
3490
3491
3492
3493 # POSIX will say in a future version that running "rm -f" with no argument
3494 # is OK; and we want to be able to make that assumption in our Makefile
3495 # recipes. So use an aggressive probe to check that the usage we want is
3496 # actually supported "in the wild" to an acceptable degree.
3497 # See automake bug#10828.
3498 # To make any issue more visible, cause the running configure to be aborted
3499 # by default if the 'rm' program in use doesn't match our expectations; the
3500 # user can still override this though.
3501 if rm -f && rm -fr && rm -rf; then : OK; else
3502 cat >&2 <<'END'
3503 Oops!
3504
3505 Your 'rm' program seems unable to run without file operands specified
3506 on the command line, even when the '-f' option is present. This is contrary
3507 to the behaviour of most rm programs out there, and not conforming with
3508 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
3509
3510 Please tell bug-automake@gnu.org about your system, including the value
3511 of your $PATH and any error possibly output before this message. This
3512 can help us improve future automake versions.
3513
3514 END
3515 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
3516 echo 'Configuration will proceed anyway, since you have set the' >&2
3517 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
3518 echo >&2
3519 else
3520 cat >&2 <<'END'
3521 Aborting the configuration process, to ensure you take notice of the issue.
3522
3523 You can download and install GNU coreutils to get an 'rm' implementation
3524 that behaves properly: <https://www.gnu.org/software/coreutils/>.
3525
3526 If you want to complete the configuration process using your problematic
3527 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
3528 to "yes", and re-run configure.
3529
3530 END
3531 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
3532 fi
3533 fi
3534
3535
3536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3537 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3538 # Check whether --enable-maintainer-mode was given.
3539 if test "${enable_maintainer_mode+set}" = set; then :
3540 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3541 else
3542 USE_MAINTAINER_MODE=no
3543 fi
3544
3545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3546 $as_echo "$USE_MAINTAINER_MODE" >&6; }
3547 if test $USE_MAINTAINER_MODE = yes; then
3548 MAINTAINER_MODE_TRUE=
3549 MAINTAINER_MODE_FALSE='#'
3550 else
3551 MAINTAINER_MODE_TRUE='#'
3552 MAINTAINER_MODE_FALSE=
3553 fi
3554
3555 MAINT=$MAINTAINER_MODE_TRUE
3556
3557
3558 # Make sure we can run config.sub.
3559 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3560 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3561
3562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3563 $as_echo_n "checking build system type... " >&6; }
3564 if ${ac_cv_build+:} false; then :
3565 $as_echo_n "(cached) " >&6
3566 else
3567 ac_build_alias=$build_alias
3568 test "x$ac_build_alias" = x &&
3569 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3570 test "x$ac_build_alias" = x &&
3571 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3572 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3573 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3574
3575 fi
3576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3577 $as_echo "$ac_cv_build" >&6; }
3578 case $ac_cv_build in
3579 *-*-*) ;;
3580 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3581 esac
3582 build=$ac_cv_build
3583 ac_save_IFS=$IFS; IFS='-'
3584 set x $ac_cv_build
3585 shift
3586 build_cpu=$1
3587 build_vendor=$2
3588 shift; shift
3589 # Remember, the first character of IFS is used to create $*,
3590 # except with old shells:
3591 build_os=$*
3592 IFS=$ac_save_IFS
3593 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3594
3595
3596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3597 $as_echo_n "checking host system type... " >&6; }
3598 if ${ac_cv_host+:} false; then :
3599 $as_echo_n "(cached) " >&6
3600 else
3601 if test "x$host_alias" = x; then
3602 ac_cv_host=$ac_cv_build
3603 else
3604 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3605 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3606 fi
3607
3608 fi
3609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3610 $as_echo "$ac_cv_host" >&6; }
3611 case $ac_cv_host in
3612 *-*-*) ;;
3613 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3614 esac
3615 host=$ac_cv_host
3616 ac_save_IFS=$IFS; IFS='-'
3617 set x $ac_cv_host
3618 shift
3619 host_cpu=$1
3620 host_vendor=$2
3621 shift; shift
3622 # Remember, the first character of IFS is used to create $*,
3623 # except with old shells:
3624 host_os=$*
3625 IFS=$ac_save_IFS
3626 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3627
3628
3629 # Check whether --enable-silent-rules was given.
3630 if test "${enable_silent_rules+set}" = set; then :
3631 enableval=$enable_silent_rules;
3632 fi
3633
3634 case $enable_silent_rules in # (((
3635 yes) AM_DEFAULT_VERBOSITY=0;;
3636 no) AM_DEFAULT_VERBOSITY=1;;
3637 *) AM_DEFAULT_VERBOSITY=1;;
3638 esac
3639 am_make=${MAKE-make}
3640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3641 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3642 if ${am_cv_make_support_nested_variables+:} false; then :
3643 $as_echo_n "(cached) " >&6
3644 else
3645 if $as_echo 'TRUE=$(BAR$(V))
3646 BAR0=false
3647 BAR1=true
3648 V=1
3649 am__doit:
3650 @$(TRUE)
3651 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3652 am_cv_make_support_nested_variables=yes
3653 else
3654 am_cv_make_support_nested_variables=no
3655 fi
3656 fi
3657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3658 $as_echo "$am_cv_make_support_nested_variables" >&6; }
3659 if test $am_cv_make_support_nested_variables = yes; then
3660 AM_V='$(V)'
3661 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3662 else
3663 AM_V=$AM_DEFAULT_VERBOSITY
3664 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3665 fi
3666 AM_BACKSLASH='\'
3667
3668
3669
3670 # Enable GNU extensions on systems that have them.
3671 DEPDIR="${am__leading_dot}deps"
3672
3673 ac_config_commands="$ac_config_commands depfiles"
3674
3675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5
3676 $as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; }
3677 cat > confinc.mk << 'END'
3678 am__doit:
3679 @echo this is the am__doit target >confinc.out
3680 .PHONY: am__doit
3681 END
3682 am__include="#"
3683 am__quote=
3684 # BSD make does it like this.
3685 echo '.include "confinc.mk" # ignored' > confmf.BSD
3686 # Other make implementations (GNU, Solaris 10, AIX) do it like this.
3687 echo 'include confinc.mk # ignored' > confmf.GNU
3688 _am_result=no
3689 for s in GNU BSD; do
3690 { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5
3691 (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5
3692 ac_status=$?
3693 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3694 (exit $ac_status); }
3695 case $?:`cat confinc.out 2>/dev/null` in #(
3696 '0:this is the am__doit target') :
3697 case $s in #(
3698 BSD) :
3699 am__include='.include' am__quote='"' ;; #(
3700 *) :
3701 am__include='include' am__quote='' ;;
3702 esac ;; #(
3703 *) :
3704 ;;
3705 esac
3706 if test "$am__include" != "#"; then
3707 _am_result="yes ($s style)"
3708 break
3709 fi
3710 done
3711 rm -f confinc.* confmf.*
3712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5
3713 $as_echo "${_am_result}" >&6; }
3714
3715 # Check whether --enable-dependency-tracking was given.
3716 if test "${enable_dependency_tracking+set}" = set; then :
3717 enableval=$enable_dependency_tracking;
3718 fi
3719
3720 if test "x$enable_dependency_tracking" != xno; then
3721 am_depcomp="$ac_aux_dir/depcomp"
3722 AMDEPBACKSLASH='\'
3723 am__nodep='_no'
3724 fi
3725 if test "x$enable_dependency_tracking" != xno; then
3726 AMDEP_TRUE=
3727 AMDEP_FALSE='#'
3728 else
3729 AMDEP_TRUE='#'
3730 AMDEP_FALSE=
3731 fi
3732
3733
3734 ac_ext=c
3735 ac_cpp='$CPP $CPPFLAGS'
3736 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3737 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3738 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3739 if test -n "$ac_tool_prefix"; then
3740 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3741 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3743 $as_echo_n "checking for $ac_word... " >&6; }
3744 if ${ac_cv_prog_CC+:} false; then :
3745 $as_echo_n "(cached) " >&6
3746 else
3747 if test -n "$CC"; then
3748 ac_cv_prog_CC="$CC" # Let the user override the test.
3749 else
3750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3751 for as_dir in $PATH
3752 do
3753 IFS=$as_save_IFS
3754 test -z "$as_dir" && as_dir=.
3755 for ac_exec_ext in '' $ac_executable_extensions; do
3756 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3757 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3758 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3759 break 2
3760 fi
3761 done
3762 done
3763 IFS=$as_save_IFS
3764
3765 fi
3766 fi
3767 CC=$ac_cv_prog_CC
3768 if test -n "$CC"; then
3769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3770 $as_echo "$CC" >&6; }
3771 else
3772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3773 $as_echo "no" >&6; }
3774 fi
3775
3776
3777 fi
3778 if test -z "$ac_cv_prog_CC"; then
3779 ac_ct_CC=$CC
3780 # Extract the first word of "gcc", so it can be a program name with args.
3781 set dummy gcc; ac_word=$2
3782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3783 $as_echo_n "checking for $ac_word... " >&6; }
3784 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3785 $as_echo_n "(cached) " >&6
3786 else
3787 if test -n "$ac_ct_CC"; then
3788 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3789 else
3790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3791 for as_dir in $PATH
3792 do
3793 IFS=$as_save_IFS
3794 test -z "$as_dir" && as_dir=.
3795 for ac_exec_ext in '' $ac_executable_extensions; do
3796 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3797 ac_cv_prog_ac_ct_CC="gcc"
3798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3799 break 2
3800 fi
3801 done
3802 done
3803 IFS=$as_save_IFS
3804
3805 fi
3806 fi
3807 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3808 if test -n "$ac_ct_CC"; then
3809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3810 $as_echo "$ac_ct_CC" >&6; }
3811 else
3812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3813 $as_echo "no" >&6; }
3814 fi
3815
3816 if test "x$ac_ct_CC" = x; then
3817 CC=""
3818 else
3819 case $cross_compiling:$ac_tool_warned in
3820 yes:)
3821 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3822 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3823 ac_tool_warned=yes ;;
3824 esac
3825 CC=$ac_ct_CC
3826 fi
3827 else
3828 CC="$ac_cv_prog_CC"
3829 fi
3830
3831 if test -z "$CC"; then
3832 if test -n "$ac_tool_prefix"; then
3833 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3834 set dummy ${ac_tool_prefix}cc; ac_word=$2
3835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3836 $as_echo_n "checking for $ac_word... " >&6; }
3837 if ${ac_cv_prog_CC+:} false; then :
3838 $as_echo_n "(cached) " >&6
3839 else
3840 if test -n "$CC"; then
3841 ac_cv_prog_CC="$CC" # Let the user override the test.
3842 else
3843 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3844 for as_dir in $PATH
3845 do
3846 IFS=$as_save_IFS
3847 test -z "$as_dir" && as_dir=.
3848 for ac_exec_ext in '' $ac_executable_extensions; do
3849 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3850 ac_cv_prog_CC="${ac_tool_prefix}cc"
3851 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3852 break 2
3853 fi
3854 done
3855 done
3856 IFS=$as_save_IFS
3857
3858 fi
3859 fi
3860 CC=$ac_cv_prog_CC
3861 if test -n "$CC"; then
3862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3863 $as_echo "$CC" >&6; }
3864 else
3865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3866 $as_echo "no" >&6; }
3867 fi
3868
3869
3870 fi
3871 fi
3872 if test -z "$CC"; then
3873 # Extract the first word of "cc", so it can be a program name with args.
3874 set dummy cc; ac_word=$2
3875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3876 $as_echo_n "checking for $ac_word... " >&6; }
3877 if ${ac_cv_prog_CC+:} false; then :
3878 $as_echo_n "(cached) " >&6
3879 else
3880 if test -n "$CC"; then
3881 ac_cv_prog_CC="$CC" # Let the user override the test.
3882 else
3883 ac_prog_rejected=no
3884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3885 for as_dir in $PATH
3886 do
3887 IFS=$as_save_IFS
3888 test -z "$as_dir" && as_dir=.
3889 for ac_exec_ext in '' $ac_executable_extensions; do
3890 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3891 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3892 ac_prog_rejected=yes
3893 continue
3894 fi
3895 ac_cv_prog_CC="cc"
3896 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3897 break 2
3898 fi
3899 done
3900 done
3901 IFS=$as_save_IFS
3902
3903 if test $ac_prog_rejected = yes; then
3904 # We found a bogon in the path, so make sure we never use it.
3905 set dummy $ac_cv_prog_CC
3906 shift
3907 if test $# != 0; then
3908 # We chose a different compiler from the bogus one.
3909 # However, it has the same basename, so the bogon will be chosen
3910 # first if we set CC to just the basename; use the full file name.
3911 shift
3912 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3913 fi
3914 fi
3915 fi
3916 fi
3917 CC=$ac_cv_prog_CC
3918 if test -n "$CC"; then
3919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3920 $as_echo "$CC" >&6; }
3921 else
3922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3923 $as_echo "no" >&6; }
3924 fi
3925
3926
3927 fi
3928 if test -z "$CC"; then
3929 if test -n "$ac_tool_prefix"; then
3930 for ac_prog in cl.exe
3931 do
3932 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3933 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3935 $as_echo_n "checking for $ac_word... " >&6; }
3936 if ${ac_cv_prog_CC+:} false; then :
3937 $as_echo_n "(cached) " >&6
3938 else
3939 if test -n "$CC"; then
3940 ac_cv_prog_CC="$CC" # Let the user override the test.
3941 else
3942 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3943 for as_dir in $PATH
3944 do
3945 IFS=$as_save_IFS
3946 test -z "$as_dir" && as_dir=.
3947 for ac_exec_ext in '' $ac_executable_extensions; do
3948 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3949 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3950 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3951 break 2
3952 fi
3953 done
3954 done
3955 IFS=$as_save_IFS
3956
3957 fi
3958 fi
3959 CC=$ac_cv_prog_CC
3960 if test -n "$CC"; then
3961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3962 $as_echo "$CC" >&6; }
3963 else
3964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3965 $as_echo "no" >&6; }
3966 fi
3967
3968
3969 test -n "$CC" && break
3970 done
3971 fi
3972 if test -z "$CC"; then
3973 ac_ct_CC=$CC
3974 for ac_prog in cl.exe
3975 do
3976 # Extract the first word of "$ac_prog", so it can be a program name with args.
3977 set dummy $ac_prog; ac_word=$2
3978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3979 $as_echo_n "checking for $ac_word... " >&6; }
3980 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3981 $as_echo_n "(cached) " >&6
3982 else
3983 if test -n "$ac_ct_CC"; then
3984 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3985 else
3986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3987 for as_dir in $PATH
3988 do
3989 IFS=$as_save_IFS
3990 test -z "$as_dir" && as_dir=.
3991 for ac_exec_ext in '' $ac_executable_extensions; do
3992 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3993 ac_cv_prog_ac_ct_CC="$ac_prog"
3994 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3995 break 2
3996 fi
3997 done
3998 done
3999 IFS=$as_save_IFS
4000
4001 fi
4002 fi
4003 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4004 if test -n "$ac_ct_CC"; then
4005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4006 $as_echo "$ac_ct_CC" >&6; }
4007 else
4008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4009 $as_echo "no" >&6; }
4010 fi
4011
4012
4013 test -n "$ac_ct_CC" && break
4014 done
4015
4016 if test "x$ac_ct_CC" = x; then
4017 CC=""
4018 else
4019 case $cross_compiling:$ac_tool_warned in
4020 yes:)
4021 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4022 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4023 ac_tool_warned=yes ;;
4024 esac
4025 CC=$ac_ct_CC
4026 fi
4027 fi
4028
4029 fi
4030
4031
4032 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4033 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4034 as_fn_error $? "no acceptable C compiler found in \$PATH
4035 See \`config.log' for more details" "$LINENO" 5; }
4036
4037 # Provide some information about the compiler.
4038 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4039 set X $ac_compile
4040 ac_compiler=$2
4041 for ac_option in --version -v -V -qversion; do
4042 { { ac_try="$ac_compiler $ac_option >&5"
4043 case "(($ac_try" in
4044 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4045 *) ac_try_echo=$ac_try;;
4046 esac
4047 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4048 $as_echo "$ac_try_echo"; } >&5
4049 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4050 ac_status=$?
4051 if test -s conftest.err; then
4052 sed '10a\
4053 ... rest of stderr output deleted ...
4054 10q' conftest.err >conftest.er1
4055 cat conftest.er1 >&5
4056 fi
4057 rm -f conftest.er1 conftest.err
4058 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4059 test $ac_status = 0; }
4060 done
4061
4062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4063 /* end confdefs.h. */
4064
4065 int
4066 main ()
4067 {
4068
4069 ;
4070 return 0;
4071 }
4072 _ACEOF
4073 ac_clean_files_save=$ac_clean_files
4074 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4075 # Try to create an executable without -o first, disregard a.out.
4076 # It will help us diagnose broken compilers, and finding out an intuition
4077 # of exeext.
4078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4079 $as_echo_n "checking whether the C compiler works... " >&6; }
4080 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4081
4082 # The possible output files:
4083 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4084
4085 ac_rmfiles=
4086 for ac_file in $ac_files
4087 do
4088 case $ac_file in
4089 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4090 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4091 esac
4092 done
4093 rm -f $ac_rmfiles
4094
4095 if { { ac_try="$ac_link_default"
4096 case "(($ac_try" in
4097 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4098 *) ac_try_echo=$ac_try;;
4099 esac
4100 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4101 $as_echo "$ac_try_echo"; } >&5
4102 (eval "$ac_link_default") 2>&5
4103 ac_status=$?
4104 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4105 test $ac_status = 0; }; then :
4106 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4107 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4108 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4109 # so that the user can short-circuit this test for compilers unknown to
4110 # Autoconf.
4111 for ac_file in $ac_files ''
4112 do
4113 test -f "$ac_file" || continue
4114 case $ac_file in
4115 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4116 ;;
4117 [ab].out )
4118 # We found the default executable, but exeext='' is most
4119 # certainly right.
4120 break;;
4121 *.* )
4122 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4123 then :; else
4124 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4125 fi
4126 # We set ac_cv_exeext here because the later test for it is not
4127 # safe: cross compilers may not add the suffix if given an `-o'
4128 # argument, so we may need to know it at that point already.
4129 # Even if this section looks crufty: it has the advantage of
4130 # actually working.
4131 break;;
4132 * )
4133 break;;
4134 esac
4135 done
4136 test "$ac_cv_exeext" = no && ac_cv_exeext=
4137
4138 else
4139 ac_file=''
4140 fi
4141 if test -z "$ac_file"; then :
4142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4143 $as_echo "no" >&6; }
4144 $as_echo "$as_me: failed program was:" >&5
4145 sed 's/^/| /' conftest.$ac_ext >&5
4146
4147 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4148 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4149 as_fn_error 77 "C compiler cannot create executables
4150 See \`config.log' for more details" "$LINENO" 5; }
4151 else
4152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4153 $as_echo "yes" >&6; }
4154 fi
4155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4156 $as_echo_n "checking for C compiler default output file name... " >&6; }
4157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4158 $as_echo "$ac_file" >&6; }
4159 ac_exeext=$ac_cv_exeext
4160
4161 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4162 ac_clean_files=$ac_clean_files_save
4163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4164 $as_echo_n "checking for suffix of executables... " >&6; }
4165 if { { ac_try="$ac_link"
4166 case "(($ac_try" in
4167 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4168 *) ac_try_echo=$ac_try;;
4169 esac
4170 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4171 $as_echo "$ac_try_echo"; } >&5
4172 (eval "$ac_link") 2>&5
4173 ac_status=$?
4174 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4175 test $ac_status = 0; }; then :
4176 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4177 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4178 # work properly (i.e., refer to `conftest.exe'), while it won't with
4179 # `rm'.
4180 for ac_file in conftest.exe conftest conftest.*; do
4181 test -f "$ac_file" || continue
4182 case $ac_file in
4183 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4184 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4185 break;;
4186 * ) break;;
4187 esac
4188 done
4189 else
4190 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4191 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4192 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4193 See \`config.log' for more details" "$LINENO" 5; }
4194 fi
4195 rm -f conftest conftest$ac_cv_exeext
4196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4197 $as_echo "$ac_cv_exeext" >&6; }
4198
4199 rm -f conftest.$ac_ext
4200 EXEEXT=$ac_cv_exeext
4201 ac_exeext=$EXEEXT
4202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4203 /* end confdefs.h. */
4204 #include <stdio.h>
4205 int
4206 main ()
4207 {
4208 FILE *f = fopen ("conftest.out", "w");
4209 return ferror (f) || fclose (f) != 0;
4210
4211 ;
4212 return 0;
4213 }
4214 _ACEOF
4215 ac_clean_files="$ac_clean_files conftest.out"
4216 # Check that the compiler produces executables we can run. If not, either
4217 # the compiler is broken, or we cross compile.
4218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4219 $as_echo_n "checking whether we are cross compiling... " >&6; }
4220 if test "$cross_compiling" != yes; then
4221 { { ac_try="$ac_link"
4222 case "(($ac_try" in
4223 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4224 *) ac_try_echo=$ac_try;;
4225 esac
4226 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4227 $as_echo "$ac_try_echo"; } >&5
4228 (eval "$ac_link") 2>&5
4229 ac_status=$?
4230 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4231 test $ac_status = 0; }
4232 if { ac_try='./conftest$ac_cv_exeext'
4233 { { case "(($ac_try" in
4234 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4235 *) ac_try_echo=$ac_try;;
4236 esac
4237 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4238 $as_echo "$ac_try_echo"; } >&5
4239 (eval "$ac_try") 2>&5
4240 ac_status=$?
4241 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4242 test $ac_status = 0; }; }; then
4243 cross_compiling=no
4244 else
4245 if test "$cross_compiling" = maybe; then
4246 cross_compiling=yes
4247 else
4248 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4249 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4250 as_fn_error $? "cannot run C compiled programs.
4251 If you meant to cross compile, use \`--host'.
4252 See \`config.log' for more details" "$LINENO" 5; }
4253 fi
4254 fi
4255 fi
4256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4257 $as_echo "$cross_compiling" >&6; }
4258
4259 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4260 ac_clean_files=$ac_clean_files_save
4261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4262 $as_echo_n "checking for suffix of object files... " >&6; }
4263 if ${ac_cv_objext+:} false; then :
4264 $as_echo_n "(cached) " >&6
4265 else
4266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4267 /* end confdefs.h. */
4268
4269 int
4270 main ()
4271 {
4272
4273 ;
4274 return 0;
4275 }
4276 _ACEOF
4277 rm -f conftest.o conftest.obj
4278 if { { ac_try="$ac_compile"
4279 case "(($ac_try" in
4280 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4281 *) ac_try_echo=$ac_try;;
4282 esac
4283 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4284 $as_echo "$ac_try_echo"; } >&5
4285 (eval "$ac_compile") 2>&5
4286 ac_status=$?
4287 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4288 test $ac_status = 0; }; then :
4289 for ac_file in conftest.o conftest.obj conftest.*; do
4290 test -f "$ac_file" || continue;
4291 case $ac_file in
4292 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4293 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4294 break;;
4295 esac
4296 done
4297 else
4298 $as_echo "$as_me: failed program was:" >&5
4299 sed 's/^/| /' conftest.$ac_ext >&5
4300
4301 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4302 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4303 as_fn_error $? "cannot compute suffix of object files: cannot compile
4304 See \`config.log' for more details" "$LINENO" 5; }
4305 fi
4306 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4307 fi
4308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4309 $as_echo "$ac_cv_objext" >&6; }
4310 OBJEXT=$ac_cv_objext
4311 ac_objext=$OBJEXT
4312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4313 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4314 if ${ac_cv_c_compiler_gnu+:} false; then :
4315 $as_echo_n "(cached) " >&6
4316 else
4317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4318 /* end confdefs.h. */
4319
4320 int
4321 main ()
4322 {
4323 #ifndef __GNUC__
4324 choke me
4325 #endif
4326
4327 ;
4328 return 0;
4329 }
4330 _ACEOF
4331 if ac_fn_c_try_compile "$LINENO"; then :
4332 ac_compiler_gnu=yes
4333 else
4334 ac_compiler_gnu=no
4335 fi
4336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4337 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4338
4339 fi
4340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4341 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4342 if test $ac_compiler_gnu = yes; then
4343 GCC=yes
4344 else
4345 GCC=
4346 fi
4347 ac_test_CFLAGS=${CFLAGS+set}
4348 ac_save_CFLAGS=$CFLAGS
4349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4350 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4351 if ${ac_cv_prog_cc_g+:} false; then :
4352 $as_echo_n "(cached) " >&6
4353 else
4354 ac_save_c_werror_flag=$ac_c_werror_flag
4355 ac_c_werror_flag=yes
4356 ac_cv_prog_cc_g=no
4357 CFLAGS="-g"
4358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4359 /* end confdefs.h. */
4360
4361 int
4362 main ()
4363 {
4364
4365 ;
4366 return 0;
4367 }
4368 _ACEOF
4369 if ac_fn_c_try_compile "$LINENO"; then :
4370 ac_cv_prog_cc_g=yes
4371 else
4372 CFLAGS=""
4373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4374 /* end confdefs.h. */
4375
4376 int
4377 main ()
4378 {
4379
4380 ;
4381 return 0;
4382 }
4383 _ACEOF
4384 if ac_fn_c_try_compile "$LINENO"; then :
4385
4386 else
4387 ac_c_werror_flag=$ac_save_c_werror_flag
4388 CFLAGS="-g"
4389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4390 /* end confdefs.h. */
4391
4392 int
4393 main ()
4394 {
4395
4396 ;
4397 return 0;
4398 }
4399 _ACEOF
4400 if ac_fn_c_try_compile "$LINENO"; then :
4401 ac_cv_prog_cc_g=yes
4402 fi
4403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4404 fi
4405 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4406 fi
4407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4408 ac_c_werror_flag=$ac_save_c_werror_flag
4409 fi
4410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4411 $as_echo "$ac_cv_prog_cc_g" >&6; }
4412 if test "$ac_test_CFLAGS" = set; then
4413 CFLAGS=$ac_save_CFLAGS
4414 elif test $ac_cv_prog_cc_g = yes; then
4415 if test "$GCC" = yes; then
4416 CFLAGS="-g -O2"
4417 else
4418 CFLAGS="-g"
4419 fi
4420 else
4421 if test "$GCC" = yes; then
4422 CFLAGS="-O2"
4423 else
4424 CFLAGS=
4425 fi
4426 fi
4427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4428 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4429 if ${ac_cv_prog_cc_c89+:} false; then :
4430 $as_echo_n "(cached) " >&6
4431 else
4432 ac_cv_prog_cc_c89=no
4433 ac_save_CC=$CC
4434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4435 /* end confdefs.h. */
4436 #include <stdarg.h>
4437 #include <stdio.h>
4438 struct stat;
4439 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4440 struct buf { int x; };
4441 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4442 static char *e (p, i)
4443 char **p;
4444 int i;
4445 {
4446 return p[i];
4447 }
4448 static char *f (char * (*g) (char **, int), char **p, ...)
4449 {
4450 char *s;
4451 va_list v;
4452 va_start (v,p);
4453 s = g (p, va_arg (v,int));
4454 va_end (v);
4455 return s;
4456 }
4457
4458 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4459 function prototypes and stuff, but not '\xHH' hex character constants.
4460 These don't provoke an error unfortunately, instead are silently treated
4461 as 'x'. The following induces an error, until -std is added to get
4462 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4463 array size at least. It's necessary to write '\x00'==0 to get something
4464 that's true only with -std. */
4465 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4466
4467 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4468 inside strings and character constants. */
4469 #define FOO(x) 'x'
4470 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4471
4472 int test (int i, double x);
4473 struct s1 {int (*f) (int a);};
4474 struct s2 {int (*f) (double a);};
4475 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4476 int argc;
4477 char **argv;
4478 int
4479 main ()
4480 {
4481 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4482 ;
4483 return 0;
4484 }
4485 _ACEOF
4486 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4487 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4488 do
4489 CC="$ac_save_CC $ac_arg"
4490 if ac_fn_c_try_compile "$LINENO"; then :
4491 ac_cv_prog_cc_c89=$ac_arg
4492 fi
4493 rm -f core conftest.err conftest.$ac_objext
4494 test "x$ac_cv_prog_cc_c89" != "xno" && break
4495 done
4496 rm -f conftest.$ac_ext
4497 CC=$ac_save_CC
4498
4499 fi
4500 # AC_CACHE_VAL
4501 case "x$ac_cv_prog_cc_c89" in
4502 x)
4503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4504 $as_echo "none needed" >&6; } ;;
4505 xno)
4506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4507 $as_echo "unsupported" >&6; } ;;
4508 *)
4509 CC="$CC $ac_cv_prog_cc_c89"
4510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4511 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4512 esac
4513 if test "x$ac_cv_prog_cc_c89" != xno; then :
4514
4515 fi
4516
4517 ac_ext=c
4518 ac_cpp='$CPP $CPPFLAGS'
4519 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4520 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4521 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4522
4523 ac_ext=c
4524 ac_cpp='$CPP $CPPFLAGS'
4525 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4526 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4527 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
4529 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
4530 if ${am_cv_prog_cc_c_o+:} false; then :
4531 $as_echo_n "(cached) " >&6
4532 else
4533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4534 /* end confdefs.h. */
4535
4536 int
4537 main ()
4538 {
4539
4540 ;
4541 return 0;
4542 }
4543 _ACEOF
4544 # Make sure it works both with $CC and with simple cc.
4545 # Following AC_PROG_CC_C_O, we do the test twice because some
4546 # compilers refuse to overwrite an existing .o file with -o,
4547 # though they will create one.
4548 am_cv_prog_cc_c_o=yes
4549 for am_i in 1 2; do
4550 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
4551 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
4552 ac_status=$?
4553 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4554 (exit $ac_status); } \
4555 && test -f conftest2.$ac_objext; then
4556 : OK
4557 else
4558 am_cv_prog_cc_c_o=no
4559 break
4560 fi
4561 done
4562 rm -f core conftest*
4563 unset am_i
4564 fi
4565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
4566 $as_echo "$am_cv_prog_cc_c_o" >&6; }
4567 if test "$am_cv_prog_cc_c_o" != yes; then
4568 # Losing compiler, so override with the script.
4569 # FIXME: It is wrong to rewrite CC.
4570 # But if we don't then we get into trouble of one sort or another.
4571 # A longer-term fix would be to have automake use am__CC in this case,
4572 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4573 CC="$am_aux_dir/compile $CC"
4574 fi
4575 ac_ext=c
4576 ac_cpp='$CPP $CPPFLAGS'
4577 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4578 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4579 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4580
4581
4582 depcc="$CC" am_compiler_list=
4583
4584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4585 $as_echo_n "checking dependency style of $depcc... " >&6; }
4586 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
4587 $as_echo_n "(cached) " >&6
4588 else
4589 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4590 # We make a subdir and do the tests there. Otherwise we can end up
4591 # making bogus files that we don't know about and never remove. For
4592 # instance it was reported that on HP-UX the gcc test will end up
4593 # making a dummy file named 'D' -- because '-MD' means "put the output
4594 # in D".
4595 rm -rf conftest.dir
4596 mkdir conftest.dir
4597 # Copy depcomp to subdir because otherwise we won't find it if we're
4598 # using a relative directory.
4599 cp "$am_depcomp" conftest.dir
4600 cd conftest.dir
4601 # We will build objects and dependencies in a subdirectory because
4602 # it helps to detect inapplicable dependency modes. For instance
4603 # both Tru64's cc and ICC support -MD to output dependencies as a
4604 # side effect of compilation, but ICC will put the dependencies in
4605 # the current directory while Tru64 will put them in the object
4606 # directory.
4607 mkdir sub
4608
4609 am_cv_CC_dependencies_compiler_type=none
4610 if test "$am_compiler_list" = ""; then
4611 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4612 fi
4613 am__universal=false
4614 case " $depcc " in #(
4615 *\ -arch\ *\ -arch\ *) am__universal=true ;;
4616 esac
4617
4618 for depmode in $am_compiler_list; do
4619 # Setup a source with many dependencies, because some compilers
4620 # like to wrap large dependency lists on column 80 (with \), and
4621 # we should not choose a depcomp mode which is confused by this.
4622 #
4623 # We need to recreate these files for each test, as the compiler may
4624 # overwrite some of them when testing with obscure command lines.
4625 # This happens at least with the AIX C compiler.
4626 : > sub/conftest.c
4627 for i in 1 2 3 4 5 6; do
4628 echo '#include "conftst'$i'.h"' >> sub/conftest.c
4629 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
4630 # Solaris 10 /bin/sh.
4631 echo '/* dummy */' > sub/conftst$i.h
4632 done
4633 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4634
4635 # We check with '-c' and '-o' for the sake of the "dashmstdout"
4636 # mode. It turns out that the SunPro C++ compiler does not properly
4637 # handle '-M -o', and we need to detect this. Also, some Intel
4638 # versions had trouble with output in subdirs.
4639 am__obj=sub/conftest.${OBJEXT-o}
4640 am__minus_obj="-o $am__obj"
4641 case $depmode in
4642 gcc)
4643 # This depmode causes a compiler race in universal mode.
4644 test "$am__universal" = false || continue
4645 ;;
4646 nosideeffect)
4647 # After this tag, mechanisms are not by side-effect, so they'll
4648 # only be used when explicitly requested.
4649 if test "x$enable_dependency_tracking" = xyes; then
4650 continue
4651 else
4652 break
4653 fi
4654 ;;
4655 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
4656 # This compiler won't grok '-c -o', but also, the minuso test has
4657 # not run yet. These depmodes are late enough in the game, and
4658 # so weak that their functioning should not be impacted.
4659 am__obj=conftest.${OBJEXT-o}
4660 am__minus_obj=
4661 ;;
4662 none) break ;;
4663 esac
4664 if depmode=$depmode \
4665 source=sub/conftest.c object=$am__obj \
4666 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4667 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4668 >/dev/null 2>conftest.err &&
4669 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4670 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4671 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4672 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4673 # icc doesn't choke on unknown options, it will just issue warnings
4674 # or remarks (even with -Werror). So we grep stderr for any message
4675 # that says an option was ignored or not supported.
4676 # When given -MP, icc 7.0 and 7.1 complain thusly:
4677 # icc: Command line warning: ignoring option '-M'; no argument required
4678 # The diagnosis changed in icc 8.0:
4679 # icc: Command line remark: option '-MP' not supported
4680 if (grep 'ignoring option' conftest.err ||
4681 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4682 am_cv_CC_dependencies_compiler_type=$depmode
4683 break
4684 fi
4685 fi
4686 done
4687
4688 cd ..
4689 rm -rf conftest.dir
4690 else
4691 am_cv_CC_dependencies_compiler_type=none
4692 fi
4693
4694 fi
4695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4696 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4697 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4698
4699 if
4700 test "x$enable_dependency_tracking" != xno \
4701 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
4702 am__fastdepCC_TRUE=
4703 am__fastdepCC_FALSE='#'
4704 else
4705 am__fastdepCC_TRUE='#'
4706 am__fastdepCC_FALSE=
4707 fi
4708
4709
4710
4711 ac_ext=c
4712 ac_cpp='$CPP $CPPFLAGS'
4713 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4714 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4715 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4717 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4718 # On Suns, sometimes $CPP names a directory.
4719 if test -n "$CPP" && test -d "$CPP"; then
4720 CPP=
4721 fi
4722 if test -z "$CPP"; then
4723 if ${ac_cv_prog_CPP+:} false; then :
4724 $as_echo_n "(cached) " >&6
4725 else
4726 # Double quotes because CPP needs to be expanded
4727 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4728 do
4729 ac_preproc_ok=false
4730 for ac_c_preproc_warn_flag in '' yes
4731 do
4732 # Use a header file that comes with gcc, so configuring glibc
4733 # with a fresh cross-compiler works.
4734 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4735 # <limits.h> exists even on freestanding compilers.
4736 # On the NeXT, cc -E runs the code through the compiler's parser,
4737 # not just through cpp. "Syntax error" is here to catch this case.
4738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4739 /* end confdefs.h. */
4740 #ifdef __STDC__
4741 # include <limits.h>
4742 #else
4743 # include <assert.h>
4744 #endif
4745 Syntax error
4746 _ACEOF
4747 if ac_fn_c_try_cpp "$LINENO"; then :
4748
4749 else
4750 # Broken: fails on valid input.
4751 continue
4752 fi
4753 rm -f conftest.err conftest.i conftest.$ac_ext
4754
4755 # OK, works on sane cases. Now check whether nonexistent headers
4756 # can be detected and how.
4757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4758 /* end confdefs.h. */
4759 #include <ac_nonexistent.h>
4760 _ACEOF
4761 if ac_fn_c_try_cpp "$LINENO"; then :
4762 # Broken: success on invalid input.
4763 continue
4764 else
4765 # Passes both tests.
4766 ac_preproc_ok=:
4767 break
4768 fi
4769 rm -f conftest.err conftest.i conftest.$ac_ext
4770
4771 done
4772 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4773 rm -f conftest.i conftest.err conftest.$ac_ext
4774 if $ac_preproc_ok; then :
4775 break
4776 fi
4777
4778 done
4779 ac_cv_prog_CPP=$CPP
4780
4781 fi
4782 CPP=$ac_cv_prog_CPP
4783 else
4784 ac_cv_prog_CPP=$CPP
4785 fi
4786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4787 $as_echo "$CPP" >&6; }
4788 ac_preproc_ok=false
4789 for ac_c_preproc_warn_flag in '' yes
4790 do
4791 # Use a header file that comes with gcc, so configuring glibc
4792 # with a fresh cross-compiler works.
4793 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4794 # <limits.h> exists even on freestanding compilers.
4795 # On the NeXT, cc -E runs the code through the compiler's parser,
4796 # not just through cpp. "Syntax error" is here to catch this case.
4797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4798 /* end confdefs.h. */
4799 #ifdef __STDC__
4800 # include <limits.h>
4801 #else
4802 # include <assert.h>
4803 #endif
4804 Syntax error
4805 _ACEOF
4806 if ac_fn_c_try_cpp "$LINENO"; then :
4807
4808 else
4809 # Broken: fails on valid input.
4810 continue
4811 fi
4812 rm -f conftest.err conftest.i conftest.$ac_ext
4813
4814 # OK, works on sane cases. Now check whether nonexistent headers
4815 # can be detected and how.
4816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4817 /* end confdefs.h. */
4818 #include <ac_nonexistent.h>
4819 _ACEOF
4820 if ac_fn_c_try_cpp "$LINENO"; then :
4821 # Broken: success on invalid input.
4822 continue
4823 else
4824 # Passes both tests.
4825 ac_preproc_ok=:
4826 break
4827 fi
4828 rm -f conftest.err conftest.i conftest.$ac_ext
4829
4830 done
4831 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4832 rm -f conftest.i conftest.err conftest.$ac_ext
4833 if $ac_preproc_ok; then :
4834
4835 else
4836 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4837 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4838 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4839 See \`config.log' for more details" "$LINENO" 5; }
4840 fi
4841
4842 ac_ext=c
4843 ac_cpp='$CPP $CPPFLAGS'
4844 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4845 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4846 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4847
4848
4849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4850 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4851 if ${ac_cv_path_GREP+:} false; then :
4852 $as_echo_n "(cached) " >&6
4853 else
4854 if test -z "$GREP"; then
4855 ac_path_GREP_found=false
4856 # Loop through the user's path and test for each of PROGNAME-LIST
4857 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4858 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4859 do
4860 IFS=$as_save_IFS
4861 test -z "$as_dir" && as_dir=.
4862 for ac_prog in grep ggrep; do
4863 for ac_exec_ext in '' $ac_executable_extensions; do
4864 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4865 as_fn_executable_p "$ac_path_GREP" || continue
4866 # Check for GNU ac_path_GREP and select it if it is found.
4867 # Check for GNU $ac_path_GREP
4868 case `"$ac_path_GREP" --version 2>&1` in
4869 *GNU*)
4870 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4871 *)
4872 ac_count=0
4873 $as_echo_n 0123456789 >"conftest.in"
4874 while :
4875 do
4876 cat "conftest.in" "conftest.in" >"conftest.tmp"
4877 mv "conftest.tmp" "conftest.in"
4878 cp "conftest.in" "conftest.nl"
4879 $as_echo 'GREP' >> "conftest.nl"
4880 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4881 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4882 as_fn_arith $ac_count + 1 && ac_count=$as_val
4883 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4884 # Best one so far, save it but keep looking for a better one
4885 ac_cv_path_GREP="$ac_path_GREP"
4886 ac_path_GREP_max=$ac_count
4887 fi
4888 # 10*(2^10) chars as input seems more than enough
4889 test $ac_count -gt 10 && break
4890 done
4891 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4892 esac
4893
4894 $ac_path_GREP_found && break 3
4895 done
4896 done
4897 done
4898 IFS=$as_save_IFS
4899 if test -z "$ac_cv_path_GREP"; then
4900 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4901 fi
4902 else
4903 ac_cv_path_GREP=$GREP
4904 fi
4905
4906 fi
4907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4908 $as_echo "$ac_cv_path_GREP" >&6; }
4909 GREP="$ac_cv_path_GREP"
4910
4911
4912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4913 $as_echo_n "checking for egrep... " >&6; }
4914 if ${ac_cv_path_EGREP+:} false; then :
4915 $as_echo_n "(cached) " >&6
4916 else
4917 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4918 then ac_cv_path_EGREP="$GREP -E"
4919 else
4920 if test -z "$EGREP"; then
4921 ac_path_EGREP_found=false
4922 # Loop through the user's path and test for each of PROGNAME-LIST
4923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4924 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4925 do
4926 IFS=$as_save_IFS
4927 test -z "$as_dir" && as_dir=.
4928 for ac_prog in egrep; do
4929 for ac_exec_ext in '' $ac_executable_extensions; do
4930 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4931 as_fn_executable_p "$ac_path_EGREP" || continue
4932 # Check for GNU ac_path_EGREP and select it if it is found.
4933 # Check for GNU $ac_path_EGREP
4934 case `"$ac_path_EGREP" --version 2>&1` in
4935 *GNU*)
4936 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4937 *)
4938 ac_count=0
4939 $as_echo_n 0123456789 >"conftest.in"
4940 while :
4941 do
4942 cat "conftest.in" "conftest.in" >"conftest.tmp"
4943 mv "conftest.tmp" "conftest.in"
4944 cp "conftest.in" "conftest.nl"
4945 $as_echo 'EGREP' >> "conftest.nl"
4946 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4947 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4948 as_fn_arith $ac_count + 1 && ac_count=$as_val
4949 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4950 # Best one so far, save it but keep looking for a better one
4951 ac_cv_path_EGREP="$ac_path_EGREP"
4952 ac_path_EGREP_max=$ac_count
4953 fi
4954 # 10*(2^10) chars as input seems more than enough
4955 test $ac_count -gt 10 && break
4956 done
4957 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4958 esac
4959
4960 $ac_path_EGREP_found && break 3
4961 done
4962 done
4963 done
4964 IFS=$as_save_IFS
4965 if test -z "$ac_cv_path_EGREP"; then
4966 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4967 fi
4968 else
4969 ac_cv_path_EGREP=$EGREP
4970 fi
4971
4972 fi
4973 fi
4974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4975 $as_echo "$ac_cv_path_EGREP" >&6; }
4976 EGREP="$ac_cv_path_EGREP"
4977
4978
4979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4980 $as_echo_n "checking for ANSI C header files... " >&6; }
4981 if ${ac_cv_header_stdc+:} false; then :
4982 $as_echo_n "(cached) " >&6
4983 else
4984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4985 /* end confdefs.h. */
4986 #include <stdlib.h>
4987 #include <stdarg.h>
4988 #include <string.h>
4989 #include <float.h>
4990
4991 int
4992 main ()
4993 {
4994
4995 ;
4996 return 0;
4997 }
4998 _ACEOF
4999 if ac_fn_c_try_compile "$LINENO"; then :
5000 ac_cv_header_stdc=yes
5001 else
5002 ac_cv_header_stdc=no
5003 fi
5004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5005
5006 if test $ac_cv_header_stdc = yes; then
5007 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5009 /* end confdefs.h. */
5010 #include <string.h>
5011
5012 _ACEOF
5013 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5014 $EGREP "memchr" >/dev/null 2>&1; then :
5015
5016 else
5017 ac_cv_header_stdc=no
5018 fi
5019 rm -f conftest*
5020
5021 fi
5022
5023 if test $ac_cv_header_stdc = yes; then
5024 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5026 /* end confdefs.h. */
5027 #include <stdlib.h>
5028
5029 _ACEOF
5030 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5031 $EGREP "free" >/dev/null 2>&1; then :
5032
5033 else
5034 ac_cv_header_stdc=no
5035 fi
5036 rm -f conftest*
5037
5038 fi
5039
5040 if test $ac_cv_header_stdc = yes; then
5041 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5042 if test "$cross_compiling" = yes; then :
5043 :
5044 else
5045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5046 /* end confdefs.h. */
5047 #include <ctype.h>
5048 #include <stdlib.h>
5049 #if ((' ' & 0x0FF) == 0x020)
5050 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5051 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5052 #else
5053 # define ISLOWER(c) \
5054 (('a' <= (c) && (c) <= 'i') \
5055 || ('j' <= (c) && (c) <= 'r') \
5056 || ('s' <= (c) && (c) <= 'z'))
5057 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5058 #endif
5059
5060 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5061 int
5062 main ()
5063 {
5064 int i;
5065 for (i = 0; i < 256; i++)
5066 if (XOR (islower (i), ISLOWER (i))
5067 || toupper (i) != TOUPPER (i))
5068 return 2;
5069 return 0;
5070 }
5071 _ACEOF
5072 if ac_fn_c_try_run "$LINENO"; then :
5073
5074 else
5075 ac_cv_header_stdc=no
5076 fi
5077 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5078 conftest.$ac_objext conftest.beam conftest.$ac_ext
5079 fi
5080
5081 fi
5082 fi
5083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
5084 $as_echo "$ac_cv_header_stdc" >&6; }
5085 if test $ac_cv_header_stdc = yes; then
5086
5087 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
5088
5089 fi
5090
5091 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
5092 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5093 inttypes.h stdint.h unistd.h
5094 do :
5095 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5096 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5097 "
5098 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5099 cat >>confdefs.h <<_ACEOF
5100 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5101 _ACEOF
5102
5103 fi
5104
5105 done
5106
5107
5108
5109 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
5110 if test "x$ac_cv_header_minix_config_h" = xyes; then :
5111 MINIX=yes
5112 else
5113 MINIX=
5114 fi
5115
5116
5117 if test "$MINIX" = yes; then
5118
5119 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
5120
5121
5122 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
5123
5124
5125 $as_echo "#define _MINIX 1" >>confdefs.h
5126
5127 fi
5128
5129
5130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5131 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5132 if ${ac_cv_safe_to_define___extensions__+:} false; then :
5133 $as_echo_n "(cached) " >&6
5134 else
5135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5136 /* end confdefs.h. */
5137
5138 # define __EXTENSIONS__ 1
5139 $ac_includes_default
5140 int
5141 main ()
5142 {
5143
5144 ;
5145 return 0;
5146 }
5147 _ACEOF
5148 if ac_fn_c_try_compile "$LINENO"; then :
5149 ac_cv_safe_to_define___extensions__=yes
5150 else
5151 ac_cv_safe_to_define___extensions__=no
5152 fi
5153 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5154 fi
5155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5156 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
5157 test $ac_cv_safe_to_define___extensions__ = yes &&
5158 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
5159
5160 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
5161
5162 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
5163
5164 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5165
5166 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
5167
5168
5169
5170 # Taken from mpfr-4.0.1, then modified for LDADD_FOR_TESTS_KLUDGE
5171 case $host in
5172 *-*-linux*)
5173 if test -n "$LD_LIBRARY_PATH"; then
5174 saved_LDFLAGS="$LDFLAGS"
5175 LDADD_FOR_TESTS_KLUDGE="-Wl,--disable-new-dtags"
5176 LDFLAGS="$LDFLAGS $LDADD_FOR_TESTS_KLUDGE"
5177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether --disable-new-dtags is supported by the linker" >&5
5178 $as_echo_n "checking whether --disable-new-dtags is supported by the linker... " >&6; }
5179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5180 /* end confdefs.h. */
5181
5182 int main (void) { return 0; }
5183
5184 _ACEOF
5185 if ac_fn_c_try_link "$LINENO"; then :
5186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (use it since LD_LIBRARY_PATH is set)" >&5
5187 $as_echo "yes (use it since LD_LIBRARY_PATH is set)" >&6; }
5188 else
5189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5190 $as_echo "no" >&6; }
5191 LDADD_FOR_TESTS_KLUDGE=""
5192
5193 fi
5194 rm -f core conftest.err conftest.$ac_objext \
5195 conftest$ac_exeext conftest.$ac_ext
5196 LDFLAGS="$saved_LDFLAGS"
5197 fi
5198 ;;
5199 esac
5200
5201
5202
5203
5204 ac_ext=c
5205 ac_cpp='$CPP $CPPFLAGS'
5206 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5207 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5208 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5209 if test -n "$ac_tool_prefix"; then
5210 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
5211 set dummy ${ac_tool_prefix}gcc; ac_word=$2
5212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5213 $as_echo_n "checking for $ac_word... " >&6; }
5214 if ${ac_cv_prog_CC+:} false; then :
5215 $as_echo_n "(cached) " >&6
5216 else
5217 if test -n "$CC"; then
5218 ac_cv_prog_CC="$CC" # Let the user override the test.
5219 else
5220 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5221 for as_dir in $PATH
5222 do
5223 IFS=$as_save_IFS
5224 test -z "$as_dir" && as_dir=.
5225 for ac_exec_ext in '' $ac_executable_extensions; do
5226 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5227 ac_cv_prog_CC="${ac_tool_prefix}gcc"
5228 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5229 break 2
5230 fi
5231 done
5232 done
5233 IFS=$as_save_IFS
5234
5235 fi
5236 fi
5237 CC=$ac_cv_prog_CC
5238 if test -n "$CC"; then
5239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5240 $as_echo "$CC" >&6; }
5241 else
5242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5243 $as_echo "no" >&6; }
5244 fi
5245
5246
5247 fi
5248 if test -z "$ac_cv_prog_CC"; then
5249 ac_ct_CC=$CC
5250 # Extract the first word of "gcc", so it can be a program name with args.
5251 set dummy gcc; ac_word=$2
5252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5253 $as_echo_n "checking for $ac_word... " >&6; }
5254 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5255 $as_echo_n "(cached) " >&6
5256 else
5257 if test -n "$ac_ct_CC"; then
5258 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5259 else
5260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5261 for as_dir in $PATH
5262 do
5263 IFS=$as_save_IFS
5264 test -z "$as_dir" && as_dir=.
5265 for ac_exec_ext in '' $ac_executable_extensions; do
5266 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5267 ac_cv_prog_ac_ct_CC="gcc"
5268 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5269 break 2
5270 fi
5271 done
5272 done
5273 IFS=$as_save_IFS
5274
5275 fi
5276 fi
5277 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5278 if test -n "$ac_ct_CC"; then
5279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5280 $as_echo "$ac_ct_CC" >&6; }
5281 else
5282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5283 $as_echo "no" >&6; }
5284 fi
5285
5286 if test "x$ac_ct_CC" = x; then
5287 CC=""
5288 else
5289 case $cross_compiling:$ac_tool_warned in
5290 yes:)
5291 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5292 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5293 ac_tool_warned=yes ;;
5294 esac
5295 CC=$ac_ct_CC
5296 fi
5297 else
5298 CC="$ac_cv_prog_CC"
5299 fi
5300
5301 if test -z "$CC"; then
5302 if test -n "$ac_tool_prefix"; then
5303 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5304 set dummy ${ac_tool_prefix}cc; ac_word=$2
5305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5306 $as_echo_n "checking for $ac_word... " >&6; }
5307 if ${ac_cv_prog_CC+:} false; then :
5308 $as_echo_n "(cached) " >&6
5309 else
5310 if test -n "$CC"; then
5311 ac_cv_prog_CC="$CC" # Let the user override the test.
5312 else
5313 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5314 for as_dir in $PATH
5315 do
5316 IFS=$as_save_IFS
5317 test -z "$as_dir" && as_dir=.
5318 for ac_exec_ext in '' $ac_executable_extensions; do
5319 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5320 ac_cv_prog_CC="${ac_tool_prefix}cc"
5321 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5322 break 2
5323 fi
5324 done
5325 done
5326 IFS=$as_save_IFS
5327
5328 fi
5329 fi
5330 CC=$ac_cv_prog_CC
5331 if test -n "$CC"; then
5332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5333 $as_echo "$CC" >&6; }
5334 else
5335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5336 $as_echo "no" >&6; }
5337 fi
5338
5339
5340 fi
5341 fi
5342 if test -z "$CC"; then
5343 # Extract the first word of "cc", so it can be a program name with args.
5344 set dummy cc; ac_word=$2
5345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5346 $as_echo_n "checking for $ac_word... " >&6; }
5347 if ${ac_cv_prog_CC+:} false; then :
5348 $as_echo_n "(cached) " >&6
5349 else
5350 if test -n "$CC"; then
5351 ac_cv_prog_CC="$CC" # Let the user override the test.
5352 else
5353 ac_prog_rejected=no
5354 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5355 for as_dir in $PATH
5356 do
5357 IFS=$as_save_IFS
5358 test -z "$as_dir" && as_dir=.
5359 for ac_exec_ext in '' $ac_executable_extensions; do
5360 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5361 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5362 ac_prog_rejected=yes
5363 continue
5364 fi
5365 ac_cv_prog_CC="cc"
5366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5367 break 2
5368 fi
5369 done
5370 done
5371 IFS=$as_save_IFS
5372
5373 if test $ac_prog_rejected = yes; then
5374 # We found a bogon in the path, so make sure we never use it.
5375 set dummy $ac_cv_prog_CC
5376 shift
5377 if test $# != 0; then
5378 # We chose a different compiler from the bogus one.
5379 # However, it has the same basename, so the bogon will be chosen
5380 # first if we set CC to just the basename; use the full file name.
5381 shift
5382 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5383 fi
5384 fi
5385 fi
5386 fi
5387 CC=$ac_cv_prog_CC
5388 if test -n "$CC"; then
5389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5390 $as_echo "$CC" >&6; }
5391 else
5392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5393 $as_echo "no" >&6; }
5394 fi
5395
5396
5397 fi
5398 if test -z "$CC"; then
5399 if test -n "$ac_tool_prefix"; then
5400 for ac_prog in cl.exe
5401 do
5402 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5403 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5405 $as_echo_n "checking for $ac_word... " >&6; }
5406 if ${ac_cv_prog_CC+:} false; then :
5407 $as_echo_n "(cached) " >&6
5408 else
5409 if test -n "$CC"; then
5410 ac_cv_prog_CC="$CC" # Let the user override the test.
5411 else
5412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5413 for as_dir in $PATH
5414 do
5415 IFS=$as_save_IFS
5416 test -z "$as_dir" && as_dir=.
5417 for ac_exec_ext in '' $ac_executable_extensions; do
5418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5419 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5421 break 2
5422 fi
5423 done
5424 done
5425 IFS=$as_save_IFS
5426
5427 fi
5428 fi
5429 CC=$ac_cv_prog_CC
5430 if test -n "$CC"; then
5431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5432 $as_echo "$CC" >&6; }
5433 else
5434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5435 $as_echo "no" >&6; }
5436 fi
5437
5438
5439 test -n "$CC" && break
5440 done
5441 fi
5442 if test -z "$CC"; then
5443 ac_ct_CC=$CC
5444 for ac_prog in cl.exe
5445 do
5446 # Extract the first word of "$ac_prog", so it can be a program name with args.
5447 set dummy $ac_prog; ac_word=$2
5448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5449 $as_echo_n "checking for $ac_word... " >&6; }
5450 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5451 $as_echo_n "(cached) " >&6
5452 else
5453 if test -n "$ac_ct_CC"; then
5454 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5455 else
5456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5457 for as_dir in $PATH
5458 do
5459 IFS=$as_save_IFS
5460 test -z "$as_dir" && as_dir=.
5461 for ac_exec_ext in '' $ac_executable_extensions; do
5462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5463 ac_cv_prog_ac_ct_CC="$ac_prog"
5464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5465 break 2
5466 fi
5467 done
5468 done
5469 IFS=$as_save_IFS
5470
5471 fi
5472 fi
5473 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5474 if test -n "$ac_ct_CC"; then
5475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5476 $as_echo "$ac_ct_CC" >&6; }
5477 else
5478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5479 $as_echo "no" >&6; }
5480 fi
5481
5482
5483 test -n "$ac_ct_CC" && break
5484 done
5485
5486 if test "x$ac_ct_CC" = x; then
5487 CC=""
5488 else
5489 case $cross_compiling:$ac_tool_warned in
5490 yes:)
5491 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5492 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5493 ac_tool_warned=yes ;;
5494 esac
5495 CC=$ac_ct_CC
5496 fi
5497 fi
5498
5499 fi
5500
5501
5502 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5503 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5504 as_fn_error $? "no acceptable C compiler found in \$PATH
5505 See \`config.log' for more details" "$LINENO" 5; }
5506
5507 # Provide some information about the compiler.
5508 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5509 set X $ac_compile
5510 ac_compiler=$2
5511 for ac_option in --version -v -V -qversion; do
5512 { { ac_try="$ac_compiler $ac_option >&5"
5513 case "(($ac_try" in
5514 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5515 *) ac_try_echo=$ac_try;;
5516 esac
5517 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5518 $as_echo "$ac_try_echo"; } >&5
5519 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5520 ac_status=$?
5521 if test -s conftest.err; then
5522 sed '10a\
5523 ... rest of stderr output deleted ...
5524 10q' conftest.err >conftest.er1
5525 cat conftest.er1 >&5
5526 fi
5527 rm -f conftest.er1 conftest.err
5528 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5529 test $ac_status = 0; }
5530 done
5531
5532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5533 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5534 if ${ac_cv_c_compiler_gnu+:} false; then :
5535 $as_echo_n "(cached) " >&6
5536 else
5537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5538 /* end confdefs.h. */
5539
5540 int
5541 main ()
5542 {
5543 #ifndef __GNUC__
5544 choke me
5545 #endif
5546
5547 ;
5548 return 0;
5549 }
5550 _ACEOF
5551 if ac_fn_c_try_compile "$LINENO"; then :
5552 ac_compiler_gnu=yes
5553 else
5554 ac_compiler_gnu=no
5555 fi
5556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5557 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5558
5559 fi
5560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5561 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5562 if test $ac_compiler_gnu = yes; then
5563 GCC=yes
5564 else
5565 GCC=
5566 fi
5567 ac_test_CFLAGS=${CFLAGS+set}
5568 ac_save_CFLAGS=$CFLAGS
5569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5570 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5571 if ${ac_cv_prog_cc_g+:} false; then :
5572 $as_echo_n "(cached) " >&6
5573 else
5574 ac_save_c_werror_flag=$ac_c_werror_flag
5575 ac_c_werror_flag=yes
5576 ac_cv_prog_cc_g=no
5577 CFLAGS="-g"
5578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5579 /* end confdefs.h. */
5580
5581 int
5582 main ()
5583 {
5584
5585 ;
5586 return 0;
5587 }
5588 _ACEOF
5589 if ac_fn_c_try_compile "$LINENO"; then :
5590 ac_cv_prog_cc_g=yes
5591 else
5592 CFLAGS=""
5593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5594 /* end confdefs.h. */
5595
5596 int
5597 main ()
5598 {
5599
5600 ;
5601 return 0;
5602 }
5603 _ACEOF
5604 if ac_fn_c_try_compile "$LINENO"; then :
5605
5606 else
5607 ac_c_werror_flag=$ac_save_c_werror_flag
5608 CFLAGS="-g"
5609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5610 /* end confdefs.h. */
5611
5612 int
5613 main ()
5614 {
5615
5616 ;
5617 return 0;
5618 }
5619 _ACEOF
5620 if ac_fn_c_try_compile "$LINENO"; then :
5621 ac_cv_prog_cc_g=yes
5622 fi
5623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5624 fi
5625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5626 fi
5627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5628 ac_c_werror_flag=$ac_save_c_werror_flag
5629 fi
5630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5631 $as_echo "$ac_cv_prog_cc_g" >&6; }
5632 if test "$ac_test_CFLAGS" = set; then
5633 CFLAGS=$ac_save_CFLAGS
5634 elif test $ac_cv_prog_cc_g = yes; then
5635 if test "$GCC" = yes; then
5636 CFLAGS="-g -O2"
5637 else
5638 CFLAGS="-g"
5639 fi
5640 else
5641 if test "$GCC" = yes; then
5642 CFLAGS="-O2"
5643 else
5644 CFLAGS=
5645 fi
5646 fi
5647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5648 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5649 if ${ac_cv_prog_cc_c89+:} false; then :
5650 $as_echo_n "(cached) " >&6
5651 else
5652 ac_cv_prog_cc_c89=no
5653 ac_save_CC=$CC
5654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5655 /* end confdefs.h. */
5656 #include <stdarg.h>
5657 #include <stdio.h>
5658 struct stat;
5659 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5660 struct buf { int x; };
5661 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5662 static char *e (p, i)
5663 char **p;
5664 int i;
5665 {
5666 return p[i];
5667 }
5668 static char *f (char * (*g) (char **, int), char **p, ...)
5669 {
5670 char *s;
5671 va_list v;
5672 va_start (v,p);
5673 s = g (p, va_arg (v,int));
5674 va_end (v);
5675 return s;
5676 }
5677
5678 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5679 function prototypes and stuff, but not '\xHH' hex character constants.
5680 These don't provoke an error unfortunately, instead are silently treated
5681 as 'x'. The following induces an error, until -std is added to get
5682 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5683 array size at least. It's necessary to write '\x00'==0 to get something
5684 that's true only with -std. */
5685 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5686
5687 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5688 inside strings and character constants. */
5689 #define FOO(x) 'x'
5690 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5691
5692 int test (int i, double x);
5693 struct s1 {int (*f) (int a);};
5694 struct s2 {int (*f) (double a);};
5695 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5696 int argc;
5697 char **argv;
5698 int
5699 main ()
5700 {
5701 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5702 ;
5703 return 0;
5704 }
5705 _ACEOF
5706 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5707 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5708 do
5709 CC="$ac_save_CC $ac_arg"
5710 if ac_fn_c_try_compile "$LINENO"; then :
5711 ac_cv_prog_cc_c89=$ac_arg
5712 fi
5713 rm -f core conftest.err conftest.$ac_objext
5714 test "x$ac_cv_prog_cc_c89" != "xno" && break
5715 done
5716 rm -f conftest.$ac_ext
5717 CC=$ac_save_CC
5718
5719 fi
5720 # AC_CACHE_VAL
5721 case "x$ac_cv_prog_cc_c89" in
5722 x)
5723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5724 $as_echo "none needed" >&6; } ;;
5725 xno)
5726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5727 $as_echo "unsupported" >&6; } ;;
5728 *)
5729 CC="$CC $ac_cv_prog_cc_c89"
5730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5731 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5732 esac
5733 if test "x$ac_cv_prog_cc_c89" != xno; then :
5734
5735 fi
5736
5737 ac_ext=c
5738 ac_cpp='$CPP $CPPFLAGS'
5739 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5740 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5741 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5742
5743 ac_ext=c
5744 ac_cpp='$CPP $CPPFLAGS'
5745 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5746 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5747 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
5749 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
5750 if ${am_cv_prog_cc_c_o+:} false; then :
5751 $as_echo_n "(cached) " >&6
5752 else
5753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5754 /* end confdefs.h. */
5755
5756 int
5757 main ()
5758 {
5759
5760 ;
5761 return 0;
5762 }
5763 _ACEOF
5764 # Make sure it works both with $CC and with simple cc.
5765 # Following AC_PROG_CC_C_O, we do the test twice because some
5766 # compilers refuse to overwrite an existing .o file with -o,
5767 # though they will create one.
5768 am_cv_prog_cc_c_o=yes
5769 for am_i in 1 2; do
5770 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
5771 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
5772 ac_status=$?
5773 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5774 (exit $ac_status); } \
5775 && test -f conftest2.$ac_objext; then
5776 : OK
5777 else
5778 am_cv_prog_cc_c_o=no
5779 break
5780 fi
5781 done
5782 rm -f core conftest*
5783 unset am_i
5784 fi
5785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
5786 $as_echo "$am_cv_prog_cc_c_o" >&6; }
5787 if test "$am_cv_prog_cc_c_o" != yes; then
5788 # Losing compiler, so override with the script.
5789 # FIXME: It is wrong to rewrite CC.
5790 # But if we don't then we get into trouble of one sort or another.
5791 # A longer-term fix would be to have automake use am__CC in this case,
5792 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5793 CC="$am_aux_dir/compile $CC"
5794 fi
5795 ac_ext=c
5796 ac_cpp='$CPP $CPPFLAGS'
5797 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5798 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5799 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5800
5801
5802 depcc="$CC" am_compiler_list=
5803
5804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5805 $as_echo_n "checking dependency style of $depcc... " >&6; }
5806 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5807 $as_echo_n "(cached) " >&6
5808 else
5809 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5810 # We make a subdir and do the tests there. Otherwise we can end up
5811 # making bogus files that we don't know about and never remove. For
5812 # instance it was reported that on HP-UX the gcc test will end up
5813 # making a dummy file named 'D' -- because '-MD' means "put the output
5814 # in D".
5815 rm -rf conftest.dir
5816 mkdir conftest.dir
5817 # Copy depcomp to subdir because otherwise we won't find it if we're
5818 # using a relative directory.
5819 cp "$am_depcomp" conftest.dir
5820 cd conftest.dir
5821 # We will build objects and dependencies in a subdirectory because
5822 # it helps to detect inapplicable dependency modes. For instance
5823 # both Tru64's cc and ICC support -MD to output dependencies as a
5824 # side effect of compilation, but ICC will put the dependencies in
5825 # the current directory while Tru64 will put them in the object
5826 # directory.
5827 mkdir sub
5828
5829 am_cv_CC_dependencies_compiler_type=none
5830 if test "$am_compiler_list" = ""; then
5831 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5832 fi
5833 am__universal=false
5834 case " $depcc " in #(
5835 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5836 esac
5837
5838 for depmode in $am_compiler_list; do
5839 # Setup a source with many dependencies, because some compilers
5840 # like to wrap large dependency lists on column 80 (with \), and
5841 # we should not choose a depcomp mode which is confused by this.
5842 #
5843 # We need to recreate these files for each test, as the compiler may
5844 # overwrite some of them when testing with obscure command lines.
5845 # This happens at least with the AIX C compiler.
5846 : > sub/conftest.c
5847 for i in 1 2 3 4 5 6; do
5848 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5849 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
5850 # Solaris 10 /bin/sh.
5851 echo '/* dummy */' > sub/conftst$i.h
5852 done
5853 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5854
5855 # We check with '-c' and '-o' for the sake of the "dashmstdout"
5856 # mode. It turns out that the SunPro C++ compiler does not properly
5857 # handle '-M -o', and we need to detect this. Also, some Intel
5858 # versions had trouble with output in subdirs.
5859 am__obj=sub/conftest.${OBJEXT-o}
5860 am__minus_obj="-o $am__obj"
5861 case $depmode in
5862 gcc)
5863 # This depmode causes a compiler race in universal mode.
5864 test "$am__universal" = false || continue
5865 ;;
5866 nosideeffect)
5867 # After this tag, mechanisms are not by side-effect, so they'll
5868 # only be used when explicitly requested.
5869 if test "x$enable_dependency_tracking" = xyes; then
5870 continue
5871 else
5872 break
5873 fi
5874 ;;
5875 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
5876 # This compiler won't grok '-c -o', but also, the minuso test has
5877 # not run yet. These depmodes are late enough in the game, and
5878 # so weak that their functioning should not be impacted.
5879 am__obj=conftest.${OBJEXT-o}
5880 am__minus_obj=
5881 ;;
5882 none) break ;;
5883 esac
5884 if depmode=$depmode \
5885 source=sub/conftest.c object=$am__obj \
5886 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5887 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5888 >/dev/null 2>conftest.err &&
5889 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5890 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5891 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5892 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5893 # icc doesn't choke on unknown options, it will just issue warnings
5894 # or remarks (even with -Werror). So we grep stderr for any message
5895 # that says an option was ignored or not supported.
5896 # When given -MP, icc 7.0 and 7.1 complain thusly:
5897 # icc: Command line warning: ignoring option '-M'; no argument required
5898 # The diagnosis changed in icc 8.0:
5899 # icc: Command line remark: option '-MP' not supported
5900 if (grep 'ignoring option' conftest.err ||
5901 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5902 am_cv_CC_dependencies_compiler_type=$depmode
5903 break
5904 fi
5905 fi
5906 done
5907
5908 cd ..
5909 rm -rf conftest.dir
5910 else
5911 am_cv_CC_dependencies_compiler_type=none
5912 fi
5913
5914 fi
5915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5916 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5917 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5918
5919 if
5920 test "x$enable_dependency_tracking" != xno \
5921 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5922 am__fastdepCC_TRUE=
5923 am__fastdepCC_FALSE='#'
5924 else
5925 am__fastdepCC_TRUE='#'
5926 am__fastdepCC_FALSE=
5927 fi
5928
5929
5930 ac_ext=c
5931 ac_cpp='$CPP $CPPFLAGS'
5932 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5933 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5934 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5936 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5937 # On Suns, sometimes $CPP names a directory.
5938 if test -n "$CPP" && test -d "$CPP"; then
5939 CPP=
5940 fi
5941 if test -z "$CPP"; then
5942 if ${ac_cv_prog_CPP+:} false; then :
5943 $as_echo_n "(cached) " >&6
5944 else
5945 # Double quotes because CPP needs to be expanded
5946 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5947 do
5948 ac_preproc_ok=false
5949 for ac_c_preproc_warn_flag in '' yes
5950 do
5951 # Use a header file that comes with gcc, so configuring glibc
5952 # with a fresh cross-compiler works.
5953 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5954 # <limits.h> exists even on freestanding compilers.
5955 # On the NeXT, cc -E runs the code through the compiler's parser,
5956 # not just through cpp. "Syntax error" is here to catch this case.
5957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5958 /* end confdefs.h. */
5959 #ifdef __STDC__
5960 # include <limits.h>
5961 #else
5962 # include <assert.h>
5963 #endif
5964 Syntax error
5965 _ACEOF
5966 if ac_fn_c_try_cpp "$LINENO"; then :
5967
5968 else
5969 # Broken: fails on valid input.
5970 continue
5971 fi
5972 rm -f conftest.err conftest.i conftest.$ac_ext
5973
5974 # OK, works on sane cases. Now check whether nonexistent headers
5975 # can be detected and how.
5976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5977 /* end confdefs.h. */
5978 #include <ac_nonexistent.h>
5979 _ACEOF
5980 if ac_fn_c_try_cpp "$LINENO"; then :
5981 # Broken: success on invalid input.
5982 continue
5983 else
5984 # Passes both tests.
5985 ac_preproc_ok=:
5986 break
5987 fi
5988 rm -f conftest.err conftest.i conftest.$ac_ext
5989
5990 done
5991 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5992 rm -f conftest.i conftest.err conftest.$ac_ext
5993 if $ac_preproc_ok; then :
5994 break
5995 fi
5996
5997 done
5998 ac_cv_prog_CPP=$CPP
5999
6000 fi
6001 CPP=$ac_cv_prog_CPP
6002 else
6003 ac_cv_prog_CPP=$CPP
6004 fi
6005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6006 $as_echo "$CPP" >&6; }
6007 ac_preproc_ok=false
6008 for ac_c_preproc_warn_flag in '' yes
6009 do
6010 # Use a header file that comes with gcc, so configuring glibc
6011 # with a fresh cross-compiler works.
6012 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6013 # <limits.h> exists even on freestanding compilers.
6014 # On the NeXT, cc -E runs the code through the compiler's parser,
6015 # not just through cpp. "Syntax error" is here to catch this case.
6016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6017 /* end confdefs.h. */
6018 #ifdef __STDC__
6019 # include <limits.h>
6020 #else
6021 # include <assert.h>
6022 #endif
6023 Syntax error
6024 _ACEOF
6025 if ac_fn_c_try_cpp "$LINENO"; then :
6026
6027 else
6028 # Broken: fails on valid input.
6029 continue
6030 fi
6031 rm -f conftest.err conftest.i conftest.$ac_ext
6032
6033 # OK, works on sane cases. Now check whether nonexistent headers
6034 # can be detected and how.
6035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6036 /* end confdefs.h. */
6037 #include <ac_nonexistent.h>
6038 _ACEOF
6039 if ac_fn_c_try_cpp "$LINENO"; then :
6040 # Broken: success on invalid input.
6041 continue
6042 else
6043 # Passes both tests.
6044 ac_preproc_ok=:
6045 break
6046 fi
6047 rm -f conftest.err conftest.i conftest.$ac_ext
6048
6049 done
6050 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6051 rm -f conftest.i conftest.err conftest.$ac_ext
6052 if $ac_preproc_ok; then :
6053
6054 else
6055 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6056 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6057 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6058 See \`config.log' for more details" "$LINENO" 5; }
6059 fi
6060
6061 ac_ext=c
6062 ac_cpp='$CPP $CPPFLAGS'
6063 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6064 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6065 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6066
6067 ac_ext=cpp
6068 ac_cpp='$CXXCPP $CPPFLAGS'
6069 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6070 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6071 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6072 if test -z "$CXX"; then
6073 if test -n "$CCC"; then
6074 CXX=$CCC
6075 else
6076 if test -n "$ac_tool_prefix"; then
6077 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
6078 do
6079 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6080 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6082 $as_echo_n "checking for $ac_word... " >&6; }
6083 if ${ac_cv_prog_CXX+:} false; then :
6084 $as_echo_n "(cached) " >&6
6085 else
6086 if test -n "$CXX"; then
6087 ac_cv_prog_CXX="$CXX" # Let the user override the test.
6088 else
6089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6090 for as_dir in $PATH
6091 do
6092 IFS=$as_save_IFS
6093 test -z "$as_dir" && as_dir=.
6094 for ac_exec_ext in '' $ac_executable_extensions; do
6095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6096 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
6097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6098 break 2
6099 fi
6100 done
6101 done
6102 IFS=$as_save_IFS
6103
6104 fi
6105 fi
6106 CXX=$ac_cv_prog_CXX
6107 if test -n "$CXX"; then
6108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
6109 $as_echo "$CXX" >&6; }
6110 else
6111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6112 $as_echo "no" >&6; }
6113 fi
6114
6115
6116 test -n "$CXX" && break
6117 done
6118 fi
6119 if test -z "$CXX"; then
6120 ac_ct_CXX=$CXX
6121 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
6122 do
6123 # Extract the first word of "$ac_prog", so it can be a program name with args.
6124 set dummy $ac_prog; ac_word=$2
6125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6126 $as_echo_n "checking for $ac_word... " >&6; }
6127 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
6128 $as_echo_n "(cached) " >&6
6129 else
6130 if test -n "$ac_ct_CXX"; then
6131 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
6132 else
6133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6134 for as_dir in $PATH
6135 do
6136 IFS=$as_save_IFS
6137 test -z "$as_dir" && as_dir=.
6138 for ac_exec_ext in '' $ac_executable_extensions; do
6139 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6140 ac_cv_prog_ac_ct_CXX="$ac_prog"
6141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6142 break 2
6143 fi
6144 done
6145 done
6146 IFS=$as_save_IFS
6147
6148 fi
6149 fi
6150 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
6151 if test -n "$ac_ct_CXX"; then
6152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
6153 $as_echo "$ac_ct_CXX" >&6; }
6154 else
6155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6156 $as_echo "no" >&6; }
6157 fi
6158
6159
6160 test -n "$ac_ct_CXX" && break
6161 done
6162
6163 if test "x$ac_ct_CXX" = x; then
6164 CXX="g++"
6165 else
6166 case $cross_compiling:$ac_tool_warned in
6167 yes:)
6168 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6169 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6170 ac_tool_warned=yes ;;
6171 esac
6172 CXX=$ac_ct_CXX
6173 fi
6174 fi
6175
6176 fi
6177 fi
6178 # Provide some information about the compiler.
6179 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
6180 set X $ac_compile
6181 ac_compiler=$2
6182 for ac_option in --version -v -V -qversion; do
6183 { { ac_try="$ac_compiler $ac_option >&5"
6184 case "(($ac_try" in
6185 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6186 *) ac_try_echo=$ac_try;;
6187 esac
6188 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6189 $as_echo "$ac_try_echo"; } >&5
6190 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
6191 ac_status=$?
6192 if test -s conftest.err; then
6193 sed '10a\
6194 ... rest of stderr output deleted ...
6195 10q' conftest.err >conftest.er1
6196 cat conftest.er1 >&5
6197 fi
6198 rm -f conftest.er1 conftest.err
6199 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6200 test $ac_status = 0; }
6201 done
6202
6203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
6204 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
6205 if ${ac_cv_cxx_compiler_gnu+:} false; then :
6206 $as_echo_n "(cached) " >&6
6207 else
6208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6209 /* end confdefs.h. */
6210
6211 int
6212 main ()
6213 {
6214 #ifndef __GNUC__
6215 choke me
6216 #endif
6217
6218 ;
6219 return 0;
6220 }
6221 _ACEOF
6222 if ac_fn_cxx_try_compile "$LINENO"; then :
6223 ac_compiler_gnu=yes
6224 else
6225 ac_compiler_gnu=no
6226 fi
6227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6228 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
6229
6230 fi
6231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
6232 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
6233 if test $ac_compiler_gnu = yes; then
6234 GXX=yes
6235 else
6236 GXX=
6237 fi
6238 ac_test_CXXFLAGS=${CXXFLAGS+set}
6239 ac_save_CXXFLAGS=$CXXFLAGS
6240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
6241 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
6242 if ${ac_cv_prog_cxx_g+:} false; then :
6243 $as_echo_n "(cached) " >&6
6244 else
6245 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6246 ac_cxx_werror_flag=yes
6247 ac_cv_prog_cxx_g=no
6248 CXXFLAGS="-g"
6249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6250 /* end confdefs.h. */
6251
6252 int
6253 main ()
6254 {
6255
6256 ;
6257 return 0;
6258 }
6259 _ACEOF
6260 if ac_fn_cxx_try_compile "$LINENO"; then :
6261 ac_cv_prog_cxx_g=yes
6262 else
6263 CXXFLAGS=""
6264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6265 /* end confdefs.h. */
6266
6267 int
6268 main ()
6269 {
6270
6271 ;
6272 return 0;
6273 }
6274 _ACEOF
6275 if ac_fn_cxx_try_compile "$LINENO"; then :
6276
6277 else
6278 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6279 CXXFLAGS="-g"
6280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6281 /* end confdefs.h. */
6282
6283 int
6284 main ()
6285 {
6286
6287 ;
6288 return 0;
6289 }
6290 _ACEOF
6291 if ac_fn_cxx_try_compile "$LINENO"; then :
6292 ac_cv_prog_cxx_g=yes
6293 fi
6294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6295 fi
6296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6297 fi
6298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6299 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6300 fi
6301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
6302 $as_echo "$ac_cv_prog_cxx_g" >&6; }
6303 if test "$ac_test_CXXFLAGS" = set; then
6304 CXXFLAGS=$ac_save_CXXFLAGS
6305 elif test $ac_cv_prog_cxx_g = yes; then
6306 if test "$GXX" = yes; then
6307 CXXFLAGS="-g -O2"
6308 else
6309 CXXFLAGS="-g"
6310 fi
6311 else
6312 if test "$GXX" = yes; then
6313 CXXFLAGS="-O2"
6314 else
6315 CXXFLAGS=
6316 fi
6317 fi
6318 ac_ext=c
6319 ac_cpp='$CPP $CPPFLAGS'
6320 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6321 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6322 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6323
6324 depcc="$CXX" am_compiler_list=
6325
6326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
6327 $as_echo_n "checking dependency style of $depcc... " >&6; }
6328 if ${am_cv_CXX_dependencies_compiler_type+:} false; then :
6329 $as_echo_n "(cached) " >&6
6330 else
6331 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
6332 # We make a subdir and do the tests there. Otherwise we can end up
6333 # making bogus files that we don't know about and never remove. For
6334 # instance it was reported that on HP-UX the gcc test will end up
6335 # making a dummy file named 'D' -- because '-MD' means "put the output
6336 # in D".
6337 rm -rf conftest.dir
6338 mkdir conftest.dir
6339 # Copy depcomp to subdir because otherwise we won't find it if we're
6340 # using a relative directory.
6341 cp "$am_depcomp" conftest.dir
6342 cd conftest.dir
6343 # We will build objects and dependencies in a subdirectory because
6344 # it helps to detect inapplicable dependency modes. For instance
6345 # both Tru64's cc and ICC support -MD to output dependencies as a
6346 # side effect of compilation, but ICC will put the dependencies in
6347 # the current directory while Tru64 will put them in the object
6348 # directory.
6349 mkdir sub
6350
6351 am_cv_CXX_dependencies_compiler_type=none
6352 if test "$am_compiler_list" = ""; then
6353 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
6354 fi
6355 am__universal=false
6356 case " $depcc " in #(
6357 *\ -arch\ *\ -arch\ *) am__universal=true ;;
6358 esac
6359
6360 for depmode in $am_compiler_list; do
6361 # Setup a source with many dependencies, because some compilers
6362 # like to wrap large dependency lists on column 80 (with \), and
6363 # we should not choose a depcomp mode which is confused by this.
6364 #
6365 # We need to recreate these files for each test, as the compiler may
6366 # overwrite some of them when testing with obscure command lines.
6367 # This happens at least with the AIX C compiler.
6368 : > sub/conftest.c
6369 for i in 1 2 3 4 5 6; do
6370 echo '#include "conftst'$i'.h"' >> sub/conftest.c
6371 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
6372 # Solaris 10 /bin/sh.
6373 echo '/* dummy */' > sub/conftst$i.h
6374 done
6375 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
6376
6377 # We check with '-c' and '-o' for the sake of the "dashmstdout"
6378 # mode. It turns out that the SunPro C++ compiler does not properly
6379 # handle '-M -o', and we need to detect this. Also, some Intel
6380 # versions had trouble with output in subdirs.
6381 am__obj=sub/conftest.${OBJEXT-o}
6382 am__minus_obj="-o $am__obj"
6383 case $depmode in
6384 gcc)
6385 # This depmode causes a compiler race in universal mode.
6386 test "$am__universal" = false || continue
6387 ;;
6388 nosideeffect)
6389 # After this tag, mechanisms are not by side-effect, so they'll
6390 # only be used when explicitly requested.
6391 if test "x$enable_dependency_tracking" = xyes; then
6392 continue
6393 else
6394 break
6395 fi
6396 ;;
6397 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
6398 # This compiler won't grok '-c -o', but also, the minuso test has
6399 # not run yet. These depmodes are late enough in the game, and
6400 # so weak that their functioning should not be impacted.
6401 am__obj=conftest.${OBJEXT-o}
6402 am__minus_obj=
6403 ;;
6404 none) break ;;
6405 esac
6406 if depmode=$depmode \
6407 source=sub/conftest.c object=$am__obj \
6408 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6409 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
6410 >/dev/null 2>conftest.err &&
6411 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
6412 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
6413 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
6414 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
6415 # icc doesn't choke on unknown options, it will just issue warnings
6416 # or remarks (even with -Werror). So we grep stderr for any message
6417 # that says an option was ignored or not supported.
6418 # When given -MP, icc 7.0 and 7.1 complain thusly:
6419 # icc: Command line warning: ignoring option '-M'; no argument required
6420 # The diagnosis changed in icc 8.0:
6421 # icc: Command line remark: option '-MP' not supported
6422 if (grep 'ignoring option' conftest.err ||
6423 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6424 am_cv_CXX_dependencies_compiler_type=$depmode
6425 break
6426 fi
6427 fi
6428 done
6429
6430 cd ..
6431 rm -rf conftest.dir
6432 else
6433 am_cv_CXX_dependencies_compiler_type=none
6434 fi
6435
6436 fi
6437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5
6438 $as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
6439 CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
6440
6441 if
6442 test "x$enable_dependency_tracking" != xno \
6443 && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then
6444 am__fastdepCXX_TRUE=
6445 am__fastdepCXX_FALSE='#'
6446 else
6447 am__fastdepCXX_TRUE='#'
6448 am__fastdepCXX_FALSE=
6449 fi
6450
6451
6452
6453 # Note: A suitable gitlog-to-changelog script can be found in GnuPG master.
6454 for ac_prog in gitlog-to-changelog
6455 do
6456 # Extract the first word of "$ac_prog", so it can be a program name with args.
6457 set dummy $ac_prog; ac_word=$2
6458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6459 $as_echo_n "checking for $ac_word... " >&6; }
6460 if ${ac_cv_prog_GITLOG_TO_CHANGELOG+:} false; then :
6461 $as_echo_n "(cached) " >&6
6462 else
6463 if test -n "$GITLOG_TO_CHANGELOG"; then
6464 ac_cv_prog_GITLOG_TO_CHANGELOG="$GITLOG_TO_CHANGELOG" # Let the user override the test.
6465 else
6466 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6467 for as_dir in $PATH
6468 do
6469 IFS=$as_save_IFS
6470 test -z "$as_dir" && as_dir=.
6471 for ac_exec_ext in '' $ac_executable_extensions; do
6472 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6473 ac_cv_prog_GITLOG_TO_CHANGELOG="$ac_prog"
6474 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6475 break 2
6476 fi
6477 done
6478 done
6479 IFS=$as_save_IFS
6480
6481 fi
6482 fi
6483 GITLOG_TO_CHANGELOG=$ac_cv_prog_GITLOG_TO_CHANGELOG
6484 if test -n "$GITLOG_TO_CHANGELOG"; then
6485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GITLOG_TO_CHANGELOG" >&5
6486 $as_echo "$GITLOG_TO_CHANGELOG" >&6; }
6487 else
6488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6489 $as_echo "no" >&6; }
6490 fi
6491
6492
6493 test -n "$GITLOG_TO_CHANGELOG" && break
6494 done
6495 test -n "$GITLOG_TO_CHANGELOG" || GITLOG_TO_CHANGELOG="gitlog-to-changelog"
6496
6497
6498
6499
6500
6501
6502 VERSION_NUMBER=0x011100
6503
6504
6505 # We need to compile and run a program on the build machine. A
6506 # comment in libgpg-error says that the AC_PROG_CC_FOR_BUILD macro in
6507 # the AC archive is broken for autoconf 2.57. Given that there is no
6508 # newer version of that macro, we assume that it is also broken for
6509 # autoconf 2.61 and thus we use a simple but usually sufficient
6510 # approach.
6511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cc for build" >&5
6512 $as_echo_n "checking for cc for build... " >&6; }
6513 if test "$cross_compiling" = "yes"; then
6514 CC_FOR_BUILD="${CC_FOR_BUILD-cc}"
6515 else
6516 CC_FOR_BUILD="${CC_FOR_BUILD-$CC}"
6517 fi
6518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_BUILD" >&5
6519 $as_echo "$CC_FOR_BUILD" >&6; }
6520
6521
6522
6523 # Don't default to build static libs.
6524
6525 case `pwd` in
6526 *\ * | *\ *)
6527 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
6528 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
6529 esac
6530
6531
6532
6533 macro_version='2.4.2'
6534 macro_revision='1.3337'
6535
6536
6537
6538
6539
6540
6541
6542
6543
6544
6545
6546
6547
6548 ltmain="$ac_aux_dir/ltmain.sh"
6549
6550 # Backslashify metacharacters that are still active within
6551 # double-quoted strings.
6552 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
6553
6554 # Same as above, but do not quote variable references.
6555 double_quote_subst='s/\(["`\\]\)/\\\1/g'
6556
6557 # Sed substitution to delay expansion of an escaped shell variable in a
6558 # double_quote_subst'ed string.
6559 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
6560
6561 # Sed substitution to delay expansion of an escaped single quote.
6562 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
6563
6564 # Sed substitution to avoid accidental globbing in evaled expressions
6565 no_glob_subst='s/\*/\\\*/g'
6566
6567 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
6568 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
6569 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
6570
6571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
6572 $as_echo_n "checking how to print strings... " >&6; }
6573 # Test print first, because it will be a builtin if present.
6574 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
6575 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
6576 ECHO='print -r --'
6577 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
6578 ECHO='printf %s\n'
6579 else
6580 # Use this function as a fallback that always works.
6581 func_fallback_echo ()
6582 {
6583 eval 'cat <<_LTECHO_EOF
6584 $1
6585 _LTECHO_EOF'
6586 }
6587 ECHO='func_fallback_echo'
6588 fi
6589
6590 # func_echo_all arg...
6591 # Invoke $ECHO with all args, space-separated.
6592 func_echo_all ()
6593 {
6594 $ECHO ""
6595 }
6596
6597 case "$ECHO" in
6598 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
6599 $as_echo "printf" >&6; } ;;
6600 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
6601 $as_echo "print -r" >&6; } ;;
6602 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
6603 $as_echo "cat" >&6; } ;;
6604 esac
6605
6606
6607
6608
6609
6610
6611
6612
6613
6614
6615
6616
6617
6618
6619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
6620 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
6621 if ${ac_cv_path_SED+:} false; then :
6622 $as_echo_n "(cached) " >&6
6623 else
6624 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
6625 for ac_i in 1 2 3 4 5 6 7; do
6626 ac_script="$ac_script$as_nl$ac_script"
6627 done
6628 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
6629 { ac_script=; unset ac_script;}
6630 if test -z "$SED"; then
6631 ac_path_SED_found=false
6632 # Loop through the user's path and test for each of PROGNAME-LIST
6633 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6634 for as_dir in $PATH
6635 do
6636 IFS=$as_save_IFS
6637 test -z "$as_dir" && as_dir=.
6638 for ac_prog in sed gsed; do
6639 for ac_exec_ext in '' $ac_executable_extensions; do
6640 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
6641 as_fn_executable_p "$ac_path_SED" || continue
6642 # Check for GNU ac_path_SED and select it if it is found.
6643 # Check for GNU $ac_path_SED
6644 case `"$ac_path_SED" --version 2>&1` in
6645 *GNU*)
6646 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
6647 *)
6648 ac_count=0
6649 $as_echo_n 0123456789 >"conftest.in"
6650 while :
6651 do
6652 cat "conftest.in" "conftest.in" >"conftest.tmp"
6653 mv "conftest.tmp" "conftest.in"
6654 cp "conftest.in" "conftest.nl"
6655 $as_echo '' >> "conftest.nl"
6656 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
6657 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6658 as_fn_arith $ac_count + 1 && ac_count=$as_val
6659 if test $ac_count -gt ${ac_path_SED_max-0}; then
6660 # Best one so far, save it but keep looking for a better one
6661 ac_cv_path_SED="$ac_path_SED"
6662 ac_path_SED_max=$ac_count
6663 fi
6664 # 10*(2^10) chars as input seems more than enough
6665 test $ac_count -gt 10 && break
6666 done
6667 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6668 esac
6669
6670 $ac_path_SED_found && break 3
6671 done
6672 done
6673 done
6674 IFS=$as_save_IFS
6675 if test -z "$ac_cv_path_SED"; then
6676 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
6677 fi
6678 else
6679 ac_cv_path_SED=$SED
6680 fi
6681
6682 fi
6683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
6684 $as_echo "$ac_cv_path_SED" >&6; }
6685 SED="$ac_cv_path_SED"
6686 rm -f conftest.sed
6687
6688 test -z "$SED" && SED=sed
6689 Xsed="$SED -e 1s/^X//"
6690
6691
6692
6693
6694
6695
6696
6697
6698
6699
6700
6701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
6702 $as_echo_n "checking for fgrep... " >&6; }
6703 if ${ac_cv_path_FGREP+:} false; then :
6704 $as_echo_n "(cached) " >&6
6705 else
6706 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
6707 then ac_cv_path_FGREP="$GREP -F"
6708 else
6709 if test -z "$FGREP"; then
6710 ac_path_FGREP_found=false
6711 # Loop through the user's path and test for each of PROGNAME-LIST
6712 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6713 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6714 do
6715 IFS=$as_save_IFS
6716 test -z "$as_dir" && as_dir=.
6717 for ac_prog in fgrep; do
6718 for ac_exec_ext in '' $ac_executable_extensions; do
6719 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
6720 as_fn_executable_p "$ac_path_FGREP" || continue
6721 # Check for GNU ac_path_FGREP and select it if it is found.
6722 # Check for GNU $ac_path_FGREP
6723 case `"$ac_path_FGREP" --version 2>&1` in
6724 *GNU*)
6725 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
6726 *)
6727 ac_count=0
6728 $as_echo_n 0123456789 >"conftest.in"
6729 while :
6730 do
6731 cat "conftest.in" "conftest.in" >"conftest.tmp"
6732 mv "conftest.tmp" "conftest.in"
6733 cp "conftest.in" "conftest.nl"
6734 $as_echo 'FGREP' >> "conftest.nl"
6735 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
6736 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6737 as_fn_arith $ac_count + 1 && ac_count=$as_val
6738 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
6739 # Best one so far, save it but keep looking for a better one
6740 ac_cv_path_FGREP="$ac_path_FGREP"
6741 ac_path_FGREP_max=$ac_count
6742 fi
6743 # 10*(2^10) chars as input seems more than enough
6744 test $ac_count -gt 10 && break
6745 done
6746 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6747 esac
6748
6749 $ac_path_FGREP_found && break 3
6750 done
6751 done
6752 done
6753 IFS=$as_save_IFS
6754 if test -z "$ac_cv_path_FGREP"; then
6755 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6756 fi
6757 else
6758 ac_cv_path_FGREP=$FGREP
6759 fi
6760
6761 fi
6762 fi
6763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
6764 $as_echo "$ac_cv_path_FGREP" >&6; }
6765 FGREP="$ac_cv_path_FGREP"
6766
6767
6768 test -z "$GREP" && GREP=grep
6769
6770
6771
6772
6773
6774
6775
6776
6777
6778
6779
6780
6781
6782
6783
6784
6785
6786
6787
6788 # Check whether --with-gnu-ld was given.
6789 if test "${with_gnu_ld+set}" = set; then :
6790 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
6791 else
6792 with_gnu_ld=no
6793 fi
6794
6795 ac_prog=ld
6796 if test "$GCC" = yes; then
6797 # Check if gcc -print-prog-name=ld gives a path.
6798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
6799 $as_echo_n "checking for ld used by $CC... " >&6; }
6800 case $host in
6801 *-*-mingw*)
6802 # gcc leaves a trailing carriage return which upsets mingw
6803 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
6804 *)
6805 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
6806 esac
6807 case $ac_prog in
6808 # Accept absolute paths.
6809 [\\/]* | ?:[\\/]*)
6810 re_direlt='/[^/][^/]*/\.\./'
6811 # Canonicalize the pathname of ld
6812 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
6813 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
6814 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
6815 done
6816 test -z "$LD" && LD="$ac_prog"
6817 ;;
6818 "")
6819 # If it fails, then pretend we aren't using GCC.
6820 ac_prog=ld
6821 ;;
6822 *)
6823 # If it is relative, then search for the first ld in PATH.
6824 with_gnu_ld=unknown
6825 ;;
6826 esac
6827 elif test "$with_gnu_ld" = yes; then
6828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
6829 $as_echo_n "checking for GNU ld... " >&6; }
6830 else
6831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
6832 $as_echo_n "checking for non-GNU ld... " >&6; }
6833 fi
6834 if ${lt_cv_path_LD+:} false; then :
6835 $as_echo_n "(cached) " >&6
6836 else
6837 if test -z "$LD"; then
6838 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
6839 for ac_dir in $PATH; do
6840 IFS="$lt_save_ifs"
6841 test -z "$ac_dir" && ac_dir=.
6842 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
6843 lt_cv_path_LD="$ac_dir/$ac_prog"
6844 # Check to see if the program is GNU ld. I'd rather use --version,
6845 # but apparently some variants of GNU ld only accept -v.
6846 # Break only if it was the GNU/non-GNU ld that we prefer.
6847 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
6848 *GNU* | *'with BFD'*)
6849 test "$with_gnu_ld" != no && break
6850 ;;
6851 *)
6852 test "$with_gnu_ld" != yes && break
6853 ;;
6854 esac
6855 fi
6856 done
6857 IFS="$lt_save_ifs"
6858 else
6859 lt_cv_path_LD="$LD" # Let the user override the test with a path.
6860 fi
6861 fi
6862
6863 LD="$lt_cv_path_LD"
6864 if test -n "$LD"; then
6865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
6866 $as_echo "$LD" >&6; }
6867 else
6868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6869 $as_echo "no" >&6; }
6870 fi
6871 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
6872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
6873 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
6874 if ${lt_cv_prog_gnu_ld+:} false; then :
6875 $as_echo_n "(cached) " >&6
6876 else
6877 # I'd rather use --version here, but apparently some GNU lds only accept -v.
6878 case `$LD -v 2>&1 </dev/null` in
6879 *GNU* | *'with BFD'*)
6880 lt_cv_prog_gnu_ld=yes
6881 ;;
6882 *)
6883 lt_cv_prog_gnu_ld=no
6884 ;;
6885 esac
6886 fi
6887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
6888 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
6889 with_gnu_ld=$lt_cv_prog_gnu_ld
6890
6891
6892
6893
6894
6895
6896
6897
6898
6899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
6900 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
6901 if ${lt_cv_path_NM+:} false; then :
6902 $as_echo_n "(cached) " >&6
6903 else
6904 if test -n "$NM"; then
6905 # Let the user override the test.
6906 lt_cv_path_NM="$NM"
6907 else
6908 lt_nm_to_check="${ac_tool_prefix}nm"
6909 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
6910 lt_nm_to_check="$lt_nm_to_check nm"
6911 fi
6912 for lt_tmp_nm in $lt_nm_to_check; do
6913 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
6914 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
6915 IFS="$lt_save_ifs"
6916 test -z "$ac_dir" && ac_dir=.
6917 tmp_nm="$ac_dir/$lt_tmp_nm"
6918 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
6919 # Check to see if the nm accepts a BSD-compat flag.
6920 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
6921 # nm: unknown option "B" ignored
6922 # Tru64's nm complains that /dev/null is an invalid object file
6923 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
6924 */dev/null* | *'Invalid file or object type'*)
6925 lt_cv_path_NM="$tmp_nm -B"
6926 break
6927 ;;
6928 *)
6929 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
6930 */dev/null*)
6931 lt_cv_path_NM="$tmp_nm -p"
6932 break
6933 ;;
6934 *)
6935 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
6936 continue # so that we can try to find one that supports BSD flags
6937 ;;
6938 esac
6939 ;;
6940 esac
6941 fi
6942 done
6943 IFS="$lt_save_ifs"
6944 done
6945 : ${lt_cv_path_NM=no}
6946 fi
6947 fi
6948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
6949 $as_echo "$lt_cv_path_NM" >&6; }
6950 if test "$lt_cv_path_NM" != "no"; then
6951 NM="$lt_cv_path_NM"
6952 else
6953 # Didn't find any BSD compatible name lister, look for dumpbin.
6954 if test -n "$DUMPBIN"; then :
6955 # Let the user override the test.
6956 else
6957 if test -n "$ac_tool_prefix"; then
6958 for ac_prog in dumpbin "link -dump"
6959 do
6960 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6961 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6963 $as_echo_n "checking for $ac_word... " >&6; }
6964 if ${ac_cv_prog_DUMPBIN+:} false; then :
6965 $as_echo_n "(cached) " >&6
6966 else
6967 if test -n "$DUMPBIN"; then
6968 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
6969 else
6970 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6971 for as_dir in $PATH
6972 do
6973 IFS=$as_save_IFS
6974 test -z "$as_dir" && as_dir=.
6975 for ac_exec_ext in '' $ac_executable_extensions; do
6976 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6977 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
6978 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6979 break 2
6980 fi
6981 done
6982 done
6983 IFS=$as_save_IFS
6984
6985 fi
6986 fi
6987 DUMPBIN=$ac_cv_prog_DUMPBIN
6988 if test -n "$DUMPBIN"; then
6989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
6990 $as_echo "$DUMPBIN" >&6; }
6991 else
6992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6993 $as_echo "no" >&6; }
6994 fi
6995
6996
6997 test -n "$DUMPBIN" && break
6998 done
6999 fi
7000 if test -z "$DUMPBIN"; then
7001 ac_ct_DUMPBIN=$DUMPBIN
7002 for ac_prog in dumpbin "link -dump"
7003 do
7004 # Extract the first word of "$ac_prog", so it can be a program name with args.
7005 set dummy $ac_prog; ac_word=$2
7006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7007 $as_echo_n "checking for $ac_word... " >&6; }
7008 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7009 $as_echo_n "(cached) " >&6
7010 else
7011 if test -n "$ac_ct_DUMPBIN"; then
7012 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7013 else
7014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7015 for as_dir in $PATH
7016 do
7017 IFS=$as_save_IFS
7018 test -z "$as_dir" && as_dir=.
7019 for ac_exec_ext in '' $ac_executable_extensions; do
7020 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7021 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7023 break 2
7024 fi
7025 done
7026 done
7027 IFS=$as_save_IFS
7028
7029 fi
7030 fi
7031 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7032 if test -n "$ac_ct_DUMPBIN"; then
7033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7034 $as_echo "$ac_ct_DUMPBIN" >&6; }
7035 else
7036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7037 $as_echo "no" >&6; }
7038 fi
7039
7040
7041 test -n "$ac_ct_DUMPBIN" && break
7042 done
7043
7044 if test "x$ac_ct_DUMPBIN" = x; then
7045 DUMPBIN=":"
7046 else
7047 case $cross_compiling:$ac_tool_warned in
7048 yes:)
7049 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7050 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7051 ac_tool_warned=yes ;;
7052 esac
7053 DUMPBIN=$ac_ct_DUMPBIN
7054 fi
7055 fi
7056
7057 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
7058 *COFF*)
7059 DUMPBIN="$DUMPBIN -symbols"
7060 ;;
7061 *)
7062 DUMPBIN=:
7063 ;;
7064 esac
7065 fi
7066
7067 if test "$DUMPBIN" != ":"; then
7068 NM="$DUMPBIN"
7069 fi
7070 fi
7071 test -z "$NM" && NM=nm
7072
7073
7074
7075
7076
7077
7078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7079 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
7080 if ${lt_cv_nm_interface+:} false; then :
7081 $as_echo_n "(cached) " >&6
7082 else
7083 lt_cv_nm_interface="BSD nm"
7084 echo "int some_variable = 0;" > conftest.$ac_ext
7085 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7086 (eval "$ac_compile" 2>conftest.err)
7087 cat conftest.err >&5
7088 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7089 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7090 cat conftest.err >&5
7091 (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7092 cat conftest.out >&5
7093 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7094 lt_cv_nm_interface="MS dumpbin"
7095 fi
7096 rm -f conftest*
7097 fi
7098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7099 $as_echo "$lt_cv_nm_interface" >&6; }
7100
7101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7102 $as_echo_n "checking whether ln -s works... " >&6; }
7103 LN_S=$as_ln_s
7104 if test "$LN_S" = "ln -s"; then
7105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7106 $as_echo "yes" >&6; }
7107 else
7108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7109 $as_echo "no, using $LN_S" >&6; }
7110 fi
7111
7112 # find the maximum length of command line arguments
7113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7114 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
7115 if ${lt_cv_sys_max_cmd_len+:} false; then :
7116 $as_echo_n "(cached) " >&6
7117 else
7118 i=0
7119 teststring="ABCD"
7120
7121 case $build_os in
7122 msdosdjgpp*)
7123 # On DJGPP, this test can blow up pretty badly due to problems in libc
7124 # (any single argument exceeding 2000 bytes causes a buffer overrun
7125 # during glob expansion). Even if it were fixed, the result of this
7126 # check would be larger than it should be.
7127 lt_cv_sys_max_cmd_len=12288; # 12K is about right
7128 ;;
7129
7130 gnu*)
7131 # Under GNU Hurd, this test is not required because there is
7132 # no limit to the length of command line arguments.
7133 # Libtool will interpret -1 as no limit whatsoever
7134 lt_cv_sys_max_cmd_len=-1;
7135 ;;
7136
7137 cygwin* | mingw* | cegcc*)
7138 # On Win9x/ME, this test blows up -- it succeeds, but takes
7139 # about 5 minutes as the teststring grows exponentially.
7140 # Worse, since 9x/ME are not pre-emptively multitasking,
7141 # you end up with a "frozen" computer, even though with patience
7142 # the test eventually succeeds (with a max line length of 256k).
7143 # Instead, let's just punt: use the minimum linelength reported by
7144 # all of the supported platforms: 8192 (on NT/2K/XP).
7145 lt_cv_sys_max_cmd_len=8192;
7146 ;;
7147
7148 mint*)
7149 # On MiNT this can take a long time and run out of memory.
7150 lt_cv_sys_max_cmd_len=8192;
7151 ;;
7152
7153 amigaos*)
7154 # On AmigaOS with pdksh, this test takes hours, literally.
7155 # So we just punt and use a minimum line length of 8192.
7156 lt_cv_sys_max_cmd_len=8192;
7157 ;;
7158
7159 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
7160 # This has been around since 386BSD, at least. Likely further.
7161 if test -x /sbin/sysctl; then
7162 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7163 elif test -x /usr/sbin/sysctl; then
7164 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7165 else
7166 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
7167 fi
7168 # And add a safety zone
7169 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7170 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7171 ;;
7172
7173 interix*)
7174 # We know the value 262144 and hardcode it with a safety zone (like BSD)
7175 lt_cv_sys_max_cmd_len=196608
7176 ;;
7177
7178 os2*)
7179 # The test takes a long time on OS/2.
7180 lt_cv_sys_max_cmd_len=8192
7181 ;;
7182
7183 osf*)
7184 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7185 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7186 # nice to cause kernel panics so lets avoid the loop below.
7187 # First set a reasonable default.
7188 lt_cv_sys_max_cmd_len=16384
7189 #
7190 if test -x /sbin/sysconfig; then
7191 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7192 *1*) lt_cv_sys_max_cmd_len=-1 ;;
7193 esac
7194 fi
7195 ;;
7196 sco3.2v5*)
7197 lt_cv_sys_max_cmd_len=102400
7198 ;;
7199 sysv5* | sco5v6* | sysv4.2uw2*)
7200 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7201 if test -n "$kargmax"; then
7202 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
7203 else
7204 lt_cv_sys_max_cmd_len=32768
7205 fi
7206 ;;
7207 *)
7208 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7209 if test -n "$lt_cv_sys_max_cmd_len"; then
7210 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7211 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7212 else
7213 # Make teststring a little bigger before we do anything with it.
7214 # a 1K string should be a reasonable start.
7215 for i in 1 2 3 4 5 6 7 8 ; do
7216 teststring=$teststring$teststring
7217 done
7218 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7219 # If test is not a shell built-in, we'll probably end up computing a
7220 # maximum length that is only half of the actual maximum length, but
7221 # we can't tell.
7222 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
7223 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7224 test $i != 17 # 1/2 MB should be enough
7225 do
7226 i=`expr $i + 1`
7227 teststring=$teststring$teststring
7228 done
7229 # Only check the string length outside the loop.
7230 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7231 teststring=
7232 # Add a significant safety factor because C++ compilers can tack on
7233 # massive amounts of additional arguments before passing them to the
7234 # linker. It appears as though 1/2 is a usable value.
7235 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7236 fi
7237 ;;
7238 esac
7239
7240 fi
7241
7242 if test -n $lt_cv_sys_max_cmd_len ; then
7243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7244 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7245 else
7246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7247 $as_echo "none" >&6; }
7248 fi
7249 max_cmd_len=$lt_cv_sys_max_cmd_len
7250
7251
7252
7253
7254
7255
7256 : ${CP="cp -f"}
7257 : ${MV="mv -f"}
7258 : ${RM="rm -f"}
7259
7260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
7261 $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
7262 # Try some XSI features
7263 xsi_shell=no
7264 ( _lt_dummy="a/b/c"
7265 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
7266 = c,a/b,b/c, \
7267 && eval 'test $(( 1 + 1 )) -eq 2 \
7268 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7269 && xsi_shell=yes
7270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
7271 $as_echo "$xsi_shell" >&6; }
7272
7273
7274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
7275 $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
7276 lt_shell_append=no
7277 ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
7278 >/dev/null 2>&1 \
7279 && lt_shell_append=yes
7280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
7281 $as_echo "$lt_shell_append" >&6; }
7282
7283
7284 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7285 lt_unset=unset
7286 else
7287 lt_unset=false
7288 fi
7289
7290
7291
7292
7293
7294 # test EBCDIC or ASCII
7295 case `echo X|tr X '\101'` in
7296 A) # ASCII based system
7297 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7298 lt_SP2NL='tr \040 \012'
7299 lt_NL2SP='tr \015\012 \040\040'
7300 ;;
7301 *) # EBCDIC based system
7302 lt_SP2NL='tr \100 \n'
7303 lt_NL2SP='tr \r\n \100\100'
7304 ;;
7305 esac
7306
7307
7308
7309
7310
7311
7312
7313
7314
7315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7316 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7317 if ${lt_cv_to_host_file_cmd+:} false; then :
7318 $as_echo_n "(cached) " >&6
7319 else
7320 case $host in
7321 *-*-mingw* )
7322 case $build in
7323 *-*-mingw* ) # actually msys
7324 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7325 ;;
7326 *-*-cygwin* )
7327 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7328 ;;
7329 * ) # otherwise, assume *nix
7330 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7331 ;;
7332 esac
7333 ;;
7334 *-*-cygwin* )
7335 case $build in
7336 *-*-mingw* ) # actually msys
7337 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7338 ;;
7339 *-*-cygwin* )
7340 lt_cv_to_host_file_cmd=func_convert_file_noop
7341 ;;
7342 * ) # otherwise, assume *nix
7343 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7344 ;;
7345 esac
7346 ;;
7347 * ) # unhandled hosts (and "normal" native builds)
7348 lt_cv_to_host_file_cmd=func_convert_file_noop
7349 ;;
7350 esac
7351
7352 fi
7353
7354 to_host_file_cmd=$lt_cv_to_host_file_cmd
7355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7356 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
7357
7358
7359
7360
7361
7362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7363 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7364 if ${lt_cv_to_tool_file_cmd+:} false; then :
7365 $as_echo_n "(cached) " >&6
7366 else
7367 #assume ordinary cross tools, or native build.
7368 lt_cv_to_tool_file_cmd=func_convert_file_noop
7369 case $host in
7370 *-*-mingw* )
7371 case $build in
7372 *-*-mingw* ) # actually msys
7373 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7374 ;;
7375 esac
7376 ;;
7377 esac
7378
7379 fi
7380
7381 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7383 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7384
7385
7386
7387
7388
7389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7390 $as_echo_n "checking for $LD option to reload object files... " >&6; }
7391 if ${lt_cv_ld_reload_flag+:} false; then :
7392 $as_echo_n "(cached) " >&6
7393 else
7394 lt_cv_ld_reload_flag='-r'
7395 fi
7396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
7397 $as_echo "$lt_cv_ld_reload_flag" >&6; }
7398 reload_flag=$lt_cv_ld_reload_flag
7399 case $reload_flag in
7400 "" | " "*) ;;
7401 *) reload_flag=" $reload_flag" ;;
7402 esac
7403 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7404 case $host_os in
7405 cygwin* | mingw* | pw32* | cegcc*)
7406 if test "$GCC" != yes; then
7407 reload_cmds=false
7408 fi
7409 ;;
7410 darwin*)
7411 if test "$GCC" = yes; then
7412 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
7413 else
7414 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7415 fi
7416 ;;
7417 esac
7418
7419
7420
7421
7422
7423
7424
7425
7426
7427 if test -n "$ac_tool_prefix"; then
7428 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
7429 set dummy ${ac_tool_prefix}objdump; ac_word=$2
7430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7431 $as_echo_n "checking for $ac_word... " >&6; }
7432 if ${ac_cv_prog_OBJDUMP+:} false; then :
7433 $as_echo_n "(cached) " >&6
7434 else
7435 if test -n "$OBJDUMP"; then
7436 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
7437 else
7438 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7439 for as_dir in $PATH
7440 do
7441 IFS=$as_save_IFS
7442 test -z "$as_dir" && as_dir=.
7443 for ac_exec_ext in '' $ac_executable_extensions; do
7444 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7445 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
7446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7447 break 2
7448 fi
7449 done
7450 done
7451 IFS=$as_save_IFS
7452
7453 fi
7454 fi
7455 OBJDUMP=$ac_cv_prog_OBJDUMP
7456 if test -n "$OBJDUMP"; then
7457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
7458 $as_echo "$OBJDUMP" >&6; }
7459 else
7460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7461 $as_echo "no" >&6; }
7462 fi
7463
7464
7465 fi
7466 if test -z "$ac_cv_prog_OBJDUMP"; then
7467 ac_ct_OBJDUMP=$OBJDUMP
7468 # Extract the first word of "objdump", so it can be a program name with args.
7469 set dummy objdump; ac_word=$2
7470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7471 $as_echo_n "checking for $ac_word... " >&6; }
7472 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
7473 $as_echo_n "(cached) " >&6
7474 else
7475 if test -n "$ac_ct_OBJDUMP"; then
7476 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
7477 else
7478 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7479 for as_dir in $PATH
7480 do
7481 IFS=$as_save_IFS
7482 test -z "$as_dir" && as_dir=.
7483 for ac_exec_ext in '' $ac_executable_extensions; do
7484 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7485 ac_cv_prog_ac_ct_OBJDUMP="objdump"
7486 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7487 break 2
7488 fi
7489 done
7490 done
7491 IFS=$as_save_IFS
7492
7493 fi
7494 fi
7495 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
7496 if test -n "$ac_ct_OBJDUMP"; then
7497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
7498 $as_echo "$ac_ct_OBJDUMP" >&6; }
7499 else
7500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7501 $as_echo "no" >&6; }
7502 fi
7503
7504 if test "x$ac_ct_OBJDUMP" = x; then
7505 OBJDUMP="false"
7506 else
7507 case $cross_compiling:$ac_tool_warned in
7508 yes:)
7509 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7510 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7511 ac_tool_warned=yes ;;
7512 esac
7513 OBJDUMP=$ac_ct_OBJDUMP
7514 fi
7515 else
7516 OBJDUMP="$ac_cv_prog_OBJDUMP"
7517 fi
7518
7519 test -z "$OBJDUMP" && OBJDUMP=objdump
7520
7521
7522
7523
7524
7525
7526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
7527 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
7528 if ${lt_cv_deplibs_check_method+:} false; then :
7529 $as_echo_n "(cached) " >&6
7530 else
7531 lt_cv_file_magic_cmd='$MAGIC_CMD'
7532 lt_cv_file_magic_test_file=
7533 lt_cv_deplibs_check_method='unknown'
7534 # Need to set the preceding variable on all platforms that support
7535 # interlibrary dependencies.
7536 # 'none' -- dependencies not supported.
7537 # `unknown' -- same as none, but documents that we really don't know.
7538 # 'pass_all' -- all dependencies passed with no checks.
7539 # 'test_compile' -- check by making test program.
7540 # 'file_magic [[regex]]' -- check by looking for files in library path
7541 # which responds to the $file_magic_cmd with a given extended regex.
7542 # If you have `file' or equivalent on your system and you're not sure
7543 # whether `pass_all' will *always* work, you probably want this one.
7544
7545 case $host_os in
7546 aix[4-9]*)
7547 lt_cv_deplibs_check_method=pass_all
7548 ;;
7549
7550 beos*)
7551 lt_cv_deplibs_check_method=pass_all
7552 ;;
7553
7554 bsdi[45]*)
7555 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
7556 lt_cv_file_magic_cmd='/usr/bin/file -L'
7557 lt_cv_file_magic_test_file=/shlib/libc.so
7558 ;;
7559
7560 cygwin*)
7561 # func_win32_libid is a shell function defined in ltmain.sh
7562 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7563 lt_cv_file_magic_cmd='func_win32_libid'
7564 ;;
7565
7566 mingw* | pw32*)
7567 # Base MSYS/MinGW do not provide the 'file' command needed by
7568 # func_win32_libid shell function, so use a weaker test based on 'objdump',
7569 # unless we find 'file', for example because we are cross-compiling.
7570 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
7571 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
7572 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7573 lt_cv_file_magic_cmd='func_win32_libid'
7574 else
7575 # Keep this pattern in sync with the one in func_win32_libid.
7576 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
7577 lt_cv_file_magic_cmd='$OBJDUMP -f'
7578 fi
7579 ;;
7580
7581 cegcc*)
7582 # use the weaker test based on 'objdump'. See mingw*.
7583 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
7584 lt_cv_file_magic_cmd='$OBJDUMP -f'
7585 ;;
7586
7587 darwin* | rhapsody*)
7588 lt_cv_deplibs_check_method=pass_all
7589 ;;
7590
7591 freebsd* | dragonfly*)
7592 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
7593 case $host_cpu in
7594 i*86 )
7595 # Not sure whether the presence of OpenBSD here was a mistake.
7596 # Let's accept both of them until this is cleared up.
7597 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
7598 lt_cv_file_magic_cmd=/usr/bin/file
7599 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
7600 ;;
7601 esac
7602 else
7603 lt_cv_deplibs_check_method=pass_all
7604 fi
7605 ;;
7606
7607 gnu*)
7608 lt_cv_deplibs_check_method=pass_all
7609 ;;
7610
7611 haiku*)
7612 lt_cv_deplibs_check_method=pass_all
7613 ;;
7614
7615 hpux10.20* | hpux11*)
7616 lt_cv_file_magic_cmd=/usr/bin/file
7617 case $host_cpu in
7618 ia64*)
7619 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
7620 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
7621 ;;
7622 hppa*64*)
7623 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
7624 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
7625 ;;
7626 *)
7627 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
7628 lt_cv_file_magic_test_file=/usr/lib/libc.sl
7629 ;;
7630 esac
7631 ;;
7632
7633 interix[3-9]*)
7634 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
7635 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
7636 ;;
7637
7638 irix5* | irix6* | nonstopux*)
7639 case $LD in
7640 *-32|*"-32 ") libmagic=32-bit;;
7641 *-n32|*"-n32 ") libmagic=N32;;
7642 *-64|*"-64 ") libmagic=64-bit;;
7643 *) libmagic=never-match;;
7644 esac
7645 lt_cv_deplibs_check_method=pass_all
7646 ;;
7647
7648 # This must be glibc/ELF.
7649 linux* | k*bsd*-gnu | kopensolaris*-gnu)
7650 lt_cv_deplibs_check_method=pass_all
7651 ;;
7652
7653 netbsd* | netbsdelf*-gnu)
7654 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
7655 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
7656 else
7657 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
7658 fi
7659 ;;
7660
7661 newos6*)
7662 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
7663 lt_cv_file_magic_cmd=/usr/bin/file
7664 lt_cv_file_magic_test_file=/usr/lib/libnls.so
7665 ;;
7666
7667 *nto* | *qnx*)
7668 lt_cv_deplibs_check_method=pass_all
7669 ;;
7670
7671 openbsd*)
7672 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7673 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
7674 else
7675 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
7676 fi
7677 ;;
7678
7679 osf3* | osf4* | osf5*)
7680 lt_cv_deplibs_check_method=pass_all
7681 ;;
7682
7683 rdos*)
7684 lt_cv_deplibs_check_method=pass_all
7685 ;;
7686
7687 solaris*)
7688 lt_cv_deplibs_check_method=pass_all
7689 ;;
7690
7691 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
7692 lt_cv_deplibs_check_method=pass_all
7693 ;;
7694
7695 sysv4 | sysv4.3*)
7696 case $host_vendor in
7697 motorola)
7698 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]'
7699 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
7700 ;;
7701 ncr)
7702 lt_cv_deplibs_check_method=pass_all
7703 ;;
7704 sequent)
7705 lt_cv_file_magic_cmd='/bin/file'
7706 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
7707 ;;
7708 sni)
7709 lt_cv_file_magic_cmd='/bin/file'
7710 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
7711 lt_cv_file_magic_test_file=/lib/libc.so
7712 ;;
7713 siemens)
7714 lt_cv_deplibs_check_method=pass_all
7715 ;;
7716 pc)
7717 lt_cv_deplibs_check_method=pass_all
7718 ;;
7719 esac
7720 ;;
7721
7722 tpf*)
7723 lt_cv_deplibs_check_method=pass_all
7724 ;;
7725 esac
7726
7727 fi
7728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
7729 $as_echo "$lt_cv_deplibs_check_method" >&6; }
7730
7731 file_magic_glob=
7732 want_nocaseglob=no
7733 if test "$build" = "$host"; then
7734 case $host_os in
7735 mingw* | pw32*)
7736 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
7737 want_nocaseglob=yes
7738 else
7739 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
7740 fi
7741 ;;
7742 esac
7743 fi
7744
7745 file_magic_cmd=$lt_cv_file_magic_cmd
7746 deplibs_check_method=$lt_cv_deplibs_check_method
7747 test -z "$deplibs_check_method" && deplibs_check_method=unknown
7748
7749
7750
7751
7752
7753
7754
7755
7756
7757
7758
7759
7760
7761
7762
7763
7764
7765
7766
7767
7768
7769
7770 if test -n "$ac_tool_prefix"; then
7771 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
7772 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
7773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7774 $as_echo_n "checking for $ac_word... " >&6; }
7775 if ${ac_cv_prog_DLLTOOL+:} false; then :
7776 $as_echo_n "(cached) " >&6
7777 else
7778 if test -n "$DLLTOOL"; then
7779 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
7780 else
7781 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7782 for as_dir in $PATH
7783 do
7784 IFS=$as_save_IFS
7785 test -z "$as_dir" && as_dir=.
7786 for ac_exec_ext in '' $ac_executable_extensions; do
7787 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7788 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
7789 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7790 break 2
7791 fi
7792 done
7793 done
7794 IFS=$as_save_IFS
7795
7796 fi
7797 fi
7798 DLLTOOL=$ac_cv_prog_DLLTOOL
7799 if test -n "$DLLTOOL"; then
7800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
7801 $as_echo "$DLLTOOL" >&6; }
7802 else
7803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7804 $as_echo "no" >&6; }
7805 fi
7806
7807
7808 fi
7809 if test -z "$ac_cv_prog_DLLTOOL"; then
7810 ac_ct_DLLTOOL=$DLLTOOL
7811 # Extract the first word of "dlltool", so it can be a program name with args.
7812 set dummy dlltool; ac_word=$2
7813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7814 $as_echo_n "checking for $ac_word... " >&6; }
7815 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
7816 $as_echo_n "(cached) " >&6
7817 else
7818 if test -n "$ac_ct_DLLTOOL"; then
7819 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
7820 else
7821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7822 for as_dir in $PATH
7823 do
7824 IFS=$as_save_IFS
7825 test -z "$as_dir" && as_dir=.
7826 for ac_exec_ext in '' $ac_executable_extensions; do
7827 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7828 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
7829 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7830 break 2
7831 fi
7832 done
7833 done
7834 IFS=$as_save_IFS
7835
7836 fi
7837 fi
7838 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
7839 if test -n "$ac_ct_DLLTOOL"; then
7840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
7841 $as_echo "$ac_ct_DLLTOOL" >&6; }
7842 else
7843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7844 $as_echo "no" >&6; }
7845 fi
7846
7847 if test "x$ac_ct_DLLTOOL" = x; then
7848 DLLTOOL="false"
7849 else
7850 case $cross_compiling:$ac_tool_warned in
7851 yes:)
7852 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7853 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7854 ac_tool_warned=yes ;;
7855 esac
7856 DLLTOOL=$ac_ct_DLLTOOL
7857 fi
7858 else
7859 DLLTOOL="$ac_cv_prog_DLLTOOL"
7860 fi
7861
7862 test -z "$DLLTOOL" && DLLTOOL=dlltool
7863
7864
7865
7866
7867
7868
7869
7870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
7871 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
7872 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
7873 $as_echo_n "(cached) " >&6
7874 else
7875 lt_cv_sharedlib_from_linklib_cmd='unknown'
7876
7877 case $host_os in
7878 cygwin* | mingw* | pw32* | cegcc*)
7879 # two different shell functions defined in ltmain.sh
7880 # decide which to use based on capabilities of $DLLTOOL
7881 case `$DLLTOOL --help 2>&1` in
7882 *--identify-strict*)
7883 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
7884 ;;
7885 *)
7886 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
7887 ;;
7888 esac
7889 ;;
7890 *)
7891 # fallback: assume linklib IS sharedlib
7892 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
7893 ;;
7894 esac
7895
7896 fi
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
7898 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
7899 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
7900 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
7901
7902
7903
7904
7905
7906
7907
7908 if test -n "$ac_tool_prefix"; then
7909 for ac_prog in ar
7910 do
7911 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7912 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7914 $as_echo_n "checking for $ac_word... " >&6; }
7915 if ${ac_cv_prog_AR+:} false; then :
7916 $as_echo_n "(cached) " >&6
7917 else
7918 if test -n "$AR"; then
7919 ac_cv_prog_AR="$AR" # Let the user override the test.
7920 else
7921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7922 for as_dir in $PATH
7923 do
7924 IFS=$as_save_IFS
7925 test -z "$as_dir" && as_dir=.
7926 for ac_exec_ext in '' $ac_executable_extensions; do
7927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7928 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
7929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7930 break 2
7931 fi
7932 done
7933 done
7934 IFS=$as_save_IFS
7935
7936 fi
7937 fi
7938 AR=$ac_cv_prog_AR
7939 if test -n "$AR"; then
7940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
7941 $as_echo "$AR" >&6; }
7942 else
7943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7944 $as_echo "no" >&6; }
7945 fi
7946
7947
7948 test -n "$AR" && break
7949 done
7950 fi
7951 if test -z "$AR"; then
7952 ac_ct_AR=$AR
7953 for ac_prog in ar
7954 do
7955 # Extract the first word of "$ac_prog", so it can be a program name with args.
7956 set dummy $ac_prog; ac_word=$2
7957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7958 $as_echo_n "checking for $ac_word... " >&6; }
7959 if ${ac_cv_prog_ac_ct_AR+:} false; then :
7960 $as_echo_n "(cached) " >&6
7961 else
7962 if test -n "$ac_ct_AR"; then
7963 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7964 else
7965 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7966 for as_dir in $PATH
7967 do
7968 IFS=$as_save_IFS
7969 test -z "$as_dir" && as_dir=.
7970 for ac_exec_ext in '' $ac_executable_extensions; do
7971 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7972 ac_cv_prog_ac_ct_AR="$ac_prog"
7973 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7974 break 2
7975 fi
7976 done
7977 done
7978 IFS=$as_save_IFS
7979
7980 fi
7981 fi
7982 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7983 if test -n "$ac_ct_AR"; then
7984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7985 $as_echo "$ac_ct_AR" >&6; }
7986 else
7987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7988 $as_echo "no" >&6; }
7989 fi
7990
7991
7992 test -n "$ac_ct_AR" && break
7993 done
7994
7995 if test "x$ac_ct_AR" = x; then
7996 AR="false"
7997 else
7998 case $cross_compiling:$ac_tool_warned in
7999 yes:)
8000 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8001 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8002 ac_tool_warned=yes ;;
8003 esac
8004 AR=$ac_ct_AR
8005 fi
8006 fi
8007
8008 : ${AR=ar}
8009 : ${AR_FLAGS=cru}
8010
8011
8012
8013
8014
8015
8016
8017
8018
8019
8020
8021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8022 $as_echo_n "checking for archiver @FILE support... " >&6; }
8023 if ${lt_cv_ar_at_file+:} false; then :
8024 $as_echo_n "(cached) " >&6
8025 else
8026 lt_cv_ar_at_file=no
8027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8028 /* end confdefs.h. */
8029
8030 int
8031 main ()
8032 {
8033
8034 ;
8035 return 0;
8036 }
8037 _ACEOF
8038 if ac_fn_c_try_compile "$LINENO"; then :
8039 echo conftest.$ac_objext > conftest.lst
8040 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8041 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8042 (eval $lt_ar_try) 2>&5
8043 ac_status=$?
8044 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8045 test $ac_status = 0; }
8046 if test "$ac_status" -eq 0; then
8047 # Ensure the archiver fails upon bogus file names.
8048 rm -f conftest.$ac_objext libconftest.a
8049 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8050 (eval $lt_ar_try) 2>&5
8051 ac_status=$?
8052 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8053 test $ac_status = 0; }
8054 if test "$ac_status" -ne 0; then
8055 lt_cv_ar_at_file=@
8056 fi
8057 fi
8058 rm -f conftest.* libconftest.a
8059
8060 fi
8061 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8062
8063 fi
8064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8065 $as_echo "$lt_cv_ar_at_file" >&6; }
8066
8067 if test "x$lt_cv_ar_at_file" = xno; then
8068 archiver_list_spec=
8069 else
8070 archiver_list_spec=$lt_cv_ar_at_file
8071 fi
8072
8073
8074
8075
8076
8077
8078
8079 if test -n "$ac_tool_prefix"; then
8080 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8081 set dummy ${ac_tool_prefix}strip; ac_word=$2
8082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8083 $as_echo_n "checking for $ac_word... " >&6; }
8084 if ${ac_cv_prog_STRIP+:} false; then :
8085 $as_echo_n "(cached) " >&6
8086 else
8087 if test -n "$STRIP"; then
8088 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8089 else
8090 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8091 for as_dir in $PATH
8092 do
8093 IFS=$as_save_IFS
8094 test -z "$as_dir" && as_dir=.
8095 for ac_exec_ext in '' $ac_executable_extensions; do
8096 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8097 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8098 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8099 break 2
8100 fi
8101 done
8102 done
8103 IFS=$as_save_IFS
8104
8105 fi
8106 fi
8107 STRIP=$ac_cv_prog_STRIP
8108 if test -n "$STRIP"; then
8109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8110 $as_echo "$STRIP" >&6; }
8111 else
8112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8113 $as_echo "no" >&6; }
8114 fi
8115
8116
8117 fi
8118 if test -z "$ac_cv_prog_STRIP"; then
8119 ac_ct_STRIP=$STRIP
8120 # Extract the first word of "strip", so it can be a program name with args.
8121 set dummy strip; ac_word=$2
8122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8123 $as_echo_n "checking for $ac_word... " >&6; }
8124 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8125 $as_echo_n "(cached) " >&6
8126 else
8127 if test -n "$ac_ct_STRIP"; then
8128 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8129 else
8130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8131 for as_dir in $PATH
8132 do
8133 IFS=$as_save_IFS
8134 test -z "$as_dir" && as_dir=.
8135 for ac_exec_ext in '' $ac_executable_extensions; do
8136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8137 ac_cv_prog_ac_ct_STRIP="strip"
8138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8139 break 2
8140 fi
8141 done
8142 done
8143 IFS=$as_save_IFS
8144
8145 fi
8146 fi
8147 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8148 if test -n "$ac_ct_STRIP"; then
8149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8150 $as_echo "$ac_ct_STRIP" >&6; }
8151 else
8152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8153 $as_echo "no" >&6; }
8154 fi
8155
8156 if test "x$ac_ct_STRIP" = x; then
8157 STRIP=":"
8158 else
8159 case $cross_compiling:$ac_tool_warned in
8160 yes:)
8161 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8162 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8163 ac_tool_warned=yes ;;
8164 esac
8165 STRIP=$ac_ct_STRIP
8166 fi
8167 else
8168 STRIP="$ac_cv_prog_STRIP"
8169 fi
8170
8171 test -z "$STRIP" && STRIP=:
8172
8173
8174
8175
8176
8177
8178 if test -n "$ac_tool_prefix"; then
8179 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8180 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8182 $as_echo_n "checking for $ac_word... " >&6; }
8183 if ${ac_cv_prog_RANLIB+:} false; then :
8184 $as_echo_n "(cached) " >&6
8185 else
8186 if test -n "$RANLIB"; then
8187 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8188 else
8189 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8190 for as_dir in $PATH
8191 do
8192 IFS=$as_save_IFS
8193 test -z "$as_dir" && as_dir=.
8194 for ac_exec_ext in '' $ac_executable_extensions; do
8195 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8196 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8197 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8198 break 2
8199 fi
8200 done
8201 done
8202 IFS=$as_save_IFS
8203
8204 fi
8205 fi
8206 RANLIB=$ac_cv_prog_RANLIB
8207 if test -n "$RANLIB"; then
8208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8209 $as_echo "$RANLIB" >&6; }
8210 else
8211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8212 $as_echo "no" >&6; }
8213 fi
8214
8215
8216 fi
8217 if test -z "$ac_cv_prog_RANLIB"; then
8218 ac_ct_RANLIB=$RANLIB
8219 # Extract the first word of "ranlib", so it can be a program name with args.
8220 set dummy ranlib; ac_word=$2
8221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8222 $as_echo_n "checking for $ac_word... " >&6; }
8223 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8224 $as_echo_n "(cached) " >&6
8225 else
8226 if test -n "$ac_ct_RANLIB"; then
8227 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8228 else
8229 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8230 for as_dir in $PATH
8231 do
8232 IFS=$as_save_IFS
8233 test -z "$as_dir" && as_dir=.
8234 for ac_exec_ext in '' $ac_executable_extensions; do
8235 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8236 ac_cv_prog_ac_ct_RANLIB="ranlib"
8237 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8238 break 2
8239 fi
8240 done
8241 done
8242 IFS=$as_save_IFS
8243
8244 fi
8245 fi
8246 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8247 if test -n "$ac_ct_RANLIB"; then
8248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8249 $as_echo "$ac_ct_RANLIB" >&6; }
8250 else
8251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8252 $as_echo "no" >&6; }
8253 fi
8254
8255 if test "x$ac_ct_RANLIB" = x; then
8256 RANLIB=":"
8257 else
8258 case $cross_compiling:$ac_tool_warned in
8259 yes:)
8260 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8261 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8262 ac_tool_warned=yes ;;
8263 esac
8264 RANLIB=$ac_ct_RANLIB
8265 fi
8266 else
8267 RANLIB="$ac_cv_prog_RANLIB"
8268 fi
8269
8270 test -z "$RANLIB" && RANLIB=:
8271
8272
8273
8274
8275
8276
8277 # Determine commands to create old-style static archives.
8278 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8279 old_postinstall_cmds='chmod 644 $oldlib'
8280 old_postuninstall_cmds=
8281
8282 if test -n "$RANLIB"; then
8283 case $host_os in
8284 openbsd*)
8285 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
8286 ;;
8287 *)
8288 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
8289 ;;
8290 esac
8291 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
8292 fi
8293
8294 case $host_os in
8295 darwin*)
8296 lock_old_archive_extraction=yes ;;
8297 *)
8298 lock_old_archive_extraction=no ;;
8299 esac
8300
8301
8302
8303
8304
8305
8306
8307
8308
8309
8310
8311
8312
8313
8314
8315
8316
8317
8318
8319
8320
8321
8322
8323
8324
8325
8326
8327
8328
8329
8330
8331
8332
8333
8334
8335
8336
8337
8338
8339 # If no C compiler was specified, use CC.
8340 LTCC=${LTCC-"$CC"}
8341
8342 # If no C compiler flags were specified, use CFLAGS.
8343 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8344
8345 # Allow CC to be a program name with arguments.
8346 compiler=$CC
8347
8348
8349 # Check for command to grab the raw symbol name followed by C symbol from nm.
8350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
8351 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
8352 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
8353 $as_echo_n "(cached) " >&6
8354 else
8355
8356 # These are sane defaults that work on at least a few old systems.
8357 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
8358
8359 # Character class describing NM global symbol codes.
8360 symcode='[BCDEGRST]'
8361
8362 # Regexp to match symbols that can be accessed directly from C.
8363 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
8364
8365 # Define system-specific variables.
8366 case $host_os in
8367 aix*)
8368 symcode='[BCDT]'
8369 ;;
8370 cygwin* | mingw* | pw32* | cegcc*)
8371 symcode='[ABCDGISTW]'
8372 ;;
8373 hpux*)
8374 if test "$host_cpu" = ia64; then
8375 symcode='[ABCDEGRST]'
8376 fi
8377 ;;
8378 irix* | nonstopux*)
8379 symcode='[BCDEGRST]'
8380 ;;
8381 osf*)
8382 symcode='[BCDEGQRST]'
8383 ;;
8384 solaris*)
8385 symcode='[BDRT]'
8386 ;;
8387 sco3.2v5*)
8388 symcode='[DT]'
8389 ;;
8390 sysv4.2uw2*)
8391 symcode='[DT]'
8392 ;;
8393 sysv5* | sco5v6* | unixware* | OpenUNIX*)
8394 symcode='[ABDT]'
8395 ;;
8396 sysv4)
8397 symcode='[DFNSTU]'
8398 ;;
8399 esac
8400
8401 # If we're using GNU nm, then use its standard symbol codes.
8402 case `$NM -V 2>&1` in
8403 *GNU* | *'with BFD'*)
8404 symcode='[ABCDGIRSTW]' ;;
8405 esac
8406
8407 # Transform an extracted symbol line into a proper C declaration.
8408 # Some systems (esp. on ia64) link data and code symbols differently,
8409 # so use this general approach.
8410 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
8411
8412 # Transform an extracted symbol line into symbol name and symbol address
8413 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
8414 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'"
8415
8416 # Handle CRLF in mingw tool chain
8417 opt_cr=
8418 case $build_os in
8419 mingw*)
8420 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
8421 ;;
8422 esac
8423
8424 # Try without a prefix underscore, then with it.
8425 for ac_symprfx in "" "_"; do
8426
8427 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
8428 symxfrm="\\1 $ac_symprfx\\2 \\2"
8429
8430 # Write the raw and C identifiers.
8431 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8432 # Fake it for dumpbin and say T for any non-static function
8433 # and D for any global variable.
8434 # Also find C++ and __fastcall symbols from MSVC++,
8435 # which start with @ or ?.
8436 lt_cv_sys_global_symbol_pipe="$AWK '"\
8437 " {last_section=section; section=\$ 3};"\
8438 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
8439 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
8440 " \$ 0!~/External *\|/{next};"\
8441 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
8442 " {if(hide[section]) next};"\
8443 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
8444 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
8445 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
8446 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
8447 " ' prfx=^$ac_symprfx"
8448 else
8449 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
8450 fi
8451 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
8452
8453 # Check to see that the pipe works correctly.
8454 pipe_works=no
8455
8456 rm -f conftest*
8457 cat > conftest.$ac_ext <<_LT_EOF
8458 #ifdef __cplusplus
8459 extern "C" {
8460 #endif
8461 char nm_test_var;
8462 void nm_test_func(void);
8463 void nm_test_func(void){}
8464 #ifdef __cplusplus
8465 }
8466 #endif
8467 int main(){nm_test_var='a';nm_test_func();return(0);}
8468 _LT_EOF
8469
8470 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8471 (eval $ac_compile) 2>&5
8472 ac_status=$?
8473 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8474 test $ac_status = 0; }; then
8475 # Now try to grab the symbols.
8476 nlist=conftest.nm
8477 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
8478 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
8479 ac_status=$?
8480 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8481 test $ac_status = 0; } && test -s "$nlist"; then
8482 # Try sorting and uniquifying the output.
8483 if sort "$nlist" | uniq > "$nlist"T; then
8484 mv -f "$nlist"T "$nlist"
8485 else
8486 rm -f "$nlist"T
8487 fi
8488
8489 # Make sure that we snagged all the symbols we need.
8490 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
8491 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
8492 cat <<_LT_EOF > conftest.$ac_ext
8493 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
8494 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
8495 /* DATA imports from DLLs on WIN32 con't be const, because runtime
8496 relocations are performed -- see ld's documentation on pseudo-relocs. */
8497 # define LT_DLSYM_CONST
8498 #elif defined(__osf__)
8499 /* This system does not cope well with relocations in const data. */
8500 # define LT_DLSYM_CONST
8501 #else
8502 # define LT_DLSYM_CONST const
8503 #endif
8504
8505 #ifdef __cplusplus
8506 extern "C" {
8507 #endif
8508
8509 _LT_EOF
8510 # Now generate the symbol file.
8511 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
8512
8513 cat <<_LT_EOF >> conftest.$ac_ext
8514
8515 /* The mapping between symbol names and symbols. */
8516 LT_DLSYM_CONST struct {
8517 const char *name;
8518 void *address;
8519 }
8520 lt__PROGRAM__LTX_preloaded_symbols[] =
8521 {
8522 { "@PROGRAM@", (void *) 0 },
8523 _LT_EOF
8524 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
8525 cat <<\_LT_EOF >> conftest.$ac_ext
8526 {0, (void *) 0}
8527 };
8528
8529 /* This works around a problem in FreeBSD linker */
8530 #ifdef FREEBSD_WORKAROUND
8531 static const void *lt_preloaded_setup() {
8532 return lt__PROGRAM__LTX_preloaded_symbols;
8533 }
8534 #endif
8535
8536 #ifdef __cplusplus
8537 }
8538 #endif
8539 _LT_EOF
8540 # Now try linking the two files.
8541 mv conftest.$ac_objext conftstm.$ac_objext
8542 lt_globsym_save_LIBS=$LIBS
8543 lt_globsym_save_CFLAGS=$CFLAGS
8544 LIBS="conftstm.$ac_objext"
8545 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
8546 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
8547 (eval $ac_link) 2>&5
8548 ac_status=$?
8549 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8550 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
8551 pipe_works=yes
8552 fi
8553 LIBS=$lt_globsym_save_LIBS
8554 CFLAGS=$lt_globsym_save_CFLAGS
8555 else
8556 echo "cannot find nm_test_func in $nlist" >&5
8557 fi
8558 else
8559 echo "cannot find nm_test_var in $nlist" >&5
8560 fi
8561 else
8562 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
8563 fi
8564 else
8565 echo "$progname: failed program was:" >&5
8566 cat conftest.$ac_ext >&5
8567 fi
8568 rm -rf conftest* conftst*
8569
8570 # Do not use the global_symbol_pipe unless it works.
8571 if test "$pipe_works" = yes; then
8572 break
8573 else
8574 lt_cv_sys_global_symbol_pipe=
8575 fi
8576 done
8577
8578 fi
8579
8580 if test -z "$lt_cv_sys_global_symbol_pipe"; then
8581 lt_cv_sys_global_symbol_to_cdecl=
8582 fi
8583 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
8584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
8585 $as_echo "failed" >&6; }
8586 else
8587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
8588 $as_echo "ok" >&6; }
8589 fi
8590
8591 # Response file support.
8592 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8593 nm_file_list_spec='@'
8594 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
8595 nm_file_list_spec='@'
8596 fi
8597
8598
8599
8600
8601
8602
8603
8604
8605
8606
8607
8608
8609
8610
8611
8612
8613
8614
8615
8616
8617
8618
8619
8620
8621
8622
8623
8624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
8625 $as_echo_n "checking for sysroot... " >&6; }
8626
8627 # Check whether --with-sysroot was given.
8628 if test "${with_sysroot+set}" = set; then :
8629 withval=$with_sysroot;
8630 else
8631 with_sysroot=no
8632 fi
8633
8634
8635 lt_sysroot=
8636 case ${with_sysroot} in #(
8637 yes)
8638 if test "$GCC" = yes; then
8639 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
8640 fi
8641 ;; #(
8642 /*)
8643 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
8644 ;; #(
8645 no|'')
8646 ;; #(
8647 *)
8648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
8649 $as_echo "${with_sysroot}" >&6; }
8650 as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
8651 ;;
8652 esac
8653
8654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
8655 $as_echo "${lt_sysroot:-no}" >&6; }
8656
8657
8658
8659
8660
8661 # Check whether --enable-libtool-lock was given.
8662 if test "${enable_libtool_lock+set}" = set; then :
8663 enableval=$enable_libtool_lock;
8664 fi
8665
8666 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
8667
8668 # Some flags need to be propagated to the compiler or linker for good
8669 # libtool support.
8670 case $host in
8671 ia64-*-hpux*)
8672 # Find out which ABI we are using.
8673 echo 'int i;' > conftest.$ac_ext
8674 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8675 (eval $ac_compile) 2>&5
8676 ac_status=$?
8677 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8678 test $ac_status = 0; }; then
8679 case `/usr/bin/file conftest.$ac_objext` in
8680 *ELF-32*)
8681 HPUX_IA64_MODE="32"
8682 ;;
8683 *ELF-64*)
8684 HPUX_IA64_MODE="64"
8685 ;;
8686 esac
8687 fi
8688 rm -rf conftest*
8689 ;;
8690 *-*-irix6*)
8691 # Find out which ABI we are using.
8692 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
8693 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8694 (eval $ac_compile) 2>&5
8695 ac_status=$?
8696 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8697 test $ac_status = 0; }; then
8698 if test "$lt_cv_prog_gnu_ld" = yes; then
8699 case `/usr/bin/file conftest.$ac_objext` in
8700 *32-bit*)
8701 LD="${LD-ld} -melf32bsmip"
8702 ;;
8703 *N32*)
8704 LD="${LD-ld} -melf32bmipn32"
8705 ;;
8706 *64-bit*)
8707 LD="${LD-ld} -melf64bmip"
8708 ;;
8709 esac
8710 else
8711 case `/usr/bin/file conftest.$ac_objext` in
8712 *32-bit*)
8713 LD="${LD-ld} -32"
8714 ;;
8715 *N32*)
8716 LD="${LD-ld} -n32"
8717 ;;
8718 *64-bit*)
8719 LD="${LD-ld} -64"
8720 ;;
8721 esac
8722 fi
8723 fi
8724 rm -rf conftest*
8725 ;;
8726
8727 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
8728 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
8729 # Find out which ABI we are using.
8730 echo 'int i;' > conftest.$ac_ext
8731 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8732 (eval $ac_compile) 2>&5
8733 ac_status=$?
8734 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8735 test $ac_status = 0; }; then
8736 case `/usr/bin/file conftest.o` in
8737 *32-bit*)
8738 case $host in
8739 x86_64-*kfreebsd*-gnu)
8740 LD="${LD-ld} -m elf_i386_fbsd"
8741 ;;
8742 x86_64-*linux*)
8743 LD="${LD-ld} -m elf_i386"
8744 ;;
8745 powerpc64le-*)
8746 LD="${LD-ld} -m elf32lppclinux"
8747 ;;
8748 powerpc64-*)
8749 LD="${LD-ld} -m elf32ppclinux"
8750 ;;
8751 s390x-*linux*)
8752 LD="${LD-ld} -m elf_s390"
8753 ;;
8754 sparc64-*linux*)
8755 LD="${LD-ld} -m elf32_sparc"
8756 ;;
8757 esac
8758 ;;
8759 *64-bit*)
8760 case $host in
8761 x86_64-*kfreebsd*-gnu)
8762 LD="${LD-ld} -m elf_x86_64_fbsd"
8763 ;;
8764 x86_64-*linux*)
8765 LD="${LD-ld} -m elf_x86_64"
8766 ;;
8767 powerpcle-*)
8768 LD="${LD-ld} -m elf64lppc"
8769 ;;
8770 powerpc-*)
8771 LD="${LD-ld} -m elf64ppc"
8772 ;;
8773 s390*-*linux*|s390*-*tpf*)
8774 LD="${LD-ld} -m elf64_s390"
8775 ;;
8776 sparc*-*linux*)
8777 LD="${LD-ld} -m elf64_sparc"
8778 ;;
8779 esac
8780 ;;
8781 esac
8782 fi
8783 rm -rf conftest*
8784 ;;
8785
8786 *-*-sco3.2v5*)
8787 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
8788 SAVE_CFLAGS="$CFLAGS"
8789 CFLAGS="$CFLAGS -belf"
8790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
8791 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
8792 if ${lt_cv_cc_needs_belf+:} false; then :
8793 $as_echo_n "(cached) " >&6
8794 else
8795 ac_ext=c
8796 ac_cpp='$CPP $CPPFLAGS'
8797 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8798 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8799 ac_compiler_gnu=$ac_cv_c_compiler_gnu
8800
8801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8802 /* end confdefs.h. */
8803
8804 int
8805 main ()
8806 {
8807
8808 ;
8809 return 0;
8810 }
8811 _ACEOF
8812 if ac_fn_c_try_link "$LINENO"; then :
8813 lt_cv_cc_needs_belf=yes
8814 else
8815 lt_cv_cc_needs_belf=no
8816 fi
8817 rm -f core conftest.err conftest.$ac_objext \
8818 conftest$ac_exeext conftest.$ac_ext
8819 ac_ext=c
8820 ac_cpp='$CPP $CPPFLAGS'
8821 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8822 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8823 ac_compiler_gnu=$ac_cv_c_compiler_gnu
8824
8825 fi
8826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
8827 $as_echo "$lt_cv_cc_needs_belf" >&6; }
8828 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
8829 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
8830 CFLAGS="$SAVE_CFLAGS"
8831 fi
8832 ;;
8833 *-*solaris*)
8834 # Find out which ABI we are using.
8835 echo 'int i;' > conftest.$ac_ext
8836 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8837 (eval $ac_compile) 2>&5
8838 ac_status=$?
8839 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8840 test $ac_status = 0; }; then
8841 case `/usr/bin/file conftest.o` in
8842 *64-bit*)
8843 case $lt_cv_prog_gnu_ld in
8844 yes*)
8845 case $host in
8846 i?86-*-solaris*)
8847 LD="${LD-ld} -m elf_x86_64"
8848 ;;
8849 sparc*-*-solaris*)
8850 LD="${LD-ld} -m elf64_sparc"
8851 ;;
8852 esac
8853 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
8854 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
8855 LD="${LD-ld}_sol2"
8856 fi
8857 ;;
8858 *)
8859 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
8860 LD="${LD-ld} -64"
8861 fi
8862 ;;
8863 esac
8864 ;;
8865 esac
8866 fi
8867 rm -rf conftest*
8868 ;;
8869 esac
8870
8871 need_locks="$enable_libtool_lock"
8872
8873 if test -n "$ac_tool_prefix"; then
8874 # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
8875 set dummy ${ac_tool_prefix}mt; ac_word=$2
8876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8877 $as_echo_n "checking for $ac_word... " >&6; }
8878 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
8879 $as_echo_n "(cached) " >&6
8880 else
8881 if test -n "$MANIFEST_TOOL"; then
8882 ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
8883 else
8884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8885 for as_dir in $PATH
8886 do
8887 IFS=$as_save_IFS
8888 test -z "$as_dir" && as_dir=.
8889 for ac_exec_ext in '' $ac_executable_extensions; do
8890 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8891 ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
8892 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8893 break 2
8894 fi
8895 done
8896 done
8897 IFS=$as_save_IFS
8898
8899 fi
8900 fi
8901 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
8902 if test -n "$MANIFEST_TOOL"; then
8903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
8904 $as_echo "$MANIFEST_TOOL" >&6; }
8905 else
8906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8907 $as_echo "no" >&6; }
8908 fi
8909
8910
8911 fi
8912 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
8913 ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
8914 # Extract the first word of "mt", so it can be a program name with args.
8915 set dummy mt; ac_word=$2
8916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8917 $as_echo_n "checking for $ac_word... " >&6; }
8918 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
8919 $as_echo_n "(cached) " >&6
8920 else
8921 if test -n "$ac_ct_MANIFEST_TOOL"; then
8922 ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
8923 else
8924 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8925 for as_dir in $PATH
8926 do
8927 IFS=$as_save_IFS
8928 test -z "$as_dir" && as_dir=.
8929 for ac_exec_ext in '' $ac_executable_extensions; do
8930 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8931 ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
8932 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8933 break 2
8934 fi
8935 done
8936 done
8937 IFS=$as_save_IFS
8938
8939 fi
8940 fi
8941 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
8942 if test -n "$ac_ct_MANIFEST_TOOL"; then
8943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
8944 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
8945 else
8946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8947 $as_echo "no" >&6; }
8948 fi
8949
8950 if test "x$ac_ct_MANIFEST_TOOL" = x; then
8951 MANIFEST_TOOL=":"
8952 else
8953 case $cross_compiling:$ac_tool_warned in
8954 yes:)
8955 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8956 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8957 ac_tool_warned=yes ;;
8958 esac
8959 MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
8960 fi
8961 else
8962 MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
8963 fi
8964
8965 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
8966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
8967 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
8968 if ${lt_cv_path_mainfest_tool+:} false; then :
8969 $as_echo_n "(cached) " >&6
8970 else
8971 lt_cv_path_mainfest_tool=no
8972 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
8973 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
8974 cat conftest.err >&5
8975 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
8976 lt_cv_path_mainfest_tool=yes
8977 fi
8978 rm -f conftest*
8979 fi
8980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
8981 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
8982 if test "x$lt_cv_path_mainfest_tool" != xyes; then
8983 MANIFEST_TOOL=:
8984 fi
8985
8986
8987
8988
8989
8990
8991 case $host_os in
8992 rhapsody* | darwin*)
8993 if test -n "$ac_tool_prefix"; then
8994 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
8995 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
8996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8997 $as_echo_n "checking for $ac_word... " >&6; }
8998 if ${ac_cv_prog_DSYMUTIL+:} false; then :
8999 $as_echo_n "(cached) " >&6
9000 else
9001 if test -n "$DSYMUTIL"; then
9002 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9003 else
9004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9005 for as_dir in $PATH
9006 do
9007 IFS=$as_save_IFS
9008 test -z "$as_dir" && as_dir=.
9009 for ac_exec_ext in '' $ac_executable_extensions; do
9010 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9011 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9012 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9013 break 2
9014 fi
9015 done
9016 done
9017 IFS=$as_save_IFS
9018
9019 fi
9020 fi
9021 DSYMUTIL=$ac_cv_prog_DSYMUTIL
9022 if test -n "$DSYMUTIL"; then
9023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9024 $as_echo "$DSYMUTIL" >&6; }
9025 else
9026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9027 $as_echo "no" >&6; }
9028 fi
9029
9030
9031 fi
9032 if test -z "$ac_cv_prog_DSYMUTIL"; then
9033 ac_ct_DSYMUTIL=$DSYMUTIL
9034 # Extract the first word of "dsymutil", so it can be a program name with args.
9035 set dummy dsymutil; ac_word=$2
9036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9037 $as_echo_n "checking for $ac_word... " >&6; }
9038 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9039 $as_echo_n "(cached) " >&6
9040 else
9041 if test -n "$ac_ct_DSYMUTIL"; then
9042 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9043 else
9044 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9045 for as_dir in $PATH
9046 do
9047 IFS=$as_save_IFS
9048 test -z "$as_dir" && as_dir=.
9049 for ac_exec_ext in '' $ac_executable_extensions; do
9050 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9051 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9052 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9053 break 2
9054 fi
9055 done
9056 done
9057 IFS=$as_save_IFS
9058
9059 fi
9060 fi
9061 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9062 if test -n "$ac_ct_DSYMUTIL"; then
9063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9064 $as_echo "$ac_ct_DSYMUTIL" >&6; }
9065 else
9066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9067 $as_echo "no" >&6; }
9068 fi
9069
9070 if test "x$ac_ct_DSYMUTIL" = x; then
9071 DSYMUTIL=":"
9072 else
9073 case $cross_compiling:$ac_tool_warned in
9074 yes:)
9075 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9076 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9077 ac_tool_warned=yes ;;
9078 esac
9079 DSYMUTIL=$ac_ct_DSYMUTIL
9080 fi
9081 else
9082 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9083 fi
9084
9085 if test -n "$ac_tool_prefix"; then
9086 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9087 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9089 $as_echo_n "checking for $ac_word... " >&6; }
9090 if ${ac_cv_prog_NMEDIT+:} false; then :
9091 $as_echo_n "(cached) " >&6
9092 else
9093 if test -n "$NMEDIT"; then
9094 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9095 else
9096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9097 for as_dir in $PATH
9098 do
9099 IFS=$as_save_IFS
9100 test -z "$as_dir" && as_dir=.
9101 for ac_exec_ext in '' $ac_executable_extensions; do
9102 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9103 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9104 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9105 break 2
9106 fi
9107 done
9108 done
9109 IFS=$as_save_IFS
9110
9111 fi
9112 fi
9113 NMEDIT=$ac_cv_prog_NMEDIT
9114 if test -n "$NMEDIT"; then
9115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
9116 $as_echo "$NMEDIT" >&6; }
9117 else
9118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9119 $as_echo "no" >&6; }
9120 fi
9121
9122
9123 fi
9124 if test -z "$ac_cv_prog_NMEDIT"; then
9125 ac_ct_NMEDIT=$NMEDIT
9126 # Extract the first word of "nmedit", so it can be a program name with args.
9127 set dummy nmedit; ac_word=$2
9128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9129 $as_echo_n "checking for $ac_word... " >&6; }
9130 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
9131 $as_echo_n "(cached) " >&6
9132 else
9133 if test -n "$ac_ct_NMEDIT"; then
9134 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
9135 else
9136 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9137 for as_dir in $PATH
9138 do
9139 IFS=$as_save_IFS
9140 test -z "$as_dir" && as_dir=.
9141 for ac_exec_ext in '' $ac_executable_extensions; do
9142 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9143 ac_cv_prog_ac_ct_NMEDIT="nmedit"
9144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9145 break 2
9146 fi
9147 done
9148 done
9149 IFS=$as_save_IFS
9150
9151 fi
9152 fi
9153 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
9154 if test -n "$ac_ct_NMEDIT"; then
9155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
9156 $as_echo "$ac_ct_NMEDIT" >&6; }
9157 else
9158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9159 $as_echo "no" >&6; }
9160 fi
9161
9162 if test "x$ac_ct_NMEDIT" = x; then
9163 NMEDIT=":"
9164 else
9165 case $cross_compiling:$ac_tool_warned in
9166 yes:)
9167 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9168 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9169 ac_tool_warned=yes ;;
9170 esac
9171 NMEDIT=$ac_ct_NMEDIT
9172 fi
9173 else
9174 NMEDIT="$ac_cv_prog_NMEDIT"
9175 fi
9176
9177 if test -n "$ac_tool_prefix"; then
9178 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
9179 set dummy ${ac_tool_prefix}lipo; ac_word=$2
9180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9181 $as_echo_n "checking for $ac_word... " >&6; }
9182 if ${ac_cv_prog_LIPO+:} false; then :
9183 $as_echo_n "(cached) " >&6
9184 else
9185 if test -n "$LIPO"; then
9186 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
9187 else
9188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9189 for as_dir in $PATH
9190 do
9191 IFS=$as_save_IFS
9192 test -z "$as_dir" && as_dir=.
9193 for ac_exec_ext in '' $ac_executable_extensions; do
9194 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9195 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
9196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9197 break 2
9198 fi
9199 done
9200 done
9201 IFS=$as_save_IFS
9202
9203 fi
9204 fi
9205 LIPO=$ac_cv_prog_LIPO
9206 if test -n "$LIPO"; then
9207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
9208 $as_echo "$LIPO" >&6; }
9209 else
9210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9211 $as_echo "no" >&6; }
9212 fi
9213
9214
9215 fi
9216 if test -z "$ac_cv_prog_LIPO"; then
9217 ac_ct_LIPO=$LIPO
9218 # Extract the first word of "lipo", so it can be a program name with args.
9219 set dummy lipo; ac_word=$2
9220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9221 $as_echo_n "checking for $ac_word... " >&6; }
9222 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
9223 $as_echo_n "(cached) " >&6
9224 else
9225 if test -n "$ac_ct_LIPO"; then
9226 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
9227 else
9228 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9229 for as_dir in $PATH
9230 do
9231 IFS=$as_save_IFS
9232 test -z "$as_dir" && as_dir=.
9233 for ac_exec_ext in '' $ac_executable_extensions; do
9234 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9235 ac_cv_prog_ac_ct_LIPO="lipo"
9236 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9237 break 2
9238 fi
9239 done
9240 done
9241 IFS=$as_save_IFS
9242
9243 fi
9244 fi
9245 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
9246 if test -n "$ac_ct_LIPO"; then
9247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
9248 $as_echo "$ac_ct_LIPO" >&6; }
9249 else
9250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9251 $as_echo "no" >&6; }
9252 fi
9253
9254 if test "x$ac_ct_LIPO" = x; then
9255 LIPO=":"
9256 else
9257 case $cross_compiling:$ac_tool_warned in
9258 yes:)
9259 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9260 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9261 ac_tool_warned=yes ;;
9262 esac
9263 LIPO=$ac_ct_LIPO
9264 fi
9265 else
9266 LIPO="$ac_cv_prog_LIPO"
9267 fi
9268
9269 if test -n "$ac_tool_prefix"; then
9270 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
9271 set dummy ${ac_tool_prefix}otool; ac_word=$2
9272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9273 $as_echo_n "checking for $ac_word... " >&6; }
9274 if ${ac_cv_prog_OTOOL+:} false; then :
9275 $as_echo_n "(cached) " >&6
9276 else
9277 if test -n "$OTOOL"; then
9278 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
9279 else
9280 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9281 for as_dir in $PATH
9282 do
9283 IFS=$as_save_IFS
9284 test -z "$as_dir" && as_dir=.
9285 for ac_exec_ext in '' $ac_executable_extensions; do
9286 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9287 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
9288 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9289 break 2
9290 fi
9291 done
9292 done
9293 IFS=$as_save_IFS
9294
9295 fi
9296 fi
9297 OTOOL=$ac_cv_prog_OTOOL
9298 if test -n "$OTOOL"; then
9299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
9300 $as_echo "$OTOOL" >&6; }
9301 else
9302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9303 $as_echo "no" >&6; }
9304 fi
9305
9306
9307 fi
9308 if test -z "$ac_cv_prog_OTOOL"; then
9309 ac_ct_OTOOL=$OTOOL
9310 # Extract the first word of "otool", so it can be a program name with args.
9311 set dummy otool; ac_word=$2
9312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9313 $as_echo_n "checking for $ac_word... " >&6; }
9314 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
9315 $as_echo_n "(cached) " >&6
9316 else
9317 if test -n "$ac_ct_OTOOL"; then
9318 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
9319 else
9320 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9321 for as_dir in $PATH
9322 do
9323 IFS=$as_save_IFS
9324 test -z "$as_dir" && as_dir=.
9325 for ac_exec_ext in '' $ac_executable_extensions; do
9326 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9327 ac_cv_prog_ac_ct_OTOOL="otool"
9328 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9329 break 2
9330 fi
9331 done
9332 done
9333 IFS=$as_save_IFS
9334
9335 fi
9336 fi
9337 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
9338 if test -n "$ac_ct_OTOOL"; then
9339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
9340 $as_echo "$ac_ct_OTOOL" >&6; }
9341 else
9342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9343 $as_echo "no" >&6; }
9344 fi
9345
9346 if test "x$ac_ct_OTOOL" = x; then
9347 OTOOL=":"
9348 else
9349 case $cross_compiling:$ac_tool_warned in
9350 yes:)
9351 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9352 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9353 ac_tool_warned=yes ;;
9354 esac
9355 OTOOL=$ac_ct_OTOOL
9356 fi
9357 else
9358 OTOOL="$ac_cv_prog_OTOOL"
9359 fi
9360
9361 if test -n "$ac_tool_prefix"; then
9362 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
9363 set dummy ${ac_tool_prefix}otool64; ac_word=$2
9364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9365 $as_echo_n "checking for $ac_word... " >&6; }
9366 if ${ac_cv_prog_OTOOL64+:} false; then :
9367 $as_echo_n "(cached) " >&6
9368 else
9369 if test -n "$OTOOL64"; then
9370 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
9371 else
9372 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9373 for as_dir in $PATH
9374 do
9375 IFS=$as_save_IFS
9376 test -z "$as_dir" && as_dir=.
9377 for ac_exec_ext in '' $ac_executable_extensions; do
9378 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9379 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
9380 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9381 break 2
9382 fi
9383 done
9384 done
9385 IFS=$as_save_IFS
9386
9387 fi
9388 fi
9389 OTOOL64=$ac_cv_prog_OTOOL64
9390 if test -n "$OTOOL64"; then
9391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
9392 $as_echo "$OTOOL64" >&6; }
9393 else
9394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9395 $as_echo "no" >&6; }
9396 fi
9397
9398
9399 fi
9400 if test -z "$ac_cv_prog_OTOOL64"; then
9401 ac_ct_OTOOL64=$OTOOL64
9402 # Extract the first word of "otool64", so it can be a program name with args.
9403 set dummy otool64; ac_word=$2
9404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9405 $as_echo_n "checking for $ac_word... " >&6; }
9406 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
9407 $as_echo_n "(cached) " >&6
9408 else
9409 if test -n "$ac_ct_OTOOL64"; then
9410 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
9411 else
9412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9413 for as_dir in $PATH
9414 do
9415 IFS=$as_save_IFS
9416 test -z "$as_dir" && as_dir=.
9417 for ac_exec_ext in '' $ac_executable_extensions; do
9418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9419 ac_cv_prog_ac_ct_OTOOL64="otool64"
9420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9421 break 2
9422 fi
9423 done
9424 done
9425 IFS=$as_save_IFS
9426
9427 fi
9428 fi
9429 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
9430 if test -n "$ac_ct_OTOOL64"; then
9431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
9432 $as_echo "$ac_ct_OTOOL64" >&6; }
9433 else
9434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9435 $as_echo "no" >&6; }
9436 fi
9437
9438 if test "x$ac_ct_OTOOL64" = x; then
9439 OTOOL64=":"
9440 else
9441 case $cross_compiling:$ac_tool_warned in
9442 yes:)
9443 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9444 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9445 ac_tool_warned=yes ;;
9446 esac
9447 OTOOL64=$ac_ct_OTOOL64
9448 fi
9449 else
9450 OTOOL64="$ac_cv_prog_OTOOL64"
9451 fi
9452
9453
9454
9455
9456
9457
9458
9459
9460
9461
9462
9463
9464
9465
9466
9467
9468
9469
9470
9471
9472
9473
9474
9475
9476
9477
9478
9479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
9480 $as_echo_n "checking for -single_module linker flag... " >&6; }
9481 if ${lt_cv_apple_cc_single_mod+:} false; then :
9482 $as_echo_n "(cached) " >&6
9483 else
9484 lt_cv_apple_cc_single_mod=no
9485 if test -z "${LT_MULTI_MODULE}"; then
9486 # By default we will add the -single_module flag. You can override
9487 # by either setting the environment variable LT_MULTI_MODULE
9488 # non-empty at configure time, or by adding -multi_module to the
9489 # link flags.
9490 rm -rf libconftest.dylib*
9491 echo "int foo(void){return 1;}" > conftest.c
9492 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
9493 -dynamiclib -Wl,-single_module conftest.c" >&5
9494 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
9495 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
9496 _lt_result=$?
9497 # If there is a non-empty error log, and "single_module"
9498 # appears in it, assume the flag caused a linker warning
9499 if test -s conftest.err && $GREP single_module conftest.err; then
9500 cat conftest.err >&5
9501 # Otherwise, if the output was created with a 0 exit code from
9502 # the compiler, it worked.
9503 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
9504 lt_cv_apple_cc_single_mod=yes
9505 else
9506 cat conftest.err >&5
9507 fi
9508 rm -rf libconftest.dylib*
9509 rm -f conftest.*
9510 fi
9511 fi
9512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
9513 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
9514
9515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
9516 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
9517 if ${lt_cv_ld_exported_symbols_list+:} false; then :
9518 $as_echo_n "(cached) " >&6
9519 else
9520 lt_cv_ld_exported_symbols_list=no
9521 save_LDFLAGS=$LDFLAGS
9522 echo "_main" > conftest.sym
9523 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
9524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9525 /* end confdefs.h. */
9526
9527 int
9528 main ()
9529 {
9530
9531 ;
9532 return 0;
9533 }
9534 _ACEOF
9535 if ac_fn_c_try_link "$LINENO"; then :
9536 lt_cv_ld_exported_symbols_list=yes
9537 else
9538 lt_cv_ld_exported_symbols_list=no
9539 fi
9540 rm -f core conftest.err conftest.$ac_objext \
9541 conftest$ac_exeext conftest.$ac_ext
9542 LDFLAGS="$save_LDFLAGS"
9543
9544 fi
9545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
9546 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
9547
9548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
9549 $as_echo_n "checking for -force_load linker flag... " >&6; }
9550 if ${lt_cv_ld_force_load+:} false; then :
9551 $as_echo_n "(cached) " >&6
9552 else
9553 lt_cv_ld_force_load=no
9554 cat > conftest.c << _LT_EOF
9555 int forced_loaded() { return 2;}
9556 _LT_EOF
9557 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
9558 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
9559 echo "$AR cru libconftest.a conftest.o" >&5
9560 $AR cru libconftest.a conftest.o 2>&5
9561 echo "$RANLIB libconftest.a" >&5
9562 $RANLIB libconftest.a 2>&5
9563 cat > conftest.c << _LT_EOF
9564 int main() { return 0;}
9565 _LT_EOF
9566 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
9567 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
9568 _lt_result=$?
9569 if test -s conftest.err && $GREP force_load conftest.err; then
9570 cat conftest.err >&5
9571 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
9572 lt_cv_ld_force_load=yes
9573 else
9574 cat conftest.err >&5
9575 fi
9576 rm -f conftest.err libconftest.a conftest conftest.c
9577 rm -rf conftest.dSYM
9578
9579 fi
9580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
9581 $as_echo "$lt_cv_ld_force_load" >&6; }
9582 case $host_os in
9583 rhapsody* | darwin1.[012])
9584 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
9585 darwin1.*)
9586 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
9587 darwin*)
9588 case ${MACOSX_DEPLOYMENT_TARGET},$host in
9589 10.[012]*,*|,*powerpc*)
9590 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
9591 *)
9592 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
9593 esac
9594 ;;
9595 esac
9596 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
9597 _lt_dar_single_mod='$single_module'
9598 fi
9599 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
9600 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
9601 else
9602 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
9603 fi
9604 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
9605 _lt_dsymutil='~$DSYMUTIL $lib || :'
9606 else
9607 _lt_dsymutil=
9608 fi
9609 ;;
9610 esac
9611
9612 for ac_header in dlfcn.h
9613 do :
9614 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
9615 "
9616 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
9617 cat >>confdefs.h <<_ACEOF
9618 #define HAVE_DLFCN_H 1
9619 _ACEOF
9620
9621 fi
9622
9623 done
9624
9625
9626
9627
9628 func_stripname_cnf ()
9629 {
9630 case ${2} in
9631 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
9632 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
9633 esac
9634 } # func_stripname_cnf
9635
9636
9637
9638
9639
9640 # Set options
9641 enable_win32_dll=yes
9642
9643 case $host in
9644 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
9645 if test -n "$ac_tool_prefix"; then
9646 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
9647 set dummy ${ac_tool_prefix}as; ac_word=$2
9648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9649 $as_echo_n "checking for $ac_word... " >&6; }
9650 if ${ac_cv_prog_AS+:} false; then :
9651 $as_echo_n "(cached) " >&6
9652 else
9653 if test -n "$AS"; then
9654 ac_cv_prog_AS="$AS" # Let the user override the test.
9655 else
9656 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9657 for as_dir in $PATH
9658 do
9659 IFS=$as_save_IFS
9660 test -z "$as_dir" && as_dir=.
9661 for ac_exec_ext in '' $ac_executable_extensions; do
9662 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9663 ac_cv_prog_AS="${ac_tool_prefix}as"
9664 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9665 break 2
9666 fi
9667 done
9668 done
9669 IFS=$as_save_IFS
9670
9671 fi
9672 fi
9673 AS=$ac_cv_prog_AS
9674 if test -n "$AS"; then
9675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
9676 $as_echo "$AS" >&6; }
9677 else
9678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9679 $as_echo "no" >&6; }
9680 fi
9681
9682
9683 fi
9684 if test -z "$ac_cv_prog_AS"; then
9685 ac_ct_AS=$AS
9686 # Extract the first word of "as", so it can be a program name with args.
9687 set dummy as; ac_word=$2
9688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9689 $as_echo_n "checking for $ac_word... " >&6; }
9690 if ${ac_cv_prog_ac_ct_AS+:} false; then :
9691 $as_echo_n "(cached) " >&6
9692 else
9693 if test -n "$ac_ct_AS"; then
9694 ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
9695 else
9696 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9697 for as_dir in $PATH
9698 do
9699 IFS=$as_save_IFS
9700 test -z "$as_dir" && as_dir=.
9701 for ac_exec_ext in '' $ac_executable_extensions; do
9702 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9703 ac_cv_prog_ac_ct_AS="as"
9704 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9705 break 2
9706 fi
9707 done
9708 done
9709 IFS=$as_save_IFS
9710
9711 fi
9712 fi
9713 ac_ct_AS=$ac_cv_prog_ac_ct_AS
9714 if test -n "$ac_ct_AS"; then
9715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5
9716 $as_echo "$ac_ct_AS" >&6; }
9717 else
9718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9719 $as_echo "no" >&6; }
9720 fi
9721
9722 if test "x$ac_ct_AS" = x; then
9723 AS="false"
9724 else
9725 case $cross_compiling:$ac_tool_warned in
9726 yes:)
9727 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9728 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9729 ac_tool_warned=yes ;;
9730 esac
9731 AS=$ac_ct_AS
9732 fi
9733 else
9734 AS="$ac_cv_prog_AS"
9735 fi
9736
9737 if test -n "$ac_tool_prefix"; then
9738 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
9739 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
9740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9741 $as_echo_n "checking for $ac_word... " >&6; }
9742 if ${ac_cv_prog_DLLTOOL+:} false; then :
9743 $as_echo_n "(cached) " >&6
9744 else
9745 if test -n "$DLLTOOL"; then
9746 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
9747 else
9748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9749 for as_dir in $PATH
9750 do
9751 IFS=$as_save_IFS
9752 test -z "$as_dir" && as_dir=.
9753 for ac_exec_ext in '' $ac_executable_extensions; do
9754 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9755 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
9756 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9757 break 2
9758 fi
9759 done
9760 done
9761 IFS=$as_save_IFS
9762
9763 fi
9764 fi
9765 DLLTOOL=$ac_cv_prog_DLLTOOL
9766 if test -n "$DLLTOOL"; then
9767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
9768 $as_echo "$DLLTOOL" >&6; }
9769 else
9770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9771 $as_echo "no" >&6; }
9772 fi
9773
9774
9775 fi
9776 if test -z "$ac_cv_prog_DLLTOOL"; then
9777 ac_ct_DLLTOOL=$DLLTOOL
9778 # Extract the first word of "dlltool", so it can be a program name with args.
9779 set dummy dlltool; ac_word=$2
9780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9781 $as_echo_n "checking for $ac_word... " >&6; }
9782 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
9783 $as_echo_n "(cached) " >&6
9784 else
9785 if test -n "$ac_ct_DLLTOOL"; then
9786 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
9787 else
9788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9789 for as_dir in $PATH
9790 do
9791 IFS=$as_save_IFS
9792 test -z "$as_dir" && as_dir=.
9793 for ac_exec_ext in '' $ac_executable_extensions; do
9794 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9795 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
9796 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9797 break 2
9798 fi
9799 done
9800 done
9801 IFS=$as_save_IFS
9802
9803 fi
9804 fi
9805 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
9806 if test -n "$ac_ct_DLLTOOL"; then
9807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
9808 $as_echo "$ac_ct_DLLTOOL" >&6; }
9809 else
9810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9811 $as_echo "no" >&6; }
9812 fi
9813
9814 if test "x$ac_ct_DLLTOOL" = x; then
9815 DLLTOOL="false"
9816 else
9817 case $cross_compiling:$ac_tool_warned in
9818 yes:)
9819 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9820 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9821 ac_tool_warned=yes ;;
9822 esac
9823 DLLTOOL=$ac_ct_DLLTOOL
9824 fi
9825 else
9826 DLLTOOL="$ac_cv_prog_DLLTOOL"
9827 fi
9828
9829 if test -n "$ac_tool_prefix"; then
9830 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
9831 set dummy ${ac_tool_prefix}objdump; ac_word=$2
9832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9833 $as_echo_n "checking for $ac_word... " >&6; }
9834 if ${ac_cv_prog_OBJDUMP+:} false; then :
9835 $as_echo_n "(cached) " >&6
9836 else
9837 if test -n "$OBJDUMP"; then
9838 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
9839 else
9840 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9841 for as_dir in $PATH
9842 do
9843 IFS=$as_save_IFS
9844 test -z "$as_dir" && as_dir=.
9845 for ac_exec_ext in '' $ac_executable_extensions; do
9846 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9847 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
9848 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9849 break 2
9850 fi
9851 done
9852 done
9853 IFS=$as_save_IFS
9854
9855 fi
9856 fi
9857 OBJDUMP=$ac_cv_prog_OBJDUMP
9858 if test -n "$OBJDUMP"; then
9859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
9860 $as_echo "$OBJDUMP" >&6; }
9861 else
9862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9863 $as_echo "no" >&6; }
9864 fi
9865
9866
9867 fi
9868 if test -z "$ac_cv_prog_OBJDUMP"; then
9869 ac_ct_OBJDUMP=$OBJDUMP
9870 # Extract the first word of "objdump", so it can be a program name with args.
9871 set dummy objdump; ac_word=$2
9872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9873 $as_echo_n "checking for $ac_word... " >&6; }
9874 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
9875 $as_echo_n "(cached) " >&6
9876 else
9877 if test -n "$ac_ct_OBJDUMP"; then
9878 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
9879 else
9880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9881 for as_dir in $PATH
9882 do
9883 IFS=$as_save_IFS
9884 test -z "$as_dir" && as_dir=.
9885 for ac_exec_ext in '' $ac_executable_extensions; do
9886 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9887 ac_cv_prog_ac_ct_OBJDUMP="objdump"
9888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9889 break 2
9890 fi
9891 done
9892 done
9893 IFS=$as_save_IFS
9894
9895 fi
9896 fi
9897 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
9898 if test -n "$ac_ct_OBJDUMP"; then
9899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
9900 $as_echo "$ac_ct_OBJDUMP" >&6; }
9901 else
9902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9903 $as_echo "no" >&6; }
9904 fi
9905
9906 if test "x$ac_ct_OBJDUMP" = x; then
9907 OBJDUMP="false"
9908 else
9909 case $cross_compiling:$ac_tool_warned in
9910 yes:)
9911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9912 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9913 ac_tool_warned=yes ;;
9914 esac
9915 OBJDUMP=$ac_ct_OBJDUMP
9916 fi
9917 else
9918 OBJDUMP="$ac_cv_prog_OBJDUMP"
9919 fi
9920
9921 ;;
9922 esac
9923
9924 test -z "$AS" && AS=as
9925
9926
9927
9928
9929
9930 test -z "$DLLTOOL" && DLLTOOL=dlltool
9931
9932
9933
9934
9935
9936 test -z "$OBJDUMP" && OBJDUMP=objdump
9937
9938
9939
9940
9941 # Check whether --enable-static was given.
9942 if test "${enable_static+set}" = set; then :
9943 enableval=$enable_static; p=${PACKAGE-default}
9944 case $enableval in
9945 yes) enable_static=yes ;;
9946 no) enable_static=no ;;
9947 *)
9948 enable_static=no
9949 # Look at the argument we got. We use all the common list separators.
9950 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9951 for pkg in $enableval; do
9952 IFS="$lt_save_ifs"
9953 if test "X$pkg" = "X$p"; then
9954 enable_static=yes
9955 fi
9956 done
9957 IFS="$lt_save_ifs"
9958 ;;
9959 esac
9960 else
9961 enable_static=no
9962 fi
9963
9964
9965
9966
9967
9968
9969
9970
9971
9972
9973 enable_dlopen=no
9974
9975
9976
9977 # Check whether --enable-shared was given.
9978 if test "${enable_shared+set}" = set; then :
9979 enableval=$enable_shared; p=${PACKAGE-default}
9980 case $enableval in
9981 yes) enable_shared=yes ;;
9982 no) enable_shared=no ;;
9983 *)
9984 enable_shared=no
9985 # Look at the argument we got. We use all the common list separators.
9986 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9987 for pkg in $enableval; do
9988 IFS="$lt_save_ifs"
9989 if test "X$pkg" = "X$p"; then
9990 enable_shared=yes
9991 fi
9992 done
9993 IFS="$lt_save_ifs"
9994 ;;
9995 esac
9996 else
9997 enable_shared=yes
9998 fi
9999
10000
10001
10002
10003
10004
10005
10006
10007
10008
10009
10010 # Check whether --with-pic was given.
10011 if test "${with_pic+set}" = set; then :
10012 withval=$with_pic; lt_p=${PACKAGE-default}
10013 case $withval in
10014 yes|no) pic_mode=$withval ;;
10015 *)
10016 pic_mode=default
10017 # Look at the argument we got. We use all the common list separators.
10018 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10019 for lt_pkg in $withval; do
10020 IFS="$lt_save_ifs"
10021 if test "X$lt_pkg" = "X$lt_p"; then
10022 pic_mode=yes
10023 fi
10024 done
10025 IFS="$lt_save_ifs"
10026 ;;
10027 esac
10028 else
10029 pic_mode=default
10030 fi
10031
10032
10033 test -z "$pic_mode" && pic_mode=default
10034
10035
10036
10037
10038
10039
10040
10041 # Check whether --enable-fast-install was given.
10042 if test "${enable_fast_install+set}" = set; then :
10043 enableval=$enable_fast_install; p=${PACKAGE-default}
10044 case $enableval in
10045 yes) enable_fast_install=yes ;;
10046 no) enable_fast_install=no ;;
10047 *)
10048 enable_fast_install=no
10049 # Look at the argument we got. We use all the common list separators.
10050 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10051 for pkg in $enableval; do
10052 IFS="$lt_save_ifs"
10053 if test "X$pkg" = "X$p"; then
10054 enable_fast_install=yes
10055 fi
10056 done
10057 IFS="$lt_save_ifs"
10058 ;;
10059 esac
10060 else
10061 enable_fast_install=yes
10062 fi
10063
10064
10065
10066
10067
10068
10069
10070
10071
10072
10073
10074 # This can be used to rebuild libtool when needed
10075 LIBTOOL_DEPS="$ltmain"
10076
10077 # Always use our own libtool.
10078 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10079
10080
10081
10082
10083
10084
10085
10086
10087
10088
10089
10090
10091
10092
10093
10094
10095
10096
10097
10098
10099
10100
10101
10102
10103
10104
10105
10106
10107
10108
10109 test -z "$LN_S" && LN_S="ln -s"
10110
10111
10112
10113
10114
10115
10116
10117
10118
10119
10120
10121
10122
10123
10124 if test -n "${ZSH_VERSION+set}" ; then
10125 setopt NO_GLOB_SUBST
10126 fi
10127
10128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
10129 $as_echo_n "checking for objdir... " >&6; }
10130 if ${lt_cv_objdir+:} false; then :
10131 $as_echo_n "(cached) " >&6
10132 else
10133 rm -f .libs 2>/dev/null
10134 mkdir .libs 2>/dev/null
10135 if test -d .libs; then
10136 lt_cv_objdir=.libs
10137 else
10138 # MS-DOS does not allow filenames that begin with a dot.
10139 lt_cv_objdir=_libs
10140 fi
10141 rmdir .libs 2>/dev/null
10142 fi
10143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
10144 $as_echo "$lt_cv_objdir" >&6; }
10145 objdir=$lt_cv_objdir
10146
10147
10148
10149
10150
10151 cat >>confdefs.h <<_ACEOF
10152 #define LT_OBJDIR "$lt_cv_objdir/"
10153 _ACEOF
10154
10155
10156
10157
10158 case $host_os in
10159 aix3*)
10160 # AIX sometimes has problems with the GCC collect2 program. For some
10161 # reason, if we set the COLLECT_NAMES environment variable, the problems
10162 # vanish in a puff of smoke.
10163 if test "X${COLLECT_NAMES+set}" != Xset; then
10164 COLLECT_NAMES=
10165 export COLLECT_NAMES
10166 fi
10167 ;;
10168 esac
10169
10170 # Global variables:
10171 ofile=libtool
10172 can_build_shared=yes
10173
10174 # All known linkers require a `.a' archive for static linking (except MSVC,
10175 # which needs '.lib').
10176 libext=a
10177
10178 with_gnu_ld="$lt_cv_prog_gnu_ld"
10179
10180 old_CC="$CC"
10181 old_CFLAGS="$CFLAGS"
10182
10183 # Set sane defaults for various variables
10184 test -z "$CC" && CC=cc
10185 test -z "$LTCC" && LTCC=$CC
10186 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
10187 test -z "$LD" && LD=ld
10188 test -z "$ac_objext" && ac_objext=o
10189
10190 for cc_temp in $compiler""; do
10191 case $cc_temp in
10192 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
10193 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
10194 \-*) ;;
10195 *) break;;
10196 esac
10197 done
10198 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
10199
10200
10201 # Only perform the check for file, if the check method requires it
10202 test -z "$MAGIC_CMD" && MAGIC_CMD=file
10203 case $deplibs_check_method in
10204 file_magic*)
10205 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
10206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
10207 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
10208 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10209 $as_echo_n "(cached) " >&6
10210 else
10211 case $MAGIC_CMD in
10212 [\\/*] | ?:[\\/]*)
10213 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
10214 ;;
10215 *)
10216 lt_save_MAGIC_CMD="$MAGIC_CMD"
10217 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
10218 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10219 for ac_dir in $ac_dummy; do
10220 IFS="$lt_save_ifs"
10221 test -z "$ac_dir" && ac_dir=.
10222 if test -f $ac_dir/${ac_tool_prefix}file; then
10223 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
10224 if test -n "$file_magic_test_file"; then
10225 case $deplibs_check_method in
10226 "file_magic "*)
10227 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10228 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
10229 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10230 $EGREP "$file_magic_regex" > /dev/null; then
10231 :
10232 else
10233 cat <<_LT_EOF 1>&2
10234
10235 *** Warning: the command libtool uses to detect shared libraries,
10236 *** $file_magic_cmd, produces output that libtool cannot recognize.
10237 *** The result is that libtool may fail to recognize shared libraries
10238 *** as such. This will affect the creation of libtool libraries that
10239 *** depend on shared libraries, but programs linked with such libtool
10240 *** libraries will work regardless of this problem. Nevertheless, you
10241 *** may want to report the problem to your system manager and/or to
10242 *** bug-libtool@gnu.org
10243
10244 _LT_EOF
10245 fi ;;
10246 esac
10247 fi
10248 break
10249 fi
10250 done
10251 IFS="$lt_save_ifs"
10252 MAGIC_CMD="$lt_save_MAGIC_CMD"
10253 ;;
10254 esac
10255 fi
10256
10257 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
10258 if test -n "$MAGIC_CMD"; then
10259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10260 $as_echo "$MAGIC_CMD" >&6; }
10261 else
10262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10263 $as_echo "no" >&6; }
10264 fi
10265
10266
10267
10268
10269
10270 if test -z "$lt_cv_path_MAGIC_CMD"; then
10271 if test -n "$ac_tool_prefix"; then
10272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
10273 $as_echo_n "checking for file... " >&6; }
10274 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10275 $as_echo_n "(cached) " >&6
10276 else
10277 case $MAGIC_CMD in
10278 [\\/*] | ?:[\\/]*)
10279 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
10280 ;;
10281 *)
10282 lt_save_MAGIC_CMD="$MAGIC_CMD"
10283 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
10284 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10285 for ac_dir in $ac_dummy; do
10286 IFS="$lt_save_ifs"
10287 test -z "$ac_dir" && ac_dir=.
10288 if test -f $ac_dir/file; then
10289 lt_cv_path_MAGIC_CMD="$ac_dir/file"
10290 if test -n "$file_magic_test_file"; then
10291 case $deplibs_check_method in
10292 "file_magic "*)
10293 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10294 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
10295 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10296 $EGREP "$file_magic_regex" > /dev/null; then
10297 :
10298 else
10299 cat <<_LT_EOF 1>&2
10300
10301 *** Warning: the command libtool uses to detect shared libraries,
10302 *** $file_magic_cmd, produces output that libtool cannot recognize.
10303 *** The result is that libtool may fail to recognize shared libraries
10304 *** as such. This will affect the creation of libtool libraries that
10305 *** depend on shared libraries, but programs linked with such libtool
10306 *** libraries will work regardless of this problem. Nevertheless, you
10307 *** may want to report the problem to your system manager and/or to
10308 *** bug-libtool@gnu.org
10309
10310 _LT_EOF
10311 fi ;;
10312 esac
10313 fi
10314 break
10315 fi
10316 done
10317 IFS="$lt_save_ifs"
10318 MAGIC_CMD="$lt_save_MAGIC_CMD"
10319 ;;
10320 esac
10321 fi
10322
10323 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
10324 if test -n "$MAGIC_CMD"; then
10325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10326 $as_echo "$MAGIC_CMD" >&6; }
10327 else
10328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10329 $as_echo "no" >&6; }
10330 fi
10331
10332
10333 else
10334 MAGIC_CMD=:
10335 fi
10336 fi
10337
10338 fi
10339 ;;
10340 esac
10341
10342 # Use C for the default configuration in the libtool script
10343
10344 lt_save_CC="$CC"
10345 ac_ext=c
10346 ac_cpp='$CPP $CPPFLAGS'
10347 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10348 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10349 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10350
10351
10352 # Source file extension for C test sources.
10353 ac_ext=c
10354
10355 # Object file extension for compiled C test sources.
10356 objext=o
10357 objext=$objext
10358
10359 # Code to be used in simple compile tests
10360 lt_simple_compile_test_code="int some_variable = 0;"
10361
10362 # Code to be used in simple link tests
10363 lt_simple_link_test_code='int main(){return(0);}'
10364
10365
10366
10367
10368
10369
10370
10371 # If no C compiler was specified, use CC.
10372 LTCC=${LTCC-"$CC"}
10373
10374 # If no C compiler flags were specified, use CFLAGS.
10375 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
10376
10377 # Allow CC to be a program name with arguments.
10378 compiler=$CC
10379
10380 # Save the default compiler, since it gets overwritten when the other
10381 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
10382 compiler_DEFAULT=$CC
10383
10384 # save warnings/boilerplate of simple test code
10385 ac_outfile=conftest.$ac_objext
10386 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
10387 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10388 _lt_compiler_boilerplate=`cat conftest.err`
10389 $RM conftest*
10390
10391 ac_outfile=conftest.$ac_objext
10392 echo "$lt_simple_link_test_code" >conftest.$ac_ext
10393 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10394 _lt_linker_boilerplate=`cat conftest.err`
10395 $RM -r conftest*
10396
10397
10398 ## CAVEAT EMPTOR:
10399 ## There is no encapsulation within the following macros, do not change
10400 ## the running order or otherwise move them around unless you know exactly
10401 ## what you are doing...
10402 if test -n "$compiler"; then
10403
10404 lt_prog_compiler_no_builtin_flag=
10405
10406 if test "$GCC" = yes; then
10407 case $cc_basename in
10408 nvcc*)
10409 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
10410 *)
10411 lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
10412 esac
10413
10414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
10415 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
10416 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
10417 $as_echo_n "(cached) " >&6
10418 else
10419 lt_cv_prog_compiler_rtti_exceptions=no
10420 ac_outfile=conftest.$ac_objext
10421 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10422 lt_compiler_flag="-fno-rtti -fno-exceptions"
10423 # Insert the option either (1) after the last *FLAGS variable, or
10424 # (2) before a word containing "conftest.", or (3) at the end.
10425 # Note that $ac_compile itself does not contain backslashes and begins
10426 # with a dollar sign (not a hyphen), so the echo should work correctly.
10427 # The option is referenced via a variable to avoid confusing sed.
10428 lt_compile=`echo "$ac_compile" | $SED \
10429 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10430 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10431 -e 's:$: $lt_compiler_flag:'`
10432 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10433 (eval "$lt_compile" 2>conftest.err)
10434 ac_status=$?
10435 cat conftest.err >&5
10436 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10437 if (exit $ac_status) && test -s "$ac_outfile"; then
10438 # The compiler can only warn and ignore the option if not recognized
10439 # So say no if there are warnings other than the usual output.
10440 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10441 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10442 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10443 lt_cv_prog_compiler_rtti_exceptions=yes
10444 fi
10445 fi
10446 $RM conftest*
10447
10448 fi
10449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
10450 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
10451
10452 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
10453 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
10454 else
10455 :
10456 fi
10457
10458 fi
10459
10460
10461
10462
10463
10464
10465 lt_prog_compiler_wl=
10466 lt_prog_compiler_pic=
10467 lt_prog_compiler_static=
10468
10469
10470 if test "$GCC" = yes; then
10471 lt_prog_compiler_wl='-Wl,'
10472 lt_prog_compiler_static='-static'
10473
10474 case $host_os in
10475 aix*)
10476 # All AIX code is PIC.
10477 if test "$host_cpu" = ia64; then
10478 # AIX 5 now supports IA64 processor
10479 lt_prog_compiler_static='-Bstatic'
10480 fi
10481 ;;
10482
10483 amigaos*)
10484 case $host_cpu in
10485 powerpc)
10486 # see comment about AmigaOS4 .so support
10487 lt_prog_compiler_pic='-fPIC'
10488 ;;
10489 m68k)
10490 # FIXME: we need at least 68020 code to build shared libraries, but
10491 # adding the `-m68020' flag to GCC prevents building anything better,
10492 # like `-m68040'.
10493 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
10494 ;;
10495 esac
10496 ;;
10497
10498 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
10499 # PIC is the default for these OSes.
10500 ;;
10501
10502 mingw* | cygwin* | pw32* | os2* | cegcc*)
10503 # This hack is so that the source file can tell whether it is being
10504 # built for inclusion in a dll (and should export symbols for example).
10505 # Although the cygwin gcc ignores -fPIC, still need this for old-style
10506 # (--disable-auto-import) libraries
10507 lt_prog_compiler_pic='-DDLL_EXPORT'
10508 ;;
10509
10510 darwin* | rhapsody*)
10511 # PIC is the default on this platform
10512 # Common symbols not allowed in MH_DYLIB files
10513 lt_prog_compiler_pic='-fno-common'
10514 ;;
10515
10516 haiku*)
10517 # PIC is the default for Haiku.
10518 # The "-static" flag exists, but is broken.
10519 lt_prog_compiler_static=
10520 ;;
10521
10522 hpux*)
10523 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
10524 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
10525 # sets the default TLS model and affects inlining.
10526 case $host_cpu in
10527 hppa*64*)
10528 # +Z the default
10529 ;;
10530 *)
10531 lt_prog_compiler_pic='-fPIC'
10532 ;;
10533 esac
10534 ;;
10535
10536 interix[3-9]*)
10537 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
10538 # Instead, we relocate shared libraries at runtime.
10539 ;;
10540
10541 msdosdjgpp*)
10542 # Just because we use GCC doesn't mean we suddenly get shared libraries
10543 # on systems that don't support them.
10544 lt_prog_compiler_can_build_shared=no
10545 enable_shared=no
10546 ;;
10547
10548 *nto* | *qnx*)
10549 # QNX uses GNU C++, but need to define -shared option too, otherwise
10550 # it will coredump.
10551 lt_prog_compiler_pic='-fPIC -shared'
10552 ;;
10553
10554 sysv4*MP*)
10555 if test -d /usr/nec; then
10556 lt_prog_compiler_pic=-Kconform_pic
10557 fi
10558 ;;
10559
10560 *)
10561 lt_prog_compiler_pic='-fPIC'
10562 ;;
10563 esac
10564
10565 case $cc_basename in
10566 nvcc*) # Cuda Compiler Driver 2.2
10567 lt_prog_compiler_wl='-Xlinker '
10568 if test -n "$lt_prog_compiler_pic"; then
10569 lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
10570 fi
10571 ;;
10572 esac
10573 else
10574 # PORTME Check for flag to pass linker flags through the system compiler.
10575 case $host_os in
10576 aix*)
10577 lt_prog_compiler_wl='-Wl,'
10578 if test "$host_cpu" = ia64; then
10579 # AIX 5 now supports IA64 processor
10580 lt_prog_compiler_static='-Bstatic'
10581 else
10582 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
10583 fi
10584 ;;
10585
10586 mingw* | cygwin* | pw32* | os2* | cegcc*)
10587 # This hack is so that the source file can tell whether it is being
10588 # built for inclusion in a dll (and should export symbols for example).
10589 lt_prog_compiler_pic='-DDLL_EXPORT'
10590 ;;
10591
10592 hpux9* | hpux10* | hpux11*)
10593 lt_prog_compiler_wl='-Wl,'
10594 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
10595 # not for PA HP-UX.
10596 case $host_cpu in
10597 hppa*64*|ia64*)
10598 # +Z the default
10599 ;;
10600 *)
10601 lt_prog_compiler_pic='+Z'
10602 ;;
10603 esac
10604 # Is there a better lt_prog_compiler_static that works with the bundled CC?
10605 lt_prog_compiler_static='${wl}-a ${wl}archive'
10606 ;;
10607
10608 irix5* | irix6* | nonstopux*)
10609 lt_prog_compiler_wl='-Wl,'
10610 # PIC (with -KPIC) is the default.
10611 lt_prog_compiler_static='-non_shared'
10612 ;;
10613
10614 linux* | k*bsd*-gnu | kopensolaris*-gnu)
10615 case $cc_basename in
10616 # old Intel for x86_64 which still supported -KPIC.
10617 ecc*)
10618 lt_prog_compiler_wl='-Wl,'
10619 lt_prog_compiler_pic='-KPIC'
10620 lt_prog_compiler_static='-static'
10621 ;;
10622 # icc used to be incompatible with GCC.
10623 # ICC 10 doesn't accept -KPIC any more.
10624 icc* | ifort*)
10625 lt_prog_compiler_wl='-Wl,'
10626 lt_prog_compiler_pic='-fPIC'
10627 lt_prog_compiler_static='-static'
10628 ;;
10629 # Lahey Fortran 8.1.
10630 lf95*)
10631 lt_prog_compiler_wl='-Wl,'
10632 lt_prog_compiler_pic='--shared'
10633 lt_prog_compiler_static='--static'
10634 ;;
10635 nagfor*)
10636 # NAG Fortran compiler
10637 lt_prog_compiler_wl='-Wl,-Wl,,'
10638 lt_prog_compiler_pic='-PIC'
10639 lt_prog_compiler_static='-Bstatic'
10640 ;;
10641 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
10642 # Portland Group compilers (*not* the Pentium gcc compiler,
10643 # which looks to be a dead project)
10644 lt_prog_compiler_wl='-Wl,'
10645 lt_prog_compiler_pic='-fpic'
10646 lt_prog_compiler_static='-Bstatic'
10647 ;;
10648 ccc*)
10649 lt_prog_compiler_wl='-Wl,'
10650 # All Alpha code is PIC.
10651 lt_prog_compiler_static='-non_shared'
10652 ;;
10653 xl* | bgxl* | bgf* | mpixl*)
10654 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
10655 lt_prog_compiler_wl='-Wl,'
10656 lt_prog_compiler_pic='-qpic'
10657 lt_prog_compiler_static='-qstaticlink'
10658 ;;
10659 *)
10660 case `$CC -V 2>&1 | sed 5q` in
10661 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
10662 # Sun Fortran 8.3 passes all unrecognized flags to the linker
10663 lt_prog_compiler_pic='-KPIC'
10664 lt_prog_compiler_static='-Bstatic'
10665 lt_prog_compiler_wl=''
10666 ;;
10667 *Sun\ F* | *Sun*Fortran*)
10668 lt_prog_compiler_pic='-KPIC'
10669 lt_prog_compiler_static='-Bstatic'
10670 lt_prog_compiler_wl='-Qoption ld '
10671 ;;
10672 *Sun\ C*)
10673 # Sun C 5.9
10674 lt_prog_compiler_pic='-KPIC'
10675 lt_prog_compiler_static='-Bstatic'
10676 lt_prog_compiler_wl='-Wl,'
10677 ;;
10678 *Intel*\ [CF]*Compiler*)
10679 lt_prog_compiler_wl='-Wl,'
10680 lt_prog_compiler_pic='-fPIC'
10681 lt_prog_compiler_static='-static'
10682 ;;
10683 *Portland\ Group*)
10684 lt_prog_compiler_wl='-Wl,'
10685 lt_prog_compiler_pic='-fpic'
10686 lt_prog_compiler_static='-Bstatic'
10687 ;;
10688 esac
10689 ;;
10690 esac
10691 ;;
10692
10693 newsos6)
10694 lt_prog_compiler_pic='-KPIC'
10695 lt_prog_compiler_static='-Bstatic'
10696 ;;
10697
10698 *nto* | *qnx*)
10699 # QNX uses GNU C++, but need to define -shared option too, otherwise
10700 # it will coredump.
10701 lt_prog_compiler_pic='-fPIC -shared'
10702 ;;
10703
10704 osf3* | osf4* | osf5*)
10705 lt_prog_compiler_wl='-Wl,'
10706 # All OSF/1 code is PIC.
10707 lt_prog_compiler_static='-non_shared'
10708 ;;
10709
10710 rdos*)
10711 lt_prog_compiler_static='-non_shared'
10712 ;;
10713
10714 solaris*)
10715 lt_prog_compiler_pic='-KPIC'
10716 lt_prog_compiler_static='-Bstatic'
10717 case $cc_basename in
10718 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
10719 lt_prog_compiler_wl='-Qoption ld ';;
10720 *)
10721 lt_prog_compiler_wl='-Wl,';;
10722 esac
10723 ;;
10724
10725 sunos4*)
10726 lt_prog_compiler_wl='-Qoption ld '
10727 lt_prog_compiler_pic='-PIC'
10728 lt_prog_compiler_static='-Bstatic'
10729 ;;
10730
10731 sysv4 | sysv4.2uw2* | sysv4.3*)
10732 lt_prog_compiler_wl='-Wl,'
10733 lt_prog_compiler_pic='-KPIC'
10734 lt_prog_compiler_static='-Bstatic'
10735 ;;
10736
10737 sysv4*MP*)
10738 if test -d /usr/nec ;then
10739 lt_prog_compiler_pic='-Kconform_pic'
10740 lt_prog_compiler_static='-Bstatic'
10741 fi
10742 ;;
10743
10744 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
10745 lt_prog_compiler_wl='-Wl,'
10746 lt_prog_compiler_pic='-KPIC'
10747 lt_prog_compiler_static='-Bstatic'
10748 ;;
10749
10750 unicos*)
10751 lt_prog_compiler_wl='-Wl,'
10752 lt_prog_compiler_can_build_shared=no
10753 ;;
10754
10755 uts4*)
10756 lt_prog_compiler_pic='-pic'
10757 lt_prog_compiler_static='-Bstatic'
10758 ;;
10759
10760 *)
10761 lt_prog_compiler_can_build_shared=no
10762 ;;
10763 esac
10764 fi
10765
10766 case $host_os in
10767 # For platforms which do not support PIC, -DPIC is meaningless:
10768 *djgpp*)
10769 lt_prog_compiler_pic=
10770 ;;
10771 *)
10772 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
10773 ;;
10774 esac
10775
10776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
10777 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
10778 if ${lt_cv_prog_compiler_pic+:} false; then :
10779 $as_echo_n "(cached) " >&6
10780 else
10781 lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
10782 fi
10783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
10784 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
10785 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
10786
10787 #
10788 # Check to make sure the PIC flag actually works.
10789 #
10790 if test -n "$lt_prog_compiler_pic"; then
10791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
10792 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
10793 if ${lt_cv_prog_compiler_pic_works+:} false; then :
10794 $as_echo_n "(cached) " >&6
10795 else
10796 lt_cv_prog_compiler_pic_works=no
10797 ac_outfile=conftest.$ac_objext
10798 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10799 lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
10800 # Insert the option either (1) after the last *FLAGS variable, or
10801 # (2) before a word containing "conftest.", or (3) at the end.
10802 # Note that $ac_compile itself does not contain backslashes and begins
10803 # with a dollar sign (not a hyphen), so the echo should work correctly.
10804 # The option is referenced via a variable to avoid confusing sed.
10805 lt_compile=`echo "$ac_compile" | $SED \
10806 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10807 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10808 -e 's:$: $lt_compiler_flag:'`
10809 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10810 (eval "$lt_compile" 2>conftest.err)
10811 ac_status=$?
10812 cat conftest.err >&5
10813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10814 if (exit $ac_status) && test -s "$ac_outfile"; then
10815 # The compiler can only warn and ignore the option if not recognized
10816 # So say no if there are warnings other than the usual output.
10817 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10818 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10819 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10820 lt_cv_prog_compiler_pic_works=yes
10821 fi
10822 fi
10823 $RM conftest*
10824
10825 fi
10826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
10827 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
10828
10829 if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
10830 case $lt_prog_compiler_pic in
10831 "" | " "*) ;;
10832 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
10833 esac
10834 else
10835 lt_prog_compiler_pic=
10836 lt_prog_compiler_can_build_shared=no
10837 fi
10838
10839 fi
10840
10841
10842
10843
10844
10845
10846
10847
10848
10849
10850
10851 #
10852 # Check to make sure the static flag actually works.
10853 #
10854 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
10855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
10856 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
10857 if ${lt_cv_prog_compiler_static_works+:} false; then :
10858 $as_echo_n "(cached) " >&6
10859 else
10860 lt_cv_prog_compiler_static_works=no
10861 save_LDFLAGS="$LDFLAGS"
10862 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
10863 echo "$lt_simple_link_test_code" > conftest.$ac_ext
10864 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
10865 # The linker can only warn and ignore the option if not recognized
10866 # So say no if there are warnings
10867 if test -s conftest.err; then
10868 # Append any errors to the config.log.
10869 cat conftest.err 1>&5
10870 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
10871 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10872 if diff conftest.exp conftest.er2 >/dev/null; then
10873 lt_cv_prog_compiler_static_works=yes
10874 fi
10875 else
10876 lt_cv_prog_compiler_static_works=yes
10877 fi
10878 fi
10879 $RM -r conftest*
10880 LDFLAGS="$save_LDFLAGS"
10881
10882 fi
10883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
10884 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
10885
10886 if test x"$lt_cv_prog_compiler_static_works" = xyes; then
10887 :
10888 else
10889 lt_prog_compiler_static=
10890 fi
10891
10892
10893
10894
10895
10896
10897
10898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
10899 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
10900 if ${lt_cv_prog_compiler_c_o+:} false; then :
10901 $as_echo_n "(cached) " >&6
10902 else
10903 lt_cv_prog_compiler_c_o=no
10904 $RM -r conftest 2>/dev/null
10905 mkdir conftest
10906 cd conftest
10907 mkdir out
10908 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10909
10910 lt_compiler_flag="-o out/conftest2.$ac_objext"
10911 # Insert the option either (1) after the last *FLAGS variable, or
10912 # (2) before a word containing "conftest.", or (3) at the end.
10913 # Note that $ac_compile itself does not contain backslashes and begins
10914 # with a dollar sign (not a hyphen), so the echo should work correctly.
10915 lt_compile=`echo "$ac_compile" | $SED \
10916 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10917 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10918 -e 's:$: $lt_compiler_flag:'`
10919 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10920 (eval "$lt_compile" 2>out/conftest.err)
10921 ac_status=$?
10922 cat out/conftest.err >&5
10923 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10924 if (exit $ac_status) && test -s out/conftest2.$ac_objext
10925 then
10926 # The compiler can only warn and ignore the option if not recognized
10927 # So say no if there are warnings
10928 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
10929 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
10930 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
10931 lt_cv_prog_compiler_c_o=yes
10932 fi
10933 fi
10934 chmod u+w . 2>&5
10935 $RM conftest*
10936 # SGI C++ compiler will create directory out/ii_files/ for
10937 # template instantiation
10938 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
10939 $RM out/* && rmdir out
10940 cd ..
10941 $RM -r conftest
10942 $RM conftest*
10943
10944 fi
10945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
10946 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
10947
10948
10949
10950
10951
10952
10953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
10954 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
10955 if ${lt_cv_prog_compiler_c_o+:} false; then :
10956 $as_echo_n "(cached) " >&6
10957 else
10958 lt_cv_prog_compiler_c_o=no
10959 $RM -r conftest 2>/dev/null
10960 mkdir conftest
10961 cd conftest
10962 mkdir out
10963 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10964
10965 lt_compiler_flag="-o out/conftest2.$ac_objext"
10966 # Insert the option either (1) after the last *FLAGS variable, or
10967 # (2) before a word containing "conftest.", or (3) at the end.
10968 # Note that $ac_compile itself does not contain backslashes and begins
10969 # with a dollar sign (not a hyphen), so the echo should work correctly.
10970 lt_compile=`echo "$ac_compile" | $SED \
10971 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10972 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10973 -e 's:$: $lt_compiler_flag:'`
10974 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10975 (eval "$lt_compile" 2>out/conftest.err)
10976 ac_status=$?
10977 cat out/conftest.err >&5
10978 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10979 if (exit $ac_status) && test -s out/conftest2.$ac_objext
10980 then
10981 # The compiler can only warn and ignore the option if not recognized
10982 # So say no if there are warnings
10983 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
10984 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
10985 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
10986 lt_cv_prog_compiler_c_o=yes
10987 fi
10988 fi
10989 chmod u+w . 2>&5
10990 $RM conftest*
10991 # SGI C++ compiler will create directory out/ii_files/ for
10992 # template instantiation
10993 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
10994 $RM out/* && rmdir out
10995 cd ..
10996 $RM -r conftest
10997 $RM conftest*
10998
10999 fi
11000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11001 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11002
11003
11004
11005
11006 hard_links="nottested"
11007 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
11008 # do not overwrite the value of need_locks provided by the user
11009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
11010 $as_echo_n "checking if we can lock with hard links... " >&6; }
11011 hard_links=yes
11012 $RM conftest*
11013 ln conftest.a conftest.b 2>/dev/null && hard_links=no
11014 touch conftest.a
11015 ln conftest.a conftest.b 2>&5 || hard_links=no
11016 ln conftest.a conftest.b 2>/dev/null && hard_links=no
11017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
11018 $as_echo "$hard_links" >&6; }
11019 if test "$hard_links" = no; then
11020 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
11021 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
11022 need_locks=warn
11023 fi
11024 else
11025 need_locks=no
11026 fi
11027
11028
11029
11030
11031
11032
11033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
11034 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
11035
11036 runpath_var=
11037 allow_undefined_flag=
11038 always_export_symbols=no
11039 archive_cmds=
11040 archive_expsym_cmds=
11041 compiler_needs_object=no
11042 enable_shared_with_static_runtimes=no
11043 export_dynamic_flag_spec=
11044 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
11045 hardcode_automatic=no
11046 hardcode_direct=no
11047 hardcode_direct_absolute=no
11048 hardcode_libdir_flag_spec=
11049 hardcode_libdir_separator=
11050 hardcode_minus_L=no
11051 hardcode_shlibpath_var=unsupported
11052 inherit_rpath=no
11053 link_all_deplibs=unknown
11054 module_cmds=
11055 module_expsym_cmds=
11056 old_archive_from_new_cmds=
11057 old_archive_from_expsyms_cmds=
11058 thread_safe_flag_spec=
11059 whole_archive_flag_spec=
11060 # include_expsyms should be a list of space-separated symbols to be *always*
11061 # included in the symbol list
11062 include_expsyms=
11063 # exclude_expsyms can be an extended regexp of symbols to exclude
11064 # it will be wrapped by ` (' and `)$', so one must not match beginning or
11065 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
11066 # as well as any symbol that contains `d'.
11067 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
11068 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
11069 # platforms (ab)use it in PIC code, but their linkers get confused if
11070 # the symbol is explicitly referenced. Since portable code cannot
11071 # rely on this symbol name, it's probably fine to never include it in
11072 # preloaded symbol tables.
11073 # Exclude shared library initialization/finalization symbols.
11074 extract_expsyms_cmds=
11075
11076 case $host_os in
11077 cygwin* | mingw* | pw32* | cegcc*)
11078 # FIXME: the MSVC++ port hasn't been tested in a loooong time
11079 # When not using gcc, we currently assume that we are using
11080 # Microsoft Visual C++.
11081 if test "$GCC" != yes; then
11082 with_gnu_ld=no
11083 fi
11084 ;;
11085 interix*)
11086 # we just hope/assume this is gcc and not c89 (= MSVC++)
11087 with_gnu_ld=yes
11088 ;;
11089 openbsd*)
11090 with_gnu_ld=no
11091 ;;
11092 linux* | k*bsd*-gnu | gnu*)
11093 link_all_deplibs=no
11094 ;;
11095 esac
11096
11097 ld_shlibs=yes
11098
11099 # On some targets, GNU ld is compatible enough with the native linker
11100 # that we're better off using the native interface for both.
11101 lt_use_gnu_ld_interface=no
11102 if test "$with_gnu_ld" = yes; then
11103 case $host_os in
11104 aix*)
11105 # The AIX port of GNU ld has always aspired to compatibility
11106 # with the native linker. However, as the warning in the GNU ld
11107 # block says, versions before 2.19.5* couldn't really create working
11108 # shared libraries, regardless of the interface used.
11109 case `$LD -v 2>&1` in
11110 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
11111 *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
11112 *\ \(GNU\ Binutils\)\ [3-9]*) ;;
11113 *)
11114 lt_use_gnu_ld_interface=yes
11115 ;;
11116 esac
11117 ;;
11118 *)
11119 lt_use_gnu_ld_interface=yes
11120 ;;
11121 esac
11122 fi
11123
11124 if test "$lt_use_gnu_ld_interface" = yes; then
11125 # If archive_cmds runs LD, not CC, wlarc should be empty
11126 wlarc='${wl}'
11127
11128 # Set some defaults for GNU ld with shared library support. These
11129 # are reset later if shared libraries are not supported. Putting them
11130 # here allows them to be overridden if necessary.
11131 runpath_var=LD_RUN_PATH
11132 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
11133 export_dynamic_flag_spec='${wl}--export-dynamic'
11134 # ancient GNU ld didn't support --whole-archive et. al.
11135 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
11136 whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
11137 else
11138 whole_archive_flag_spec=
11139 fi
11140 supports_anon_versioning=no
11141 case `$LD -v 2>&1` in
11142 *GNU\ gold*) supports_anon_versioning=yes ;;
11143 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
11144 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
11145 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
11146 *\ 2.11.*) ;; # other 2.11 versions
11147 *) supports_anon_versioning=yes ;;
11148 esac
11149
11150 # See if GNU ld supports shared libraries.
11151 case $host_os in
11152 aix[3-9]*)
11153 # On AIX/PPC, the GNU linker is very broken
11154 if test "$host_cpu" != ia64; then
11155 ld_shlibs=no
11156 cat <<_LT_EOF 1>&2
11157
11158 *** Warning: the GNU linker, at least up to release 2.19, is reported
11159 *** to be unable to reliably create shared libraries on AIX.
11160 *** Therefore, libtool is disabling shared libraries support. If you
11161 *** really care for shared libraries, you may want to install binutils
11162 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
11163 *** You will then need to restart the configuration process.
11164
11165 _LT_EOF
11166 fi
11167 ;;
11168
11169 amigaos*)
11170 case $host_cpu in
11171 powerpc)
11172 # see comment about AmigaOS4 .so support
11173 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11174 archive_expsym_cmds=''
11175 ;;
11176 m68k)
11177 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
11178 hardcode_libdir_flag_spec='-L$libdir'
11179 hardcode_minus_L=yes
11180 ;;
11181 esac
11182 ;;
11183
11184 beos*)
11185 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11186 allow_undefined_flag=unsupported
11187 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
11188 # support --undefined. This deserves some investigation. FIXME
11189 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11190 else
11191 ld_shlibs=no
11192 fi
11193 ;;
11194
11195 cygwin* | mingw* | pw32* | cegcc*)
11196 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
11197 # as there is no search path for DLLs.
11198 hardcode_libdir_flag_spec='-L$libdir'
11199 export_dynamic_flag_spec='${wl}--export-all-symbols'
11200 allow_undefined_flag=unsupported
11201 always_export_symbols=no
11202 enable_shared_with_static_runtimes=yes
11203 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
11204 exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11205
11206 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11207 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11208 # If the export-symbols file already is a .def file (1st line
11209 # is EXPORTS), use it as is; otherwise, prepend...
11210 archive_expsym_cmds='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
11211 cp $export_symbols $output_objdir/$soname.def;
11212 else
11213 echo EXPORTS > $output_objdir/$soname.def;
11214 cat $export_symbols >> $output_objdir/$soname.def;
11215 fi~
11216 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11217 else
11218 ld_shlibs=no
11219 fi
11220 ;;
11221
11222 haiku*)
11223 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11224 link_all_deplibs=yes
11225 ;;
11226
11227 interix[3-9]*)
11228 hardcode_direct=no
11229 hardcode_shlibpath_var=no
11230 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
11231 export_dynamic_flag_spec='${wl}-E'
11232 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
11233 # Instead, shared libraries are loaded at an image base (0x10000000 by
11234 # default) and relocated if they conflict, which is a slow very memory
11235 # consuming and fragmenting process. To avoid this, we pick a random,
11236 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
11237 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
11238 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11239 archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11240 ;;
11241
11242 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
11243 tmp_diet=no
11244 if test "$host_os" = linux-dietlibc; then
11245 case $cc_basename in
11246 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
11247 esac
11248 fi
11249 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11250 && test "$tmp_diet" = no
11251 then
11252 tmp_addflag=' $pic_flag'
11253 tmp_sharedflag='-shared'
11254 case $cc_basename,$host_cpu in
11255 pgcc*) # Portland Group C compiler
11256 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
11257 tmp_addflag=' $pic_flag'
11258 ;;
11259 pgf77* | pgf90* | pgf95* | pgfortran*)
11260 # Portland Group f77 and f90 compilers
11261 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
11262 tmp_addflag=' $pic_flag -Mnomain' ;;
11263 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
11264 tmp_addflag=' -i_dynamic' ;;
11265 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
11266 tmp_addflag=' -i_dynamic -nofor_main' ;;
11267 ifc* | ifort*) # Intel Fortran compiler
11268 tmp_addflag=' -nofor_main' ;;
11269 lf95*) # Lahey Fortran 8.1
11270 whole_archive_flag_spec=
11271 tmp_sharedflag='--shared' ;;
11272 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
11273 tmp_sharedflag='-qmkshrobj'
11274 tmp_addflag= ;;
11275 nvcc*) # Cuda Compiler Driver 2.2
11276 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
11277 compiler_needs_object=yes
11278 ;;
11279 esac
11280 case `$CC -V 2>&1 | sed 5q` in
11281 *Sun\ C*) # Sun C 5.9
11282 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
11283 compiler_needs_object=yes
11284 tmp_sharedflag='-G' ;;
11285 *Sun\ F*) # Sun Fortran 8.3
11286 tmp_sharedflag='-G' ;;
11287 esac
11288 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11289
11290 if test "x$supports_anon_versioning" = xyes; then
11291 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11292 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11293 echo "local: *; };" >> $output_objdir/$libname.ver~
11294 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
11295 fi
11296
11297 case $cc_basename in
11298 xlf* | bgf* | bgxlf* | mpixlf*)
11299 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
11300 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11301 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
11302 archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11303 if test "x$supports_anon_versioning" = xyes; then
11304 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11305 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11306 echo "local: *; };" >> $output_objdir/$libname.ver~
11307 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11308 fi
11309 ;;
11310 esac
11311 else
11312 ld_shlibs=no
11313 fi
11314 ;;
11315
11316 netbsd* | netbsdelf*-gnu)
11317 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11318 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11319 wlarc=
11320 else
11321 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11322 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11323 fi
11324 ;;
11325
11326 solaris*)
11327 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
11328 ld_shlibs=no
11329 cat <<_LT_EOF 1>&2
11330
11331 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
11332 *** create shared libraries on Solaris systems. Therefore, libtool
11333 *** is disabling shared libraries support. We urge you to upgrade GNU
11334 *** binutils to release 2.9.1 or newer. Another option is to modify
11335 *** your PATH or compiler configuration so that the native linker is
11336 *** used, and then restart.
11337
11338 _LT_EOF
11339 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11340 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11341 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11342 else
11343 ld_shlibs=no
11344 fi
11345 ;;
11346
11347 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
11348 case `$LD -v 2>&1` in
11349 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
11350 ld_shlibs=no
11351 cat <<_LT_EOF 1>&2
11352
11353 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
11354 *** reliably create shared libraries on SCO systems. Therefore, libtool
11355 *** is disabling shared libraries support. We urge you to upgrade GNU
11356 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
11357 *** your PATH or compiler configuration so that the native linker is
11358 *** used, and then restart.
11359
11360 _LT_EOF
11361 ;;
11362 *)
11363 # For security reasons, it is highly recommended that you always
11364 # use absolute paths for naming shared libraries, and exclude the
11365 # DT_RUNPATH tag from executables and libraries. But doing so
11366 # requires that you compile everything twice, which is a pain.
11367 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11368 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
11369 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11370 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11371 else
11372 ld_shlibs=no
11373 fi
11374 ;;
11375 esac
11376 ;;
11377
11378 sunos4*)
11379 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11380 wlarc=
11381 hardcode_direct=yes
11382 hardcode_shlibpath_var=no
11383 ;;
11384
11385 *)
11386 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11387 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11388 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11389 else
11390 ld_shlibs=no
11391 fi
11392 ;;
11393 esac
11394
11395 if test "$ld_shlibs" = no; then
11396 runpath_var=
11397 hardcode_libdir_flag_spec=
11398 export_dynamic_flag_spec=
11399 whole_archive_flag_spec=
11400 fi
11401 else
11402 # PORTME fill in a description of your system's linker (not GNU ld)
11403 case $host_os in
11404 aix3*)
11405 allow_undefined_flag=unsupported
11406 always_export_symbols=yes
11407 archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
11408 # Note: this linker hardcodes the directories in LIBPATH if there
11409 # are no directories specified by -L.
11410 hardcode_minus_L=yes
11411 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
11412 # Neither direct hardcoding nor static linking is supported with a
11413 # broken collect2.
11414 hardcode_direct=unsupported
11415 fi
11416 ;;
11417
11418 aix[4-9]*)
11419 if test "$host_cpu" = ia64; then
11420 # On IA64, the linker does run time linking by default, so we don't
11421 # have to do anything special.
11422 aix_use_runtimelinking=no
11423 exp_sym_flag='-Bexport'
11424 no_entry_flag=""
11425 else
11426 # If we're using GNU nm, then we don't want the "-C" option.
11427 # -C means demangle to AIX nm, but means don't demangle with GNU nm
11428 # Also, AIX nm treats weak defined symbols like other global
11429 # defined symbols, whereas GNU nm marks them as "W".
11430 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
11431 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
11432 else
11433 export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
11434 fi
11435 aix_use_runtimelinking=no
11436
11437 # Test if we are trying to use run time linking or normal
11438 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
11439 # need to do runtime linking.
11440 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
11441 for ld_flag in $LDFLAGS; do
11442 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
11443 aix_use_runtimelinking=yes
11444 break
11445 fi
11446 done
11447 ;;
11448 esac
11449
11450 exp_sym_flag='-bexport'
11451 no_entry_flag='-bnoentry'
11452 fi
11453
11454 # When large executables or shared objects are built, AIX ld can
11455 # have problems creating the table of contents. If linking a library
11456 # or program results in "error TOC overflow" add -mminimal-toc to
11457 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
11458 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
11459
11460 archive_cmds=''
11461 hardcode_direct=yes
11462 hardcode_direct_absolute=yes
11463 hardcode_libdir_separator=':'
11464 link_all_deplibs=yes
11465 file_list_spec='${wl}-f,'
11466
11467 if test "$GCC" = yes; then
11468 case $host_os in aix4.[012]|aix4.[012].*)
11469 # We only want to do this on AIX 4.2 and lower, the check
11470 # below for broken collect2 doesn't work under 4.3+
11471 collect2name=`${CC} -print-prog-name=collect2`
11472 if test -f "$collect2name" &&
11473 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
11474 then
11475 # We have reworked collect2
11476 :
11477 else
11478 # We have old collect2
11479 hardcode_direct=unsupported
11480 # It fails to find uninstalled libraries when the uninstalled
11481 # path is not listed in the libpath. Setting hardcode_minus_L
11482 # to unsupported forces relinking
11483 hardcode_minus_L=yes
11484 hardcode_libdir_flag_spec='-L$libdir'
11485 hardcode_libdir_separator=
11486 fi
11487 ;;
11488 esac
11489 shared_flag='-shared'
11490 if test "$aix_use_runtimelinking" = yes; then
11491 shared_flag="$shared_flag "'${wl}-G'
11492 fi
11493 link_all_deplibs=no
11494 else
11495 # not using gcc
11496 if test "$host_cpu" = ia64; then
11497 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
11498 # chokes on -Wl,-G. The following line is correct:
11499 shared_flag='-G'
11500 else
11501 if test "$aix_use_runtimelinking" = yes; then
11502 shared_flag='${wl}-G'
11503 else
11504 shared_flag='${wl}-bM:SRE'
11505 fi
11506 fi
11507 fi
11508
11509 export_dynamic_flag_spec='${wl}-bexpall'
11510 # It seems that -bexpall does not export symbols beginning with
11511 # underscore (_), so it is better to generate a list of symbols to export.
11512 always_export_symbols=yes
11513 if test "$aix_use_runtimelinking" = yes; then
11514 # Warning - without using the other runtime loading flags (-brtl),
11515 # -berok will link without error, but may produce a broken library.
11516 allow_undefined_flag='-berok'
11517 # Determine the default libpath from the value encoded in an
11518 # empty executable.
11519 if test "${lt_cv_aix_libpath+set}" = set; then
11520 aix_libpath=$lt_cv_aix_libpath
11521 else
11522 if ${lt_cv_aix_libpath_+:} false; then :
11523 $as_echo_n "(cached) " >&6
11524 else
11525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11526 /* end confdefs.h. */
11527
11528 int
11529 main ()
11530 {
11531
11532 ;
11533 return 0;
11534 }
11535 _ACEOF
11536 if ac_fn_c_try_link "$LINENO"; then :
11537
11538 lt_aix_libpath_sed='
11539 /Import File Strings/,/^$/ {
11540 /^0/ {
11541 s/^0 *\([^ ]*\) *$/\1/
11542 p
11543 }
11544 }'
11545 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11546 # Check for a 64-bit object if we didn't find anything.
11547 if test -z "$lt_cv_aix_libpath_"; then
11548 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11549 fi
11550 fi
11551 rm -f core conftest.err conftest.$ac_objext \
11552 conftest$ac_exeext conftest.$ac_ext
11553 if test -z "$lt_cv_aix_libpath_"; then
11554 lt_cv_aix_libpath_="/usr/lib:/lib"
11555 fi
11556
11557 fi
11558
11559 aix_libpath=$lt_cv_aix_libpath_
11560 fi
11561
11562 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
11563 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
11564 else
11565 if test "$host_cpu" = ia64; then
11566 hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
11567 allow_undefined_flag="-z nodefs"
11568 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
11569 else
11570 # Determine the default libpath from the value encoded in an
11571 # empty executable.
11572 if test "${lt_cv_aix_libpath+set}" = set; then
11573 aix_libpath=$lt_cv_aix_libpath
11574 else
11575 if ${lt_cv_aix_libpath_+:} false; then :
11576 $as_echo_n "(cached) " >&6
11577 else
11578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11579 /* end confdefs.h. */
11580
11581 int
11582 main ()
11583 {
11584
11585 ;
11586 return 0;
11587 }
11588 _ACEOF
11589 if ac_fn_c_try_link "$LINENO"; then :
11590
11591 lt_aix_libpath_sed='
11592 /Import File Strings/,/^$/ {
11593 /^0/ {
11594 s/^0 *\([^ ]*\) *$/\1/
11595 p
11596 }
11597 }'
11598 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11599 # Check for a 64-bit object if we didn't find anything.
11600 if test -z "$lt_cv_aix_libpath_"; then
11601 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11602 fi
11603 fi
11604 rm -f core conftest.err conftest.$ac_objext \
11605 conftest$ac_exeext conftest.$ac_ext
11606 if test -z "$lt_cv_aix_libpath_"; then
11607 lt_cv_aix_libpath_="/usr/lib:/lib"
11608 fi
11609
11610 fi
11611
11612 aix_libpath=$lt_cv_aix_libpath_
11613 fi
11614
11615 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
11616 # Warning - without using the other run time loading flags,
11617 # -berok will link without error, but may produce a broken library.
11618 no_undefined_flag=' ${wl}-bernotok'
11619 allow_undefined_flag=' ${wl}-berok'
11620 if test "$with_gnu_ld" = yes; then
11621 # We only use this code for GNU lds that support --whole-archive.
11622 whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
11623 else
11624 # Exported symbols can be pulled into shared objects from archives
11625 whole_archive_flag_spec='$convenience'
11626 fi
11627 archive_cmds_need_lc=yes
11628 # This is similar to how AIX traditionally builds its shared libraries.
11629 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
11630 fi
11631 fi
11632 ;;
11633
11634 amigaos*)
11635 case $host_cpu in
11636 powerpc)
11637 # see comment about AmigaOS4 .so support
11638 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11639 archive_expsym_cmds=''
11640 ;;
11641 m68k)
11642 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
11643 hardcode_libdir_flag_spec='-L$libdir'
11644 hardcode_minus_L=yes
11645 ;;
11646 esac
11647 ;;
11648
11649 bsdi[45]*)
11650 export_dynamic_flag_spec=-rdynamic
11651 ;;
11652
11653 cygwin* | mingw* | pw32* | cegcc*)
11654 # When not using gcc, we currently assume that we are using
11655 # Microsoft Visual C++.
11656 # hardcode_libdir_flag_spec is actually meaningless, as there is
11657 # no search path for DLLs.
11658 case $cc_basename in
11659 cl*)
11660 # Native MSVC
11661 hardcode_libdir_flag_spec=' '
11662 allow_undefined_flag=unsupported
11663 always_export_symbols=yes
11664 file_list_spec='@'
11665 # Tell ltmain to make .lib files, not .a files.
11666 libext=lib
11667 # Tell ltmain to make .dll files, not .so files.
11668 shrext_cmds=".dll"
11669 # FIXME: Setting linknames here is a bad hack.
11670 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
11671 archive_expsym_cmds='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
11672 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
11673 else
11674 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
11675 fi~
11676 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
11677 linknames='
11678 # The linker will not automatically build a static lib if we build a DLL.
11679 # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
11680 enable_shared_with_static_runtimes=yes
11681 exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
11682 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
11683 # Don't use ranlib
11684 old_postinstall_cmds='chmod 644 $oldlib'
11685 postlink_cmds='lt_outputfile="@OUTPUT@"~
11686 lt_tool_outputfile="@TOOL_OUTPUT@"~
11687 case $lt_outputfile in
11688 *.exe|*.EXE) ;;
11689 *)
11690 lt_outputfile="$lt_outputfile.exe"
11691 lt_tool_outputfile="$lt_tool_outputfile.exe"
11692 ;;
11693 esac~
11694 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
11695 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
11696 $RM "$lt_outputfile.manifest";
11697 fi'
11698 ;;
11699 *)
11700 # Assume MSVC wrapper
11701 hardcode_libdir_flag_spec=' '
11702 allow_undefined_flag=unsupported
11703 # Tell ltmain to make .lib files, not .a files.
11704 libext=lib
11705 # Tell ltmain to make .dll files, not .so files.
11706 shrext_cmds=".dll"
11707 # FIXME: Setting linknames here is a bad hack.
11708 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
11709 # The linker will automatically build a .lib file if we build a DLL.
11710 old_archive_from_new_cmds='true'
11711 # FIXME: Should let the user specify the lib program.
11712 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
11713 enable_shared_with_static_runtimes=yes
11714 ;;
11715 esac
11716 ;;
11717
11718 darwin* | rhapsody*)
11719
11720
11721 archive_cmds_need_lc=no
11722 hardcode_direct=no
11723 hardcode_automatic=yes
11724 hardcode_shlibpath_var=unsupported
11725 if test "$lt_cv_ld_force_load" = "yes"; then
11726 whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
11727
11728 else
11729 whole_archive_flag_spec=''
11730 fi
11731 link_all_deplibs=yes
11732 allow_undefined_flag="$_lt_dar_allow_undefined"
11733 case $cc_basename in
11734 ifort*) _lt_dar_can_shared=yes ;;
11735 *) _lt_dar_can_shared=$GCC ;;
11736 esac
11737 if test "$_lt_dar_can_shared" = "yes"; then
11738 output_verbose_link_cmd=func_echo_all
11739 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
11740 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
11741 archive_expsym_cmds="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}"
11742 module_expsym_cmds="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}"
11743
11744 else
11745 ld_shlibs=no
11746 fi
11747
11748 ;;
11749
11750 dgux*)
11751 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
11752 hardcode_libdir_flag_spec='-L$libdir'
11753 hardcode_shlibpath_var=no
11754 ;;
11755
11756 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
11757 # support. Future versions do this automatically, but an explicit c++rt0.o
11758 # does not break anything, and helps significantly (at the cost of a little
11759 # extra space).
11760 freebsd2.2*)
11761 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
11762 hardcode_libdir_flag_spec='-R$libdir'
11763 hardcode_direct=yes
11764 hardcode_shlibpath_var=no
11765 ;;
11766
11767 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
11768 freebsd2.*)
11769 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11770 hardcode_direct=yes
11771 hardcode_minus_L=yes
11772 hardcode_shlibpath_var=no
11773 ;;
11774
11775 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
11776 freebsd* | dragonfly*)
11777 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
11778 hardcode_libdir_flag_spec='-R$libdir'
11779 hardcode_direct=yes
11780 hardcode_shlibpath_var=no
11781 ;;
11782
11783 hpux9*)
11784 if test "$GCC" = yes; then
11785 archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
11786 else
11787 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
11788 fi
11789 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
11790 hardcode_libdir_separator=:
11791 hardcode_direct=yes
11792
11793 # hardcode_minus_L: Not really in the search PATH,
11794 # but as the default location of the library.
11795 hardcode_minus_L=yes
11796 export_dynamic_flag_spec='${wl}-E'
11797 ;;
11798
11799 hpux10*)
11800 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
11801 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
11802 else
11803 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
11804 fi
11805 if test "$with_gnu_ld" = no; then
11806 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
11807 hardcode_libdir_separator=:
11808 hardcode_direct=yes
11809 hardcode_direct_absolute=yes
11810 export_dynamic_flag_spec='${wl}-E'
11811 # hardcode_minus_L: Not really in the search PATH,
11812 # but as the default location of the library.
11813 hardcode_minus_L=yes
11814 fi
11815 ;;
11816
11817 hpux11*)
11818 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
11819 case $host_cpu in
11820 hppa*64*)
11821 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
11822 ;;
11823 ia64*)
11824 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
11825 ;;
11826 *)
11827 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
11828 ;;
11829 esac
11830 else
11831 case $host_cpu in
11832 hppa*64*)
11833 archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
11834 ;;
11835 ia64*)
11836 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
11837 ;;
11838 *)
11839
11840 # Older versions of the 11.00 compiler do not understand -b yet
11841 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
11842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
11843 $as_echo_n "checking if $CC understands -b... " >&6; }
11844 if ${lt_cv_prog_compiler__b+:} false; then :
11845 $as_echo_n "(cached) " >&6
11846 else
11847 lt_cv_prog_compiler__b=no
11848 save_LDFLAGS="$LDFLAGS"
11849 LDFLAGS="$LDFLAGS -b"
11850 echo "$lt_simple_link_test_code" > conftest.$ac_ext
11851 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
11852 # The linker can only warn and ignore the option if not recognized
11853 # So say no if there are warnings
11854 if test -s conftest.err; then
11855 # Append any errors to the config.log.
11856 cat conftest.err 1>&5
11857 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
11858 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11859 if diff conftest.exp conftest.er2 >/dev/null; then
11860 lt_cv_prog_compiler__b=yes
11861 fi
11862 else
11863 lt_cv_prog_compiler__b=yes
11864 fi
11865 fi
11866 $RM -r conftest*
11867 LDFLAGS="$save_LDFLAGS"
11868
11869 fi
11870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
11871 $as_echo "$lt_cv_prog_compiler__b" >&6; }
11872
11873 if test x"$lt_cv_prog_compiler__b" = xyes; then
11874 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
11875 else
11876 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
11877 fi
11878
11879 ;;
11880 esac
11881 fi
11882 if test "$with_gnu_ld" = no; then
11883 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
11884 hardcode_libdir_separator=:
11885
11886 case $host_cpu in
11887 hppa*64*|ia64*)
11888 hardcode_direct=no
11889 hardcode_shlibpath_var=no
11890 ;;
11891 *)
11892 hardcode_direct=yes
11893 hardcode_direct_absolute=yes
11894 export_dynamic_flag_spec='${wl}-E'
11895
11896 # hardcode_minus_L: Not really in the search PATH,
11897 # but as the default location of the library.
11898 hardcode_minus_L=yes
11899 ;;
11900 esac
11901 fi
11902 ;;
11903
11904 irix5* | irix6* | nonstopux*)
11905 if test "$GCC" = yes; then
11906 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
11907 # Try to use the -exported_symbol ld option, if it does not
11908 # work, assume that -exports_file does not work either and
11909 # implicitly export all symbols.
11910 # This should be the same for all languages, so no per-tag cache variable.
11911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
11912 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
11913 if ${lt_cv_irix_exported_symbol+:} false; then :
11914 $as_echo_n "(cached) " >&6
11915 else
11916 save_LDFLAGS="$LDFLAGS"
11917 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
11918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11919 /* end confdefs.h. */
11920 int foo (void) { return 0; }
11921 _ACEOF
11922 if ac_fn_c_try_link "$LINENO"; then :
11923 lt_cv_irix_exported_symbol=yes
11924 else
11925 lt_cv_irix_exported_symbol=no
11926 fi
11927 rm -f core conftest.err conftest.$ac_objext \
11928 conftest$ac_exeext conftest.$ac_ext
11929 LDFLAGS="$save_LDFLAGS"
11930 fi
11931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
11932 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
11933 if test "$lt_cv_irix_exported_symbol" = yes; then
11934 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
11935 fi
11936 else
11937 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
11938 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
11939 fi
11940 archive_cmds_need_lc='no'
11941 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
11942 hardcode_libdir_separator=:
11943 inherit_rpath=yes
11944 link_all_deplibs=yes
11945 ;;
11946
11947 netbsd* | netbsdelf*-gnu)
11948 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11949 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
11950 else
11951 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
11952 fi
11953 hardcode_libdir_flag_spec='-R$libdir'
11954 hardcode_direct=yes
11955 hardcode_shlibpath_var=no
11956 ;;
11957
11958 newsos6)
11959 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
11960 hardcode_direct=yes
11961 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
11962 hardcode_libdir_separator=:
11963 hardcode_shlibpath_var=no
11964 ;;
11965
11966 *nto* | *qnx*)
11967 ;;
11968
11969 openbsd*)
11970 if test -f /usr/libexec/ld.so; then
11971 hardcode_direct=yes
11972 hardcode_shlibpath_var=no
11973 hardcode_direct_absolute=yes
11974 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
11975 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
11976 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
11977 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
11978 export_dynamic_flag_spec='${wl}-E'
11979 else
11980 case $host_os in
11981 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
11982 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11983 hardcode_libdir_flag_spec='-R$libdir'
11984 ;;
11985 *)
11986 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
11987 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
11988 ;;
11989 esac
11990 fi
11991 else
11992 ld_shlibs=no
11993 fi
11994 ;;
11995
11996 os2*)
11997 hardcode_libdir_flag_spec='-L$libdir'
11998 hardcode_minus_L=yes
11999 allow_undefined_flag=unsupported
12000 archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
12001 old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
12002 ;;
12003
12004 osf3*)
12005 if test "$GCC" = yes; then
12006 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
12007 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12008 else
12009 allow_undefined_flag=' -expect_unresolved \*'
12010 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
12011 fi
12012 archive_cmds_need_lc='no'
12013 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
12014 hardcode_libdir_separator=:
12015 ;;
12016
12017 osf4* | osf5*) # as osf3* with the addition of -msym flag
12018 if test "$GCC" = yes; then
12019 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
12020 archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12021 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
12022 else
12023 allow_undefined_flag=' -expect_unresolved \*'
12024 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
12025 archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
12026 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
12027
12028 # Both c and cxx compiler support -rpath directly
12029 hardcode_libdir_flag_spec='-rpath $libdir'
12030 fi
12031 archive_cmds_need_lc='no'
12032 hardcode_libdir_separator=:
12033 ;;
12034
12035 solaris*)
12036 no_undefined_flag=' -z defs'
12037 if test "$GCC" = yes; then
12038 wlarc='${wl}'
12039 archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
12040 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12041 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12042 else
12043 case `$CC -V 2>&1` in
12044 *"Compilers 5.0"*)
12045 wlarc=''
12046 archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
12047 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12048 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
12049 ;;
12050 *)
12051 wlarc='${wl}'
12052 archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
12053 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12054 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12055 ;;
12056 esac
12057 fi
12058 hardcode_libdir_flag_spec='-R$libdir'
12059 hardcode_shlibpath_var=no
12060 case $host_os in
12061 solaris2.[0-5] | solaris2.[0-5].*) ;;
12062 *)
12063 # The compiler driver will combine and reorder linker options,
12064 # but understands `-z linker_flag'. GCC discards it without `$wl',
12065 # but is careful enough not to reorder.
12066 # Supported since Solaris 2.6 (maybe 2.5.1?)
12067 if test "$GCC" = yes; then
12068 whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
12069 else
12070 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
12071 fi
12072 ;;
12073 esac
12074 link_all_deplibs=yes
12075 ;;
12076
12077 sunos4*)
12078 if test "x$host_vendor" = xsequent; then
12079 # Use $CC to link under sequent, because it throws in some extra .o
12080 # files that make .init and .fini sections work.
12081 archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
12082 else
12083 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
12084 fi
12085 hardcode_libdir_flag_spec='-L$libdir'
12086 hardcode_direct=yes
12087 hardcode_minus_L=yes
12088 hardcode_shlibpath_var=no
12089 ;;
12090
12091 sysv4)
12092 case $host_vendor in
12093 sni)
12094 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12095 hardcode_direct=yes # is this really true???
12096 ;;
12097 siemens)
12098 ## LD is ld it makes a PLAMLIB
12099 ## CC just makes a GrossModule.
12100 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
12101 reload_cmds='$CC -r -o $output$reload_objs'
12102 hardcode_direct=no
12103 ;;
12104 motorola)
12105 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12106 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
12107 ;;
12108 esac
12109 runpath_var='LD_RUN_PATH'
12110 hardcode_shlibpath_var=no
12111 ;;
12112
12113 sysv4.3*)
12114 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12115 hardcode_shlibpath_var=no
12116 export_dynamic_flag_spec='-Bexport'
12117 ;;
12118
12119 sysv4*MP*)
12120 if test -d /usr/nec; then
12121 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12122 hardcode_shlibpath_var=no
12123 runpath_var=LD_RUN_PATH
12124 hardcode_runpath_var=yes
12125 ld_shlibs=yes
12126 fi
12127 ;;
12128
12129 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
12130 no_undefined_flag='${wl}-z,text'
12131 archive_cmds_need_lc=no
12132 hardcode_shlibpath_var=no
12133 runpath_var='LD_RUN_PATH'
12134
12135 if test "$GCC" = yes; then
12136 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12137 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12138 else
12139 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12140 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12141 fi
12142 ;;
12143
12144 sysv5* | sco3.2v5* | sco5v6*)
12145 # Note: We can NOT use -z defs as we might desire, because we do not
12146 # link with -lc, and that would cause any symbols used from libc to
12147 # always be unresolved, which means just about no library would
12148 # ever link correctly. If we're not using GNU ld we use -z text
12149 # though, which does catch some bad symbols but isn't as heavy-handed
12150 # as -z defs.
12151 no_undefined_flag='${wl}-z,text'
12152 allow_undefined_flag='${wl}-z,nodefs'
12153 archive_cmds_need_lc=no
12154 hardcode_shlibpath_var=no
12155 hardcode_libdir_flag_spec='${wl}-R,$libdir'
12156 hardcode_libdir_separator=':'
12157 link_all_deplibs=yes
12158 export_dynamic_flag_spec='${wl}-Bexport'
12159 runpath_var='LD_RUN_PATH'
12160
12161 if test "$GCC" = yes; then
12162 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12163 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12164 else
12165 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12166 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12167 fi
12168 ;;
12169
12170 uts4*)
12171 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12172 hardcode_libdir_flag_spec='-L$libdir'
12173 hardcode_shlibpath_var=no
12174 ;;
12175
12176 *)
12177 ld_shlibs=no
12178 ;;
12179 esac
12180
12181 if test x$host_vendor = xsni; then
12182 case $host in
12183 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
12184 export_dynamic_flag_spec='${wl}-Blargedynsym'
12185 ;;
12186 esac
12187 fi
12188 fi
12189
12190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
12191 $as_echo "$ld_shlibs" >&6; }
12192 test "$ld_shlibs" = no && can_build_shared=no
12193
12194 with_gnu_ld=$with_gnu_ld
12195
12196
12197
12198
12199
12200
12201
12202
12203
12204
12205
12206
12207
12208
12209
12210 #
12211 # Do we need to explicitly link libc?
12212 #
12213 case "x$archive_cmds_need_lc" in
12214 x|xyes)
12215 # Assume -lc should be added
12216 archive_cmds_need_lc=yes
12217
12218 if test "$enable_shared" = yes && test "$GCC" = yes; then
12219 case $archive_cmds in
12220 *'~'*)
12221 # FIXME: we may have to deal with multi-command sequences.
12222 ;;
12223 '$CC '*)
12224 # Test whether the compiler implicitly links with -lc since on some
12225 # systems, -lgcc has to come before -lc. If gcc already passes -lc
12226 # to ld, don't add -lc before -lgcc.
12227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
12228 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
12229 if ${lt_cv_archive_cmds_need_lc+:} false; then :
12230 $as_echo_n "(cached) " >&6
12231 else
12232 $RM conftest*
12233 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12234
12235 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12236 (eval $ac_compile) 2>&5
12237 ac_status=$?
12238 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12239 test $ac_status = 0; } 2>conftest.err; then
12240 soname=conftest
12241 lib=conftest
12242 libobjs=conftest.$ac_objext
12243 deplibs=
12244 wl=$lt_prog_compiler_wl
12245 pic_flag=$lt_prog_compiler_pic
12246 compiler_flags=-v
12247 linker_flags=-v
12248 verstring=
12249 output_objdir=.
12250 libname=conftest
12251 lt_save_allow_undefined_flag=$allow_undefined_flag
12252 allow_undefined_flag=
12253 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
12254 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
12255 ac_status=$?
12256 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12257 test $ac_status = 0; }
12258 then
12259 lt_cv_archive_cmds_need_lc=no
12260 else
12261 lt_cv_archive_cmds_need_lc=yes
12262 fi
12263 allow_undefined_flag=$lt_save_allow_undefined_flag
12264 else
12265 cat conftest.err 1>&5
12266 fi
12267 $RM conftest*
12268
12269 fi
12270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
12271 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
12272 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
12273 ;;
12274 esac
12275 fi
12276 ;;
12277 esac
12278
12279
12280
12281
12282
12283
12284
12285
12286
12287
12288
12289
12290
12291
12292
12293
12294
12295
12296
12297
12298
12299
12300
12301
12302
12303
12304
12305
12306
12307
12308
12309
12310
12311
12312
12313
12314
12315
12316
12317
12318
12319
12320
12321
12322
12323
12324
12325
12326
12327
12328
12329
12330
12331
12332
12333
12334
12335
12336
12337
12338
12339
12340
12341
12342
12343
12344
12345
12346
12347
12348
12349
12350
12351
12352
12353
12354
12355
12356
12357
12358
12359
12360
12361
12362
12363
12364
12365
12366
12367
12368
12369
12370
12371
12372
12373
12374
12375
12376
12377
12378
12379
12380
12381
12382
12383
12384
12385
12386
12387
12388
12389
12390
12391
12392
12393
12394
12395
12396
12397
12398
12399
12400
12401
12402
12403
12404
12405
12406
12407
12408
12409
12410
12411
12412
12413
12414
12415
12416
12417
12418
12419
12420
12421
12422
12423
12424
12425
12426
12427
12428
12429
12430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
12431 $as_echo_n "checking dynamic linker characteristics... " >&6; }
12432
12433 if test "$GCC" = yes; then
12434 case $host_os in
12435 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
12436 *) lt_awk_arg="/^libraries:/" ;;
12437 esac
12438 case $host_os in
12439 mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
12440 *) lt_sed_strip_eq="s,=/,/,g" ;;
12441 esac
12442 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
12443 case $lt_search_path_spec in
12444 *\;*)
12445 # if the path contains ";" then we assume it to be the separator
12446 # otherwise default to the standard path separator (i.e. ":") - it is
12447 # assumed that no part of a normal pathname contains ";" but that should
12448 # okay in the real world where ";" in dirpaths is itself problematic.
12449 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
12450 ;;
12451 *)
12452 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
12453 ;;
12454 esac
12455 # Ok, now we have the path, separated by spaces, we can step through it
12456 # and add multilib dir if necessary.
12457 lt_tmp_lt_search_path_spec=
12458 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
12459 for lt_sys_path in $lt_search_path_spec; do
12460 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
12461 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
12462 else
12463 test -d "$lt_sys_path" && \
12464 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
12465 fi
12466 done
12467 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
12468 BEGIN {RS=" "; FS="/|\n";} {
12469 lt_foo="";
12470 lt_count=0;
12471 for (lt_i = NF; lt_i > 0; lt_i--) {
12472 if ($lt_i != "" && $lt_i != ".") {
12473 if ($lt_i == "..") {
12474 lt_count++;
12475 } else {
12476 if (lt_count == 0) {
12477 lt_foo="/" $lt_i lt_foo;
12478 } else {
12479 lt_count--;
12480 }
12481 }
12482 }
12483 }
12484 if (lt_foo != "") { lt_freq[lt_foo]++; }
12485 if (lt_freq[lt_foo] == 1) { print lt_foo; }
12486 }'`
12487 # AWK program above erroneously prepends '/' to C:/dos/paths
12488 # for these hosts.
12489 case $host_os in
12490 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
12491 $SED 's,/\([A-Za-z]:\),\1,g'` ;;
12492 esac
12493 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
12494 else
12495 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
12496 fi
12497 library_names_spec=
12498 libname_spec='lib$name'
12499 soname_spec=
12500 shrext_cmds=".so"
12501 postinstall_cmds=
12502 postuninstall_cmds=
12503 finish_cmds=
12504 finish_eval=
12505 shlibpath_var=
12506 shlibpath_overrides_runpath=unknown
12507 version_type=none
12508 dynamic_linker="$host_os ld.so"
12509 sys_lib_dlsearch_path_spec="/lib /usr/lib"
12510 need_lib_prefix=unknown
12511 hardcode_into_libs=no
12512
12513 # when you set need_version to no, make sure it does not cause -set_version
12514 # flags to be left without arguments
12515 need_version=unknown
12516
12517 case $host_os in
12518 aix3*)
12519 version_type=linux # correct to gnu/linux during the next big refactor
12520 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
12521 shlibpath_var=LIBPATH
12522
12523 # AIX 3 has no versioning support, so we append a major version to the name.
12524 soname_spec='${libname}${release}${shared_ext}$major'
12525 ;;
12526
12527 aix[4-9]*)
12528 version_type=linux # correct to gnu/linux during the next big refactor
12529 need_lib_prefix=no
12530 need_version=no
12531 hardcode_into_libs=yes
12532 if test "$host_cpu" = ia64; then
12533 # AIX 5 supports IA64
12534 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
12535 shlibpath_var=LD_LIBRARY_PATH
12536 else
12537 # With GCC up to 2.95.x, collect2 would create an import file
12538 # for dependence libraries. The import file would start with
12539 # the line `#! .'. This would cause the generated library to
12540 # depend on `.', always an invalid library. This was fixed in
12541 # development snapshots of GCC prior to 3.0.
12542 case $host_os in
12543 aix4 | aix4.[01] | aix4.[01].*)
12544 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
12545 echo ' yes '
12546 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
12547 :
12548 else
12549 can_build_shared=no
12550 fi
12551 ;;
12552 esac
12553 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
12554 # soname into executable. Probably we can add versioning support to
12555 # collect2, so additional links can be useful in future.
12556 if test "$aix_use_runtimelinking" = yes; then
12557 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
12558 # instead of lib<name>.a to let people know that these are not
12559 # typical AIX shared libraries.
12560 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12561 else
12562 # We preserve .a as extension for shared libraries through AIX4.2
12563 # and later when we are not doing run time linking.
12564 library_names_spec='${libname}${release}.a $libname.a'
12565 soname_spec='${libname}${release}${shared_ext}$major'
12566 fi
12567 shlibpath_var=LIBPATH
12568 fi
12569 ;;
12570
12571 amigaos*)
12572 case $host_cpu in
12573 powerpc)
12574 # Since July 2007 AmigaOS4 officially supports .so libraries.
12575 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
12576 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12577 ;;
12578 m68k)
12579 library_names_spec='$libname.ixlibrary $libname.a'
12580 # Create ${libname}_ixlibrary.a entries in /sys/libs.
12581 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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'
12582 ;;
12583 esac
12584 ;;
12585
12586 beos*)
12587 library_names_spec='${libname}${shared_ext}'
12588 dynamic_linker="$host_os ld.so"
12589 shlibpath_var=LIBRARY_PATH
12590 ;;
12591
12592 bsdi[45]*)
12593 version_type=linux # correct to gnu/linux during the next big refactor
12594 need_version=no
12595 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12596 soname_spec='${libname}${release}${shared_ext}$major'
12597 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
12598 shlibpath_var=LD_LIBRARY_PATH
12599 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
12600 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
12601 # the default ld.so.conf also contains /usr/contrib/lib and
12602 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
12603 # libtool to hard-code these into programs
12604 ;;
12605
12606 cygwin* | mingw* | pw32* | cegcc*)
12607 version_type=windows
12608 shrext_cmds=".dll"
12609 need_version=no
12610 need_lib_prefix=no
12611
12612 case $GCC,$cc_basename in
12613 yes,*)
12614 # gcc
12615 library_names_spec='$libname.dll.a'
12616 # DLL is installed to $(libdir)/../bin by postinstall_cmds
12617 postinstall_cmds='base_file=`basename \${file}`~
12618 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
12619 dldir=$destdir/`dirname \$dlpath`~
12620 test -d \$dldir || mkdir -p \$dldir~
12621 $install_prog $dir/$dlname \$dldir/$dlname~
12622 chmod a+x \$dldir/$dlname~
12623 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
12624 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
12625 fi'
12626 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
12627 dlpath=$dir/\$dldll~
12628 $RM \$dlpath'
12629 shlibpath_overrides_runpath=yes
12630
12631 case $host_os in
12632 cygwin*)
12633 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
12634 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
12635
12636 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
12637 ;;
12638 mingw* | cegcc*)
12639 # MinGW DLLs use traditional 'lib' prefix
12640 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
12641 ;;
12642 pw32*)
12643 # pw32 DLLs use 'pw' prefix rather than 'lib'
12644 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
12645 ;;
12646 esac
12647 dynamic_linker='Win32 ld.exe'
12648 ;;
12649
12650 *,cl*)
12651 # Native MSVC
12652 libname_spec='$name'
12653 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
12654 library_names_spec='${libname}.dll.lib'
12655
12656 case $build_os in
12657 mingw*)
12658 sys_lib_search_path_spec=
12659 lt_save_ifs=$IFS
12660 IFS=';'
12661 for lt_path in $LIB
12662 do
12663 IFS=$lt_save_ifs
12664 # Let DOS variable expansion print the short 8.3 style file name.
12665 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
12666 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
12667 done
12668 IFS=$lt_save_ifs
12669 # Convert to MSYS style.
12670 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
12671 ;;
12672 cygwin*)
12673 # Convert to unix form, then to dos form, then back to unix form
12674 # but this time dos style (no spaces!) so that the unix form looks
12675 # like /cygdrive/c/PROGRA~1:/cygdr...
12676 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
12677 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
12678 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
12679 ;;
12680 *)
12681 sys_lib_search_path_spec="$LIB"
12682 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
12683 # It is most probably a Windows format PATH.
12684 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
12685 else
12686 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
12687 fi
12688 # FIXME: find the short name or the path components, as spaces are
12689 # common. (e.g. "Program Files" -> "PROGRA~1")
12690 ;;
12691 esac
12692
12693 # DLL is installed to $(libdir)/../bin by postinstall_cmds
12694 postinstall_cmds='base_file=`basename \${file}`~
12695 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
12696 dldir=$destdir/`dirname \$dlpath`~
12697 test -d \$dldir || mkdir -p \$dldir~
12698 $install_prog $dir/$dlname \$dldir/$dlname'
12699 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
12700 dlpath=$dir/\$dldll~
12701 $RM \$dlpath'
12702 shlibpath_overrides_runpath=yes
12703 dynamic_linker='Win32 link.exe'
12704 ;;
12705
12706 *)
12707 # Assume MSVC wrapper
12708 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
12709 dynamic_linker='Win32 ld.exe'
12710 ;;
12711 esac
12712 # FIXME: first we should search . and the directory the executable is in
12713 shlibpath_var=PATH
12714 ;;
12715
12716 darwin* | rhapsody*)
12717 dynamic_linker="$host_os dyld"
12718 version_type=darwin
12719 need_lib_prefix=no
12720 need_version=no
12721 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
12722 soname_spec='${libname}${release}${major}$shared_ext'
12723 shlibpath_overrides_runpath=yes
12724 shlibpath_var=DYLD_LIBRARY_PATH
12725 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
12726
12727 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
12728 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
12729 ;;
12730
12731 dgux*)
12732 version_type=linux # correct to gnu/linux during the next big refactor
12733 need_lib_prefix=no
12734 need_version=no
12735 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
12736 soname_spec='${libname}${release}${shared_ext}$major'
12737 shlibpath_var=LD_LIBRARY_PATH
12738 ;;
12739
12740 freebsd* | dragonfly*)
12741 # DragonFly does not have aout. When/if they implement a new
12742 # versioning mechanism, adjust this.
12743 if test -x /usr/bin/objformat; then
12744 objformat=`/usr/bin/objformat`
12745 else
12746 case $host_os in
12747 freebsd[23].*) objformat=aout ;;
12748 *) objformat=elf ;;
12749 esac
12750 fi
12751 version_type=freebsd-$objformat
12752 case $version_type in
12753 freebsd-elf*)
12754 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
12755 need_version=no
12756 need_lib_prefix=no
12757 ;;
12758 freebsd-*)
12759 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
12760 need_version=yes
12761 ;;
12762 esac
12763 shlibpath_var=LD_LIBRARY_PATH
12764 case $host_os in
12765 freebsd2.*)
12766 shlibpath_overrides_runpath=yes
12767 ;;
12768 freebsd3.[01]* | freebsdelf3.[01]*)
12769 shlibpath_overrides_runpath=yes
12770 hardcode_into_libs=yes
12771 ;;
12772 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
12773 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
12774 shlibpath_overrides_runpath=no
12775 hardcode_into_libs=yes
12776 ;;
12777 *) # from 4.6 on, and DragonFly
12778 shlibpath_overrides_runpath=yes
12779 hardcode_into_libs=yes
12780 ;;
12781 esac
12782 ;;
12783
12784 gnu*)
12785 version_type=linux # correct to gnu/linux during the next big refactor
12786 need_lib_prefix=no
12787 need_version=no
12788 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
12789 soname_spec='${libname}${release}${shared_ext}$major'
12790 shlibpath_var=LD_LIBRARY_PATH
12791 shlibpath_overrides_runpath=no
12792 hardcode_into_libs=yes
12793 ;;
12794
12795 haiku*)
12796 version_type=linux # correct to gnu/linux during the next big refactor
12797 need_lib_prefix=no
12798 need_version=no
12799 dynamic_linker="$host_os runtime_loader"
12800 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
12801 soname_spec='${libname}${release}${shared_ext}$major'
12802 shlibpath_var=LIBRARY_PATH
12803 shlibpath_overrides_runpath=yes
12804 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
12805 hardcode_into_libs=yes
12806 ;;
12807
12808 hpux9* | hpux10* | hpux11*)
12809 # Give a soname corresponding to the major version so that dld.sl refuses to
12810 # link against other versions.
12811 version_type=sunos
12812 need_lib_prefix=no
12813 need_version=no
12814 case $host_cpu in
12815 ia64*)
12816 shrext_cmds='.so'
12817 hardcode_into_libs=yes
12818 dynamic_linker="$host_os dld.so"
12819 shlibpath_var=LD_LIBRARY_PATH
12820 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
12821 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12822 soname_spec='${libname}${release}${shared_ext}$major'
12823 if test "X$HPUX_IA64_MODE" = X32; then
12824 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
12825 else
12826 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
12827 fi
12828 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
12829 ;;
12830 hppa*64*)
12831 shrext_cmds='.sl'
12832 hardcode_into_libs=yes
12833 dynamic_linker="$host_os dld.sl"
12834 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
12835 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
12836 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12837 soname_spec='${libname}${release}${shared_ext}$major'
12838 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
12839 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
12840 ;;
12841 *)
12842 shrext_cmds='.sl'
12843 dynamic_linker="$host_os dld.sl"
12844 shlibpath_var=SHLIB_PATH
12845 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
12846 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12847 soname_spec='${libname}${release}${shared_ext}$major'
12848 ;;
12849 esac
12850 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
12851 postinstall_cmds='chmod 555 $lib'
12852 # or fails outright, so override atomically:
12853 install_override_mode=555
12854 ;;
12855
12856 interix[3-9]*)
12857 version_type=linux # correct to gnu/linux during the next big refactor
12858 need_lib_prefix=no
12859 need_version=no
12860 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
12861 soname_spec='${libname}${release}${shared_ext}$major'
12862 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
12863 shlibpath_var=LD_LIBRARY_PATH
12864 shlibpath_overrides_runpath=no
12865 hardcode_into_libs=yes
12866 ;;
12867
12868 irix5* | irix6* | nonstopux*)
12869 case $host_os in
12870 nonstopux*) version_type=nonstopux ;;
12871 *)
12872 if test "$lt_cv_prog_gnu_ld" = yes; then
12873 version_type=linux # correct to gnu/linux during the next big refactor
12874 else
12875 version_type=irix
12876 fi ;;
12877 esac
12878 need_lib_prefix=no
12879 need_version=no
12880 soname_spec='${libname}${release}${shared_ext}$major'
12881 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
12882 case $host_os in
12883 irix5* | nonstopux*)
12884 libsuff= shlibsuff=
12885 ;;
12886 *)
12887 case $LD in # libtool.m4 will add one of these switches to LD
12888 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
12889 libsuff= shlibsuff= libmagic=32-bit;;
12890 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
12891 libsuff=32 shlibsuff=N32 libmagic=N32;;
12892 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
12893 libsuff=64 shlibsuff=64 libmagic=64-bit;;
12894 *) libsuff= shlibsuff= libmagic=never-match;;
12895 esac
12896 ;;
12897 esac
12898 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
12899 shlibpath_overrides_runpath=no
12900 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
12901 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
12902 hardcode_into_libs=yes
12903 ;;
12904
12905 # No shared lib support for Linux oldld, aout, or coff.
12906 linux*oldld* | linux*aout* | linux*coff*)
12907 dynamic_linker=no
12908 ;;
12909
12910 linux*android*)
12911 version_type=none # Android doesn't support versioned libraries.
12912 need_lib_prefix=no
12913 need_version=no
12914 library_names_spec='$libname$release$shared_ext'
12915 soname_spec='$libname$release$shared_ext'
12916 finish_cmds=
12917 shlibpath_var=LD_LIBRARY_PATH
12918 shlibpath_overrides_runpath=yes
12919
12920 # This implies no fast_install, which is unacceptable.
12921 # Some rework will be needed to allow for fast_install
12922 # before this can be enabled.
12923 hardcode_into_libs=yes
12924
12925 dynamic_linker='Android linker'
12926 # Don't embed -rpath directories since the linker doesn't support them.
12927 hardcode_libdir_flag_spec='-L$libdir'
12928 ;;
12929
12930 # This must be glibc/ELF.
12931 linux* | k*bsd*-gnu | kopensolaris*-gnu)
12932 version_type=linux # correct to gnu/linux during the next big refactor
12933 need_lib_prefix=no
12934 need_version=no
12935 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
12936 soname_spec='${libname}${release}${shared_ext}$major'
12937 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
12938 shlibpath_var=LD_LIBRARY_PATH
12939 shlibpath_overrides_runpath=no
12940
12941 # Some binutils ld are patched to set DT_RUNPATH
12942 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
12943 $as_echo_n "(cached) " >&6
12944 else
12945 lt_cv_shlibpath_overrides_runpath=no
12946 save_LDFLAGS=$LDFLAGS
12947 save_libdir=$libdir
12948 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
12949 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
12950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12951 /* end confdefs.h. */
12952
12953 int
12954 main ()
12955 {
12956
12957 ;
12958 return 0;
12959 }
12960 _ACEOF
12961 if ac_fn_c_try_link "$LINENO"; then :
12962 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
12963 lt_cv_shlibpath_overrides_runpath=yes
12964 fi
12965 fi
12966 rm -f core conftest.err conftest.$ac_objext \
12967 conftest$ac_exeext conftest.$ac_ext
12968 LDFLAGS=$save_LDFLAGS
12969 libdir=$save_libdir
12970
12971 fi
12972
12973 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
12974
12975 # This implies no fast_install, which is unacceptable.
12976 # Some rework will be needed to allow for fast_install
12977 # before this can be enabled.
12978 hardcode_into_libs=yes
12979
12980 # Append ld.so.conf contents to the search path
12981 if test -f /etc/ld.so.conf; then
12982 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;s/"//g;/^$/d' | tr '\n' ' '`
12983 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
12984 fi
12985
12986 # We used to test for /lib/ld.so.1 and disable shared libraries on
12987 # powerpc, because MkLinux only supported shared libraries with the
12988 # GNU dynamic linker. Since this was broken with cross compilers,
12989 # most powerpc-linux boxes support dynamic linking these days and
12990 # people can always --disable-shared, the test was removed, and we
12991 # assume the GNU/Linux dynamic linker is in use.
12992 dynamic_linker='GNU/Linux ld.so'
12993 ;;
12994
12995 netbsdelf*-gnu)
12996 version_type=linux
12997 need_lib_prefix=no
12998 need_version=no
12999 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
13000 soname_spec='${libname}${release}${shared_ext}$major'
13001 shlibpath_var=LD_LIBRARY_PATH
13002 shlibpath_overrides_runpath=no
13003 hardcode_into_libs=yes
13004 dynamic_linker='NetBSD ld.elf_so'
13005 ;;
13006
13007 netbsd*)
13008 version_type=sunos
13009 need_lib_prefix=no
13010 need_version=no
13011 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13012 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
13013 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13014 dynamic_linker='NetBSD (a.out) ld.so'
13015 else
13016 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
13017 soname_spec='${libname}${release}${shared_ext}$major'
13018 dynamic_linker='NetBSD ld.elf_so'
13019 fi
13020 shlibpath_var=LD_LIBRARY_PATH
13021 shlibpath_overrides_runpath=yes
13022 hardcode_into_libs=yes
13023 ;;
13024
13025 newsos6)
13026 version_type=linux # correct to gnu/linux during the next big refactor
13027 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13028 shlibpath_var=LD_LIBRARY_PATH
13029 shlibpath_overrides_runpath=yes
13030 ;;
13031
13032 *nto* | *qnx*)
13033 version_type=qnx
13034 need_lib_prefix=no
13035 need_version=no
13036 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13037 soname_spec='${libname}${release}${shared_ext}$major'
13038 shlibpath_var=LD_LIBRARY_PATH
13039 shlibpath_overrides_runpath=no
13040 hardcode_into_libs=yes
13041 dynamic_linker='ldqnx.so'
13042 ;;
13043
13044 openbsd*)
13045 version_type=sunos
13046 sys_lib_dlsearch_path_spec="/usr/lib"
13047 need_lib_prefix=no
13048 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
13049 case $host_os in
13050 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
13051 *) need_version=no ;;
13052 esac
13053 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
13054 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13055 shlibpath_var=LD_LIBRARY_PATH
13056 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
13057 case $host_os in
13058 openbsd2.[89] | openbsd2.[89].*)
13059 shlibpath_overrides_runpath=no
13060 ;;
13061 *)
13062 shlibpath_overrides_runpath=yes
13063 ;;
13064 esac
13065 else
13066 shlibpath_overrides_runpath=yes
13067 fi
13068 ;;
13069
13070 os2*)
13071 libname_spec='$name'
13072 shrext_cmds=".dll"
13073 need_lib_prefix=no
13074 library_names_spec='$libname${shared_ext} $libname.a'
13075 dynamic_linker='OS/2 ld.exe'
13076 shlibpath_var=LIBPATH
13077 ;;
13078
13079 osf3* | osf4* | osf5*)
13080 version_type=osf
13081 need_lib_prefix=no
13082 need_version=no
13083 soname_spec='${libname}${release}${shared_ext}$major'
13084 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13085 shlibpath_var=LD_LIBRARY_PATH
13086 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
13087 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
13088 ;;
13089
13090 rdos*)
13091 dynamic_linker=no
13092 ;;
13093
13094 solaris*)
13095 version_type=linux # correct to gnu/linux during the next big refactor
13096 need_lib_prefix=no
13097 need_version=no
13098 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13099 soname_spec='${libname}${release}${shared_ext}$major'
13100 shlibpath_var=LD_LIBRARY_PATH
13101 shlibpath_overrides_runpath=yes
13102 hardcode_into_libs=yes
13103 # ldd complains unless libraries are executable
13104 postinstall_cmds='chmod +x $lib'
13105 ;;
13106
13107 sunos4*)
13108 version_type=sunos
13109 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
13110 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
13111 shlibpath_var=LD_LIBRARY_PATH
13112 shlibpath_overrides_runpath=yes
13113 if test "$with_gnu_ld" = yes; then
13114 need_lib_prefix=no
13115 fi
13116 need_version=yes
13117 ;;
13118
13119 sysv4 | sysv4.3*)
13120 version_type=linux # correct to gnu/linux during the next big refactor
13121 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13122 soname_spec='${libname}${release}${shared_ext}$major'
13123 shlibpath_var=LD_LIBRARY_PATH
13124 case $host_vendor in
13125 sni)
13126 shlibpath_overrides_runpath=no
13127 need_lib_prefix=no
13128 runpath_var=LD_RUN_PATH
13129 ;;
13130 siemens)
13131 need_lib_prefix=no
13132 ;;
13133 motorola)
13134 need_lib_prefix=no
13135 need_version=no
13136 shlibpath_overrides_runpath=no
13137 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
13138 ;;
13139 esac
13140 ;;
13141
13142 sysv4*MP*)
13143 if test -d /usr/nec ;then
13144 version_type=linux # correct to gnu/linux during the next big refactor
13145 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
13146 soname_spec='$libname${shared_ext}.$major'
13147 shlibpath_var=LD_LIBRARY_PATH
13148 fi
13149 ;;
13150
13151 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
13152 version_type=freebsd-elf
13153 need_lib_prefix=no
13154 need_version=no
13155 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
13156 soname_spec='${libname}${release}${shared_ext}$major'
13157 shlibpath_var=LD_LIBRARY_PATH
13158 shlibpath_overrides_runpath=yes
13159 hardcode_into_libs=yes
13160 if test "$with_gnu_ld" = yes; then
13161 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
13162 else
13163 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
13164 case $host_os in
13165 sco3.2v5*)
13166 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
13167 ;;
13168 esac
13169 fi
13170 sys_lib_dlsearch_path_spec='/usr/lib'
13171 ;;
13172
13173 tpf*)
13174 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
13175 version_type=linux # correct to gnu/linux during the next big refactor
13176 need_lib_prefix=no
13177 need_version=no
13178 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13179 shlibpath_var=LD_LIBRARY_PATH
13180 shlibpath_overrides_runpath=no
13181 hardcode_into_libs=yes
13182 ;;
13183
13184 uts4*)
13185 version_type=linux # correct to gnu/linux during the next big refactor
13186 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
13187 soname_spec='${libname}${release}${shared_ext}$major'
13188 shlibpath_var=LD_LIBRARY_PATH
13189 ;;
13190
13191 *)
13192 dynamic_linker=no
13193 ;;
13194 esac
13195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
13196 $as_echo "$dynamic_linker" >&6; }
13197 test "$dynamic_linker" = no && can_build_shared=no
13198
13199 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
13200 if test "$GCC" = yes; then
13201 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
13202 fi
13203
13204 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
13205 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
13206 fi
13207 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
13208 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
13209 fi
13210
13211
13212
13213
13214
13215
13216
13217
13218
13219
13220
13221
13222
13223
13224
13225
13226
13227
13228
13229
13230
13231
13232
13233
13234
13235
13236
13237
13238
13239
13240
13241
13242
13243
13244
13245
13246
13247
13248
13249
13250
13251
13252
13253
13254
13255
13256
13257
13258
13259
13260
13261
13262
13263
13264
13265
13266
13267
13268
13269
13270
13271
13272
13273
13274
13275
13276
13277
13278
13279
13280
13281
13282
13283
13284
13285
13286
13287
13288
13289
13290
13291
13292
13293
13294
13295
13296
13297
13298
13299
13300
13301
13302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
13303 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
13304 hardcode_action=
13305 if test -n "$hardcode_libdir_flag_spec" ||
13306 test -n "$runpath_var" ||
13307 test "X$hardcode_automatic" = "Xyes" ; then
13308
13309 # We can hardcode non-existent directories.
13310 if test "$hardcode_direct" != no &&
13311 # If the only mechanism to avoid hardcoding is shlibpath_var, we
13312 # have to relink, otherwise we might link with an installed library
13313 # when we should be linking with a yet-to-be-installed one
13314 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
13315 test "$hardcode_minus_L" != no; then
13316 # Linking always hardcodes the temporary library directory.
13317 hardcode_action=relink
13318 else
13319 # We can link without hardcoding, and we can hardcode nonexisting dirs.
13320 hardcode_action=immediate
13321 fi
13322 else
13323 # We cannot hardcode anything, or else we can only hardcode existing
13324 # directories.
13325 hardcode_action=unsupported
13326 fi
13327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
13328 $as_echo "$hardcode_action" >&6; }
13329
13330 if test "$hardcode_action" = relink ||
13331 test "$inherit_rpath" = yes; then
13332 # Fast installation is not supported
13333 enable_fast_install=no
13334 elif test "$shlibpath_overrides_runpath" = yes ||
13335 test "$enable_shared" = no; then
13336 # Fast installation is not necessary
13337 enable_fast_install=needless
13338 fi
13339
13340
13341
13342
13343
13344
13345 if test "x$enable_dlopen" != xyes; then
13346 enable_dlopen=unknown
13347 enable_dlopen_self=unknown
13348 enable_dlopen_self_static=unknown
13349 else
13350 lt_cv_dlopen=no
13351 lt_cv_dlopen_libs=
13352
13353 case $host_os in
13354 beos*)
13355 lt_cv_dlopen="load_add_on"
13356 lt_cv_dlopen_libs=
13357 lt_cv_dlopen_self=yes
13358 ;;
13359
13360 mingw* | pw32* | cegcc*)
13361 lt_cv_dlopen="LoadLibrary"
13362 lt_cv_dlopen_libs=
13363 ;;
13364
13365 cygwin*)
13366 lt_cv_dlopen="dlopen"
13367 lt_cv_dlopen_libs=
13368 ;;
13369
13370 darwin*)
13371 # if libdl is installed we need to link against it
13372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13373 $as_echo_n "checking for dlopen in -ldl... " >&6; }
13374 if ${ac_cv_lib_dl_dlopen+:} false; then :
13375 $as_echo_n "(cached) " >&6
13376 else
13377 ac_check_lib_save_LIBS=$LIBS
13378 LIBS="-ldl $LIBS"
13379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13380 /* end confdefs.h. */
13381
13382 /* Override any GCC internal prototype to avoid an error.
13383 Use char because int might match the return type of a GCC
13384 builtin and then its argument prototype would still apply. */
13385 #ifdef __cplusplus
13386 extern "C"
13387 #endif
13388 char dlopen ();
13389 int
13390 main ()
13391 {
13392 return dlopen ();
13393 ;
13394 return 0;
13395 }
13396 _ACEOF
13397 if ac_fn_c_try_link "$LINENO"; then :
13398 ac_cv_lib_dl_dlopen=yes
13399 else
13400 ac_cv_lib_dl_dlopen=no
13401 fi
13402 rm -f core conftest.err conftest.$ac_objext \
13403 conftest$ac_exeext conftest.$ac_ext
13404 LIBS=$ac_check_lib_save_LIBS
13405 fi
13406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
13407 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
13408 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
13409 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
13410 else
13411
13412 lt_cv_dlopen="dyld"
13413 lt_cv_dlopen_libs=
13414 lt_cv_dlopen_self=yes
13415
13416 fi
13417
13418 ;;
13419
13420 *)
13421 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
13422 if test "x$ac_cv_func_shl_load" = xyes; then :
13423 lt_cv_dlopen="shl_load"
13424 else
13425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
13426 $as_echo_n "checking for shl_load in -ldld... " >&6; }
13427 if ${ac_cv_lib_dld_shl_load+:} false; then :
13428 $as_echo_n "(cached) " >&6
13429 else
13430 ac_check_lib_save_LIBS=$LIBS
13431 LIBS="-ldld $LIBS"
13432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13433 /* end confdefs.h. */
13434
13435 /* Override any GCC internal prototype to avoid an error.
13436 Use char because int might match the return type of a GCC
13437 builtin and then its argument prototype would still apply. */
13438 #ifdef __cplusplus
13439 extern "C"
13440 #endif
13441 char shl_load ();
13442 int
13443 main ()
13444 {
13445 return shl_load ();
13446 ;
13447 return 0;
13448 }
13449 _ACEOF
13450 if ac_fn_c_try_link "$LINENO"; then :
13451 ac_cv_lib_dld_shl_load=yes
13452 else
13453 ac_cv_lib_dld_shl_load=no
13454 fi
13455 rm -f core conftest.err conftest.$ac_objext \
13456 conftest$ac_exeext conftest.$ac_ext
13457 LIBS=$ac_check_lib_save_LIBS
13458 fi
13459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
13460 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
13461 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
13462 lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
13463 else
13464 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
13465 if test "x$ac_cv_func_dlopen" = xyes; then :
13466 lt_cv_dlopen="dlopen"
13467 else
13468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13469 $as_echo_n "checking for dlopen in -ldl... " >&6; }
13470 if ${ac_cv_lib_dl_dlopen+:} false; then :
13471 $as_echo_n "(cached) " >&6
13472 else
13473 ac_check_lib_save_LIBS=$LIBS
13474 LIBS="-ldl $LIBS"
13475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13476 /* end confdefs.h. */
13477
13478 /* Override any GCC internal prototype to avoid an error.
13479 Use char because int might match the return type of a GCC
13480 builtin and then its argument prototype would still apply. */
13481 #ifdef __cplusplus
13482 extern "C"
13483 #endif
13484 char dlopen ();
13485 int
13486 main ()
13487 {
13488 return dlopen ();
13489 ;
13490 return 0;
13491 }
13492 _ACEOF
13493 if ac_fn_c_try_link "$LINENO"; then :
13494 ac_cv_lib_dl_dlopen=yes
13495 else
13496 ac_cv_lib_dl_dlopen=no
13497 fi
13498 rm -f core conftest.err conftest.$ac_objext \
13499 conftest$ac_exeext conftest.$ac_ext
13500 LIBS=$ac_check_lib_save_LIBS
13501 fi
13502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
13503 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
13504 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
13505 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
13506 else
13507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
13508 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
13509 if ${ac_cv_lib_svld_dlopen+:} false; then :
13510 $as_echo_n "(cached) " >&6
13511 else
13512 ac_check_lib_save_LIBS=$LIBS
13513 LIBS="-lsvld $LIBS"
13514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13515 /* end confdefs.h. */
13516
13517 /* Override any GCC internal prototype to avoid an error.
13518 Use char because int might match the return type of a GCC
13519 builtin and then its argument prototype would still apply. */
13520 #ifdef __cplusplus
13521 extern "C"
13522 #endif
13523 char dlopen ();
13524 int
13525 main ()
13526 {
13527 return dlopen ();
13528 ;
13529 return 0;
13530 }
13531 _ACEOF
13532 if ac_fn_c_try_link "$LINENO"; then :
13533 ac_cv_lib_svld_dlopen=yes
13534 else
13535 ac_cv_lib_svld_dlopen=no
13536 fi
13537 rm -f core conftest.err conftest.$ac_objext \
13538 conftest$ac_exeext conftest.$ac_ext
13539 LIBS=$ac_check_lib_save_LIBS
13540 fi
13541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
13542 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
13543 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
13544 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
13545 else
13546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
13547 $as_echo_n "checking for dld_link in -ldld... " >&6; }
13548 if ${ac_cv_lib_dld_dld_link+:} false; then :
13549 $as_echo_n "(cached) " >&6
13550 else
13551 ac_check_lib_save_LIBS=$LIBS
13552 LIBS="-ldld $LIBS"
13553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13554 /* end confdefs.h. */
13555
13556 /* Override any GCC internal prototype to avoid an error.
13557 Use char because int might match the return type of a GCC
13558 builtin and then its argument prototype would still apply. */
13559 #ifdef __cplusplus
13560 extern "C"
13561 #endif
13562 char dld_link ();
13563 int
13564 main ()
13565 {
13566 return dld_link ();
13567 ;
13568 return 0;
13569 }
13570 _ACEOF
13571 if ac_fn_c_try_link "$LINENO"; then :
13572 ac_cv_lib_dld_dld_link=yes
13573 else
13574 ac_cv_lib_dld_dld_link=no
13575 fi
13576 rm -f core conftest.err conftest.$ac_objext \
13577 conftest$ac_exeext conftest.$ac_ext
13578 LIBS=$ac_check_lib_save_LIBS
13579 fi
13580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
13581 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
13582 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
13583 lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
13584 fi
13585
13586
13587 fi
13588
13589
13590 fi
13591
13592
13593 fi
13594
13595
13596 fi
13597
13598
13599 fi
13600
13601 ;;
13602 esac
13603
13604 if test "x$lt_cv_dlopen" != xno; then
13605 enable_dlopen=yes
13606 else
13607 enable_dlopen=no
13608 fi
13609
13610 case $lt_cv_dlopen in
13611 dlopen)
13612 save_CPPFLAGS="$CPPFLAGS"
13613 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
13614
13615 save_LDFLAGS="$LDFLAGS"
13616 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
13617
13618 save_LIBS="$LIBS"
13619 LIBS="$lt_cv_dlopen_libs $LIBS"
13620
13621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
13622 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
13623 if ${lt_cv_dlopen_self+:} false; then :
13624 $as_echo_n "(cached) " >&6
13625 else
13626 if test "$cross_compiling" = yes; then :
13627 lt_cv_dlopen_self=cross
13628 else
13629 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
13630 lt_status=$lt_dlunknown
13631 cat > conftest.$ac_ext <<_LT_EOF
13632 #line $LINENO "configure"
13633 #include "confdefs.h"
13634
13635 #if HAVE_DLFCN_H
13636 #include <dlfcn.h>
13637 #endif
13638
13639 #include <stdio.h>
13640
13641 #ifdef RTLD_GLOBAL
13642 # define LT_DLGLOBAL RTLD_GLOBAL
13643 #else
13644 # ifdef DL_GLOBAL
13645 # define LT_DLGLOBAL DL_GLOBAL
13646 # else
13647 # define LT_DLGLOBAL 0
13648 # endif
13649 #endif
13650
13651 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
13652 find out it does not work in some platform. */
13653 #ifndef LT_DLLAZY_OR_NOW
13654 # ifdef RTLD_LAZY
13655 # define LT_DLLAZY_OR_NOW RTLD_LAZY
13656 # else
13657 # ifdef DL_LAZY
13658 # define LT_DLLAZY_OR_NOW DL_LAZY
13659 # else
13660 # ifdef RTLD_NOW
13661 # define LT_DLLAZY_OR_NOW RTLD_NOW
13662 # else
13663 # ifdef DL_NOW
13664 # define LT_DLLAZY_OR_NOW DL_NOW
13665 # else
13666 # define LT_DLLAZY_OR_NOW 0
13667 # endif
13668 # endif
13669 # endif
13670 # endif
13671 #endif
13672
13673 /* When -fvisbility=hidden is used, assume the code has been annotated
13674 correspondingly for the symbols needed. */
13675 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
13676 int fnord () __attribute__((visibility("default")));
13677 #endif
13678
13679 int fnord () { return 42; }
13680 int main ()
13681 {
13682 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
13683 int status = $lt_dlunknown;
13684
13685 if (self)
13686 {
13687 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
13688 else
13689 {
13690 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
13691 else puts (dlerror ());
13692 }
13693 /* dlclose (self); */
13694 }
13695 else
13696 puts (dlerror ());
13697
13698 return status;
13699 }
13700 _LT_EOF
13701 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
13702 (eval $ac_link) 2>&5
13703 ac_status=$?
13704 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13705 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
13706 (./conftest; exit; ) >&5 2>/dev/null
13707 lt_status=$?
13708 case x$lt_status in
13709 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
13710 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
13711 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
13712 esac
13713 else :
13714 # compilation failed
13715 lt_cv_dlopen_self=no
13716 fi
13717 fi
13718 rm -fr conftest*
13719
13720
13721 fi
13722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
13723 $as_echo "$lt_cv_dlopen_self" >&6; }
13724
13725 if test "x$lt_cv_dlopen_self" = xyes; then
13726 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
13727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
13728 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
13729 if ${lt_cv_dlopen_self_static+:} false; then :
13730 $as_echo_n "(cached) " >&6
13731 else
13732 if test "$cross_compiling" = yes; then :
13733 lt_cv_dlopen_self_static=cross
13734 else
13735 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
13736 lt_status=$lt_dlunknown
13737 cat > conftest.$ac_ext <<_LT_EOF
13738 #line $LINENO "configure"
13739 #include "confdefs.h"
13740
13741 #if HAVE_DLFCN_H
13742 #include <dlfcn.h>
13743 #endif
13744
13745 #include <stdio.h>
13746
13747 #ifdef RTLD_GLOBAL
13748 # define LT_DLGLOBAL RTLD_GLOBAL
13749 #else
13750 # ifdef DL_GLOBAL
13751 # define LT_DLGLOBAL DL_GLOBAL
13752 # else
13753 # define LT_DLGLOBAL 0
13754 # endif
13755 #endif
13756
13757 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
13758 find out it does not work in some platform. */
13759 #ifndef LT_DLLAZY_OR_NOW
13760 # ifdef RTLD_LAZY
13761 # define LT_DLLAZY_OR_NOW RTLD_LAZY
13762 # else
13763 # ifdef DL_LAZY
13764 # define LT_DLLAZY_OR_NOW DL_LAZY
13765 # else
13766 # ifdef RTLD_NOW
13767 # define LT_DLLAZY_OR_NOW RTLD_NOW
13768 # else
13769 # ifdef DL_NOW
13770 # define LT_DLLAZY_OR_NOW DL_NOW
13771 # else
13772 # define LT_DLLAZY_OR_NOW 0
13773 # endif
13774 # endif
13775 # endif
13776 # endif
13777 #endif
13778
13779 /* When -fvisbility=hidden is used, assume the code has been annotated
13780 correspondingly for the symbols needed. */
13781 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
13782 int fnord () __attribute__((visibility("default")));
13783 #endif
13784
13785 int fnord () { return 42; }
13786 int main ()
13787 {
13788 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
13789 int status = $lt_dlunknown;
13790
13791 if (self)
13792 {
13793 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
13794 else
13795 {
13796 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
13797 else puts (dlerror ());
13798 }
13799 /* dlclose (self); */
13800 }
13801 else
13802 puts (dlerror ());
13803
13804 return status;
13805 }
13806 _LT_EOF
13807 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
13808 (eval $ac_link) 2>&5
13809 ac_status=$?
13810 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13811 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
13812 (./conftest; exit; ) >&5 2>/dev/null
13813 lt_status=$?
13814 case x$lt_status in
13815 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
13816 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
13817 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
13818 esac
13819 else :
13820 # compilation failed
13821 lt_cv_dlopen_self_static=no
13822 fi
13823 fi
13824 rm -fr conftest*
13825
13826
13827 fi
13828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
13829 $as_echo "$lt_cv_dlopen_self_static" >&6; }
13830 fi
13831
13832 CPPFLAGS="$save_CPPFLAGS"
13833 LDFLAGS="$save_LDFLAGS"
13834 LIBS="$save_LIBS"
13835 ;;
13836 esac
13837
13838 case $lt_cv_dlopen_self in
13839 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
13840 *) enable_dlopen_self=unknown ;;
13841 esac
13842
13843 case $lt_cv_dlopen_self_static in
13844 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
13845 *) enable_dlopen_self_static=unknown ;;
13846 esac
13847 fi
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865 striplib=
13866 old_striplib=
13867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
13868 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
13869 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
13870 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
13871 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
13872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13873 $as_echo "yes" >&6; }
13874 else
13875 # FIXME - insert some real tests, host_os isn't really good enough
13876 case $host_os in
13877 darwin*)
13878 if test -n "$STRIP" ; then
13879 striplib="$STRIP -x"
13880 old_striplib="$STRIP -S"
13881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13882 $as_echo "yes" >&6; }
13883 else
13884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13885 $as_echo "no" >&6; }
13886 fi
13887 ;;
13888 *)
13889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13890 $as_echo "no" >&6; }
13891 ;;
13892 esac
13893 fi
13894
13895
13896
13897
13898
13899
13900
13901
13902
13903
13904
13905
13906 # Report which library types will actually be built
13907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
13908 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
13909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
13910 $as_echo "$can_build_shared" >&6; }
13911
13912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
13913 $as_echo_n "checking whether to build shared libraries... " >&6; }
13914 test "$can_build_shared" = "no" && enable_shared=no
13915
13916 # On AIX, shared libraries and static libraries use the same namespace, and
13917 # are all built from PIC.
13918 case $host_os in
13919 aix3*)
13920 test "$enable_shared" = yes && enable_static=no
13921 if test -n "$RANLIB"; then
13922 archive_cmds="$archive_cmds~\$RANLIB \$lib"
13923 postinstall_cmds='$RANLIB $lib'
13924 fi
13925 ;;
13926
13927 aix[4-9]*)
13928 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
13929 test "$enable_shared" = yes && enable_static=no
13930 fi
13931 ;;
13932 esac
13933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
13934 $as_echo "$enable_shared" >&6; }
13935
13936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
13937 $as_echo_n "checking whether to build static libraries... " >&6; }
13938 # Make sure either enable_shared or enable_static is yes.
13939 test "$enable_shared" = yes || enable_static=yes
13940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
13941 $as_echo "$enable_static" >&6; }
13942
13943
13944
13945
13946 fi
13947 ac_ext=c
13948 ac_cpp='$CPP $CPPFLAGS'
13949 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13950 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13951 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13952
13953 CC="$lt_save_CC"
13954
13955 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
13956 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
13957 (test "X$CXX" != "Xg++"))) ; then
13958 ac_ext=cpp
13959 ac_cpp='$CXXCPP $CPPFLAGS'
13960 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13961 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13962 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
13963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
13964 $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
13965 if test -z "$CXXCPP"; then
13966 if ${ac_cv_prog_CXXCPP+:} false; then :
13967 $as_echo_n "(cached) " >&6
13968 else
13969 # Double quotes because CXXCPP needs to be expanded
13970 for CXXCPP in "$CXX -E" "/lib/cpp"
13971 do
13972 ac_preproc_ok=false
13973 for ac_cxx_preproc_warn_flag in '' yes
13974 do
13975 # Use a header file that comes with gcc, so configuring glibc
13976 # with a fresh cross-compiler works.
13977 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13978 # <limits.h> exists even on freestanding compilers.
13979 # On the NeXT, cc -E runs the code through the compiler's parser,
13980 # not just through cpp. "Syntax error" is here to catch this case.
13981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13982 /* end confdefs.h. */
13983 #ifdef __STDC__
13984 # include <limits.h>
13985 #else
13986 # include <assert.h>
13987 #endif
13988 Syntax error
13989 _ACEOF
13990 if ac_fn_cxx_try_cpp "$LINENO"; then :
13991
13992 else
13993 # Broken: fails on valid input.
13994 continue
13995 fi
13996 rm -f conftest.err conftest.i conftest.$ac_ext
13997
13998 # OK, works on sane cases. Now check whether nonexistent headers
13999 # can be detected and how.
14000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14001 /* end confdefs.h. */
14002 #include <ac_nonexistent.h>
14003 _ACEOF
14004 if ac_fn_cxx_try_cpp "$LINENO"; then :
14005 # Broken: success on invalid input.
14006 continue
14007 else
14008 # Passes both tests.
14009 ac_preproc_ok=:
14010 break
14011 fi
14012 rm -f conftest.err conftest.i conftest.$ac_ext
14013
14014 done
14015 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
14016 rm -f conftest.i conftest.err conftest.$ac_ext
14017 if $ac_preproc_ok; then :
14018 break
14019 fi
14020
14021 done
14022 ac_cv_prog_CXXCPP=$CXXCPP
14023
14024 fi
14025 CXXCPP=$ac_cv_prog_CXXCPP
14026 else
14027 ac_cv_prog_CXXCPP=$CXXCPP
14028 fi
14029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
14030 $as_echo "$CXXCPP" >&6; }
14031 ac_preproc_ok=false
14032 for ac_cxx_preproc_warn_flag in '' yes
14033 do
14034 # Use a header file that comes with gcc, so configuring glibc
14035 # with a fresh cross-compiler works.
14036 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14037 # <limits.h> exists even on freestanding compilers.
14038 # On the NeXT, cc -E runs the code through the compiler's parser,
14039 # not just through cpp. "Syntax error" is here to catch this case.
14040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14041 /* end confdefs.h. */
14042 #ifdef __STDC__
14043 # include <limits.h>
14044 #else
14045 # include <assert.h>
14046 #endif
14047 Syntax error
14048 _ACEOF
14049 if ac_fn_cxx_try_cpp "$LINENO"; then :
14050
14051 else
14052 # Broken: fails on valid input.
14053 continue
14054 fi
14055 rm -f conftest.err conftest.i conftest.$ac_ext
14056
14057 # OK, works on sane cases. Now check whether nonexistent headers
14058 # can be detected and how.
14059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14060 /* end confdefs.h. */
14061 #include <ac_nonexistent.h>
14062 _ACEOF
14063 if ac_fn_cxx_try_cpp "$LINENO"; then :
14064 # Broken: success on invalid input.
14065 continue
14066 else
14067 # Passes both tests.
14068 ac_preproc_ok=:
14069 break
14070 fi
14071 rm -f conftest.err conftest.i conftest.$ac_ext
14072
14073 done
14074 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
14075 rm -f conftest.i conftest.err conftest.$ac_ext
14076 if $ac_preproc_ok; then :
14077
14078 else
14079 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14080 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14081 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
14082 See \`config.log' for more details" "$LINENO" 5; }
14083 fi
14084
14085 ac_ext=c
14086 ac_cpp='$CPP $CPPFLAGS'
14087 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14088 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14089 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14090
14091 else
14092 _lt_caught_CXX_error=yes
14093 fi
14094
14095 ac_ext=cpp
14096 ac_cpp='$CXXCPP $CPPFLAGS'
14097 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14098 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14099 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
14100
14101 archive_cmds_need_lc_CXX=no
14102 allow_undefined_flag_CXX=
14103 always_export_symbols_CXX=no
14104 archive_expsym_cmds_CXX=
14105 compiler_needs_object_CXX=no
14106 export_dynamic_flag_spec_CXX=
14107 hardcode_direct_CXX=no
14108 hardcode_direct_absolute_CXX=no
14109 hardcode_libdir_flag_spec_CXX=
14110 hardcode_libdir_separator_CXX=
14111 hardcode_minus_L_CXX=no
14112 hardcode_shlibpath_var_CXX=unsupported
14113 hardcode_automatic_CXX=no
14114 inherit_rpath_CXX=no
14115 module_cmds_CXX=
14116 module_expsym_cmds_CXX=
14117 link_all_deplibs_CXX=unknown
14118 old_archive_cmds_CXX=$old_archive_cmds
14119 reload_flag_CXX=$reload_flag
14120 reload_cmds_CXX=$reload_cmds
14121 no_undefined_flag_CXX=
14122 whole_archive_flag_spec_CXX=
14123 enable_shared_with_static_runtimes_CXX=no
14124
14125 # Source file extension for C++ test sources.
14126 ac_ext=cpp
14127
14128 # Object file extension for compiled C++ test sources.
14129 objext=o
14130 objext_CXX=$objext
14131
14132 # No sense in running all these tests if we already determined that
14133 # the CXX compiler isn't working. Some variables (like enable_shared)
14134 # are currently assumed to apply to all compilers on this platform,
14135 # and will be corrupted by setting them based on a non-working compiler.
14136 if test "$_lt_caught_CXX_error" != yes; then
14137 # Code to be used in simple compile tests
14138 lt_simple_compile_test_code="int some_variable = 0;"
14139
14140 # Code to be used in simple link tests
14141 lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
14142
14143 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
14144
14145
14146
14147
14148
14149
14150 # If no C compiler was specified, use CC.
14151 LTCC=${LTCC-"$CC"}
14152
14153 # If no C compiler flags were specified, use CFLAGS.
14154 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
14155
14156 # Allow CC to be a program name with arguments.
14157 compiler=$CC
14158
14159
14160 # save warnings/boilerplate of simple test code
14161 ac_outfile=conftest.$ac_objext
14162 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
14163 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
14164 _lt_compiler_boilerplate=`cat conftest.err`
14165 $RM conftest*
14166
14167 ac_outfile=conftest.$ac_objext
14168 echo "$lt_simple_link_test_code" >conftest.$ac_ext
14169 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
14170 _lt_linker_boilerplate=`cat conftest.err`
14171 $RM -r conftest*
14172
14173
14174 # Allow CC to be a program name with arguments.
14175 lt_save_CC=$CC
14176 lt_save_CFLAGS=$CFLAGS
14177 lt_save_LD=$LD
14178 lt_save_GCC=$GCC
14179 GCC=$GXX
14180 lt_save_with_gnu_ld=$with_gnu_ld
14181 lt_save_path_LD=$lt_cv_path_LD
14182 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
14183 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
14184 else
14185 $as_unset lt_cv_prog_gnu_ld
14186 fi
14187 if test -n "${lt_cv_path_LDCXX+set}"; then
14188 lt_cv_path_LD=$lt_cv_path_LDCXX
14189 else
14190 $as_unset lt_cv_path_LD
14191 fi
14192 test -z "${LDCXX+set}" || LD=$LDCXX
14193 CC=${CXX-"c++"}
14194 CFLAGS=$CXXFLAGS
14195 compiler=$CC
14196 compiler_CXX=$CC
14197 for cc_temp in $compiler""; do
14198 case $cc_temp in
14199 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
14200 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
14201 \-*) ;;
14202 *) break;;
14203 esac
14204 done
14205 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
14206
14207
14208 if test -n "$compiler"; then
14209 # We don't want -fno-exception when compiling C++ code, so set the
14210 # no_builtin_flag separately
14211 if test "$GXX" = yes; then
14212 lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
14213 else
14214 lt_prog_compiler_no_builtin_flag_CXX=
14215 fi
14216
14217 if test "$GXX" = yes; then
14218 # Set up default GNU C++ configuration
14219
14220
14221
14222 # Check whether --with-gnu-ld was given.
14223 if test "${with_gnu_ld+set}" = set; then :
14224 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
14225 else
14226 with_gnu_ld=no
14227 fi
14228
14229 ac_prog=ld
14230 if test "$GCC" = yes; then
14231 # Check if gcc -print-prog-name=ld gives a path.
14232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
14233 $as_echo_n "checking for ld used by $CC... " >&6; }
14234 case $host in
14235 *-*-mingw*)
14236 # gcc leaves a trailing carriage return which upsets mingw
14237 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
14238 *)
14239 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
14240 esac
14241 case $ac_prog in
14242 # Accept absolute paths.
14243 [\\/]* | ?:[\\/]*)
14244 re_direlt='/[^/][^/]*/\.\./'
14245 # Canonicalize the pathname of ld
14246 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
14247 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
14248 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
14249 done
14250 test -z "$LD" && LD="$ac_prog"
14251 ;;
14252 "")
14253 # If it fails, then pretend we aren't using GCC.
14254 ac_prog=ld
14255 ;;
14256 *)
14257 # If it is relative, then search for the first ld in PATH.
14258 with_gnu_ld=unknown
14259 ;;
14260 esac
14261 elif test "$with_gnu_ld" = yes; then
14262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
14263 $as_echo_n "checking for GNU ld... " >&6; }
14264 else
14265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
14266 $as_echo_n "checking for non-GNU ld... " >&6; }
14267 fi
14268 if ${lt_cv_path_LD+:} false; then :
14269 $as_echo_n "(cached) " >&6
14270 else
14271 if test -z "$LD"; then
14272 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
14273 for ac_dir in $PATH; do
14274 IFS="$lt_save_ifs"
14275 test -z "$ac_dir" && ac_dir=.
14276 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
14277 lt_cv_path_LD="$ac_dir/$ac_prog"
14278 # Check to see if the program is GNU ld. I'd rather use --version,
14279 # but apparently some variants of GNU ld only accept -v.
14280 # Break only if it was the GNU/non-GNU ld that we prefer.
14281 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
14282 *GNU* | *'with BFD'*)
14283 test "$with_gnu_ld" != no && break
14284 ;;
14285 *)
14286 test "$with_gnu_ld" != yes && break
14287 ;;
14288 esac
14289 fi
14290 done
14291 IFS="$lt_save_ifs"
14292 else
14293 lt_cv_path_LD="$LD" # Let the user override the test with a path.
14294 fi
14295 fi
14296
14297 LD="$lt_cv_path_LD"
14298 if test -n "$LD"; then
14299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
14300 $as_echo "$LD" >&6; }
14301 else
14302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14303 $as_echo "no" >&6; }
14304 fi
14305 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
14306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
14307 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
14308 if ${lt_cv_prog_gnu_ld+:} false; then :
14309 $as_echo_n "(cached) " >&6
14310 else
14311 # I'd rather use --version here, but apparently some GNU lds only accept -v.
14312 case `$LD -v 2>&1 </dev/null` in
14313 *GNU* | *'with BFD'*)
14314 lt_cv_prog_gnu_ld=yes
14315 ;;
14316 *)
14317 lt_cv_prog_gnu_ld=no
14318 ;;
14319 esac
14320 fi
14321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
14322 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
14323 with_gnu_ld=$lt_cv_prog_gnu_ld
14324
14325
14326
14327
14328
14329
14330
14331 # Check if GNU C++ uses GNU ld as the underlying linker, since the
14332 # archiving commands below assume that GNU ld is being used.
14333 if test "$with_gnu_ld" = yes; then
14334 archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
14335 archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14336
14337 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
14338 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
14339
14340 # If archive_cmds runs LD, not CC, wlarc should be empty
14341 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
14342 # investigate it a little bit more. (MM)
14343 wlarc='${wl}'
14344
14345 # ancient GNU ld didn't support --whole-archive et. al.
14346 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
14347 $GREP 'no-whole-archive' > /dev/null; then
14348 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
14349 else
14350 whole_archive_flag_spec_CXX=
14351 fi
14352 else
14353 with_gnu_ld=no
14354 wlarc=
14355
14356 # A generic and very simple default shared library creation
14357 # command for GNU C++ for the case where it uses the native
14358 # linker, instead of GNU ld. If possible, this setting should
14359 # overridden to take advantage of the native linker features on
14360 # the platform it is being used on.
14361 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
14362 fi
14363
14364 # Commands to make compiler produce verbose output that lists
14365 # what "hidden" libraries, object files and flags are used when
14366 # linking a shared library.
14367 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
14368
14369 else
14370 GXX=no
14371 with_gnu_ld=no
14372 wlarc=
14373 fi
14374
14375 # PORTME: fill in a description of your system's C++ link characteristics
14376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
14377 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
14378 ld_shlibs_CXX=yes
14379 case $host_os in
14380 aix3*)
14381 # FIXME: insert proper C++ library support
14382 ld_shlibs_CXX=no
14383 ;;
14384 aix[4-9]*)
14385 if test "$host_cpu" = ia64; then
14386 # On IA64, the linker does run time linking by default, so we don't
14387 # have to do anything special.
14388 aix_use_runtimelinking=no
14389 exp_sym_flag='-Bexport'
14390 no_entry_flag=""
14391 else
14392 aix_use_runtimelinking=no
14393
14394 # Test if we are trying to use run time linking or normal
14395 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
14396 # need to do runtime linking.
14397 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
14398 for ld_flag in $LDFLAGS; do
14399 case $ld_flag in
14400 *-brtl*)
14401 aix_use_runtimelinking=yes
14402 break
14403 ;;
14404 esac
14405 done
14406 ;;
14407 esac
14408
14409 exp_sym_flag='-bexport'
14410 no_entry_flag='-bnoentry'
14411 fi
14412
14413 # When large executables or shared objects are built, AIX ld can
14414 # have problems creating the table of contents. If linking a library
14415 # or program results in "error TOC overflow" add -mminimal-toc to
14416 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
14417 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
14418
14419 archive_cmds_CXX=''
14420 hardcode_direct_CXX=yes
14421 hardcode_direct_absolute_CXX=yes
14422 hardcode_libdir_separator_CXX=':'
14423 link_all_deplibs_CXX=yes
14424 file_list_spec_CXX='${wl}-f,'
14425
14426 if test "$GXX" = yes; then
14427 case $host_os in aix4.[012]|aix4.[012].*)
14428 # We only want to do this on AIX 4.2 and lower, the check
14429 # below for broken collect2 doesn't work under 4.3+
14430 collect2name=`${CC} -print-prog-name=collect2`
14431 if test -f "$collect2name" &&
14432 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
14433 then
14434 # We have reworked collect2
14435 :
14436 else
14437 # We have old collect2
14438 hardcode_direct_CXX=unsupported
14439 # It fails to find uninstalled libraries when the uninstalled
14440 # path is not listed in the libpath. Setting hardcode_minus_L
14441 # to unsupported forces relinking
14442 hardcode_minus_L_CXX=yes
14443 hardcode_libdir_flag_spec_CXX='-L$libdir'
14444 hardcode_libdir_separator_CXX=
14445 fi
14446 esac
14447 shared_flag='-shared'
14448 if test "$aix_use_runtimelinking" = yes; then
14449 shared_flag="$shared_flag "'${wl}-G'
14450 fi
14451 else
14452 # not using gcc
14453 if test "$host_cpu" = ia64; then
14454 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
14455 # chokes on -Wl,-G. The following line is correct:
14456 shared_flag='-G'
14457 else
14458 if test "$aix_use_runtimelinking" = yes; then
14459 shared_flag='${wl}-G'
14460 else
14461 shared_flag='${wl}-bM:SRE'
14462 fi
14463 fi
14464 fi
14465
14466 export_dynamic_flag_spec_CXX='${wl}-bexpall'
14467 # It seems that -bexpall does not export symbols beginning with
14468 # underscore (_), so it is better to generate a list of symbols to
14469 # export.
14470 always_export_symbols_CXX=yes
14471 if test "$aix_use_runtimelinking" = yes; then
14472 # Warning - without using the other runtime loading flags (-brtl),
14473 # -berok will link without error, but may produce a broken library.
14474 allow_undefined_flag_CXX='-berok'
14475 # Determine the default libpath from the value encoded in an empty
14476 # executable.
14477 if test "${lt_cv_aix_libpath+set}" = set; then
14478 aix_libpath=$lt_cv_aix_libpath
14479 else
14480 if ${lt_cv_aix_libpath__CXX+:} false; then :
14481 $as_echo_n "(cached) " >&6
14482 else
14483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14484 /* end confdefs.h. */
14485
14486 int
14487 main ()
14488 {
14489
14490 ;
14491 return 0;
14492 }
14493 _ACEOF
14494 if ac_fn_cxx_try_link "$LINENO"; then :
14495
14496 lt_aix_libpath_sed='
14497 /Import File Strings/,/^$/ {
14498 /^0/ {
14499 s/^0 *\([^ ]*\) *$/\1/
14500 p
14501 }
14502 }'
14503 lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14504 # Check for a 64-bit object if we didn't find anything.
14505 if test -z "$lt_cv_aix_libpath__CXX"; then
14506 lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14507 fi
14508 fi
14509 rm -f core conftest.err conftest.$ac_objext \
14510 conftest$ac_exeext conftest.$ac_ext
14511 if test -z "$lt_cv_aix_libpath__CXX"; then
14512 lt_cv_aix_libpath__CXX="/usr/lib:/lib"
14513 fi
14514
14515 fi
14516
14517 aix_libpath=$lt_cv_aix_libpath__CXX
14518 fi
14519
14520 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
14521
14522 archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
14523 else
14524 if test "$host_cpu" = ia64; then
14525 hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
14526 allow_undefined_flag_CXX="-z nodefs"
14527 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
14528 else
14529 # Determine the default libpath from the value encoded in an
14530 # empty executable.
14531 if test "${lt_cv_aix_libpath+set}" = set; then
14532 aix_libpath=$lt_cv_aix_libpath
14533 else
14534 if ${lt_cv_aix_libpath__CXX+:} false; then :
14535 $as_echo_n "(cached) " >&6
14536 else
14537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14538 /* end confdefs.h. */
14539
14540 int
14541 main ()
14542 {
14543
14544 ;
14545 return 0;
14546 }
14547 _ACEOF
14548 if ac_fn_cxx_try_link "$LINENO"; then :
14549
14550 lt_aix_libpath_sed='
14551 /Import File Strings/,/^$/ {
14552 /^0/ {
14553 s/^0 *\([^ ]*\) *$/\1/
14554 p
14555 }
14556 }'
14557 lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14558 # Check for a 64-bit object if we didn't find anything.
14559 if test -z "$lt_cv_aix_libpath__CXX"; then
14560 lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14561 fi
14562 fi
14563 rm -f core conftest.err conftest.$ac_objext \
14564 conftest$ac_exeext conftest.$ac_ext
14565 if test -z "$lt_cv_aix_libpath__CXX"; then
14566 lt_cv_aix_libpath__CXX="/usr/lib:/lib"
14567 fi
14568
14569 fi
14570
14571 aix_libpath=$lt_cv_aix_libpath__CXX
14572 fi
14573
14574 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
14575 # Warning - without using the other run time loading flags,
14576 # -berok will link without error, but may produce a broken library.
14577 no_undefined_flag_CXX=' ${wl}-bernotok'
14578 allow_undefined_flag_CXX=' ${wl}-berok'
14579 if test "$with_gnu_ld" = yes; then
14580 # We only use this code for GNU lds that support --whole-archive.
14581 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
14582 else
14583 # Exported symbols can be pulled into shared objects from archives
14584 whole_archive_flag_spec_CXX='$convenience'
14585 fi
14586 archive_cmds_need_lc_CXX=yes
14587 # This is similar to how AIX traditionally builds its shared
14588 # libraries.
14589 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
14590 fi
14591 fi
14592 ;;
14593
14594 beos*)
14595 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
14596 allow_undefined_flag_CXX=unsupported
14597 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
14598 # support --undefined. This deserves some investigation. FIXME
14599 archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14600 else
14601 ld_shlibs_CXX=no
14602 fi
14603 ;;
14604
14605 chorus*)
14606 case $cc_basename in
14607 *)
14608 # FIXME: insert proper C++ library support
14609 ld_shlibs_CXX=no
14610 ;;
14611 esac
14612 ;;
14613
14614 cygwin* | mingw* | pw32* | cegcc*)
14615 case $GXX,$cc_basename in
14616 ,cl* | no,cl*)
14617 # Native MSVC
14618 # hardcode_libdir_flag_spec is actually meaningless, as there is
14619 # no search path for DLLs.
14620 hardcode_libdir_flag_spec_CXX=' '
14621 allow_undefined_flag_CXX=unsupported
14622 always_export_symbols_CXX=yes
14623 file_list_spec_CXX='@'
14624 # Tell ltmain to make .lib files, not .a files.
14625 libext=lib
14626 # Tell ltmain to make .dll files, not .so files.
14627 shrext_cmds=".dll"
14628 # FIXME: Setting linknames here is a bad hack.
14629 archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
14630 archive_expsym_cmds_CXX='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
14631 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
14632 else
14633 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
14634 fi~
14635 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
14636 linknames='
14637 # The linker will not automatically build a static lib if we build a DLL.
14638 # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true'
14639 enable_shared_with_static_runtimes_CXX=yes
14640 # Don't use ranlib
14641 old_postinstall_cmds_CXX='chmod 644 $oldlib'
14642 postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~
14643 lt_tool_outputfile="@TOOL_OUTPUT@"~
14644 case $lt_outputfile in
14645 *.exe|*.EXE) ;;
14646 *)
14647 lt_outputfile="$lt_outputfile.exe"
14648 lt_tool_outputfile="$lt_tool_outputfile.exe"
14649 ;;
14650 esac~
14651 func_to_tool_file "$lt_outputfile"~
14652 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
14653 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
14654 $RM "$lt_outputfile.manifest";
14655 fi'
14656 ;;
14657 *)
14658 # g++
14659 # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
14660 # as there is no search path for DLLs.
14661 hardcode_libdir_flag_spec_CXX='-L$libdir'
14662 export_dynamic_flag_spec_CXX='${wl}--export-all-symbols'
14663 allow_undefined_flag_CXX=unsupported
14664 always_export_symbols_CXX=no
14665 enable_shared_with_static_runtimes_CXX=yes
14666
14667 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
14668 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
14669 # If the export-symbols file already is a .def file (1st line
14670 # is EXPORTS), use it as is; otherwise, prepend...
14671 archive_expsym_cmds_CXX='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
14672 cp $export_symbols $output_objdir/$soname.def;
14673 else
14674 echo EXPORTS > $output_objdir/$soname.def;
14675 cat $export_symbols >> $output_objdir/$soname.def;
14676 fi~
14677 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
14678 else
14679 ld_shlibs_CXX=no
14680 fi
14681 ;;
14682 esac
14683 ;;
14684 darwin* | rhapsody*)
14685
14686
14687 archive_cmds_need_lc_CXX=no
14688 hardcode_direct_CXX=no
14689 hardcode_automatic_CXX=yes
14690 hardcode_shlibpath_var_CXX=unsupported
14691 if test "$lt_cv_ld_force_load" = "yes"; then
14692 whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
14693
14694 else
14695 whole_archive_flag_spec_CXX=''
14696 fi
14697 link_all_deplibs_CXX=yes
14698 allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
14699 case $cc_basename in
14700 ifort*) _lt_dar_can_shared=yes ;;
14701 *) _lt_dar_can_shared=$GCC ;;
14702 esac
14703 if test "$_lt_dar_can_shared" = "yes"; then
14704 output_verbose_link_cmd=func_echo_all
14705 archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
14706 module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
14707 archive_expsym_cmds_CXX="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}"
14708 module_expsym_cmds_CXX="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}"
14709 if test "$lt_cv_apple_cc_single_mod" != "yes"; then
14710 archive_cmds_CXX="\$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}"
14711 archive_expsym_cmds_CXX="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}"
14712 fi
14713
14714 else
14715 ld_shlibs_CXX=no
14716 fi
14717
14718 ;;
14719
14720 dgux*)
14721 case $cc_basename in
14722 ec++*)
14723 # FIXME: insert proper C++ library support
14724 ld_shlibs_CXX=no
14725 ;;
14726 ghcx*)
14727 # Green Hills C++ Compiler
14728 # FIXME: insert proper C++ library support
14729 ld_shlibs_CXX=no
14730 ;;
14731 *)
14732 # FIXME: insert proper C++ library support
14733 ld_shlibs_CXX=no
14734 ;;
14735 esac
14736 ;;
14737
14738 freebsd2.*)
14739 # C++ shared libraries reported to be fairly broken before
14740 # switch to ELF
14741 ld_shlibs_CXX=no
14742 ;;
14743
14744 freebsd-elf*)
14745 archive_cmds_need_lc_CXX=no
14746 ;;
14747
14748 freebsd* | dragonfly*)
14749 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
14750 # conventions
14751 ld_shlibs_CXX=yes
14752 ;;
14753
14754 gnu*)
14755 ;;
14756
14757 haiku*)
14758 archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14759 link_all_deplibs_CXX=yes
14760 ;;
14761
14762 hpux9*)
14763 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
14764 hardcode_libdir_separator_CXX=:
14765 export_dynamic_flag_spec_CXX='${wl}-E'
14766 hardcode_direct_CXX=yes
14767 hardcode_minus_L_CXX=yes # Not in the search PATH,
14768 # but as the default
14769 # location of the library.
14770
14771 case $cc_basename in
14772 CC*)
14773 # FIXME: insert proper C++ library support
14774 ld_shlibs_CXX=no
14775 ;;
14776 aCC*)
14777 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14778 # Commands to make compiler produce verbose output that lists
14779 # what "hidden" libraries, object files and flags are used when
14780 # linking a shared library.
14781 #
14782 # There doesn't appear to be a way to prevent this compiler from
14783 # explicitly linking system object files so we need to strip them
14784 # from the output so that they don't get included in the library
14785 # dependencies.
14786 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
14787 ;;
14788 *)
14789 if test "$GXX" = yes; then
14790 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14791 else
14792 # FIXME: insert proper C++ library support
14793 ld_shlibs_CXX=no
14794 fi
14795 ;;
14796 esac
14797 ;;
14798
14799 hpux10*|hpux11*)
14800 if test $with_gnu_ld = no; then
14801 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
14802 hardcode_libdir_separator_CXX=:
14803
14804 case $host_cpu in
14805 hppa*64*|ia64*)
14806 ;;
14807 *)
14808 export_dynamic_flag_spec_CXX='${wl}-E'
14809 ;;
14810 esac
14811 fi
14812 case $host_cpu in
14813 hppa*64*|ia64*)
14814 hardcode_direct_CXX=no
14815 hardcode_shlibpath_var_CXX=no
14816 ;;
14817 *)
14818 hardcode_direct_CXX=yes
14819 hardcode_direct_absolute_CXX=yes
14820 hardcode_minus_L_CXX=yes # Not in the search PATH,
14821 # but as the default
14822 # location of the library.
14823 ;;
14824 esac
14825
14826 case $cc_basename in
14827 CC*)
14828 # FIXME: insert proper C++ library support
14829 ld_shlibs_CXX=no
14830 ;;
14831 aCC*)
14832 case $host_cpu in
14833 hppa*64*)
14834 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
14835 ;;
14836 ia64*)
14837 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
14838 ;;
14839 *)
14840 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
14841 ;;
14842 esac
14843 # Commands to make compiler produce verbose output that lists
14844 # what "hidden" libraries, object files and flags are used when
14845 # linking a shared library.
14846 #
14847 # There doesn't appear to be a way to prevent this compiler from
14848 # explicitly linking system object files so we need to strip them
14849 # from the output so that they don't get included in the library
14850 # dependencies.
14851 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
14852 ;;
14853 *)
14854 if test "$GXX" = yes; then
14855 if test $with_gnu_ld = no; then
14856 case $host_cpu in
14857 hppa*64*)
14858 archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
14859 ;;
14860 ia64*)
14861 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
14862 ;;
14863 *)
14864 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
14865 ;;
14866 esac
14867 fi
14868 else
14869 # FIXME: insert proper C++ library support
14870 ld_shlibs_CXX=no
14871 fi
14872 ;;
14873 esac
14874 ;;
14875
14876 interix[3-9]*)
14877 hardcode_direct_CXX=no
14878 hardcode_shlibpath_var_CXX=no
14879 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
14880 export_dynamic_flag_spec_CXX='${wl}-E'
14881 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
14882 # Instead, shared libraries are loaded at an image base (0x10000000 by
14883 # default) and relocated if they conflict, which is a slow very memory
14884 # consuming and fragmenting process. To avoid this, we pick a random,
14885 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
14886 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
14887 archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
14888 archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
14889 ;;
14890 irix5* | irix6*)
14891 case $cc_basename in
14892 CC*)
14893 # SGI C++
14894 archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
14895
14896 # Archives containing C++ object files must be created using
14897 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
14898 # necessary to make sure instantiated templates are included
14899 # in the archive.
14900 old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
14901 ;;
14902 *)
14903 if test "$GXX" = yes; then
14904 if test "$with_gnu_ld" = no; then
14905 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14906 else
14907 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
14908 fi
14909 fi
14910 link_all_deplibs_CXX=yes
14911 ;;
14912 esac
14913 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
14914 hardcode_libdir_separator_CXX=:
14915 inherit_rpath_CXX=yes
14916 ;;
14917
14918 linux* | k*bsd*-gnu | kopensolaris*-gnu)
14919 case $cc_basename in
14920 KCC*)
14921 # Kuck and Associates, Inc. (KAI) C++ Compiler
14922
14923 # KCC will only create a shared library if the output file
14924 # ends with ".so" (or ".sl" for HP-UX), so rename the library
14925 # to its proper name (with version) after linking.
14926 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
14927 archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
14928 # Commands to make compiler produce verbose output that lists
14929 # what "hidden" libraries, object files and flags are used when
14930 # linking a shared library.
14931 #
14932 # There doesn't appear to be a way to prevent this compiler from
14933 # explicitly linking system object files so we need to strip them
14934 # from the output so that they don't get included in the library
14935 # dependencies.
14936 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
14937
14938 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
14939 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
14940
14941 # Archives containing C++ object files must be created using
14942 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
14943 old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
14944 ;;
14945 icpc* | ecpc* )
14946 # Intel C++
14947 with_gnu_ld=yes
14948 # version 8.0 and above of icpc choke on multiply defined symbols
14949 # if we add $predep_objects and $postdep_objects, however 7.1 and
14950 # earlier do not add the objects themselves.
14951 case `$CC -V 2>&1` in
14952 *"Version 7."*)
14953 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
14954 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14955 ;;
14956 *) # Version 8.0 or newer
14957 tmp_idyn=
14958 case $host_cpu in
14959 ia64*) tmp_idyn=' -i_dynamic';;
14960 esac
14961 archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14962 archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14963 ;;
14964 esac
14965 archive_cmds_need_lc_CXX=no
14966 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
14967 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
14968 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
14969 ;;
14970 pgCC* | pgcpp*)
14971 # Portland Group C++ compiler
14972 case `$CC -V` in
14973 *pgCC\ [1-5].* | *pgcpp\ [1-5].*)
14974 prelink_cmds_CXX='tpldir=Template.dir~
14975 rm -rf $tpldir~
14976 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
14977 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
14978 old_archive_cmds_CXX='tpldir=Template.dir~
14979 rm -rf $tpldir~
14980 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
14981 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
14982 $RANLIB $oldlib'
14983 archive_cmds_CXX='tpldir=Template.dir~
14984 rm -rf $tpldir~
14985 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
14986 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
14987 archive_expsym_cmds_CXX='tpldir=Template.dir~
14988 rm -rf $tpldir~
14989 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
14990 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
14991 ;;
14992 *) # Version 6 and above use weak symbols
14993 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
14994 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
14995 ;;
14996 esac
14997
14998 hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
14999 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
15000 whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
15001 ;;
15002 cxx*)
15003 # Compaq C++
15004 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
15005 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
15006
15007 runpath_var=LD_RUN_PATH
15008 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
15009 hardcode_libdir_separator_CXX=:
15010
15011 # Commands to make compiler produce verbose output that lists
15012 # what "hidden" libraries, object files and flags are used when
15013 # linking a shared library.
15014 #
15015 # There doesn't appear to be a way to prevent this compiler from
15016 # explicitly linking system object files so we need to strip them
15017 # from the output so that they don't get included in the library
15018 # dependencies.
15019 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
15020 ;;
15021 xl* | mpixl* | bgxl*)
15022 # IBM XL 8.0 on PPC, with GNU ld
15023 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
15024 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
15025 archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15026 if test "x$supports_anon_versioning" = xyes; then
15027 archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~
15028 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
15029 echo "local: *; };" >> $output_objdir/$libname.ver~
15030 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
15031 fi
15032 ;;
15033 *)
15034 case `$CC -V 2>&1 | sed 5q` in
15035 *Sun\ C*)
15036 # Sun C++ 5.9
15037 no_undefined_flag_CXX=' -zdefs'
15038 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
15039 archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
15040 hardcode_libdir_flag_spec_CXX='-R$libdir'
15041 whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
15042 compiler_needs_object_CXX=yes
15043
15044 # Not sure whether something based on
15045 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
15046 # would be better.
15047 output_verbose_link_cmd='func_echo_all'
15048
15049 # Archives containing C++ object files must be created using
15050 # "CC -xar", where "CC" is the Sun C++ compiler. This is
15051 # necessary to make sure instantiated templates are included
15052 # in the archive.
15053 old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
15054 ;;
15055 esac
15056 ;;
15057 esac
15058 ;;
15059
15060 lynxos*)
15061 # FIXME: insert proper C++ library support
15062 ld_shlibs_CXX=no
15063 ;;
15064
15065 m88k*)
15066 # FIXME: insert proper C++ library support
15067 ld_shlibs_CXX=no
15068 ;;
15069
15070 mvs*)
15071 case $cc_basename in
15072 cxx*)
15073 # FIXME: insert proper C++ library support
15074 ld_shlibs_CXX=no
15075 ;;
15076 *)
15077 # FIXME: insert proper C++ library support
15078 ld_shlibs_CXX=no
15079 ;;
15080 esac
15081 ;;
15082
15083 netbsd*)
15084 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
15085 archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
15086 wlarc=
15087 hardcode_libdir_flag_spec_CXX='-R$libdir'
15088 hardcode_direct_CXX=yes
15089 hardcode_shlibpath_var_CXX=no
15090 fi
15091 # Workaround some broken pre-1.5 toolchains
15092 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
15093 ;;
15094
15095 *nto* | *qnx*)
15096 ld_shlibs_CXX=yes
15097 ;;
15098
15099 openbsd2*)
15100 # C++ shared libraries are fairly broken
15101 ld_shlibs_CXX=no
15102 ;;
15103
15104 openbsd*)
15105 if test -f /usr/libexec/ld.so; then
15106 hardcode_direct_CXX=yes
15107 hardcode_shlibpath_var_CXX=no
15108 hardcode_direct_absolute_CXX=yes
15109 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
15110 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
15111 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
15112 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
15113 export_dynamic_flag_spec_CXX='${wl}-E'
15114 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
15115 fi
15116 output_verbose_link_cmd=func_echo_all
15117 else
15118 ld_shlibs_CXX=no
15119 fi
15120 ;;
15121
15122 osf3* | osf4* | osf5*)
15123 case $cc_basename in
15124 KCC*)
15125 # Kuck and Associates, Inc. (KAI) C++ Compiler
15126
15127 # KCC will only create a shared library if the output file
15128 # ends with ".so" (or ".sl" for HP-UX), so rename the library
15129 # to its proper name (with version) after linking.
15130 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
15131
15132 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
15133 hardcode_libdir_separator_CXX=:
15134
15135 # Archives containing C++ object files must be created using
15136 # the KAI C++ compiler.
15137 case $host in
15138 osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;;
15139 *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;;
15140 esac
15141 ;;
15142 RCC*)
15143 # Rational C++ 2.4.1
15144 # FIXME: insert proper C++ library support
15145 ld_shlibs_CXX=no
15146 ;;
15147 cxx*)
15148 case $host in
15149 osf3*)
15150 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
15151 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
15152 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
15153 ;;
15154 *)
15155 allow_undefined_flag_CXX=' -expect_unresolved \*'
15156 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
15157 archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
15158 echo "-hidden">> $lib.exp~
15159 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
15160 $RM $lib.exp'
15161 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
15162 ;;
15163 esac
15164
15165 hardcode_libdir_separator_CXX=:
15166
15167 # Commands to make compiler produce verbose output that lists
15168 # what "hidden" libraries, object files and flags are used when
15169 # linking a shared library.
15170 #
15171 # There doesn't appear to be a way to prevent this compiler from
15172 # explicitly linking system object files so we need to strip them
15173 # from the output so that they don't get included in the library
15174 # dependencies.
15175 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
15176 ;;
15177 *)
15178 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
15179 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
15180 case $host in
15181 osf3*)
15182 archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
15183 ;;
15184 *)
15185 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
15186 ;;
15187 esac
15188
15189 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
15190 hardcode_libdir_separator_CXX=:
15191
15192 # Commands to make compiler produce verbose output that lists
15193 # what "hidden" libraries, object files and flags are used when
15194 # linking a shared library.
15195 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
15196
15197 else
15198 # FIXME: insert proper C++ library support
15199 ld_shlibs_CXX=no
15200 fi
15201 ;;
15202 esac
15203 ;;
15204
15205 psos*)
15206 # FIXME: insert proper C++ library support
15207 ld_shlibs_CXX=no
15208 ;;
15209
15210 sunos4*)
15211 case $cc_basename in
15212 CC*)
15213 # Sun C++ 4.x
15214 # FIXME: insert proper C++ library support
15215 ld_shlibs_CXX=no
15216 ;;
15217 lcc*)
15218 # Lucid
15219 # FIXME: insert proper C++ library support
15220 ld_shlibs_CXX=no
15221 ;;
15222 *)
15223 # FIXME: insert proper C++ library support
15224 ld_shlibs_CXX=no
15225 ;;
15226 esac
15227 ;;
15228
15229 solaris*)
15230 case $cc_basename in
15231 CC* | sunCC*)
15232 # Sun C++ 4.2, 5.x and Centerline C++
15233 archive_cmds_need_lc_CXX=yes
15234 no_undefined_flag_CXX=' -zdefs'
15235 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
15236 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
15237 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
15238
15239 hardcode_libdir_flag_spec_CXX='-R$libdir'
15240 hardcode_shlibpath_var_CXX=no
15241 case $host_os in
15242 solaris2.[0-5] | solaris2.[0-5].*) ;;
15243 *)
15244 # The compiler driver will combine and reorder linker options,
15245 # but understands `-z linker_flag'.
15246 # Supported since Solaris 2.6 (maybe 2.5.1?)
15247 whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
15248 ;;
15249 esac
15250 link_all_deplibs_CXX=yes
15251
15252 output_verbose_link_cmd='func_echo_all'
15253
15254 # Archives containing C++ object files must be created using
15255 # "CC -xar", where "CC" is the Sun C++ compiler. This is
15256 # necessary to make sure instantiated templates are included
15257 # in the archive.
15258 old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
15259 ;;
15260 gcx*)
15261 # Green Hills C++ Compiler
15262 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
15263
15264 # The C++ compiler must be used to create the archive.
15265 old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
15266 ;;
15267 *)
15268 # GNU C++ compiler with Solaris linker
15269 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
15270 no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
15271 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
15272 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
15273 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
15274 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
15275
15276 # Commands to make compiler produce verbose output that lists
15277 # what "hidden" libraries, object files and flags are used when
15278 # linking a shared library.
15279 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
15280 else
15281 # g++ 2.7 appears to require `-G' NOT `-shared' on this
15282 # platform.
15283 archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
15284 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
15285 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
15286
15287 # Commands to make compiler produce verbose output that lists
15288 # what "hidden" libraries, object files and flags are used when
15289 # linking a shared library.
15290 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
15291 fi
15292
15293 hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
15294 case $host_os in
15295 solaris2.[0-5] | solaris2.[0-5].*) ;;
15296 *)
15297 whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
15298 ;;
15299 esac
15300 fi
15301 ;;
15302 esac
15303 ;;
15304
15305 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
15306 no_undefined_flag_CXX='${wl}-z,text'
15307 archive_cmds_need_lc_CXX=no
15308 hardcode_shlibpath_var_CXX=no
15309 runpath_var='LD_RUN_PATH'
15310
15311 case $cc_basename in
15312 CC*)
15313 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15314 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15315 ;;
15316 *)
15317 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15318 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15319 ;;
15320 esac
15321 ;;
15322
15323 sysv5* | sco3.2v5* | sco5v6*)
15324 # Note: We can NOT use -z defs as we might desire, because we do not
15325 # link with -lc, and that would cause any symbols used from libc to
15326 # always be unresolved, which means just about no library would
15327 # ever link correctly. If we're not using GNU ld we use -z text
15328 # though, which does catch some bad symbols but isn't as heavy-handed
15329 # as -z defs.
15330 no_undefined_flag_CXX='${wl}-z,text'
15331 allow_undefined_flag_CXX='${wl}-z,nodefs'
15332 archive_cmds_need_lc_CXX=no
15333 hardcode_shlibpath_var_CXX=no
15334 hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir'
15335 hardcode_libdir_separator_CXX=':'
15336 link_all_deplibs_CXX=yes
15337 export_dynamic_flag_spec_CXX='${wl}-Bexport'
15338 runpath_var='LD_RUN_PATH'
15339
15340 case $cc_basename in
15341 CC*)
15342 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15343 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15344 old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~
15345 '"$old_archive_cmds_CXX"
15346 reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~
15347 '"$reload_cmds_CXX"
15348 ;;
15349 *)
15350 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15351 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15352 ;;
15353 esac
15354 ;;
15355
15356 tandem*)
15357 case $cc_basename in
15358 NCC*)
15359 # NonStop-UX NCC 3.20
15360 # FIXME: insert proper C++ library support
15361 ld_shlibs_CXX=no
15362 ;;
15363 *)
15364 # FIXME: insert proper C++ library support
15365 ld_shlibs_CXX=no
15366 ;;
15367 esac
15368 ;;
15369
15370 vxworks*)
15371 # FIXME: insert proper C++ library support
15372 ld_shlibs_CXX=no
15373 ;;
15374
15375 *)
15376 # FIXME: insert proper C++ library support
15377 ld_shlibs_CXX=no
15378 ;;
15379 esac
15380
15381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
15382 $as_echo "$ld_shlibs_CXX" >&6; }
15383 test "$ld_shlibs_CXX" = no && can_build_shared=no
15384
15385 GCC_CXX="$GXX"
15386 LD_CXX="$LD"
15387
15388 ## CAVEAT EMPTOR:
15389 ## There is no encapsulation within the following macros, do not change
15390 ## the running order or otherwise move them around unless you know exactly
15391 ## what you are doing...
15392 # Dependencies to place before and after the object being linked:
15393 predep_objects_CXX=
15394 postdep_objects_CXX=
15395 predeps_CXX=
15396 postdeps_CXX=
15397 compiler_lib_search_path_CXX=
15398
15399 cat > conftest.$ac_ext <<_LT_EOF
15400 class Foo
15401 {
15402 public:
15403 Foo (void) { a = 0; }
15404 private:
15405 int a;
15406 };
15407 _LT_EOF
15408
15409
15410 _lt_libdeps_save_CFLAGS=$CFLAGS
15411 case "$CC $CFLAGS " in #(
15412 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
15413 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
15414 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
15415 esac
15416
15417 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
15418 (eval $ac_compile) 2>&5
15419 ac_status=$?
15420 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15421 test $ac_status = 0; }; then
15422 # Parse the compiler output and extract the necessary
15423 # objects, libraries and library flags.
15424
15425 # Sentinel used to keep track of whether or not we are before
15426 # the conftest object file.
15427 pre_test_object_deps_done=no
15428
15429 for p in `eval "$output_verbose_link_cmd"`; do
15430 case ${prev}${p} in
15431
15432 -L* | -R* | -l*)
15433 # Some compilers place space between "-{L,R}" and the path.
15434 # Remove the space.
15435 if test $p = "-L" ||
15436 test $p = "-R"; then
15437 prev=$p
15438 continue
15439 fi
15440
15441 # Expand the sysroot to ease extracting the directories later.
15442 if test -z "$prev"; then
15443 case $p in
15444 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
15445 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
15446 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
15447 esac
15448 fi
15449 case $p in
15450 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
15451 esac
15452 if test "$pre_test_object_deps_done" = no; then
15453 case ${prev} in
15454 -L | -R)
15455 # Internal compiler library paths should come after those
15456 # provided the user. The postdeps already come after the
15457 # user supplied libs so there is no need to process them.
15458 if test -z "$compiler_lib_search_path_CXX"; then
15459 compiler_lib_search_path_CXX="${prev}${p}"
15460 else
15461 compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
15462 fi
15463 ;;
15464 # The "-l" case would never come before the object being
15465 # linked, so don't bother handling this case.
15466 esac
15467 else
15468 if test -z "$postdeps_CXX"; then
15469 postdeps_CXX="${prev}${p}"
15470 else
15471 postdeps_CXX="${postdeps_CXX} ${prev}${p}"
15472 fi
15473 fi
15474 prev=
15475 ;;
15476
15477 *.lto.$objext) ;; # Ignore GCC LTO objects
15478 *.$objext)
15479 # This assumes that the test object file only shows up
15480 # once in the compiler output.
15481 if test "$p" = "conftest.$objext"; then
15482 pre_test_object_deps_done=yes
15483 continue
15484 fi
15485
15486 if test "$pre_test_object_deps_done" = no; then
15487 if test -z "$predep_objects_CXX"; then
15488 predep_objects_CXX="$p"
15489 else
15490 predep_objects_CXX="$predep_objects_CXX $p"
15491 fi
15492 else
15493 if test -z "$postdep_objects_CXX"; then
15494 postdep_objects_CXX="$p"
15495 else
15496 postdep_objects_CXX="$postdep_objects_CXX $p"
15497 fi
15498 fi
15499 ;;
15500
15501 *) ;; # Ignore the rest.
15502
15503 esac
15504 done
15505
15506 # Clean up.
15507 rm -f a.out a.exe
15508 else
15509 echo "libtool.m4: error: problem compiling CXX test program"
15510 fi
15511
15512 $RM -f confest.$objext
15513 CFLAGS=$_lt_libdeps_save_CFLAGS
15514
15515 # PORTME: override above test on systems where it is broken
15516 case $host_os in
15517 interix[3-9]*)
15518 # Interix 3.5 installs completely hosed .la files for C++, so rather than
15519 # hack all around it, let's just trust "g++" to DTRT.
15520 predep_objects_CXX=
15521 postdep_objects_CXX=
15522 postdeps_CXX=
15523 ;;
15524
15525 linux*)
15526 case `$CC -V 2>&1 | sed 5q` in
15527 *Sun\ C*)
15528 # Sun C++ 5.9
15529
15530 # The more standards-conforming stlport4 library is
15531 # incompatible with the Cstd library. Avoid specifying
15532 # it if it's in CXXFLAGS. Ignore libCrun as
15533 # -library=stlport4 depends on it.
15534 case " $CXX $CXXFLAGS " in
15535 *" -library=stlport4 "*)
15536 solaris_use_stlport4=yes
15537 ;;
15538 esac
15539
15540 if test "$solaris_use_stlport4" != yes; then
15541 postdeps_CXX='-library=Cstd -library=Crun'
15542 fi
15543 ;;
15544 esac
15545 ;;
15546
15547 solaris*)
15548 case $cc_basename in
15549 CC* | sunCC*)
15550 # The more standards-conforming stlport4 library is
15551 # incompatible with the Cstd library. Avoid specifying
15552 # it if it's in CXXFLAGS. Ignore libCrun as
15553 # -library=stlport4 depends on it.
15554 case " $CXX $CXXFLAGS " in
15555 *" -library=stlport4 "*)
15556 solaris_use_stlport4=yes
15557 ;;
15558 esac
15559
15560 # Adding this requires a known-good setup of shared libraries for
15561 # Sun compiler versions before 5.6, else PIC objects from an old
15562 # archive will be linked into the output, leading to subtle bugs.
15563 if test "$solaris_use_stlport4" != yes; then
15564 postdeps_CXX='-library=Cstd -library=Crun'
15565 fi
15566 ;;
15567 esac
15568 ;;
15569 esac
15570
15571
15572 case " $postdeps_CXX " in
15573 *" -lc "*) archive_cmds_need_lc_CXX=no ;;
15574 esac
15575 compiler_lib_search_dirs_CXX=
15576 if test -n "${compiler_lib_search_path_CXX}"; then
15577 compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
15578 fi
15579
15580
15581
15582
15583
15584
15585
15586
15587
15588
15589
15590
15591
15592
15593
15594
15595
15596
15597
15598
15599
15600
15601
15602
15603
15604
15605
15606
15607
15608
15609
15610 lt_prog_compiler_wl_CXX=
15611 lt_prog_compiler_pic_CXX=
15612 lt_prog_compiler_static_CXX=
15613
15614
15615 # C++ specific cases for pic, static, wl, etc.
15616 if test "$GXX" = yes; then
15617 lt_prog_compiler_wl_CXX='-Wl,'
15618 lt_prog_compiler_static_CXX='-static'
15619
15620 case $host_os in
15621 aix*)
15622 # All AIX code is PIC.
15623 if test "$host_cpu" = ia64; then
15624 # AIX 5 now supports IA64 processor
15625 lt_prog_compiler_static_CXX='-Bstatic'
15626 fi
15627 ;;
15628
15629 amigaos*)
15630 case $host_cpu in
15631 powerpc)
15632 # see comment about AmigaOS4 .so support
15633 lt_prog_compiler_pic_CXX='-fPIC'
15634 ;;
15635 m68k)
15636 # FIXME: we need at least 68020 code to build shared libraries, but
15637 # adding the `-m68020' flag to GCC prevents building anything better,
15638 # like `-m68040'.
15639 lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
15640 ;;
15641 esac
15642 ;;
15643
15644 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
15645 # PIC is the default for these OSes.
15646 ;;
15647 mingw* | cygwin* | os2* | pw32* | cegcc*)
15648 # This hack is so that the source file can tell whether it is being
15649 # built for inclusion in a dll (and should export symbols for example).
15650 # Although the cygwin gcc ignores -fPIC, still need this for old-style
15651 # (--disable-auto-import) libraries
15652 lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
15653 ;;
15654 darwin* | rhapsody*)
15655 # PIC is the default on this platform
15656 # Common symbols not allowed in MH_DYLIB files
15657 lt_prog_compiler_pic_CXX='-fno-common'
15658 ;;
15659 *djgpp*)
15660 # DJGPP does not support shared libraries at all
15661 lt_prog_compiler_pic_CXX=
15662 ;;
15663 haiku*)
15664 # PIC is the default for Haiku.
15665 # The "-static" flag exists, but is broken.
15666 lt_prog_compiler_static_CXX=
15667 ;;
15668 interix[3-9]*)
15669 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
15670 # Instead, we relocate shared libraries at runtime.
15671 ;;
15672 sysv4*MP*)
15673 if test -d /usr/nec; then
15674 lt_prog_compiler_pic_CXX=-Kconform_pic
15675 fi
15676 ;;
15677 hpux*)
15678 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
15679 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
15680 # sets the default TLS model and affects inlining.
15681 case $host_cpu in
15682 hppa*64*)
15683 ;;
15684 *)
15685 lt_prog_compiler_pic_CXX='-fPIC'
15686 ;;
15687 esac
15688 ;;
15689 *qnx* | *nto*)
15690 # QNX uses GNU C++, but need to define -shared option too, otherwise
15691 # it will coredump.
15692 lt_prog_compiler_pic_CXX='-fPIC -shared'
15693 ;;
15694 *)
15695 lt_prog_compiler_pic_CXX='-fPIC'
15696 ;;
15697 esac
15698 else
15699 case $host_os in
15700 aix[4-9]*)
15701 # All AIX code is PIC.
15702 if test "$host_cpu" = ia64; then
15703 # AIX 5 now supports IA64 processor
15704 lt_prog_compiler_static_CXX='-Bstatic'
15705 else
15706 lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
15707 fi
15708 ;;
15709 chorus*)
15710 case $cc_basename in
15711 cxch68*)
15712 # Green Hills C++ Compiler
15713 # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--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"
15714 ;;
15715 esac
15716 ;;
15717 mingw* | cygwin* | os2* | pw32* | cegcc*)
15718 # This hack is so that the source file can tell whether it is being
15719 # built for inclusion in a dll (and should export symbols for example).
15720 lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
15721 ;;
15722 dgux*)
15723 case $cc_basename in
15724 ec++*)
15725 lt_prog_compiler_pic_CXX='-KPIC'
15726 ;;
15727 ghcx*)
15728 # Green Hills C++ Compiler
15729 lt_prog_compiler_pic_CXX='-pic'
15730 ;;
15731 *)
15732 ;;
15733 esac
15734 ;;
15735 freebsd* | dragonfly*)
15736 # FreeBSD uses GNU C++
15737 ;;
15738 hpux9* | hpux10* | hpux11*)
15739 case $cc_basename in
15740 CC*)
15741 lt_prog_compiler_wl_CXX='-Wl,'
15742 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
15743 if test "$host_cpu" != ia64; then
15744 lt_prog_compiler_pic_CXX='+Z'
15745 fi
15746 ;;
15747 aCC*)
15748 lt_prog_compiler_wl_CXX='-Wl,'
15749 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
15750 case $host_cpu in
15751 hppa*64*|ia64*)
15752 # +Z the default
15753 ;;
15754 *)
15755 lt_prog_compiler_pic_CXX='+Z'
15756 ;;
15757 esac
15758 ;;
15759 *)
15760 ;;
15761 esac
15762 ;;
15763 interix*)
15764 # This is c89, which is MS Visual C++ (no shared libs)
15765 # Anyone wants to do a port?
15766 ;;
15767 irix5* | irix6* | nonstopux*)
15768 case $cc_basename in
15769 CC*)
15770 lt_prog_compiler_wl_CXX='-Wl,'
15771 lt_prog_compiler_static_CXX='-non_shared'
15772 # CC pic flag -KPIC is the default.
15773 ;;
15774 *)
15775 ;;
15776 esac
15777 ;;
15778 linux* | k*bsd*-gnu | kopensolaris*-gnu)
15779 case $cc_basename in
15780 KCC*)
15781 # KAI C++ Compiler
15782 lt_prog_compiler_wl_CXX='--backend -Wl,'
15783 lt_prog_compiler_pic_CXX='-fPIC'
15784 ;;
15785 ecpc* )
15786 # old Intel C++ for x86_64 which still supported -KPIC.
15787 lt_prog_compiler_wl_CXX='-Wl,'
15788 lt_prog_compiler_pic_CXX='-KPIC'
15789 lt_prog_compiler_static_CXX='-static'
15790 ;;
15791 icpc* )
15792 # Intel C++, used to be incompatible with GCC.
15793 # ICC 10 doesn't accept -KPIC any more.
15794 lt_prog_compiler_wl_CXX='-Wl,'
15795 lt_prog_compiler_pic_CXX='-fPIC'
15796 lt_prog_compiler_static_CXX='-static'
15797 ;;
15798 pgCC* | pgcpp*)
15799 # Portland Group C++ compiler
15800 lt_prog_compiler_wl_CXX='-Wl,'
15801 lt_prog_compiler_pic_CXX='-fpic'
15802 lt_prog_compiler_static_CXX='-Bstatic'
15803 ;;
15804 cxx*)
15805 # Compaq C++
15806 # Make sure the PIC flag is empty. It appears that all Alpha
15807 # Linux and Compaq Tru64 Unix objects are PIC.
15808 lt_prog_compiler_pic_CXX=
15809 lt_prog_compiler_static_CXX='-non_shared'
15810 ;;
15811 xlc* | xlC* | bgxl[cC]* | mpixl[cC]*)
15812 # IBM XL 8.0, 9.0 on PPC and BlueGene
15813 lt_prog_compiler_wl_CXX='-Wl,'
15814 lt_prog_compiler_pic_CXX='-qpic'
15815 lt_prog_compiler_static_CXX='-qstaticlink'
15816 ;;
15817 *)
15818 case `$CC -V 2>&1 | sed 5q` in
15819 *Sun\ C*)
15820 # Sun C++ 5.9
15821 lt_prog_compiler_pic_CXX='-KPIC'
15822 lt_prog_compiler_static_CXX='-Bstatic'
15823 lt_prog_compiler_wl_CXX='-Qoption ld '
15824 ;;
15825 esac
15826 ;;
15827 esac
15828 ;;
15829 lynxos*)
15830 ;;
15831 m88k*)
15832 ;;
15833 mvs*)
15834 case $cc_basename in
15835 cxx*)
15836 lt_prog_compiler_pic_CXX='-W c,exportall'
15837 ;;
15838 *)
15839 ;;
15840 esac
15841 ;;
15842 netbsd* | netbsdelf*-gnu)
15843 ;;
15844 *qnx* | *nto*)
15845 # QNX uses GNU C++, but need to define -shared option too, otherwise
15846 # it will coredump.
15847 lt_prog_compiler_pic_CXX='-fPIC -shared'
15848 ;;
15849 osf3* | osf4* | osf5*)
15850 case $cc_basename in
15851 KCC*)
15852 lt_prog_compiler_wl_CXX='--backend -Wl,'
15853 ;;
15854 RCC*)
15855 # Rational C++ 2.4.1
15856 lt_prog_compiler_pic_CXX='-pic'
15857 ;;
15858 cxx*)
15859 # Digital/Compaq C++
15860 lt_prog_compiler_wl_CXX='-Wl,'
15861 # Make sure the PIC flag is empty. It appears that all Alpha
15862 # Linux and Compaq Tru64 Unix objects are PIC.
15863 lt_prog_compiler_pic_CXX=
15864 lt_prog_compiler_static_CXX='-non_shared'
15865 ;;
15866 *)
15867 ;;
15868 esac
15869 ;;
15870 psos*)
15871 ;;
15872 solaris*)
15873 case $cc_basename in
15874 CC* | sunCC*)
15875 # Sun C++ 4.2, 5.x and Centerline C++
15876 lt_prog_compiler_pic_CXX='-KPIC'
15877 lt_prog_compiler_static_CXX='-Bstatic'
15878 lt_prog_compiler_wl_CXX='-Qoption ld '
15879 ;;
15880 gcx*)
15881 # Green Hills C++ Compiler
15882 lt_prog_compiler_pic_CXX='-PIC'
15883 ;;
15884 *)
15885 ;;
15886 esac
15887 ;;
15888 sunos4*)
15889 case $cc_basename in
15890 CC*)
15891 # Sun C++ 4.x
15892 lt_prog_compiler_pic_CXX='-pic'
15893 lt_prog_compiler_static_CXX='-Bstatic'
15894 ;;
15895 lcc*)
15896 # Lucid
15897 lt_prog_compiler_pic_CXX='-pic'
15898 ;;
15899 *)
15900 ;;
15901 esac
15902 ;;
15903 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
15904 case $cc_basename in
15905 CC*)
15906 lt_prog_compiler_wl_CXX='-Wl,'
15907 lt_prog_compiler_pic_CXX='-KPIC'
15908 lt_prog_compiler_static_CXX='-Bstatic'
15909 ;;
15910 esac
15911 ;;
15912 tandem*)
15913 case $cc_basename in
15914 NCC*)
15915 # NonStop-UX NCC 3.20
15916 lt_prog_compiler_pic_CXX='-KPIC'
15917 ;;
15918 *)
15919 ;;
15920 esac
15921 ;;
15922 vxworks*)
15923 ;;
15924 *)
15925 lt_prog_compiler_can_build_shared_CXX=no
15926 ;;
15927 esac
15928 fi
15929
15930 case $host_os in
15931 # For platforms which do not support PIC, -DPIC is meaningless:
15932 *djgpp*)
15933 lt_prog_compiler_pic_CXX=
15934 ;;
15935 *)
15936 lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
15937 ;;
15938 esac
15939
15940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
15941 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
15942 if ${lt_cv_prog_compiler_pic_CXX+:} false; then :
15943 $as_echo_n "(cached) " >&6
15944 else
15945 lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX
15946 fi
15947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5
15948 $as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; }
15949 lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX
15950
15951 #
15952 # Check to make sure the PIC flag actually works.
15953 #
15954 if test -n "$lt_prog_compiler_pic_CXX"; then
15955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
15956 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; }
15957 if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then :
15958 $as_echo_n "(cached) " >&6
15959 else
15960 lt_cv_prog_compiler_pic_works_CXX=no
15961 ac_outfile=conftest.$ac_objext
15962 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
15963 lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
15964 # Insert the option either (1) after the last *FLAGS variable, or
15965 # (2) before a word containing "conftest.", or (3) at the end.
15966 # Note that $ac_compile itself does not contain backslashes and begins
15967 # with a dollar sign (not a hyphen), so the echo should work correctly.
15968 # The option is referenced via a variable to avoid confusing sed.
15969 lt_compile=`echo "$ac_compile" | $SED \
15970 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
15971 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
15972 -e 's:$: $lt_compiler_flag:'`
15973 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
15974 (eval "$lt_compile" 2>conftest.err)
15975 ac_status=$?
15976 cat conftest.err >&5
15977 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15978 if (exit $ac_status) && test -s "$ac_outfile"; then
15979 # The compiler can only warn and ignore the option if not recognized
15980 # So say no if there are warnings other than the usual output.
15981 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
15982 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
15983 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
15984 lt_cv_prog_compiler_pic_works_CXX=yes
15985 fi
15986 fi
15987 $RM conftest*
15988
15989 fi
15990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
15991 $as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
15992
15993 if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
15994 case $lt_prog_compiler_pic_CXX in
15995 "" | " "*) ;;
15996 *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
15997 esac
15998 else
15999 lt_prog_compiler_pic_CXX=
16000 lt_prog_compiler_can_build_shared_CXX=no
16001 fi
16002
16003 fi
16004
16005
16006
16007
16008
16009 #
16010 # Check to make sure the static flag actually works.
16011 #
16012 wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
16013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
16014 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
16015 if ${lt_cv_prog_compiler_static_works_CXX+:} false; then :
16016 $as_echo_n "(cached) " >&6
16017 else
16018 lt_cv_prog_compiler_static_works_CXX=no
16019 save_LDFLAGS="$LDFLAGS"
16020 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
16021 echo "$lt_simple_link_test_code" > conftest.$ac_ext
16022 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
16023 # The linker can only warn and ignore the option if not recognized
16024 # So say no if there are warnings
16025 if test -s conftest.err; then
16026 # Append any errors to the config.log.
16027 cat conftest.err 1>&5
16028 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
16029 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
16030 if diff conftest.exp conftest.er2 >/dev/null; then
16031 lt_cv_prog_compiler_static_works_CXX=yes
16032 fi
16033 else
16034 lt_cv_prog_compiler_static_works_CXX=yes
16035 fi
16036 fi
16037 $RM -r conftest*
16038 LDFLAGS="$save_LDFLAGS"
16039
16040 fi
16041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
16042 $as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; }
16043
16044 if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
16045 :
16046 else
16047 lt_prog_compiler_static_CXX=
16048 fi
16049
16050
16051
16052
16053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
16054 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
16055 if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
16056 $as_echo_n "(cached) " >&6
16057 else
16058 lt_cv_prog_compiler_c_o_CXX=no
16059 $RM -r conftest 2>/dev/null
16060 mkdir conftest
16061 cd conftest
16062 mkdir out
16063 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
16064
16065 lt_compiler_flag="-o out/conftest2.$ac_objext"
16066 # Insert the option either (1) after the last *FLAGS variable, or
16067 # (2) before a word containing "conftest.", or (3) at the end.
16068 # Note that $ac_compile itself does not contain backslashes and begins
16069 # with a dollar sign (not a hyphen), so the echo should work correctly.
16070 lt_compile=`echo "$ac_compile" | $SED \
16071 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
16072 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
16073 -e 's:$: $lt_compiler_flag:'`
16074 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
16075 (eval "$lt_compile" 2>out/conftest.err)
16076 ac_status=$?
16077 cat out/conftest.err >&5
16078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16079 if (exit $ac_status) && test -s out/conftest2.$ac_objext
16080 then
16081 # The compiler can only warn and ignore the option if not recognized
16082 # So say no if there are warnings
16083 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
16084 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
16085 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
16086 lt_cv_prog_compiler_c_o_CXX=yes
16087 fi
16088 fi
16089 chmod u+w . 2>&5
16090 $RM conftest*
16091 # SGI C++ compiler will create directory out/ii_files/ for
16092 # template instantiation
16093 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
16094 $RM out/* && rmdir out
16095 cd ..
16096 $RM -r conftest
16097 $RM conftest*
16098
16099 fi
16100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
16101 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
16102
16103
16104
16105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
16106 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
16107 if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
16108 $as_echo_n "(cached) " >&6
16109 else
16110 lt_cv_prog_compiler_c_o_CXX=no
16111 $RM -r conftest 2>/dev/null
16112 mkdir conftest
16113 cd conftest
16114 mkdir out
16115 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
16116
16117 lt_compiler_flag="-o out/conftest2.$ac_objext"
16118 # Insert the option either (1) after the last *FLAGS variable, or
16119 # (2) before a word containing "conftest.", or (3) at the end.
16120 # Note that $ac_compile itself does not contain backslashes and begins
16121 # with a dollar sign (not a hyphen), so the echo should work correctly.
16122 lt_compile=`echo "$ac_compile" | $SED \
16123 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
16124 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
16125 -e 's:$: $lt_compiler_flag:'`
16126 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
16127 (eval "$lt_compile" 2>out/conftest.err)
16128 ac_status=$?
16129 cat out/conftest.err >&5
16130 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16131 if (exit $ac_status) && test -s out/conftest2.$ac_objext
16132 then
16133 # The compiler can only warn and ignore the option if not recognized
16134 # So say no if there are warnings
16135 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
16136 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
16137 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
16138 lt_cv_prog_compiler_c_o_CXX=yes
16139 fi
16140 fi
16141 chmod u+w . 2>&5
16142 $RM conftest*
16143 # SGI C++ compiler will create directory out/ii_files/ for
16144 # template instantiation
16145 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
16146 $RM out/* && rmdir out
16147 cd ..
16148 $RM -r conftest
16149 $RM conftest*
16150
16151 fi
16152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
16153 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
16154
16155
16156
16157
16158 hard_links="nottested"
16159 if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
16160 # do not overwrite the value of need_locks provided by the user
16161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
16162 $as_echo_n "checking if we can lock with hard links... " >&6; }
16163 hard_links=yes
16164 $RM conftest*
16165 ln conftest.a conftest.b 2>/dev/null && hard_links=no
16166 touch conftest.a
16167 ln conftest.a conftest.b 2>&5 || hard_links=no
16168 ln conftest.a conftest.b 2>/dev/null && hard_links=no
16169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
16170 $as_echo "$hard_links" >&6; }
16171 if test "$hard_links" = no; then
16172 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
16173 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
16174 need_locks=warn
16175 fi
16176 else
16177 need_locks=no
16178 fi
16179
16180
16181
16182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
16183 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
16184
16185 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
16186 exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
16187 case $host_os in
16188 aix[4-9]*)
16189 # If we're using GNU nm, then we don't want the "-C" option.
16190 # -C means demangle to AIX nm, but means don't demangle with GNU nm
16191 # Also, AIX nm treats weak defined symbols like other global defined
16192 # symbols, whereas GNU nm marks them as "W".
16193 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
16194 export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
16195 else
16196 export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
16197 fi
16198 ;;
16199 pw32*)
16200 export_symbols_cmds_CXX="$ltdll_cmds"
16201 ;;
16202 cygwin* | mingw* | cegcc*)
16203 case $cc_basename in
16204 cl*)
16205 exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
16206 ;;
16207 *)
16208 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
16209 exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
16210 ;;
16211 esac
16212 ;;
16213 linux* | k*bsd*-gnu | gnu*)
16214 link_all_deplibs_CXX=no
16215 ;;
16216 *)
16217 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
16218 ;;
16219 esac
16220
16221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
16222 $as_echo "$ld_shlibs_CXX" >&6; }
16223 test "$ld_shlibs_CXX" = no && can_build_shared=no
16224
16225 with_gnu_ld_CXX=$with_gnu_ld
16226
16227
16228
16229
16230
16231
16232 #
16233 # Do we need to explicitly link libc?
16234 #
16235 case "x$archive_cmds_need_lc_CXX" in
16236 x|xyes)
16237 # Assume -lc should be added
16238 archive_cmds_need_lc_CXX=yes
16239
16240 if test "$enable_shared" = yes && test "$GCC" = yes; then
16241 case $archive_cmds_CXX in
16242 *'~'*)
16243 # FIXME: we may have to deal with multi-command sequences.
16244 ;;
16245 '$CC '*)
16246 # Test whether the compiler implicitly links with -lc since on some
16247 # systems, -lgcc has to come before -lc. If gcc already passes -lc
16248 # to ld, don't add -lc before -lgcc.
16249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
16250 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
16251 if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then :
16252 $as_echo_n "(cached) " >&6
16253 else
16254 $RM conftest*
16255 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
16256
16257 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
16258 (eval $ac_compile) 2>&5
16259 ac_status=$?
16260 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16261 test $ac_status = 0; } 2>conftest.err; then
16262 soname=conftest
16263 lib=conftest
16264 libobjs=conftest.$ac_objext
16265 deplibs=
16266 wl=$lt_prog_compiler_wl_CXX
16267 pic_flag=$lt_prog_compiler_pic_CXX
16268 compiler_flags=-v
16269 linker_flags=-v
16270 verstring=
16271 output_objdir=.
16272 libname=conftest
16273 lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
16274 allow_undefined_flag_CXX=
16275 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
16276 (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
16277 ac_status=$?
16278 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16279 test $ac_status = 0; }
16280 then
16281 lt_cv_archive_cmds_need_lc_CXX=no
16282 else
16283 lt_cv_archive_cmds_need_lc_CXX=yes
16284 fi
16285 allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
16286 else
16287 cat conftest.err 1>&5
16288 fi
16289 $RM conftest*
16290
16291 fi
16292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5
16293 $as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; }
16294 archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX
16295 ;;
16296 esac
16297 fi
16298 ;;
16299 esac
16300
16301
16302
16303
16304
16305
16306
16307
16308
16309
16310
16311
16312
16313
16314
16315
16316
16317
16318
16319
16320
16321
16322
16323
16324
16325
16326
16327
16328
16329
16330
16331
16332
16333
16334
16335
16336
16337
16338
16339
16340
16341
16342
16343
16344
16345
16346
16347
16348
16349
16350
16351
16352
16353
16354
16355
16356
16357
16358
16359
16360
16361
16362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
16363 $as_echo_n "checking dynamic linker characteristics... " >&6; }
16364
16365 library_names_spec=
16366 libname_spec='lib$name'
16367 soname_spec=
16368 shrext_cmds=".so"
16369 postinstall_cmds=
16370 postuninstall_cmds=
16371 finish_cmds=
16372 finish_eval=
16373 shlibpath_var=
16374 shlibpath_overrides_runpath=unknown
16375 version_type=none
16376 dynamic_linker="$host_os ld.so"
16377 sys_lib_dlsearch_path_spec="/lib /usr/lib"
16378 need_lib_prefix=unknown
16379 hardcode_into_libs=no
16380
16381 # when you set need_version to no, make sure it does not cause -set_version
16382 # flags to be left without arguments
16383 need_version=unknown
16384
16385 case $host_os in
16386 aix3*)
16387 version_type=linux # correct to gnu/linux during the next big refactor
16388 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
16389 shlibpath_var=LIBPATH
16390
16391 # AIX 3 has no versioning support, so we append a major version to the name.
16392 soname_spec='${libname}${release}${shared_ext}$major'
16393 ;;
16394
16395 aix[4-9]*)
16396 version_type=linux # correct to gnu/linux during the next big refactor
16397 need_lib_prefix=no
16398 need_version=no
16399 hardcode_into_libs=yes
16400 if test "$host_cpu" = ia64; then
16401 # AIX 5 supports IA64
16402 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
16403 shlibpath_var=LD_LIBRARY_PATH
16404 else
16405 # With GCC up to 2.95.x, collect2 would create an import file
16406 # for dependence libraries. The import file would start with
16407 # the line `#! .'. This would cause the generated library to
16408 # depend on `.', always an invalid library. This was fixed in
16409 # development snapshots of GCC prior to 3.0.
16410 case $host_os in
16411 aix4 | aix4.[01] | aix4.[01].*)
16412 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
16413 echo ' yes '
16414 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
16415 :
16416 else
16417 can_build_shared=no
16418 fi
16419 ;;
16420 esac
16421 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
16422 # soname into executable. Probably we can add versioning support to
16423 # collect2, so additional links can be useful in future.
16424 if test "$aix_use_runtimelinking" = yes; then
16425 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
16426 # instead of lib<name>.a to let people know that these are not
16427 # typical AIX shared libraries.
16428 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16429 else
16430 # We preserve .a as extension for shared libraries through AIX4.2
16431 # and later when we are not doing run time linking.
16432 library_names_spec='${libname}${release}.a $libname.a'
16433 soname_spec='${libname}${release}${shared_ext}$major'
16434 fi
16435 shlibpath_var=LIBPATH
16436 fi
16437 ;;
16438
16439 amigaos*)
16440 case $host_cpu in
16441 powerpc)
16442 # Since July 2007 AmigaOS4 officially supports .so libraries.
16443 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
16444 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16445 ;;
16446 m68k)
16447 library_names_spec='$libname.ixlibrary $libname.a'
16448 # Create ${libname}_ixlibrary.a entries in /sys/libs.
16449 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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'
16450 ;;
16451 esac
16452 ;;
16453
16454 beos*)
16455 library_names_spec='${libname}${shared_ext}'
16456 dynamic_linker="$host_os ld.so"
16457 shlibpath_var=LIBRARY_PATH
16458 ;;
16459
16460 bsdi[45]*)
16461 version_type=linux # correct to gnu/linux during the next big refactor
16462 need_version=no
16463 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16464 soname_spec='${libname}${release}${shared_ext}$major'
16465 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
16466 shlibpath_var=LD_LIBRARY_PATH
16467 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
16468 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
16469 # the default ld.so.conf also contains /usr/contrib/lib and
16470 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
16471 # libtool to hard-code these into programs
16472 ;;
16473
16474 cygwin* | mingw* | pw32* | cegcc*)
16475 version_type=windows
16476 shrext_cmds=".dll"
16477 need_version=no
16478 need_lib_prefix=no
16479
16480 case $GCC,$cc_basename in
16481 yes,*)
16482 # gcc
16483 library_names_spec='$libname.dll.a'
16484 # DLL is installed to $(libdir)/../bin by postinstall_cmds
16485 postinstall_cmds='base_file=`basename \${file}`~
16486 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
16487 dldir=$destdir/`dirname \$dlpath`~
16488 test -d \$dldir || mkdir -p \$dldir~
16489 $install_prog $dir/$dlname \$dldir/$dlname~
16490 chmod a+x \$dldir/$dlname~
16491 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
16492 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
16493 fi'
16494 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
16495 dlpath=$dir/\$dldll~
16496 $RM \$dlpath'
16497 shlibpath_overrides_runpath=yes
16498
16499 case $host_os in
16500 cygwin*)
16501 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
16502 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
16503
16504 ;;
16505 mingw* | cegcc*)
16506 # MinGW DLLs use traditional 'lib' prefix
16507 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
16508 ;;
16509 pw32*)
16510 # pw32 DLLs use 'pw' prefix rather than 'lib'
16511 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
16512 ;;
16513 esac
16514 dynamic_linker='Win32 ld.exe'
16515 ;;
16516
16517 *,cl*)
16518 # Native MSVC
16519 libname_spec='$name'
16520 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
16521 library_names_spec='${libname}.dll.lib'
16522
16523 case $build_os in
16524 mingw*)
16525 sys_lib_search_path_spec=
16526 lt_save_ifs=$IFS
16527 IFS=';'
16528 for lt_path in $LIB
16529 do
16530 IFS=$lt_save_ifs
16531 # Let DOS variable expansion print the short 8.3 style file name.
16532 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
16533 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
16534 done
16535 IFS=$lt_save_ifs
16536 # Convert to MSYS style.
16537 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
16538 ;;
16539 cygwin*)
16540 # Convert to unix form, then to dos form, then back to unix form
16541 # but this time dos style (no spaces!) so that the unix form looks
16542 # like /cygdrive/c/PROGRA~1:/cygdr...
16543 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
16544 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
16545 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
16546 ;;
16547 *)
16548 sys_lib_search_path_spec="$LIB"
16549 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
16550 # It is most probably a Windows format PATH.
16551 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
16552 else
16553 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
16554 fi
16555 # FIXME: find the short name or the path components, as spaces are
16556 # common. (e.g. "Program Files" -> "PROGRA~1")
16557 ;;
16558 esac
16559
16560 # DLL is installed to $(libdir)/../bin by postinstall_cmds
16561 postinstall_cmds='base_file=`basename \${file}`~
16562 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
16563 dldir=$destdir/`dirname \$dlpath`~
16564 test -d \$dldir || mkdir -p \$dldir~
16565 $install_prog $dir/$dlname \$dldir/$dlname'
16566 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
16567 dlpath=$dir/\$dldll~
16568 $RM \$dlpath'
16569 shlibpath_overrides_runpath=yes
16570 dynamic_linker='Win32 link.exe'
16571 ;;
16572
16573 *)
16574 # Assume MSVC wrapper
16575 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
16576 dynamic_linker='Win32 ld.exe'
16577 ;;
16578 esac
16579 # FIXME: first we should search . and the directory the executable is in
16580 shlibpath_var=PATH
16581 ;;
16582
16583 darwin* | rhapsody*)
16584 dynamic_linker="$host_os dyld"
16585 version_type=darwin
16586 need_lib_prefix=no
16587 need_version=no
16588 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
16589 soname_spec='${libname}${release}${major}$shared_ext'
16590 shlibpath_overrides_runpath=yes
16591 shlibpath_var=DYLD_LIBRARY_PATH
16592 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
16593
16594 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
16595 ;;
16596
16597 dgux*)
16598 version_type=linux # correct to gnu/linux during the next big refactor
16599 need_lib_prefix=no
16600 need_version=no
16601 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
16602 soname_spec='${libname}${release}${shared_ext}$major'
16603 shlibpath_var=LD_LIBRARY_PATH
16604 ;;
16605
16606 freebsd* | dragonfly*)
16607 # DragonFly does not have aout. When/if they implement a new
16608 # versioning mechanism, adjust this.
16609 if test -x /usr/bin/objformat; then
16610 objformat=`/usr/bin/objformat`
16611 else
16612 case $host_os in
16613 freebsd[23].*) objformat=aout ;;
16614 *) objformat=elf ;;
16615 esac
16616 fi
16617 version_type=freebsd-$objformat
16618 case $version_type in
16619 freebsd-elf*)
16620 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
16621 need_version=no
16622 need_lib_prefix=no
16623 ;;
16624 freebsd-*)
16625 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
16626 need_version=yes
16627 ;;
16628 esac
16629 shlibpath_var=LD_LIBRARY_PATH
16630 case $host_os in
16631 freebsd2.*)
16632 shlibpath_overrides_runpath=yes
16633 ;;
16634 freebsd3.[01]* | freebsdelf3.[01]*)
16635 shlibpath_overrides_runpath=yes
16636 hardcode_into_libs=yes
16637 ;;
16638 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
16639 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
16640 shlibpath_overrides_runpath=no
16641 hardcode_into_libs=yes
16642 ;;
16643 *) # from 4.6 on, and DragonFly
16644 shlibpath_overrides_runpath=yes
16645 hardcode_into_libs=yes
16646 ;;
16647 esac
16648 ;;
16649
16650 gnu*)
16651 version_type=linux # correct to gnu/linux during the next big refactor
16652 need_lib_prefix=no
16653 need_version=no
16654 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
16655 soname_spec='${libname}${release}${shared_ext}$major'
16656 shlibpath_var=LD_LIBRARY_PATH
16657 shlibpath_overrides_runpath=no
16658 hardcode_into_libs=yes
16659 ;;
16660
16661 haiku*)
16662 version_type=linux # correct to gnu/linux during the next big refactor
16663 need_lib_prefix=no
16664 need_version=no
16665 dynamic_linker="$host_os runtime_loader"
16666 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
16667 soname_spec='${libname}${release}${shared_ext}$major'
16668 shlibpath_var=LIBRARY_PATH
16669 shlibpath_overrides_runpath=yes
16670 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
16671 hardcode_into_libs=yes
16672 ;;
16673
16674 hpux9* | hpux10* | hpux11*)
16675 # Give a soname corresponding to the major version so that dld.sl refuses to
16676 # link against other versions.
16677 version_type=sunos
16678 need_lib_prefix=no
16679 need_version=no
16680 case $host_cpu in
16681 ia64*)
16682 shrext_cmds='.so'
16683 hardcode_into_libs=yes
16684 dynamic_linker="$host_os dld.so"
16685 shlibpath_var=LD_LIBRARY_PATH
16686 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
16687 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16688 soname_spec='${libname}${release}${shared_ext}$major'
16689 if test "X$HPUX_IA64_MODE" = X32; then
16690 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
16691 else
16692 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
16693 fi
16694 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
16695 ;;
16696 hppa*64*)
16697 shrext_cmds='.sl'
16698 hardcode_into_libs=yes
16699 dynamic_linker="$host_os dld.sl"
16700 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
16701 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
16702 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16703 soname_spec='${libname}${release}${shared_ext}$major'
16704 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
16705 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
16706 ;;
16707 *)
16708 shrext_cmds='.sl'
16709 dynamic_linker="$host_os dld.sl"
16710 shlibpath_var=SHLIB_PATH
16711 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
16712 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16713 soname_spec='${libname}${release}${shared_ext}$major'
16714 ;;
16715 esac
16716 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
16717 postinstall_cmds='chmod 555 $lib'
16718 # or fails outright, so override atomically:
16719 install_override_mode=555
16720 ;;
16721
16722 interix[3-9]*)
16723 version_type=linux # correct to gnu/linux during the next big refactor
16724 need_lib_prefix=no
16725 need_version=no
16726 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
16727 soname_spec='${libname}${release}${shared_ext}$major'
16728 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
16729 shlibpath_var=LD_LIBRARY_PATH
16730 shlibpath_overrides_runpath=no
16731 hardcode_into_libs=yes
16732 ;;
16733
16734 irix5* | irix6* | nonstopux*)
16735 case $host_os in
16736 nonstopux*) version_type=nonstopux ;;
16737 *)
16738 if test "$lt_cv_prog_gnu_ld" = yes; then
16739 version_type=linux # correct to gnu/linux during the next big refactor
16740 else
16741 version_type=irix
16742 fi ;;
16743 esac
16744 need_lib_prefix=no
16745 need_version=no
16746 soname_spec='${libname}${release}${shared_ext}$major'
16747 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
16748 case $host_os in
16749 irix5* | nonstopux*)
16750 libsuff= shlibsuff=
16751 ;;
16752 *)
16753 case $LD in # libtool.m4 will add one of these switches to LD
16754 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
16755 libsuff= shlibsuff= libmagic=32-bit;;
16756 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
16757 libsuff=32 shlibsuff=N32 libmagic=N32;;
16758 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
16759 libsuff=64 shlibsuff=64 libmagic=64-bit;;
16760 *) libsuff= shlibsuff= libmagic=never-match;;
16761 esac
16762 ;;
16763 esac
16764 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
16765 shlibpath_overrides_runpath=no
16766 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
16767 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
16768 hardcode_into_libs=yes
16769 ;;
16770
16771 # No shared lib support for Linux oldld, aout, or coff.
16772 linux*oldld* | linux*aout* | linux*coff*)
16773 dynamic_linker=no
16774 ;;
16775
16776 linux*android*)
16777 version_type=none # Android doesn't support versioned libraries.
16778 need_lib_prefix=no
16779 need_version=no
16780 library_names_spec='$libname$release$shared_ext'
16781 soname_spec='$libname$release$shared_ext'
16782 finish_cmds=
16783 shlibpath_var=LD_LIBRARY_PATH
16784 shlibpath_overrides_runpath=yes
16785
16786 # This implies no fast_install, which is unacceptable.
16787 # Some rework will be needed to allow for fast_install
16788 # before this can be enabled.
16789 hardcode_into_libs=yes
16790
16791 dynamic_linker='Android linker'
16792 # Don't embed -rpath directories since the linker doesn't support them.
16793 hardcode_libdir_flag_spec_CXX='-L$libdir'
16794 ;;
16795
16796 # This must be glibc/ELF.
16797 linux* | k*bsd*-gnu | kopensolaris*-gnu)
16798 version_type=linux # correct to gnu/linux during the next big refactor
16799 need_lib_prefix=no
16800 need_version=no
16801 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16802 soname_spec='${libname}${release}${shared_ext}$major'
16803 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
16804 shlibpath_var=LD_LIBRARY_PATH
16805 shlibpath_overrides_runpath=no
16806
16807 # Some binutils ld are patched to set DT_RUNPATH
16808 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
16809 $as_echo_n "(cached) " >&6
16810 else
16811 lt_cv_shlibpath_overrides_runpath=no
16812 save_LDFLAGS=$LDFLAGS
16813 save_libdir=$libdir
16814 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \
16815 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\""
16816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16817 /* end confdefs.h. */
16818
16819 int
16820 main ()
16821 {
16822
16823 ;
16824 return 0;
16825 }
16826 _ACEOF
16827 if ac_fn_cxx_try_link "$LINENO"; then :
16828 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
16829 lt_cv_shlibpath_overrides_runpath=yes
16830 fi
16831 fi
16832 rm -f core conftest.err conftest.$ac_objext \
16833 conftest$ac_exeext conftest.$ac_ext
16834 LDFLAGS=$save_LDFLAGS
16835 libdir=$save_libdir
16836
16837 fi
16838
16839 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
16840
16841 # This implies no fast_install, which is unacceptable.
16842 # Some rework will be needed to allow for fast_install
16843 # before this can be enabled.
16844 hardcode_into_libs=yes
16845
16846 # Append ld.so.conf contents to the search path
16847 if test -f /etc/ld.so.conf; then
16848 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;s/"//g;/^$/d' | tr '\n' ' '`
16849 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
16850 fi
16851
16852 # We used to test for /lib/ld.so.1 and disable shared libraries on
16853 # powerpc, because MkLinux only supported shared libraries with the
16854 # GNU dynamic linker. Since this was broken with cross compilers,
16855 # most powerpc-linux boxes support dynamic linking these days and
16856 # people can always --disable-shared, the test was removed, and we
16857 # assume the GNU/Linux dynamic linker is in use.
16858 dynamic_linker='GNU/Linux ld.so'
16859 ;;
16860
16861 netbsdelf*-gnu)
16862 version_type=linux
16863 need_lib_prefix=no
16864 need_version=no
16865 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
16866 soname_spec='${libname}${release}${shared_ext}$major'
16867 shlibpath_var=LD_LIBRARY_PATH
16868 shlibpath_overrides_runpath=no
16869 hardcode_into_libs=yes
16870 dynamic_linker='NetBSD ld.elf_so'
16871 ;;
16872
16873 netbsd*)
16874 version_type=sunos
16875 need_lib_prefix=no
16876 need_version=no
16877 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
16878 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
16879 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
16880 dynamic_linker='NetBSD (a.out) ld.so'
16881 else
16882 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
16883 soname_spec='${libname}${release}${shared_ext}$major'
16884 dynamic_linker='NetBSD ld.elf_so'
16885 fi
16886 shlibpath_var=LD_LIBRARY_PATH
16887 shlibpath_overrides_runpath=yes
16888 hardcode_into_libs=yes
16889 ;;
16890
16891 newsos6)
16892 version_type=linux # correct to gnu/linux during the next big refactor
16893 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16894 shlibpath_var=LD_LIBRARY_PATH
16895 shlibpath_overrides_runpath=yes
16896 ;;
16897
16898 *nto* | *qnx*)
16899 version_type=qnx
16900 need_lib_prefix=no
16901 need_version=no
16902 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16903 soname_spec='${libname}${release}${shared_ext}$major'
16904 shlibpath_var=LD_LIBRARY_PATH
16905 shlibpath_overrides_runpath=no
16906 hardcode_into_libs=yes
16907 dynamic_linker='ldqnx.so'
16908 ;;
16909
16910 openbsd*)
16911 version_type=sunos
16912 sys_lib_dlsearch_path_spec="/usr/lib"
16913 need_lib_prefix=no
16914 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
16915 case $host_os in
16916 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
16917 *) need_version=no ;;
16918 esac
16919 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
16920 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
16921 shlibpath_var=LD_LIBRARY_PATH
16922 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
16923 case $host_os in
16924 openbsd2.[89] | openbsd2.[89].*)
16925 shlibpath_overrides_runpath=no
16926 ;;
16927 *)
16928 shlibpath_overrides_runpath=yes
16929 ;;
16930 esac
16931 else
16932 shlibpath_overrides_runpath=yes
16933 fi
16934 ;;
16935
16936 os2*)
16937 libname_spec='$name'
16938 shrext_cmds=".dll"
16939 need_lib_prefix=no
16940 library_names_spec='$libname${shared_ext} $libname.a'
16941 dynamic_linker='OS/2 ld.exe'
16942 shlibpath_var=LIBPATH
16943 ;;
16944
16945 osf3* | osf4* | osf5*)
16946 version_type=osf
16947 need_lib_prefix=no
16948 need_version=no
16949 soname_spec='${libname}${release}${shared_ext}$major'
16950 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16951 shlibpath_var=LD_LIBRARY_PATH
16952 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
16953 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
16954 ;;
16955
16956 rdos*)
16957 dynamic_linker=no
16958 ;;
16959
16960 solaris*)
16961 version_type=linux # correct to gnu/linux during the next big refactor
16962 need_lib_prefix=no
16963 need_version=no
16964 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16965 soname_spec='${libname}${release}${shared_ext}$major'
16966 shlibpath_var=LD_LIBRARY_PATH
16967 shlibpath_overrides_runpath=yes
16968 hardcode_into_libs=yes
16969 # ldd complains unless libraries are executable
16970 postinstall_cmds='chmod +x $lib'
16971 ;;
16972
16973 sunos4*)
16974 version_type=sunos
16975 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
16976 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
16977 shlibpath_var=LD_LIBRARY_PATH
16978 shlibpath_overrides_runpath=yes
16979 if test "$with_gnu_ld" = yes; then
16980 need_lib_prefix=no
16981 fi
16982 need_version=yes
16983 ;;
16984
16985 sysv4 | sysv4.3*)
16986 version_type=linux # correct to gnu/linux during the next big refactor
16987 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16988 soname_spec='${libname}${release}${shared_ext}$major'
16989 shlibpath_var=LD_LIBRARY_PATH
16990 case $host_vendor in
16991 sni)
16992 shlibpath_overrides_runpath=no
16993 need_lib_prefix=no
16994 runpath_var=LD_RUN_PATH
16995 ;;
16996 siemens)
16997 need_lib_prefix=no
16998 ;;
16999 motorola)
17000 need_lib_prefix=no
17001 need_version=no
17002 shlibpath_overrides_runpath=no
17003 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
17004 ;;
17005 esac
17006 ;;
17007
17008 sysv4*MP*)
17009 if test -d /usr/nec ;then
17010 version_type=linux # correct to gnu/linux during the next big refactor
17011 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
17012 soname_spec='$libname${shared_ext}.$major'
17013 shlibpath_var=LD_LIBRARY_PATH
17014 fi
17015 ;;
17016
17017 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
17018 version_type=freebsd-elf
17019 need_lib_prefix=no
17020 need_version=no
17021 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
17022 soname_spec='${libname}${release}${shared_ext}$major'
17023 shlibpath_var=LD_LIBRARY_PATH
17024 shlibpath_overrides_runpath=yes
17025 hardcode_into_libs=yes
17026 if test "$with_gnu_ld" = yes; then
17027 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
17028 else
17029 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
17030 case $host_os in
17031 sco3.2v5*)
17032 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
17033 ;;
17034 esac
17035 fi
17036 sys_lib_dlsearch_path_spec='/usr/lib'
17037 ;;
17038
17039 tpf*)
17040 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
17041 version_type=linux # correct to gnu/linux during the next big refactor
17042 need_lib_prefix=no
17043 need_version=no
17044 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
17045 shlibpath_var=LD_LIBRARY_PATH
17046 shlibpath_overrides_runpath=no
17047 hardcode_into_libs=yes
17048 ;;
17049
17050 uts4*)
17051 version_type=linux # correct to gnu/linux during the next big refactor
17052 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
17053 soname_spec='${libname}${release}${shared_ext}$major'
17054 shlibpath_var=LD_LIBRARY_PATH
17055 ;;
17056
17057 *)
17058 dynamic_linker=no
17059 ;;
17060 esac
17061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
17062 $as_echo "$dynamic_linker" >&6; }
17063 test "$dynamic_linker" = no && can_build_shared=no
17064
17065 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
17066 if test "$GCC" = yes; then
17067 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
17068 fi
17069
17070 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
17071 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
17072 fi
17073 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
17074 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
17075 fi
17076
17077
17078
17079
17080
17081
17082
17083
17084
17085
17086
17087
17088
17089
17090
17091
17092
17093
17094
17095
17096
17097
17098
17099
17100
17101
17102
17103
17104
17105
17106
17107
17108
17109
17110
17111
17112
17113
17114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
17115 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
17116 hardcode_action_CXX=
17117 if test -n "$hardcode_libdir_flag_spec_CXX" ||
17118 test -n "$runpath_var_CXX" ||
17119 test "X$hardcode_automatic_CXX" = "Xyes" ; then
17120
17121 # We can hardcode non-existent directories.
17122 if test "$hardcode_direct_CXX" != no &&
17123 # If the only mechanism to avoid hardcoding is shlibpath_var, we
17124 # have to relink, otherwise we might link with an installed library
17125 # when we should be linking with a yet-to-be-installed one
17126 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
17127 test "$hardcode_minus_L_CXX" != no; then
17128 # Linking always hardcodes the temporary library directory.
17129 hardcode_action_CXX=relink
17130 else
17131 # We can link without hardcoding, and we can hardcode nonexisting dirs.
17132 hardcode_action_CXX=immediate
17133 fi
17134 else
17135 # We cannot hardcode anything, or else we can only hardcode existing
17136 # directories.
17137 hardcode_action_CXX=unsupported
17138 fi
17139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
17140 $as_echo "$hardcode_action_CXX" >&6; }
17141
17142 if test "$hardcode_action_CXX" = relink ||
17143 test "$inherit_rpath_CXX" = yes; then
17144 # Fast installation is not supported
17145 enable_fast_install=no
17146 elif test "$shlibpath_overrides_runpath" = yes ||
17147 test "$enable_shared" = no; then
17148 # Fast installation is not necessary
17149 enable_fast_install=needless
17150 fi
17151
17152
17153
17154
17155
17156
17157
17158 fi # test -n "$compiler"
17159
17160 CC=$lt_save_CC
17161 CFLAGS=$lt_save_CFLAGS
17162 LDCXX=$LD
17163 LD=$lt_save_LD
17164 GCC=$lt_save_GCC
17165 with_gnu_ld=$lt_save_with_gnu_ld
17166 lt_cv_path_LDCXX=$lt_cv_path_LD
17167 lt_cv_path_LD=$lt_save_path_LD
17168 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
17169 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
17170 fi # test "$_lt_caught_CXX_error" != yes
17171
17172 ac_ext=c
17173 ac_cpp='$CPP $CPPFLAGS'
17174 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17175 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17176 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17177
17178
17179
17180
17181
17182
17183
17184
17185
17186
17187
17188
17189
17190
17191
17192 ac_config_commands="$ac_config_commands libtool"
17193
17194
17195
17196
17197 # Only expand once:
17198
17199
17200 if test -n "$ac_tool_prefix"; then
17201 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
17202 set dummy ${ac_tool_prefix}windres; ac_word=$2
17203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17204 $as_echo_n "checking for $ac_word... " >&6; }
17205 if ${ac_cv_prog_RC+:} false; then :
17206 $as_echo_n "(cached) " >&6
17207 else
17208 if test -n "$RC"; then
17209 ac_cv_prog_RC="$RC" # Let the user override the test.
17210 else
17211 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17212 for as_dir in $PATH
17213 do
17214 IFS=$as_save_IFS
17215 test -z "$as_dir" && as_dir=.
17216 for ac_exec_ext in '' $ac_executable_extensions; do
17217 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17218 ac_cv_prog_RC="${ac_tool_prefix}windres"
17219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17220 break 2
17221 fi
17222 done
17223 done
17224 IFS=$as_save_IFS
17225
17226 fi
17227 fi
17228 RC=$ac_cv_prog_RC
17229 if test -n "$RC"; then
17230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
17231 $as_echo "$RC" >&6; }
17232 else
17233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17234 $as_echo "no" >&6; }
17235 fi
17236
17237
17238 fi
17239 if test -z "$ac_cv_prog_RC"; then
17240 ac_ct_RC=$RC
17241 # Extract the first word of "windres", so it can be a program name with args.
17242 set dummy windres; ac_word=$2
17243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17244 $as_echo_n "checking for $ac_word... " >&6; }
17245 if ${ac_cv_prog_ac_ct_RC+:} false; then :
17246 $as_echo_n "(cached) " >&6
17247 else
17248 if test -n "$ac_ct_RC"; then
17249 ac_cv_prog_ac_ct_RC="$ac_ct_RC" # Let the user override the test.
17250 else
17251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17252 for as_dir in $PATH
17253 do
17254 IFS=$as_save_IFS
17255 test -z "$as_dir" && as_dir=.
17256 for ac_exec_ext in '' $ac_executable_extensions; do
17257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17258 ac_cv_prog_ac_ct_RC="windres"
17259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17260 break 2
17261 fi
17262 done
17263 done
17264 IFS=$as_save_IFS
17265
17266 fi
17267 fi
17268 ac_ct_RC=$ac_cv_prog_ac_ct_RC
17269 if test -n "$ac_ct_RC"; then
17270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RC" >&5
17271 $as_echo "$ac_ct_RC" >&6; }
17272 else
17273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17274 $as_echo "no" >&6; }
17275 fi
17276
17277 if test "x$ac_ct_RC" = x; then
17278 RC=""
17279 else
17280 case $cross_compiling:$ac_tool_warned in
17281 yes:)
17282 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17283 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17284 ac_tool_warned=yes ;;
17285 esac
17286 RC=$ac_ct_RC
17287 fi
17288 else
17289 RC="$ac_cv_prog_RC"
17290 fi
17291
17292
17293
17294
17295 # Source file extension for RC test sources.
17296 ac_ext=rc
17297
17298 # Object file extension for compiled RC test sources.
17299 objext=o
17300 objext_RC=$objext
17301
17302 # Code to be used in simple compile tests
17303 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
17304
17305 # Code to be used in simple link tests
17306 lt_simple_link_test_code="$lt_simple_compile_test_code"
17307
17308 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
17309
17310
17311
17312
17313
17314
17315 # If no C compiler was specified, use CC.
17316 LTCC=${LTCC-"$CC"}
17317
17318 # If no C compiler flags were specified, use CFLAGS.
17319 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
17320
17321 # Allow CC to be a program name with arguments.
17322 compiler=$CC
17323
17324
17325 # save warnings/boilerplate of simple test code
17326 ac_outfile=conftest.$ac_objext
17327 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
17328 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
17329 _lt_compiler_boilerplate=`cat conftest.err`
17330 $RM conftest*
17331
17332 ac_outfile=conftest.$ac_objext
17333 echo "$lt_simple_link_test_code" >conftest.$ac_ext
17334 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
17335 _lt_linker_boilerplate=`cat conftest.err`
17336 $RM -r conftest*
17337
17338
17339 # Allow CC to be a program name with arguments.
17340 lt_save_CC="$CC"
17341 lt_save_CFLAGS=$CFLAGS
17342 lt_save_GCC=$GCC
17343 GCC=
17344 CC=${RC-"windres"}
17345 CFLAGS=
17346 compiler=$CC
17347 compiler_RC=$CC
17348 for cc_temp in $compiler""; do
17349 case $cc_temp in
17350 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
17351 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
17352 \-*) ;;
17353 *) break;;
17354 esac
17355 done
17356 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
17357
17358 lt_cv_prog_compiler_c_o_RC=yes
17359
17360 if test -n "$compiler"; then
17361 :
17362
17363
17364
17365 fi
17366
17367 GCC=$lt_save_GCC
17368 ac_ext=c
17369 ac_cpp='$CPP $CPPFLAGS'
17370 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17371 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17372 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17373
17374 CC=$lt_save_CC
17375 CFLAGS=$lt_save_CFLAGS
17376
17377
17378 # For now we hardcode the use of version scripts. It would be better
17379 # to write a test for this or even implement this within libtool.
17380 have_ld_version_script=no
17381 case "${host}" in
17382 *-*-linux*)
17383 have_ld_version_script=yes
17384 ;;
17385 *-*-gnu*)
17386 have_ld_version_script=yes
17387 ;;
17388 *-apple-darwin*)
17389
17390 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
17391
17392
17393 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
17394
17395 ;;
17396 esac
17397
17398 if test "$have_ld_version_script" = "yes"; then
17399 HAVE_LD_VERSION_SCRIPT_TRUE=
17400 HAVE_LD_VERSION_SCRIPT_FALSE='#'
17401 else
17402 HAVE_LD_VERSION_SCRIPT_TRUE='#'
17403 HAVE_LD_VERSION_SCRIPT_FALSE=
17404 fi
17405
17406
17407 GPG_DEFAULT=no
17408 GPGSM_DEFAULT=no
17409 GPGCONF_DEFAULT=no
17410 G13_DEFAULT=no
17411 component_system=None
17412 have_dosish_system=no
17413 have_android_system=no
17414 have_w32_system=no
17415 have_w64_system=no
17416 have_macos_system=no
17417 build_w32_glib=no
17418 build_w32_qt=no
17419 available_languages="cl cpp python qt"
17420 default_languages="cl cpp python qt"
17421 case "${host}" in
17422 x86_64-*mingw32*)
17423 have_w64_system=yes
17424 ;;
17425 *-linux-androideabi)
17426 have_android_system=yes
17427 ;;
17428 *-apple-darwin*)
17429 have_macos_system=yes
17430 ;;
17431 esac
17432 case "${host}" in
17433 *-mingw32*)
17434 have_dosish_system=yes
17435 have_w32_system=yes
17436 GPG_DEFAULT='c:\\gnupg\\gpg.exe'
17437 GPGSM_DEFAULT='c:\\gnupg\\gpgsm.exe'
17438 GPGCONF_DEFAULT='c:\\gnupg\\gpgconf.exe'
17439 G13_DEFAULT='c:\\gnupg\\g13.exe'
17440 #component_system='COM+'
17441
17442 # Check whether --enable-glibtest was given.
17443 if test "${enable_glibtest+set}" = set; then :
17444 enableval=$enable_glibtest;
17445 else
17446 enable_glibtest=yes
17447 fi
17448
17449
17450 pkg_config_args=glib-2.0
17451 for module in .
17452 do
17453 case "$module" in
17454 gmodule)
17455 pkg_config_args="$pkg_config_args gmodule-2.0"
17456 ;;
17457 gmodule-no-export)
17458 pkg_config_args="$pkg_config_args gmodule-no-export-2.0"
17459 ;;
17460 gobject)
17461 pkg_config_args="$pkg_config_args gobject-2.0"
17462 ;;
17463 gthread)
17464 pkg_config_args="$pkg_config_args gthread-2.0"
17465 ;;
17466 esac
17467 done
17468
17469 # Extract the first word of "pkg-config", so it can be a program name with args.
17470 set dummy pkg-config; ac_word=$2
17471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17472 $as_echo_n "checking for $ac_word... " >&6; }
17473 if ${ac_cv_path_PKG_CONFIG+:} false; then :
17474 $as_echo_n "(cached) " >&6
17475 else
17476 case $PKG_CONFIG in
17477 [\\/]* | ?:[\\/]*)
17478 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
17479 ;;
17480 *)
17481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17482 for as_dir in $PATH
17483 do
17484 IFS=$as_save_IFS
17485 test -z "$as_dir" && as_dir=.
17486 for ac_exec_ext in '' $ac_executable_extensions; do
17487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17488 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
17489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17490 break 2
17491 fi
17492 done
17493 done
17494 IFS=$as_save_IFS
17495
17496 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
17497 ;;
17498 esac
17499 fi
17500 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
17501 if test -n "$PKG_CONFIG"; then
17502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
17503 $as_echo "$PKG_CONFIG" >&6; }
17504 else
17505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17506 $as_echo "no" >&6; }
17507 fi
17508
17509
17510
17511 no_glib=""
17512
17513 if test x$PKG_CONFIG != xno ; then
17514 if $PKG_CONFIG --atleast-pkgconfig-version 0.7 ; then
17515 :
17516 else
17517 echo *** pkg-config too old; version 0.7 or better required.
17518 no_glib=yes
17519 PKG_CONFIG=no
17520 fi
17521 else
17522 no_glib=yes
17523 fi
17524
17525 min_glib_version=2.0.0
17526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLIB - version >= $min_glib_version" >&5
17527 $as_echo_n "checking for GLIB - version >= $min_glib_version... " >&6; }
17528
17529 if test x$PKG_CONFIG != xno ; then
17530 ## don't try to run the test against uninstalled libtool libs
17531 if $PKG_CONFIG --uninstalled $pkg_config_args; then
17532 echo "Will use uninstalled version of GLib found in PKG_CONFIG_PATH"
17533 enable_glibtest=no
17534 fi
17535
17536 if $PKG_CONFIG --atleast-version $min_glib_version $pkg_config_args; then
17537 :
17538 else
17539 no_glib=yes
17540 fi
17541 fi
17542
17543 if test x"$no_glib" = x ; then
17544 GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
17545 GOBJECT_QUERY=`$PKG_CONFIG --variable=gobject_query glib-2.0`
17546 GLIB_MKENUMS=`$PKG_CONFIG --variable=glib_mkenums glib-2.0`
17547
17548 GLIB_CFLAGS=`$PKG_CONFIG --cflags $pkg_config_args`
17549 GLIB_LIBS=`$PKG_CONFIG --libs $pkg_config_args`
17550 glib_config_major_version=`$PKG_CONFIG --modversion glib-2.0 | \
17551 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
17552 glib_config_minor_version=`$PKG_CONFIG --modversion glib-2.0 | \
17553 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
17554 glib_config_micro_version=`$PKG_CONFIG --modversion glib-2.0 | \
17555 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
17556 if test "x$enable_glibtest" = "xyes" ; then
17557 ac_save_CFLAGS="$CFLAGS"
17558 ac_save_LIBS="$LIBS"
17559 CFLAGS="$CFLAGS $GLIB_CFLAGS"
17560 LIBS="$GLIB_LIBS $LIBS"
17561 rm -f conf.glibtest
17562 if test "$cross_compiling" = yes; then :
17563 echo $ac_n "cross compiling; assumed OK... $ac_c"
17564 else
17565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17566 /* end confdefs.h. */
17567
17568 #include <glib.h>
17569 #include <stdio.h>
17570 #include <stdlib.h>
17571
17572 int
17573 main ()
17574 {
17575 int major, minor, micro;
17576 char *tmp_version;
17577
17578 system ("touch conf.glibtest");
17579
17580 /* HP/UX 9 (%@#!) writes to sscanf strings */
17581 tmp_version = g_strdup("$min_glib_version");
17582 if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
17583 printf("%s, bad version string\n", "$min_glib_version");
17584 exit(1);
17585 }
17586
17587 if ((glib_major_version != $glib_config_major_version) ||
17588 (glib_minor_version != $glib_config_minor_version) ||
17589 (glib_micro_version != $glib_config_micro_version))
17590 {
17591 printf("\n*** 'pkg-config --modversion glib-2.0' returned %d.%d.%d, but GLIB (%d.%d.%d)\n",
17592 $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version,
17593 glib_major_version, glib_minor_version, glib_micro_version);
17594 printf ("*** was found! If pkg-config was correct, then it is best\n");
17595 printf ("*** to remove the old version of GLib. You may also be able to fix the error\n");
17596 printf("*** by modifying your LD_LIBRARY_PATH environment variable, or by editing\n");
17597 printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
17598 printf("*** required on your system.\n");
17599 printf("*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH\n");
17600 printf("*** to point to the correct configuration files\n");
17601 }
17602 else if ((glib_major_version != GLIB_MAJOR_VERSION) ||
17603 (glib_minor_version != GLIB_MINOR_VERSION) ||
17604 (glib_micro_version != GLIB_MICRO_VERSION))
17605 {
17606 printf("*** GLIB header files (version %d.%d.%d) do not match\n",
17607 GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION);
17608 printf("*** library (version %d.%d.%d)\n",
17609 glib_major_version, glib_minor_version, glib_micro_version);
17610 }
17611 else
17612 {
17613 if ((glib_major_version > major) ||
17614 ((glib_major_version == major) && (glib_minor_version > minor)) ||
17615 ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro)))
17616 {
17617 return 0;
17618 }
17619 else
17620 {
17621 printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n",
17622 glib_major_version, glib_minor_version, glib_micro_version);
17623 printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n",
17624 major, minor, micro);
17625 printf("*** GLIB is always available from ftp://ftp.gtk.org.\n");
17626 printf("***\n");
17627 printf("*** If you have already installed a sufficiently new version, this error\n");
17628 printf("*** probably means that the wrong copy of the pkg-config shell script is\n");
17629 printf("*** being found. The easiest way to fix this is to remove the old version\n");
17630 printf("*** of GLIB, but you can also set the PKG_CONFIG environment to point to the\n");
17631 printf("*** correct copy of pkg-config. (In this case, you will have to\n");
17632 printf("*** modify your LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf\n");
17633 printf("*** so that the correct libraries are found at run-time))\n");
17634 }
17635 }
17636 return 1;
17637 }
17638
17639 _ACEOF
17640 if ac_fn_c_try_run "$LINENO"; then :
17641
17642 else
17643 no_glib=yes
17644 fi
17645 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17646 conftest.$ac_objext conftest.beam conftest.$ac_ext
17647 fi
17648
17649 CFLAGS="$ac_save_CFLAGS"
17650 LIBS="$ac_save_LIBS"
17651 fi
17652 fi
17653 if test "x$no_glib" = x ; then
17654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version)" >&5
17655 $as_echo "yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version)" >&6; }
17656 :
17657 else
17658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17659 $as_echo "no" >&6; }
17660 if test "$PKG_CONFIG" = "no" ; then
17661 echo "*** A new enough version of pkg-config was not found."
17662 echo "*** See https://www.freedesktop.org/software/pkgconfig/"
17663 else
17664 if test -f conf.glibtest ; then
17665 :
17666 else
17667 echo "*** Could not run GLIB test program, checking why..."
17668 ac_save_CFLAGS="$CFLAGS"
17669 ac_save_LIBS="$LIBS"
17670 CFLAGS="$CFLAGS $GLIB_CFLAGS"
17671 LIBS="$LIBS $GLIB_LIBS"
17672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17673 /* end confdefs.h. */
17674
17675 #include <glib.h>
17676 #include <stdio.h>
17677
17678 int
17679 main ()
17680 {
17681 return ((glib_major_version) || (glib_minor_version) || (glib_micro_version));
17682 ;
17683 return 0;
17684 }
17685 _ACEOF
17686 if ac_fn_c_try_link "$LINENO"; then :
17687 echo "*** The test program compiled, but did not run. This usually means"
17688 echo "*** that the run-time linker is not finding GLIB or finding the wrong"
17689 echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your"
17690 echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
17691 echo "*** to the installed location Also, make sure you have run ldconfig if that"
17692 echo "*** is required on your system"
17693 echo "***"
17694 echo "*** If you have an old version installed, it is best to remove it, although"
17695 echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
17696 else
17697 echo "*** The test program failed to compile or link. See the file config.log for the"
17698 echo "*** exact error that occurred. This usually means GLIB is incorrectly installed."
17699 fi
17700 rm -f core conftest.err conftest.$ac_objext \
17701 conftest$ac_exeext conftest.$ac_ext
17702 CFLAGS="$ac_save_CFLAGS"
17703 LIBS="$ac_save_LIBS"
17704 fi
17705 fi
17706 GLIB_CFLAGS=""
17707 GLIB_LIBS=""
17708 GLIB_GENMARSHAL=""
17709 GOBJECT_QUERY=""
17710 GLIB_MKENUMS=""
17711 :
17712 fi
17713
17714
17715
17716
17717
17718 rm -f conf.glibtest
17719
17720 # Check whether --enable-w32-glib was given.
17721 if test "${enable_w32_glib+set}" = set; then :
17722 enableval=$enable_w32_glib; build_w32_glib=$enableval
17723 fi
17724
17725 ;;
17726 *)
17727
17728 # XXX: Probably use exec-prefix here?
17729 # GPG_DEFAULT='/usr/bin/gpg'
17730 # GPGSM_DEFAULT='/usr/bin/gpgsm'
17731 # GPGCONF_DEFAULT='/usr/bin/gpgconf'
17732 # G13_DEFAULT='/usr/bin/g13'
17733 ;;
17734 esac
17735
17736 if test "$have_dosish_system" = yes; then
17737
17738 $as_echo "#define HAVE_DOSISH_SYSTEM 1" >>confdefs.h
17739
17740 fi
17741 if test "$have_dosish_system" = yes; then
17742 HAVE_DOSISH_SYSTEM_TRUE=
17743 HAVE_DOSISH_SYSTEM_FALSE='#'
17744 else
17745 HAVE_DOSISH_SYSTEM_TRUE='#'
17746 HAVE_DOSISH_SYSTEM_FALSE=
17747 fi
17748
17749
17750 if test "$have_w32_system" = yes; then
17751
17752 $as_echo "#define HAVE_W32_SYSTEM 1" >>confdefs.h
17753
17754 fi
17755 if test "$have_w32_system" = yes; then
17756 HAVE_W32_SYSTEM_TRUE=
17757 HAVE_W32_SYSTEM_FALSE='#'
17758 else
17759 HAVE_W32_SYSTEM_TRUE='#'
17760 HAVE_W32_SYSTEM_FALSE=
17761 fi
17762
17763
17764 if test "$have_w64_system" = yes; then
17765
17766 $as_echo "#define HAVE_W64_SYSTEM 1" >>confdefs.h
17767
17768 fi
17769 if test "$have_w64_system" = yes; then
17770 HAVE_W64_SYSTEM_TRUE=
17771 HAVE_W64_SYSTEM_FALSE='#'
17772 else
17773 HAVE_W64_SYSTEM_TRUE='#'
17774 HAVE_W64_SYSTEM_FALSE=
17775 fi
17776
17777
17778 if test "$have_android_system" = yes; then
17779
17780 $as_echo "#define HAVE_ANDROID_SYSTEM 1" >>confdefs.h
17781
17782 fi
17783 if test "$have_android_system" = yes; then
17784 HAVE_ANDROID_SYSTEM_TRUE=
17785 HAVE_ANDROID_SYSTEM_FALSE='#'
17786 else
17787 HAVE_ANDROID_SYSTEM_TRUE='#'
17788 HAVE_ANDROID_SYSTEM_FALSE=
17789 fi
17790
17791
17792 if test "$have_macos_system" = yes; then
17793
17794 $as_echo "#define HAVE_MACOS_SYSTEM 1" >>confdefs.h
17795
17796 fi
17797 if test "$have_macos_system" = yes; then
17798 HAVE_MACOS_SYSTEM_TRUE=
17799 HAVE_MACOS_SYSTEM_FALSE='#'
17800 else
17801 HAVE_MACOS_SYSTEM_TRUE='#'
17802 HAVE_MACOS_SYSTEM_FALSE=
17803 fi
17804
17805
17806 if test "$build_w32_glib" = yes; then
17807 BUILD_W32_GLIB_TRUE=
17808 BUILD_W32_GLIB_FALSE='#'
17809 else
17810 BUILD_W32_GLIB_TRUE='#'
17811 BUILD_W32_GLIB_FALSE=
17812 fi
17813
17814
17815
17816 # Check whether --enable-fixed-path was given.
17817 if test "${enable_fixed_path+set}" = set; then :
17818 enableval=$enable_fixed_path; fixed_search_path="$enableval"
17819 else
17820 fixed_search_path=""
17821 fi
17822
17823 if test x$fixed_search_path != x ; then
17824
17825 cat >>confdefs.h <<_ACEOF
17826 #define FIXED_SEARCH_PATH "$fixed_search_path"
17827 _ACEOF
17828
17829 fi
17830
17831
17832 # Note: You need to declare all possible languages also in
17833 # lang/Makefile.am's DIST_SUBDIRS.
17834 # Check whether --enable-languages was given.
17835 if test "${enable_languages+set}" = set; then :
17836 enableval=$enable_languages; enabled_languages=`echo $enableval | \
17837 tr ',:' ' ' | tr 'A-Z' 'a-z' | \
17838 sed 's/c++/cpp/'`
17839 else
17840 enabled_languages="maybe"
17841 fi
17842
17843 if test "x$enabled_languages" = "x" \
17844 -o "$enabled_languages" = "no"; then
17845 enabled_languages=
17846 fi
17847
17848 # If languages are explicitly set missing requirements
17849 # for the languages are treated as errors otherwise
17850 # there will be a warning.
17851 explicit_languages=1
17852 if test "x$enabled_languages" = "xmaybe"; then
17853 explicit_languages=0
17854 enabled_languages="$default_languages"
17855 fi
17856
17857 for language in $enabled_languages; do
17858
17859 name=$language
17860 list=$available_languages
17861 found=0
17862
17863 for n in $list; do
17864 if test "x$name" = "x$n"; then
17865 found=1
17866 fi
17867 done
17868
17869 if test "$found" = "0"; then
17870 as_fn_error $? "unsupported language binding specified" "$LINENO" 5
17871 fi
17872 done
17873
17874
17875
17876 # Enable C++ 11 if cpp language is requested
17877
17878 name="cpp"
17879 list=$enabled_languages
17880 found=0
17881
17882 for n in $list; do
17883 if test "x$name" = "x$n"; then
17884 found=1
17885 fi
17886 done
17887
17888 if test "$found" = "1"; then
17889 ax_cxx_compile_cxx11_required=false
17890 ac_ext=cpp
17891 ac_cpp='$CXXCPP $CPPFLAGS'
17892 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17893 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17894 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
17895 ac_success=no
17896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
17897 $as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
17898 if ${ax_cv_cxx_compile_cxx11+:} false; then :
17899 $as_echo_n "(cached) " >&6
17900 else
17901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17902 /* end confdefs.h. */
17903
17904
17905 // If the compiler admits that it is not ready for C++11, why torture it?
17906 // Hopefully, this will speed up the test.
17907
17908 #ifndef __cplusplus
17909
17910 #error "This is not a C++ compiler"
17911
17912 #elif __cplusplus < 201103L
17913
17914 #error "This is not a C++11 compiler"
17915
17916 #else
17917
17918 namespace cxx11
17919 {
17920
17921 namespace test_static_assert
17922 {
17923
17924 template <typename T>
17925 struct check
17926 {
17927 static_assert(sizeof(int) <= sizeof(T), "not big enough");
17928 };
17929
17930 }
17931
17932 namespace test_final_override
17933 {
17934
17935 struct Base
17936 {
17937 virtual void f() {}
17938 };
17939
17940 struct Derived : public Base
17941 {
17942 virtual void f() override {}
17943 };
17944
17945 }
17946
17947 namespace test_double_right_angle_brackets
17948 {
17949
17950 template < typename T >
17951 struct check {};
17952
17953 typedef check<void> single_type;
17954 typedef check<check<void>> double_type;
17955 typedef check<check<check<void>>> triple_type;
17956 typedef check<check<check<check<void>>>> quadruple_type;
17957
17958 }
17959
17960 namespace test_decltype
17961 {
17962
17963 int
17964 f()
17965 {
17966 int a = 1;
17967 decltype(a) b = 2;
17968 return a + b;
17969 }
17970
17971 }
17972
17973 namespace test_type_deduction
17974 {
17975
17976 template < typename T1, typename T2 >
17977 struct is_same
17978 {
17979 static const bool value = false;
17980 };
17981
17982 template < typename T >
17983 struct is_same<T, T>
17984 {
17985 static const bool value = true;
17986 };
17987
17988 template < typename T1, typename T2 >
17989 auto
17990 add(T1 a1, T2 a2) -> decltype(a1 + a2)
17991 {
17992 return a1 + a2;
17993 }
17994
17995 int
17996 test(const int c, volatile int v)
17997 {
17998 static_assert(is_same<int, decltype(0)>::value == true, "");
17999 static_assert(is_same<int, decltype(c)>::value == false, "");
18000 static_assert(is_same<int, decltype(v)>::value == false, "");
18001 auto ac = c;
18002 auto av = v;
18003 auto sumi = ac + av + 'x';
18004 auto sumf = ac + av + 1.0;
18005 static_assert(is_same<int, decltype(ac)>::value == true, "");
18006 static_assert(is_same<int, decltype(av)>::value == true, "");
18007 static_assert(is_same<int, decltype(sumi)>::value == true, "");
18008 static_assert(is_same<int, decltype(sumf)>::value == false, "");
18009 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
18010 return (sumf > 0.0) ? sumi : add(c, v);
18011 }
18012
18013 }
18014
18015 namespace test_noexcept
18016 {
18017
18018 int f() { return 0; }
18019 int g() noexcept { return 0; }
18020
18021 static_assert(noexcept(f()) == false, "");
18022 static_assert(noexcept(g()) == true, "");
18023
18024 }
18025
18026 namespace test_constexpr
18027 {
18028
18029 template < typename CharT >
18030 unsigned long constexpr
18031 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
18032 {
18033 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
18034 }
18035
18036 template < typename CharT >
18037 unsigned long constexpr
18038 strlen_c(const CharT *const s) noexcept
18039 {
18040 return strlen_c_r(s, 0UL);
18041 }
18042
18043 static_assert(strlen_c("") == 0UL, "");
18044 static_assert(strlen_c("1") == 1UL, "");
18045 static_assert(strlen_c("example") == 7UL, "");
18046 static_assert(strlen_c("another\0example") == 7UL, "");
18047
18048 }
18049
18050 namespace test_rvalue_references
18051 {
18052
18053 template < int N >
18054 struct answer
18055 {
18056 static constexpr int value = N;
18057 };
18058
18059 answer<1> f(int&) { return answer<1>(); }
18060 answer<2> f(const int&) { return answer<2>(); }
18061 answer<3> f(int&&) { return answer<3>(); }
18062
18063 void
18064 test()
18065 {
18066 int i = 0;
18067 const int c = 0;
18068 static_assert(decltype(f(i))::value == 1, "");
18069 static_assert(decltype(f(c))::value == 2, "");
18070 static_assert(decltype(f(0))::value == 3, "");
18071 }
18072
18073 }
18074
18075 namespace test_uniform_initialization
18076 {
18077
18078 struct test
18079 {
18080 static const int zero {};
18081 static const int one {1};
18082 };
18083
18084 static_assert(test::zero == 0, "");
18085 static_assert(test::one == 1, "");
18086
18087 }
18088
18089 namespace test_lambdas
18090 {
18091
18092 void
18093 test1()
18094 {
18095 auto lambda1 = [](){};
18096 auto lambda2 = lambda1;
18097 lambda1();
18098 lambda2();
18099 }
18100
18101 int
18102 test2()
18103 {
18104 auto a = [](int i, int j){ return i + j; }(1, 2);
18105 auto b = []() -> int { return '0'; }();
18106 auto c = [=](){ return a + b; }();
18107 auto d = [&](){ return c; }();
18108 auto e = [a, &b](int x) mutable {
18109 const auto identity = [](int y){ return y; };
18110 for (auto i = 0; i < a; ++i)
18111 a += b--;
18112 return x + identity(a + b);
18113 }(0);
18114 return a + b + c + d + e;
18115 }
18116
18117 int
18118 test3()
18119 {
18120 const auto nullary = [](){ return 0; };
18121 const auto unary = [](int x){ return x; };
18122 using nullary_t = decltype(nullary);
18123 using unary_t = decltype(unary);
18124 const auto higher1st = [](nullary_t f){ return f(); };
18125 const auto higher2nd = [unary](nullary_t f1){
18126 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
18127 };
18128 return higher1st(nullary) + higher2nd(nullary)(unary);
18129 }
18130
18131 }
18132
18133 namespace test_variadic_templates
18134 {
18135
18136 template <int...>
18137 struct sum;
18138
18139 template <int N0, int... N1toN>
18140 struct sum<N0, N1toN...>
18141 {
18142 static constexpr auto value = N0 + sum<N1toN...>::value;
18143 };
18144
18145 template <>
18146 struct sum<>
18147 {
18148 static constexpr auto value = 0;
18149 };
18150
18151 static_assert(sum<>::value == 0, "");
18152 static_assert(sum<1>::value == 1, "");
18153 static_assert(sum<23>::value == 23, "");
18154 static_assert(sum<1, 2>::value == 3, "");
18155 static_assert(sum<5, 5, 11>::value == 21, "");
18156 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
18157
18158 }
18159
18160 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
18161 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
18162 // because of this.
18163 namespace test_template_alias_sfinae
18164 {
18165
18166 struct foo {};
18167
18168 template<typename T>
18169 using member = typename T::member_type;
18170
18171 template<typename T>
18172 void func(...) {}
18173
18174 template<typename T>
18175 void func(member<T>*) {}
18176
18177 void test();
18178
18179 void test() { func<foo>(0); }
18180
18181 }
18182
18183 } // namespace cxx11
18184
18185 #endif // __cplusplus >= 201103L
18186
18187
18188
18189 _ACEOF
18190 if ac_fn_cxx_try_compile "$LINENO"; then :
18191 ax_cv_cxx_compile_cxx11=yes
18192 else
18193 ax_cv_cxx_compile_cxx11=no
18194 fi
18195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18196 fi
18197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
18198 $as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
18199 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
18200 ac_success=yes
18201 fi
18202
18203
18204
18205 if test x$ac_success = xno; then
18206 for switch in -std=c++11 -std=c++0x +std=c++11 "-h std=c++11"; do
18207 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
18208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
18209 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
18210 if eval \${$cachevar+:} false; then :
18211 $as_echo_n "(cached) " >&6
18212 else
18213 ac_save_CXX="$CXX"
18214 CXX="$CXX $switch"
18215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18216 /* end confdefs.h. */
18217
18218
18219 // If the compiler admits that it is not ready for C++11, why torture it?
18220 // Hopefully, this will speed up the test.
18221
18222 #ifndef __cplusplus
18223
18224 #error "This is not a C++ compiler"
18225
18226 #elif __cplusplus < 201103L
18227
18228 #error "This is not a C++11 compiler"
18229
18230 #else
18231
18232 namespace cxx11
18233 {
18234
18235 namespace test_static_assert
18236 {
18237
18238 template <typename T>
18239 struct check
18240 {
18241 static_assert(sizeof(int) <= sizeof(T), "not big enough");
18242 };
18243
18244 }
18245
18246 namespace test_final_override
18247 {
18248
18249 struct Base
18250 {
18251 virtual void f() {}
18252 };
18253
18254 struct Derived : public Base
18255 {
18256 virtual void f() override {}
18257 };
18258
18259 }
18260
18261 namespace test_double_right_angle_brackets
18262 {
18263
18264 template < typename T >
18265 struct check {};
18266
18267 typedef check<void> single_type;
18268 typedef check<check<void>> double_type;
18269 typedef check<check<check<void>>> triple_type;
18270 typedef check<check<check<check<void>>>> quadruple_type;
18271
18272 }
18273
18274 namespace test_decltype
18275 {
18276
18277 int
18278 f()
18279 {
18280 int a = 1;
18281 decltype(a) b = 2;
18282 return a + b;
18283 }
18284
18285 }
18286
18287 namespace test_type_deduction
18288 {
18289
18290 template < typename T1, typename T2 >
18291 struct is_same
18292 {
18293 static const bool value = false;
18294 };
18295
18296 template < typename T >
18297 struct is_same<T, T>
18298 {
18299 static const bool value = true;
18300 };
18301
18302 template < typename T1, typename T2 >
18303 auto
18304 add(T1 a1, T2 a2) -> decltype(a1 + a2)
18305 {
18306 return a1 + a2;
18307 }
18308
18309 int
18310 test(const int c, volatile int v)
18311 {
18312 static_assert(is_same<int, decltype(0)>::value == true, "");
18313 static_assert(is_same<int, decltype(c)>::value == false, "");
18314 static_assert(is_same<int, decltype(v)>::value == false, "");
18315 auto ac = c;
18316 auto av = v;
18317 auto sumi = ac + av + 'x';
18318 auto sumf = ac + av + 1.0;
18319 static_assert(is_same<int, decltype(ac)>::value == true, "");
18320 static_assert(is_same<int, decltype(av)>::value == true, "");
18321 static_assert(is_same<int, decltype(sumi)>::value == true, "");
18322 static_assert(is_same<int, decltype(sumf)>::value == false, "");
18323 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
18324 return (sumf > 0.0) ? sumi : add(c, v);
18325 }
18326
18327 }
18328
18329 namespace test_noexcept
18330 {
18331
18332 int f() { return 0; }
18333 int g() noexcept { return 0; }
18334
18335 static_assert(noexcept(f()) == false, "");
18336 static_assert(noexcept(g()) == true, "");
18337
18338 }
18339
18340 namespace test_constexpr
18341 {
18342
18343 template < typename CharT >
18344 unsigned long constexpr
18345 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
18346 {
18347 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
18348 }
18349
18350 template < typename CharT >
18351 unsigned long constexpr
18352 strlen_c(const CharT *const s) noexcept
18353 {
18354 return strlen_c_r(s, 0UL);
18355 }
18356
18357 static_assert(strlen_c("") == 0UL, "");
18358 static_assert(strlen_c("1") == 1UL, "");
18359 static_assert(strlen_c("example") == 7UL, "");
18360 static_assert(strlen_c("another\0example") == 7UL, "");
18361
18362 }
18363
18364 namespace test_rvalue_references
18365 {
18366
18367 template < int N >
18368 struct answer
18369 {
18370 static constexpr int value = N;
18371 };
18372
18373 answer<1> f(int&) { return answer<1>(); }
18374 answer<2> f(const int&) { return answer<2>(); }
18375 answer<3> f(int&&) { return answer<3>(); }
18376
18377 void
18378 test()
18379 {
18380 int i = 0;
18381 const int c = 0;
18382 static_assert(decltype(f(i))::value == 1, "");
18383 static_assert(decltype(f(c))::value == 2, "");
18384 static_assert(decltype(f(0))::value == 3, "");
18385 }
18386
18387 }
18388
18389 namespace test_uniform_initialization
18390 {
18391
18392 struct test
18393 {
18394 static const int zero {};
18395 static const int one {1};
18396 };
18397
18398 static_assert(test::zero == 0, "");
18399 static_assert(test::one == 1, "");
18400
18401 }
18402
18403 namespace test_lambdas
18404 {
18405
18406 void
18407 test1()
18408 {
18409 auto lambda1 = [](){};
18410 auto lambda2 = lambda1;
18411 lambda1();
18412 lambda2();
18413 }
18414
18415 int
18416 test2()
18417 {
18418 auto a = [](int i, int j){ return i + j; }(1, 2);
18419 auto b = []() -> int { return '0'; }();
18420 auto c = [=](){ return a + b; }();
18421 auto d = [&](){ return c; }();
18422 auto e = [a, &b](int x) mutable {
18423 const auto identity = [](int y){ return y; };
18424 for (auto i = 0; i < a; ++i)
18425 a += b--;
18426 return x + identity(a + b);
18427 }(0);
18428 return a + b + c + d + e;
18429 }
18430
18431 int
18432 test3()
18433 {
18434 const auto nullary = [](){ return 0; };
18435 const auto unary = [](int x){ return x; };
18436 using nullary_t = decltype(nullary);
18437 using unary_t = decltype(unary);
18438 const auto higher1st = [](nullary_t f){ return f(); };
18439 const auto higher2nd = [unary](nullary_t f1){
18440 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
18441 };
18442 return higher1st(nullary) + higher2nd(nullary)(unary);
18443 }
18444
18445 }
18446
18447 namespace test_variadic_templates
18448 {
18449
18450 template <int...>
18451 struct sum;
18452
18453 template <int N0, int... N1toN>
18454 struct sum<N0, N1toN...>
18455 {
18456 static constexpr auto value = N0 + sum<N1toN...>::value;
18457 };
18458
18459 template <>
18460 struct sum<>
18461 {
18462 static constexpr auto value = 0;
18463 };
18464
18465 static_assert(sum<>::value == 0, "");
18466 static_assert(sum<1>::value == 1, "");
18467 static_assert(sum<23>::value == 23, "");
18468 static_assert(sum<1, 2>::value == 3, "");
18469 static_assert(sum<5, 5, 11>::value == 21, "");
18470 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
18471
18472 }
18473
18474 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
18475 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
18476 // because of this.
18477 namespace test_template_alias_sfinae
18478 {
18479
18480 struct foo {};
18481
18482 template<typename T>
18483 using member = typename T::member_type;
18484
18485 template<typename T>
18486 void func(...) {}
18487
18488 template<typename T>
18489 void func(member<T>*) {}
18490
18491 void test();
18492
18493 void test() { func<foo>(0); }
18494
18495 }
18496
18497 } // namespace cxx11
18498
18499 #endif // __cplusplus >= 201103L
18500
18501
18502
18503 _ACEOF
18504 if ac_fn_cxx_try_compile "$LINENO"; then :
18505 eval $cachevar=yes
18506 else
18507 eval $cachevar=no
18508 fi
18509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18510 CXX="$ac_save_CXX"
18511 fi
18512 eval ac_res=\$$cachevar
18513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18514 $as_echo "$ac_res" >&6; }
18515 if eval test x\$$cachevar = xyes; then
18516 CXX="$CXX $switch"
18517 CXXCPP="$CXXCPP $switch"
18518 ac_success=yes
18519 break
18520 fi
18521 done
18522 fi
18523 ac_ext=c
18524 ac_cpp='$CPP $CPPFLAGS'
18525 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18526 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18527 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18528
18529 if test x$ax_cxx_compile_cxx11_required = xtrue; then
18530 if test x$ac_success = xno; then
18531 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
18532 fi
18533 fi
18534 if test x$ac_success = xno; then
18535 HAVE_CXX11=0
18536 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
18537 $as_echo "$as_me: No compiler with C++11 support was found" >&6;}
18538 else
18539 HAVE_CXX11=1
18540
18541 $as_echo "#define HAVE_CXX11 1" >>confdefs.h
18542
18543 fi
18544
18545
18546 if test "$HAVE_CXX11" != "1"; then
18547 if test "$explicit_languages" = "1"; then
18548 as_fn_error $? "
18549 ***
18550 *** A compiler with c++11 support is required for the c++ binding.
18551 ***" "$LINENO" 5
18552 else
18553 enabled_languages=$(echo $enabled_languages | sed 's/cpp//')
18554 enabled_languages=$(echo $enabled_languages | sed 's/qt//')
18555 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
18556 ***
18557 *** No c++11 support detected. C++ and Qt bindings will be disabled.
18558 ***" >&5
18559 $as_echo "$as_me: WARNING:
18560 ***
18561 *** No c++11 support detected. C++ and Qt bindings will be disabled.
18562 ***" >&2;}
18563 fi
18564 fi
18565 fi
18566
18567 # Check that if qt is enabled cpp also is enabled
18568
18569 name="qt"
18570 list=$enabled_languages
18571 found=0
18572
18573 for n in $list; do
18574 if test "x$name" = "x$n"; then
18575 found=1
18576 fi
18577 done
18578
18579 if test "$found" = "1"; then
18580 # We need to ensure that in the language order qt comes after cpp
18581 # so we remove qt first and explicitly add it as last list member.
18582 enabled_languages=$(echo $enabled_languages | sed 's/qt//')
18583
18584 name="cpp"
18585 list=$enabled_languages
18586 found=0
18587
18588 for n in $list; do
18589 if test "x$name" = "x$n"; then
18590 found=1
18591 fi
18592 done
18593
18594 if test "$found" = "0"; then
18595 as_fn_error $? "
18596 ***
18597 *** Qt language binding depends on cpp binding.
18598 ***" "$LINENO" 5
18599 fi
18600
18601
18602 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
18603 if test -n "$ac_tool_prefix"; then
18604 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
18605 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
18606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18607 $as_echo_n "checking for $ac_word... " >&6; }
18608 if ${ac_cv_path_PKG_CONFIG+:} false; then :
18609 $as_echo_n "(cached) " >&6
18610 else
18611 case $PKG_CONFIG in
18612 [\\/]* | ?:[\\/]*)
18613 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
18614 ;;
18615 *)
18616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18617 for as_dir in $PATH
18618 do
18619 IFS=$as_save_IFS
18620 test -z "$as_dir" && as_dir=.
18621 for ac_exec_ext in '' $ac_executable_extensions; do
18622 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18623 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
18624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18625 break 2
18626 fi
18627 done
18628 done
18629 IFS=$as_save_IFS
18630
18631 ;;
18632 esac
18633 fi
18634 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
18635 if test -n "$PKG_CONFIG"; then
18636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
18637 $as_echo "$PKG_CONFIG" >&6; }
18638 else
18639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18640 $as_echo "no" >&6; }
18641 fi
18642
18643
18644 fi
18645 if test -z "$ac_cv_path_PKG_CONFIG"; then
18646 ac_pt_PKG_CONFIG=$PKG_CONFIG
18647 # Extract the first word of "pkg-config", so it can be a program name with args.
18648 set dummy pkg-config; ac_word=$2
18649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18650 $as_echo_n "checking for $ac_word... " >&6; }
18651 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
18652 $as_echo_n "(cached) " >&6
18653 else
18654 case $ac_pt_PKG_CONFIG in
18655 [\\/]* | ?:[\\/]*)
18656 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
18657 ;;
18658 *)
18659 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18660 for as_dir in $PATH
18661 do
18662 IFS=$as_save_IFS
18663 test -z "$as_dir" && as_dir=.
18664 for ac_exec_ext in '' $ac_executable_extensions; do
18665 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18666 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
18667 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18668 break 2
18669 fi
18670 done
18671 done
18672 IFS=$as_save_IFS
18673
18674 ;;
18675 esac
18676 fi
18677 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
18678 if test -n "$ac_pt_PKG_CONFIG"; then
18679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
18680 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
18681 else
18682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18683 $as_echo "no" >&6; }
18684 fi
18685
18686 if test "x$ac_pt_PKG_CONFIG" = x; then
18687 PKG_CONFIG=""
18688 else
18689 case $cross_compiling:$ac_tool_warned in
18690 yes:)
18691 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18692 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18693 ac_tool_warned=yes ;;
18694 esac
18695 PKG_CONFIG=$ac_pt_PKG_CONFIG
18696 fi
18697 else
18698 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
18699 fi
18700
18701 fi
18702 if test -n "$PKG_CONFIG"; then
18703 _pkg_min_version=0.9.0
18704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
18705 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
18706 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
18707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18708 $as_echo "yes" >&6; }
18709 else
18710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18711 $as_echo "no" >&6; }
18712 PKG_CONFIG=""
18713 fi
18714
18715 fi
18716
18717 have_qt5_libs="no";
18718
18719
18720 pkg_failed=no
18721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GPGME_QT" >&5
18722 $as_echo_n "checking for GPGME_QT... " >&6; }
18723
18724 if test -n "$PKG_CONFIG"; then
18725 if test -n "$GPGME_QT_CFLAGS"; then
18726 pkg_cv_GPGME_QT_CFLAGS="$GPGME_QT_CFLAGS"
18727 else
18728 if test -n "$PKG_CONFIG" && \
18729 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Qt5Core >= 5.0.0\""; } >&5
18730 ($PKG_CONFIG --exists --print-errors "Qt5Core >= 5.0.0") 2>&5
18731 ac_status=$?
18732 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18733 test $ac_status = 0; }; then
18734 pkg_cv_GPGME_QT_CFLAGS=`$PKG_CONFIG --cflags "Qt5Core >= 5.0.0" 2>/dev/null`
18735 else
18736 pkg_failed=yes
18737 fi
18738 fi
18739 else
18740 pkg_failed=untried
18741 fi
18742 if test -n "$PKG_CONFIG"; then
18743 if test -n "$GPGME_QT_LIBS"; then
18744 pkg_cv_GPGME_QT_LIBS="$GPGME_QT_LIBS"
18745 else
18746 if test -n "$PKG_CONFIG" && \
18747 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Qt5Core >= 5.0.0\""; } >&5
18748 ($PKG_CONFIG --exists --print-errors "Qt5Core >= 5.0.0") 2>&5
18749 ac_status=$?
18750 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18751 test $ac_status = 0; }; then
18752 pkg_cv_GPGME_QT_LIBS=`$PKG_CONFIG --libs "Qt5Core >= 5.0.0" 2>/dev/null`
18753 else
18754 pkg_failed=yes
18755 fi
18756 fi
18757 else
18758 pkg_failed=untried
18759 fi
18760
18761
18762
18763 if test $pkg_failed = yes; then
18764
18765 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
18766 _pkg_short_errors_supported=yes
18767 else
18768 _pkg_short_errors_supported=no
18769 fi
18770 if test $_pkg_short_errors_supported = yes; then
18771 GPGME_QT_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "Qt5Core >= 5.0.0"`
18772 else
18773 GPGME_QT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "Qt5Core >= 5.0.0"`
18774 fi
18775 # Put the nasty error message in config.log where it belongs
18776 echo "$GPGME_QT_PKG_ERRORS" >&5
18777
18778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18779 $as_echo "no" >&6; }
18780 have_qt5_libs="no"
18781 elif test $pkg_failed = untried; then
18782 have_qt5_libs="no"
18783 else
18784 GPGME_QT_CFLAGS=$pkg_cv_GPGME_QT_CFLAGS
18785 GPGME_QT_LIBS=$pkg_cv_GPGME_QT_LIBS
18786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18787 $as_echo "yes" >&6; }
18788 have_qt5_libs="yes"
18789 fi
18790
18791
18792 pkg_failed=no
18793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GPGME_QTTEST" >&5
18794 $as_echo_n "checking for GPGME_QTTEST... " >&6; }
18795
18796 if test -n "$PKG_CONFIG"; then
18797 if test -n "$GPGME_QTTEST_CFLAGS"; then
18798 pkg_cv_GPGME_QTTEST_CFLAGS="$GPGME_QTTEST_CFLAGS"
18799 else
18800 if test -n "$PKG_CONFIG" && \
18801 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Qt5Test >= 5.0.0\""; } >&5
18802 ($PKG_CONFIG --exists --print-errors "Qt5Test >= 5.0.0") 2>&5
18803 ac_status=$?
18804 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18805 test $ac_status = 0; }; then
18806 pkg_cv_GPGME_QTTEST_CFLAGS=`$PKG_CONFIG --cflags "Qt5Test >= 5.0.0" 2>/dev/null`
18807 else
18808 pkg_failed=yes
18809 fi
18810 fi
18811 else
18812 pkg_failed=untried
18813 fi
18814 if test -n "$PKG_CONFIG"; then
18815 if test -n "$GPGME_QTTEST_LIBS"; then
18816 pkg_cv_GPGME_QTTEST_LIBS="$GPGME_QTTEST_LIBS"
18817 else
18818 if test -n "$PKG_CONFIG" && \
18819 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Qt5Test >= 5.0.0\""; } >&5
18820 ($PKG_CONFIG --exists --print-errors "Qt5Test >= 5.0.0") 2>&5
18821 ac_status=$?
18822 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18823 test $ac_status = 0; }; then
18824 pkg_cv_GPGME_QTTEST_LIBS=`$PKG_CONFIG --libs "Qt5Test >= 5.0.0" 2>/dev/null`
18825 else
18826 pkg_failed=yes
18827 fi
18828 fi
18829 else
18830 pkg_failed=untried
18831 fi
18832
18833
18834
18835 if test $pkg_failed = yes; then
18836
18837 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
18838 _pkg_short_errors_supported=yes
18839 else
18840 _pkg_short_errors_supported=no
18841 fi
18842 if test $_pkg_short_errors_supported = yes; then
18843 GPGME_QTTEST_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "Qt5Test >= 5.0.0"`
18844 else
18845 GPGME_QTTEST_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "Qt5Test >= 5.0.0"`
18846 fi
18847 # Put the nasty error message in config.log where it belongs
18848 echo "$GPGME_QTTEST_PKG_ERRORS" >&5
18849
18850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18851 $as_echo "no" >&6; }
18852 have_qt5test_libs="no"
18853 elif test $pkg_failed = untried; then
18854 have_qt5test_libs="no"
18855 else
18856 GPGME_QTTEST_CFLAGS=$pkg_cv_GPGME_QTTEST_CFLAGS
18857 GPGME_QTTEST_LIBS=$pkg_cv_GPGME_QTTEST_LIBS
18858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18859 $as_echo "yes" >&6; }
18860 have_qt5test_libs="yes"
18861 fi
18862
18863 if ! test "$have_w32_system" = yes; then
18864 if "$PKG_CONFIG" --variable qt_config Qt5Core | grep -q "reduce_relocations"; then
18865 GPGME_QT_CFLAGS="$GPGME_QT_CFLAGS -fpic"
18866 fi
18867 fi
18868 if test "$have_qt5_libs" = "yes"; then
18869 if test -n "$ac_tool_prefix"; then
18870 # Extract the first word of "${ac_tool_prefix}moc", so it can be a program name with args.
18871 set dummy ${ac_tool_prefix}moc; ac_word=$2
18872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18873 $as_echo_n "checking for $ac_word... " >&6; }
18874 if ${ac_cv_prog_MOC+:} false; then :
18875 $as_echo_n "(cached) " >&6
18876 else
18877 if test -n "$MOC"; then
18878 ac_cv_prog_MOC="$MOC" # Let the user override the test.
18879 else
18880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18881 for as_dir in $PATH
18882 do
18883 IFS=$as_save_IFS
18884 test -z "$as_dir" && as_dir=.
18885 for ac_exec_ext in '' $ac_executable_extensions; do
18886 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18887 ac_cv_prog_MOC="${ac_tool_prefix}moc"
18888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18889 break 2
18890 fi
18891 done
18892 done
18893 IFS=$as_save_IFS
18894
18895 fi
18896 fi
18897 MOC=$ac_cv_prog_MOC
18898 if test -n "$MOC"; then
18899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MOC" >&5
18900 $as_echo "$MOC" >&6; }
18901 else
18902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18903 $as_echo "no" >&6; }
18904 fi
18905
18906
18907 fi
18908 if test -z "$ac_cv_prog_MOC"; then
18909 ac_ct_MOC=$MOC
18910 # Extract the first word of "moc", so it can be a program name with args.
18911 set dummy moc; ac_word=$2
18912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18913 $as_echo_n "checking for $ac_word... " >&6; }
18914 if ${ac_cv_prog_ac_ct_MOC+:} false; then :
18915 $as_echo_n "(cached) " >&6
18916 else
18917 if test -n "$ac_ct_MOC"; then
18918 ac_cv_prog_ac_ct_MOC="$ac_ct_MOC" # Let the user override the test.
18919 else
18920 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18921 for as_dir in $PATH
18922 do
18923 IFS=$as_save_IFS
18924 test -z "$as_dir" && as_dir=.
18925 for ac_exec_ext in '' $ac_executable_extensions; do
18926 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18927 ac_cv_prog_ac_ct_MOC="moc"
18928 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18929 break 2
18930 fi
18931 done
18932 done
18933 IFS=$as_save_IFS
18934
18935 fi
18936 fi
18937 ac_ct_MOC=$ac_cv_prog_ac_ct_MOC
18938 if test -n "$ac_ct_MOC"; then
18939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MOC" >&5
18940 $as_echo "$ac_ct_MOC" >&6; }
18941 else
18942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18943 $as_echo "no" >&6; }
18944 fi
18945
18946 if test "x$ac_ct_MOC" = x; then
18947 MOC=""
18948 else
18949 case $cross_compiling:$ac_tool_warned in
18950 yes:)
18951 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18952 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18953 ac_tool_warned=yes ;;
18954 esac
18955 MOC=$ac_ct_MOC
18956 fi
18957 else
18958 MOC="$ac_cv_prog_MOC"
18959 fi
18960
18961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking moc version" >&5
18962 $as_echo_n "checking moc version... " >&6; }
18963 mocversion=`$MOC -v 2>&1`
18964 mocversiongrep=`echo $mocversion | grep -E "Qt 5|moc 5"`
18965 if test x"$mocversiongrep" != x"$mocversion"; then
18966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18967 $as_echo "no" >&6; }
18968 # moc was not the qt5 one, try with moc-qt5
18969 if test -n "$ac_tool_prefix"; then
18970 # Extract the first word of "${ac_tool_prefix}moc-qt5", so it can be a program name with args.
18971 set dummy ${ac_tool_prefix}moc-qt5; ac_word=$2
18972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18973 $as_echo_n "checking for $ac_word... " >&6; }
18974 if ${ac_cv_prog_MOC2+:} false; then :
18975 $as_echo_n "(cached) " >&6
18976 else
18977 if test -n "$MOC2"; then
18978 ac_cv_prog_MOC2="$MOC2" # Let the user override the test.
18979 else
18980 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18981 for as_dir in $PATH
18982 do
18983 IFS=$as_save_IFS
18984 test -z "$as_dir" && as_dir=.
18985 for ac_exec_ext in '' $ac_executable_extensions; do
18986 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18987 ac_cv_prog_MOC2="${ac_tool_prefix}moc-qt5"
18988 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18989 break 2
18990 fi
18991 done
18992 done
18993 IFS=$as_save_IFS
18994
18995 fi
18996 fi
18997 MOC2=$ac_cv_prog_MOC2
18998 if test -n "$MOC2"; then
18999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MOC2" >&5
19000 $as_echo "$MOC2" >&6; }
19001 else
19002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19003 $as_echo "no" >&6; }
19004 fi
19005
19006
19007 fi
19008 if test -z "$ac_cv_prog_MOC2"; then
19009 ac_ct_MOC2=$MOC2
19010 # Extract the first word of "moc-qt5", so it can be a program name with args.
19011 set dummy moc-qt5; ac_word=$2
19012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19013 $as_echo_n "checking for $ac_word... " >&6; }
19014 if ${ac_cv_prog_ac_ct_MOC2+:} false; then :
19015 $as_echo_n "(cached) " >&6
19016 else
19017 if test -n "$ac_ct_MOC2"; then
19018 ac_cv_prog_ac_ct_MOC2="$ac_ct_MOC2" # Let the user override the test.
19019 else
19020 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19021 for as_dir in $PATH
19022 do
19023 IFS=$as_save_IFS
19024 test -z "$as_dir" && as_dir=.
19025 for ac_exec_ext in '' $ac_executable_extensions; do
19026 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19027 ac_cv_prog_ac_ct_MOC2="moc-qt5"
19028 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19029 break 2
19030 fi
19031 done
19032 done
19033 IFS=$as_save_IFS
19034
19035 fi
19036 fi
19037 ac_ct_MOC2=$ac_cv_prog_ac_ct_MOC2
19038 if test -n "$ac_ct_MOC2"; then
19039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MOC2" >&5
19040 $as_echo "$ac_ct_MOC2" >&6; }
19041 else
19042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19043 $as_echo "no" >&6; }
19044 fi
19045
19046 if test "x$ac_ct_MOC2" = x; then
19047 MOC2=""
19048 else
19049 case $cross_compiling:$ac_tool_warned in
19050 yes:)
19051 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19052 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19053 ac_tool_warned=yes ;;
19054 esac
19055 MOC2=$ac_ct_MOC2
19056 fi
19057 else
19058 MOC2="$ac_cv_prog_MOC2"
19059 fi
19060
19061 mocversion=`$MOC2 -v 2>&1`
19062 mocversiongrep=`echo $mocversion | grep -E "Qt 5|moc-qt5 5|moc 5"`
19063 if test x"$mocversiongrep" != x"$mocversion"; then
19064 if test -n "$ac_tool_prefix"; then
19065 # Extract the first word of "${ac_tool_prefix}qtchooser", so it can be a program name with args.
19066 set dummy ${ac_tool_prefix}qtchooser; ac_word=$2
19067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19068 $as_echo_n "checking for $ac_word... " >&6; }
19069 if ${ac_cv_prog_QTCHOOSER+:} false; then :
19070 $as_echo_n "(cached) " >&6
19071 else
19072 if test -n "$QTCHOOSER"; then
19073 ac_cv_prog_QTCHOOSER="$QTCHOOSER" # Let the user override the test.
19074 else
19075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19076 for as_dir in $PATH
19077 do
19078 IFS=$as_save_IFS
19079 test -z "$as_dir" && as_dir=.
19080 for ac_exec_ext in '' $ac_executable_extensions; do
19081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19082 ac_cv_prog_QTCHOOSER="${ac_tool_prefix}qtchooser"
19083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19084 break 2
19085 fi
19086 done
19087 done
19088 IFS=$as_save_IFS
19089
19090 fi
19091 fi
19092 QTCHOOSER=$ac_cv_prog_QTCHOOSER
19093 if test -n "$QTCHOOSER"; then
19094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $QTCHOOSER" >&5
19095 $as_echo "$QTCHOOSER" >&6; }
19096 else
19097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19098 $as_echo "no" >&6; }
19099 fi
19100
19101
19102 fi
19103 if test -z "$ac_cv_prog_QTCHOOSER"; then
19104 ac_ct_QTCHOOSER=$QTCHOOSER
19105 # Extract the first word of "qtchooser", so it can be a program name with args.
19106 set dummy qtchooser; ac_word=$2
19107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19108 $as_echo_n "checking for $ac_word... " >&6; }
19109 if ${ac_cv_prog_ac_ct_QTCHOOSER+:} false; then :
19110 $as_echo_n "(cached) " >&6
19111 else
19112 if test -n "$ac_ct_QTCHOOSER"; then
19113 ac_cv_prog_ac_ct_QTCHOOSER="$ac_ct_QTCHOOSER" # Let the user override the test.
19114 else
19115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19116 for as_dir in $PATH
19117 do
19118 IFS=$as_save_IFS
19119 test -z "$as_dir" && as_dir=.
19120 for ac_exec_ext in '' $ac_executable_extensions; do
19121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19122 ac_cv_prog_ac_ct_QTCHOOSER="qtchooser"
19123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19124 break 2
19125 fi
19126 done
19127 done
19128 IFS=$as_save_IFS
19129
19130 fi
19131 fi
19132 ac_ct_QTCHOOSER=$ac_cv_prog_ac_ct_QTCHOOSER
19133 if test -n "$ac_ct_QTCHOOSER"; then
19134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_QTCHOOSER" >&5
19135 $as_echo "$ac_ct_QTCHOOSER" >&6; }
19136 else
19137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19138 $as_echo "no" >&6; }
19139 fi
19140
19141 if test "x$ac_ct_QTCHOOSER" = x; then
19142 QTCHOOSER=""
19143 else
19144 case $cross_compiling:$ac_tool_warned in
19145 yes:)
19146 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19147 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19148 ac_tool_warned=yes ;;
19149 esac
19150 QTCHOOSER=$ac_ct_QTCHOOSER
19151 fi
19152 else
19153 QTCHOOSER="$ac_cv_prog_QTCHOOSER"
19154 fi
19155
19156 qt5tooldir=`QT_SELECT=qt5 qtchooser -print-env | grep QTTOOLDIR | cut -d '=' -f 2 | cut -d \" -f 2`
19157 mocversion=`$qt5tooldir/moc -v 2>&1`
19158 mocversiongrep=`echo $mocversion | grep -E "Qt 5|moc 5"`
19159 if test x"$mocversiongrep" != x"$mocversion"; then
19160 # no valid moc found
19161 have_qt5_libs="no";
19162 else
19163 MOC=$qt5tooldir/moc
19164 fi
19165 else
19166 MOC=$MOC2
19167 fi
19168 fi
19169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $mocversion" >&5
19170 $as_echo "$mocversion" >&6; }
19171 OLDCPPFLAGS=$CPPFLAGS
19172 CPPFLAGS=$GPGME_QT_CFLAGS
19173 OLDLIBS=$LIBS
19174 LIBS=$GPGME_QT_LIBS
19175 ac_ext=cpp
19176 ac_cpp='$CXXCPP $CPPFLAGS'
19177 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
19178 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19179 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
19180
19181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a simple qt program can be built" >&5
19182 $as_echo_n "checking whether a simple qt program can be built... " >&6; }
19183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19184 /* end confdefs.h. */
19185
19186 #include <QCoreApplication>
19187 int main (int argc, char **argv) {
19188 QCoreApplication app(argc, argv);
19189 app.exec();
19190 }
19191 _ACEOF
19192 if ac_fn_cxx_try_link "$LINENO"; then :
19193 have_qt5_libs='yes'
19194 else
19195 have_qt5_libs='no'
19196 fi
19197 rm -f core conftest.err conftest.$ac_objext \
19198 conftest$ac_exeext conftest.$ac_ext
19199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_qt5_libs" >&5
19200 $as_echo "$have_qt5_libs" >&6; }
19201 ac_ext=c
19202 ac_cpp='$CPP $CPPFLAGS'
19203 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
19204 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19205 ac_compiler_gnu=$ac_cv_c_compiler_gnu
19206
19207 CPPFLAGS=$OLDCPPFLAGS
19208 LIBS=$OLDLIBS
19209 fi
19210
19211 if test "$have_qt5_libs" != "yes"; then
19212 if test "$explicit_languages" = "1"; then
19213 as_fn_error $? "
19214 ***
19215 *** Qt5 (Qt5Core) is required for Qt binding.
19216 ***" "$LINENO" 5
19217 else
19218 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
19219 ***
19220 *** Qt5 (Qt5Core) not found Qt Binding will be disabled.
19221 ***" >&5
19222 $as_echo "$as_me: WARNING:
19223 ***
19224 *** Qt5 (Qt5Core) not found Qt Binding will be disabled.
19225 ***" >&2;}
19226 fi
19227 else
19228 enabled_languages=`echo $enabled_languages qt`
19229
19230 for ac_prog in doxygen
19231 do
19232 # Extract the first word of "$ac_prog", so it can be a program name with args.
19233 set dummy $ac_prog; ac_word=$2
19234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19235 $as_echo_n "checking for $ac_word... " >&6; }
19236 if ${ac_cv_prog_DOXYGEN+:} false; then :
19237 $as_echo_n "(cached) " >&6
19238 else
19239 if test -n "$DOXYGEN"; then
19240 ac_cv_prog_DOXYGEN="$DOXYGEN" # Let the user override the test.
19241 else
19242 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19243 for as_dir in $PATH
19244 do
19245 IFS=$as_save_IFS
19246 test -z "$as_dir" && as_dir=.
19247 for ac_exec_ext in '' $ac_executable_extensions; do
19248 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19249 ac_cv_prog_DOXYGEN="$ac_prog"
19250 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19251 break 2
19252 fi
19253 done
19254 done
19255 IFS=$as_save_IFS
19256
19257 fi
19258 fi
19259 DOXYGEN=$ac_cv_prog_DOXYGEN
19260 if test -n "$DOXYGEN"; then
19261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOXYGEN" >&5
19262 $as_echo "$DOXYGEN" >&6; }
19263 else
19264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19265 $as_echo "no" >&6; }
19266 fi
19267
19268
19269 test -n "$DOXYGEN" && break
19270 done
19271
19272 if test -z "$DOXYGEN";
19273 # This is not highlighted because it's not really important.
19274 then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Doxygen not found - Qt binding doc will not be built." >&5
19275 $as_echo "$as_me: WARNING: Doxygen not found - Qt binding doc will not be built." >&2;}
19276 fi
19277 for ac_prog in dot
19278 do
19279 # Extract the first word of "$ac_prog", so it can be a program name with args.
19280 set dummy $ac_prog; ac_word=$2
19281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19282 $as_echo_n "checking for $ac_word... " >&6; }
19283 if ${ac_cv_prog_GRAPHVIZ+:} false; then :
19284 $as_echo_n "(cached) " >&6
19285 else
19286 if test -n "$GRAPHVIZ"; then
19287 ac_cv_prog_GRAPHVIZ="$GRAPHVIZ" # Let the user override the test.
19288 else
19289 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19290 for as_dir in $PATH
19291 do
19292 IFS=$as_save_IFS
19293 test -z "$as_dir" && as_dir=.
19294 for ac_exec_ext in '' $ac_executable_extensions; do
19295 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19296 ac_cv_prog_GRAPHVIZ="$ac_prog"
19297 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19298 break 2
19299 fi
19300 done
19301 done
19302 IFS=$as_save_IFS
19303
19304 fi
19305 fi
19306 GRAPHVIZ=$ac_cv_prog_GRAPHVIZ
19307 if test -n "$GRAPHVIZ"; then
19308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GRAPHVIZ" >&5
19309 $as_echo "$GRAPHVIZ" >&6; }
19310 else
19311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19312 $as_echo "no" >&6; }
19313 fi
19314
19315
19316 test -n "$GRAPHVIZ" && break
19317 done
19318
19319 if test -z "$GRAPHVIZ";
19320 then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Graphviz not found - Qt binding doc will not have diagrams." >&5
19321 $as_echo "$as_me: WARNING: Graphviz not found - Qt binding doc will not have diagrams." >&2;}
19322 fi
19323 fi
19324 fi
19325 if test -n "$DOXYGEN"; then
19326 HAVE_DOXYGEN_TRUE=
19327 HAVE_DOXYGEN_FALSE='#'
19328 else
19329 HAVE_DOXYGEN_TRUE='#'
19330 HAVE_DOXYGEN_FALSE=
19331 fi
19332
19333 if test -n "$GRAPHVIZ"; then
19334 HAVE_DOT="YES"
19335 else
19336 HAVE_DOT="NO"
19337 fi
19338
19339
19340 # Python bindings.
19341
19342 name="python"
19343 list=$enabled_languages
19344 found=0
19345
19346 for n in $list; do
19347 if test "x$name" = "x$n"; then
19348 found=1
19349 fi
19350 done
19351
19352 found_py=$found
19353 if test "$found_py" = "1"; then
19354
19355 # Ubuntu has swig 2.0 as /usr/bin/swig2.0
19356 for ac_prog in swig swig2.0
19357 do
19358 # Extract the first word of "$ac_prog", so it can be a program name with args.
19359 set dummy $ac_prog; ac_word=$2
19360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19361 $as_echo_n "checking for $ac_word... " >&6; }
19362 if ${ac_cv_path_SWIG+:} false; then :
19363 $as_echo_n "(cached) " >&6
19364 else
19365 case $SWIG in
19366 [\\/]* | ?:[\\/]*)
19367 ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
19368 ;;
19369 *)
19370 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19371 for as_dir in $PATH
19372 do
19373 IFS=$as_save_IFS
19374 test -z "$as_dir" && as_dir=.
19375 for ac_exec_ext in '' $ac_executable_extensions; do
19376 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19377 ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
19378 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19379 break 2
19380 fi
19381 done
19382 done
19383 IFS=$as_save_IFS
19384
19385 ;;
19386 esac
19387 fi
19388 SWIG=$ac_cv_path_SWIG
19389 if test -n "$SWIG"; then
19390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
19391 $as_echo "$SWIG" >&6; }
19392 else
19393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19394 $as_echo "no" >&6; }
19395 fi
19396
19397
19398 test -n "$SWIG" && break
19399 done
19400
19401 if test -z "$SWIG" ; then
19402 :
19403 elif test -n "" ; then
19404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG version" >&5
19405 $as_echo_n "checking SWIG version... " >&6; }
19406 swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'`
19407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
19408 $as_echo "$swig_version" >&6; }
19409 if test -n "$swig_version" ; then
19410 # Calculate the required version number components
19411 required=
19412 required_major=`echo $required | sed 's/[^0-9].*//'`
19413 if test -z "$required_major" ; then
19414 required_major=0
19415 fi
19416 required=`echo $required | sed 's/[0-9]*[^0-9]//'`
19417 required_minor=`echo $required | sed 's/[^0-9].*//'`
19418 if test -z "$required_minor" ; then
19419 required_minor=0
19420 fi
19421 required=`echo $required | sed 's/[0-9]*[^0-9]//'`
19422 required_patch=`echo $required | sed 's/[^0-9].*//'`
19423 if test -z "$required_patch" ; then
19424 required_patch=0
19425 fi
19426 # Calculate the available version number components
19427 available=$swig_version
19428 available_major=`echo $available | sed 's/[^0-9].*//'`
19429 if test -z "$available_major" ; then
19430 available_major=0
19431 fi
19432 available=`echo $available | sed 's/[0-9]*[^0-9]//'`
19433 available_minor=`echo $available | sed 's/[^0-9].*//'`
19434 if test -z "$available_minor" ; then
19435 available_minor=0
19436 fi
19437 available=`echo $available | sed 's/[0-9]*[^0-9]//'`
19438 available_patch=`echo $available | sed 's/[^0-9].*//'`
19439 if test -z "$available_patch" ; then
19440 available_patch=0
19441 fi
19442 # Convert the version tuple into a single number for easier comparison.
19443 # Using base 100 should be safe since SWIG internally uses BCD values
19444 # to encode its version number.
19445 required_swig_vernum=`expr $required_major \* 10000 \
19446 \+ $required_minor \* 100 \+ $required_patch`
19447 available_swig_vernum=`expr $available_major \* 10000 \
19448 \+ $available_minor \* 100 \+ $available_patch`
19449
19450 if test $available_swig_vernum -lt $required_swig_vernum; then
19451 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= is required. You have $swig_version." >&5
19452 $as_echo "$as_me: WARNING: SWIG version >= is required. You have $swig_version." >&2;}
19453 SWIG=''
19454
19455 else
19456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG library" >&5
19457 $as_echo_n "checking for SWIG library... " >&6; }
19458 SWIG_LIB=`$SWIG -swiglib`
19459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG_LIB" >&5
19460 $as_echo "$SWIG_LIB" >&6; }
19461
19462 fi
19463 else
19464 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
19465 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
19466 SWIG=''
19467
19468 fi
19469 fi
19470
19471
19472 if test -z "$SWIG"; then
19473 if test "$explicit_languages" = "1"; then
19474 as_fn_error $? "
19475 ***
19476 *** You need SWIG to build the Python bindings.
19477 ***" "$LINENO" 5
19478 else
19479 enabled_languages=$(echo $enabled_languages | sed 's/python//')
19480 fi
19481 else
19482 # Reset the version collecting vars.
19483 PYTHONS=
19484 PYTHON_VERSIONS=
19485
19486 if test "$found_py" = "1" -o "$found_py3" = "1"; then
19487 # Reset everything, so that we can look for another Python.
19488 unset PYTHON
19489 unset PYTHON_VERSION
19490 unset PYTHON_CPPFLAGS
19491 unset PYTHON_LDFLAGS
19492 unset PYTHON_SITE_PKG
19493 unset PYTHON_EXTRA_LIBS
19494 unset PYTHON_EXTRA_LDFLAGS
19495 unset ac_cv_path_PYTHON
19496 unset am_cv_pathless_PYTHON
19497 unset am_cv_python_version
19498 unset am_cv_python_platform
19499 unset am_cv_python_pythondir
19500 unset am_cv_python_pyexecdir
19501
19502
19503
19504
19505
19506
19507 if test -n "$PYTHON"; then
19508 # If the user set $PYTHON, use it and don't search something else.
19509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 2.7" >&5
19510 $as_echo_n "checking whether $PYTHON version is >= 2.7... " >&6; }
19511 prog="import sys
19512 # split strings by '.' and convert to numeric. Append some zeros
19513 # because we need at least 4 digits for the hex conversion.
19514 # map returns an iterator in Python 3.0 and a list in 2.x
19515 minver = list(map(int, '2.7'.split('.'))) + [0, 0, 0]
19516 minverhex = 0
19517 # xrange is not present in Python 3.0 and range returns an iterator
19518 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
19519 sys.exit(sys.hexversion < minverhex)"
19520 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
19521 ($PYTHON -c "$prog") >&5 2>&5
19522 ac_status=$?
19523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19524 (exit $ac_status); }; then :
19525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19526 $as_echo "yes" >&6; }
19527 else
19528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19529 $as_echo "no" >&6; }
19530 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
19531 fi
19532 am_display_PYTHON=$PYTHON
19533 else
19534 # Otherwise, try each interpreter until we find one that satisfies
19535 # VERSION.
19536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 2.7" >&5
19537 $as_echo_n "checking for a Python interpreter with version >= 2.7... " >&6; }
19538 if ${am_cv_pathless_PYTHON+:} false; then :
19539 $as_echo_n "(cached) " >&6
19540 else
19541
19542 for am_cv_pathless_PYTHON in python2.7 none; do
19543 test "$am_cv_pathless_PYTHON" = none && break
19544 prog="import sys
19545 # split strings by '.' and convert to numeric. Append some zeros
19546 # because we need at least 4 digits for the hex conversion.
19547 # map returns an iterator in Python 3.0 and a list in 2.x
19548 minver = list(map(int, '2.7'.split('.'))) + [0, 0, 0]
19549 minverhex = 0
19550 # xrange is not present in Python 3.0 and range returns an iterator
19551 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
19552 sys.exit(sys.hexversion < minverhex)"
19553 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
19554 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
19555 ac_status=$?
19556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19557 (exit $ac_status); }; then :
19558 break
19559 fi
19560 done
19561 fi
19562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
19563 $as_echo "$am_cv_pathless_PYTHON" >&6; }
19564 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
19565 if test "$am_cv_pathless_PYTHON" = none; then
19566 PYTHON=:
19567 else
19568 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
19569 set dummy $am_cv_pathless_PYTHON; ac_word=$2
19570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19571 $as_echo_n "checking for $ac_word... " >&6; }
19572 if ${ac_cv_path_PYTHON+:} false; then :
19573 $as_echo_n "(cached) " >&6
19574 else
19575 case $PYTHON in
19576 [\\/]* | ?:[\\/]*)
19577 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
19578 ;;
19579 *)
19580 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19581 for as_dir in $PATH
19582 do
19583 IFS=$as_save_IFS
19584 test -z "$as_dir" && as_dir=.
19585 for ac_exec_ext in '' $ac_executable_extensions; do
19586 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19587 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
19588 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19589 break 2
19590 fi
19591 done
19592 done
19593 IFS=$as_save_IFS
19594
19595 ;;
19596 esac
19597 fi
19598 PYTHON=$ac_cv_path_PYTHON
19599 if test -n "$PYTHON"; then
19600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
19601 $as_echo "$PYTHON" >&6; }
19602 else
19603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19604 $as_echo "no" >&6; }
19605 fi
19606
19607
19608 fi
19609 am_display_PYTHON=$am_cv_pathless_PYTHON
19610 fi
19611
19612
19613 if test "$PYTHON" = :; then
19614 :
19615 else
19616
19617
19618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
19619 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
19620 if ${am_cv_python_version+:} false; then :
19621 $as_echo_n "(cached) " >&6
19622 else
19623 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
19624 fi
19625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
19626 $as_echo "$am_cv_python_version" >&6; }
19627 PYTHON_VERSION=$am_cv_python_version
19628
19629
19630
19631 PYTHON_PREFIX='${prefix}'
19632
19633 PYTHON_EXEC_PREFIX='${exec_prefix}'
19634
19635
19636
19637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
19638 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
19639 if ${am_cv_python_platform+:} false; then :
19640 $as_echo_n "(cached) " >&6
19641 else
19642 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
19643 fi
19644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
19645 $as_echo "$am_cv_python_platform" >&6; }
19646 PYTHON_PLATFORM=$am_cv_python_platform
19647
19648
19649 # Just factor out some code duplication.
19650 am_python_setup_sysconfig="\
19651 import sys
19652 # Prefer sysconfig over distutils.sysconfig, for better compatibility
19653 # with python 3.x. See automake bug#10227.
19654 try:
19655 import sysconfig
19656 except ImportError:
19657 can_use_sysconfig = 0
19658 else:
19659 can_use_sysconfig = 1
19660 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
19661 # <https://github.com/pypa/virtualenv/issues/118>
19662 try:
19663 from platform import python_implementation
19664 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
19665 can_use_sysconfig = 0
19666 except ImportError:
19667 pass"
19668
19669
19670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
19671 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
19672 if ${am_cv_python_pythondir+:} false; then :
19673 $as_echo_n "(cached) " >&6
19674 else
19675 if test "x$prefix" = xNONE
19676 then
19677 am_py_prefix=$ac_default_prefix
19678 else
19679 am_py_prefix=$prefix
19680 fi
19681 am_cv_python_pythondir=`$PYTHON -c "
19682 $am_python_setup_sysconfig
19683 if can_use_sysconfig:
19684 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
19685 else:
19686 from distutils import sysconfig
19687 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
19688 sys.stdout.write(sitedir)"`
19689 case $am_cv_python_pythondir in
19690 $am_py_prefix*)
19691 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
19692 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
19693 ;;
19694 *)
19695 case $am_py_prefix in
19696 /usr|/System*) ;;
19697 *)
19698 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
19699 ;;
19700 esac
19701 ;;
19702 esac
19703
19704 fi
19705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
19706 $as_echo "$am_cv_python_pythondir" >&6; }
19707 pythondir=$am_cv_python_pythondir
19708
19709
19710
19711 pkgpythondir=\${pythondir}/$PACKAGE
19712
19713
19714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
19715 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
19716 if ${am_cv_python_pyexecdir+:} false; then :
19717 $as_echo_n "(cached) " >&6
19718 else
19719 if test "x$exec_prefix" = xNONE
19720 then
19721 am_py_exec_prefix=$am_py_prefix
19722 else
19723 am_py_exec_prefix=$exec_prefix
19724 fi
19725 am_cv_python_pyexecdir=`$PYTHON -c "
19726 $am_python_setup_sysconfig
19727 if can_use_sysconfig:
19728 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
19729 else:
19730 from distutils import sysconfig
19731 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
19732 sys.stdout.write(sitedir)"`
19733 case $am_cv_python_pyexecdir in
19734 $am_py_exec_prefix*)
19735 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
19736 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
19737 ;;
19738 *)
19739 case $am_py_exec_prefix in
19740 /usr|/System*) ;;
19741 *)
19742 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
19743 ;;
19744 esac
19745 ;;
19746 esac
19747
19748 fi
19749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
19750 $as_echo "$am_cv_python_pyexecdir" >&6; }
19751 pyexecdir=$am_cv_python_pyexecdir
19752
19753
19754
19755 pkgpyexecdir=\${pyexecdir}/$PACKAGE
19756
19757
19758
19759
19760 #
19761 # Allow the use of a (user set) custom python version
19762 #
19763
19764
19765 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
19766 set dummy python$PYTHON_VERSION; ac_word=$2
19767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19768 $as_echo_n "checking for $ac_word... " >&6; }
19769 if ${ac_cv_path_PYTHON+:} false; then :
19770 $as_echo_n "(cached) " >&6
19771 else
19772 case $PYTHON in
19773 [\\/]* | ?:[\\/]*)
19774 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
19775 ;;
19776 *)
19777 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19778 for as_dir in $PATH
19779 do
19780 IFS=$as_save_IFS
19781 test -z "$as_dir" && as_dir=.
19782 for ac_exec_ext in '' $ac_executable_extensions; do
19783 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19784 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
19785 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19786 break 2
19787 fi
19788 done
19789 done
19790 IFS=$as_save_IFS
19791
19792 ;;
19793 esac
19794 fi
19795 PYTHON=$ac_cv_path_PYTHON
19796 if test -n "$PYTHON"; then
19797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
19798 $as_echo "$PYTHON" >&6; }
19799 else
19800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19801 $as_echo "no" >&6; }
19802 fi
19803
19804
19805 if test -z "$PYTHON"; then
19806 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
19807 PYTHON_VERSION=""
19808 fi
19809
19810 #
19811 # Check for a version of Python >= 2.1.0
19812 #
19813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
19814 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
19815 ac_supports_python_ver=`$PYTHON -c "import sys; \
19816 ver = sys.version.split ()[0]; \
19817 print (ver >= '2.1.0')"`
19818 if test "$ac_supports_python_ver" != "True"; then
19819 if test -z "$PYTHON_NOVERSIONCHECK"; then
19820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19821 $as_echo "no" >&6; }
19822 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19823 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19824 as_fn_error $? "
19825 This version of the AC_PYTHON_DEVEL macro
19826 doesn't work properly with versions of Python before
19827 2.1.0. You may need to re-run configure, setting the
19828 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
19829 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
19830 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
19831 to something else than an empty string.
19832
19833 See \`config.log' for more details" "$LINENO" 5; }
19834 else
19835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
19836 $as_echo "skip at user request" >&6; }
19837 fi
19838 else
19839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19840 $as_echo "yes" >&6; }
19841 fi
19842
19843 #
19844 # if the macro parameter ``version'' is set, honour it
19845 #
19846 if test -n ""; then
19847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
19848 $as_echo_n "checking for a version of Python ... " >&6; }
19849 ac_supports_python_ver=`$PYTHON -c "import sys; \
19850 ver = sys.version.split ()[0]; \
19851 print (ver )"`
19852 if test "$ac_supports_python_ver" = "True"; then
19853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19854 $as_echo "yes" >&6; }
19855 else
19856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19857 $as_echo "no" >&6; }
19858 as_fn_error $? "this package requires Python .
19859 If you have it installed, but it isn't the default Python
19860 interpreter in your system path, please pass the PYTHON_VERSION
19861 variable to configure. See \`\`configure --help'' for reference.
19862 " "$LINENO" 5
19863 PYTHON_VERSION=""
19864 fi
19865 fi
19866
19867 #
19868 # Check if you have distutils, else fail
19869 #
19870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
19871 $as_echo_n "checking for the distutils Python package... " >&6; }
19872 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
19873 if test -z "$ac_distutils_result"; then
19874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19875 $as_echo "yes" >&6; }
19876 else
19877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19878 $as_echo "no" >&6; }
19879 as_fn_error $? "cannot import Python module \"distutils\".
19880 Please check your Python installation. The error was:
19881 $ac_distutils_result" "$LINENO" 5
19882 PYTHON_VERSION=""
19883 fi
19884
19885 #
19886 # Check for Python include path
19887 #
19888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
19889 $as_echo_n "checking for Python include path... " >&6; }
19890 if test -z "$PYTHON_CPPFLAGS"; then
19891 python_path=`$PYTHON -c "import distutils.sysconfig; \
19892 print (distutils.sysconfig.get_python_inc ());"`
19893 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
19894 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
19895 if test -n "${python_path}"; then
19896 if test "${plat_python_path}" != "${python_path}"; then
19897 python_path="-I$python_path -I$plat_python_path"
19898 else
19899 python_path="-I$python_path"
19900 fi
19901 fi
19902 PYTHON_CPPFLAGS=$python_path
19903 fi
19904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
19905 $as_echo "$PYTHON_CPPFLAGS" >&6; }
19906
19907
19908 #
19909 # Check for Python library path
19910 #
19911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
19912 $as_echo_n "checking for Python library path... " >&6; }
19913 if test -z "$PYTHON_LDFLAGS"; then
19914 # (makes two attempts to ensure we've got a version number
19915 # from the interpreter)
19916 ac_python_version=`cat<<EOD | $PYTHON -
19917
19918 # join all versioning strings, on some systems
19919 # major/minor numbers could be in different list elements
19920 from distutils.sysconfig import *
19921 e = get_config_var('VERSION')
19922 if e is not None:
19923 print(e)
19924 EOD`
19925
19926 if test -z "$ac_python_version"; then
19927 if test -n "$PYTHON_VERSION"; then
19928 ac_python_version=$PYTHON_VERSION
19929 else
19930 ac_python_version=`$PYTHON -c "import sys; \
19931 print (sys.version[:3])"`
19932 fi
19933 fi
19934
19935 # Make the versioning information available to the compiler
19936
19937 # JW: We don't need it and it interferes with the hack
19938 # to detect multiple Pyhton versions
19939 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
19940 # [If available, contains the Python version number currently in use.])
19941
19942 # First, the library directory:
19943 ac_python_libdir=`cat<<EOD | $PYTHON -
19944
19945 # There should be only one
19946 import distutils.sysconfig
19947 e = distutils.sysconfig.get_config_var('LIBDIR')
19948 if e is not None:
19949 print (e)
19950 EOD`
19951
19952 # Now, for the library:
19953 ac_python_library=`cat<<EOD | $PYTHON -
19954
19955 import distutils.sysconfig
19956 c = distutils.sysconfig.get_config_vars()
19957 if 'LDVERSION' in c:
19958 print ('python'+c['LDVERSION'])
19959 else:
19960 print ('python'+c['VERSION'])
19961 EOD`
19962
19963 # This small piece shamelessly adapted from PostgreSQL python macro;
19964 # credits goes to momjian, I think. I'd like to put the right name
19965 # in the credits, if someone can point me in the right direction... ?
19966 #
19967 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
19968 then
19969 # use the official shared library
19970 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
19971 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
19972 else
19973 # old way: use libpython from python_configdir
19974 ac_python_libdir=`$PYTHON -c \
19975 "from distutils.sysconfig import get_python_lib as f; \
19976 import os; \
19977 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
19978 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
19979 fi
19980
19981 if test -z "PYTHON_LDFLAGS"; then
19982 as_fn_error $? "
19983 Cannot determine location of your Python DSO. Please check it was installed with
19984 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
19985 " "$LINENO" 5
19986 fi
19987 fi
19988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
19989 $as_echo "$PYTHON_LDFLAGS" >&6; }
19990
19991
19992 #
19993 # Check for site packages
19994 #
19995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
19996 $as_echo_n "checking for Python site-packages path... " >&6; }
19997 if test -z "$PYTHON_SITE_PKG"; then
19998 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
19999 print (distutils.sysconfig.get_python_lib(0,0));"`
20000 fi
20001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
20002 $as_echo "$PYTHON_SITE_PKG" >&6; }
20003
20004
20005 #
20006 # libraries which must be linked in when embedding
20007 #
20008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
20009 $as_echo_n "checking python extra libraries... " >&6; }
20010 if test -z "$PYTHON_EXTRA_LIBS"; then
20011 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
20012 conf = distutils.sysconfig.get_config_var; \
20013 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
20014 fi
20015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
20016 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
20017
20018
20019 #
20020 # linking flags needed when embedding
20021 #
20022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
20023 $as_echo_n "checking python extra linking flags... " >&6; }
20024 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
20025 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
20026 conf = distutils.sysconfig.get_config_var; \
20027 print (conf('LINKFORSHARED'))"`
20028 fi
20029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
20030 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
20031
20032
20033 #
20034 # final check to see if everything compiles alright
20035 #
20036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
20037 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
20038 # save current global flags
20039 ac_save_LIBS="$LIBS"
20040 ac_save_CPPFLAGS="$CPPFLAGS"
20041 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
20042 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
20043 ac_ext=c
20044 ac_cpp='$CPP $CPPFLAGS'
20045 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
20046 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
20047 ac_compiler_gnu=$ac_cv_c_compiler_gnu
20048
20049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20050 /* end confdefs.h. */
20051
20052 #include <Python.h>
20053 int
20054 main ()
20055 {
20056 Py_Initialize();
20057 ;
20058 return 0;
20059 }
20060
20061 _ACEOF
20062 if ac_fn_c_try_link "$LINENO"; then :
20063 pythonexists=yes
20064 else
20065 pythonexists=no
20066 fi
20067 rm -f core conftest.err conftest.$ac_objext \
20068 conftest$ac_exeext conftest.$ac_ext
20069 ac_ext=c
20070 ac_cpp='$CPP $CPPFLAGS'
20071 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
20072 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
20073 ac_compiler_gnu=$ac_cv_c_compiler_gnu
20074
20075 # turn back to default flags
20076 CPPFLAGS="$ac_save_CPPFLAGS"
20077 LIBS="$ac_save_LIBS"
20078
20079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
20080 $as_echo "$pythonexists" >&6; }
20081
20082 if test ! "x$pythonexists" = "xyes"; then
20083 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
20084 Could not link test program to Python. Maybe the main Python library has been
20085 installed in some non-standard library path. If so, pass it to configure,
20086 via the LDFLAGS environment variable.
20087 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
20088 ============================================================================
20089 You probably have to install the development version of the Python package
20090 for your distribution. The exact name of this package varies among them.
20091 ============================================================================
20092 " >&5
20093 $as_echo "$as_me: WARNING:
20094 Could not link test program to Python. Maybe the main Python library has been
20095 installed in some non-standard library path. If so, pass it to configure,
20096 via the LDFLAGS environment variable.
20097 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
20098 ============================================================================
20099 You probably have to install the development version of the Python package
20100 for your distribution. The exact name of this package varies among them.
20101 ============================================================================
20102 " >&2;}
20103 PYTHON_VERSION=""
20104 fi
20105
20106 #
20107 # all done!
20108 #
20109
20110 if test "$PYTHON_VERSION"; then
20111 PYTHONS="$(echo $PYTHONS $PYTHON)"
20112 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
20113 fi
20114
20115 fi
20116
20117
20118 unset PYTHON
20119 unset PYTHON_VERSION
20120 unset PYTHON_CPPFLAGS
20121 unset PYTHON_LDFLAGS
20122 unset PYTHON_SITE_PKG
20123 unset PYTHON_EXTRA_LIBS
20124 unset PYTHON_EXTRA_LDFLAGS
20125 unset ac_cv_path_PYTHON
20126 unset am_cv_pathless_PYTHON
20127 unset am_cv_python_version
20128 unset am_cv_python_platform
20129 unset am_cv_python_pythondir
20130 unset am_cv_python_pyexecdir
20131
20132
20133
20134
20135
20136
20137 if test -n "$PYTHON"; then
20138 # If the user set $PYTHON, use it and don't search something else.
20139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3.4" >&5
20140 $as_echo_n "checking whether $PYTHON version is >= 3.4... " >&6; }
20141 prog="import sys
20142 # split strings by '.' and convert to numeric. Append some zeros
20143 # because we need at least 4 digits for the hex conversion.
20144 # map returns an iterator in Python 3.0 and a list in 2.x
20145 minver = list(map(int, '3.4'.split('.'))) + [0, 0, 0]
20146 minverhex = 0
20147 # xrange is not present in Python 3.0 and range returns an iterator
20148 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
20149 sys.exit(sys.hexversion < minverhex)"
20150 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
20151 ($PYTHON -c "$prog") >&5 2>&5
20152 ac_status=$?
20153 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20154 (exit $ac_status); }; then :
20155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20156 $as_echo "yes" >&6; }
20157 else
20158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20159 $as_echo "no" >&6; }
20160 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
20161 fi
20162 am_display_PYTHON=$PYTHON
20163 else
20164 # Otherwise, try each interpreter until we find one that satisfies
20165 # VERSION.
20166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3.4" >&5
20167 $as_echo_n "checking for a Python interpreter with version >= 3.4... " >&6; }
20168 if ${am_cv_pathless_PYTHON+:} false; then :
20169 $as_echo_n "(cached) " >&6
20170 else
20171
20172 for am_cv_pathless_PYTHON in python3.4 none; do
20173 test "$am_cv_pathless_PYTHON" = none && break
20174 prog="import sys
20175 # split strings by '.' and convert to numeric. Append some zeros
20176 # because we need at least 4 digits for the hex conversion.
20177 # map returns an iterator in Python 3.0 and a list in 2.x
20178 minver = list(map(int, '3.4'.split('.'))) + [0, 0, 0]
20179 minverhex = 0
20180 # xrange is not present in Python 3.0 and range returns an iterator
20181 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
20182 sys.exit(sys.hexversion < minverhex)"
20183 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
20184 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
20185 ac_status=$?
20186 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20187 (exit $ac_status); }; then :
20188 break
20189 fi
20190 done
20191 fi
20192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
20193 $as_echo "$am_cv_pathless_PYTHON" >&6; }
20194 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
20195 if test "$am_cv_pathless_PYTHON" = none; then
20196 PYTHON=:
20197 else
20198 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
20199 set dummy $am_cv_pathless_PYTHON; ac_word=$2
20200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20201 $as_echo_n "checking for $ac_word... " >&6; }
20202 if ${ac_cv_path_PYTHON+:} false; then :
20203 $as_echo_n "(cached) " >&6
20204 else
20205 case $PYTHON in
20206 [\\/]* | ?:[\\/]*)
20207 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
20208 ;;
20209 *)
20210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20211 for as_dir in $PATH
20212 do
20213 IFS=$as_save_IFS
20214 test -z "$as_dir" && as_dir=.
20215 for ac_exec_ext in '' $ac_executable_extensions; do
20216 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20217 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
20218 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20219 break 2
20220 fi
20221 done
20222 done
20223 IFS=$as_save_IFS
20224
20225 ;;
20226 esac
20227 fi
20228 PYTHON=$ac_cv_path_PYTHON
20229 if test -n "$PYTHON"; then
20230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
20231 $as_echo "$PYTHON" >&6; }
20232 else
20233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20234 $as_echo "no" >&6; }
20235 fi
20236
20237
20238 fi
20239 am_display_PYTHON=$am_cv_pathless_PYTHON
20240 fi
20241
20242
20243 if test "$PYTHON" = :; then
20244 :
20245 else
20246
20247
20248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
20249 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
20250 if ${am_cv_python_version+:} false; then :
20251 $as_echo_n "(cached) " >&6
20252 else
20253 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
20254 fi
20255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
20256 $as_echo "$am_cv_python_version" >&6; }
20257 PYTHON_VERSION=$am_cv_python_version
20258
20259
20260
20261 PYTHON_PREFIX='${prefix}'
20262
20263 PYTHON_EXEC_PREFIX='${exec_prefix}'
20264
20265
20266
20267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
20268 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
20269 if ${am_cv_python_platform+:} false; then :
20270 $as_echo_n "(cached) " >&6
20271 else
20272 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
20273 fi
20274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
20275 $as_echo "$am_cv_python_platform" >&6; }
20276 PYTHON_PLATFORM=$am_cv_python_platform
20277
20278
20279 # Just factor out some code duplication.
20280 am_python_setup_sysconfig="\
20281 import sys
20282 # Prefer sysconfig over distutils.sysconfig, for better compatibility
20283 # with python 3.x. See automake bug#10227.
20284 try:
20285 import sysconfig
20286 except ImportError:
20287 can_use_sysconfig = 0
20288 else:
20289 can_use_sysconfig = 1
20290 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
20291 # <https://github.com/pypa/virtualenv/issues/118>
20292 try:
20293 from platform import python_implementation
20294 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
20295 can_use_sysconfig = 0
20296 except ImportError:
20297 pass"
20298
20299
20300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
20301 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
20302 if ${am_cv_python_pythondir+:} false; then :
20303 $as_echo_n "(cached) " >&6
20304 else
20305 if test "x$prefix" = xNONE
20306 then
20307 am_py_prefix=$ac_default_prefix
20308 else
20309 am_py_prefix=$prefix
20310 fi
20311 am_cv_python_pythondir=`$PYTHON -c "
20312 $am_python_setup_sysconfig
20313 if can_use_sysconfig:
20314 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
20315 else:
20316 from distutils import sysconfig
20317 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
20318 sys.stdout.write(sitedir)"`
20319 case $am_cv_python_pythondir in
20320 $am_py_prefix*)
20321 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
20322 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
20323 ;;
20324 *)
20325 case $am_py_prefix in
20326 /usr|/System*) ;;
20327 *)
20328 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
20329 ;;
20330 esac
20331 ;;
20332 esac
20333
20334 fi
20335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
20336 $as_echo "$am_cv_python_pythondir" >&6; }
20337 pythondir=$am_cv_python_pythondir
20338
20339
20340
20341 pkgpythondir=\${pythondir}/$PACKAGE
20342
20343
20344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
20345 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
20346 if ${am_cv_python_pyexecdir+:} false; then :
20347 $as_echo_n "(cached) " >&6
20348 else
20349 if test "x$exec_prefix" = xNONE
20350 then
20351 am_py_exec_prefix=$am_py_prefix
20352 else
20353 am_py_exec_prefix=$exec_prefix
20354 fi
20355 am_cv_python_pyexecdir=`$PYTHON -c "
20356 $am_python_setup_sysconfig
20357 if can_use_sysconfig:
20358 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
20359 else:
20360 from distutils import sysconfig
20361 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
20362 sys.stdout.write(sitedir)"`
20363 case $am_cv_python_pyexecdir in
20364 $am_py_exec_prefix*)
20365 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
20366 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
20367 ;;
20368 *)
20369 case $am_py_exec_prefix in
20370 /usr|/System*) ;;
20371 *)
20372 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
20373 ;;
20374 esac
20375 ;;
20376 esac
20377
20378 fi
20379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
20380 $as_echo "$am_cv_python_pyexecdir" >&6; }
20381 pyexecdir=$am_cv_python_pyexecdir
20382
20383
20384
20385 pkgpyexecdir=\${pyexecdir}/$PACKAGE
20386
20387
20388
20389
20390 #
20391 # Allow the use of a (user set) custom python version
20392 #
20393
20394
20395 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
20396 set dummy python$PYTHON_VERSION; ac_word=$2
20397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20398 $as_echo_n "checking for $ac_word... " >&6; }
20399 if ${ac_cv_path_PYTHON+:} false; then :
20400 $as_echo_n "(cached) " >&6
20401 else
20402 case $PYTHON in
20403 [\\/]* | ?:[\\/]*)
20404 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
20405 ;;
20406 *)
20407 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20408 for as_dir in $PATH
20409 do
20410 IFS=$as_save_IFS
20411 test -z "$as_dir" && as_dir=.
20412 for ac_exec_ext in '' $ac_executable_extensions; do
20413 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20414 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
20415 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20416 break 2
20417 fi
20418 done
20419 done
20420 IFS=$as_save_IFS
20421
20422 ;;
20423 esac
20424 fi
20425 PYTHON=$ac_cv_path_PYTHON
20426 if test -n "$PYTHON"; then
20427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
20428 $as_echo "$PYTHON" >&6; }
20429 else
20430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20431 $as_echo "no" >&6; }
20432 fi
20433
20434
20435 if test -z "$PYTHON"; then
20436 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
20437 PYTHON_VERSION=""
20438 fi
20439
20440 #
20441 # Check for a version of Python >= 2.1.0
20442 #
20443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
20444 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
20445 ac_supports_python_ver=`$PYTHON -c "import sys; \
20446 ver = sys.version.split ()[0]; \
20447 print (ver >= '2.1.0')"`
20448 if test "$ac_supports_python_ver" != "True"; then
20449 if test -z "$PYTHON_NOVERSIONCHECK"; then
20450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20451 $as_echo "no" >&6; }
20452 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20453 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20454 as_fn_error $? "
20455 This version of the AC_PYTHON_DEVEL macro
20456 doesn't work properly with versions of Python before
20457 2.1.0. You may need to re-run configure, setting the
20458 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
20459 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
20460 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
20461 to something else than an empty string.
20462
20463 See \`config.log' for more details" "$LINENO" 5; }
20464 else
20465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
20466 $as_echo "skip at user request" >&6; }
20467 fi
20468 else
20469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20470 $as_echo "yes" >&6; }
20471 fi
20472
20473 #
20474 # if the macro parameter ``version'' is set, honour it
20475 #
20476 if test -n ""; then
20477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
20478 $as_echo_n "checking for a version of Python ... " >&6; }
20479 ac_supports_python_ver=`$PYTHON -c "import sys; \
20480 ver = sys.version.split ()[0]; \
20481 print (ver )"`
20482 if test "$ac_supports_python_ver" = "True"; then
20483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20484 $as_echo "yes" >&6; }
20485 else
20486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20487 $as_echo "no" >&6; }
20488 as_fn_error $? "this package requires Python .
20489 If you have it installed, but it isn't the default Python
20490 interpreter in your system path, please pass the PYTHON_VERSION
20491 variable to configure. See \`\`configure --help'' for reference.
20492 " "$LINENO" 5
20493 PYTHON_VERSION=""
20494 fi
20495 fi
20496
20497 #
20498 # Check if you have distutils, else fail
20499 #
20500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
20501 $as_echo_n "checking for the distutils Python package... " >&6; }
20502 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
20503 if test -z "$ac_distutils_result"; then
20504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20505 $as_echo "yes" >&6; }
20506 else
20507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20508 $as_echo "no" >&6; }
20509 as_fn_error $? "cannot import Python module \"distutils\".
20510 Please check your Python installation. The error was:
20511 $ac_distutils_result" "$LINENO" 5
20512 PYTHON_VERSION=""
20513 fi
20514
20515 #
20516 # Check for Python include path
20517 #
20518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
20519 $as_echo_n "checking for Python include path... " >&6; }
20520 if test -z "$PYTHON_CPPFLAGS"; then
20521 python_path=`$PYTHON -c "import distutils.sysconfig; \
20522 print (distutils.sysconfig.get_python_inc ());"`
20523 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
20524 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
20525 if test -n "${python_path}"; then
20526 if test "${plat_python_path}" != "${python_path}"; then
20527 python_path="-I$python_path -I$plat_python_path"
20528 else
20529 python_path="-I$python_path"
20530 fi
20531 fi
20532 PYTHON_CPPFLAGS=$python_path
20533 fi
20534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
20535 $as_echo "$PYTHON_CPPFLAGS" >&6; }
20536
20537
20538 #
20539 # Check for Python library path
20540 #
20541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
20542 $as_echo_n "checking for Python library path... " >&6; }
20543 if test -z "$PYTHON_LDFLAGS"; then
20544 # (makes two attempts to ensure we've got a version number
20545 # from the interpreter)
20546 ac_python_version=`cat<<EOD | $PYTHON -
20547
20548 # join all versioning strings, on some systems
20549 # major/minor numbers could be in different list elements
20550 from distutils.sysconfig import *
20551 e = get_config_var('VERSION')
20552 if e is not None:
20553 print(e)
20554 EOD`
20555
20556 if test -z "$ac_python_version"; then
20557 if test -n "$PYTHON_VERSION"; then
20558 ac_python_version=$PYTHON_VERSION
20559 else
20560 ac_python_version=`$PYTHON -c "import sys; \
20561 print (sys.version[:3])"`
20562 fi
20563 fi
20564
20565 # Make the versioning information available to the compiler
20566
20567 # JW: We don't need it and it interferes with the hack
20568 # to detect multiple Pyhton versions
20569 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
20570 # [If available, contains the Python version number currently in use.])
20571
20572 # First, the library directory:
20573 ac_python_libdir=`cat<<EOD | $PYTHON -
20574
20575 # There should be only one
20576 import distutils.sysconfig
20577 e = distutils.sysconfig.get_config_var('LIBDIR')
20578 if e is not None:
20579 print (e)
20580 EOD`
20581
20582 # Now, for the library:
20583 ac_python_library=`cat<<EOD | $PYTHON -
20584
20585 import distutils.sysconfig
20586 c = distutils.sysconfig.get_config_vars()
20587 if 'LDVERSION' in c:
20588 print ('python'+c['LDVERSION'])
20589 else:
20590 print ('python'+c['VERSION'])
20591 EOD`
20592
20593 # This small piece shamelessly adapted from PostgreSQL python macro;
20594 # credits goes to momjian, I think. I'd like to put the right name
20595 # in the credits, if someone can point me in the right direction... ?
20596 #
20597 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
20598 then
20599 # use the official shared library
20600 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
20601 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
20602 else
20603 # old way: use libpython from python_configdir
20604 ac_python_libdir=`$PYTHON -c \
20605 "from distutils.sysconfig import get_python_lib as f; \
20606 import os; \
20607 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
20608 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
20609 fi
20610
20611 if test -z "PYTHON_LDFLAGS"; then
20612 as_fn_error $? "
20613 Cannot determine location of your Python DSO. Please check it was installed with
20614 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
20615 " "$LINENO" 5
20616 fi
20617 fi
20618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
20619 $as_echo "$PYTHON_LDFLAGS" >&6; }
20620
20621
20622 #
20623 # Check for site packages
20624 #
20625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
20626 $as_echo_n "checking for Python site-packages path... " >&6; }
20627 if test -z "$PYTHON_SITE_PKG"; then
20628 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
20629 print (distutils.sysconfig.get_python_lib(0,0));"`
20630 fi
20631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
20632 $as_echo "$PYTHON_SITE_PKG" >&6; }
20633
20634
20635 #
20636 # libraries which must be linked in when embedding
20637 #
20638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
20639 $as_echo_n "checking python extra libraries... " >&6; }
20640 if test -z "$PYTHON_EXTRA_LIBS"; then
20641 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
20642 conf = distutils.sysconfig.get_config_var; \
20643 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
20644 fi
20645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
20646 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
20647
20648
20649 #
20650 # linking flags needed when embedding
20651 #
20652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
20653 $as_echo_n "checking python extra linking flags... " >&6; }
20654 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
20655 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
20656 conf = distutils.sysconfig.get_config_var; \
20657 print (conf('LINKFORSHARED'))"`
20658 fi
20659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
20660 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
20661
20662
20663 #
20664 # final check to see if everything compiles alright
20665 #
20666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
20667 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
20668 # save current global flags
20669 ac_save_LIBS="$LIBS"
20670 ac_save_CPPFLAGS="$CPPFLAGS"
20671 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
20672 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
20673 ac_ext=c
20674 ac_cpp='$CPP $CPPFLAGS'
20675 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
20676 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
20677 ac_compiler_gnu=$ac_cv_c_compiler_gnu
20678
20679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20680 /* end confdefs.h. */
20681
20682 #include <Python.h>
20683 int
20684 main ()
20685 {
20686 Py_Initialize();
20687 ;
20688 return 0;
20689 }
20690
20691 _ACEOF
20692 if ac_fn_c_try_link "$LINENO"; then :
20693 pythonexists=yes
20694 else
20695 pythonexists=no
20696 fi
20697 rm -f core conftest.err conftest.$ac_objext \
20698 conftest$ac_exeext conftest.$ac_ext
20699 ac_ext=c
20700 ac_cpp='$CPP $CPPFLAGS'
20701 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
20702 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
20703 ac_compiler_gnu=$ac_cv_c_compiler_gnu
20704
20705 # turn back to default flags
20706 CPPFLAGS="$ac_save_CPPFLAGS"
20707 LIBS="$ac_save_LIBS"
20708
20709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
20710 $as_echo "$pythonexists" >&6; }
20711
20712 if test ! "x$pythonexists" = "xyes"; then
20713 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
20714 Could not link test program to Python. Maybe the main Python library has been
20715 installed in some non-standard library path. If so, pass it to configure,
20716 via the LDFLAGS environment variable.
20717 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
20718 ============================================================================
20719 You probably have to install the development version of the Python package
20720 for your distribution. The exact name of this package varies among them.
20721 ============================================================================
20722 " >&5
20723 $as_echo "$as_me: WARNING:
20724 Could not link test program to Python. Maybe the main Python library has been
20725 installed in some non-standard library path. If so, pass it to configure,
20726 via the LDFLAGS environment variable.
20727 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
20728 ============================================================================
20729 You probably have to install the development version of the Python package
20730 for your distribution. The exact name of this package varies among them.
20731 ============================================================================
20732 " >&2;}
20733 PYTHON_VERSION=""
20734 fi
20735
20736 #
20737 # all done!
20738 #
20739
20740 if test "$PYTHON_VERSION"; then
20741 PYTHONS="$(echo $PYTHONS $PYTHON)"
20742 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
20743 fi
20744
20745 fi
20746
20747
20748 unset PYTHON
20749 unset PYTHON_VERSION
20750 unset PYTHON_CPPFLAGS
20751 unset PYTHON_LDFLAGS
20752 unset PYTHON_SITE_PKG
20753 unset PYTHON_EXTRA_LIBS
20754 unset PYTHON_EXTRA_LDFLAGS
20755 unset ac_cv_path_PYTHON
20756 unset am_cv_pathless_PYTHON
20757 unset am_cv_python_version
20758 unset am_cv_python_platform
20759 unset am_cv_python_pythondir
20760 unset am_cv_python_pyexecdir
20761
20762
20763
20764
20765
20766
20767 if test -n "$PYTHON"; then
20768 # If the user set $PYTHON, use it and don't search something else.
20769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3.5" >&5
20770 $as_echo_n "checking whether $PYTHON version is >= 3.5... " >&6; }
20771 prog="import sys
20772 # split strings by '.' and convert to numeric. Append some zeros
20773 # because we need at least 4 digits for the hex conversion.
20774 # map returns an iterator in Python 3.0 and a list in 2.x
20775 minver = list(map(int, '3.5'.split('.'))) + [0, 0, 0]
20776 minverhex = 0
20777 # xrange is not present in Python 3.0 and range returns an iterator
20778 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
20779 sys.exit(sys.hexversion < minverhex)"
20780 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
20781 ($PYTHON -c "$prog") >&5 2>&5
20782 ac_status=$?
20783 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20784 (exit $ac_status); }; then :
20785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20786 $as_echo "yes" >&6; }
20787 else
20788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20789 $as_echo "no" >&6; }
20790 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
20791 fi
20792 am_display_PYTHON=$PYTHON
20793 else
20794 # Otherwise, try each interpreter until we find one that satisfies
20795 # VERSION.
20796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3.5" >&5
20797 $as_echo_n "checking for a Python interpreter with version >= 3.5... " >&6; }
20798 if ${am_cv_pathless_PYTHON+:} false; then :
20799 $as_echo_n "(cached) " >&6
20800 else
20801
20802 for am_cv_pathless_PYTHON in python3.5 none; do
20803 test "$am_cv_pathless_PYTHON" = none && break
20804 prog="import sys
20805 # split strings by '.' and convert to numeric. Append some zeros
20806 # because we need at least 4 digits for the hex conversion.
20807 # map returns an iterator in Python 3.0 and a list in 2.x
20808 minver = list(map(int, '3.5'.split('.'))) + [0, 0, 0]
20809 minverhex = 0
20810 # xrange is not present in Python 3.0 and range returns an iterator
20811 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
20812 sys.exit(sys.hexversion < minverhex)"
20813 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
20814 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
20815 ac_status=$?
20816 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20817 (exit $ac_status); }; then :
20818 break
20819 fi
20820 done
20821 fi
20822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
20823 $as_echo "$am_cv_pathless_PYTHON" >&6; }
20824 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
20825 if test "$am_cv_pathless_PYTHON" = none; then
20826 PYTHON=:
20827 else
20828 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
20829 set dummy $am_cv_pathless_PYTHON; ac_word=$2
20830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20831 $as_echo_n "checking for $ac_word... " >&6; }
20832 if ${ac_cv_path_PYTHON+:} false; then :
20833 $as_echo_n "(cached) " >&6
20834 else
20835 case $PYTHON in
20836 [\\/]* | ?:[\\/]*)
20837 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
20838 ;;
20839 *)
20840 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20841 for as_dir in $PATH
20842 do
20843 IFS=$as_save_IFS
20844 test -z "$as_dir" && as_dir=.
20845 for ac_exec_ext in '' $ac_executable_extensions; do
20846 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20847 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
20848 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20849 break 2
20850 fi
20851 done
20852 done
20853 IFS=$as_save_IFS
20854
20855 ;;
20856 esac
20857 fi
20858 PYTHON=$ac_cv_path_PYTHON
20859 if test -n "$PYTHON"; then
20860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
20861 $as_echo "$PYTHON" >&6; }
20862 else
20863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20864 $as_echo "no" >&6; }
20865 fi
20866
20867
20868 fi
20869 am_display_PYTHON=$am_cv_pathless_PYTHON
20870 fi
20871
20872
20873 if test "$PYTHON" = :; then
20874 :
20875 else
20876
20877
20878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
20879 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
20880 if ${am_cv_python_version+:} false; then :
20881 $as_echo_n "(cached) " >&6
20882 else
20883 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
20884 fi
20885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
20886 $as_echo "$am_cv_python_version" >&6; }
20887 PYTHON_VERSION=$am_cv_python_version
20888
20889
20890
20891 PYTHON_PREFIX='${prefix}'
20892
20893 PYTHON_EXEC_PREFIX='${exec_prefix}'
20894
20895
20896
20897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
20898 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
20899 if ${am_cv_python_platform+:} false; then :
20900 $as_echo_n "(cached) " >&6
20901 else
20902 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
20903 fi
20904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
20905 $as_echo "$am_cv_python_platform" >&6; }
20906 PYTHON_PLATFORM=$am_cv_python_platform
20907
20908
20909 # Just factor out some code duplication.
20910 am_python_setup_sysconfig="\
20911 import sys
20912 # Prefer sysconfig over distutils.sysconfig, for better compatibility
20913 # with python 3.x. See automake bug#10227.
20914 try:
20915 import sysconfig
20916 except ImportError:
20917 can_use_sysconfig = 0
20918 else:
20919 can_use_sysconfig = 1
20920 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
20921 # <https://github.com/pypa/virtualenv/issues/118>
20922 try:
20923 from platform import python_implementation
20924 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
20925 can_use_sysconfig = 0
20926 except ImportError:
20927 pass"
20928
20929
20930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
20931 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
20932 if ${am_cv_python_pythondir+:} false; then :
20933 $as_echo_n "(cached) " >&6
20934 else
20935 if test "x$prefix" = xNONE
20936 then
20937 am_py_prefix=$ac_default_prefix
20938 else
20939 am_py_prefix=$prefix
20940 fi
20941 am_cv_python_pythondir=`$PYTHON -c "
20942 $am_python_setup_sysconfig
20943 if can_use_sysconfig:
20944 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
20945 else:
20946 from distutils import sysconfig
20947 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
20948 sys.stdout.write(sitedir)"`
20949 case $am_cv_python_pythondir in
20950 $am_py_prefix*)
20951 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
20952 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
20953 ;;
20954 *)
20955 case $am_py_prefix in
20956 /usr|/System*) ;;
20957 *)
20958 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
20959 ;;
20960 esac
20961 ;;
20962 esac
20963
20964 fi
20965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
20966 $as_echo "$am_cv_python_pythondir" >&6; }
20967 pythondir=$am_cv_python_pythondir
20968
20969
20970
20971 pkgpythondir=\${pythondir}/$PACKAGE
20972
20973
20974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
20975 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
20976 if ${am_cv_python_pyexecdir+:} false; then :
20977 $as_echo_n "(cached) " >&6
20978 else
20979 if test "x$exec_prefix" = xNONE
20980 then
20981 am_py_exec_prefix=$am_py_prefix
20982 else
20983 am_py_exec_prefix=$exec_prefix
20984 fi
20985 am_cv_python_pyexecdir=`$PYTHON -c "
20986 $am_python_setup_sysconfig
20987 if can_use_sysconfig:
20988 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
20989 else:
20990 from distutils import sysconfig
20991 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
20992 sys.stdout.write(sitedir)"`
20993 case $am_cv_python_pyexecdir in
20994 $am_py_exec_prefix*)
20995 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
20996 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
20997 ;;
20998 *)
20999 case $am_py_exec_prefix in
21000 /usr|/System*) ;;
21001 *)
21002 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
21003 ;;
21004 esac
21005 ;;
21006 esac
21007
21008 fi
21009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
21010 $as_echo "$am_cv_python_pyexecdir" >&6; }
21011 pyexecdir=$am_cv_python_pyexecdir
21012
21013
21014
21015 pkgpyexecdir=\${pyexecdir}/$PACKAGE
21016
21017
21018
21019
21020 #
21021 # Allow the use of a (user set) custom python version
21022 #
21023
21024
21025 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
21026 set dummy python$PYTHON_VERSION; ac_word=$2
21027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21028 $as_echo_n "checking for $ac_word... " >&6; }
21029 if ${ac_cv_path_PYTHON+:} false; then :
21030 $as_echo_n "(cached) " >&6
21031 else
21032 case $PYTHON in
21033 [\\/]* | ?:[\\/]*)
21034 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
21035 ;;
21036 *)
21037 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21038 for as_dir in $PATH
21039 do
21040 IFS=$as_save_IFS
21041 test -z "$as_dir" && as_dir=.
21042 for ac_exec_ext in '' $ac_executable_extensions; do
21043 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21044 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
21045 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21046 break 2
21047 fi
21048 done
21049 done
21050 IFS=$as_save_IFS
21051
21052 ;;
21053 esac
21054 fi
21055 PYTHON=$ac_cv_path_PYTHON
21056 if test -n "$PYTHON"; then
21057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
21058 $as_echo "$PYTHON" >&6; }
21059 else
21060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21061 $as_echo "no" >&6; }
21062 fi
21063
21064
21065 if test -z "$PYTHON"; then
21066 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
21067 PYTHON_VERSION=""
21068 fi
21069
21070 #
21071 # Check for a version of Python >= 2.1.0
21072 #
21073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
21074 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
21075 ac_supports_python_ver=`$PYTHON -c "import sys; \
21076 ver = sys.version.split ()[0]; \
21077 print (ver >= '2.1.0')"`
21078 if test "$ac_supports_python_ver" != "True"; then
21079 if test -z "$PYTHON_NOVERSIONCHECK"; then
21080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21081 $as_echo "no" >&6; }
21082 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
21083 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
21084 as_fn_error $? "
21085 This version of the AC_PYTHON_DEVEL macro
21086 doesn't work properly with versions of Python before
21087 2.1.0. You may need to re-run configure, setting the
21088 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
21089 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
21090 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
21091 to something else than an empty string.
21092
21093 See \`config.log' for more details" "$LINENO" 5; }
21094 else
21095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
21096 $as_echo "skip at user request" >&6; }
21097 fi
21098 else
21099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21100 $as_echo "yes" >&6; }
21101 fi
21102
21103 #
21104 # if the macro parameter ``version'' is set, honour it
21105 #
21106 if test -n ""; then
21107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
21108 $as_echo_n "checking for a version of Python ... " >&6; }
21109 ac_supports_python_ver=`$PYTHON -c "import sys; \
21110 ver = sys.version.split ()[0]; \
21111 print (ver )"`
21112 if test "$ac_supports_python_ver" = "True"; then
21113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21114 $as_echo "yes" >&6; }
21115 else
21116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21117 $as_echo "no" >&6; }
21118 as_fn_error $? "this package requires Python .
21119 If you have it installed, but it isn't the default Python
21120 interpreter in your system path, please pass the PYTHON_VERSION
21121 variable to configure. See \`\`configure --help'' for reference.
21122 " "$LINENO" 5
21123 PYTHON_VERSION=""
21124 fi
21125 fi
21126
21127 #
21128 # Check if you have distutils, else fail
21129 #
21130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
21131 $as_echo_n "checking for the distutils Python package... " >&6; }
21132 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
21133 if test -z "$ac_distutils_result"; then
21134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21135 $as_echo "yes" >&6; }
21136 else
21137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21138 $as_echo "no" >&6; }
21139 as_fn_error $? "cannot import Python module \"distutils\".
21140 Please check your Python installation. The error was:
21141 $ac_distutils_result" "$LINENO" 5
21142 PYTHON_VERSION=""
21143 fi
21144
21145 #
21146 # Check for Python include path
21147 #
21148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
21149 $as_echo_n "checking for Python include path... " >&6; }
21150 if test -z "$PYTHON_CPPFLAGS"; then
21151 python_path=`$PYTHON -c "import distutils.sysconfig; \
21152 print (distutils.sysconfig.get_python_inc ());"`
21153 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
21154 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
21155 if test -n "${python_path}"; then
21156 if test "${plat_python_path}" != "${python_path}"; then
21157 python_path="-I$python_path -I$plat_python_path"
21158 else
21159 python_path="-I$python_path"
21160 fi
21161 fi
21162 PYTHON_CPPFLAGS=$python_path
21163 fi
21164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
21165 $as_echo "$PYTHON_CPPFLAGS" >&6; }
21166
21167
21168 #
21169 # Check for Python library path
21170 #
21171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
21172 $as_echo_n "checking for Python library path... " >&6; }
21173 if test -z "$PYTHON_LDFLAGS"; then
21174 # (makes two attempts to ensure we've got a version number
21175 # from the interpreter)
21176 ac_python_version=`cat<<EOD | $PYTHON -
21177
21178 # join all versioning strings, on some systems
21179 # major/minor numbers could be in different list elements
21180 from distutils.sysconfig import *
21181 e = get_config_var('VERSION')
21182 if e is not None:
21183 print(e)
21184 EOD`
21185
21186 if test -z "$ac_python_version"; then
21187 if test -n "$PYTHON_VERSION"; then
21188 ac_python_version=$PYTHON_VERSION
21189 else
21190 ac_python_version=`$PYTHON -c "import sys; \
21191 print (sys.version[:3])"`
21192 fi
21193 fi
21194
21195 # Make the versioning information available to the compiler
21196
21197 # JW: We don't need it and it interferes with the hack
21198 # to detect multiple Pyhton versions
21199 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
21200 # [If available, contains the Python version number currently in use.])
21201
21202 # First, the library directory:
21203 ac_python_libdir=`cat<<EOD | $PYTHON -
21204
21205 # There should be only one
21206 import distutils.sysconfig
21207 e = distutils.sysconfig.get_config_var('LIBDIR')
21208 if e is not None:
21209 print (e)
21210 EOD`
21211
21212 # Now, for the library:
21213 ac_python_library=`cat<<EOD | $PYTHON -
21214
21215 import distutils.sysconfig
21216 c = distutils.sysconfig.get_config_vars()
21217 if 'LDVERSION' in c:
21218 print ('python'+c['LDVERSION'])
21219 else:
21220 print ('python'+c['VERSION'])
21221 EOD`
21222
21223 # This small piece shamelessly adapted from PostgreSQL python macro;
21224 # credits goes to momjian, I think. I'd like to put the right name
21225 # in the credits, if someone can point me in the right direction... ?
21226 #
21227 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
21228 then
21229 # use the official shared library
21230 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
21231 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
21232 else
21233 # old way: use libpython from python_configdir
21234 ac_python_libdir=`$PYTHON -c \
21235 "from distutils.sysconfig import get_python_lib as f; \
21236 import os; \
21237 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
21238 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
21239 fi
21240
21241 if test -z "PYTHON_LDFLAGS"; then
21242 as_fn_error $? "
21243 Cannot determine location of your Python DSO. Please check it was installed with
21244 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
21245 " "$LINENO" 5
21246 fi
21247 fi
21248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
21249 $as_echo "$PYTHON_LDFLAGS" >&6; }
21250
21251
21252 #
21253 # Check for site packages
21254 #
21255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
21256 $as_echo_n "checking for Python site-packages path... " >&6; }
21257 if test -z "$PYTHON_SITE_PKG"; then
21258 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
21259 print (distutils.sysconfig.get_python_lib(0,0));"`
21260 fi
21261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
21262 $as_echo "$PYTHON_SITE_PKG" >&6; }
21263
21264
21265 #
21266 # libraries which must be linked in when embedding
21267 #
21268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
21269 $as_echo_n "checking python extra libraries... " >&6; }
21270 if test -z "$PYTHON_EXTRA_LIBS"; then
21271 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
21272 conf = distutils.sysconfig.get_config_var; \
21273 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
21274 fi
21275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
21276 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
21277
21278
21279 #
21280 # linking flags needed when embedding
21281 #
21282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
21283 $as_echo_n "checking python extra linking flags... " >&6; }
21284 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
21285 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
21286 conf = distutils.sysconfig.get_config_var; \
21287 print (conf('LINKFORSHARED'))"`
21288 fi
21289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
21290 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
21291
21292
21293 #
21294 # final check to see if everything compiles alright
21295 #
21296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
21297 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
21298 # save current global flags
21299 ac_save_LIBS="$LIBS"
21300 ac_save_CPPFLAGS="$CPPFLAGS"
21301 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
21302 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
21303 ac_ext=c
21304 ac_cpp='$CPP $CPPFLAGS'
21305 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
21306 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
21307 ac_compiler_gnu=$ac_cv_c_compiler_gnu
21308
21309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21310 /* end confdefs.h. */
21311
21312 #include <Python.h>
21313 int
21314 main ()
21315 {
21316 Py_Initialize();
21317 ;
21318 return 0;
21319 }
21320
21321 _ACEOF
21322 if ac_fn_c_try_link "$LINENO"; then :
21323 pythonexists=yes
21324 else
21325 pythonexists=no
21326 fi
21327 rm -f core conftest.err conftest.$ac_objext \
21328 conftest$ac_exeext conftest.$ac_ext
21329 ac_ext=c
21330 ac_cpp='$CPP $CPPFLAGS'
21331 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
21332 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
21333 ac_compiler_gnu=$ac_cv_c_compiler_gnu
21334
21335 # turn back to default flags
21336 CPPFLAGS="$ac_save_CPPFLAGS"
21337 LIBS="$ac_save_LIBS"
21338
21339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
21340 $as_echo "$pythonexists" >&6; }
21341
21342 if test ! "x$pythonexists" = "xyes"; then
21343 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
21344 Could not link test program to Python. Maybe the main Python library has been
21345 installed in some non-standard library path. If so, pass it to configure,
21346 via the LDFLAGS environment variable.
21347 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
21348 ============================================================================
21349 You probably have to install the development version of the Python package
21350 for your distribution. The exact name of this package varies among them.
21351 ============================================================================
21352 " >&5
21353 $as_echo "$as_me: WARNING:
21354 Could not link test program to Python. Maybe the main Python library has been
21355 installed in some non-standard library path. If so, pass it to configure,
21356 via the LDFLAGS environment variable.
21357 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
21358 ============================================================================
21359 You probably have to install the development version of the Python package
21360 for your distribution. The exact name of this package varies among them.
21361 ============================================================================
21362 " >&2;}
21363 PYTHON_VERSION=""
21364 fi
21365
21366 #
21367 # all done!
21368 #
21369
21370 if test "$PYTHON_VERSION"; then
21371 PYTHONS="$(echo $PYTHONS $PYTHON)"
21372 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
21373 fi
21374
21375 fi
21376
21377
21378 unset PYTHON
21379 unset PYTHON_VERSION
21380 unset PYTHON_CPPFLAGS
21381 unset PYTHON_LDFLAGS
21382 unset PYTHON_SITE_PKG
21383 unset PYTHON_EXTRA_LIBS
21384 unset PYTHON_EXTRA_LDFLAGS
21385 unset ac_cv_path_PYTHON
21386 unset am_cv_pathless_PYTHON
21387 unset am_cv_python_version
21388 unset am_cv_python_platform
21389 unset am_cv_python_pythondir
21390 unset am_cv_python_pyexecdir
21391
21392
21393
21394
21395
21396
21397 if test -n "$PYTHON"; then
21398 # If the user set $PYTHON, use it and don't search something else.
21399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3.6" >&5
21400 $as_echo_n "checking whether $PYTHON version is >= 3.6... " >&6; }
21401 prog="import sys
21402 # split strings by '.' and convert to numeric. Append some zeros
21403 # because we need at least 4 digits for the hex conversion.
21404 # map returns an iterator in Python 3.0 and a list in 2.x
21405 minver = list(map(int, '3.6'.split('.'))) + [0, 0, 0]
21406 minverhex = 0
21407 # xrange is not present in Python 3.0 and range returns an iterator
21408 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
21409 sys.exit(sys.hexversion < minverhex)"
21410 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
21411 ($PYTHON -c "$prog") >&5 2>&5
21412 ac_status=$?
21413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21414 (exit $ac_status); }; then :
21415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21416 $as_echo "yes" >&6; }
21417 else
21418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21419 $as_echo "no" >&6; }
21420 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
21421 fi
21422 am_display_PYTHON=$PYTHON
21423 else
21424 # Otherwise, try each interpreter until we find one that satisfies
21425 # VERSION.
21426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3.6" >&5
21427 $as_echo_n "checking for a Python interpreter with version >= 3.6... " >&6; }
21428 if ${am_cv_pathless_PYTHON+:} false; then :
21429 $as_echo_n "(cached) " >&6
21430 else
21431
21432 for am_cv_pathless_PYTHON in python3.6 none; do
21433 test "$am_cv_pathless_PYTHON" = none && break
21434 prog="import sys
21435 # split strings by '.' and convert to numeric. Append some zeros
21436 # because we need at least 4 digits for the hex conversion.
21437 # map returns an iterator in Python 3.0 and a list in 2.x
21438 minver = list(map(int, '3.6'.split('.'))) + [0, 0, 0]
21439 minverhex = 0
21440 # xrange is not present in Python 3.0 and range returns an iterator
21441 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
21442 sys.exit(sys.hexversion < minverhex)"
21443 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
21444 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
21445 ac_status=$?
21446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21447 (exit $ac_status); }; then :
21448 break
21449 fi
21450 done
21451 fi
21452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
21453 $as_echo "$am_cv_pathless_PYTHON" >&6; }
21454 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
21455 if test "$am_cv_pathless_PYTHON" = none; then
21456 PYTHON=:
21457 else
21458 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
21459 set dummy $am_cv_pathless_PYTHON; ac_word=$2
21460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21461 $as_echo_n "checking for $ac_word... " >&6; }
21462 if ${ac_cv_path_PYTHON+:} false; then :
21463 $as_echo_n "(cached) " >&6
21464 else
21465 case $PYTHON in
21466 [\\/]* | ?:[\\/]*)
21467 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
21468 ;;
21469 *)
21470 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21471 for as_dir in $PATH
21472 do
21473 IFS=$as_save_IFS
21474 test -z "$as_dir" && as_dir=.
21475 for ac_exec_ext in '' $ac_executable_extensions; do
21476 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21477 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
21478 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21479 break 2
21480 fi
21481 done
21482 done
21483 IFS=$as_save_IFS
21484
21485 ;;
21486 esac
21487 fi
21488 PYTHON=$ac_cv_path_PYTHON
21489 if test -n "$PYTHON"; then
21490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
21491 $as_echo "$PYTHON" >&6; }
21492 else
21493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21494 $as_echo "no" >&6; }
21495 fi
21496
21497
21498 fi
21499 am_display_PYTHON=$am_cv_pathless_PYTHON
21500 fi
21501
21502
21503 if test "$PYTHON" = :; then
21504 :
21505 else
21506
21507
21508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
21509 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
21510 if ${am_cv_python_version+:} false; then :
21511 $as_echo_n "(cached) " >&6
21512 else
21513 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
21514 fi
21515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
21516 $as_echo "$am_cv_python_version" >&6; }
21517 PYTHON_VERSION=$am_cv_python_version
21518
21519
21520
21521 PYTHON_PREFIX='${prefix}'
21522
21523 PYTHON_EXEC_PREFIX='${exec_prefix}'
21524
21525
21526
21527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
21528 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
21529 if ${am_cv_python_platform+:} false; then :
21530 $as_echo_n "(cached) " >&6
21531 else
21532 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
21533 fi
21534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
21535 $as_echo "$am_cv_python_platform" >&6; }
21536 PYTHON_PLATFORM=$am_cv_python_platform
21537
21538
21539 # Just factor out some code duplication.
21540 am_python_setup_sysconfig="\
21541 import sys
21542 # Prefer sysconfig over distutils.sysconfig, for better compatibility
21543 # with python 3.x. See automake bug#10227.
21544 try:
21545 import sysconfig
21546 except ImportError:
21547 can_use_sysconfig = 0
21548 else:
21549 can_use_sysconfig = 1
21550 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
21551 # <https://github.com/pypa/virtualenv/issues/118>
21552 try:
21553 from platform import python_implementation
21554 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
21555 can_use_sysconfig = 0
21556 except ImportError:
21557 pass"
21558
21559
21560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
21561 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
21562 if ${am_cv_python_pythondir+:} false; then :
21563 $as_echo_n "(cached) " >&6
21564 else
21565 if test "x$prefix" = xNONE
21566 then
21567 am_py_prefix=$ac_default_prefix
21568 else
21569 am_py_prefix=$prefix
21570 fi
21571 am_cv_python_pythondir=`$PYTHON -c "
21572 $am_python_setup_sysconfig
21573 if can_use_sysconfig:
21574 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
21575 else:
21576 from distutils import sysconfig
21577 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
21578 sys.stdout.write(sitedir)"`
21579 case $am_cv_python_pythondir in
21580 $am_py_prefix*)
21581 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
21582 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
21583 ;;
21584 *)
21585 case $am_py_prefix in
21586 /usr|/System*) ;;
21587 *)
21588 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
21589 ;;
21590 esac
21591 ;;
21592 esac
21593
21594 fi
21595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
21596 $as_echo "$am_cv_python_pythondir" >&6; }
21597 pythondir=$am_cv_python_pythondir
21598
21599
21600
21601 pkgpythondir=\${pythondir}/$PACKAGE
21602
21603
21604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
21605 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
21606 if ${am_cv_python_pyexecdir+:} false; then :
21607 $as_echo_n "(cached) " >&6
21608 else
21609 if test "x$exec_prefix" = xNONE
21610 then
21611 am_py_exec_prefix=$am_py_prefix
21612 else
21613 am_py_exec_prefix=$exec_prefix
21614 fi
21615 am_cv_python_pyexecdir=`$PYTHON -c "
21616 $am_python_setup_sysconfig
21617 if can_use_sysconfig:
21618 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
21619 else:
21620 from distutils import sysconfig
21621 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
21622 sys.stdout.write(sitedir)"`
21623 case $am_cv_python_pyexecdir in
21624 $am_py_exec_prefix*)
21625 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
21626 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
21627 ;;
21628 *)
21629 case $am_py_exec_prefix in
21630 /usr|/System*) ;;
21631 *)
21632 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
21633 ;;
21634 esac
21635 ;;
21636 esac
21637
21638 fi
21639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
21640 $as_echo "$am_cv_python_pyexecdir" >&6; }
21641 pyexecdir=$am_cv_python_pyexecdir
21642
21643
21644
21645 pkgpyexecdir=\${pyexecdir}/$PACKAGE
21646
21647
21648
21649
21650 #
21651 # Allow the use of a (user set) custom python version
21652 #
21653
21654
21655 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
21656 set dummy python$PYTHON_VERSION; ac_word=$2
21657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21658 $as_echo_n "checking for $ac_word... " >&6; }
21659 if ${ac_cv_path_PYTHON+:} false; then :
21660 $as_echo_n "(cached) " >&6
21661 else
21662 case $PYTHON in
21663 [\\/]* | ?:[\\/]*)
21664 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
21665 ;;
21666 *)
21667 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21668 for as_dir in $PATH
21669 do
21670 IFS=$as_save_IFS
21671 test -z "$as_dir" && as_dir=.
21672 for ac_exec_ext in '' $ac_executable_extensions; do
21673 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21674 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
21675 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21676 break 2
21677 fi
21678 done
21679 done
21680 IFS=$as_save_IFS
21681
21682 ;;
21683 esac
21684 fi
21685 PYTHON=$ac_cv_path_PYTHON
21686 if test -n "$PYTHON"; then
21687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
21688 $as_echo "$PYTHON" >&6; }
21689 else
21690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21691 $as_echo "no" >&6; }
21692 fi
21693
21694
21695 if test -z "$PYTHON"; then
21696 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
21697 PYTHON_VERSION=""
21698 fi
21699
21700 #
21701 # Check for a version of Python >= 2.1.0
21702 #
21703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
21704 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
21705 ac_supports_python_ver=`$PYTHON -c "import sys; \
21706 ver = sys.version.split ()[0]; \
21707 print (ver >= '2.1.0')"`
21708 if test "$ac_supports_python_ver" != "True"; then
21709 if test -z "$PYTHON_NOVERSIONCHECK"; then
21710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21711 $as_echo "no" >&6; }
21712 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
21713 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
21714 as_fn_error $? "
21715 This version of the AC_PYTHON_DEVEL macro
21716 doesn't work properly with versions of Python before
21717 2.1.0. You may need to re-run configure, setting the
21718 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
21719 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
21720 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
21721 to something else than an empty string.
21722
21723 See \`config.log' for more details" "$LINENO" 5; }
21724 else
21725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
21726 $as_echo "skip at user request" >&6; }
21727 fi
21728 else
21729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21730 $as_echo "yes" >&6; }
21731 fi
21732
21733 #
21734 # if the macro parameter ``version'' is set, honour it
21735 #
21736 if test -n ""; then
21737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
21738 $as_echo_n "checking for a version of Python ... " >&6; }
21739 ac_supports_python_ver=`$PYTHON -c "import sys; \
21740 ver = sys.version.split ()[0]; \
21741 print (ver )"`
21742 if test "$ac_supports_python_ver" = "True"; then
21743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21744 $as_echo "yes" >&6; }
21745 else
21746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21747 $as_echo "no" >&6; }
21748 as_fn_error $? "this package requires Python .
21749 If you have it installed, but it isn't the default Python
21750 interpreter in your system path, please pass the PYTHON_VERSION
21751 variable to configure. See \`\`configure --help'' for reference.
21752 " "$LINENO" 5
21753 PYTHON_VERSION=""
21754 fi
21755 fi
21756
21757 #
21758 # Check if you have distutils, else fail
21759 #
21760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
21761 $as_echo_n "checking for the distutils Python package... " >&6; }
21762 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
21763 if test -z "$ac_distutils_result"; then
21764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21765 $as_echo "yes" >&6; }
21766 else
21767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21768 $as_echo "no" >&6; }
21769 as_fn_error $? "cannot import Python module \"distutils\".
21770 Please check your Python installation. The error was:
21771 $ac_distutils_result" "$LINENO" 5
21772 PYTHON_VERSION=""
21773 fi
21774
21775 #
21776 # Check for Python include path
21777 #
21778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
21779 $as_echo_n "checking for Python include path... " >&6; }
21780 if test -z "$PYTHON_CPPFLAGS"; then
21781 python_path=`$PYTHON -c "import distutils.sysconfig; \
21782 print (distutils.sysconfig.get_python_inc ());"`
21783 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
21784 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
21785 if test -n "${python_path}"; then
21786 if test "${plat_python_path}" != "${python_path}"; then
21787 python_path="-I$python_path -I$plat_python_path"
21788 else
21789 python_path="-I$python_path"
21790 fi
21791 fi
21792 PYTHON_CPPFLAGS=$python_path
21793 fi
21794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
21795 $as_echo "$PYTHON_CPPFLAGS" >&6; }
21796
21797
21798 #
21799 # Check for Python library path
21800 #
21801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
21802 $as_echo_n "checking for Python library path... " >&6; }
21803 if test -z "$PYTHON_LDFLAGS"; then
21804 # (makes two attempts to ensure we've got a version number
21805 # from the interpreter)
21806 ac_python_version=`cat<<EOD | $PYTHON -
21807
21808 # join all versioning strings, on some systems
21809 # major/minor numbers could be in different list elements
21810 from distutils.sysconfig import *
21811 e = get_config_var('VERSION')
21812 if e is not None:
21813 print(e)
21814 EOD`
21815
21816 if test -z "$ac_python_version"; then
21817 if test -n "$PYTHON_VERSION"; then
21818 ac_python_version=$PYTHON_VERSION
21819 else
21820 ac_python_version=`$PYTHON -c "import sys; \
21821 print (sys.version[:3])"`
21822 fi
21823 fi
21824
21825 # Make the versioning information available to the compiler
21826
21827 # JW: We don't need it and it interferes with the hack
21828 # to detect multiple Pyhton versions
21829 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
21830 # [If available, contains the Python version number currently in use.])
21831
21832 # First, the library directory:
21833 ac_python_libdir=`cat<<EOD | $PYTHON -
21834
21835 # There should be only one
21836 import distutils.sysconfig
21837 e = distutils.sysconfig.get_config_var('LIBDIR')
21838 if e is not None:
21839 print (e)
21840 EOD`
21841
21842 # Now, for the library:
21843 ac_python_library=`cat<<EOD | $PYTHON -
21844
21845 import distutils.sysconfig
21846 c = distutils.sysconfig.get_config_vars()
21847 if 'LDVERSION' in c:
21848 print ('python'+c['LDVERSION'])
21849 else:
21850 print ('python'+c['VERSION'])
21851 EOD`
21852
21853 # This small piece shamelessly adapted from PostgreSQL python macro;
21854 # credits goes to momjian, I think. I'd like to put the right name
21855 # in the credits, if someone can point me in the right direction... ?
21856 #
21857 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
21858 then
21859 # use the official shared library
21860 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
21861 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
21862 else
21863 # old way: use libpython from python_configdir
21864 ac_python_libdir=`$PYTHON -c \
21865 "from distutils.sysconfig import get_python_lib as f; \
21866 import os; \
21867 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
21868 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
21869 fi
21870
21871 if test -z "PYTHON_LDFLAGS"; then
21872 as_fn_error $? "
21873 Cannot determine location of your Python DSO. Please check it was installed with
21874 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
21875 " "$LINENO" 5
21876 fi
21877 fi
21878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
21879 $as_echo "$PYTHON_LDFLAGS" >&6; }
21880
21881
21882 #
21883 # Check for site packages
21884 #
21885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
21886 $as_echo_n "checking for Python site-packages path... " >&6; }
21887 if test -z "$PYTHON_SITE_PKG"; then
21888 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
21889 print (distutils.sysconfig.get_python_lib(0,0));"`
21890 fi
21891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
21892 $as_echo "$PYTHON_SITE_PKG" >&6; }
21893
21894
21895 #
21896 # libraries which must be linked in when embedding
21897 #
21898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
21899 $as_echo_n "checking python extra libraries... " >&6; }
21900 if test -z "$PYTHON_EXTRA_LIBS"; then
21901 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
21902 conf = distutils.sysconfig.get_config_var; \
21903 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
21904 fi
21905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
21906 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
21907
21908
21909 #
21910 # linking flags needed when embedding
21911 #
21912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
21913 $as_echo_n "checking python extra linking flags... " >&6; }
21914 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
21915 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
21916 conf = distutils.sysconfig.get_config_var; \
21917 print (conf('LINKFORSHARED'))"`
21918 fi
21919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
21920 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
21921
21922
21923 #
21924 # final check to see if everything compiles alright
21925 #
21926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
21927 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
21928 # save current global flags
21929 ac_save_LIBS="$LIBS"
21930 ac_save_CPPFLAGS="$CPPFLAGS"
21931 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
21932 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
21933 ac_ext=c
21934 ac_cpp='$CPP $CPPFLAGS'
21935 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
21936 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
21937 ac_compiler_gnu=$ac_cv_c_compiler_gnu
21938
21939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21940 /* end confdefs.h. */
21941
21942 #include <Python.h>
21943 int
21944 main ()
21945 {
21946 Py_Initialize();
21947 ;
21948 return 0;
21949 }
21950
21951 _ACEOF
21952 if ac_fn_c_try_link "$LINENO"; then :
21953 pythonexists=yes
21954 else
21955 pythonexists=no
21956 fi
21957 rm -f core conftest.err conftest.$ac_objext \
21958 conftest$ac_exeext conftest.$ac_ext
21959 ac_ext=c
21960 ac_cpp='$CPP $CPPFLAGS'
21961 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
21962 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
21963 ac_compiler_gnu=$ac_cv_c_compiler_gnu
21964
21965 # turn back to default flags
21966 CPPFLAGS="$ac_save_CPPFLAGS"
21967 LIBS="$ac_save_LIBS"
21968
21969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
21970 $as_echo "$pythonexists" >&6; }
21971
21972 if test ! "x$pythonexists" = "xyes"; then
21973 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
21974 Could not link test program to Python. Maybe the main Python library has been
21975 installed in some non-standard library path. If so, pass it to configure,
21976 via the LDFLAGS environment variable.
21977 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
21978 ============================================================================
21979 You probably have to install the development version of the Python package
21980 for your distribution. The exact name of this package varies among them.
21981 ============================================================================
21982 " >&5
21983 $as_echo "$as_me: WARNING:
21984 Could not link test program to Python. Maybe the main Python library has been
21985 installed in some non-standard library path. If so, pass it to configure,
21986 via the LDFLAGS environment variable.
21987 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
21988 ============================================================================
21989 You probably have to install the development version of the Python package
21990 for your distribution. The exact name of this package varies among them.
21991 ============================================================================
21992 " >&2;}
21993 PYTHON_VERSION=""
21994 fi
21995
21996 #
21997 # all done!
21998 #
21999
22000 if test "$PYTHON_VERSION"; then
22001 PYTHONS="$(echo $PYTHONS $PYTHON)"
22002 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
22003 fi
22004
22005 fi
22006
22007
22008 unset PYTHON
22009 unset PYTHON_VERSION
22010 unset PYTHON_CPPFLAGS
22011 unset PYTHON_LDFLAGS
22012 unset PYTHON_SITE_PKG
22013 unset PYTHON_EXTRA_LIBS
22014 unset PYTHON_EXTRA_LDFLAGS
22015 unset ac_cv_path_PYTHON
22016 unset am_cv_pathless_PYTHON
22017 unset am_cv_python_version
22018 unset am_cv_python_platform
22019 unset am_cv_python_pythondir
22020 unset am_cv_python_pyexecdir
22021
22022
22023
22024
22025
22026
22027 if test -n "$PYTHON"; then
22028 # If the user set $PYTHON, use it and don't search something else.
22029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3.7" >&5
22030 $as_echo_n "checking whether $PYTHON version is >= 3.7... " >&6; }
22031 prog="import sys
22032 # split strings by '.' and convert to numeric. Append some zeros
22033 # because we need at least 4 digits for the hex conversion.
22034 # map returns an iterator in Python 3.0 and a list in 2.x
22035 minver = list(map(int, '3.7'.split('.'))) + [0, 0, 0]
22036 minverhex = 0
22037 # xrange is not present in Python 3.0 and range returns an iterator
22038 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
22039 sys.exit(sys.hexversion < minverhex)"
22040 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
22041 ($PYTHON -c "$prog") >&5 2>&5
22042 ac_status=$?
22043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22044 (exit $ac_status); }; then :
22045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22046 $as_echo "yes" >&6; }
22047 else
22048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22049 $as_echo "no" >&6; }
22050 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
22051 fi
22052 am_display_PYTHON=$PYTHON
22053 else
22054 # Otherwise, try each interpreter until we find one that satisfies
22055 # VERSION.
22056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3.7" >&5
22057 $as_echo_n "checking for a Python interpreter with version >= 3.7... " >&6; }
22058 if ${am_cv_pathless_PYTHON+:} false; then :
22059 $as_echo_n "(cached) " >&6
22060 else
22061
22062 for am_cv_pathless_PYTHON in python3.7 none; do
22063 test "$am_cv_pathless_PYTHON" = none && break
22064 prog="import sys
22065 # split strings by '.' and convert to numeric. Append some zeros
22066 # because we need at least 4 digits for the hex conversion.
22067 # map returns an iterator in Python 3.0 and a list in 2.x
22068 minver = list(map(int, '3.7'.split('.'))) + [0, 0, 0]
22069 minverhex = 0
22070 # xrange is not present in Python 3.0 and range returns an iterator
22071 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
22072 sys.exit(sys.hexversion < minverhex)"
22073 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
22074 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
22075 ac_status=$?
22076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22077 (exit $ac_status); }; then :
22078 break
22079 fi
22080 done
22081 fi
22082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
22083 $as_echo "$am_cv_pathless_PYTHON" >&6; }
22084 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
22085 if test "$am_cv_pathless_PYTHON" = none; then
22086 PYTHON=:
22087 else
22088 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
22089 set dummy $am_cv_pathless_PYTHON; ac_word=$2
22090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22091 $as_echo_n "checking for $ac_word... " >&6; }
22092 if ${ac_cv_path_PYTHON+:} false; then :
22093 $as_echo_n "(cached) " >&6
22094 else
22095 case $PYTHON in
22096 [\\/]* | ?:[\\/]*)
22097 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
22098 ;;
22099 *)
22100 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22101 for as_dir in $PATH
22102 do
22103 IFS=$as_save_IFS
22104 test -z "$as_dir" && as_dir=.
22105 for ac_exec_ext in '' $ac_executable_extensions; do
22106 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22107 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
22108 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22109 break 2
22110 fi
22111 done
22112 done
22113 IFS=$as_save_IFS
22114
22115 ;;
22116 esac
22117 fi
22118 PYTHON=$ac_cv_path_PYTHON
22119 if test -n "$PYTHON"; then
22120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
22121 $as_echo "$PYTHON" >&6; }
22122 else
22123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22124 $as_echo "no" >&6; }
22125 fi
22126
22127
22128 fi
22129 am_display_PYTHON=$am_cv_pathless_PYTHON
22130 fi
22131
22132
22133 if test "$PYTHON" = :; then
22134 :
22135 else
22136
22137
22138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
22139 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
22140 if ${am_cv_python_version+:} false; then :
22141 $as_echo_n "(cached) " >&6
22142 else
22143 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
22144 fi
22145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
22146 $as_echo "$am_cv_python_version" >&6; }
22147 PYTHON_VERSION=$am_cv_python_version
22148
22149
22150
22151 PYTHON_PREFIX='${prefix}'
22152
22153 PYTHON_EXEC_PREFIX='${exec_prefix}'
22154
22155
22156
22157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
22158 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
22159 if ${am_cv_python_platform+:} false; then :
22160 $as_echo_n "(cached) " >&6
22161 else
22162 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
22163 fi
22164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
22165 $as_echo "$am_cv_python_platform" >&6; }
22166 PYTHON_PLATFORM=$am_cv_python_platform
22167
22168
22169 # Just factor out some code duplication.
22170 am_python_setup_sysconfig="\
22171 import sys
22172 # Prefer sysconfig over distutils.sysconfig, for better compatibility
22173 # with python 3.x. See automake bug#10227.
22174 try:
22175 import sysconfig
22176 except ImportError:
22177 can_use_sysconfig = 0
22178 else:
22179 can_use_sysconfig = 1
22180 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
22181 # <https://github.com/pypa/virtualenv/issues/118>
22182 try:
22183 from platform import python_implementation
22184 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
22185 can_use_sysconfig = 0
22186 except ImportError:
22187 pass"
22188
22189
22190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
22191 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
22192 if ${am_cv_python_pythondir+:} false; then :
22193 $as_echo_n "(cached) " >&6
22194 else
22195 if test "x$prefix" = xNONE
22196 then
22197 am_py_prefix=$ac_default_prefix
22198 else
22199 am_py_prefix=$prefix
22200 fi
22201 am_cv_python_pythondir=`$PYTHON -c "
22202 $am_python_setup_sysconfig
22203 if can_use_sysconfig:
22204 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
22205 else:
22206 from distutils import sysconfig
22207 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
22208 sys.stdout.write(sitedir)"`
22209 case $am_cv_python_pythondir in
22210 $am_py_prefix*)
22211 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
22212 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
22213 ;;
22214 *)
22215 case $am_py_prefix in
22216 /usr|/System*) ;;
22217 *)
22218 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
22219 ;;
22220 esac
22221 ;;
22222 esac
22223
22224 fi
22225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
22226 $as_echo "$am_cv_python_pythondir" >&6; }
22227 pythondir=$am_cv_python_pythondir
22228
22229
22230
22231 pkgpythondir=\${pythondir}/$PACKAGE
22232
22233
22234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
22235 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
22236 if ${am_cv_python_pyexecdir+:} false; then :
22237 $as_echo_n "(cached) " >&6
22238 else
22239 if test "x$exec_prefix" = xNONE
22240 then
22241 am_py_exec_prefix=$am_py_prefix
22242 else
22243 am_py_exec_prefix=$exec_prefix
22244 fi
22245 am_cv_python_pyexecdir=`$PYTHON -c "
22246 $am_python_setup_sysconfig
22247 if can_use_sysconfig:
22248 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
22249 else:
22250 from distutils import sysconfig
22251 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
22252 sys.stdout.write(sitedir)"`
22253 case $am_cv_python_pyexecdir in
22254 $am_py_exec_prefix*)
22255 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
22256 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
22257 ;;
22258 *)
22259 case $am_py_exec_prefix in
22260 /usr|/System*) ;;
22261 *)
22262 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
22263 ;;
22264 esac
22265 ;;
22266 esac
22267
22268 fi
22269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
22270 $as_echo "$am_cv_python_pyexecdir" >&6; }
22271 pyexecdir=$am_cv_python_pyexecdir
22272
22273
22274
22275 pkgpyexecdir=\${pyexecdir}/$PACKAGE
22276
22277
22278
22279
22280 #
22281 # Allow the use of a (user set) custom python version
22282 #
22283
22284
22285 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
22286 set dummy python$PYTHON_VERSION; ac_word=$2
22287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22288 $as_echo_n "checking for $ac_word... " >&6; }
22289 if ${ac_cv_path_PYTHON+:} false; then :
22290 $as_echo_n "(cached) " >&6
22291 else
22292 case $PYTHON in
22293 [\\/]* | ?:[\\/]*)
22294 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
22295 ;;
22296 *)
22297 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22298 for as_dir in $PATH
22299 do
22300 IFS=$as_save_IFS
22301 test -z "$as_dir" && as_dir=.
22302 for ac_exec_ext in '' $ac_executable_extensions; do
22303 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22304 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
22305 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22306 break 2
22307 fi
22308 done
22309 done
22310 IFS=$as_save_IFS
22311
22312 ;;
22313 esac
22314 fi
22315 PYTHON=$ac_cv_path_PYTHON
22316 if test -n "$PYTHON"; then
22317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
22318 $as_echo "$PYTHON" >&6; }
22319 else
22320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22321 $as_echo "no" >&6; }
22322 fi
22323
22324
22325 if test -z "$PYTHON"; then
22326 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
22327 PYTHON_VERSION=""
22328 fi
22329
22330 #
22331 # Check for a version of Python >= 2.1.0
22332 #
22333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
22334 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
22335 ac_supports_python_ver=`$PYTHON -c "import sys; \
22336 ver = sys.version.split ()[0]; \
22337 print (ver >= '2.1.0')"`
22338 if test "$ac_supports_python_ver" != "True"; then
22339 if test -z "$PYTHON_NOVERSIONCHECK"; then
22340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22341 $as_echo "no" >&6; }
22342 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22343 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22344 as_fn_error $? "
22345 This version of the AC_PYTHON_DEVEL macro
22346 doesn't work properly with versions of Python before
22347 2.1.0. You may need to re-run configure, setting the
22348 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
22349 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
22350 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
22351 to something else than an empty string.
22352
22353 See \`config.log' for more details" "$LINENO" 5; }
22354 else
22355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
22356 $as_echo "skip at user request" >&6; }
22357 fi
22358 else
22359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22360 $as_echo "yes" >&6; }
22361 fi
22362
22363 #
22364 # if the macro parameter ``version'' is set, honour it
22365 #
22366 if test -n ""; then
22367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
22368 $as_echo_n "checking for a version of Python ... " >&6; }
22369 ac_supports_python_ver=`$PYTHON -c "import sys; \
22370 ver = sys.version.split ()[0]; \
22371 print (ver )"`
22372 if test "$ac_supports_python_ver" = "True"; then
22373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22374 $as_echo "yes" >&6; }
22375 else
22376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22377 $as_echo "no" >&6; }
22378 as_fn_error $? "this package requires Python .
22379 If you have it installed, but it isn't the default Python
22380 interpreter in your system path, please pass the PYTHON_VERSION
22381 variable to configure. See \`\`configure --help'' for reference.
22382 " "$LINENO" 5
22383 PYTHON_VERSION=""
22384 fi
22385 fi
22386
22387 #
22388 # Check if you have distutils, else fail
22389 #
22390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
22391 $as_echo_n "checking for the distutils Python package... " >&6; }
22392 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
22393 if test -z "$ac_distutils_result"; then
22394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22395 $as_echo "yes" >&6; }
22396 else
22397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22398 $as_echo "no" >&6; }
22399 as_fn_error $? "cannot import Python module \"distutils\".
22400 Please check your Python installation. The error was:
22401 $ac_distutils_result" "$LINENO" 5
22402 PYTHON_VERSION=""
22403 fi
22404
22405 #
22406 # Check for Python include path
22407 #
22408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
22409 $as_echo_n "checking for Python include path... " >&6; }
22410 if test -z "$PYTHON_CPPFLAGS"; then
22411 python_path=`$PYTHON -c "import distutils.sysconfig; \
22412 print (distutils.sysconfig.get_python_inc ());"`
22413 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
22414 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
22415 if test -n "${python_path}"; then
22416 if test "${plat_python_path}" != "${python_path}"; then
22417 python_path="-I$python_path -I$plat_python_path"
22418 else
22419 python_path="-I$python_path"
22420 fi
22421 fi
22422 PYTHON_CPPFLAGS=$python_path
22423 fi
22424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
22425 $as_echo "$PYTHON_CPPFLAGS" >&6; }
22426
22427
22428 #
22429 # Check for Python library path
22430 #
22431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
22432 $as_echo_n "checking for Python library path... " >&6; }
22433 if test -z "$PYTHON_LDFLAGS"; then
22434 # (makes two attempts to ensure we've got a version number
22435 # from the interpreter)
22436 ac_python_version=`cat<<EOD | $PYTHON -
22437
22438 # join all versioning strings, on some systems
22439 # major/minor numbers could be in different list elements
22440 from distutils.sysconfig import *
22441 e = get_config_var('VERSION')
22442 if e is not None:
22443 print(e)
22444 EOD`
22445
22446 if test -z "$ac_python_version"; then
22447 if test -n "$PYTHON_VERSION"; then
22448 ac_python_version=$PYTHON_VERSION
22449 else
22450 ac_python_version=`$PYTHON -c "import sys; \
22451 print (sys.version[:3])"`
22452 fi
22453 fi
22454
22455 # Make the versioning information available to the compiler
22456
22457 # JW: We don't need it and it interferes with the hack
22458 # to detect multiple Pyhton versions
22459 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
22460 # [If available, contains the Python version number currently in use.])
22461
22462 # First, the library directory:
22463 ac_python_libdir=`cat<<EOD | $PYTHON -
22464
22465 # There should be only one
22466 import distutils.sysconfig
22467 e = distutils.sysconfig.get_config_var('LIBDIR')
22468 if e is not None:
22469 print (e)
22470 EOD`
22471
22472 # Now, for the library:
22473 ac_python_library=`cat<<EOD | $PYTHON -
22474
22475 import distutils.sysconfig
22476 c = distutils.sysconfig.get_config_vars()
22477 if 'LDVERSION' in c:
22478 print ('python'+c['LDVERSION'])
22479 else:
22480 print ('python'+c['VERSION'])
22481 EOD`
22482
22483 # This small piece shamelessly adapted from PostgreSQL python macro;
22484 # credits goes to momjian, I think. I'd like to put the right name
22485 # in the credits, if someone can point me in the right direction... ?
22486 #
22487 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
22488 then
22489 # use the official shared library
22490 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
22491 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
22492 else
22493 # old way: use libpython from python_configdir
22494 ac_python_libdir=`$PYTHON -c \
22495 "from distutils.sysconfig import get_python_lib as f; \
22496 import os; \
22497 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
22498 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
22499 fi
22500
22501 if test -z "PYTHON_LDFLAGS"; then
22502 as_fn_error $? "
22503 Cannot determine location of your Python DSO. Please check it was installed with
22504 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
22505 " "$LINENO" 5
22506 fi
22507 fi
22508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
22509 $as_echo "$PYTHON_LDFLAGS" >&6; }
22510
22511
22512 #
22513 # Check for site packages
22514 #
22515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
22516 $as_echo_n "checking for Python site-packages path... " >&6; }
22517 if test -z "$PYTHON_SITE_PKG"; then
22518 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
22519 print (distutils.sysconfig.get_python_lib(0,0));"`
22520 fi
22521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
22522 $as_echo "$PYTHON_SITE_PKG" >&6; }
22523
22524
22525 #
22526 # libraries which must be linked in when embedding
22527 #
22528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
22529 $as_echo_n "checking python extra libraries... " >&6; }
22530 if test -z "$PYTHON_EXTRA_LIBS"; then
22531 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
22532 conf = distutils.sysconfig.get_config_var; \
22533 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
22534 fi
22535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
22536 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
22537
22538
22539 #
22540 # linking flags needed when embedding
22541 #
22542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
22543 $as_echo_n "checking python extra linking flags... " >&6; }
22544 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
22545 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
22546 conf = distutils.sysconfig.get_config_var; \
22547 print (conf('LINKFORSHARED'))"`
22548 fi
22549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
22550 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
22551
22552
22553 #
22554 # final check to see if everything compiles alright
22555 #
22556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
22557 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
22558 # save current global flags
22559 ac_save_LIBS="$LIBS"
22560 ac_save_CPPFLAGS="$CPPFLAGS"
22561 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
22562 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
22563 ac_ext=c
22564 ac_cpp='$CPP $CPPFLAGS'
22565 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22566 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22567 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22568
22569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22570 /* end confdefs.h. */
22571
22572 #include <Python.h>
22573 int
22574 main ()
22575 {
22576 Py_Initialize();
22577 ;
22578 return 0;
22579 }
22580
22581 _ACEOF
22582 if ac_fn_c_try_link "$LINENO"; then :
22583 pythonexists=yes
22584 else
22585 pythonexists=no
22586 fi
22587 rm -f core conftest.err conftest.$ac_objext \
22588 conftest$ac_exeext conftest.$ac_ext
22589 ac_ext=c
22590 ac_cpp='$CPP $CPPFLAGS'
22591 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22592 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22593 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22594
22595 # turn back to default flags
22596 CPPFLAGS="$ac_save_CPPFLAGS"
22597 LIBS="$ac_save_LIBS"
22598
22599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
22600 $as_echo "$pythonexists" >&6; }
22601
22602 if test ! "x$pythonexists" = "xyes"; then
22603 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
22604 Could not link test program to Python. Maybe the main Python library has been
22605 installed in some non-standard library path. If so, pass it to configure,
22606 via the LDFLAGS environment variable.
22607 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
22608 ============================================================================
22609 You probably have to install the development version of the Python package
22610 for your distribution. The exact name of this package varies among them.
22611 ============================================================================
22612 " >&5
22613 $as_echo "$as_me: WARNING:
22614 Could not link test program to Python. Maybe the main Python library has been
22615 installed in some non-standard library path. If so, pass it to configure,
22616 via the LDFLAGS environment variable.
22617 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
22618 ============================================================================
22619 You probably have to install the development version of the Python package
22620 for your distribution. The exact name of this package varies among them.
22621 ============================================================================
22622 " >&2;}
22623 PYTHON_VERSION=""
22624 fi
22625
22626 #
22627 # all done!
22628 #
22629
22630 if test "$PYTHON_VERSION"; then
22631 PYTHONS="$(echo $PYTHONS $PYTHON)"
22632 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
22633 fi
22634
22635 fi
22636
22637
22638 unset PYTHON
22639 unset PYTHON_VERSION
22640 unset PYTHON_CPPFLAGS
22641 unset PYTHON_LDFLAGS
22642 unset PYTHON_SITE_PKG
22643 unset PYTHON_EXTRA_LIBS
22644 unset PYTHON_EXTRA_LDFLAGS
22645 unset ac_cv_path_PYTHON
22646 unset am_cv_pathless_PYTHON
22647 unset am_cv_python_version
22648 unset am_cv_python_platform
22649 unset am_cv_python_pythondir
22650 unset am_cv_python_pyexecdir
22651
22652
22653
22654
22655
22656
22657 if test -n "$PYTHON"; then
22658 # If the user set $PYTHON, use it and don't search something else.
22659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3.8" >&5
22660 $as_echo_n "checking whether $PYTHON version is >= 3.8... " >&6; }
22661 prog="import sys
22662 # split strings by '.' and convert to numeric. Append some zeros
22663 # because we need at least 4 digits for the hex conversion.
22664 # map returns an iterator in Python 3.0 and a list in 2.x
22665 minver = list(map(int, '3.8'.split('.'))) + [0, 0, 0]
22666 minverhex = 0
22667 # xrange is not present in Python 3.0 and range returns an iterator
22668 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
22669 sys.exit(sys.hexversion < minverhex)"
22670 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
22671 ($PYTHON -c "$prog") >&5 2>&5
22672 ac_status=$?
22673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22674 (exit $ac_status); }; then :
22675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22676 $as_echo "yes" >&6; }
22677 else
22678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22679 $as_echo "no" >&6; }
22680 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
22681 fi
22682 am_display_PYTHON=$PYTHON
22683 else
22684 # Otherwise, try each interpreter until we find one that satisfies
22685 # VERSION.
22686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3.8" >&5
22687 $as_echo_n "checking for a Python interpreter with version >= 3.8... " >&6; }
22688 if ${am_cv_pathless_PYTHON+:} false; then :
22689 $as_echo_n "(cached) " >&6
22690 else
22691
22692 for am_cv_pathless_PYTHON in python3.8 none; do
22693 test "$am_cv_pathless_PYTHON" = none && break
22694 prog="import sys
22695 # split strings by '.' and convert to numeric. Append some zeros
22696 # because we need at least 4 digits for the hex conversion.
22697 # map returns an iterator in Python 3.0 and a list in 2.x
22698 minver = list(map(int, '3.8'.split('.'))) + [0, 0, 0]
22699 minverhex = 0
22700 # xrange is not present in Python 3.0 and range returns an iterator
22701 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
22702 sys.exit(sys.hexversion < minverhex)"
22703 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
22704 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
22705 ac_status=$?
22706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22707 (exit $ac_status); }; then :
22708 break
22709 fi
22710 done
22711 fi
22712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
22713 $as_echo "$am_cv_pathless_PYTHON" >&6; }
22714 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
22715 if test "$am_cv_pathless_PYTHON" = none; then
22716 PYTHON=:
22717 else
22718 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
22719 set dummy $am_cv_pathless_PYTHON; ac_word=$2
22720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22721 $as_echo_n "checking for $ac_word... " >&6; }
22722 if ${ac_cv_path_PYTHON+:} false; then :
22723 $as_echo_n "(cached) " >&6
22724 else
22725 case $PYTHON in
22726 [\\/]* | ?:[\\/]*)
22727 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
22728 ;;
22729 *)
22730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22731 for as_dir in $PATH
22732 do
22733 IFS=$as_save_IFS
22734 test -z "$as_dir" && as_dir=.
22735 for ac_exec_ext in '' $ac_executable_extensions; do
22736 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22737 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
22738 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22739 break 2
22740 fi
22741 done
22742 done
22743 IFS=$as_save_IFS
22744
22745 ;;
22746 esac
22747 fi
22748 PYTHON=$ac_cv_path_PYTHON
22749 if test -n "$PYTHON"; then
22750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
22751 $as_echo "$PYTHON" >&6; }
22752 else
22753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22754 $as_echo "no" >&6; }
22755 fi
22756
22757
22758 fi
22759 am_display_PYTHON=$am_cv_pathless_PYTHON
22760 fi
22761
22762
22763 if test "$PYTHON" = :; then
22764 :
22765 else
22766
22767
22768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
22769 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
22770 if ${am_cv_python_version+:} false; then :
22771 $as_echo_n "(cached) " >&6
22772 else
22773 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
22774 fi
22775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
22776 $as_echo "$am_cv_python_version" >&6; }
22777 PYTHON_VERSION=$am_cv_python_version
22778
22779
22780
22781 PYTHON_PREFIX='${prefix}'
22782
22783 PYTHON_EXEC_PREFIX='${exec_prefix}'
22784
22785
22786
22787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
22788 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
22789 if ${am_cv_python_platform+:} false; then :
22790 $as_echo_n "(cached) " >&6
22791 else
22792 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
22793 fi
22794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
22795 $as_echo "$am_cv_python_platform" >&6; }
22796 PYTHON_PLATFORM=$am_cv_python_platform
22797
22798
22799 # Just factor out some code duplication.
22800 am_python_setup_sysconfig="\
22801 import sys
22802 # Prefer sysconfig over distutils.sysconfig, for better compatibility
22803 # with python 3.x. See automake bug#10227.
22804 try:
22805 import sysconfig
22806 except ImportError:
22807 can_use_sysconfig = 0
22808 else:
22809 can_use_sysconfig = 1
22810 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
22811 # <https://github.com/pypa/virtualenv/issues/118>
22812 try:
22813 from platform import python_implementation
22814 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
22815 can_use_sysconfig = 0
22816 except ImportError:
22817 pass"
22818
22819
22820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
22821 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
22822 if ${am_cv_python_pythondir+:} false; then :
22823 $as_echo_n "(cached) " >&6
22824 else
22825 if test "x$prefix" = xNONE
22826 then
22827 am_py_prefix=$ac_default_prefix
22828 else
22829 am_py_prefix=$prefix
22830 fi
22831 am_cv_python_pythondir=`$PYTHON -c "
22832 $am_python_setup_sysconfig
22833 if can_use_sysconfig:
22834 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
22835 else:
22836 from distutils import sysconfig
22837 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
22838 sys.stdout.write(sitedir)"`
22839 case $am_cv_python_pythondir in
22840 $am_py_prefix*)
22841 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
22842 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
22843 ;;
22844 *)
22845 case $am_py_prefix in
22846 /usr|/System*) ;;
22847 *)
22848 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
22849 ;;
22850 esac
22851 ;;
22852 esac
22853
22854 fi
22855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
22856 $as_echo "$am_cv_python_pythondir" >&6; }
22857 pythondir=$am_cv_python_pythondir
22858
22859
22860
22861 pkgpythondir=\${pythondir}/$PACKAGE
22862
22863
22864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
22865 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
22866 if ${am_cv_python_pyexecdir+:} false; then :
22867 $as_echo_n "(cached) " >&6
22868 else
22869 if test "x$exec_prefix" = xNONE
22870 then
22871 am_py_exec_prefix=$am_py_prefix
22872 else
22873 am_py_exec_prefix=$exec_prefix
22874 fi
22875 am_cv_python_pyexecdir=`$PYTHON -c "
22876 $am_python_setup_sysconfig
22877 if can_use_sysconfig:
22878 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
22879 else:
22880 from distutils import sysconfig
22881 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
22882 sys.stdout.write(sitedir)"`
22883 case $am_cv_python_pyexecdir in
22884 $am_py_exec_prefix*)
22885 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
22886 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
22887 ;;
22888 *)
22889 case $am_py_exec_prefix in
22890 /usr|/System*) ;;
22891 *)
22892 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
22893 ;;
22894 esac
22895 ;;
22896 esac
22897
22898 fi
22899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
22900 $as_echo "$am_cv_python_pyexecdir" >&6; }
22901 pyexecdir=$am_cv_python_pyexecdir
22902
22903
22904
22905 pkgpyexecdir=\${pyexecdir}/$PACKAGE
22906
22907
22908
22909
22910 #
22911 # Allow the use of a (user set) custom python version
22912 #
22913
22914
22915 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
22916 set dummy python$PYTHON_VERSION; ac_word=$2
22917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22918 $as_echo_n "checking for $ac_word... " >&6; }
22919 if ${ac_cv_path_PYTHON+:} false; then :
22920 $as_echo_n "(cached) " >&6
22921 else
22922 case $PYTHON in
22923 [\\/]* | ?:[\\/]*)
22924 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
22925 ;;
22926 *)
22927 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22928 for as_dir in $PATH
22929 do
22930 IFS=$as_save_IFS
22931 test -z "$as_dir" && as_dir=.
22932 for ac_exec_ext in '' $ac_executable_extensions; do
22933 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22934 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
22935 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22936 break 2
22937 fi
22938 done
22939 done
22940 IFS=$as_save_IFS
22941
22942 ;;
22943 esac
22944 fi
22945 PYTHON=$ac_cv_path_PYTHON
22946 if test -n "$PYTHON"; then
22947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
22948 $as_echo "$PYTHON" >&6; }
22949 else
22950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22951 $as_echo "no" >&6; }
22952 fi
22953
22954
22955 if test -z "$PYTHON"; then
22956 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
22957 PYTHON_VERSION=""
22958 fi
22959
22960 #
22961 # Check for a version of Python >= 2.1.0
22962 #
22963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
22964 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
22965 ac_supports_python_ver=`$PYTHON -c "import sys; \
22966 ver = sys.version.split ()[0]; \
22967 print (ver >= '2.1.0')"`
22968 if test "$ac_supports_python_ver" != "True"; then
22969 if test -z "$PYTHON_NOVERSIONCHECK"; then
22970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22971 $as_echo "no" >&6; }
22972 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22973 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22974 as_fn_error $? "
22975 This version of the AC_PYTHON_DEVEL macro
22976 doesn't work properly with versions of Python before
22977 2.1.0. You may need to re-run configure, setting the
22978 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
22979 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
22980 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
22981 to something else than an empty string.
22982
22983 See \`config.log' for more details" "$LINENO" 5; }
22984 else
22985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
22986 $as_echo "skip at user request" >&6; }
22987 fi
22988 else
22989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22990 $as_echo "yes" >&6; }
22991 fi
22992
22993 #
22994 # if the macro parameter ``version'' is set, honour it
22995 #
22996 if test -n ""; then
22997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
22998 $as_echo_n "checking for a version of Python ... " >&6; }
22999 ac_supports_python_ver=`$PYTHON -c "import sys; \
23000 ver = sys.version.split ()[0]; \
23001 print (ver )"`
23002 if test "$ac_supports_python_ver" = "True"; then
23003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23004 $as_echo "yes" >&6; }
23005 else
23006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23007 $as_echo "no" >&6; }
23008 as_fn_error $? "this package requires Python .
23009 If you have it installed, but it isn't the default Python
23010 interpreter in your system path, please pass the PYTHON_VERSION
23011 variable to configure. See \`\`configure --help'' for reference.
23012 " "$LINENO" 5
23013 PYTHON_VERSION=""
23014 fi
23015 fi
23016
23017 #
23018 # Check if you have distutils, else fail
23019 #
23020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
23021 $as_echo_n "checking for the distutils Python package... " >&6; }
23022 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
23023 if test -z "$ac_distutils_result"; then
23024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23025 $as_echo "yes" >&6; }
23026 else
23027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23028 $as_echo "no" >&6; }
23029 as_fn_error $? "cannot import Python module \"distutils\".
23030 Please check your Python installation. The error was:
23031 $ac_distutils_result" "$LINENO" 5
23032 PYTHON_VERSION=""
23033 fi
23034
23035 #
23036 # Check for Python include path
23037 #
23038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
23039 $as_echo_n "checking for Python include path... " >&6; }
23040 if test -z "$PYTHON_CPPFLAGS"; then
23041 python_path=`$PYTHON -c "import distutils.sysconfig; \
23042 print (distutils.sysconfig.get_python_inc ());"`
23043 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
23044 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
23045 if test -n "${python_path}"; then
23046 if test "${plat_python_path}" != "${python_path}"; then
23047 python_path="-I$python_path -I$plat_python_path"
23048 else
23049 python_path="-I$python_path"
23050 fi
23051 fi
23052 PYTHON_CPPFLAGS=$python_path
23053 fi
23054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
23055 $as_echo "$PYTHON_CPPFLAGS" >&6; }
23056
23057
23058 #
23059 # Check for Python library path
23060 #
23061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
23062 $as_echo_n "checking for Python library path... " >&6; }
23063 if test -z "$PYTHON_LDFLAGS"; then
23064 # (makes two attempts to ensure we've got a version number
23065 # from the interpreter)
23066 ac_python_version=`cat<<EOD | $PYTHON -
23067
23068 # join all versioning strings, on some systems
23069 # major/minor numbers could be in different list elements
23070 from distutils.sysconfig import *
23071 e = get_config_var('VERSION')
23072 if e is not None:
23073 print(e)
23074 EOD`
23075
23076 if test -z "$ac_python_version"; then
23077 if test -n "$PYTHON_VERSION"; then
23078 ac_python_version=$PYTHON_VERSION
23079 else
23080 ac_python_version=`$PYTHON -c "import sys; \
23081 print (sys.version[:3])"`
23082 fi
23083 fi
23084
23085 # Make the versioning information available to the compiler
23086
23087 # JW: We don't need it and it interferes with the hack
23088 # to detect multiple Pyhton versions
23089 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
23090 # [If available, contains the Python version number currently in use.])
23091
23092 # First, the library directory:
23093 ac_python_libdir=`cat<<EOD | $PYTHON -
23094
23095 # There should be only one
23096 import distutils.sysconfig
23097 e = distutils.sysconfig.get_config_var('LIBDIR')
23098 if e is not None:
23099 print (e)
23100 EOD`
23101
23102 # Now, for the library:
23103 ac_python_library=`cat<<EOD | $PYTHON -
23104
23105 import distutils.sysconfig
23106 c = distutils.sysconfig.get_config_vars()
23107 if 'LDVERSION' in c:
23108 print ('python'+c['LDVERSION'])
23109 else:
23110 print ('python'+c['VERSION'])
23111 EOD`
23112
23113 # This small piece shamelessly adapted from PostgreSQL python macro;
23114 # credits goes to momjian, I think. I'd like to put the right name
23115 # in the credits, if someone can point me in the right direction... ?
23116 #
23117 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
23118 then
23119 # use the official shared library
23120 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
23121 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
23122 else
23123 # old way: use libpython from python_configdir
23124 ac_python_libdir=`$PYTHON -c \
23125 "from distutils.sysconfig import get_python_lib as f; \
23126 import os; \
23127 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
23128 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
23129 fi
23130
23131 if test -z "PYTHON_LDFLAGS"; then
23132 as_fn_error $? "
23133 Cannot determine location of your Python DSO. Please check it was installed with
23134 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
23135 " "$LINENO" 5
23136 fi
23137 fi
23138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
23139 $as_echo "$PYTHON_LDFLAGS" >&6; }
23140
23141
23142 #
23143 # Check for site packages
23144 #
23145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
23146 $as_echo_n "checking for Python site-packages path... " >&6; }
23147 if test -z "$PYTHON_SITE_PKG"; then
23148 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
23149 print (distutils.sysconfig.get_python_lib(0,0));"`
23150 fi
23151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
23152 $as_echo "$PYTHON_SITE_PKG" >&6; }
23153
23154
23155 #
23156 # libraries which must be linked in when embedding
23157 #
23158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
23159 $as_echo_n "checking python extra libraries... " >&6; }
23160 if test -z "$PYTHON_EXTRA_LIBS"; then
23161 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
23162 conf = distutils.sysconfig.get_config_var; \
23163 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
23164 fi
23165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
23166 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
23167
23168
23169 #
23170 # linking flags needed when embedding
23171 #
23172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
23173 $as_echo_n "checking python extra linking flags... " >&6; }
23174 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
23175 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
23176 conf = distutils.sysconfig.get_config_var; \
23177 print (conf('LINKFORSHARED'))"`
23178 fi
23179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
23180 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
23181
23182
23183 #
23184 # final check to see if everything compiles alright
23185 #
23186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
23187 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
23188 # save current global flags
23189 ac_save_LIBS="$LIBS"
23190 ac_save_CPPFLAGS="$CPPFLAGS"
23191 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
23192 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
23193 ac_ext=c
23194 ac_cpp='$CPP $CPPFLAGS'
23195 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23196 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23197 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23198
23199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23200 /* end confdefs.h. */
23201
23202 #include <Python.h>
23203 int
23204 main ()
23205 {
23206 Py_Initialize();
23207 ;
23208 return 0;
23209 }
23210
23211 _ACEOF
23212 if ac_fn_c_try_link "$LINENO"; then :
23213 pythonexists=yes
23214 else
23215 pythonexists=no
23216 fi
23217 rm -f core conftest.err conftest.$ac_objext \
23218 conftest$ac_exeext conftest.$ac_ext
23219 ac_ext=c
23220 ac_cpp='$CPP $CPPFLAGS'
23221 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23222 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23223 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23224
23225 # turn back to default flags
23226 CPPFLAGS="$ac_save_CPPFLAGS"
23227 LIBS="$ac_save_LIBS"
23228
23229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
23230 $as_echo "$pythonexists" >&6; }
23231
23232 if test ! "x$pythonexists" = "xyes"; then
23233 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
23234 Could not link test program to Python. Maybe the main Python library has been
23235 installed in some non-standard library path. If so, pass it to configure,
23236 via the LDFLAGS environment variable.
23237 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
23238 ============================================================================
23239 You probably have to install the development version of the Python package
23240 for your distribution. The exact name of this package varies among them.
23241 ============================================================================
23242 " >&5
23243 $as_echo "$as_me: WARNING:
23244 Could not link test program to Python. Maybe the main Python library has been
23245 installed in some non-standard library path. If so, pass it to configure,
23246 via the LDFLAGS environment variable.
23247 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
23248 ============================================================================
23249 You probably have to install the development version of the Python package
23250 for your distribution. The exact name of this package varies among them.
23251 ============================================================================
23252 " >&2;}
23253 PYTHON_VERSION=""
23254 fi
23255
23256 #
23257 # all done!
23258 #
23259
23260 if test "$PYTHON_VERSION"; then
23261 PYTHONS="$(echo $PYTHONS $PYTHON)"
23262 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
23263 fi
23264
23265 fi
23266
23267
23268 unset PYTHON
23269 unset PYTHON_VERSION
23270 unset PYTHON_CPPFLAGS
23271 unset PYTHON_LDFLAGS
23272 unset PYTHON_SITE_PKG
23273 unset PYTHON_EXTRA_LIBS
23274 unset PYTHON_EXTRA_LDFLAGS
23275 unset ac_cv_path_PYTHON
23276 unset am_cv_pathless_PYTHON
23277 unset am_cv_python_version
23278 unset am_cv_python_platform
23279 unset am_cv_python_pythondir
23280 unset am_cv_python_pyexecdir
23281
23282
23283
23284
23285
23286
23287 if test -n "$PYTHON"; then
23288 # If the user set $PYTHON, use it and don't search something else.
23289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3.9" >&5
23290 $as_echo_n "checking whether $PYTHON version is >= 3.9... " >&6; }
23291 prog="import sys
23292 # split strings by '.' and convert to numeric. Append some zeros
23293 # because we need at least 4 digits for the hex conversion.
23294 # map returns an iterator in Python 3.0 and a list in 2.x
23295 minver = list(map(int, '3.9'.split('.'))) + [0, 0, 0]
23296 minverhex = 0
23297 # xrange is not present in Python 3.0 and range returns an iterator
23298 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
23299 sys.exit(sys.hexversion < minverhex)"
23300 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
23301 ($PYTHON -c "$prog") >&5 2>&5
23302 ac_status=$?
23303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23304 (exit $ac_status); }; then :
23305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23306 $as_echo "yes" >&6; }
23307 else
23308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23309 $as_echo "no" >&6; }
23310 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
23311 fi
23312 am_display_PYTHON=$PYTHON
23313 else
23314 # Otherwise, try each interpreter until we find one that satisfies
23315 # VERSION.
23316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3.9" >&5
23317 $as_echo_n "checking for a Python interpreter with version >= 3.9... " >&6; }
23318 if ${am_cv_pathless_PYTHON+:} false; then :
23319 $as_echo_n "(cached) " >&6
23320 else
23321
23322 for am_cv_pathless_PYTHON in python3.9 none; do
23323 test "$am_cv_pathless_PYTHON" = none && break
23324 prog="import sys
23325 # split strings by '.' and convert to numeric. Append some zeros
23326 # because we need at least 4 digits for the hex conversion.
23327 # map returns an iterator in Python 3.0 and a list in 2.x
23328 minver = list(map(int, '3.9'.split('.'))) + [0, 0, 0]
23329 minverhex = 0
23330 # xrange is not present in Python 3.0 and range returns an iterator
23331 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
23332 sys.exit(sys.hexversion < minverhex)"
23333 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
23334 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
23335 ac_status=$?
23336 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23337 (exit $ac_status); }; then :
23338 break
23339 fi
23340 done
23341 fi
23342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
23343 $as_echo "$am_cv_pathless_PYTHON" >&6; }
23344 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
23345 if test "$am_cv_pathless_PYTHON" = none; then
23346 PYTHON=:
23347 else
23348 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
23349 set dummy $am_cv_pathless_PYTHON; ac_word=$2
23350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23351 $as_echo_n "checking for $ac_word... " >&6; }
23352 if ${ac_cv_path_PYTHON+:} false; then :
23353 $as_echo_n "(cached) " >&6
23354 else
23355 case $PYTHON in
23356 [\\/]* | ?:[\\/]*)
23357 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
23358 ;;
23359 *)
23360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23361 for as_dir in $PATH
23362 do
23363 IFS=$as_save_IFS
23364 test -z "$as_dir" && as_dir=.
23365 for ac_exec_ext in '' $ac_executable_extensions; do
23366 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23367 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
23368 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23369 break 2
23370 fi
23371 done
23372 done
23373 IFS=$as_save_IFS
23374
23375 ;;
23376 esac
23377 fi
23378 PYTHON=$ac_cv_path_PYTHON
23379 if test -n "$PYTHON"; then
23380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
23381 $as_echo "$PYTHON" >&6; }
23382 else
23383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23384 $as_echo "no" >&6; }
23385 fi
23386
23387
23388 fi
23389 am_display_PYTHON=$am_cv_pathless_PYTHON
23390 fi
23391
23392
23393 if test "$PYTHON" = :; then
23394 :
23395 else
23396
23397
23398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
23399 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
23400 if ${am_cv_python_version+:} false; then :
23401 $as_echo_n "(cached) " >&6
23402 else
23403 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
23404 fi
23405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
23406 $as_echo "$am_cv_python_version" >&6; }
23407 PYTHON_VERSION=$am_cv_python_version
23408
23409
23410
23411 PYTHON_PREFIX='${prefix}'
23412
23413 PYTHON_EXEC_PREFIX='${exec_prefix}'
23414
23415
23416
23417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
23418 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
23419 if ${am_cv_python_platform+:} false; then :
23420 $as_echo_n "(cached) " >&6
23421 else
23422 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
23423 fi
23424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
23425 $as_echo "$am_cv_python_platform" >&6; }
23426 PYTHON_PLATFORM=$am_cv_python_platform
23427
23428
23429 # Just factor out some code duplication.
23430 am_python_setup_sysconfig="\
23431 import sys
23432 # Prefer sysconfig over distutils.sysconfig, for better compatibility
23433 # with python 3.x. See automake bug#10227.
23434 try:
23435 import sysconfig
23436 except ImportError:
23437 can_use_sysconfig = 0
23438 else:
23439 can_use_sysconfig = 1
23440 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
23441 # <https://github.com/pypa/virtualenv/issues/118>
23442 try:
23443 from platform import python_implementation
23444 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
23445 can_use_sysconfig = 0
23446 except ImportError:
23447 pass"
23448
23449
23450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
23451 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
23452 if ${am_cv_python_pythondir+:} false; then :
23453 $as_echo_n "(cached) " >&6
23454 else
23455 if test "x$prefix" = xNONE
23456 then
23457 am_py_prefix=$ac_default_prefix
23458 else
23459 am_py_prefix=$prefix
23460 fi
23461 am_cv_python_pythondir=`$PYTHON -c "
23462 $am_python_setup_sysconfig
23463 if can_use_sysconfig:
23464 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
23465 else:
23466 from distutils import sysconfig
23467 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
23468 sys.stdout.write(sitedir)"`
23469 case $am_cv_python_pythondir in
23470 $am_py_prefix*)
23471 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
23472 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
23473 ;;
23474 *)
23475 case $am_py_prefix in
23476 /usr|/System*) ;;
23477 *)
23478 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
23479 ;;
23480 esac
23481 ;;
23482 esac
23483
23484 fi
23485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
23486 $as_echo "$am_cv_python_pythondir" >&6; }
23487 pythondir=$am_cv_python_pythondir
23488
23489
23490
23491 pkgpythondir=\${pythondir}/$PACKAGE
23492
23493
23494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
23495 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
23496 if ${am_cv_python_pyexecdir+:} false; then :
23497 $as_echo_n "(cached) " >&6
23498 else
23499 if test "x$exec_prefix" = xNONE
23500 then
23501 am_py_exec_prefix=$am_py_prefix
23502 else
23503 am_py_exec_prefix=$exec_prefix
23504 fi
23505 am_cv_python_pyexecdir=`$PYTHON -c "
23506 $am_python_setup_sysconfig
23507 if can_use_sysconfig:
23508 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
23509 else:
23510 from distutils import sysconfig
23511 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
23512 sys.stdout.write(sitedir)"`
23513 case $am_cv_python_pyexecdir in
23514 $am_py_exec_prefix*)
23515 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
23516 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
23517 ;;
23518 *)
23519 case $am_py_exec_prefix in
23520 /usr|/System*) ;;
23521 *)
23522 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
23523 ;;
23524 esac
23525 ;;
23526 esac
23527
23528 fi
23529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
23530 $as_echo "$am_cv_python_pyexecdir" >&6; }
23531 pyexecdir=$am_cv_python_pyexecdir
23532
23533
23534
23535 pkgpyexecdir=\${pyexecdir}/$PACKAGE
23536
23537
23538
23539
23540 #
23541 # Allow the use of a (user set) custom python version
23542 #
23543
23544
23545 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
23546 set dummy python$PYTHON_VERSION; ac_word=$2
23547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23548 $as_echo_n "checking for $ac_word... " >&6; }
23549 if ${ac_cv_path_PYTHON+:} false; then :
23550 $as_echo_n "(cached) " >&6
23551 else
23552 case $PYTHON in
23553 [\\/]* | ?:[\\/]*)
23554 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
23555 ;;
23556 *)
23557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23558 for as_dir in $PATH
23559 do
23560 IFS=$as_save_IFS
23561 test -z "$as_dir" && as_dir=.
23562 for ac_exec_ext in '' $ac_executable_extensions; do
23563 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23564 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
23565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23566 break 2
23567 fi
23568 done
23569 done
23570 IFS=$as_save_IFS
23571
23572 ;;
23573 esac
23574 fi
23575 PYTHON=$ac_cv_path_PYTHON
23576 if test -n "$PYTHON"; then
23577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
23578 $as_echo "$PYTHON" >&6; }
23579 else
23580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23581 $as_echo "no" >&6; }
23582 fi
23583
23584
23585 if test -z "$PYTHON"; then
23586 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
23587 PYTHON_VERSION=""
23588 fi
23589
23590 #
23591 # Check for a version of Python >= 2.1.0
23592 #
23593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
23594 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
23595 ac_supports_python_ver=`$PYTHON -c "import sys; \
23596 ver = sys.version.split ()[0]; \
23597 print (ver >= '2.1.0')"`
23598 if test "$ac_supports_python_ver" != "True"; then
23599 if test -z "$PYTHON_NOVERSIONCHECK"; then
23600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23601 $as_echo "no" >&6; }
23602 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23603 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23604 as_fn_error $? "
23605 This version of the AC_PYTHON_DEVEL macro
23606 doesn't work properly with versions of Python before
23607 2.1.0. You may need to re-run configure, setting the
23608 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
23609 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
23610 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
23611 to something else than an empty string.
23612
23613 See \`config.log' for more details" "$LINENO" 5; }
23614 else
23615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
23616 $as_echo "skip at user request" >&6; }
23617 fi
23618 else
23619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23620 $as_echo "yes" >&6; }
23621 fi
23622
23623 #
23624 # if the macro parameter ``version'' is set, honour it
23625 #
23626 if test -n ""; then
23627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
23628 $as_echo_n "checking for a version of Python ... " >&6; }
23629 ac_supports_python_ver=`$PYTHON -c "import sys; \
23630 ver = sys.version.split ()[0]; \
23631 print (ver )"`
23632 if test "$ac_supports_python_ver" = "True"; then
23633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23634 $as_echo "yes" >&6; }
23635 else
23636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23637 $as_echo "no" >&6; }
23638 as_fn_error $? "this package requires Python .
23639 If you have it installed, but it isn't the default Python
23640 interpreter in your system path, please pass the PYTHON_VERSION
23641 variable to configure. See \`\`configure --help'' for reference.
23642 " "$LINENO" 5
23643 PYTHON_VERSION=""
23644 fi
23645 fi
23646
23647 #
23648 # Check if you have distutils, else fail
23649 #
23650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
23651 $as_echo_n "checking for the distutils Python package... " >&6; }
23652 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
23653 if test -z "$ac_distutils_result"; then
23654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23655 $as_echo "yes" >&6; }
23656 else
23657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23658 $as_echo "no" >&6; }
23659 as_fn_error $? "cannot import Python module \"distutils\".
23660 Please check your Python installation. The error was:
23661 $ac_distutils_result" "$LINENO" 5
23662 PYTHON_VERSION=""
23663 fi
23664
23665 #
23666 # Check for Python include path
23667 #
23668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
23669 $as_echo_n "checking for Python include path... " >&6; }
23670 if test -z "$PYTHON_CPPFLAGS"; then
23671 python_path=`$PYTHON -c "import distutils.sysconfig; \
23672 print (distutils.sysconfig.get_python_inc ());"`
23673 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
23674 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
23675 if test -n "${python_path}"; then
23676 if test "${plat_python_path}" != "${python_path}"; then
23677 python_path="-I$python_path -I$plat_python_path"
23678 else
23679 python_path="-I$python_path"
23680 fi
23681 fi
23682 PYTHON_CPPFLAGS=$python_path
23683 fi
23684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
23685 $as_echo "$PYTHON_CPPFLAGS" >&6; }
23686
23687
23688 #
23689 # Check for Python library path
23690 #
23691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
23692 $as_echo_n "checking for Python library path... " >&6; }
23693 if test -z "$PYTHON_LDFLAGS"; then
23694 # (makes two attempts to ensure we've got a version number
23695 # from the interpreter)
23696 ac_python_version=`cat<<EOD | $PYTHON -
23697
23698 # join all versioning strings, on some systems
23699 # major/minor numbers could be in different list elements
23700 from distutils.sysconfig import *
23701 e = get_config_var('VERSION')
23702 if e is not None:
23703 print(e)
23704 EOD`
23705
23706 if test -z "$ac_python_version"; then
23707 if test -n "$PYTHON_VERSION"; then
23708 ac_python_version=$PYTHON_VERSION
23709 else
23710 ac_python_version=`$PYTHON -c "import sys; \
23711 print (sys.version[:3])"`
23712 fi
23713 fi
23714
23715 # Make the versioning information available to the compiler
23716
23717 # JW: We don't need it and it interferes with the hack
23718 # to detect multiple Pyhton versions
23719 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
23720 # [If available, contains the Python version number currently in use.])
23721
23722 # First, the library directory:
23723 ac_python_libdir=`cat<<EOD | $PYTHON -
23724
23725 # There should be only one
23726 import distutils.sysconfig
23727 e = distutils.sysconfig.get_config_var('LIBDIR')
23728 if e is not None:
23729 print (e)
23730 EOD`
23731
23732 # Now, for the library:
23733 ac_python_library=`cat<<EOD | $PYTHON -
23734
23735 import distutils.sysconfig
23736 c = distutils.sysconfig.get_config_vars()
23737 if 'LDVERSION' in c:
23738 print ('python'+c['LDVERSION'])
23739 else:
23740 print ('python'+c['VERSION'])
23741 EOD`
23742
23743 # This small piece shamelessly adapted from PostgreSQL python macro;
23744 # credits goes to momjian, I think. I'd like to put the right name
23745 # in the credits, if someone can point me in the right direction... ?
23746 #
23747 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
23748 then
23749 # use the official shared library
23750 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
23751 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
23752 else
23753 # old way: use libpython from python_configdir
23754 ac_python_libdir=`$PYTHON -c \
23755 "from distutils.sysconfig import get_python_lib as f; \
23756 import os; \
23757 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
23758 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
23759 fi
23760
23761 if test -z "PYTHON_LDFLAGS"; then
23762 as_fn_error $? "
23763 Cannot determine location of your Python DSO. Please check it was installed with
23764 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
23765 " "$LINENO" 5
23766 fi
23767 fi
23768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
23769 $as_echo "$PYTHON_LDFLAGS" >&6; }
23770
23771
23772 #
23773 # Check for site packages
23774 #
23775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
23776 $as_echo_n "checking for Python site-packages path... " >&6; }
23777 if test -z "$PYTHON_SITE_PKG"; then
23778 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
23779 print (distutils.sysconfig.get_python_lib(0,0));"`
23780 fi
23781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
23782 $as_echo "$PYTHON_SITE_PKG" >&6; }
23783
23784
23785 #
23786 # libraries which must be linked in when embedding
23787 #
23788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
23789 $as_echo_n "checking python extra libraries... " >&6; }
23790 if test -z "$PYTHON_EXTRA_LIBS"; then
23791 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
23792 conf = distutils.sysconfig.get_config_var; \
23793 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
23794 fi
23795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
23796 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
23797
23798
23799 #
23800 # linking flags needed when embedding
23801 #
23802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
23803 $as_echo_n "checking python extra linking flags... " >&6; }
23804 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
23805 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
23806 conf = distutils.sysconfig.get_config_var; \
23807 print (conf('LINKFORSHARED'))"`
23808 fi
23809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
23810 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
23811
23812
23813 #
23814 # final check to see if everything compiles alright
23815 #
23816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
23817 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
23818 # save current global flags
23819 ac_save_LIBS="$LIBS"
23820 ac_save_CPPFLAGS="$CPPFLAGS"
23821 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
23822 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
23823 ac_ext=c
23824 ac_cpp='$CPP $CPPFLAGS'
23825 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23826 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23827 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23828
23829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23830 /* end confdefs.h. */
23831
23832 #include <Python.h>
23833 int
23834 main ()
23835 {
23836 Py_Initialize();
23837 ;
23838 return 0;
23839 }
23840
23841 _ACEOF
23842 if ac_fn_c_try_link "$LINENO"; then :
23843 pythonexists=yes
23844 else
23845 pythonexists=no
23846 fi
23847 rm -f core conftest.err conftest.$ac_objext \
23848 conftest$ac_exeext conftest.$ac_ext
23849 ac_ext=c
23850 ac_cpp='$CPP $CPPFLAGS'
23851 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23852 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23853 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23854
23855 # turn back to default flags
23856 CPPFLAGS="$ac_save_CPPFLAGS"
23857 LIBS="$ac_save_LIBS"
23858
23859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
23860 $as_echo "$pythonexists" >&6; }
23861
23862 if test ! "x$pythonexists" = "xyes"; then
23863 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
23864 Could not link test program to Python. Maybe the main Python library has been
23865 installed in some non-standard library path. If so, pass it to configure,
23866 via the LDFLAGS environment variable.
23867 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
23868 ============================================================================
23869 You probably have to install the development version of the Python package
23870 for your distribution. The exact name of this package varies among them.
23871 ============================================================================
23872 " >&5
23873 $as_echo "$as_me: WARNING:
23874 Could not link test program to Python. Maybe the main Python library has been
23875 installed in some non-standard library path. If so, pass it to configure,
23876 via the LDFLAGS environment variable.
23877 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
23878 ============================================================================
23879 You probably have to install the development version of the Python package
23880 for your distribution. The exact name of this package varies among them.
23881 ============================================================================
23882 " >&2;}
23883 PYTHON_VERSION=""
23884 fi
23885
23886 #
23887 # all done!
23888 #
23889
23890 if test "$PYTHON_VERSION"; then
23891 PYTHONS="$(echo $PYTHONS $PYTHON)"
23892 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
23893 fi
23894
23895 fi
23896
23897
23898 unset PYTHON
23899 unset PYTHON_VERSION
23900 unset PYTHON_CPPFLAGS
23901 unset PYTHON_LDFLAGS
23902 unset PYTHON_SITE_PKG
23903 unset PYTHON_EXTRA_LIBS
23904 unset PYTHON_EXTRA_LDFLAGS
23905 unset ac_cv_path_PYTHON
23906 unset am_cv_pathless_PYTHON
23907 unset am_cv_python_version
23908 unset am_cv_python_platform
23909 unset am_cv_python_pythondir
23910 unset am_cv_python_pyexecdir
23911
23912
23913
23914
23915
23916
23917 if test -n "$PYTHON"; then
23918 # If the user set $PYTHON, use it and don't search something else.
23919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= all" >&5
23920 $as_echo_n "checking whether $PYTHON version is >= all... " >&6; }
23921 prog="import sys
23922 # split strings by '.' and convert to numeric. Append some zeros
23923 # because we need at least 4 digits for the hex conversion.
23924 # map returns an iterator in Python 3.0 and a list in 2.x
23925 minver = list(map(int, 'all'.split('.'))) + [0, 0, 0]
23926 minverhex = 0
23927 # xrange is not present in Python 3.0 and range returns an iterator
23928 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
23929 sys.exit(sys.hexversion < minverhex)"
23930 if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5
23931 ($PYTHON -c "$prog") >&5 2>&5
23932 ac_status=$?
23933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23934 (exit $ac_status); }; then :
23935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23936 $as_echo "yes" >&6; }
23937 else
23938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23939 $as_echo "no" >&6; }
23940 as_fn_error $? "Python interpreter is too old" "$LINENO" 5
23941 fi
23942 am_display_PYTHON=$PYTHON
23943 else
23944 # Otherwise, try each interpreter until we find one that satisfies
23945 # VERSION.
23946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= all" >&5
23947 $as_echo_n "checking for a Python interpreter with version >= all... " >&6; }
23948 if ${am_cv_pathless_PYTHON+:} false; then :
23949 $as_echo_n "(cached) " >&6
23950 else
23951
23952 for am_cv_pathless_PYTHON in pythonall none; do
23953 test "$am_cv_pathless_PYTHON" = none && break
23954 prog="import sys
23955 # split strings by '.' and convert to numeric. Append some zeros
23956 # because we need at least 4 digits for the hex conversion.
23957 # map returns an iterator in Python 3.0 and a list in 2.x
23958 minver = list(map(int, 'all'.split('.'))) + [0, 0, 0]
23959 minverhex = 0
23960 # xrange is not present in Python 3.0 and range returns an iterator
23961 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
23962 sys.exit(sys.hexversion < minverhex)"
23963 if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5
23964 ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5
23965 ac_status=$?
23966 echo "$as_me:$LINENO: \$? = $ac_status" >&5
23967 (exit $ac_status); }; then :
23968 break
23969 fi
23970 done
23971 fi
23972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5
23973 $as_echo "$am_cv_pathless_PYTHON" >&6; }
23974 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
23975 if test "$am_cv_pathless_PYTHON" = none; then
23976 PYTHON=:
23977 else
23978 # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args.
23979 set dummy $am_cv_pathless_PYTHON; ac_word=$2
23980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23981 $as_echo_n "checking for $ac_word... " >&6; }
23982 if ${ac_cv_path_PYTHON+:} false; then :
23983 $as_echo_n "(cached) " >&6
23984 else
23985 case $PYTHON in
23986 [\\/]* | ?:[\\/]*)
23987 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
23988 ;;
23989 *)
23990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23991 for as_dir in $PATH
23992 do
23993 IFS=$as_save_IFS
23994 test -z "$as_dir" && as_dir=.
23995 for ac_exec_ext in '' $ac_executable_extensions; do
23996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23997 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
23998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23999 break 2
24000 fi
24001 done
24002 done
24003 IFS=$as_save_IFS
24004
24005 ;;
24006 esac
24007 fi
24008 PYTHON=$ac_cv_path_PYTHON
24009 if test -n "$PYTHON"; then
24010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
24011 $as_echo "$PYTHON" >&6; }
24012 else
24013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24014 $as_echo "no" >&6; }
24015 fi
24016
24017
24018 fi
24019 am_display_PYTHON=$am_cv_pathless_PYTHON
24020 fi
24021
24022
24023 if test "$PYTHON" = :; then
24024 :
24025 else
24026
24027
24028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
24029 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
24030 if ${am_cv_python_version+:} false; then :
24031 $as_echo_n "(cached) " >&6
24032 else
24033 am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
24034 fi
24035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5
24036 $as_echo "$am_cv_python_version" >&6; }
24037 PYTHON_VERSION=$am_cv_python_version
24038
24039
24040
24041 PYTHON_PREFIX='${prefix}'
24042
24043 PYTHON_EXEC_PREFIX='${exec_prefix}'
24044
24045
24046
24047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
24048 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
24049 if ${am_cv_python_platform+:} false; then :
24050 $as_echo_n "(cached) " >&6
24051 else
24052 am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
24053 fi
24054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5
24055 $as_echo "$am_cv_python_platform" >&6; }
24056 PYTHON_PLATFORM=$am_cv_python_platform
24057
24058
24059 # Just factor out some code duplication.
24060 am_python_setup_sysconfig="\
24061 import sys
24062 # Prefer sysconfig over distutils.sysconfig, for better compatibility
24063 # with python 3.x. See automake bug#10227.
24064 try:
24065 import sysconfig
24066 except ImportError:
24067 can_use_sysconfig = 0
24068 else:
24069 can_use_sysconfig = 1
24070 # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
24071 # <https://github.com/pypa/virtualenv/issues/118>
24072 try:
24073 from platform import python_implementation
24074 if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
24075 can_use_sysconfig = 0
24076 except ImportError:
24077 pass"
24078
24079
24080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
24081 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
24082 if ${am_cv_python_pythondir+:} false; then :
24083 $as_echo_n "(cached) " >&6
24084 else
24085 if test "x$prefix" = xNONE
24086 then
24087 am_py_prefix=$ac_default_prefix
24088 else
24089 am_py_prefix=$prefix
24090 fi
24091 am_cv_python_pythondir=`$PYTHON -c "
24092 $am_python_setup_sysconfig
24093 if can_use_sysconfig:
24094 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
24095 else:
24096 from distutils import sysconfig
24097 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
24098 sys.stdout.write(sitedir)"`
24099 case $am_cv_python_pythondir in
24100 $am_py_prefix*)
24101 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
24102 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
24103 ;;
24104 *)
24105 case $am_py_prefix in
24106 /usr|/System*) ;;
24107 *)
24108 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
24109 ;;
24110 esac
24111 ;;
24112 esac
24113
24114 fi
24115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5
24116 $as_echo "$am_cv_python_pythondir" >&6; }
24117 pythondir=$am_cv_python_pythondir
24118
24119
24120
24121 pkgpythondir=\${pythondir}/$PACKAGE
24122
24123
24124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
24125 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
24126 if ${am_cv_python_pyexecdir+:} false; then :
24127 $as_echo_n "(cached) " >&6
24128 else
24129 if test "x$exec_prefix" = xNONE
24130 then
24131 am_py_exec_prefix=$am_py_prefix
24132 else
24133 am_py_exec_prefix=$exec_prefix
24134 fi
24135 am_cv_python_pyexecdir=`$PYTHON -c "
24136 $am_python_setup_sysconfig
24137 if can_use_sysconfig:
24138 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'})
24139 else:
24140 from distutils import sysconfig
24141 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix')
24142 sys.stdout.write(sitedir)"`
24143 case $am_cv_python_pyexecdir in
24144 $am_py_exec_prefix*)
24145 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
24146 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
24147 ;;
24148 *)
24149 case $am_py_exec_prefix in
24150 /usr|/System*) ;;
24151 *)
24152 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
24153 ;;
24154 esac
24155 ;;
24156 esac
24157
24158 fi
24159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5
24160 $as_echo "$am_cv_python_pyexecdir" >&6; }
24161 pyexecdir=$am_cv_python_pyexecdir
24162
24163
24164
24165 pkgpyexecdir=\${pyexecdir}/$PACKAGE
24166
24167
24168
24169
24170 #
24171 # Allow the use of a (user set) custom python version
24172 #
24173
24174
24175 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
24176 set dummy python$PYTHON_VERSION; ac_word=$2
24177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24178 $as_echo_n "checking for $ac_word... " >&6; }
24179 if ${ac_cv_path_PYTHON+:} false; then :
24180 $as_echo_n "(cached) " >&6
24181 else
24182 case $PYTHON in
24183 [\\/]* | ?:[\\/]*)
24184 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
24185 ;;
24186 *)
24187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24188 for as_dir in $PATH
24189 do
24190 IFS=$as_save_IFS
24191 test -z "$as_dir" && as_dir=.
24192 for ac_exec_ext in '' $ac_executable_extensions; do
24193 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24194 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
24195 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24196 break 2
24197 fi
24198 done
24199 done
24200 IFS=$as_save_IFS
24201
24202 ;;
24203 esac
24204 fi
24205 PYTHON=$ac_cv_path_PYTHON
24206 if test -n "$PYTHON"; then
24207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
24208 $as_echo "$PYTHON" >&6; }
24209 else
24210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24211 $as_echo "no" >&6; }
24212 fi
24213
24214
24215 if test -z "$PYTHON"; then
24216 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
24217 PYTHON_VERSION=""
24218 fi
24219
24220 #
24221 # Check for a version of Python >= 2.1.0
24222 #
24223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python >= '2.1.0'" >&5
24224 $as_echo_n "checking for a version of Python >= '2.1.0'... " >&6; }
24225 ac_supports_python_ver=`$PYTHON -c "import sys; \
24226 ver = sys.version.split ()[0]; \
24227 print (ver >= '2.1.0')"`
24228 if test "$ac_supports_python_ver" != "True"; then
24229 if test -z "$PYTHON_NOVERSIONCHECK"; then
24230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24231 $as_echo "no" >&6; }
24232 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
24233 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24234 as_fn_error $? "
24235 This version of the AC_PYTHON_DEVEL macro
24236 doesn't work properly with versions of Python before
24237 2.1.0. You may need to re-run configure, setting the
24238 variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
24239 PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
24240 Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
24241 to something else than an empty string.
24242
24243 See \`config.log' for more details" "$LINENO" 5; }
24244 else
24245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: skip at user request" >&5
24246 $as_echo "skip at user request" >&6; }
24247 fi
24248 else
24249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24250 $as_echo "yes" >&6; }
24251 fi
24252
24253 #
24254 # if the macro parameter ``version'' is set, honour it
24255 #
24256 if test -n ""; then
24257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of Python " >&5
24258 $as_echo_n "checking for a version of Python ... " >&6; }
24259 ac_supports_python_ver=`$PYTHON -c "import sys; \
24260 ver = sys.version.split ()[0]; \
24261 print (ver )"`
24262 if test "$ac_supports_python_ver" = "True"; then
24263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24264 $as_echo "yes" >&6; }
24265 else
24266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24267 $as_echo "no" >&6; }
24268 as_fn_error $? "this package requires Python .
24269 If you have it installed, but it isn't the default Python
24270 interpreter in your system path, please pass the PYTHON_VERSION
24271 variable to configure. See \`\`configure --help'' for reference.
24272 " "$LINENO" 5
24273 PYTHON_VERSION=""
24274 fi
24275 fi
24276
24277 #
24278 # Check if you have distutils, else fail
24279 #
24280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
24281 $as_echo_n "checking for the distutils Python package... " >&6; }
24282 ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
24283 if test -z "$ac_distutils_result"; then
24284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24285 $as_echo "yes" >&6; }
24286 else
24287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24288 $as_echo "no" >&6; }
24289 as_fn_error $? "cannot import Python module \"distutils\".
24290 Please check your Python installation. The error was:
24291 $ac_distutils_result" "$LINENO" 5
24292 PYTHON_VERSION=""
24293 fi
24294
24295 #
24296 # Check for Python include path
24297 #
24298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
24299 $as_echo_n "checking for Python include path... " >&6; }
24300 if test -z "$PYTHON_CPPFLAGS"; then
24301 python_path=`$PYTHON -c "import distutils.sysconfig; \
24302 print (distutils.sysconfig.get_python_inc ());"`
24303 plat_python_path=`$PYTHON -c "import distutils.sysconfig; \
24304 print (distutils.sysconfig.get_python_inc (plat_specific=1));"`
24305 if test -n "${python_path}"; then
24306 if test "${plat_python_path}" != "${python_path}"; then
24307 python_path="-I$python_path -I$plat_python_path"
24308 else
24309 python_path="-I$python_path"
24310 fi
24311 fi
24312 PYTHON_CPPFLAGS=$python_path
24313 fi
24314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
24315 $as_echo "$PYTHON_CPPFLAGS" >&6; }
24316
24317
24318 #
24319 # Check for Python library path
24320 #
24321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
24322 $as_echo_n "checking for Python library path... " >&6; }
24323 if test -z "$PYTHON_LDFLAGS"; then
24324 # (makes two attempts to ensure we've got a version number
24325 # from the interpreter)
24326 ac_python_version=`cat<<EOD | $PYTHON -
24327
24328 # join all versioning strings, on some systems
24329 # major/minor numbers could be in different list elements
24330 from distutils.sysconfig import *
24331 e = get_config_var('VERSION')
24332 if e is not None:
24333 print(e)
24334 EOD`
24335
24336 if test -z "$ac_python_version"; then
24337 if test -n "$PYTHON_VERSION"; then
24338 ac_python_version=$PYTHON_VERSION
24339 else
24340 ac_python_version=`$PYTHON -c "import sys; \
24341 print (sys.version[:3])"`
24342 fi
24343 fi
24344
24345 # Make the versioning information available to the compiler
24346
24347 # JW: We don't need it and it interferes with the hack
24348 # to detect multiple Pyhton versions
24349 #AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
24350 # [If available, contains the Python version number currently in use.])
24351
24352 # First, the library directory:
24353 ac_python_libdir=`cat<<EOD | $PYTHON -
24354
24355 # There should be only one
24356 import distutils.sysconfig
24357 e = distutils.sysconfig.get_config_var('LIBDIR')
24358 if e is not None:
24359 print (e)
24360 EOD`
24361
24362 # Now, for the library:
24363 ac_python_library=`cat<<EOD | $PYTHON -
24364
24365 import distutils.sysconfig
24366 c = distutils.sysconfig.get_config_vars()
24367 if 'LDVERSION' in c:
24368 print ('python'+c['LDVERSION'])
24369 else:
24370 print ('python'+c['VERSION'])
24371 EOD`
24372
24373 # This small piece shamelessly adapted from PostgreSQL python macro;
24374 # credits goes to momjian, I think. I'd like to put the right name
24375 # in the credits, if someone can point me in the right direction... ?
24376 #
24377 if test -n "$ac_python_libdir" -a -n "$ac_python_library"
24378 then
24379 # use the official shared library
24380 ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
24381 PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
24382 else
24383 # old way: use libpython from python_configdir
24384 ac_python_libdir=`$PYTHON -c \
24385 "from distutils.sysconfig import get_python_lib as f; \
24386 import os; \
24387 print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
24388 PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
24389 fi
24390
24391 if test -z "PYTHON_LDFLAGS"; then
24392 as_fn_error $? "
24393 Cannot determine location of your Python DSO. Please check it was installed with
24394 dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
24395 " "$LINENO" 5
24396 fi
24397 fi
24398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
24399 $as_echo "$PYTHON_LDFLAGS" >&6; }
24400
24401
24402 #
24403 # Check for site packages
24404 #
24405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
24406 $as_echo_n "checking for Python site-packages path... " >&6; }
24407 if test -z "$PYTHON_SITE_PKG"; then
24408 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
24409 print (distutils.sysconfig.get_python_lib(0,0));"`
24410 fi
24411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
24412 $as_echo "$PYTHON_SITE_PKG" >&6; }
24413
24414
24415 #
24416 # libraries which must be linked in when embedding
24417 #
24418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra libraries" >&5
24419 $as_echo_n "checking python extra libraries... " >&6; }
24420 if test -z "$PYTHON_EXTRA_LIBS"; then
24421 PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
24422 conf = distutils.sysconfig.get_config_var; \
24423 print (conf('LIBS') + ' ' + conf('SYSLIBS'))"`
24424 fi
24425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LIBS" >&5
24426 $as_echo "$PYTHON_EXTRA_LIBS" >&6; }
24427
24428
24429 #
24430 # linking flags needed when embedding
24431 #
24432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking python extra linking flags" >&5
24433 $as_echo_n "checking python extra linking flags... " >&6; }
24434 if test -z "$PYTHON_EXTRA_LDFLAGS"; then
24435 PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
24436 conf = distutils.sysconfig.get_config_var; \
24437 print (conf('LINKFORSHARED'))"`
24438 fi
24439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_EXTRA_LDFLAGS" >&5
24440 $as_echo "$PYTHON_EXTRA_LDFLAGS" >&6; }
24441
24442
24443 #
24444 # final check to see if everything compiles alright
24445 #
24446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
24447 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
24448 # save current global flags
24449 ac_save_LIBS="$LIBS"
24450 ac_save_CPPFLAGS="$CPPFLAGS"
24451 LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
24452 CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
24453 ac_ext=c
24454 ac_cpp='$CPP $CPPFLAGS'
24455 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
24456 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
24457 ac_compiler_gnu=$ac_cv_c_compiler_gnu
24458
24459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24460 /* end confdefs.h. */
24461
24462 #include <Python.h>
24463 int
24464 main ()
24465 {
24466 Py_Initialize();
24467 ;
24468 return 0;
24469 }
24470
24471 _ACEOF
24472 if ac_fn_c_try_link "$LINENO"; then :
24473 pythonexists=yes
24474 else
24475 pythonexists=no
24476 fi
24477 rm -f core conftest.err conftest.$ac_objext \
24478 conftest$ac_exeext conftest.$ac_ext
24479 ac_ext=c
24480 ac_cpp='$CPP $CPPFLAGS'
24481 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
24482 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
24483 ac_compiler_gnu=$ac_cv_c_compiler_gnu
24484
24485 # turn back to default flags
24486 CPPFLAGS="$ac_save_CPPFLAGS"
24487 LIBS="$ac_save_LIBS"
24488
24489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
24490 $as_echo "$pythonexists" >&6; }
24491
24492 if test ! "x$pythonexists" = "xyes"; then
24493 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
24494 Could not link test program to Python. Maybe the main Python library has been
24495 installed in some non-standard library path. If so, pass it to configure,
24496 via the LDFLAGS environment variable.
24497 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
24498 ============================================================================
24499 You probably have to install the development version of the Python package
24500 for your distribution. The exact name of this package varies among them.
24501 ============================================================================
24502 " >&5
24503 $as_echo "$as_me: WARNING:
24504 Could not link test program to Python. Maybe the main Python library has been
24505 installed in some non-standard library path. If so, pass it to configure,
24506 via the LDFLAGS environment variable.
24507 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
24508 ============================================================================
24509 You probably have to install the development version of the Python package
24510 for your distribution. The exact name of this package varies among them.
24511 ============================================================================
24512 " >&2;}
24513 PYTHON_VERSION=""
24514 fi
24515
24516 #
24517 # all done!
24518 #
24519
24520 if test "$PYTHON_VERSION"; then
24521 PYTHONS="$(echo $PYTHONS $PYTHON)"
24522 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS $PYTHON_VERSION)"
24523 fi
24524
24525 fi
24526
24527
24528
24529 fi
24530
24531 # Recover some values lost in the second attempt to find Python.
24532 PYTHON="$(echo $PYTHONS | cut -d ' ' -f 1)"
24533 PYTHON_VERSION="$(echo $PYTHON_VERSIONS | cut -d ' ' -f 1)"
24534
24535 # Remove duplicates.
24536 PYTHONS="$(echo $PYTHONS | tr '[:space:]' '\n' | sort | uniq | tr '\n' ' ' | sed -e 's/ $//')"
24537 PYTHON_VERSIONS="$(echo $PYTHON_VERSIONS | tr '[:space:]' '\n' | sort | uniq | tr '\n' ' ' | sed -e 's/ $//')"
24538
24539 if test "$PYTHON_VERSIONS"; then
24540 enabled_languages_v=$(echo $enabled_languages | sed -Ee "s/python[23]?/python ($PYTHON_VERSIONS)/")
24541 enabled_languages=$(echo $enabled_languages | sed -Ee "s/python[23]?/python/")
24542 else
24543 if test "$explicit_languages" = "1"; then
24544 as_fn_error $? "
24545 ***
24546 *** Please install the python development packages.
24547 ***" "$LINENO" 5
24548 else
24549 enabled_languages=$(echo $enabled_languages | sed 's/python//')
24550 fi
24551 fi
24552
24553 PYTHONS=$PYTHONS
24554
24555 fi
24556 fi
24557
24558 ENABLED_LANGUAGES=$enabled_languages
24559
24560
24561 #
24562 # Provide information about the build.
24563 #
24564 BUILD_REVISION="72bb46b3"
24565
24566
24567 cat >>confdefs.h <<_ACEOF
24568 #define BUILD_REVISION "$BUILD_REVISION"
24569 _ACEOF
24570
24571
24572 BUILD_VERSION=`echo "$PACKAGE_VERSION" | sed 's/\([0-9.]*\).*/\1./'`
24573 BUILD_VERSION="${BUILD_VERSION}29371"
24574 BUILD_FILEVERSION=`echo "${BUILD_VERSION}" | tr . ,`
24575
24576
24577
24578 # Check whether --enable-build-timestamp was given.
24579 if test "${enable_build_timestamp+set}" = set; then :
24580 enableval=$enable_build_timestamp; if test "$enableval" = "yes"; then
24581 BUILD_TIMESTAMP=`date -u +%Y-%m-%dT%H:%M+0000 2>/dev/null || date`
24582 else
24583 BUILD_TIMESTAMP="$enableval"
24584 fi
24585 else
24586 BUILD_TIMESTAMP="<none>"
24587 fi
24588
24589
24590
24591 cat >>confdefs.h <<_ACEOF
24592 #define BUILD_TIMESTAMP "$BUILD_TIMESTAMP"
24593 _ACEOF
24594
24595
24596
24597 #
24598 # Options to disable some regression tests
24599 #
24600 run_gpgconf_test="yes"
24601 # Check whether --enable-gpgconf-test was given.
24602 if test "${enable_gpgconf_test+set}" = set; then :
24603 enableval=$enable_gpgconf_test; run_gpgconf_test=$enableval
24604 fi
24605
24606 if test "$run_gpgconf_test" = "yes"; then
24607 RUN_GPGCONF_TESTS_TRUE=
24608 RUN_GPGCONF_TESTS_FALSE='#'
24609 else
24610 RUN_GPGCONF_TESTS_TRUE='#'
24611 RUN_GPGCONF_TESTS_FALSE=
24612 fi
24613
24614
24615 run_gpg_test="yes"
24616 # Check whether --enable-gpg-test was given.
24617 if test "${enable_gpg_test+set}" = set; then :
24618 enableval=$enable_gpg_test; run_gpg_test=$enableval
24619 fi
24620
24621 if test "$run_gpg_test" = "yes"; then
24622 RUN_GPG_TESTS_TRUE=
24623 RUN_GPG_TESTS_FALSE='#'
24624 else
24625 RUN_GPG_TESTS_TRUE='#'
24626 RUN_GPG_TESTS_FALSE=
24627 fi
24628
24629
24630 run_gpgsm_test="yes"
24631 # Check whether --enable-gpgsm-test was given.
24632 if test "${enable_gpgsm_test+set}" = set; then :
24633 enableval=$enable_gpgsm_test; run_gpgsm_test=$enableval
24634 fi
24635
24636 if test "$run_gpgsm_test" = "yes"; then
24637 RUN_GPGSM_TESTS_TRUE=
24638 RUN_GPGSM_TESTS_FALSE='#'
24639 else
24640 RUN_GPGSM_TESTS_TRUE='#'
24641 RUN_GPGSM_TESTS_FALSE=
24642 fi
24643
24644
24645 run_g13_test="yes"
24646 # Check whether --enable-g13-test was given.
24647 if test "${enable_g13_test+set}" = set; then :
24648 enableval=$enable_g13_test; run_g13_test=$enableval
24649 fi
24650
24651 if test "$run_g13_test" = "yes"; then
24652 RUN_G13_TESTS_TRUE=
24653 RUN_G13_TESTS_FALSE='#'
24654 else
24655 RUN_G13_TESTS_TRUE='#'
24656 RUN_G13_TESTS_FALSE=
24657 fi
24658
24659
24660
24661 # Checks for header files.
24662
24663
24664
24665 for ac_header in $ac_header_list
24666 do :
24667 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
24668 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
24669 "
24670 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
24671 cat >>confdefs.h <<_ACEOF
24672 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
24673 _ACEOF
24674
24675 fi
24676
24677 done
24678
24679
24680
24681
24682
24683
24684
24685
24686
24687
24688
24689
24690
24691
24692
24693
24694
24695
24696
24697
24698
24699
24700
24701
24702 # Type checks.
24703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
24704 $as_echo_n "checking for inline... " >&6; }
24705 if ${ac_cv_c_inline+:} false; then :
24706 $as_echo_n "(cached) " >&6
24707 else
24708 ac_cv_c_inline=no
24709 for ac_kw in inline __inline__ __inline; do
24710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24711 /* end confdefs.h. */
24712 #ifndef __cplusplus
24713 typedef int foo_t;
24714 static $ac_kw foo_t static_foo () {return 0; }
24715 $ac_kw foo_t foo () {return 0; }
24716 #endif
24717
24718 _ACEOF
24719 if ac_fn_c_try_compile "$LINENO"; then :
24720 ac_cv_c_inline=$ac_kw
24721 fi
24722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24723 test "$ac_cv_c_inline" != no && break
24724 done
24725
24726 fi
24727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
24728 $as_echo "$ac_cv_c_inline" >&6; }
24729
24730 case $ac_cv_c_inline in
24731 inline | yes) ;;
24732 *)
24733 case $ac_cv_c_inline in
24734 no) ac_val=;;
24735 *) ac_val=$ac_cv_c_inline;;
24736 esac
24737 cat >>confdefs.h <<_ACEOF
24738 #ifndef __cplusplus
24739 #define inline $ac_val
24740 #endif
24741 _ACEOF
24742 ;;
24743 esac
24744
24745
24746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array members" >&5
24747 $as_echo_n "checking for flexible array members... " >&6; }
24748 if ${ac_cv_c_flexmember+:} false; then :
24749 $as_echo_n "(cached) " >&6
24750 else
24751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24752 /* end confdefs.h. */
24753 #include <stdlib.h>
24754 #include <stdio.h>
24755 #include <stddef.h>
24756 struct s { int n; double d[]; };
24757 int
24758 main ()
24759 {
24760 int m = getchar ();
24761 struct s *p = malloc (offsetof (struct s, d)
24762 + m * sizeof (double));
24763 p->d[0] = 0.0;
24764 return p->d != (double *) NULL;
24765 ;
24766 return 0;
24767 }
24768 _ACEOF
24769 if ac_fn_c_try_compile "$LINENO"; then :
24770 ac_cv_c_flexmember=yes
24771 else
24772 ac_cv_c_flexmember=no
24773 fi
24774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24775 fi
24776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
24777 $as_echo "$ac_cv_c_flexmember" >&6; }
24778 if test $ac_cv_c_flexmember = yes; then
24779
24780 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
24781
24782 else
24783 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
24784
24785 fi
24786
24787 # The cast to long int works around a bug in the HP C Compiler
24788 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24789 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24790 # This bug is HP SR number 8606223364.
24791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned int" >&5
24792 $as_echo_n "checking size of unsigned int... " >&6; }
24793 if ${ac_cv_sizeof_unsigned_int+:} false; then :
24794 $as_echo_n "(cached) " >&6
24795 else
24796 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned int))" "ac_cv_sizeof_unsigned_int" "$ac_includes_default"; then :
24797
24798 else
24799 if test "$ac_cv_type_unsigned_int" = yes; then
24800 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
24801 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24802 as_fn_error 77 "cannot compute sizeof (unsigned int)
24803 See \`config.log' for more details" "$LINENO" 5; }
24804 else
24805 ac_cv_sizeof_unsigned_int=0
24806 fi
24807 fi
24808
24809 fi
24810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_int" >&5
24811 $as_echo "$ac_cv_sizeof_unsigned_int" >&6; }
24812
24813
24814
24815 cat >>confdefs.h <<_ACEOF
24816 #define SIZEOF_UNSIGNED_INT $ac_cv_sizeof_unsigned_int
24817 _ACEOF
24818
24819
24820 # Check whether --enable-largefile was given.
24821 if test "${enable_largefile+set}" = set; then :
24822 enableval=$enable_largefile;
24823 fi
24824
24825 if test "$enable_largefile" != no; then
24826
24827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
24828 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
24829 if ${ac_cv_sys_largefile_CC+:} false; then :
24830 $as_echo_n "(cached) " >&6
24831 else
24832 ac_cv_sys_largefile_CC=no
24833 if test "$GCC" != yes; then
24834 ac_save_CC=$CC
24835 while :; do
24836 # IRIX 6.2 and later do not support large files by default,
24837 # so use the C compiler's -n32 option if that helps.
24838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24839 /* end confdefs.h. */
24840 #include <sys/types.h>
24841 /* Check that off_t can represent 2**63 - 1 correctly.
24842 We can't simply define LARGE_OFF_T to be 9223372036854775807,
24843 since some C++ compilers masquerading as C compilers
24844 incorrectly reject 9223372036854775807. */
24845 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24846 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24847 && LARGE_OFF_T % 2147483647 == 1)
24848 ? 1 : -1];
24849 int
24850 main ()
24851 {
24852
24853 ;
24854 return 0;
24855 }
24856 _ACEOF
24857 if ac_fn_c_try_compile "$LINENO"; then :
24858 break
24859 fi
24860 rm -f core conftest.err conftest.$ac_objext
24861 CC="$CC -n32"
24862 if ac_fn_c_try_compile "$LINENO"; then :
24863 ac_cv_sys_largefile_CC=' -n32'; break
24864 fi
24865 rm -f core conftest.err conftest.$ac_objext
24866 break
24867 done
24868 CC=$ac_save_CC
24869 rm -f conftest.$ac_ext
24870 fi
24871 fi
24872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
24873 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
24874 if test "$ac_cv_sys_largefile_CC" != no; then
24875 CC=$CC$ac_cv_sys_largefile_CC
24876 fi
24877
24878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
24879 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
24880 if ${ac_cv_sys_file_offset_bits+:} false; then :
24881 $as_echo_n "(cached) " >&6
24882 else
24883 while :; do
24884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24885 /* end confdefs.h. */
24886 #include <sys/types.h>
24887 /* Check that off_t can represent 2**63 - 1 correctly.
24888 We can't simply define LARGE_OFF_T to be 9223372036854775807,
24889 since some C++ compilers masquerading as C compilers
24890 incorrectly reject 9223372036854775807. */
24891 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24892 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24893 && LARGE_OFF_T % 2147483647 == 1)
24894 ? 1 : -1];
24895 int
24896 main ()
24897 {
24898
24899 ;
24900 return 0;
24901 }
24902 _ACEOF
24903 if ac_fn_c_try_compile "$LINENO"; then :
24904 ac_cv_sys_file_offset_bits=no; break
24905 fi
24906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24908 /* end confdefs.h. */
24909 #define _FILE_OFFSET_BITS 64
24910 #include <sys/types.h>
24911 /* Check that off_t can represent 2**63 - 1 correctly.
24912 We can't simply define LARGE_OFF_T to be 9223372036854775807,
24913 since some C++ compilers masquerading as C compilers
24914 incorrectly reject 9223372036854775807. */
24915 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24916 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24917 && LARGE_OFF_T % 2147483647 == 1)
24918 ? 1 : -1];
24919 int
24920 main ()
24921 {
24922
24923 ;
24924 return 0;
24925 }
24926 _ACEOF
24927 if ac_fn_c_try_compile "$LINENO"; then :
24928 ac_cv_sys_file_offset_bits=64; break
24929 fi
24930 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24931 ac_cv_sys_file_offset_bits=unknown
24932 break
24933 done
24934 fi
24935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
24936 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
24937 case $ac_cv_sys_file_offset_bits in #(
24938 no | unknown) ;;
24939 *)
24940 cat >>confdefs.h <<_ACEOF
24941 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
24942 _ACEOF
24943 ;;
24944 esac
24945 rm -rf conftest*
24946 if test $ac_cv_sys_file_offset_bits = unknown; then
24947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
24948 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
24949 if ${ac_cv_sys_large_files+:} false; then :
24950 $as_echo_n "(cached) " >&6
24951 else
24952 while :; do
24953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24954 /* end confdefs.h. */
24955 #include <sys/types.h>
24956 /* Check that off_t can represent 2**63 - 1 correctly.
24957 We can't simply define LARGE_OFF_T to be 9223372036854775807,
24958 since some C++ compilers masquerading as C compilers
24959 incorrectly reject 9223372036854775807. */
24960 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24961 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24962 && LARGE_OFF_T % 2147483647 == 1)
24963 ? 1 : -1];
24964 int
24965 main ()
24966 {
24967
24968 ;
24969 return 0;
24970 }
24971 _ACEOF
24972 if ac_fn_c_try_compile "$LINENO"; then :
24973 ac_cv_sys_large_files=no; break
24974 fi
24975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24977 /* end confdefs.h. */
24978 #define _LARGE_FILES 1
24979 #include <sys/types.h>
24980 /* Check that off_t can represent 2**63 - 1 correctly.
24981 We can't simply define LARGE_OFF_T to be 9223372036854775807,
24982 since some C++ compilers masquerading as C compilers
24983 incorrectly reject 9223372036854775807. */
24984 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24985 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24986 && LARGE_OFF_T % 2147483647 == 1)
24987 ? 1 : -1];
24988 int
24989 main ()
24990 {
24991
24992 ;
24993 return 0;
24994 }
24995 _ACEOF
24996 if ac_fn_c_try_compile "$LINENO"; then :
24997 ac_cv_sys_large_files=1; break
24998 fi
24999 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25000 ac_cv_sys_large_files=unknown
25001 break
25002 done
25003 fi
25004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
25005 $as_echo "$ac_cv_sys_large_files" >&6; }
25006 case $ac_cv_sys_large_files in #(
25007 no | unknown) ;;
25008 *)
25009 cat >>confdefs.h <<_ACEOF
25010 #define _LARGE_FILES $ac_cv_sys_large_files
25011 _ACEOF
25012 ;;
25013 esac
25014 rm -rf conftest*
25015 fi
25016
25017
25018 fi
25019
25020 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
25021 if test "x$ac_cv_type_off_t" = xyes; then :
25022
25023 else
25024
25025 cat >>confdefs.h <<_ACEOF
25026 #define off_t long int
25027 _ACEOF
25028
25029 fi
25030
25031
25032 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
25033 if test "x$ac_cv_type_uintptr_t" = xyes; then :
25034
25035 $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
25036
25037 else
25038 for ac_type in 'unsigned int' 'unsigned long int' \
25039 'unsigned long long int'; do
25040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25041 /* end confdefs.h. */
25042 $ac_includes_default
25043 int
25044 main ()
25045 {
25046 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
25047 test_array [0] = 0;
25048 return test_array [0];
25049
25050 ;
25051 return 0;
25052 }
25053 _ACEOF
25054 if ac_fn_c_try_compile "$LINENO"; then :
25055
25056 cat >>confdefs.h <<_ACEOF
25057 #define uintptr_t $ac_type
25058 _ACEOF
25059
25060 ac_type=
25061 fi
25062 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25063 test -z "$ac_type" && break
25064 done
25065 fi
25066
25067
25068
25069 # We require uint64_t
25070 if test "$ac_cv_header_stdint_h" != yes; then
25071 as_fn_error $? "
25072 ***
25073 *** No stdint.h and thus no uint64_t type. Can't build this library.
25074 ***" "$LINENO" 5
25075 fi
25076
25077
25078 # A simple compile time check in gpgme.h for GNU/Linux systems that
25079 # prevents a file offset bits mismatch between gpgme and the application.
25080 NEED__FILE_OFFSET_BITS=0
25081 if test "$have_w32_system" != yes; then
25082 case "$ac_cv_sys_file_offset_bits" in
25083 "" | no | unknown) ;;
25084 *)
25085 NEED__FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits
25086 ;;
25087 esac
25088 fi
25089
25090
25091 # Figure out platform dependent typedefs for gpgme.h
25092 if test "$have_w32_system" = yes; then
25093 INSERT__TYPEDEFS_FOR_GPGME_H="
25094 #ifdef _WIN64
25095 # include <stdint.h>
25096 typedef int64_t gpgme_off_t;
25097 typedef int64_t gpgme_ssize_t;
25098 #else /* _WIN32 */
25099 typedef long gpgme_off_t;
25100 typedef long gpgme_ssize_t;
25101 #endif /* _WIN32 */"
25102 API__OFF_T="gpgme_off_t"
25103 API__SSIZE_T="gpgme_ssize_t"
25104 else
25105 INSERT__TYPEDEFS_FOR_GPGME_H="
25106 #include <sys/types.h>
25107 typedef off_t gpgme_off_t;
25108 typedef ssize_t gpgme_ssize_t;"
25109 API__OFF_T="off_t"
25110 API__SSIZE_T="ssize_t"
25111 fi
25112
25113
25114
25115
25116
25117
25118
25119 # Checks for compiler features.
25120 if test "$GCC" = yes; then
25121 CFLAGS="$CFLAGS -Wall -Wcast-align -Wshadow -Wstrict-prototypes"
25122 CFLAGS="$CFLAGS -Wno-format-y2k"
25123
25124 # If -Wno-missing-field-initializers is supported we can expect a
25125 # a larger set of warning options.
25126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gcc supports -Wno-missing-field-initializers" >&5
25127 $as_echo_n "checking if gcc supports -Wno-missing-field-initializers... " >&6; }
25128 _gcc_cflags_save=$CFLAGS
25129 CFLAGS="-Wno-missing-field-initializers"
25130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25131 /* end confdefs.h. */
25132
25133 int
25134 main ()
25135 {
25136
25137 ;
25138 return 0;
25139 }
25140 _ACEOF
25141 if ac_fn_c_try_compile "$LINENO"; then :
25142 _gcc_wopt=yes
25143 else
25144 _gcc_wopt=no
25145 fi
25146 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_gcc_wopt" >&5
25148 $as_echo "$_gcc_wopt" >&6; }
25149 CFLAGS=$_gcc_cflags_save;
25150 if test x"$_gcc_wopt" = xyes ; then
25151 CFLAGS="$CFLAGS -Wno-missing-field-initializers"
25152 CFLAGS="$CFLAGS -Wno-sign-compare"
25153 CFLAGS="$CFLAGS -Wno-format-zero-length"
25154 CFLAGS="$CFLAGS -Wno-format-truncation"
25155 CFLAGS="$CFLAGS -Wno-sizeof-pointer-div"
25156 fi
25157 if test "$USE_MAINTAINER_MODE" = "yes"; then
25158 if test x"$_gcc_wopt" = xyes ; then
25159 CFLAGS="$CFLAGS -W -Wextra -Wbad-function-cast"
25160 CFLAGS="$CFLAGS -Wwrite-strings"
25161 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
25162 fi
25163 CFLAGS="$CFLAGS -Wformat -Wformat-security"
25164 CXXFLAGS="$CXXFLAGS -Wall -Wextra -Wno-shadow"
25165
25166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gcc supports -Wpointer-arith" >&5
25167 $as_echo_n "checking if gcc supports -Wpointer-arith... " >&6; }
25168 _gcc_cflags_save=$CFLAGS
25169 CFLAGS="-Wpointer-arith"
25170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25171 /* end confdefs.h. */
25172
25173 int
25174 main ()
25175 {
25176
25177 ;
25178 return 0;
25179 }
25180 _ACEOF
25181 if ac_fn_c_try_compile "$LINENO"; then :
25182 _gcc_wopt=yes
25183 else
25184 _gcc_wopt=no
25185 fi
25186 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_gcc_wopt" >&5
25188 $as_echo "$_gcc_wopt" >&6; }
25189 CFLAGS=$_gcc_cflags_save;
25190 if test x"$_gcc_wopt" = xyes ; then
25191 CFLAGS="$CFLAGS -Wpointer-arith"
25192 fi
25193 fi
25194 if test "$have_w32_system" = yes; then
25195 CFLAGS="$CFLAGS -mms-bitfields"
25196 fi
25197 fi
25198
25199 # Only used for debugging, so no serious test needed (for actual
25200 # functionality you have to test libc as well, this only tests the
25201 # compiler).
25202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __thread" >&5
25203 $as_echo_n "checking for __thread... " >&6; }
25204 if ${gpgme_cv_tls_works+:} false; then :
25205 $as_echo_n "(cached) " >&6
25206 else
25207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25208 /* end confdefs.h. */
25209 __thread int foo;
25210 int
25211 main ()
25212 {
25213
25214 ;
25215 return 0;
25216 }
25217 _ACEOF
25218 if ac_fn_c_try_compile "$LINENO"; then :
25219 gpgme_cv_tls_works=yes
25220 else
25221 gpgme_cv_tls_works=no
25222 fi
25223 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25224 fi
25225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gpgme_cv_tls_works" >&5
25226 $as_echo "$gpgme_cv_tls_works" >&6; }
25227 if test "$gpgme_cv_tls_works" = yes; then
25228
25229 $as_echo "#define HAVE_TLS 1" >>confdefs.h
25230
25231 fi
25232
25233
25234 # Checks for library functions.
25235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libraries" >&5
25236 $as_echo "$as_me: checking for libraries" >&6;}
25237
25238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
25239 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
25240 if ${ac_cv_sys_largefile_source+:} false; then :
25241 $as_echo_n "(cached) " >&6
25242 else
25243 while :; do
25244 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25245 /* end confdefs.h. */
25246 #include <sys/types.h> /* for off_t */
25247 #include <stdio.h>
25248 int
25249 main ()
25250 {
25251 int (*fp) (FILE *, off_t, int) = fseeko;
25252 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
25253 ;
25254 return 0;
25255 }
25256 _ACEOF
25257 if ac_fn_c_try_link "$LINENO"; then :
25258 ac_cv_sys_largefile_source=no; break
25259 fi
25260 rm -f core conftest.err conftest.$ac_objext \
25261 conftest$ac_exeext conftest.$ac_ext
25262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25263 /* end confdefs.h. */
25264 #define _LARGEFILE_SOURCE 1
25265 #include <sys/types.h> /* for off_t */
25266 #include <stdio.h>
25267 int
25268 main ()
25269 {
25270 int (*fp) (FILE *, off_t, int) = fseeko;
25271 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
25272 ;
25273 return 0;
25274 }
25275 _ACEOF
25276 if ac_fn_c_try_link "$LINENO"; then :
25277 ac_cv_sys_largefile_source=1; break
25278 fi
25279 rm -f core conftest.err conftest.$ac_objext \
25280 conftest$ac_exeext conftest.$ac_ext
25281 ac_cv_sys_largefile_source=unknown
25282 break
25283 done
25284 fi
25285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
25286 $as_echo "$ac_cv_sys_largefile_source" >&6; }
25287 case $ac_cv_sys_largefile_source in #(
25288 no | unknown) ;;
25289 *)
25290 cat >>confdefs.h <<_ACEOF
25291 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
25292 _ACEOF
25293 ;;
25294 esac
25295 rm -rf conftest*
25296
25297 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
25298 # in glibc 2.1.3, but that breaks too many other things.
25299 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
25300 if test $ac_cv_sys_largefile_source != unknown; then
25301
25302 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
25303
25304 fi
25305
25306
25307 # Try to find a thread-safe version of ttyname().
25308 ac_fn_c_check_decl "$LINENO" "ttyname_r" "ac_cv_have_decl_ttyname_r" "$ac_includes_default"
25309 if test "x$ac_cv_have_decl_ttyname_r" = xyes; then :
25310 ac_have_decl=1
25311 else
25312 ac_have_decl=0
25313 fi
25314
25315 cat >>confdefs.h <<_ACEOF
25316 #define HAVE_DECL_TTYNAME_R $ac_have_decl
25317 _ACEOF
25318
25319
25320 for ac_header in unistd.h
25321 do :
25322 ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
25323 if test "x$ac_cv_header_unistd_h" = xyes; then :
25324 cat >>confdefs.h <<_ACEOF
25325 #define HAVE_UNISTD_H 1
25326 _ACEOF
25327
25328 fi
25329
25330 done
25331
25332
25333
25334 if test $ac_cv_have_decl_ttyname_r = no; then
25335 HAVE_DECL_TTYNAME_R=0
25336 fi
25337
25338 for ac_func in ttyname_r
25339 do :
25340 ac_fn_c_check_func "$LINENO" "ttyname_r" "ac_cv_func_ttyname_r"
25341 if test "x$ac_cv_func_ttyname_r" = xyes; then :
25342 cat >>confdefs.h <<_ACEOF
25343 #define HAVE_TTYNAME_R 1
25344 _ACEOF
25345
25346 fi
25347 done
25348
25349 if test $ac_cv_func_ttyname_r = no; then
25350 HAVE_TTYNAME_R=0
25351 case " $LIBOBJS " in
25352 *" ttyname_r.$ac_objext "* ) ;;
25353 *) LIBOBJS="$LIBOBJS ttyname_r.$ac_objext"
25354 ;;
25355 esac
25356
25357
25358 $as_echo "#define REPLACE_TTYNAME_R 1" >>confdefs.h
25359
25360 else
25361 HAVE_TTYNAME_R=1
25362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ttyname_r is compatible with its POSIX signature" >&5
25363 $as_echo_n "checking whether ttyname_r is compatible with its POSIX signature... " >&6; }
25364 if ${gnupg_cv_func_ttyname_r_posix+:} false; then :
25365 $as_echo_n "(cached) " >&6
25366 else
25367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25368 /* end confdefs.h. */
25369 #include <stddef.h>
25370 #include <unistd.h>
25371 int
25372 main ()
25373 {
25374 *ttyname_r (0, NULL, 0);
25375 ;
25376 return 0;
25377 }
25378
25379 _ACEOF
25380 if ac_fn_c_try_compile "$LINENO"; then :
25381 gnupg_cv_func_ttyname_r_posix=no
25382 else
25383 gnupg_cv_func_ttyname_r_posix=yes
25384 fi
25385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25386
25387 fi
25388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gnupg_cv_func_ttyname_r_posix" >&5
25389 $as_echo "$gnupg_cv_func_ttyname_r_posix" >&6; }
25390 if test $gnupg_cv_func_ttyname_r_posix = no; then
25391 case " $LIBOBJS " in
25392 *" ttyname_r.$ac_objext "* ) ;;
25393 *) LIBOBJS="$LIBOBJS ttyname_r.$ac_objext"
25394 ;;
25395 esac
25396
25397 $as_echo "#define REPLACE_TTYNAME_R 1" >>confdefs.h
25398
25399 elif test "$have_android_system" = yes; then
25400 # Android has ttyname and ttyname_r but they are only stubs and
25401 # print an annoying warning message. Thus we need to replace
25402 # ttyname_r with our own dummy function.
25403 case " $LIBOBJS " in
25404 *" ttyname_r.$ac_objext "* ) ;;
25405 *) LIBOBJS="$LIBOBJS ttyname_r.$ac_objext"
25406 ;;
25407 esac
25408
25409 $as_echo "#define REPLACE_TTYNAME_R 1" >>confdefs.h
25410
25411 else
25412
25413 $as_echo "#define HAVE_POSIXDECL_TTYNAME_R 1" >>confdefs.h
25414
25415
25416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ttyname_r works with small buffers" >&5
25417 $as_echo_n "checking whether ttyname_r works with small buffers... " >&6; }
25418 if ${gnupg_cv_func_ttyname_r_works+:} false; then :
25419 $as_echo_n "(cached) " >&6
25420 else
25421
25422 case "$host_os" in
25423 # Guess no on Solaris.
25424 solaris*) gnupg_cv_func_ttyname_r_works="guessing no" ;;
25425 # Guess no on OSF/1.
25426 osf*) gnupg_cv_func_ttyname_r_works="guessing no" ;;
25427 # Guess yes otherwise.
25428 *) gnupg_cv_func_ttyname_r_works="guessing yes" ;;
25429 esac
25430 if test "$cross_compiling" = yes; then :
25431 :
25432 else
25433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25434 /* end confdefs.h. */
25435
25436 #include <fcntl.h>
25437 #include <unistd.h>
25438 int
25439 main (void)
25440 {
25441 int result = 0;
25442 int fd;
25443 char buf[31]; /* use any size < 128 here */
25444
25445 fd = open ("/dev/tty", O_RDONLY);
25446 if (fd < 0)
25447 result |= 16;
25448 else if (ttyname_r (fd, buf, sizeof (buf)) != 0)
25449 result |= 17;
25450 else if (ttyname_r (fd, buf, 1) == 0)
25451 result |= 18;
25452 return result;
25453 }
25454 _ACEOF
25455 if ac_fn_c_try_run "$LINENO"; then :
25456 gnupg_cv_func_ttyname_r_works=yes
25457 else
25458 case $? in
25459 17 | 18) gnupg_cv_func_ttyname_r_works=no ;;
25460 esac
25461 fi
25462 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25463 conftest.$ac_objext conftest.beam conftest.$ac_ext
25464 fi
25465
25466
25467 fi
25468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gnupg_cv_func_ttyname_r_works" >&5
25469 $as_echo "$gnupg_cv_func_ttyname_r_works" >&6; }
25470 case "$gnupg_cv_func_ttyname_r_works" in
25471 *yes) ;;
25472 *) case " $LIBOBJS " in
25473 *" ttyname_r.$ac_objext "* ) ;;
25474 *) LIBOBJS="$LIBOBJS ttyname_r.$ac_objext"
25475 ;;
25476 esac
25477
25478 $as_echo "#define REPLACE_TTYNAME_R 1" >>confdefs.h
25479
25480
25481 $as_echo "#define HAVE_BROKEN_TTYNAME_R 1" >>confdefs.h
25482
25483 ;;
25484 esac
25485 fi
25486 fi
25487
25488 if test "$ac_cv_func_ttyname_r" != yes; then
25489 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
25490 ***
25491 *** ttyname() is not thread-safe and ttyname_r() does not exist
25492 ***" >&5
25493 $as_echo "$as_me: WARNING:
25494 ***
25495 *** ttyname() is not thread-safe and ttyname_r() does not exist
25496 ***" >&2;}
25497 fi
25498
25499 # Try to find a thread-safe version of getenv().
25500 have_thread_safe_getenv=no
25501
25502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2.1 or newer" >&5
25503 $as_echo_n "checking whether we are using the GNU C Library 2.1 or newer... " >&6; }
25504 if ${ac_cv_gnu_library_2_1+:} false; then :
25505 $as_echo_n "(cached) " >&6
25506 else
25507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25508 /* end confdefs.h. */
25509
25510 #include <features.h>
25511 #ifdef __GNU_LIBRARY__
25512 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
25513 Lucky GNU user
25514 #endif
25515 #endif
25516
25517 _ACEOF
25518 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25519 $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
25520 ac_cv_gnu_library_2_1=yes
25521 else
25522 ac_cv_gnu_library_2_1=no
25523 fi
25524 rm -f conftest*
25525
25526
25527
25528 fi
25529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
25530 $as_echo "$ac_cv_gnu_library_2_1" >&6; }
25531
25532 GLIBC21="$ac_cv_gnu_library_2_1"
25533
25534
25535 if test $GLIBC21 = yes -o $have_w32_system = yes; then
25536 have_thread_safe_getenv=yes
25537 fi
25538 if test $have_thread_safe_getenv = yes; then
25539
25540 $as_echo "#define HAVE_THREAD_SAFE_GETENV 1" >>confdefs.h
25541
25542 fi
25543 have_getenv_r=no
25544 for ac_func in getenv_r
25545 do :
25546 ac_fn_c_check_func "$LINENO" "getenv_r" "ac_cv_func_getenv_r"
25547 if test "x$ac_cv_func_getenv_r" = xyes; then :
25548 cat >>confdefs.h <<_ACEOF
25549 #define HAVE_GETENV_R 1
25550 _ACEOF
25551 have_getenv_r=yes
25552 fi
25553 done
25554
25555 if test $have_getenv_r = no && test $have_thread_safe_getenv = no; then
25556 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
25557 ***
25558 *** getenv() is not thread-safe and getenv_r() does not exist
25559 ***" >&5
25560 $as_echo "$as_me: WARNING:
25561 ***
25562 *** getenv() is not thread-safe and getenv_r() does not exist
25563 ***" >&2;}
25564 fi
25565
25566 # For converting time strings to seconds since Epoch, we need the timegm
25567 # function.
25568 for ac_func in timegm
25569 do :
25570 ac_fn_c_check_func "$LINENO" "timegm" "ac_cv_func_timegm"
25571 if test "x$ac_cv_func_timegm" = xyes; then :
25572 cat >>confdefs.h <<_ACEOF
25573 #define HAVE_TIMEGM 1
25574 _ACEOF
25575
25576 fi
25577 done
25578
25579 if test "$ac_cv_func_timegm" != yes; then
25580 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
25581 ***
25582 *** timegm() not available - a non-thread-safe kludge will be used
25583 *** and the TZ variable might be changed at runtime.
25584 ***" >&5
25585 $as_echo "$as_me: WARNING:
25586 ***
25587 *** timegm() not available - a non-thread-safe kludge will be used
25588 *** and the TZ variable might be changed at runtime.
25589 ***" >&2;}
25590 fi
25591
25592 for ac_func in setlocale
25593 do :
25594 ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale"
25595 if test "x$ac_cv_func_setlocale" = xyes; then :
25596 cat >>confdefs.h <<_ACEOF
25597 #define HAVE_SETLOCALE 1
25598 _ACEOF
25599
25600 fi
25601 done
25602
25603
25604 # Checking for libgpg-error.
25605 have_gpg_error=no
25606
25607 gpg_error_config_prefix=""
25608
25609 # Check whether --with-libgpg-error-prefix was given.
25610 if test "${with_libgpg_error_prefix+set}" = set; then :
25611 withval=$with_libgpg_error_prefix; gpg_error_config_prefix="$withval"
25612 fi
25613
25614
25615
25616 # Check whether --with-gpg-error-prefix was given.
25617 if test "${with_gpg_error_prefix+set}" = set; then :
25618 withval=$with_gpg_error_prefix; gpg_error_config_prefix="$withval"
25619 fi
25620
25621
25622 if test x"${GPG_ERROR_CONFIG}" = x ; then
25623 if test x"${gpg_error_config_prefix}" != x ; then
25624 GPG_ERROR_CONFIG="${gpg_error_config_prefix}/bin/gpg-error-config"
25625 else
25626 case "${SYSROOT}" in
25627 /*)
25628 if test -x "${SYSROOT}/bin/gpg-error-config" ; then
25629 GPG_ERROR_CONFIG="${SYSROOT}/bin/gpg-error-config"
25630 fi
25631 ;;
25632 '')
25633 ;;
25634 *)
25635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring \$SYSROOT as it is not an absolute path." >&5
25636 $as_echo "$as_me: WARNING: Ignoring \$SYSROOT as it is not an absolute path." >&2;}
25637 ;;
25638 esac
25639 fi
25640 fi
25641
25642 # Extract the first word of "gpg-error-config", so it can be a program name with args.
25643 set dummy gpg-error-config; ac_word=$2
25644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25645 $as_echo_n "checking for $ac_word... " >&6; }
25646 if ${ac_cv_path_GPG_ERROR_CONFIG+:} false; then :
25647 $as_echo_n "(cached) " >&6
25648 else
25649 case $GPG_ERROR_CONFIG in
25650 [\\/]* | ?:[\\/]*)
25651 ac_cv_path_GPG_ERROR_CONFIG="$GPG_ERROR_CONFIG" # Let the user override the test with a path.
25652 ;;
25653 *)
25654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25655 for as_dir in $PATH
25656 do
25657 IFS=$as_save_IFS
25658 test -z "$as_dir" && as_dir=.
25659 for ac_exec_ext in '' $ac_executable_extensions; do
25660 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25661 ac_cv_path_GPG_ERROR_CONFIG="$as_dir/$ac_word$ac_exec_ext"
25662 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25663 break 2
25664 fi
25665 done
25666 done
25667 IFS=$as_save_IFS
25668
25669 test -z "$ac_cv_path_GPG_ERROR_CONFIG" && ac_cv_path_GPG_ERROR_CONFIG="no"
25670 ;;
25671 esac
25672 fi
25673 GPG_ERROR_CONFIG=$ac_cv_path_GPG_ERROR_CONFIG
25674 if test -n "$GPG_ERROR_CONFIG"; then
25675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GPG_ERROR_CONFIG" >&5
25676 $as_echo "$GPG_ERROR_CONFIG" >&6; }
25677 else
25678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25679 $as_echo "no" >&6; }
25680 fi
25681
25682
25683 min_gpg_error_version="$NEED_GPG_ERROR_VERSION"
25684 ok=no
25685
25686 # Extract the first word of "gpgrt-config", so it can be a program name with args.
25687 set dummy gpgrt-config; ac_word=$2
25688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25689 $as_echo_n "checking for $ac_word... " >&6; }
25690 if ${ac_cv_path_GPGRT_CONFIG+:} false; then :
25691 $as_echo_n "(cached) " >&6
25692 else
25693 case $GPGRT_CONFIG in
25694 [\\/]* | ?:[\\/]*)
25695 ac_cv_path_GPGRT_CONFIG="$GPGRT_CONFIG" # Let the user override the test with a path.
25696 ;;
25697 *)
25698 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25699 as_dummy="$prefix/bin:$PATH"
25700 for as_dir in $as_dummy
25701 do
25702 IFS=$as_save_IFS
25703 test -z "$as_dir" && as_dir=.
25704 for ac_exec_ext in '' $ac_executable_extensions; do
25705 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25706 ac_cv_path_GPGRT_CONFIG="$as_dir/$ac_word$ac_exec_ext"
25707 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25708 break 2
25709 fi
25710 done
25711 done
25712 IFS=$as_save_IFS
25713
25714 test -z "$ac_cv_path_GPGRT_CONFIG" && ac_cv_path_GPGRT_CONFIG="no"
25715 ;;
25716 esac
25717 fi
25718 GPGRT_CONFIG=$ac_cv_path_GPGRT_CONFIG
25719 if test -n "$GPGRT_CONFIG"; then
25720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GPGRT_CONFIG" >&5
25721 $as_echo "$GPGRT_CONFIG" >&6; }
25722 else
25723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25724 $as_echo "no" >&6; }
25725 fi
25726
25727
25728 if test "$GPGRT_CONFIG" != "no"; then
25729 # Determine gpgrt_libdir
25730 #
25731 # Get the prefix of gpgrt-config assuming it's something like:
25732 # <PREFIX>/bin/gpgrt-config
25733 gpgrt_prefix=${GPGRT_CONFIG%/*/*}
25734 possible_libdir1=${gpgrt_prefix}/lib
25735 # Determine by using system libdir-format with CC, it's like:
25736 # Normal style: /usr/lib
25737 # GNU cross style: /usr/<triplet>/lib
25738 # Debian style: /usr/lib/<multiarch-name>
25739 # Fedora/openSUSE style: /usr/lib, /usr/lib32 or /usr/lib64
25740 # It is assumed that CC is specified to the one of host on cross build.
25741 if libdir_candidates=$(${CC:-cc} -print-search-dirs | \
25742 sed -n -e "/^libraries/{s/libraries: =//;s/:/\\
25743 /g;p;}"); then
25744 # From the output of -print-search-dirs, select valid pkgconfig dirs.
25745 libdir_candidates=$(for dir in $libdir_candidates; do
25746 if p=$(cd $dir 2>/dev/null && pwd); then
25747 test -d "$p/pkgconfig" && echo $p;
25748 fi
25749 done)
25750
25751 for possible_libdir0 in $libdir_candidates; do
25752 # possible_libdir0:
25753 # Fallback candidate, the one of system-installed (by $CC)
25754 # (/usr/<triplet>/lib, /usr/lib/<multiarch-name> or /usr/lib32)
25755 # possible_libdir1:
25756 # Another candidate, user-locally-installed
25757 # (<gpgrt_prefix>/lib)
25758 # possible_libdir2
25759 # Most preferred
25760 # (<gpgrt_prefix>/<triplet>/lib,
25761 # <gpgrt_prefix>/lib/<multiarch-name> or <gpgrt_prefix>/lib32)
25762 if test "${possible_libdir0##*/}" = "lib"; then
25763 possible_prefix0=${possible_libdir0%/lib}
25764 possible_prefix0_triplet=${possible_prefix0##*/}
25765 if test -z "$possible_prefix0_triplet"; then
25766 continue
25767 fi
25768 possible_libdir2=${gpgrt_prefix}/$possible_prefix0_triplet/lib
25769 else
25770 possible_prefix0=${possible_libdir0%%/lib*}
25771 possible_libdir2=${gpgrt_prefix}${possible_libdir0#$possible_prefix0}
25772 fi
25773 if test -f ${possible_libdir2}/pkgconfig/gpg-error.pc; then
25774 gpgrt_libdir=${possible_libdir2}
25775 elif test -f ${possible_libdir1}/pkgconfig/gpg-error.pc; then
25776 gpgrt_libdir=${possible_libdir1}
25777 elif test -f ${possible_libdir0}/pkgconfig/gpg-error.pc; then
25778 gpgrt_libdir=${possible_libdir0}
25779 fi
25780 if test -n "$gpgrt_libdir"; then break; fi
25781 done
25782 else
25783 # When we cannot determine system libdir-format, use this:
25784 gpgrt_libdir=${possible_libdir1}
25785 fi
25786 else
25787 unset GPGRT_CONFIG
25788 fi
25789
25790 if test -n "$gpgrt_libdir"; then
25791 GPGRT_CONFIG="$GPGRT_CONFIG --libdir=$gpgrt_libdir"
25792 if $GPGRT_CONFIG gpg-error >/dev/null 2>&1; then
25793 GPG_ERROR_CONFIG="$GPGRT_CONFIG gpg-error"
25794 { $as_echo "$as_me:${as_lineno-$LINENO}: Use gpgrt-config with $gpgrt_libdir as gpg-error-config" >&5
25795 $as_echo "$as_me: Use gpgrt-config with $gpgrt_libdir as gpg-error-config" >&6;}
25796 gpg_error_config_version=`$GPG_ERROR_CONFIG --modversion`
25797 else
25798 unset GPGRT_CONFIG
25799 fi
25800 elif test "$GPG_ERROR_CONFIG" != "no"; then
25801 gpg_error_config_version=`$GPG_ERROR_CONFIG --version`
25802 fi
25803 if test "$GPG_ERROR_CONFIG" != "no"; then
25804 req_major=`echo $min_gpg_error_version | \
25805 sed 's/\([0-9]*\)\.\([0-9]*\)/\1/'`
25806 req_minor=`echo $min_gpg_error_version | \
25807 sed 's/\([0-9]*\)\.\([0-9]*\)/\2/'`
25808 major=`echo $gpg_error_config_version | \
25809 sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'`
25810 minor=`echo $gpg_error_config_version | \
25811 sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'`
25812 if test "$major" -gt "$req_major"; then
25813 ok=yes
25814 else
25815 if test "$major" -eq "$req_major"; then
25816 if test "$minor" -ge "$req_minor"; then
25817 ok=yes
25818 fi
25819 fi
25820 fi
25821 fi
25822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GPG Error - version >= $min_gpg_error_version" >&5
25823 $as_echo_n "checking for GPG Error - version >= $min_gpg_error_version... " >&6; }
25824 if test $ok = yes; then
25825 GPG_ERROR_CFLAGS=`$GPG_ERROR_CONFIG --cflags`
25826 GPG_ERROR_LIBS=`$GPG_ERROR_CONFIG --libs`
25827 if test -z "$GPGRT_CONFIG"; then
25828 GPG_ERROR_MT_CFLAGS=`$GPG_ERROR_CONFIG --mt --cflags 2>/dev/null`
25829 GPG_ERROR_MT_LIBS=`$GPG_ERROR_CONFIG --mt --libs 2>/dev/null`
25830 else
25831 GPG_ERROR_MT_CFLAGS=`$GPG_ERROR_CONFIG --variable=mtcflags 2>/dev/null`
25832 GPG_ERROR_MT_CFLAGS="$GPG_ERROR_CFLAGS${GPG_ERROR_CFLAGS:+ }$GPG_ERROR_MT_CFLAGS"
25833 GPG_ERROR_MT_LIBS=`$GPG_ERROR_CONFIG --variable=mtlibs 2>/dev/null`
25834 GPG_ERROR_MT_LIBS="$GPG_ERROR_LIBS${GPG_ERROR_LIBS:+ }$GPG_ERROR_MT_LIBS"
25835 fi
25836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($gpg_error_config_version)" >&5
25837 $as_echo "yes ($gpg_error_config_version)" >&6; }
25838 have_gpg_error=yes
25839 if test -z "$GPGRT_CONFIG"; then
25840 gpg_error_config_host=`$GPG_ERROR_CONFIG --host 2>/dev/null || echo none`
25841 else
25842 gpg_error_config_host=`$GPG_ERROR_CONFIG --variable=host 2>/dev/null || echo none`
25843 fi
25844 if test x"$gpg_error_config_host" != xnone ; then
25845 if test x"$gpg_error_config_host" != x"$host" ; then
25846 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
25847 ***
25848 *** The config script \"$GPG_ERROR_CONFIG\" was
25849 *** built for $gpg_error_config_host and thus may not match the
25850 *** used host $host.
25851 *** You may want to use the configure option --with-libgpg-error-prefix
25852 *** to specify a matching config script or use \$SYSROOT.
25853 ***" >&5
25854 $as_echo "$as_me: WARNING:
25855 ***
25856 *** The config script \"$GPG_ERROR_CONFIG\" was
25857 *** built for $gpg_error_config_host and thus may not match the
25858 *** used host $host.
25859 *** You may want to use the configure option --with-libgpg-error-prefix
25860 *** to specify a matching config script or use \$SYSROOT.
25861 ***" >&2;}
25862 gpg_config_script_warn="$gpg_config_script_warn libgpg-error"
25863 fi
25864 fi
25865 else
25866 GPG_ERROR_CFLAGS=""
25867 GPG_ERROR_LIBS=""
25868 GPG_ERROR_MT_CFLAGS=""
25869 GPG_ERROR_MT_LIBS=""
25870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25871 $as_echo "no" >&6; }
25872 have_gpg_error=no
25873 fi
25874
25875
25876
25877
25878
25879
25880 $as_echo "#define GPG_ERR_SOURCE_DEFAULT GPG_ERR_SOURCE_GPGME" >>confdefs.h
25881
25882
25883 # And for libassuan.
25884 have_libassuan=no
25885
25886
25887 # Check whether --with-libassuan-prefix was given.
25888 if test "${with_libassuan_prefix+set}" = set; then :
25889 withval=$with_libassuan_prefix; libassuan_config_prefix="$withval"
25890 else
25891 libassuan_config_prefix=""
25892 fi
25893
25894 if test x$libassuan_config_prefix != x ; then
25895 if test x${LIBASSUAN_CONFIG+set} != xset ; then
25896 LIBASSUAN_CONFIG=$libassuan_config_prefix/bin/libassuan-config
25897 fi
25898 fi
25899
25900 use_gpgrt_config=""
25901 if test x"${LIBASSUAN_CONFIG}" = x -a x"$GPGRT_CONFIG" != x -a "$GPGRT_CONFIG" != "no"; then
25902 if $GPGRT_CONFIG libassuan --exists; then
25903 LIBASSUAN_CONFIG="$GPGRT_CONFIG libassuan"
25904 { $as_echo "$as_me:${as_lineno-$LINENO}: Use gpgrt-config as libassuan-config" >&5
25905 $as_echo "$as_me: Use gpgrt-config as libassuan-config" >&6;}
25906 use_gpgrt_config=yes
25907 fi
25908 fi
25909 if test -z "$use_gpgrt_config"; then
25910 # Extract the first word of "libassuan-config", so it can be a program name with args.
25911 set dummy libassuan-config; ac_word=$2
25912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25913 $as_echo_n "checking for $ac_word... " >&6; }
25914 if ${ac_cv_path_LIBASSUAN_CONFIG+:} false; then :
25915 $as_echo_n "(cached) " >&6
25916 else
25917 case $LIBASSUAN_CONFIG in
25918 [\\/]* | ?:[\\/]*)
25919 ac_cv_path_LIBASSUAN_CONFIG="$LIBASSUAN_CONFIG" # Let the user override the test with a path.
25920 ;;
25921 *)
25922 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25923 for as_dir in $PATH
25924 do
25925 IFS=$as_save_IFS
25926 test -z "$as_dir" && as_dir=.
25927 for ac_exec_ext in '' $ac_executable_extensions; do
25928 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25929 ac_cv_path_LIBASSUAN_CONFIG="$as_dir/$ac_word$ac_exec_ext"
25930 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25931 break 2
25932 fi
25933 done
25934 done
25935 IFS=$as_save_IFS
25936
25937 test -z "$ac_cv_path_LIBASSUAN_CONFIG" && ac_cv_path_LIBASSUAN_CONFIG="no"
25938 ;;
25939 esac
25940 fi
25941 LIBASSUAN_CONFIG=$ac_cv_path_LIBASSUAN_CONFIG
25942 if test -n "$LIBASSUAN_CONFIG"; then
25943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBASSUAN_CONFIG" >&5
25944 $as_echo "$LIBASSUAN_CONFIG" >&6; }
25945 else
25946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25947 $as_echo "no" >&6; }
25948 fi
25949
25950
25951 fi
25952
25953 tmp="$NEED_LIBASSUAN_API:$NEED_LIBASSUAN_VERSION"
25954 if echo "$tmp" | grep ':' >/dev/null 2>/dev/null ; then
25955 req_libassuan_api=`echo "$tmp" | sed 's/\(.*\):\(.*\)/\1/'`
25956 min_libassuan_version=`echo "$tmp" | sed 's/\(.*\):\(.*\)/\2/'`
25957 else
25958 req_libassuan_api=0
25959 min_libassuan_version="$tmp"
25960 fi
25961
25962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBASSUAN - version >= $min_libassuan_version" >&5
25963 $as_echo_n "checking for LIBASSUAN - version >= $min_libassuan_version... " >&6; }
25964 ok=no
25965 if test "$LIBASSUAN_CONFIG" != "no"; then
25966 req_major=`echo $min_libassuan_version | \
25967 sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\)/\1/'`
25968 req_minor=`echo $min_libassuan_version | \
25969 sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\)/\2/'`
25970 req_micro=`echo $min_libassuan_version | \
25971 sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\)/\3/'`
25972
25973 if test -z "$use_gpgrt_config"; then
25974 libassuan_config_version=`$LIBASSUAN_CONFIG --version`
25975 else
25976 libassuan_config_version=`$LIBASSUAN_CONFIG --modversion`
25977 fi
25978 major=`echo $libassuan_config_version | \
25979 sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/\1/'`
25980 minor=`echo $libassuan_config_version | \
25981 sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/\2/'`
25982 micro=`echo $libassuan_config_version | \
25983 sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/\3/'`
25984
25985 if test "$major" -gt "$req_major"; then
25986 ok=yes
25987 else
25988 if test "$major" -eq "$req_major"; then
25989 if test "$minor" -gt "$req_minor"; then
25990 ok=yes
25991 else
25992 if test "$minor" -eq "$req_minor"; then
25993 if test "$micro" -ge "$req_micro"; then
25994 ok=yes
25995 fi
25996 fi
25997 fi
25998 fi
25999 fi
26000 fi
26001
26002 if test $ok = yes; then
26003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($libassuan_config_version)" >&5
26004 $as_echo "yes ($libassuan_config_version)" >&6; }
26005 else
26006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26007 $as_echo "no" >&6; }
26008 fi
26009
26010 if test $ok = yes; then
26011 if test "$req_libassuan_api" -gt 0 ; then
26012 if test -z "$use_gpgrt_config"; then
26013 tmp=`$LIBASSUAN_CONFIG --api-version 2>/dev/null || echo 0`
26014 else
26015 tmp=`$LIBASSUAN_CONFIG --variable=api_version 2>/dev/null || echo 0`
26016 fi
26017 if test "$tmp" -gt 0 ; then
26018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBASSUAN API version" >&5
26019 $as_echo_n "checking LIBASSUAN API version... " >&6; }
26020 if test "$req_libassuan_api" -eq "$tmp" ; then
26021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: okay" >&5
26022 $as_echo "okay" >&6; }
26023 else
26024 ok=no
26025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: does not match. want=$req_libassuan_api got=$tmp." >&5
26026 $as_echo "does not match. want=$req_libassuan_api got=$tmp." >&6; }
26027 fi
26028 fi
26029 fi
26030 fi
26031
26032 if test $ok = yes; then
26033 if test x"$host" != x ; then
26034 if test -z "$use_gpgrt_config"; then
26035 libassuan_config_host=`$LIBASSUAN_CONFIG --host 2>/dev/null || echo none`
26036 else
26037 libassuan_config_host=`$LIBASSUAN_CONFIG --variable=host 2>/dev/null || echo none`
26038 fi
26039 if test x"$libassuan_config_host" != xnone ; then
26040 if test x"$libassuan_config_host" != x"$host" ; then
26041 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
26042 ***
26043 *** The config script \"$LIBASSUAN_CONFIG\" was
26044 *** built for $libassuan_config_host and thus may not match the
26045 *** used host $host.
26046 *** You may want to use the configure option --with-libassuan-prefix
26047 *** to specify a matching config script.
26048 ***" >&5
26049 $as_echo "$as_me: WARNING:
26050 ***
26051 *** The config script \"$LIBASSUAN_CONFIG\" was
26052 *** built for $libassuan_config_host and thus may not match the
26053 *** used host $host.
26054 *** You may want to use the configure option --with-libassuan-prefix
26055 *** to specify a matching config script.
26056 ***" >&2;}
26057 fi
26058 fi
26059 fi
26060 fi
26061
26062 if test $ok = yes; then
26063 LIBASSUAN_CFLAGS=`$LIBASSUAN_CONFIG --cflags`
26064 LIBASSUAN_LIBS=`$LIBASSUAN_CONFIG --libs`
26065 have_libassuan=yes
26066 else
26067 LIBASSUAN_CFLAGS=""
26068 LIBASSUAN_LIBS=""
26069 have_libassuan=no
26070 fi
26071
26072
26073
26074 if test "$have_libassuan" = "yes"; then
26075
26076 cat >>confdefs.h <<_ACEOF
26077 #define GPGME_LIBASSUAN_VERSION "$libassuan_version"
26078 _ACEOF
26079
26080 fi
26081
26082
26083 #
26084 # Other checks
26085 #
26086
26087 # Check for getgid etc
26088 for ac_func in getgid getegid closefrom
26089 do :
26090 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
26091 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
26092 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
26093 cat >>confdefs.h <<_ACEOF
26094 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
26095 _ACEOF
26096
26097 fi
26098 done
26099
26100
26101
26102 # Replacement functions.
26103 ac_fn_c_check_func "$LINENO" "stpcpy" "ac_cv_func_stpcpy"
26104 if test "x$ac_cv_func_stpcpy" = xyes; then :
26105 $as_echo "#define HAVE_STPCPY 1" >>confdefs.h
26106
26107 else
26108 case " $LIBOBJS " in
26109 *" stpcpy.$ac_objext "* ) ;;
26110 *) LIBOBJS="$LIBOBJS stpcpy.$ac_objext"
26111 ;;
26112 esac
26113
26114 fi
26115
26116
26117 ac_fn_c_check_func "$LINENO" "setenv" "ac_cv_func_setenv"
26118 if test "x$ac_cv_func_setenv" = xyes; then :
26119 $as_echo "#define HAVE_SETENV 1" >>confdefs.h
26120
26121 else
26122 case " $LIBOBJS " in
26123 *" setenv.$ac_objext "* ) ;;
26124 *) LIBOBJS="$LIBOBJS setenv.$ac_objext"
26125 ;;
26126 esac
26127
26128 fi
26129
26130
26131
26132 # Assuan check for descriptor passing.
26133 ac_fn_c_check_member "$LINENO" "struct cmsghdr" "cmsg_len" "ac_cv_member_struct_cmsghdr_cmsg_len" "
26134 #include <stdlib.h>
26135 #include <stddef.h>
26136 #include <stdio.h>
26137 #include <sys/types.h>
26138 #include <sys/socket.h>
26139 #include <sys/un.h>
26140 #if HAVE_SYS_UIO_H
26141 #include <sys/uio.h>
26142 #endif
26143 #include <unistd.h>
26144
26145 "
26146 if test "x$ac_cv_member_struct_cmsghdr_cmsg_len" = xyes; then :
26147 supports_descriptor_passing=yes
26148 else
26149 supports_descriptor_passing=no
26150 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
26151 ***
26152 *** Data structure for sending ancillary data missing.
26153 *** Descriptor passing won't work.
26154 ***" >&5
26155 $as_echo "$as_me: WARNING:
26156 ***
26157 *** Data structure for sending ancillary data missing.
26158 *** Descriptor passing won't work.
26159 ***" >&2;}
26160 fi
26161
26162
26163 use_descriptor_passing=yes
26164 # Check whether --enable-fd-passing was given.
26165 if test "${enable_fd_passing+set}" = set; then :
26166 enableval=$enable_fd_passing; use_descriptor_passing=$enableval
26167 fi
26168
26169
26170 if test "$supports_descriptor_passing" != "yes"; then
26171 use_descriptor_passing=no
26172 fi
26173
26174 if test "$use_descriptor_passing" = "yes"; then
26175
26176 $as_echo "#define USE_DESCRIPTOR_PASSING 1" >>confdefs.h
26177
26178 fi
26179
26180 if test "$use_descriptor_passing" = "yes"; then
26181 USE_DESCRIPTOR_PASSING_TRUE=
26182 USE_DESCRIPTOR_PASSING_FALSE='#'
26183 else
26184 USE_DESCRIPTOR_PASSING_TRUE='#'
26185 USE_DESCRIPTOR_PASSING_FALSE=
26186 fi
26187
26188
26189
26190 uiserver=no
26191 if test "$use_descriptor_passing" = "yes" && test "$have_libassuan" = "yes"; then
26192 uiserver=yes
26193 fi
26194 if test "$uiserver" != "no"; then
26195
26196 $as_echo "#define ENABLE_UISERVER 1" >>confdefs.h
26197
26198 fi
26199 if test "$uiserver" != "no"; then
26200 HAVE_UISERVER_TRUE=
26201 HAVE_UISERVER_FALSE='#'
26202 else
26203 HAVE_UISERVER_TRUE='#'
26204 HAVE_UISERVER_FALSE=
26205 fi
26206
26207
26208
26209 # Option --disable-linux-getdents
26210 #
26211 # By default we use SYS_getdents on Linux to optimize fd closing
26212 # before an exec. This option allows to switch this optimization off.
26213 use_linux_getdents=yes
26214 # Check whether --enable-linux-getdents was given.
26215 if test "${enable_linux_getdents+set}" = set; then :
26216 enableval=$enable_linux_getdents; use_linux_getdents=$enableval
26217 fi
26218
26219 if test "$use_linux_getdents" = "yes"; then
26220 case "${host}" in
26221 *-*-linux*)
26222
26223 $as_echo "#define USE_LINUX_GETDENTS 1" >>confdefs.h
26224
26225 ;;
26226 esac
26227 fi
26228
26229
26230 #
26231 # Add a few constants to help porting to W32
26232 #
26233
26234
26235
26236
26237
26238 # Substitution used for gpgme-config
26239 GPGME_CONFIG_LIBS="-lgpgme"
26240 GPGME_CONFIG_CFLAGS=""
26241 GPGME_CONFIG_HOST="$host"
26242 GPGME_CONFIG_AVAIL_LANG="$enabled_languages"
26243
26244
26245
26246
26247
26248
26249 # Frob'da Variables
26250 LTLIBOBJS=`echo "$LIBOBJS" |
26251 sed 's,\.[^.]* ,.lo ,g;s,\.[^.]*$,.lo,'`
26252
26253
26254 # Some checks for gpgme-tool
26255 # Done at top: AC_CHECK_HEADER([argp.h])
26256 ac_fn_c_check_type "$LINENO" "error_t" "ac_cv_type_error_t" "#include <errno.h>
26257 "
26258 if test "x$ac_cv_type_error_t" = xyes; then :
26259
26260 cat >>confdefs.h <<_ACEOF
26261 #define HAVE_ERROR_T 1
26262 _ACEOF
26263
26264
26265 else
26266
26267 $as_echo "#define error_t int" >>confdefs.h
26268
26269 fi
26270
26271
26272
26273 # A substitution to set generated files in a Emacs buffer to read-only.
26274 emacs_local_vars_begin='Local Variables:'
26275
26276 emacs_local_vars_read_only='buffer-read-only: t'
26277
26278 emacs_local_vars_end='End:'
26279
26280
26281 # Last check.
26282 die=no
26283 if test "$have_gpg_error" = "no"; then
26284 die=yes
26285 { $as_echo "$as_me:${as_lineno-$LINENO}:
26286 ***
26287 *** You need libgpg-error to build this program.
26288 ** This library is for example available at
26289 *** https://www.gnupg.org/ftp/gcrypt/libgpg-error/
26290 *** (at least version $NEED_GPG_ERROR_VERSION is required.)
26291 ***" >&5
26292 $as_echo "$as_me:
26293 ***
26294 *** You need libgpg-error to build this program.
26295 ** This library is for example available at
26296 *** https://www.gnupg.org/ftp/gcrypt/libgpg-error/
26297 *** (at least version $NEED_GPG_ERROR_VERSION is required.)
26298 ***" >&6;}
26299 fi
26300 if test "$have_libassuan" = "no"; then
26301 die=yes
26302 { $as_echo "$as_me:${as_lineno-$LINENO}:
26303 ***
26304 *** You need libassuan to build this program.
26305 *** This library is for example available at
26306 *** https://www.gnupg.org/ftp/gcrypt/libassuan/
26307 *** (at least version $NEED_LIBASSUAN_VERSION (API $NEED_LIBASSUAN_API) is required).
26308 ***" >&5
26309 $as_echo "$as_me:
26310 ***
26311 *** You need libassuan to build this program.
26312 *** This library is for example available at
26313 *** https://www.gnupg.org/ftp/gcrypt/libassuan/
26314 *** (at least version $NEED_LIBASSUAN_VERSION (API $NEED_LIBASSUAN_API) is required).
26315 ***" >&6;}
26316 fi
26317
26318 if test "$die" = "yes"; then
26319 as_fn_error $? "
26320 ***
26321 *** Required libraries not found. Please consult the above messages
26322 *** and install them before running configure again.
26323 ***" "$LINENO" 5
26324 fi
26325
26326
26327 #
26328 # Create config files
26329
26330 ac_config_files="$ac_config_files Makefile src/Makefile tests/Makefile tests/gpg/Makefile tests/gpgsm/Makefile tests/opassuan/Makefile tests/json/Makefile doc/Makefile src/versioninfo.rc src/gpgme.pc src/gpgme-glib.pc src/gpgme.h"
26331
26332 ac_config_files="$ac_config_files src/gpgme-config"
26333
26334 ac_config_files="$ac_config_files lang/cpp/Makefile lang/cpp/src/Makefile"
26335
26336 ac_config_files="$ac_config_files lang/cpp/tests/Makefile"
26337
26338 ac_config_files="$ac_config_files lang/cpp/src/GpgmeppConfig-w32.cmake.in"
26339
26340 ac_config_files="$ac_config_files lang/cpp/src/GpgmeppConfig.cmake.in"
26341
26342 ac_config_files="$ac_config_files lang/cpp/src/GpgmeppConfigVersion.cmake"
26343
26344 ac_config_files="$ac_config_files lang/cpp/src/gpgmepp_version.h"
26345
26346 ac_config_files="$ac_config_files lang/qt/Makefile lang/qt/src/Makefile"
26347
26348 ac_config_files="$ac_config_files lang/qt/src/QGpgmeConfig-w32.cmake.in"
26349
26350 ac_config_files="$ac_config_files lang/qt/src/QGpgmeConfig.cmake.in"
26351
26352 ac_config_files="$ac_config_files lang/qt/src/QGpgmeConfigVersion.cmake"
26353
26354 ac_config_files="$ac_config_files lang/qt/tests/Makefile"
26355
26356 ac_config_files="$ac_config_files lang/qt/src/qgpgme_version.h"
26357
26358 ac_config_files="$ac_config_files lang/Makefile lang/cl/Makefile lang/cl/gpgme.asd"
26359
26360 if test -z "$HAVE_DOXYGEN_TRUE"; then :
26361 ac_config_files="$ac_config_files lang/qt/doc/Doxyfile"
26362
26363 fi
26364 ac_config_files="$ac_config_files lang/js/Makefile lang/js/src/Makefile lang/js/BrowserTestExtension/Makefile lang/js/DemoExtension/Makefile"
26365
26366 ac_config_files="$ac_config_files lang/qt/doc/Makefile"
26367
26368 ac_config_files="$ac_config_files lang/python/Makefile lang/python/version.py lang/python/tests/Makefile lang/python/src/Makefile lang/python/examples/Makefile lang/python/doc/Makefile"
26369
26370 ac_config_files="$ac_config_files lang/python/setup.py"
26371
26372 cat >confcache <<\_ACEOF
26373 # This file is a shell script that caches the results of configure
26374 # tests run on this system so they can be shared between configure
26375 # scripts and configure runs, see configure's option --config-cache.
26376 # It is not useful on other systems. If it contains results you don't
26377 # want to keep, you may remove or edit it.
26378 #
26379 # config.status only pays attention to the cache file if you give it
26380 # the --recheck option to rerun configure.
26381 #
26382 # `ac_cv_env_foo' variables (set or unset) will be overridden when
26383 # loading this file, other *unset* `ac_cv_foo' will be assigned the
26384 # following values.
26385
26386 _ACEOF
26387
26388 # The following way of writing the cache mishandles newlines in values,
26389 # but we know of no workaround that is simple, portable, and efficient.
26390 # So, we kill variables containing newlines.
26391 # Ultrix sh set writes to stderr and can't be redirected directly,
26392 # and sets the high bit in the cache file unless we assign to the vars.
26393 (
26394 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
26395 eval ac_val=\$$ac_var
26396 case $ac_val in #(
26397 *${as_nl}*)
26398 case $ac_var in #(
26399 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
26400 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
26401 esac
26402 case $ac_var in #(
26403 _ | IFS | as_nl) ;; #(
26404 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
26405 *) { eval $ac_var=; unset $ac_var;} ;;
26406 esac ;;
26407 esac
26408 done
26409
26410 (set) 2>&1 |
26411 case $as_nl`(ac_space=' '; set) 2>&1` in #(
26412 *${as_nl}ac_space=\ *)
26413 # `set' does not quote correctly, so add quotes: double-quote
26414 # substitution turns \\\\ into \\, and sed turns \\ into \.
26415 sed -n \
26416 "s/'/'\\\\''/g;
26417 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
26418 ;; #(
26419 *)
26420 # `set' quotes correctly as required by POSIX, so do not add quotes.
26421 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
26422 ;;
26423 esac |
26424 sort
26425 ) |
26426 sed '
26427 /^ac_cv_env_/b end
26428 t clear
26429 :clear
26430 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
26431 t end
26432 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
26433 :end' >>confcache
26434 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
26435 if test -w "$cache_file"; then
26436 if test "x$cache_file" != "x/dev/null"; then
26437 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
26438 $as_echo "$as_me: updating cache $cache_file" >&6;}
26439 if test ! -f "$cache_file" || test -h "$cache_file"; then
26440 cat confcache >"$cache_file"
26441 else
26442 case $cache_file in #(
26443 */* | ?:*)
26444 mv -f confcache "$cache_file"$$ &&
26445 mv -f "$cache_file"$$ "$cache_file" ;; #(
26446 *)
26447 mv -f confcache "$cache_file" ;;
26448 esac
26449 fi
26450 fi
26451 else
26452 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
26453 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
26454 fi
26455 fi
26456 rm -f confcache
26457
26458 test "x$prefix" = xNONE && prefix=$ac_default_prefix
26459 # Let make expand exec_prefix.
26460 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
26461
26462 DEFS=-DHAVE_CONFIG_H
26463
26464 ac_libobjs=
26465 ac_ltlibobjs=
26466 U=
26467 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
26468 # 1. Remove the extension, and $U if already installed.
26469 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
26470 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
26471 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
26472 # will be set to the directory where LIBOBJS objects are built.
26473 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
26474 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
26475 done
26476 LIBOBJS=$ac_libobjs
26477
26478 LTLIBOBJS=$ac_ltlibobjs
26479
26480
26481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
26482 $as_echo_n "checking that generated files are newer than configure... " >&6; }
26483 if test -n "$am_sleep_pid"; then
26484 # Hide warnings about reused PIDs.
26485 wait $am_sleep_pid 2>/dev/null
26486 fi
26487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
26488 $as_echo "done" >&6; }
26489 if test -n "$EXEEXT"; then
26490 am__EXEEXT_TRUE=
26491 am__EXEEXT_FALSE='#'
26492 else
26493 am__EXEEXT_TRUE='#'
26494 am__EXEEXT_FALSE=
26495 fi
26496
26497 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
26498 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
26499 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26500 fi
26501 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
26502 as_fn_error $? "conditional \"AMDEP\" was never defined.
26503 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26504 fi
26505 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
26506 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
26507 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26508 fi
26509 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
26510 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
26511 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26512 fi
26513 if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
26514 as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
26515 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26516 fi
26517 if test -z "${HAVE_LD_VERSION_SCRIPT_TRUE}" && test -z "${HAVE_LD_VERSION_SCRIPT_FALSE}"; then
26518 as_fn_error $? "conditional \"HAVE_LD_VERSION_SCRIPT\" was never defined.
26519 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26520 fi
26521 if test -z "${HAVE_DOSISH_SYSTEM_TRUE}" && test -z "${HAVE_DOSISH_SYSTEM_FALSE}"; then
26522 as_fn_error $? "conditional \"HAVE_DOSISH_SYSTEM\" was never defined.
26523 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26524 fi
26525 if test -z "${HAVE_W32_SYSTEM_TRUE}" && test -z "${HAVE_W32_SYSTEM_FALSE}"; then
26526 as_fn_error $? "conditional \"HAVE_W32_SYSTEM\" was never defined.
26527 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26528 fi
26529 if test -z "${HAVE_W64_SYSTEM_TRUE}" && test -z "${HAVE_W64_SYSTEM_FALSE}"; then
26530 as_fn_error $? "conditional \"HAVE_W64_SYSTEM\" was never defined.
26531 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26532 fi
26533 if test -z "${HAVE_ANDROID_SYSTEM_TRUE}" && test -z "${HAVE_ANDROID_SYSTEM_FALSE}"; then
26534 as_fn_error $? "conditional \"HAVE_ANDROID_SYSTEM\" was never defined.
26535 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26536 fi
26537 if test -z "${HAVE_MACOS_SYSTEM_TRUE}" && test -z "${HAVE_MACOS_SYSTEM_FALSE}"; then
26538 as_fn_error $? "conditional \"HAVE_MACOS_SYSTEM\" was never defined.
26539 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26540 fi
26541 if test -z "${BUILD_W32_GLIB_TRUE}" && test -z "${BUILD_W32_GLIB_FALSE}"; then
26542 as_fn_error $? "conditional \"BUILD_W32_GLIB\" was never defined.
26543 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26544 fi
26545 if test -z "${HAVE_DOXYGEN_TRUE}" && test -z "${HAVE_DOXYGEN_FALSE}"; then
26546 as_fn_error $? "conditional \"HAVE_DOXYGEN\" was never defined.
26547 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26548 fi
26549 if test -z "${RUN_GPGCONF_TESTS_TRUE}" && test -z "${RUN_GPGCONF_TESTS_FALSE}"; then
26550 as_fn_error $? "conditional \"RUN_GPGCONF_TESTS\" was never defined.
26551 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26552 fi
26553 if test -z "${RUN_GPG_TESTS_TRUE}" && test -z "${RUN_GPG_TESTS_FALSE}"; then
26554 as_fn_error $? "conditional \"RUN_GPG_TESTS\" was never defined.
26555 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26556 fi
26557 if test -z "${RUN_GPGSM_TESTS_TRUE}" && test -z "${RUN_GPGSM_TESTS_FALSE}"; then
26558 as_fn_error $? "conditional \"RUN_GPGSM_TESTS\" was never defined.
26559 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26560 fi
26561 if test -z "${RUN_G13_TESTS_TRUE}" && test -z "${RUN_G13_TESTS_FALSE}"; then
26562 as_fn_error $? "conditional \"RUN_G13_TESTS\" was never defined.
26563 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26564 fi
26565 if test -z "${USE_DESCRIPTOR_PASSING_TRUE}" && test -z "${USE_DESCRIPTOR_PASSING_FALSE}"; then
26566 as_fn_error $? "conditional \"USE_DESCRIPTOR_PASSING\" was never defined.
26567 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26568 fi
26569 if test -z "${HAVE_UISERVER_TRUE}" && test -z "${HAVE_UISERVER_FALSE}"; then
26570 as_fn_error $? "conditional \"HAVE_UISERVER\" was never defined.
26571 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26572 fi
26573
26574 : "${CONFIG_STATUS=./config.status}"
26575 ac_write_fail=0
26576 ac_clean_files_save=$ac_clean_files
26577 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
26578 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
26579 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
26580 as_write_fail=0
26581 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
26582 #! $SHELL
26583 # Generated by $as_me.
26584 # Run this file to recreate the current configuration.
26585 # Compiler output produced by configure, useful for debugging
26586 # configure, is in config.log if it exists.
26587
26588 debug=false
26589 ac_cs_recheck=false
26590 ac_cs_silent=false
26591
26592 SHELL=\${CONFIG_SHELL-$SHELL}
26593 export SHELL
26594 _ASEOF
26595 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
26596 ## -------------------- ##
26597 ## M4sh Initialization. ##
26598 ## -------------------- ##
26599
26600 # Be more Bourne compatible
26601 DUALCASE=1; export DUALCASE # for MKS sh
26602 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
26603 emulate sh
26604 NULLCMD=:
26605 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26606 # is contrary to our usage. Disable this feature.
26607 alias -g '${1+"$@"}'='"$@"'
26608 setopt NO_GLOB_SUBST
26609 else
26610 case `(set -o) 2>/dev/null` in #(
26611 *posix*) :
26612 set -o posix ;; #(
26613 *) :
26614 ;;
26615 esac
26616 fi
26617
26618
26619 as_nl='
26620 '
26621 export as_nl
26622 # Printing a long string crashes Solaris 7 /usr/bin/printf.
26623 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
26624 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
26625 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
26626 # Prefer a ksh shell builtin over an external printf program on Solaris,
26627 # but without wasting forks for bash or zsh.
26628 if test -z "$BASH_VERSION$ZSH_VERSION" \
26629 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
26630 as_echo='print -r --'
26631 as_echo_n='print -rn --'
26632 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
26633 as_echo='printf %s\n'
26634 as_echo_n='printf %s'
26635 else
26636 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
26637 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
26638 as_echo_n='/usr/ucb/echo -n'
26639 else
26640 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
26641 as_echo_n_body='eval
26642 arg=$1;
26643 case $arg in #(
26644 *"$as_nl"*)
26645 expr "X$arg" : "X\\(.*\\)$as_nl";
26646 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
26647 esac;
26648 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
26649 '
26650 export as_echo_n_body
26651 as_echo_n='sh -c $as_echo_n_body as_echo'
26652 fi
26653 export as_echo_body
26654 as_echo='sh -c $as_echo_body as_echo'
26655 fi
26656
26657 # The user is always right.
26658 if test "${PATH_SEPARATOR+set}" != set; then
26659 PATH_SEPARATOR=:
26660 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
26661 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
26662 PATH_SEPARATOR=';'
26663 }
26664 fi
26665
26666
26667 # IFS
26668 # We need space, tab and new line, in precisely that order. Quoting is
26669 # there to prevent editors from complaining about space-tab.
26670 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
26671 # splitting by setting IFS to empty value.)
26672 IFS=" "" $as_nl"
26673
26674 # Find who we are. Look in the path if we contain no directory separator.
26675 as_myself=
26676 case $0 in #((
26677 *[\\/]* ) as_myself=$0 ;;
26678 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26679 for as_dir in $PATH
26680 do
26681 IFS=$as_save_IFS
26682 test -z "$as_dir" && as_dir=.
26683 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26684 done
26685 IFS=$as_save_IFS
26686
26687 ;;
26688 esac
26689 # We did not find ourselves, most probably we were run as `sh COMMAND'
26690 # in which case we are not to be found in the path.
26691 if test "x$as_myself" = x; then
26692 as_myself=$0
26693 fi
26694 if test ! -f "$as_myself"; then
26695 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
26696 exit 1
26697 fi
26698
26699 # Unset variables that we do not need and which cause bugs (e.g. in
26700 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
26701 # suppresses any "Segmentation fault" message there. '((' could
26702 # trigger a bug in pdksh 5.2.14.
26703 for as_var in BASH_ENV ENV MAIL MAILPATH
26704 do eval test x\${$as_var+set} = xset \
26705 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
26706 done
26707 PS1='$ '
26708 PS2='> '
26709 PS4='+ '
26710
26711 # NLS nuisances.
26712 LC_ALL=C
26713 export LC_ALL
26714 LANGUAGE=C
26715 export LANGUAGE
26716
26717 # CDPATH.
26718 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
26719
26720
26721 # as_fn_error STATUS ERROR [LINENO LOG_FD]
26722 # ----------------------------------------
26723 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
26724 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
26725 # script with STATUS, using 1 if that was 0.
26726 as_fn_error ()
26727 {
26728 as_status=$1; test $as_status -eq 0 && as_status=1
26729 if test "$4"; then
26730 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
26731 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
26732 fi
26733 $as_echo "$as_me: error: $2" >&2
26734 as_fn_exit $as_status
26735 } # as_fn_error
26736
26737
26738 # as_fn_set_status STATUS
26739 # -----------------------
26740 # Set $? to STATUS, without forking.
26741 as_fn_set_status ()
26742 {
26743 return $1
26744 } # as_fn_set_status
26745
26746 # as_fn_exit STATUS
26747 # -----------------
26748 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
26749 as_fn_exit ()
26750 {
26751 set +e
26752 as_fn_set_status $1
26753 exit $1
26754 } # as_fn_exit
26755
26756 # as_fn_unset VAR
26757 # ---------------
26758 # Portably unset VAR.
26759 as_fn_unset ()
26760 {
26761 { eval $1=; unset $1;}
26762 }
26763 as_unset=as_fn_unset
26764 # as_fn_append VAR VALUE
26765 # ----------------------
26766 # Append the text in VALUE to the end of the definition contained in VAR. Take
26767 # advantage of any shell optimizations that allow amortized linear growth over
26768 # repeated appends, instead of the typical quadratic growth present in naive
26769 # implementations.
26770 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
26771 eval 'as_fn_append ()
26772 {
26773 eval $1+=\$2
26774 }'
26775 else
26776 as_fn_append ()
26777 {
26778 eval $1=\$$1\$2
26779 }
26780 fi # as_fn_append
26781
26782 # as_fn_arith ARG...
26783 # ------------------
26784 # Perform arithmetic evaluation on the ARGs, and store the result in the
26785 # global $as_val. Take advantage of shells that can avoid forks. The arguments
26786 # must be portable across $(()) and expr.
26787 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
26788 eval 'as_fn_arith ()
26789 {
26790 as_val=$(( $* ))
26791 }'
26792 else
26793 as_fn_arith ()
26794 {
26795 as_val=`expr "$@" || test $? -eq 1`
26796 }
26797 fi # as_fn_arith
26798
26799
26800 if expr a : '\(a\)' >/dev/null 2>&1 &&
26801 test "X`expr 00001 : '.*\(...\)'`" = X001; then
26802 as_expr=expr
26803 else
26804 as_expr=false
26805 fi
26806
26807 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26808 as_basename=basename
26809 else
26810 as_basename=false
26811 fi
26812
26813 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26814 as_dirname=dirname
26815 else
26816 as_dirname=false
26817 fi
26818
26819 as_me=`$as_basename -- "$0" ||
26820 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26821 X"$0" : 'X\(//\)$' \| \
26822 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
26823 $as_echo X/"$0" |
26824 sed '/^.*\/\([^/][^/]*\)\/*$/{
26825 s//\1/
26826 q
26827 }
26828 /^X\/\(\/\/\)$/{
26829 s//\1/
26830 q
26831 }
26832 /^X\/\(\/\).*/{
26833 s//\1/
26834 q
26835 }
26836 s/.*/./; q'`
26837
26838 # Avoid depending upon Character Ranges.
26839 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
26840 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
26841 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
26842 as_cr_digits='0123456789'
26843 as_cr_alnum=$as_cr_Letters$as_cr_digits
26844
26845 ECHO_C= ECHO_N= ECHO_T=
26846 case `echo -n x` in #(((((
26847 -n*)
26848 case `echo 'xy\c'` in
26849 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
26850 xy) ECHO_C='\c';;
26851 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
26852 ECHO_T=' ';;
26853 esac;;
26854 *)
26855 ECHO_N='-n';;
26856 esac
26857
26858 rm -f conf$$ conf$$.exe conf$$.file
26859 if test -d conf$$.dir; then
26860 rm -f conf$$.dir/conf$$.file
26861 else
26862 rm -f conf$$.dir
26863 mkdir conf$$.dir 2>/dev/null
26864 fi
26865 if (echo >conf$$.file) 2>/dev/null; then
26866 if ln -s conf$$.file conf$$ 2>/dev/null; then
26867 as_ln_s='ln -s'
26868 # ... but there are two gotchas:
26869 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26870 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26871 # In both cases, we have to default to `cp -pR'.
26872 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26873 as_ln_s='cp -pR'
26874 elif ln conf$$.file conf$$ 2>/dev/null; then
26875 as_ln_s=ln
26876 else
26877 as_ln_s='cp -pR'
26878 fi
26879 else
26880 as_ln_s='cp -pR'
26881 fi
26882 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26883 rmdir conf$$.dir 2>/dev/null
26884
26885
26886 # as_fn_mkdir_p
26887 # -------------
26888 # Create "$as_dir" as a directory, including parents if necessary.
26889 as_fn_mkdir_p ()
26890 {
26891
26892 case $as_dir in #(
26893 -*) as_dir=./$as_dir;;
26894 esac
26895 test -d "$as_dir" || eval $as_mkdir_p || {
26896 as_dirs=
26897 while :; do
26898 case $as_dir in #(
26899 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
26900 *) as_qdir=$as_dir;;
26901 esac
26902 as_dirs="'$as_qdir' $as_dirs"
26903 as_dir=`$as_dirname -- "$as_dir" ||
26904 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26905 X"$as_dir" : 'X\(//\)[^/]' \| \
26906 X"$as_dir" : 'X\(//\)$' \| \
26907 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
26908 $as_echo X"$as_dir" |
26909 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26910 s//\1/
26911 q
26912 }
26913 /^X\(\/\/\)[^/].*/{
26914 s//\1/
26915 q
26916 }
26917 /^X\(\/\/\)$/{
26918 s//\1/
26919 q
26920 }
26921 /^X\(\/\).*/{
26922 s//\1/
26923 q
26924 }
26925 s/.*/./; q'`
26926 test -d "$as_dir" && break
26927 done
26928 test -z "$as_dirs" || eval "mkdir $as_dirs"
26929 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
26930
26931
26932 } # as_fn_mkdir_p
26933 if mkdir -p . 2>/dev/null; then
26934 as_mkdir_p='mkdir -p "$as_dir"'
26935 else
26936 test -d ./-p && rmdir ./-p
26937 as_mkdir_p=false
26938 fi
26939
26940
26941 # as_fn_executable_p FILE
26942 # -----------------------
26943 # Test if FILE is an executable regular file.
26944 as_fn_executable_p ()
26945 {
26946 test -f "$1" && test -x "$1"
26947 } # as_fn_executable_p
26948 as_test_x='test -x'
26949 as_executable_p=as_fn_executable_p
26950
26951 # Sed expression to map a string onto a valid CPP name.
26952 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
26953
26954 # Sed expression to map a string onto a valid variable name.
26955 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
26956
26957
26958 exec 6>&1
26959 ## ----------------------------------- ##
26960 ## Main body of $CONFIG_STATUS script. ##
26961 ## ----------------------------------- ##
26962 _ASEOF
26963 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
26964
26965 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26966 # Save the log message, to keep $0 and so on meaningful, and to
26967 # report actual input values of CONFIG_FILES etc. instead of their
26968 # values after options handling.
26969 ac_log="
26970 This file was extended by gpgme $as_me 1.17.0, which was
26971 generated by GNU Autoconf 2.69. Invocation command line was
26972
26973 CONFIG_FILES = $CONFIG_FILES
26974 CONFIG_HEADERS = $CONFIG_HEADERS
26975 CONFIG_LINKS = $CONFIG_LINKS
26976 CONFIG_COMMANDS = $CONFIG_COMMANDS
26977 $ $0 $@
26978
26979 on `(hostname || uname -n) 2>/dev/null | sed 1q`
26980 "
26981
26982 _ACEOF
26983
26984 case $ac_config_files in *"
26985 "*) set x $ac_config_files; shift; ac_config_files=$*;;
26986 esac
26987
26988 case $ac_config_headers in *"
26989 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
26990 esac
26991
26992
26993 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26994 # Files that config.status was made for.
26995 config_files="$ac_config_files"
26996 config_headers="$ac_config_headers"
26997 config_commands="$ac_config_commands"
26998
26999 _ACEOF
27000
27001 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27002 ac_cs_usage="\
27003 \`$as_me' instantiates files and other configuration actions
27004 from templates according to the current configuration. Unless the files
27005 and actions are specified as TAGs, all are instantiated by default.
27006
27007 Usage: $0 [OPTION]... [TAG]...
27008
27009 -h, --help print this help, then exit
27010 -V, --version print version number and configuration settings, then exit
27011 --config print configuration, then exit
27012 -q, --quiet, --silent
27013 do not print progress messages
27014 -d, --debug don't remove temporary files
27015 --recheck update $as_me by reconfiguring in the same conditions
27016 --file=FILE[:TEMPLATE]
27017 instantiate the configuration file FILE
27018 --header=FILE[:TEMPLATE]
27019 instantiate the configuration header FILE
27020
27021 Configuration files:
27022 $config_files
27023
27024 Configuration headers:
27025 $config_headers
27026
27027 Configuration commands:
27028 $config_commands
27029
27030 Report bugs to <https://bugs.gnupg.org>."
27031
27032 _ACEOF
27033 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27034 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
27035 ac_cs_version="\\
27036 gpgme config.status 1.17.0
27037 configured by $0, generated by GNU Autoconf 2.69,
27038 with options \\"\$ac_cs_config\\"
27039
27040 Copyright (C) 2012 Free Software Foundation, Inc.
27041 This config.status script is free software; the Free Software Foundation
27042 gives unlimited permission to copy, distribute and modify it."
27043
27044 ac_pwd='$ac_pwd'
27045 srcdir='$srcdir'
27046 INSTALL='$INSTALL'
27047 MKDIR_P='$MKDIR_P'
27048 AWK='$AWK'
27049 test -n "\$AWK" || AWK=awk
27050 _ACEOF
27051
27052 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27053 # The default lists apply if the user does not specify any file.
27054 ac_need_defaults=:
27055 while test $# != 0
27056 do
27057 case $1 in
27058 --*=?*)
27059 ac_option=`expr "X$1" : 'X\([^=]*\)='`
27060 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
27061 ac_shift=:
27062 ;;
27063 --*=)
27064 ac_option=`expr "X$1" : 'X\([^=]*\)='`
27065 ac_optarg=
27066 ac_shift=:
27067 ;;
27068 *)
27069 ac_option=$1
27070 ac_optarg=$2
27071 ac_shift=shift
27072 ;;
27073 esac
27074
27075 case $ac_option in
27076 # Handling of the options.
27077 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
27078 ac_cs_recheck=: ;;
27079 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
27080 $as_echo "$ac_cs_version"; exit ;;
27081 --config | --confi | --conf | --con | --co | --c )
27082 $as_echo "$ac_cs_config"; exit ;;
27083 --debug | --debu | --deb | --de | --d | -d )
27084 debug=: ;;
27085 --file | --fil | --fi | --f )
27086 $ac_shift
27087 case $ac_optarg in
27088 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
27089 '') as_fn_error $? "missing file argument" ;;
27090 esac
27091 as_fn_append CONFIG_FILES " '$ac_optarg'"
27092 ac_need_defaults=false;;
27093 --header | --heade | --head | --hea )
27094 $ac_shift
27095 case $ac_optarg in
27096 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
27097 esac
27098 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
27099 ac_need_defaults=false;;
27100 --he | --h)
27101 # Conflict between --help and --header
27102 as_fn_error $? "ambiguous option: \`$1'
27103 Try \`$0 --help' for more information.";;
27104 --help | --hel | -h )
27105 $as_echo "$ac_cs_usage"; exit ;;
27106 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
27107 | -silent | --silent | --silen | --sile | --sil | --si | --s)
27108 ac_cs_silent=: ;;
27109
27110 # This is an error.
27111 -*) as_fn_error $? "unrecognized option: \`$1'
27112 Try \`$0 --help' for more information." ;;
27113
27114 *) as_fn_append ac_config_targets " $1"
27115 ac_need_defaults=false ;;
27116
27117 esac
27118 shift
27119 done
27120
27121 ac_configure_extra_args=
27122
27123 if $ac_cs_silent; then
27124 exec 6>/dev/null
27125 ac_configure_extra_args="$ac_configure_extra_args --silent"
27126 fi
27127
27128 _ACEOF
27129 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27130 if \$ac_cs_recheck; then
27131 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
27132 shift
27133 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
27134 CONFIG_SHELL='$SHELL'
27135 export CONFIG_SHELL
27136 exec "\$@"
27137 fi
27138
27139 _ACEOF
27140 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27141 exec 5>>config.log
27142 {
27143 echo
27144 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
27145 ## Running $as_me. ##
27146 _ASBOX
27147 $as_echo "$ac_log"
27148 } >&5
27149
27150 _ACEOF
27151 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27152 #
27153 # INIT-COMMANDS
27154 #
27155 AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"
27156
27157
27158 # The HP-UX ksh and POSIX shell print the target directory to stdout
27159 # if CDPATH is set.
27160 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
27161
27162 sed_quote_subst='$sed_quote_subst'
27163 double_quote_subst='$double_quote_subst'
27164 delay_variable_subst='$delay_variable_subst'
27165 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
27166 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
27167 AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`'
27168 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
27169 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
27170 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
27171 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
27172 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
27173 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
27174 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
27175 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
27176 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
27177 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
27178 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
27179 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
27180 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
27181 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
27182 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
27183 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
27184 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
27185 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
27186 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
27187 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
27188 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
27189 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
27190 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
27191 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
27192 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
27193 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
27194 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
27195 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
27196 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
27197 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
27198 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
27199 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
27200 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
27201 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
27202 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
27203 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
27204 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
27205 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
27206 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
27207 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
27208 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
27209 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
27210 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
27211 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
27212 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
27213 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
27214 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
27215 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
27216 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
27217 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
27218 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
27219 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
27220 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
27221 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
27222 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
27223 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
27224 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
27225 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
27226 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
27227 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
27228 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
27229 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
27230 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
27231 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
27232 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
27233 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
27234 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
27235 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
27236 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
27237 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
27238 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
27239 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
27240 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
27241 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
27242 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
27243 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
27244 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
27245 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
27246 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
27247 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
27248 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
27249 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
27250 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
27251 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
27252 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
27253 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
27254 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
27255 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
27256 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
27257 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
27258 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
27259 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
27260 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
27261 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
27262 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
27263 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
27264 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
27265 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
27266 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
27267 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
27268 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
27269 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
27270 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
27271 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
27272 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
27273 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
27274 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
27275 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
27276 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
27277 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
27278 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
27279 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
27280 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
27281 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
27282 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
27283 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
27284 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
27285 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
27286 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
27287 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
27288 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
27289 sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
27290 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
27291 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
27292 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
27293 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
27294 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
27295 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
27296 compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
27297 predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
27298 postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
27299 predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
27300 postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
27301 compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
27302 LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`'
27303 LD_RC='`$ECHO "$LD_RC" | $SED "$delay_single_quote_subst"`'
27304 reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`'
27305 reload_flag_RC='`$ECHO "$reload_flag_RC" | $SED "$delay_single_quote_subst"`'
27306 reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27307 reload_cmds_RC='`$ECHO "$reload_cmds_RC" | $SED "$delay_single_quote_subst"`'
27308 old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27309 old_archive_cmds_RC='`$ECHO "$old_archive_cmds_RC" | $SED "$delay_single_quote_subst"`'
27310 compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
27311 compiler_RC='`$ECHO "$compiler_RC" | $SED "$delay_single_quote_subst"`'
27312 GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
27313 GCC_RC='`$ECHO "$GCC_RC" | $SED "$delay_single_quote_subst"`'
27314 lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
27315 lt_prog_compiler_no_builtin_flag_RC='`$ECHO "$lt_prog_compiler_no_builtin_flag_RC" | $SED "$delay_single_quote_subst"`'
27316 lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`'
27317 lt_prog_compiler_pic_RC='`$ECHO "$lt_prog_compiler_pic_RC" | $SED "$delay_single_quote_subst"`'
27318 lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`'
27319 lt_prog_compiler_wl_RC='`$ECHO "$lt_prog_compiler_wl_RC" | $SED "$delay_single_quote_subst"`'
27320 lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
27321 lt_prog_compiler_static_RC='`$ECHO "$lt_prog_compiler_static_RC" | $SED "$delay_single_quote_subst"`'
27322 lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
27323 lt_cv_prog_compiler_c_o_RC='`$ECHO "$lt_cv_prog_compiler_c_o_RC" | $SED "$delay_single_quote_subst"`'
27324 archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
27325 archive_cmds_need_lc_RC='`$ECHO "$archive_cmds_need_lc_RC" | $SED "$delay_single_quote_subst"`'
27326 enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`'
27327 enable_shared_with_static_runtimes_RC='`$ECHO "$enable_shared_with_static_runtimes_RC" | $SED "$delay_single_quote_subst"`'
27328 export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
27329 export_dynamic_flag_spec_RC='`$ECHO "$export_dynamic_flag_spec_RC" | $SED "$delay_single_quote_subst"`'
27330 whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
27331 whole_archive_flag_spec_RC='`$ECHO "$whole_archive_flag_spec_RC" | $SED "$delay_single_quote_subst"`'
27332 compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`'
27333 compiler_needs_object_RC='`$ECHO "$compiler_needs_object_RC" | $SED "$delay_single_quote_subst"`'
27334 old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27335 old_archive_from_new_cmds_RC='`$ECHO "$old_archive_from_new_cmds_RC" | $SED "$delay_single_quote_subst"`'
27336 old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27337 old_archive_from_expsyms_cmds_RC='`$ECHO "$old_archive_from_expsyms_cmds_RC" | $SED "$delay_single_quote_subst"`'
27338 archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27339 archive_cmds_RC='`$ECHO "$archive_cmds_RC" | $SED "$delay_single_quote_subst"`'
27340 archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27341 archive_expsym_cmds_RC='`$ECHO "$archive_expsym_cmds_RC" | $SED "$delay_single_quote_subst"`'
27342 module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27343 module_cmds_RC='`$ECHO "$module_cmds_RC" | $SED "$delay_single_quote_subst"`'
27344 module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27345 module_expsym_cmds_RC='`$ECHO "$module_expsym_cmds_RC" | $SED "$delay_single_quote_subst"`'
27346 with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`'
27347 with_gnu_ld_RC='`$ECHO "$with_gnu_ld_RC" | $SED "$delay_single_quote_subst"`'
27348 allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
27349 allow_undefined_flag_RC='`$ECHO "$allow_undefined_flag_RC" | $SED "$delay_single_quote_subst"`'
27350 no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
27351 no_undefined_flag_RC='`$ECHO "$no_undefined_flag_RC" | $SED "$delay_single_quote_subst"`'
27352 hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
27353 hardcode_libdir_flag_spec_RC='`$ECHO "$hardcode_libdir_flag_spec_RC" | $SED "$delay_single_quote_subst"`'
27354 hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
27355 hardcode_libdir_separator_RC='`$ECHO "$hardcode_libdir_separator_RC" | $SED "$delay_single_quote_subst"`'
27356 hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
27357 hardcode_direct_RC='`$ECHO "$hardcode_direct_RC" | $SED "$delay_single_quote_subst"`'
27358 hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
27359 hardcode_direct_absolute_RC='`$ECHO "$hardcode_direct_absolute_RC" | $SED "$delay_single_quote_subst"`'
27360 hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`'
27361 hardcode_minus_L_RC='`$ECHO "$hardcode_minus_L_RC" | $SED "$delay_single_quote_subst"`'
27362 hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`'
27363 hardcode_shlibpath_var_RC='`$ECHO "$hardcode_shlibpath_var_RC" | $SED "$delay_single_quote_subst"`'
27364 hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
27365 hardcode_automatic_RC='`$ECHO "$hardcode_automatic_RC" | $SED "$delay_single_quote_subst"`'
27366 inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
27367 inherit_rpath_RC='`$ECHO "$inherit_rpath_RC" | $SED "$delay_single_quote_subst"`'
27368 link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
27369 link_all_deplibs_RC='`$ECHO "$link_all_deplibs_RC" | $SED "$delay_single_quote_subst"`'
27370 always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`'
27371 always_export_symbols_RC='`$ECHO "$always_export_symbols_RC" | $SED "$delay_single_quote_subst"`'
27372 export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27373 export_symbols_cmds_RC='`$ECHO "$export_symbols_cmds_RC" | $SED "$delay_single_quote_subst"`'
27374 exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
27375 exclude_expsyms_RC='`$ECHO "$exclude_expsyms_RC" | $SED "$delay_single_quote_subst"`'
27376 include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
27377 include_expsyms_RC='`$ECHO "$include_expsyms_RC" | $SED "$delay_single_quote_subst"`'
27378 prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27379 prelink_cmds_RC='`$ECHO "$prelink_cmds_RC" | $SED "$delay_single_quote_subst"`'
27380 postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
27381 postlink_cmds_RC='`$ECHO "$postlink_cmds_RC" | $SED "$delay_single_quote_subst"`'
27382 file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
27383 file_list_spec_RC='`$ECHO "$file_list_spec_RC" | $SED "$delay_single_quote_subst"`'
27384 hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
27385 hardcode_action_RC='`$ECHO "$hardcode_action_RC" | $SED "$delay_single_quote_subst"`'
27386 compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
27387 compiler_lib_search_dirs_RC='`$ECHO "$compiler_lib_search_dirs_RC" | $SED "$delay_single_quote_subst"`'
27388 predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`'
27389 predep_objects_RC='`$ECHO "$predep_objects_RC" | $SED "$delay_single_quote_subst"`'
27390 postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`'
27391 postdep_objects_RC='`$ECHO "$postdep_objects_RC" | $SED "$delay_single_quote_subst"`'
27392 predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`'
27393 predeps_RC='`$ECHO "$predeps_RC" | $SED "$delay_single_quote_subst"`'
27394 postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`'
27395 postdeps_RC='`$ECHO "$postdeps_RC" | $SED "$delay_single_quote_subst"`'
27396 compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`'
27397 compiler_lib_search_path_RC='`$ECHO "$compiler_lib_search_path_RC" | $SED "$delay_single_quote_subst"`'
27398
27399 LTCC='$LTCC'
27400 LTCFLAGS='$LTCFLAGS'
27401 compiler='$compiler_DEFAULT'
27402
27403 # A function that is used when there is no print builtin or printf.
27404 func_fallback_echo ()
27405 {
27406 eval 'cat <<_LTECHO_EOF
27407 \$1
27408 _LTECHO_EOF'
27409 }
27410
27411 # Quote evaled strings.
27412 for var in AS \
27413 DLLTOOL \
27414 OBJDUMP \
27415 SHELL \
27416 ECHO \
27417 PATH_SEPARATOR \
27418 SED \
27419 GREP \
27420 EGREP \
27421 FGREP \
27422 LD \
27423 NM \
27424 LN_S \
27425 lt_SP2NL \
27426 lt_NL2SP \
27427 reload_flag \
27428 deplibs_check_method \
27429 file_magic_cmd \
27430 file_magic_glob \
27431 want_nocaseglob \
27432 sharedlib_from_linklib_cmd \
27433 AR \
27434 AR_FLAGS \
27435 archiver_list_spec \
27436 STRIP \
27437 RANLIB \
27438 CC \
27439 CFLAGS \
27440 compiler \
27441 lt_cv_sys_global_symbol_pipe \
27442 lt_cv_sys_global_symbol_to_cdecl \
27443 lt_cv_sys_global_symbol_to_c_name_address \
27444 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
27445 nm_file_list_spec \
27446 lt_prog_compiler_no_builtin_flag \
27447 lt_prog_compiler_pic \
27448 lt_prog_compiler_wl \
27449 lt_prog_compiler_static \
27450 lt_cv_prog_compiler_c_o \
27451 need_locks \
27452 MANIFEST_TOOL \
27453 DSYMUTIL \
27454 NMEDIT \
27455 LIPO \
27456 OTOOL \
27457 OTOOL64 \
27458 shrext_cmds \
27459 export_dynamic_flag_spec \
27460 whole_archive_flag_spec \
27461 compiler_needs_object \
27462 with_gnu_ld \
27463 allow_undefined_flag \
27464 no_undefined_flag \
27465 hardcode_libdir_flag_spec \
27466 hardcode_libdir_separator \
27467 exclude_expsyms \
27468 include_expsyms \
27469 file_list_spec \
27470 variables_saved_for_relink \
27471 libname_spec \
27472 library_names_spec \
27473 soname_spec \
27474 install_override_mode \
27475 finish_eval \
27476 old_striplib \
27477 striplib \
27478 compiler_lib_search_dirs \
27479 predep_objects \
27480 postdep_objects \
27481 predeps \
27482 postdeps \
27483 compiler_lib_search_path \
27484 LD_CXX \
27485 LD_RC \
27486 reload_flag_CXX \
27487 reload_flag_RC \
27488 compiler_CXX \
27489 compiler_RC \
27490 lt_prog_compiler_no_builtin_flag_CXX \
27491 lt_prog_compiler_no_builtin_flag_RC \
27492 lt_prog_compiler_pic_CXX \
27493 lt_prog_compiler_pic_RC \
27494 lt_prog_compiler_wl_CXX \
27495 lt_prog_compiler_wl_RC \
27496 lt_prog_compiler_static_CXX \
27497 lt_prog_compiler_static_RC \
27498 lt_cv_prog_compiler_c_o_CXX \
27499 lt_cv_prog_compiler_c_o_RC \
27500 export_dynamic_flag_spec_CXX \
27501 export_dynamic_flag_spec_RC \
27502 whole_archive_flag_spec_CXX \
27503 whole_archive_flag_spec_RC \
27504 compiler_needs_object_CXX \
27505 compiler_needs_object_RC \
27506 with_gnu_ld_CXX \
27507 with_gnu_ld_RC \
27508 allow_undefined_flag_CXX \
27509 allow_undefined_flag_RC \
27510 no_undefined_flag_CXX \
27511 no_undefined_flag_RC \
27512 hardcode_libdir_flag_spec_CXX \
27513 hardcode_libdir_flag_spec_RC \
27514 hardcode_libdir_separator_CXX \
27515 hardcode_libdir_separator_RC \
27516 exclude_expsyms_CXX \
27517 exclude_expsyms_RC \
27518 include_expsyms_CXX \
27519 include_expsyms_RC \
27520 file_list_spec_CXX \
27521 file_list_spec_RC \
27522 compiler_lib_search_dirs_CXX \
27523 compiler_lib_search_dirs_RC \
27524 predep_objects_CXX \
27525 predep_objects_RC \
27526 postdep_objects_CXX \
27527 postdep_objects_RC \
27528 predeps_CXX \
27529 predeps_RC \
27530 postdeps_CXX \
27531 postdeps_RC \
27532 compiler_lib_search_path_CXX \
27533 compiler_lib_search_path_RC; do
27534 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
27535 *[\\\\\\\`\\"\\\$]*)
27536 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
27537 ;;
27538 *)
27539 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
27540 ;;
27541 esac
27542 done
27543
27544 # Double-quote double-evaled strings.
27545 for var in reload_cmds \
27546 old_postinstall_cmds \
27547 old_postuninstall_cmds \
27548 old_archive_cmds \
27549 extract_expsyms_cmds \
27550 old_archive_from_new_cmds \
27551 old_archive_from_expsyms_cmds \
27552 archive_cmds \
27553 archive_expsym_cmds \
27554 module_cmds \
27555 module_expsym_cmds \
27556 export_symbols_cmds \
27557 prelink_cmds \
27558 postlink_cmds \
27559 postinstall_cmds \
27560 postuninstall_cmds \
27561 finish_cmds \
27562 sys_lib_search_path_spec \
27563 sys_lib_dlsearch_path_spec \
27564 reload_cmds_CXX \
27565 reload_cmds_RC \
27566 old_archive_cmds_CXX \
27567 old_archive_cmds_RC \
27568 old_archive_from_new_cmds_CXX \
27569 old_archive_from_new_cmds_RC \
27570 old_archive_from_expsyms_cmds_CXX \
27571 old_archive_from_expsyms_cmds_RC \
27572 archive_cmds_CXX \
27573 archive_cmds_RC \
27574 archive_expsym_cmds_CXX \
27575 archive_expsym_cmds_RC \
27576 module_cmds_CXX \
27577 module_cmds_RC \
27578 module_expsym_cmds_CXX \
27579 module_expsym_cmds_RC \
27580 export_symbols_cmds_CXX \
27581 export_symbols_cmds_RC \
27582 prelink_cmds_CXX \
27583 prelink_cmds_RC \
27584 postlink_cmds_CXX \
27585 postlink_cmds_RC; do
27586 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
27587 *[\\\\\\\`\\"\\\$]*)
27588 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
27589 ;;
27590 *)
27591 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
27592 ;;
27593 esac
27594 done
27595
27596 ac_aux_dir='$ac_aux_dir'
27597 xsi_shell='$xsi_shell'
27598 lt_shell_append='$lt_shell_append'
27599
27600 # See if we are running on zsh, and set the options which allow our
27601 # commands through without removal of \ escapes INIT.
27602 if test -n "\${ZSH_VERSION+set}" ; then
27603 setopt NO_GLOB_SUBST
27604 fi
27605
27606
27607 PACKAGE='$PACKAGE'
27608 VERSION='$VERSION'
27609 TIMESTAMP='$TIMESTAMP'
27610 RM='$RM'
27611 ofile='$ofile'
27612
27613
27614
27615
27616
27617
27618
27619
27620 _ACEOF
27621
27622 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27623
27624 # Handling of arguments.
27625 for ac_config_target in $ac_config_targets
27626 do
27627 case $ac_config_target in
27628 "conf/config.h") CONFIG_HEADERS="$CONFIG_HEADERS conf/config.h" ;;
27629 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
27630 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
27631 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
27632 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
27633 "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
27634 "tests/gpg/Makefile") CONFIG_FILES="$CONFIG_FILES tests/gpg/Makefile" ;;
27635 "tests/gpgsm/Makefile") CONFIG_FILES="$CONFIG_FILES tests/gpgsm/Makefile" ;;
27636 "tests/opassuan/Makefile") CONFIG_FILES="$CONFIG_FILES tests/opassuan/Makefile" ;;
27637 "tests/json/Makefile") CONFIG_FILES="$CONFIG_FILES tests/json/Makefile" ;;
27638 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
27639 "src/versioninfo.rc") CONFIG_FILES="$CONFIG_FILES src/versioninfo.rc" ;;
27640 "src/gpgme.pc") CONFIG_FILES="$CONFIG_FILES src/gpgme.pc" ;;
27641 "src/gpgme-glib.pc") CONFIG_FILES="$CONFIG_FILES src/gpgme-glib.pc" ;;
27642 "src/gpgme.h") CONFIG_FILES="$CONFIG_FILES src/gpgme.h" ;;
27643 "src/gpgme-config") CONFIG_FILES="$CONFIG_FILES src/gpgme-config" ;;
27644 "lang/cpp/Makefile") CONFIG_FILES="$CONFIG_FILES lang/cpp/Makefile" ;;
27645 "lang/cpp/src/Makefile") CONFIG_FILES="$CONFIG_FILES lang/cpp/src/Makefile" ;;
27646 "lang/cpp/tests/Makefile") CONFIG_FILES="$CONFIG_FILES lang/cpp/tests/Makefile" ;;
27647 "lang/cpp/src/GpgmeppConfig-w32.cmake.in") CONFIG_FILES="$CONFIG_FILES lang/cpp/src/GpgmeppConfig-w32.cmake.in" ;;
27648 "lang/cpp/src/GpgmeppConfig.cmake.in") CONFIG_FILES="$CONFIG_FILES lang/cpp/src/GpgmeppConfig.cmake.in" ;;
27649 "lang/cpp/src/GpgmeppConfigVersion.cmake") CONFIG_FILES="$CONFIG_FILES lang/cpp/src/GpgmeppConfigVersion.cmake" ;;
27650 "lang/cpp/src/gpgmepp_version.h") CONFIG_FILES="$CONFIG_FILES lang/cpp/src/gpgmepp_version.h" ;;
27651 "lang/qt/Makefile") CONFIG_FILES="$CONFIG_FILES lang/qt/Makefile" ;;
27652 "lang/qt/src/Makefile") CONFIG_FILES="$CONFIG_FILES lang/qt/src/Makefile" ;;
27653 "lang/qt/src/QGpgmeConfig-w32.cmake.in") CONFIG_FILES="$CONFIG_FILES lang/qt/src/QGpgmeConfig-w32.cmake.in" ;;
27654 "lang/qt/src/QGpgmeConfig.cmake.in") CONFIG_FILES="$CONFIG_FILES lang/qt/src/QGpgmeConfig.cmake.in" ;;
27655 "lang/qt/src/QGpgmeConfigVersion.cmake") CONFIG_FILES="$CONFIG_FILES lang/qt/src/QGpgmeConfigVersion.cmake" ;;
27656 "lang/qt/tests/Makefile") CONFIG_FILES="$CONFIG_FILES lang/qt/tests/Makefile" ;;
27657 "lang/qt/src/qgpgme_version.h") CONFIG_FILES="$CONFIG_FILES lang/qt/src/qgpgme_version.h" ;;
27658 "lang/Makefile") CONFIG_FILES="$CONFIG_FILES lang/Makefile" ;;
27659 "lang/cl/Makefile") CONFIG_FILES="$CONFIG_FILES lang/cl/Makefile" ;;
27660 "lang/cl/gpgme.asd") CONFIG_FILES="$CONFIG_FILES lang/cl/gpgme.asd" ;;
27661 "lang/qt/doc/Doxyfile") CONFIG_FILES="$CONFIG_FILES lang/qt/doc/Doxyfile" ;;
27662 "lang/js/Makefile") CONFIG_FILES="$CONFIG_FILES lang/js/Makefile" ;;
27663 "lang/js/src/Makefile") CONFIG_FILES="$CONFIG_FILES lang/js/src/Makefile" ;;
27664 "lang/js/BrowserTestExtension/Makefile") CONFIG_FILES="$CONFIG_FILES lang/js/BrowserTestExtension/Makefile" ;;
27665 "lang/js/DemoExtension/Makefile") CONFIG_FILES="$CONFIG_FILES lang/js/DemoExtension/Makefile" ;;
27666 "lang/qt/doc/Makefile") CONFIG_FILES="$CONFIG_FILES lang/qt/doc/Makefile" ;;
27667 "lang/python/Makefile") CONFIG_FILES="$CONFIG_FILES lang/python/Makefile" ;;
27668 "lang/python/version.py") CONFIG_FILES="$CONFIG_FILES lang/python/version.py" ;;
27669 "lang/python/tests/Makefile") CONFIG_FILES="$CONFIG_FILES lang/python/tests/Makefile" ;;
27670 "lang/python/src/Makefile") CONFIG_FILES="$CONFIG_FILES lang/python/src/Makefile" ;;
27671 "lang/python/examples/Makefile") CONFIG_FILES="$CONFIG_FILES lang/python/examples/Makefile" ;;
27672 "lang/python/doc/Makefile") CONFIG_FILES="$CONFIG_FILES lang/python/doc/Makefile" ;;
27673 "lang/python/setup.py") CONFIG_FILES="$CONFIG_FILES lang/python/setup.py" ;;
27674
27675 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
27676 esac
27677 done
27678
27679
27680 # If the user did not use the arguments to specify the items to instantiate,
27681 # then the envvar interface is used. Set only those that are not.
27682 # We use the long form for the default assignment because of an extremely
27683 # bizarre bug on SunOS 4.1.3.
27684 if $ac_need_defaults; then
27685 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
27686 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
27687 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
27688 fi
27689
27690 # Have a temporary directory for convenience. Make it in the build tree
27691 # simply because there is no reason against having it here, and in addition,
27692 # creating and moving files from /tmp can sometimes cause problems.
27693 # Hook for its removal unless debugging.
27694 # Note that there is a small window in which the directory will not be cleaned:
27695 # after its creation but before its name has been assigned to `$tmp'.
27696 $debug ||
27697 {
27698 tmp= ac_tmp=
27699 trap 'exit_status=$?
27700 : "${ac_tmp:=$tmp}"
27701 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
27702 ' 0
27703 trap 'as_fn_exit 1' 1 2 13 15
27704 }
27705 # Create a (secure) tmp directory for tmp files.
27706
27707 {
27708 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
27709 test -d "$tmp"
27710 } ||
27711 {
27712 tmp=./conf$$-$RANDOM
27713 (umask 077 && mkdir "$tmp")
27714 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
27715 ac_tmp=$tmp
27716
27717 # Set up the scripts for CONFIG_FILES section.
27718 # No need to generate them if there are no CONFIG_FILES.
27719 # This happens for instance with `./config.status config.h'.
27720 if test -n "$CONFIG_FILES"; then
27721
27722
27723 ac_cr=`echo X | tr X '\015'`
27724 # On cygwin, bash can eat \r inside `` if the user requested igncr.
27725 # But we know of no other shell where ac_cr would be empty at this
27726 # point, so we can use a bashism as a fallback.
27727 if test "x$ac_cr" = x; then
27728 eval ac_cr=\$\'\\r\'
27729 fi
27730 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
27731 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
27732 ac_cs_awk_cr='\\r'
27733 else
27734 ac_cs_awk_cr=$ac_cr
27735 fi
27736
27737 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
27738 _ACEOF
27739
27740
27741 {
27742 echo "cat >conf$$subs.awk <<_ACEOF" &&
27743 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
27744 echo "_ACEOF"
27745 } >conf$$subs.sh ||
27746 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
27747 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
27748 ac_delim='%!_!# '
27749 for ac_last_try in false false false false false :; do
27750 . ./conf$$subs.sh ||
27751 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
27752
27753 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
27754 if test $ac_delim_n = $ac_delim_num; then
27755 break
27756 elif $ac_last_try; then
27757 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
27758 else
27759 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27760 fi
27761 done
27762 rm -f conf$$subs.sh
27763
27764 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27765 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
27766 _ACEOF
27767 sed -n '
27768 h
27769 s/^/S["/; s/!.*/"]=/
27770 p
27771 g
27772 s/^[^!]*!//
27773 :repl
27774 t repl
27775 s/'"$ac_delim"'$//
27776 t delim
27777 :nl
27778 h
27779 s/\(.\{148\}\)..*/\1/
27780 t more1
27781 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
27782 p
27783 n
27784 b repl
27785 :more1
27786 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27787 p
27788 g
27789 s/.\{148\}//
27790 t nl
27791 :delim
27792 h
27793 s/\(.\{148\}\)..*/\1/
27794 t more2
27795 s/["\\]/\\&/g; s/^/"/; s/$/"/
27796 p
27797 b
27798 :more2
27799 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27800 p
27801 g
27802 s/.\{148\}//
27803 t delim
27804 ' <conf$$subs.awk | sed '
27805 /^[^""]/{
27806 N
27807 s/\n//
27808 }
27809 ' >>$CONFIG_STATUS || ac_write_fail=1
27810 rm -f conf$$subs.awk
27811 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27812 _ACAWK
27813 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
27814 for (key in S) S_is_set[key] = 1
27815 FS = ""
27816
27817 }
27818 {
27819 line = $ 0
27820 nfields = split(line, field, "@")
27821 substed = 0
27822 len = length(field[1])
27823 for (i = 2; i < nfields; i++) {
27824 key = field[i]
27825 keylen = length(key)
27826 if (S_is_set[key]) {
27827 value = S[key]
27828 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
27829 len += length(value) + length(field[++i])
27830 substed = 1
27831 } else
27832 len += 1 + keylen
27833 }
27834
27835 print line
27836 }
27837
27838 _ACAWK
27839 _ACEOF
27840 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27841 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
27842 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
27843 else
27844 cat
27845 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
27846 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
27847 _ACEOF
27848
27849 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
27850 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
27851 # trailing colons and then remove the whole line if VPATH becomes empty
27852 # (actually we leave an empty line to preserve line numbers).
27853 if test "x$srcdir" = x.; then
27854 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
27855 h
27856 s///
27857 s/^/:/
27858 s/[ ]*$/:/
27859 s/:\$(srcdir):/:/g
27860 s/:\${srcdir}:/:/g
27861 s/:@srcdir@:/:/g
27862 s/^:*//
27863 s/:*$//
27864 x
27865 s/\(=[ ]*\).*/\1/
27866 G
27867 s/\n//
27868 s/^[^=]*=[ ]*$//
27869 }'
27870 fi
27871
27872 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27873 fi # test -n "$CONFIG_FILES"
27874
27875 # Set up the scripts for CONFIG_HEADERS section.
27876 # No need to generate them if there are no CONFIG_HEADERS.
27877 # This happens for instance with `./config.status Makefile'.
27878 if test -n "$CONFIG_HEADERS"; then
27879 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
27880 BEGIN {
27881 _ACEOF
27882
27883 # Transform confdefs.h into an awk script `defines.awk', embedded as
27884 # here-document in config.status, that substitutes the proper values into
27885 # config.h.in to produce config.h.
27886
27887 # Create a delimiter string that does not exist in confdefs.h, to ease
27888 # handling of long lines.
27889 ac_delim='%!_!# '
27890 for ac_last_try in false false :; do
27891 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
27892 if test -z "$ac_tt"; then
27893 break
27894 elif $ac_last_try; then
27895 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
27896 else
27897 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27898 fi
27899 done
27900
27901 # For the awk script, D is an array of macro values keyed by name,
27902 # likewise P contains macro parameters if any. Preserve backslash
27903 # newline sequences.
27904
27905 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
27906 sed -n '
27907 s/.\{148\}/&'"$ac_delim"'/g
27908 t rset
27909 :rset
27910 s/^[ ]*#[ ]*define[ ][ ]*/ /
27911 t def
27912 d
27913 :def
27914 s/\\$//
27915 t bsnl
27916 s/["\\]/\\&/g
27917 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27918 D["\1"]=" \3"/p
27919 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
27920 d
27921 :bsnl
27922 s/["\\]/\\&/g
27923 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27924 D["\1"]=" \3\\\\\\n"\\/p
27925 t cont
27926 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
27927 t cont
27928 d
27929 :cont
27930 n
27931 s/.\{148\}/&'"$ac_delim"'/g
27932 t clear
27933 :clear
27934 s/\\$//
27935 t bsnlc
27936 s/["\\]/\\&/g; s/^/"/; s/$/"/p
27937 d
27938 :bsnlc
27939 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
27940 b cont
27941 ' <confdefs.h | sed '
27942 s/'"$ac_delim"'/"\\\
27943 "/g' >>$CONFIG_STATUS || ac_write_fail=1
27944
27945 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27946 for (key in D) D_is_set[key] = 1
27947 FS = ""
27948 }
27949 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
27950 line = \$ 0
27951 split(line, arg, " ")
27952 if (arg[1] == "#") {
27953 defundef = arg[2]
27954 mac1 = arg[3]
27955 } else {
27956 defundef = substr(arg[1], 2)
27957 mac1 = arg[2]
27958 }
27959 split(mac1, mac2, "(") #)
27960 macro = mac2[1]
27961 prefix = substr(line, 1, index(line, defundef) - 1)
27962 if (D_is_set[macro]) {
27963 # Preserve the white space surrounding the "#".
27964 print prefix "define", macro P[macro] D[macro]
27965 next
27966 } else {
27967 # Replace #undef with comments. This is necessary, for example,
27968 # in the case of _POSIX_SOURCE, which is predefined and required
27969 # on some systems where configure will not decide to define it.
27970 if (defundef == "undef") {
27971 print "/*", prefix defundef, macro, "*/"
27972 next
27973 }
27974 }
27975 }
27976 { print }
27977 _ACAWK
27978 _ACEOF
27979 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27980 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
27981 fi # test -n "$CONFIG_HEADERS"
27982
27983
27984 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
27985 shift
27986 for ac_tag
27987 do
27988 case $ac_tag in
27989 :[FHLC]) ac_mode=$ac_tag; continue;;
27990 esac
27991 case $ac_mode$ac_tag in
27992 :[FHL]*:*);;
27993 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
27994 :[FH]-) ac_tag=-:-;;
27995 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
27996 esac
27997 ac_save_IFS=$IFS
27998 IFS=:
27999 set x $ac_tag
28000 IFS=$ac_save_IFS
28001 shift
28002 ac_file=$1
28003 shift
28004
28005 case $ac_mode in
28006 :L) ac_source=$1;;
28007 :[FH])
28008 ac_file_inputs=
28009 for ac_f
28010 do
28011 case $ac_f in
28012 -) ac_f="$ac_tmp/stdin";;
28013 *) # Look for the file first in the build tree, then in the source tree
28014 # (if the path is not absolute). The absolute path cannot be DOS-style,
28015 # because $ac_f cannot contain `:'.
28016 test -f "$ac_f" ||
28017 case $ac_f in
28018 [\\/$]*) false;;
28019 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
28020 esac ||
28021 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
28022 esac
28023 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
28024 as_fn_append ac_file_inputs " '$ac_f'"
28025 done
28026
28027 # Let's still pretend it is `configure' which instantiates (i.e., don't
28028 # use $as_me), people would be surprised to read:
28029 # /* config.h. Generated by config.status. */
28030 configure_input='Generated from '`
28031 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
28032 `' by configure.'
28033 if test x"$ac_file" != x-; then
28034 configure_input="$ac_file. $configure_input"
28035 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
28036 $as_echo "$as_me: creating $ac_file" >&6;}
28037 fi
28038 # Neutralize special characters interpreted by sed in replacement strings.
28039 case $configure_input in #(
28040 *\&* | *\|* | *\\* )
28041 ac_sed_conf_input=`$as_echo "$configure_input" |
28042 sed 's/[\\\\&|]/\\\\&/g'`;; #(
28043 *) ac_sed_conf_input=$configure_input;;
28044 esac
28045
28046 case $ac_tag in
28047 *:-:* | *:-) cat >"$ac_tmp/stdin" \
28048 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
28049 esac
28050 ;;
28051 esac
28052
28053 ac_dir=`$as_dirname -- "$ac_file" ||
28054 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28055 X"$ac_file" : 'X\(//\)[^/]' \| \
28056 X"$ac_file" : 'X\(//\)$' \| \
28057 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
28058 $as_echo X"$ac_file" |
28059 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28060 s//\1/
28061 q
28062 }
28063 /^X\(\/\/\)[^/].*/{
28064 s//\1/
28065 q
28066 }
28067 /^X\(\/\/\)$/{
28068 s//\1/
28069 q
28070 }
28071 /^X\(\/\).*/{
28072 s//\1/
28073 q
28074 }
28075 s/.*/./; q'`
28076 as_dir="$ac_dir"; as_fn_mkdir_p
28077 ac_builddir=.
28078
28079 case "$ac_dir" in
28080 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
28081 *)
28082 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
28083 # A ".." for each directory in $ac_dir_suffix.
28084 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
28085 case $ac_top_builddir_sub in
28086 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
28087 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
28088 esac ;;
28089 esac
28090 ac_abs_top_builddir=$ac_pwd
28091 ac_abs_builddir=$ac_pwd$ac_dir_suffix
28092 # for backward compatibility:
28093 ac_top_builddir=$ac_top_build_prefix
28094
28095 case $srcdir in
28096 .) # We are building in place.
28097 ac_srcdir=.
28098 ac_top_srcdir=$ac_top_builddir_sub
28099 ac_abs_top_srcdir=$ac_pwd ;;
28100 [\\/]* | ?:[\\/]* ) # Absolute name.
28101 ac_srcdir=$srcdir$ac_dir_suffix;
28102 ac_top_srcdir=$srcdir
28103 ac_abs_top_srcdir=$srcdir ;;
28104 *) # Relative name.
28105 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
28106 ac_top_srcdir=$ac_top_build_prefix$srcdir
28107 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
28108 esac
28109 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
28110
28111
28112 case $ac_mode in
28113 :F)
28114 #
28115 # CONFIG_FILE
28116 #
28117
28118 case $INSTALL in
28119 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
28120 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
28121 esac
28122 ac_MKDIR_P=$MKDIR_P
28123 case $MKDIR_P in
28124 [\\/$]* | ?:[\\/]* ) ;;
28125 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
28126 esac
28127 _ACEOF
28128
28129 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28130 # If the template does not know about datarootdir, expand it.
28131 # FIXME: This hack should be removed a few years after 2.60.
28132 ac_datarootdir_hack=; ac_datarootdir_seen=
28133 ac_sed_dataroot='
28134 /datarootdir/ {
28135 p
28136 q
28137 }
28138 /@datadir@/p
28139 /@docdir@/p
28140 /@infodir@/p
28141 /@localedir@/p
28142 /@mandir@/p'
28143 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
28144 *datarootdir*) ac_datarootdir_seen=yes;;
28145 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
28146 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
28147 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
28148 _ACEOF
28149 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28150 ac_datarootdir_hack='
28151 s&@datadir@&$datadir&g
28152 s&@docdir@&$docdir&g
28153 s&@infodir@&$infodir&g
28154 s&@localedir@&$localedir&g
28155 s&@mandir@&$mandir&g
28156 s&\\\${datarootdir}&$datarootdir&g' ;;
28157 esac
28158 _ACEOF
28159
28160 # Neutralize VPATH when `$srcdir' = `.'.
28161 # Shell code in configure.ac might set extrasub.
28162 # FIXME: do we really want to maintain this feature?
28163 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28164 ac_sed_extra="$ac_vpsub
28165 $extrasub
28166 _ACEOF
28167 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28168 :t
28169 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
28170 s|@configure_input@|$ac_sed_conf_input|;t t
28171 s&@top_builddir@&$ac_top_builddir_sub&;t t
28172 s&@top_build_prefix@&$ac_top_build_prefix&;t t
28173 s&@srcdir@&$ac_srcdir&;t t
28174 s&@abs_srcdir@&$ac_abs_srcdir&;t t
28175 s&@top_srcdir@&$ac_top_srcdir&;t t
28176 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
28177 s&@builddir@&$ac_builddir&;t t
28178 s&@abs_builddir@&$ac_abs_builddir&;t t
28179 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
28180 s&@INSTALL@&$ac_INSTALL&;t t
28181 s&@MKDIR_P@&$ac_MKDIR_P&;t t
28182 $ac_datarootdir_hack
28183 "
28184 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
28185 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28186
28187 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
28188 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
28189 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
28190 "$ac_tmp/out"`; test -z "$ac_out"; } &&
28191 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
28192 which seems to be undefined. Please make sure it is defined" >&5
28193 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
28194 which seems to be undefined. Please make sure it is defined" >&2;}
28195
28196 rm -f "$ac_tmp/stdin"
28197 case $ac_file in
28198 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
28199 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
28200 esac \
28201 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28202 ;;
28203 :H)
28204 #
28205 # CONFIG_HEADER
28206 #
28207 if test x"$ac_file" != x-; then
28208 {
28209 $as_echo "/* $configure_input */" \
28210 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
28211 } >"$ac_tmp/config.h" \
28212 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28213 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
28214 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
28215 $as_echo "$as_me: $ac_file is unchanged" >&6;}
28216 else
28217 rm -f "$ac_file"
28218 mv "$ac_tmp/config.h" "$ac_file" \
28219 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
28220 fi
28221 else
28222 $as_echo "/* $configure_input */" \
28223 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
28224 || as_fn_error $? "could not create -" "$LINENO" 5
28225 fi
28226 # Compute "$ac_file"'s index in $config_headers.
28227 _am_arg="$ac_file"
28228 _am_stamp_count=1
28229 for _am_header in $config_headers :; do
28230 case $_am_header in
28231 $_am_arg | $_am_arg:* )
28232 break ;;
28233 * )
28234 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
28235 esac
28236 done
28237 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
28238 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28239 X"$_am_arg" : 'X\(//\)[^/]' \| \
28240 X"$_am_arg" : 'X\(//\)$' \| \
28241 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
28242 $as_echo X"$_am_arg" |
28243 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28244 s//\1/
28245 q
28246 }
28247 /^X\(\/\/\)[^/].*/{
28248 s//\1/
28249 q
28250 }
28251 /^X\(\/\/\)$/{
28252 s//\1/
28253 q
28254 }
28255 /^X\(\/\).*/{
28256 s//\1/
28257 q
28258 }
28259 s/.*/./; q'`/stamp-h$_am_stamp_count
28260 ;;
28261
28262 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
28263 $as_echo "$as_me: executing $ac_file commands" >&6;}
28264 ;;
28265 esac
28266
28267
28268 case $ac_file$ac_mode in
28269 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
28270 # Older Autoconf quotes --file arguments for eval, but not when files
28271 # are listed without --file. Let's play safe and only enable the eval
28272 # if we detect the quoting.
28273 # TODO: see whether this extra hack can be removed once we start
28274 # requiring Autoconf 2.70 or later.
28275 case $CONFIG_FILES in #(
28276 *\'*) :
28277 eval set x "$CONFIG_FILES" ;; #(
28278 *) :
28279 set x $CONFIG_FILES ;; #(
28280 *) :
28281 ;;
28282 esac
28283 shift
28284 # Used to flag and report bootstrapping failures.
28285 am_rc=0
28286 for am_mf
28287 do
28288 # Strip MF so we end up with the name of the file.
28289 am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'`
28290 # Check whether this is an Automake generated Makefile which includes
28291 # dependency-tracking related rules and includes.
28292 # Grep'ing the whole file directly is not great: AIX grep has a line
28293 # limit of 2048, but all sed's we know have understand at least 4000.
28294 sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
28295 || continue
28296 am_dirpart=`$as_dirname -- "$am_mf" ||
28297 $as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28298 X"$am_mf" : 'X\(//\)[^/]' \| \
28299 X"$am_mf" : 'X\(//\)$' \| \
28300 X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
28301 $as_echo X"$am_mf" |
28302 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28303 s//\1/
28304 q
28305 }
28306 /^X\(\/\/\)[^/].*/{
28307 s//\1/
28308 q
28309 }
28310 /^X\(\/\/\)$/{
28311 s//\1/
28312 q
28313 }
28314 /^X\(\/\).*/{
28315 s//\1/
28316 q
28317 }
28318 s/.*/./; q'`
28319 am_filepart=`$as_basename -- "$am_mf" ||
28320 $as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \
28321 X"$am_mf" : 'X\(//\)$' \| \
28322 X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
28323 $as_echo X/"$am_mf" |
28324 sed '/^.*\/\([^/][^/]*\)\/*$/{
28325 s//\1/
28326 q
28327 }
28328 /^X\/\(\/\/\)$/{
28329 s//\1/
28330 q
28331 }
28332 /^X\/\(\/\).*/{
28333 s//\1/
28334 q
28335 }
28336 s/.*/./; q'`
28337 { echo "$as_me:$LINENO: cd "$am_dirpart" \
28338 && sed -e '/# am--include-marker/d' "$am_filepart" \
28339 | $MAKE -f - am--depfiles" >&5
28340 (cd "$am_dirpart" \
28341 && sed -e '/# am--include-marker/d' "$am_filepart" \
28342 | $MAKE -f - am--depfiles) >&5 2>&5
28343 ac_status=$?
28344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
28345 (exit $ac_status); } || am_rc=$?
28346 done
28347 if test $am_rc -ne 0; then
28348 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28349 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28350 as_fn_error $? "Something went wrong bootstrapping makefile fragments
28351 for automatic dependency tracking. If GNU make was not used, consider
28352 re-running the configure script with MAKE=\"gmake\" (or whatever is
28353 necessary). You can also try re-running configure with the
28354 '--disable-dependency-tracking' option to at least be able to build
28355 the package (albeit without support for automatic dependency tracking).
28356 See \`config.log' for more details" "$LINENO" 5; }
28357 fi
28358 { am_dirpart=; unset am_dirpart;}
28359 { am_filepart=; unset am_filepart;}
28360 { am_mf=; unset am_mf;}
28361 { am_rc=; unset am_rc;}
28362 rm -f conftest-deps.mk
28363 }
28364 ;;
28365 "libtool":C)
28366
28367 # See if we are running on zsh, and set the options which allow our
28368 # commands through without removal of \ escapes.
28369 if test -n "${ZSH_VERSION+set}" ; then
28370 setopt NO_GLOB_SUBST
28371 fi
28372
28373 cfgfile="${ofile}T"
28374 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
28375 $RM "$cfgfile"
28376
28377 cat <<_LT_EOF >> "$cfgfile"
28378 #! $SHELL
28379
28380 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
28381 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
28382 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
28383 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
28384 #
28385 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
28386 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
28387 # Foundation, Inc.
28388 # Written by Gordon Matzigkeit, 1996
28389 #
28390 # This file is part of GNU Libtool.
28391 #
28392 # GNU Libtool is free software; you can redistribute it and/or
28393 # modify it under the terms of the GNU General Public License as
28394 # published by the Free Software Foundation; either version 2 of
28395 # the License, or (at your option) any later version.
28396 #
28397 # As a special exception to the GNU General Public License,
28398 # if you distribute this file as part of a program or library that
28399 # is built using GNU Libtool, you may include this file under the
28400 # same distribution terms that you use for the rest of that program.
28401 #
28402 # GNU Libtool is distributed in the hope that it will be useful,
28403 # but WITHOUT ANY WARRANTY; without even the implied warranty of
28404 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28405 # GNU General Public License for more details.
28406 #
28407 # You should have received a copy of the GNU General Public License
28408 # along with GNU Libtool; see the file COPYING. If not, a copy
28409 # can be downloaded from https://www.gnu.org/licenses/gpl.html, or
28410 # obtained by writing to the Free Software Foundation, Inc.,
28411 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
28412
28413
28414 # The names of the tagged configurations supported by this script.
28415 available_tags="CXX RC "
28416
28417 # ### BEGIN LIBTOOL CONFIG
28418
28419 # Which release of libtool.m4 was used?
28420 macro_version=$macro_version
28421 macro_revision=$macro_revision
28422
28423 # Assembler program.
28424 AS=$lt_AS
28425
28426 # DLL creation program.
28427 DLLTOOL=$lt_DLLTOOL
28428
28429 # Object dumper program.
28430 OBJDUMP=$lt_OBJDUMP
28431
28432 # Whether or not to build static libraries.
28433 build_old_libs=$enable_static
28434
28435 # Whether or not to build shared libraries.
28436 build_libtool_libs=$enable_shared
28437
28438 # What type of objects to build.
28439 pic_mode=$pic_mode
28440
28441 # Whether or not to optimize for fast installation.
28442 fast_install=$enable_fast_install
28443
28444 # Shell to use when invoking shell scripts.
28445 SHELL=$lt_SHELL
28446
28447 # An echo program that protects backslashes.
28448 ECHO=$lt_ECHO
28449
28450 # The PATH separator for the build system.
28451 PATH_SEPARATOR=$lt_PATH_SEPARATOR
28452
28453 # The host system.
28454 host_alias=$host_alias
28455 host=$host
28456 host_os=$host_os
28457
28458 # The build system.
28459 build_alias=$build_alias
28460 build=$build
28461 build_os=$build_os
28462
28463 # A sed program that does not truncate output.
28464 SED=$lt_SED
28465
28466 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
28467 Xsed="\$SED -e 1s/^X//"
28468
28469 # A grep program that handles long lines.
28470 GREP=$lt_GREP
28471
28472 # An ERE matcher.
28473 EGREP=$lt_EGREP
28474
28475 # A literal string matcher.
28476 FGREP=$lt_FGREP
28477
28478 # A BSD- or MS-compatible name lister.
28479 NM=$lt_NM
28480
28481 # Whether we need soft or hard links.
28482 LN_S=$lt_LN_S
28483
28484 # What is the maximum length of a command?
28485 max_cmd_len=$max_cmd_len
28486
28487 # Object file suffix (normally "o").
28488 objext=$ac_objext
28489
28490 # Executable file suffix (normally "").
28491 exeext=$exeext
28492
28493 # whether the shell understands "unset".
28494 lt_unset=$lt_unset
28495
28496 # turn spaces into newlines.
28497 SP2NL=$lt_lt_SP2NL
28498
28499 # turn newlines into spaces.
28500 NL2SP=$lt_lt_NL2SP
28501
28502 # convert \$build file names to \$host format.
28503 to_host_file_cmd=$lt_cv_to_host_file_cmd
28504
28505 # convert \$build files to toolchain format.
28506 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
28507
28508 # Method to check whether dependent libraries are shared objects.
28509 deplibs_check_method=$lt_deplibs_check_method
28510
28511 # Command to use when deplibs_check_method = "file_magic".
28512 file_magic_cmd=$lt_file_magic_cmd
28513
28514 # How to find potential files when deplibs_check_method = "file_magic".
28515 file_magic_glob=$lt_file_magic_glob
28516
28517 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
28518 want_nocaseglob=$lt_want_nocaseglob
28519
28520 # Command to associate shared and link libraries.
28521 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
28522
28523 # The archiver.
28524 AR=$lt_AR
28525
28526 # Flags to create an archive.
28527 AR_FLAGS=$lt_AR_FLAGS
28528
28529 # How to feed a file listing to the archiver.
28530 archiver_list_spec=$lt_archiver_list_spec
28531
28532 # A symbol stripping program.
28533 STRIP=$lt_STRIP
28534
28535 # Commands used to install an old-style archive.
28536 RANLIB=$lt_RANLIB
28537 old_postinstall_cmds=$lt_old_postinstall_cmds
28538 old_postuninstall_cmds=$lt_old_postuninstall_cmds
28539
28540 # Whether to use a lock for old archive extraction.
28541 lock_old_archive_extraction=$lock_old_archive_extraction
28542
28543 # A C compiler.
28544 LTCC=$lt_CC
28545
28546 # LTCC compiler flags.
28547 LTCFLAGS=$lt_CFLAGS
28548
28549 # Take the output of nm and produce a listing of raw symbols and C names.
28550 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
28551
28552 # Transform the output of nm in a proper C declaration.
28553 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
28554
28555 # Transform the output of nm in a C name address pair.
28556 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
28557
28558 # Transform the output of nm in a C name address pair when lib prefix is needed.
28559 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
28560
28561 # Specify filename containing input files for \$NM.
28562 nm_file_list_spec=$lt_nm_file_list_spec
28563
28564 # The root where to search for dependent libraries,and in which our libraries should be installed.
28565 lt_sysroot=$lt_sysroot
28566
28567 # The name of the directory that contains temporary libtool files.
28568 objdir=$objdir
28569
28570 # Used to examine libraries when file_magic_cmd begins with "file".
28571 MAGIC_CMD=$MAGIC_CMD
28572
28573 # Must we lock files when doing compilation?
28574 need_locks=$lt_need_locks
28575
28576 # Manifest tool.
28577 MANIFEST_TOOL=$lt_MANIFEST_TOOL
28578
28579 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
28580 DSYMUTIL=$lt_DSYMUTIL
28581
28582 # Tool to change global to local symbols on Mac OS X.
28583 NMEDIT=$lt_NMEDIT
28584
28585 # Tool to manipulate fat objects and archives on Mac OS X.
28586 LIPO=$lt_LIPO
28587
28588 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
28589 OTOOL=$lt_OTOOL
28590
28591 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
28592 OTOOL64=$lt_OTOOL64
28593
28594 # Old archive suffix (normally "a").
28595 libext=$libext
28596
28597 # Shared library suffix (normally ".so").
28598 shrext_cmds=$lt_shrext_cmds
28599
28600 # The commands to extract the exported symbol list from a shared archive.
28601 extract_expsyms_cmds=$lt_extract_expsyms_cmds
28602
28603 # Variables whose values should be saved in libtool wrapper scripts and
28604 # restored at link time.
28605 variables_saved_for_relink=$lt_variables_saved_for_relink
28606
28607 # Do we need the "lib" prefix for modules?
28608 need_lib_prefix=$need_lib_prefix
28609
28610 # Do we need a version for libraries?
28611 need_version=$need_version
28612
28613 # Library versioning type.
28614 version_type=$version_type
28615
28616 # Shared library runtime path variable.
28617 runpath_var=$runpath_var
28618
28619 # Shared library path variable.
28620 shlibpath_var=$shlibpath_var
28621
28622 # Is shlibpath searched before the hard-coded library search path?
28623 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
28624
28625 # Format of library name prefix.
28626 libname_spec=$lt_libname_spec
28627
28628 # List of archive names. First name is the real one, the rest are links.
28629 # The last name is the one that the linker finds with -lNAME
28630 library_names_spec=$lt_library_names_spec
28631
28632 # The coded name of the library, if different from the real name.
28633 soname_spec=$lt_soname_spec
28634
28635 # Permission mode override for installation of shared libraries.
28636 install_override_mode=$lt_install_override_mode
28637
28638 # Command to use after installation of a shared archive.
28639 postinstall_cmds=$lt_postinstall_cmds
28640
28641 # Command to use after uninstallation of a shared archive.
28642 postuninstall_cmds=$lt_postuninstall_cmds
28643
28644 # Commands used to finish a libtool library installation in a directory.
28645 finish_cmds=$lt_finish_cmds
28646
28647 # As "finish_cmds", except a single script fragment to be evaled but
28648 # not shown.
28649 finish_eval=$lt_finish_eval
28650
28651 # Whether we should hardcode library paths into libraries.
28652 hardcode_into_libs=$hardcode_into_libs
28653
28654 # Compile-time system search path for libraries.
28655 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
28656
28657 # Run-time system search path for libraries.
28658 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
28659
28660 # Whether dlopen is supported.
28661 dlopen_support=$enable_dlopen
28662
28663 # Whether dlopen of programs is supported.
28664 dlopen_self=$enable_dlopen_self
28665
28666 # Whether dlopen of statically linked programs is supported.
28667 dlopen_self_static=$enable_dlopen_self_static
28668
28669 # Commands to strip libraries.
28670 old_striplib=$lt_old_striplib
28671 striplib=$lt_striplib
28672
28673
28674 # The linker used to build libraries.
28675 LD=$lt_LD
28676
28677 # How to create reloadable object files.
28678 reload_flag=$lt_reload_flag
28679 reload_cmds=$lt_reload_cmds
28680
28681 # Commands used to build an old-style archive.
28682 old_archive_cmds=$lt_old_archive_cmds
28683
28684 # A language specific compiler.
28685 CC=$lt_compiler
28686
28687 # Is the compiler the GNU compiler?
28688 with_gcc=$GCC
28689
28690 # Compiler flag to turn off builtin functions.
28691 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
28692
28693 # Additional compiler flags for building library objects.
28694 pic_flag=$lt_lt_prog_compiler_pic
28695
28696 # How to pass a linker flag through the compiler.
28697 wl=$lt_lt_prog_compiler_wl
28698
28699 # Compiler flag to prevent dynamic linking.
28700 link_static_flag=$lt_lt_prog_compiler_static
28701
28702 # Does compiler simultaneously support -c and -o options?
28703 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
28704
28705 # Whether or not to add -lc for building shared libraries.
28706 build_libtool_need_lc=$archive_cmds_need_lc
28707
28708 # Whether or not to disallow shared libs when runtime libs are static.
28709 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
28710
28711 # Compiler flag to allow reflexive dlopens.
28712 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
28713
28714 # Compiler flag to generate shared objects directly from archives.
28715 whole_archive_flag_spec=$lt_whole_archive_flag_spec
28716
28717 # Whether the compiler copes with passing no objects directly.
28718 compiler_needs_object=$lt_compiler_needs_object
28719
28720 # Create an old-style archive from a shared archive.
28721 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
28722
28723 # Create a temporary old-style archive to link instead of a shared archive.
28724 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
28725
28726 # Commands used to build a shared archive.
28727 archive_cmds=$lt_archive_cmds
28728 archive_expsym_cmds=$lt_archive_expsym_cmds
28729
28730 # Commands used to build a loadable module if different from building
28731 # a shared archive.
28732 module_cmds=$lt_module_cmds
28733 module_expsym_cmds=$lt_module_expsym_cmds
28734
28735 # Whether we are building with GNU ld or not.
28736 with_gnu_ld=$lt_with_gnu_ld
28737
28738 # Flag that allows shared libraries with undefined symbols to be built.
28739 allow_undefined_flag=$lt_allow_undefined_flag
28740
28741 # Flag that enforces no undefined symbols.
28742 no_undefined_flag=$lt_no_undefined_flag
28743
28744 # Flag to hardcode \$libdir into a binary during linking.
28745 # This must work even if \$libdir does not exist
28746 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
28747
28748 # Whether we need a single "-rpath" flag with a separated argument.
28749 hardcode_libdir_separator=$lt_hardcode_libdir_separator
28750
28751 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
28752 # DIR into the resulting binary.
28753 hardcode_direct=$hardcode_direct
28754
28755 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
28756 # DIR into the resulting binary and the resulting library dependency is
28757 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
28758 # library is relocated.
28759 hardcode_direct_absolute=$hardcode_direct_absolute
28760
28761 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
28762 # into the resulting binary.
28763 hardcode_minus_L=$hardcode_minus_L
28764
28765 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
28766 # into the resulting binary.
28767 hardcode_shlibpath_var=$hardcode_shlibpath_var
28768
28769 # Set to "yes" if building a shared library automatically hardcodes DIR
28770 # into the library and all subsequent libraries and executables linked
28771 # against it.
28772 hardcode_automatic=$hardcode_automatic
28773
28774 # Set to yes if linker adds runtime paths of dependent libraries
28775 # to runtime path list.
28776 inherit_rpath=$inherit_rpath
28777
28778 # Whether libtool must link a program against all its dependency libraries.
28779 link_all_deplibs=$link_all_deplibs
28780
28781 # Set to "yes" if exported symbols are required.
28782 always_export_symbols=$always_export_symbols
28783
28784 # The commands to list exported symbols.
28785 export_symbols_cmds=$lt_export_symbols_cmds
28786
28787 # Symbols that should not be listed in the preloaded symbols.
28788 exclude_expsyms=$lt_exclude_expsyms
28789
28790 # Symbols that must always be exported.
28791 include_expsyms=$lt_include_expsyms
28792
28793 # Commands necessary for linking programs (against libraries) with templates.
28794 prelink_cmds=$lt_prelink_cmds
28795
28796 # Commands necessary for finishing linking programs.
28797 postlink_cmds=$lt_postlink_cmds
28798
28799 # Specify filename containing input files.
28800 file_list_spec=$lt_file_list_spec
28801
28802 # How to hardcode a shared library path into an executable.
28803 hardcode_action=$hardcode_action
28804
28805 # The directories searched by this compiler when creating a shared library.
28806 compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
28807
28808 # Dependencies to place before and after the objects being linked to
28809 # create a shared library.
28810 predep_objects=$lt_predep_objects
28811 postdep_objects=$lt_postdep_objects
28812 predeps=$lt_predeps
28813 postdeps=$lt_postdeps
28814
28815 # The library search path used internally by the compiler when linking
28816 # a shared library.
28817 compiler_lib_search_path=$lt_compiler_lib_search_path
28818
28819 # ### END LIBTOOL CONFIG
28820
28821 _LT_EOF
28822
28823 case $host_os in
28824 aix3*)
28825 cat <<\_LT_EOF >> "$cfgfile"
28826 # AIX sometimes has problems with the GCC collect2 program. For some
28827 # reason, if we set the COLLECT_NAMES environment variable, the problems
28828 # vanish in a puff of smoke.
28829 if test "X${COLLECT_NAMES+set}" != Xset; then
28830 COLLECT_NAMES=
28831 export COLLECT_NAMES
28832 fi
28833 _LT_EOF
28834 ;;
28835 esac
28836
28837
28838 ltmain="$ac_aux_dir/ltmain.sh"
28839
28840
28841 # We use sed instead of cat because bash on DJGPP gets confused if
28842 # if finds mixed CR/LF and LF-only lines. Since sed operates in
28843 # text mode, it properly converts lines to CR/LF. This bash problem
28844 # is reportedly fixed, but why not run on old versions too?
28845 sed '$q' "$ltmain" >> "$cfgfile" \
28846 || (rm -f "$cfgfile"; exit 1)
28847
28848 if test x"$xsi_shell" = xyes; then
28849 sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
28850 func_dirname ()\
28851 {\
28852 \ case ${1} in\
28853 \ */*) func_dirname_result="${1%/*}${2}" ;;\
28854 \ * ) func_dirname_result="${3}" ;;\
28855 \ esac\
28856 } # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
28857 && mv -f "$cfgfile.tmp" "$cfgfile" \
28858 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28859 test 0 -eq $? || _lt_function_replace_fail=:
28860
28861
28862 sed -e '/^func_basename ()$/,/^} # func_basename /c\
28863 func_basename ()\
28864 {\
28865 \ func_basename_result="${1##*/}"\
28866 } # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
28867 && mv -f "$cfgfile.tmp" "$cfgfile" \
28868 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28869 test 0 -eq $? || _lt_function_replace_fail=:
28870
28871
28872 sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
28873 func_dirname_and_basename ()\
28874 {\
28875 \ case ${1} in\
28876 \ */*) func_dirname_result="${1%/*}${2}" ;;\
28877 \ * ) func_dirname_result="${3}" ;;\
28878 \ esac\
28879 \ func_basename_result="${1##*/}"\
28880 } # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
28881 && mv -f "$cfgfile.tmp" "$cfgfile" \
28882 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28883 test 0 -eq $? || _lt_function_replace_fail=:
28884
28885
28886 sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
28887 func_stripname ()\
28888 {\
28889 \ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
28890 \ # positional parameters, so assign one to ordinary parameter first.\
28891 \ func_stripname_result=${3}\
28892 \ func_stripname_result=${func_stripname_result#"${1}"}\
28893 \ func_stripname_result=${func_stripname_result%"${2}"}\
28894 } # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
28895 && mv -f "$cfgfile.tmp" "$cfgfile" \
28896 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28897 test 0 -eq $? || _lt_function_replace_fail=:
28898
28899
28900 sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
28901 func_split_long_opt ()\
28902 {\
28903 \ func_split_long_opt_name=${1%%=*}\
28904 \ func_split_long_opt_arg=${1#*=}\
28905 } # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
28906 && mv -f "$cfgfile.tmp" "$cfgfile" \
28907 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28908 test 0 -eq $? || _lt_function_replace_fail=:
28909
28910
28911 sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
28912 func_split_short_opt ()\
28913 {\
28914 \ func_split_short_opt_arg=${1#??}\
28915 \ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
28916 } # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
28917 && mv -f "$cfgfile.tmp" "$cfgfile" \
28918 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28919 test 0 -eq $? || _lt_function_replace_fail=:
28920
28921
28922 sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
28923 func_lo2o ()\
28924 {\
28925 \ case ${1} in\
28926 \ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
28927 \ *) func_lo2o_result=${1} ;;\
28928 \ esac\
28929 } # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
28930 && mv -f "$cfgfile.tmp" "$cfgfile" \
28931 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28932 test 0 -eq $? || _lt_function_replace_fail=:
28933
28934
28935 sed -e '/^func_xform ()$/,/^} # func_xform /c\
28936 func_xform ()\
28937 {\
28938 func_xform_result=${1%.*}.lo\
28939 } # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
28940 && mv -f "$cfgfile.tmp" "$cfgfile" \
28941 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28942 test 0 -eq $? || _lt_function_replace_fail=:
28943
28944
28945 sed -e '/^func_arith ()$/,/^} # func_arith /c\
28946 func_arith ()\
28947 {\
28948 func_arith_result=$(( $* ))\
28949 } # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
28950 && mv -f "$cfgfile.tmp" "$cfgfile" \
28951 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28952 test 0 -eq $? || _lt_function_replace_fail=:
28953
28954
28955 sed -e '/^func_len ()$/,/^} # func_len /c\
28956 func_len ()\
28957 {\
28958 func_len_result=${#1}\
28959 } # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
28960 && mv -f "$cfgfile.tmp" "$cfgfile" \
28961 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28962 test 0 -eq $? || _lt_function_replace_fail=:
28963
28964 fi
28965
28966 if test x"$lt_shell_append" = xyes; then
28967 sed -e '/^func_append ()$/,/^} # func_append /c\
28968 func_append ()\
28969 {\
28970 eval "${1}+=\\${2}"\
28971 } # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
28972 && mv -f "$cfgfile.tmp" "$cfgfile" \
28973 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28974 test 0 -eq $? || _lt_function_replace_fail=:
28975
28976
28977 sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
28978 func_append_quoted ()\
28979 {\
28980 \ func_quote_for_eval "${2}"\
28981 \ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
28982 } # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
28983 && mv -f "$cfgfile.tmp" "$cfgfile" \
28984 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28985 test 0 -eq $? || _lt_function_replace_fail=:
28986
28987
28988 # Save a `func_append' function call where possible by direct use of '+='
28989 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
28990 && mv -f "$cfgfile.tmp" "$cfgfile" \
28991 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28992 test 0 -eq $? || _lt_function_replace_fail=:
28993 else
28994 # Save a `func_append' function call even when '+=' is not available
28995 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
28996 && mv -f "$cfgfile.tmp" "$cfgfile" \
28997 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
28998 test 0 -eq $? || _lt_function_replace_fail=:
28999 fi
29000
29001 if test x"$_lt_function_replace_fail" = x":"; then
29002 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
29003 $as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
29004 fi
29005
29006
29007 mv -f "$cfgfile" "$ofile" ||
29008 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
29009 chmod +x "$ofile"
29010
29011
29012 cat <<_LT_EOF >> "$ofile"
29013
29014 # ### BEGIN LIBTOOL TAG CONFIG: CXX
29015
29016 # The linker used to build libraries.
29017 LD=$lt_LD_CXX
29018
29019 # How to create reloadable object files.
29020 reload_flag=$lt_reload_flag_CXX
29021 reload_cmds=$lt_reload_cmds_CXX
29022
29023 # Commands used to build an old-style archive.
29024 old_archive_cmds=$lt_old_archive_cmds_CXX
29025
29026 # A language specific compiler.
29027 CC=$lt_compiler_CXX
29028
29029 # Is the compiler the GNU compiler?
29030 with_gcc=$GCC_CXX
29031
29032 # Compiler flag to turn off builtin functions.
29033 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
29034
29035 # Additional compiler flags for building library objects.
29036 pic_flag=$lt_lt_prog_compiler_pic_CXX
29037
29038 # How to pass a linker flag through the compiler.
29039 wl=$lt_lt_prog_compiler_wl_CXX
29040
29041 # Compiler flag to prevent dynamic linking.
29042 link_static_flag=$lt_lt_prog_compiler_static_CXX
29043
29044 # Does compiler simultaneously support -c and -o options?
29045 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
29046
29047 # Whether or not to add -lc for building shared libraries.
29048 build_libtool_need_lc=$archive_cmds_need_lc_CXX
29049
29050 # Whether or not to disallow shared libs when runtime libs are static.
29051 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
29052
29053 # Compiler flag to allow reflexive dlopens.
29054 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
29055
29056 # Compiler flag to generate shared objects directly from archives.
29057 whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
29058
29059 # Whether the compiler copes with passing no objects directly.
29060 compiler_needs_object=$lt_compiler_needs_object_CXX
29061
29062 # Create an old-style archive from a shared archive.
29063 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
29064
29065 # Create a temporary old-style archive to link instead of a shared archive.
29066 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
29067
29068 # Commands used to build a shared archive.
29069 archive_cmds=$lt_archive_cmds_CXX
29070 archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
29071
29072 # Commands used to build a loadable module if different from building
29073 # a shared archive.
29074 module_cmds=$lt_module_cmds_CXX
29075 module_expsym_cmds=$lt_module_expsym_cmds_CXX
29076
29077 # Whether we are building with GNU ld or not.
29078 with_gnu_ld=$lt_with_gnu_ld_CXX
29079
29080 # Flag that allows shared libraries with undefined symbols to be built.
29081 allow_undefined_flag=$lt_allow_undefined_flag_CXX
29082
29083 # Flag that enforces no undefined symbols.
29084 no_undefined_flag=$lt_no_undefined_flag_CXX
29085
29086 # Flag to hardcode \$libdir into a binary during linking.
29087 # This must work even if \$libdir does not exist
29088 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
29089
29090 # Whether we need a single "-rpath" flag with a separated argument.
29091 hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
29092
29093 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
29094 # DIR into the resulting binary.
29095 hardcode_direct=$hardcode_direct_CXX
29096
29097 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
29098 # DIR into the resulting binary and the resulting library dependency is
29099 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
29100 # library is relocated.
29101 hardcode_direct_absolute=$hardcode_direct_absolute_CXX
29102
29103 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
29104 # into the resulting binary.
29105 hardcode_minus_L=$hardcode_minus_L_CXX
29106
29107 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
29108 # into the resulting binary.
29109 hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
29110
29111 # Set to "yes" if building a shared library automatically hardcodes DIR
29112 # into the library and all subsequent libraries and executables linked
29113 # against it.
29114 hardcode_automatic=$hardcode_automatic_CXX
29115
29116 # Set to yes if linker adds runtime paths of dependent libraries
29117 # to runtime path list.
29118 inherit_rpath=$inherit_rpath_CXX
29119
29120 # Whether libtool must link a program against all its dependency libraries.
29121 link_all_deplibs=$link_all_deplibs_CXX
29122
29123 # Set to "yes" if exported symbols are required.
29124 always_export_symbols=$always_export_symbols_CXX
29125
29126 # The commands to list exported symbols.
29127 export_symbols_cmds=$lt_export_symbols_cmds_CXX
29128
29129 # Symbols that should not be listed in the preloaded symbols.
29130 exclude_expsyms=$lt_exclude_expsyms_CXX
29131
29132 # Symbols that must always be exported.
29133 include_expsyms=$lt_include_expsyms_CXX
29134
29135 # Commands necessary for linking programs (against libraries) with templates.
29136 prelink_cmds=$lt_prelink_cmds_CXX
29137
29138 # Commands necessary for finishing linking programs.
29139 postlink_cmds=$lt_postlink_cmds_CXX
29140
29141 # Specify filename containing input files.
29142 file_list_spec=$lt_file_list_spec_CXX
29143
29144 # How to hardcode a shared library path into an executable.
29145 hardcode_action=$hardcode_action_CXX
29146
29147 # The directories searched by this compiler when creating a shared library.
29148 compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
29149
29150 # Dependencies to place before and after the objects being linked to
29151 # create a shared library.
29152 predep_objects=$lt_predep_objects_CXX
29153 postdep_objects=$lt_postdep_objects_CXX
29154 predeps=$lt_predeps_CXX
29155 postdeps=$lt_postdeps_CXX
29156
29157 # The library search path used internally by the compiler when linking
29158 # a shared library.
29159 compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
29160
29161 # ### END LIBTOOL TAG CONFIG: CXX
29162 _LT_EOF
29163
29164
29165 cat <<_LT_EOF >> "$ofile"
29166
29167 # ### BEGIN LIBTOOL TAG CONFIG: RC
29168
29169 # The linker used to build libraries.
29170 LD=$lt_LD_RC
29171
29172 # How to create reloadable object files.
29173 reload_flag=$lt_reload_flag_RC
29174 reload_cmds=$lt_reload_cmds_RC
29175
29176 # Commands used to build an old-style archive.
29177 old_archive_cmds=$lt_old_archive_cmds_RC
29178
29179 # A language specific compiler.
29180 CC=$lt_compiler_RC
29181
29182 # Is the compiler the GNU compiler?
29183 with_gcc=$GCC_RC
29184
29185 # Compiler flag to turn off builtin functions.
29186 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC
29187
29188 # Additional compiler flags for building library objects.
29189 pic_flag=$lt_lt_prog_compiler_pic_RC
29190
29191 # How to pass a linker flag through the compiler.
29192 wl=$lt_lt_prog_compiler_wl_RC
29193
29194 # Compiler flag to prevent dynamic linking.
29195 link_static_flag=$lt_lt_prog_compiler_static_RC
29196
29197 # Does compiler simultaneously support -c and -o options?
29198 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC
29199
29200 # Whether or not to add -lc for building shared libraries.
29201 build_libtool_need_lc=$archive_cmds_need_lc_RC
29202
29203 # Whether or not to disallow shared libs when runtime libs are static.
29204 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC
29205
29206 # Compiler flag to allow reflexive dlopens.
29207 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC
29208
29209 # Compiler flag to generate shared objects directly from archives.
29210 whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC
29211
29212 # Whether the compiler copes with passing no objects directly.
29213 compiler_needs_object=$lt_compiler_needs_object_RC
29214
29215 # Create an old-style archive from a shared archive.
29216 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC
29217
29218 # Create a temporary old-style archive to link instead of a shared archive.
29219 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC
29220
29221 # Commands used to build a shared archive.
29222 archive_cmds=$lt_archive_cmds_RC
29223 archive_expsym_cmds=$lt_archive_expsym_cmds_RC
29224
29225 # Commands used to build a loadable module if different from building
29226 # a shared archive.
29227 module_cmds=$lt_module_cmds_RC
29228 module_expsym_cmds=$lt_module_expsym_cmds_RC
29229
29230 # Whether we are building with GNU ld or not.
29231 with_gnu_ld=$lt_with_gnu_ld_RC
29232
29233 # Flag that allows shared libraries with undefined symbols to be built.
29234 allow_undefined_flag=$lt_allow_undefined_flag_RC
29235
29236 # Flag that enforces no undefined symbols.
29237 no_undefined_flag=$lt_no_undefined_flag_RC
29238
29239 # Flag to hardcode \$libdir into a binary during linking.
29240 # This must work even if \$libdir does not exist
29241 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC
29242
29243 # Whether we need a single "-rpath" flag with a separated argument.
29244 hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC
29245
29246 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
29247 # DIR into the resulting binary.
29248 hardcode_direct=$hardcode_direct_RC
29249
29250 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
29251 # DIR into the resulting binary and the resulting library dependency is
29252 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
29253 # library is relocated.
29254 hardcode_direct_absolute=$hardcode_direct_absolute_RC
29255
29256 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
29257 # into the resulting binary.
29258 hardcode_minus_L=$hardcode_minus_L_RC
29259
29260 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
29261 # into the resulting binary.
29262 hardcode_shlibpath_var=$hardcode_shlibpath_var_RC
29263
29264 # Set to "yes" if building a shared library automatically hardcodes DIR
29265 # into the library and all subsequent libraries and executables linked
29266 # against it.
29267 hardcode_automatic=$hardcode_automatic_RC
29268
29269 # Set to yes if linker adds runtime paths of dependent libraries
29270 # to runtime path list.
29271 inherit_rpath=$inherit_rpath_RC
29272
29273 # Whether libtool must link a program against all its dependency libraries.
29274 link_all_deplibs=$link_all_deplibs_RC
29275
29276 # Set to "yes" if exported symbols are required.
29277 always_export_symbols=$always_export_symbols_RC
29278
29279 # The commands to list exported symbols.
29280 export_symbols_cmds=$lt_export_symbols_cmds_RC
29281
29282 # Symbols that should not be listed in the preloaded symbols.
29283 exclude_expsyms=$lt_exclude_expsyms_RC
29284
29285 # Symbols that must always be exported.
29286 include_expsyms=$lt_include_expsyms_RC
29287
29288 # Commands necessary for linking programs (against libraries) with templates.
29289 prelink_cmds=$lt_prelink_cmds_RC
29290
29291 # Commands necessary for finishing linking programs.
29292 postlink_cmds=$lt_postlink_cmds_RC
29293
29294 # Specify filename containing input files.
29295 file_list_spec=$lt_file_list_spec_RC
29296
29297 # How to hardcode a shared library path into an executable.
29298 hardcode_action=$hardcode_action_RC
29299
29300 # The directories searched by this compiler when creating a shared library.
29301 compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_RC
29302
29303 # Dependencies to place before and after the objects being linked to
29304 # create a shared library.
29305 predep_objects=$lt_predep_objects_RC
29306 postdep_objects=$lt_postdep_objects_RC
29307 predeps=$lt_predeps_RC
29308 postdeps=$lt_postdeps_RC
29309
29310 # The library search path used internally by the compiler when linking
29311 # a shared library.
29312 compiler_lib_search_path=$lt_compiler_lib_search_path_RC
29313
29314 # ### END LIBTOOL TAG CONFIG: RC
29315 _LT_EOF
29316
29317 ;;
29318 "src/gpgme-config":F) chmod +x src/gpgme-config ;;
29319 "lang/python/setup.py":F) chmod a+x lang/python/setup.py ;;
29320
29321 esac
29322 done # for ac_tag
29323
29324
29325 as_fn_exit 0
29326 _ACEOF
29327 ac_clean_files=$ac_clean_files_save
29328
29329 test $ac_write_fail = 0 ||
29330 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
29331
29332
29333 # configure is writing to config.log, and then calls config.status.
29334 # config.status does its own redirection, appending to config.log.
29335 # Unfortunately, on DOS this fails, as config.log is still kept open
29336 # by configure, so config.status won't be able to write to it; its
29337 # output is simply discarded. So we exec the FD to /dev/null,
29338 # effectively closing config.log, so it can be properly (re)opened and
29339 # appended to by config.status. When coming back to configure, we
29340 # need to make the FD available again.
29341 if test "$no_create" != yes; then
29342 ac_cs_success=:
29343 ac_config_status_args=
29344 test "$silent" = yes &&
29345 ac_config_status_args="$ac_config_status_args --quiet"
29346 exec 5>/dev/null
29347 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
29348 exec 5>>config.log
29349 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
29350 # would make configure fail if this is the last instruction.
29351 $ac_cs_success || as_fn_exit 1
29352 fi
29353 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
29354 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
29355 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
29356 fi
29357
29358
29359 echo "
29360 GPGME v${VERSION} has been configured as follows:
29361
29362 Revision: 72bb46b3 (29371)
29363 Platform: $host
29364
29365 UI Server: $uiserver
29366 FD Passing: $use_descriptor_passing
29367
29368 Language bindings: ${enabled_languages_v:-$enabled_languages}
29369 "
29370 if test "x${gpg_config_script_warn}" != x; then
29371 cat <<G10EOF
29372 Mismatches between the target platform and the to
29373 be used libraries have been been detected for:
29374 ${gpg_config_script_warn}
29375 Please check above for warning messages.
29376
29377 G10EOF
29378 fi
1818 # SPDX-License-Identifier: LGPL-2.1-or-later
1919
2020 # (Process this file with autoconf to produce a configure script.)
21 AC_PREREQ([2.59])
21 AC_PREREQ([2.69])
2222 min_automake_version="1.14"
2323
2424 # To build a release you need to create a tag with the version number
3030 # for the LT versions.
3131 m4_define([mym4_package],[gpgme])
3232 m4_define([mym4_major], [1])
33 m4_define([mym4_minor], [16])
33 m4_define([mym4_minor], [17])
3434 m4_define([mym4_micro], [0])
3535
3636 # Below is m4 magic to extract and compute the git revision number,
5252 # (Interfaces added: AGE++)
5353 # (Interfaces removed: AGE=0)
5454 #
55 LIBGPGME_LT_CURRENT=36
56 LIBGPGME_LT_AGE=25
55 LIBGPGME_LT_CURRENT=37
56 LIBGPGME_LT_AGE=26
5757 LIBGPGME_LT_REVISION=0
5858
5959 # If there is an ABI break in gpgmepp or qgpgme also bump the
6060 # version in IMPORTED_LOCATION in the GpgmeppConfig-w32.cmake.in.in
6161
62 LIBGPGMEPP_LT_CURRENT=19
63 LIBGPGMEPP_LT_AGE=13
62 LIBGPGMEPP_LT_CURRENT=20
63 LIBGPGMEPP_LT_AGE=14
6464 LIBGPGMEPP_LT_REVISION=0
6565
66 LIBQGPGME_LT_CURRENT=13
67 LIBQGPGME_LT_AGE=6
66 LIBQGPGME_LT_CURRENT=14
67 LIBQGPGME_LT_AGE=7
6868 LIBQGPGME_LT_REVISION=0
6969 ################################################
7070
9595
9696 AC_CONFIG_AUX_DIR([build-aux])
9797 AC_CONFIG_MACRO_DIR([m4])
98 AC_CONFIG_SRCDIR(src/gpgme.h.in)
99 AC_CONFIG_HEADER(conf/config.h)
98 AC_CONFIG_SRCDIR([src/gpgme.h.in])
99 AC_CONFIG_HEADERS([conf/config.h])
100100 AM_INIT_AUTOMAKE([serial-tests dist-bzip2 no-dist-gzip])
101101 AM_MAINTAINER_MODE
102102 AC_CANONICAL_HOST
537537
538538 # Checks for header files.
539539 AC_CHECK_HEADERS_ONCE([locale.h sys/select.h sys/uio.h argp.h stdint.h
540 unistd.h sys/time.h sys/types.h sys/stat.h])
540 unistd.h poll.h sys/time.h sys/types.h sys/stat.h])
541541
542542
543543 # Type checks.
544544 AC_C_INLINE
545 AC_C_FLEXIBLE_ARRAY_MEMBER
545546 AC_CHECK_SIZEOF(unsigned int)
546547 AC_SYS_LARGEFILE
547548 AC_TYPE_OFF_T
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # doc - Automake template
17 # Copyright (C) 2001, 2004 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = doc
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES =
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 AM_V_DVIPS = $(am__v_DVIPS_@AM_V@)
143 am__v_DVIPS_ = $(am__v_DVIPS_@AM_DEFAULT_V@)
144 am__v_DVIPS_0 = @echo " DVIPS " $@;
145 am__v_DVIPS_1 =
146 AM_V_MAKEINFO = $(am__v_MAKEINFO_@AM_V@)
147 am__v_MAKEINFO_ = $(am__v_MAKEINFO_@AM_DEFAULT_V@)
148 am__v_MAKEINFO_0 = @echo " MAKEINFO" $@;
149 am__v_MAKEINFO_1 =
150 AM_V_INFOHTML = $(am__v_INFOHTML_@AM_V@)
151 am__v_INFOHTML_ = $(am__v_INFOHTML_@AM_DEFAULT_V@)
152 am__v_INFOHTML_0 = @echo " INFOHTML" $@;
153 am__v_INFOHTML_1 =
154 AM_V_TEXI2DVI = $(am__v_TEXI2DVI_@AM_V@)
155 am__v_TEXI2DVI_ = $(am__v_TEXI2DVI_@AM_DEFAULT_V@)
156 am__v_TEXI2DVI_0 = @echo " TEXI2DVI" $@;
157 am__v_TEXI2DVI_1 =
158 AM_V_TEXI2PDF = $(am__v_TEXI2PDF_@AM_V@)
159 am__v_TEXI2PDF_ = $(am__v_TEXI2PDF_@AM_DEFAULT_V@)
160 am__v_TEXI2PDF_0 = @echo " TEXI2PDF" $@;
161 am__v_TEXI2PDF_1 =
162 AM_V_texinfo = $(am__v_texinfo_@AM_V@)
163 am__v_texinfo_ = $(am__v_texinfo_@AM_DEFAULT_V@)
164 am__v_texinfo_0 = -q
165 am__v_texinfo_1 =
166 AM_V_texidevnull = $(am__v_texidevnull_@AM_V@)
167 am__v_texidevnull_ = $(am__v_texidevnull_@AM_DEFAULT_V@)
168 am__v_texidevnull_0 = > /dev/null
169 am__v_texidevnull_1 =
170 INFO_DEPS = $(srcdir)/gpgme.info
171 TEXINFO_TEX = $(top_srcdir)/build-aux/texinfo.tex
172 am__TEXINFO_TEX_DIR = $(top_srcdir)/build-aux
173 DVIS = gpgme.dvi
174 PDFS = gpgme.pdf
175 PSS = gpgme.ps
176 HTMLS = gpgme.html
177 TEXINFOS = gpgme.texi
178 TEXI2DVI = texi2dvi
179 TEXI2PDF = $(TEXI2DVI) --pdf --batch
180 MAKEINFOHTML = $(MAKEINFO) --html
181 AM_MAKEINFOHTMLFLAGS = $(AM_MAKEINFOFLAGS)
182 DVIPS = dvips
183 am__can_run_installinfo = \
184 case $$AM_UPDATE_INFO_DIR in \
185 n|no|NO) false;; \
186 *) (install-info --version) >/dev/null 2>&1;; \
187 esac
188 am__installdirs = "$(DESTDIR)$(infodir)"
189 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
190 am__vpath_adj = case $$p in \
191 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
192 *) f=$$p;; \
193 esac;
194 am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
195 am__install_max = 40
196 am__nobase_strip_setup = \
197 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
198 am__nobase_strip = \
199 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
200 am__nobase_list = $(am__nobase_strip_setup); \
201 for p in $$list; do echo "$$p $$p"; done | \
202 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
203 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
204 if (++n[$$2] == $(am__install_max)) \
205 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
206 END { for (dir in files) print dir, files[dir] }'
207 am__base_list = \
208 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
209 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
210 am__uninstall_files_from_dir = { \
211 test -z "$$files" \
212 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
213 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
214 $(am__cd) "$$dir" && rm -f $$files; }; \
215 }
216 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
217 am__DIST_COMMON = $(gpgme_TEXINFOS) $(srcdir)/Makefile.in \
218 $(top_srcdir)/build-aux/mkinstalldirs \
219 $(top_srcdir)/build-aux/texinfo.tex mdate-sh texinfo.tex
220 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
221 ACLOCAL = @ACLOCAL@
222 AMTAR = @AMTAR@
223 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
224 AR = @AR@
225 AS = @AS@
226 AUTOCONF = @AUTOCONF@
227 AUTOHEADER = @AUTOHEADER@
228 AUTOMAKE = @AUTOMAKE@
229 AWK = @AWK@
230 BUILD_FILEVERSION = @BUILD_FILEVERSION@
231 BUILD_REVISION = @BUILD_REVISION@
232 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
233 BUILD_VERSION = @BUILD_VERSION@
234 CC = @CC@
235 CCDEPMODE = @CCDEPMODE@
236 CC_FOR_BUILD = @CC_FOR_BUILD@
237 CFLAGS = @CFLAGS@
238 CPP = @CPP@
239 CPPFLAGS = @CPPFLAGS@
240 CXX = @CXX@
241 CXXCPP = @CXXCPP@
242 CXXDEPMODE = @CXXDEPMODE@
243 CXXFLAGS = @CXXFLAGS@
244 CYGPATH_W = @CYGPATH_W@
245 DEFS = @DEFS@
246 DEPDIR = @DEPDIR@
247 DLLTOOL = @DLLTOOL@
248 DOXYGEN = @DOXYGEN@
249 DSYMUTIL = @DSYMUTIL@
250 DUMPBIN = @DUMPBIN@
251 ECHO_C = @ECHO_C@
252 ECHO_N = @ECHO_N@
253 ECHO_T = @ECHO_T@
254 EGREP = @EGREP@
255 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
256 EXEEXT = @EXEEXT@
257 FGREP = @FGREP@
258 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
259 GLIBC21 = @GLIBC21@
260 GLIB_CFLAGS = @GLIB_CFLAGS@
261 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
262 GLIB_LIBS = @GLIB_LIBS@
263 GLIB_MKENUMS = @GLIB_MKENUMS@
264 GOBJECT_QUERY = @GOBJECT_QUERY@
265 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
266 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
267 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
268 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
269 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
270 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
271 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
272 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
273 GPGME_QT_LIBS = @GPGME_QT_LIBS@
274 GPGRT_CONFIG = @GPGRT_CONFIG@
275 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
276 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
277 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
278 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
279 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
280 GRAPHVIZ = @GRAPHVIZ@
281 GREP = @GREP@
282 HAVE_CXX11 = @HAVE_CXX11@
283 HAVE_DOT = @HAVE_DOT@
284 INSTALL = @INSTALL@
285 INSTALL_DATA = @INSTALL_DATA@
286 INSTALL_PROGRAM = @INSTALL_PROGRAM@
287 INSTALL_SCRIPT = @INSTALL_SCRIPT@
288 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
289 LD = @LD@
290 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
291 LDFLAGS = @LDFLAGS@
292 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
293 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
294 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
295 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
296 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
297 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
298 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
299 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
300 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
301 LIBOBJS = @LIBOBJS@
302 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
303 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
304 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
305 LIBS = @LIBS@
306 LIBTOOL = @LIBTOOL@
307 LIPO = @LIPO@
308 LN_S = @LN_S@
309 LTLIBOBJS = @LTLIBOBJS@
310 MAINT = @MAINT@
311 MAKEINFO = @MAKEINFO@
312 MANIFEST_TOOL = @MANIFEST_TOOL@
313 MKDIR_P = @MKDIR_P@
314 MOC = @MOC@
315 MOC2 = @MOC2@
316 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
317 NM = @NM@
318 NMEDIT = @NMEDIT@
319 OBJDUMP = @OBJDUMP@
320 OBJEXT = @OBJEXT@
321 OTOOL = @OTOOL@
322 OTOOL64 = @OTOOL64@
323 PACKAGE = @PACKAGE@
324 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
325 PACKAGE_NAME = @PACKAGE_NAME@
326 PACKAGE_STRING = @PACKAGE_STRING@
327 PACKAGE_TARNAME = @PACKAGE_TARNAME@
328 PACKAGE_URL = @PACKAGE_URL@
329 PACKAGE_VERSION = @PACKAGE_VERSION@
330 PATH_SEPARATOR = @PATH_SEPARATOR@
331 PKG_CONFIG = @PKG_CONFIG@
332 PYTHON = @PYTHON@
333 PYTHONS = @PYTHONS@
334 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
335 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
336 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
337 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
338 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
339 PYTHON_PLATFORM = @PYTHON_PLATFORM@
340 PYTHON_PREFIX = @PYTHON_PREFIX@
341 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
342 PYTHON_VERSION = @PYTHON_VERSION@
343 QTCHOOSER = @QTCHOOSER@
344 RANLIB = @RANLIB@
345 RC = @RC@
346 SED = @SED@
347 SET_MAKE = @SET_MAKE@
348 SHELL = @SHELL@
349 STRIP = @STRIP@
350 SWIG = @SWIG@
351 SWIG_LIB = @SWIG_LIB@
352 SYSROOT = @SYSROOT@
353 VERSION = @VERSION@
354 VERSION_MAJOR = @VERSION_MAJOR@
355 VERSION_MICRO = @VERSION_MICRO@
356 VERSION_MINOR = @VERSION_MINOR@
357 VERSION_NUMBER = @VERSION_NUMBER@
358 abs_builddir = @abs_builddir@
359 abs_srcdir = @abs_srcdir@
360 abs_top_builddir = @abs_top_builddir@
361 abs_top_srcdir = @abs_top_srcdir@
362 ac_ct_AR = @ac_ct_AR@
363 ac_ct_CC = @ac_ct_CC@
364 ac_ct_CXX = @ac_ct_CXX@
365 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
366 am__include = @am__include@
367 am__leading_dot = @am__leading_dot@
368 am__quote = @am__quote@
369 am__tar = @am__tar@
370 am__untar = @am__untar@
371 bindir = @bindir@
372 build = @build@
373 build_alias = @build_alias@
374 build_cpu = @build_cpu@
375 build_os = @build_os@
376 build_vendor = @build_vendor@
377 builddir = @builddir@
378 datadir = @datadir@
379 datarootdir = @datarootdir@
380 docdir = @docdir@
381 dvidir = @dvidir@
382 emacs_local_vars_begin = @emacs_local_vars_begin@
383 emacs_local_vars_end = @emacs_local_vars_end@
384 emacs_local_vars_read_only = @emacs_local_vars_read_only@
385 exec_prefix = @exec_prefix@
386 host = @host@
387 host_alias = @host_alias@
388 host_cpu = @host_cpu@
389 host_os = @host_os@
390 host_vendor = @host_vendor@
391 htmldir = @htmldir@
392 includedir = @includedir@
393 infodir = @infodir@
394 install_sh = @install_sh@
395 libdir = @libdir@
396 libexecdir = @libexecdir@
397 localedir = @localedir@
398 localstatedir = @localstatedir@
399 mandir = @mandir@
400 mkdir_p = @mkdir_p@
401 oldincludedir = @oldincludedir@
402 pdfdir = @pdfdir@
403 pkgpyexecdir = @pkgpyexecdir@
404 pkgpythondir = @pkgpythondir@
405 prefix = @prefix@
406 program_transform_name = @program_transform_name@
407 psdir = @psdir@
408 pyexecdir = @pyexecdir@
409 pythondir = @pythondir@
410 runstatedir = @runstatedir@
411 sbindir = @sbindir@
412 sharedstatedir = @sharedstatedir@
413 srcdir = @srcdir@
414 sysconfdir = @sysconfdir@
415 target_alias = @target_alias@
416 top_build_prefix = @top_build_prefix@
417 top_builddir = @top_builddir@
418 top_srcdir = @top_srcdir@
419 DISTCLEANFILES = gpgme.tmp
420 CLEANFILES = mkdefsinc defs.inc
421 EXTRA_DIST = module-overview.sk HACKING DCO ChangeLog-2011 \
422 mkdefsinc.c defsincdate \
423 examples/gpgme-mozilla.json examples/gpgme-chrome.json
424
425 BUILT_SOURCES = defsincdate defs.inc
426 info_TEXINFOS = gpgme.texi
427 gpgme_TEXINFOS = uiserver.texi lesser.texi gpl.texi
428 all: $(BUILT_SOURCES)
429 $(MAKE) $(AM_MAKEFLAGS) all-am
430
431 .SUFFIXES:
432 .SUFFIXES: .dvi .html .info .pdf .ps .texi
433 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
434 @for dep in $?; do \
435 case '$(am__configure_deps)' in \
436 *$$dep*) \
437 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
438 && { if test -f $@; then exit 0; else break; fi; }; \
439 exit 1;; \
440 esac; \
441 done; \
442 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu doc/Makefile'; \
443 $(am__cd) $(top_srcdir) && \
444 $(AUTOMAKE) --gnu doc/Makefile
445 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
446 @case '$?' in \
447 *config.status*) \
448 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
449 *) \
450 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
451 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
452 esac;
453
454 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
455 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
456
457 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
458 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
459 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
460 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
461 $(am__aclocal_m4_deps):
462
463 mostlyclean-libtool:
464 -rm -f *.lo
465
466 clean-libtool:
467 -rm -rf .libs _libs
468
469 .texi.info:
470 $(AM_V_MAKEINFO)restore=: && backupdir="$(am__leading_dot)am$$$$" && \
471 am__cwd=`pwd` && $(am__cd) $(srcdir) && \
472 rm -rf $$backupdir && mkdir $$backupdir && \
473 if ($(MAKEINFO) --version) >/dev/null 2>&1; then \
474 for f in $@ $@-[0-9] $@-[0-9][0-9] $(@:.info=).i[0-9] $(@:.info=).i[0-9][0-9]; do \
475 if test -f $$f; then mv $$f $$backupdir; restore=mv; else :; fi; \
476 done; \
477 else :; fi && \
478 cd "$$am__cwd"; \
479 if $(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
480 -o $@ $<; \
481 then \
482 rc=0; \
483 $(am__cd) $(srcdir); \
484 else \
485 rc=$$?; \
486 $(am__cd) $(srcdir) && \
487 $$restore $$backupdir/* `echo "./$@" | sed 's|[^/]*$$||'`; \
488 fi; \
489 rm -rf $$backupdir; exit $$rc
490
491 .texi.dvi:
492 $(AM_V_TEXI2DVI)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
493 MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
494 $(TEXI2DVI) $(AM_V_texinfo) --build-dir=$(@:.dvi=.t2d) -o $@ $(AM_V_texidevnull) \
495 $<
496
497 .texi.pdf:
498 $(AM_V_TEXI2PDF)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
499 MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
500 $(TEXI2PDF) $(AM_V_texinfo) --build-dir=$(@:.pdf=.t2p) -o $@ $(AM_V_texidevnull) \
501 $<
502
503 .texi.html:
504 $(AM_V_MAKEINFO)rm -rf $(@:.html=.htp)
505 $(AM_V_at)if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
506 -o $(@:.html=.htp) $<; \
507 then \
508 rm -rf $@ && mv $(@:.html=.htp) $@; \
509 else \
510 rm -rf $(@:.html=.htp); exit 1; \
511 fi
512 $(srcdir)/gpgme.info: gpgme.texi $(gpgme_TEXINFOS)
513 gpgme.dvi: gpgme.texi $(gpgme_TEXINFOS)
514 gpgme.pdf: gpgme.texi $(gpgme_TEXINFOS)
515 gpgme.html: gpgme.texi $(gpgme_TEXINFOS)
516 .dvi.ps:
517 $(AM_V_DVIPS)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
518 $(DVIPS) $(AM_V_texinfo) -o $@ $<
519
520 uninstall-dvi-am:
521 @$(NORMAL_UNINSTALL)
522 @list='$(DVIS)'; test -n "$(dvidir)" || list=; \
523 for p in $$list; do \
524 $(am__strip_dir) \
525 echo " rm -f '$(DESTDIR)$(dvidir)/$$f'"; \
526 rm -f "$(DESTDIR)$(dvidir)/$$f"; \
527 done
528
529 uninstall-html-am:
530 @$(NORMAL_UNINSTALL)
531 @list='$(HTMLS)'; test -n "$(htmldir)" || list=; \
532 for p in $$list; do \
533 $(am__strip_dir) \
534 echo " rm -rf '$(DESTDIR)$(htmldir)/$$f'"; \
535 rm -rf "$(DESTDIR)$(htmldir)/$$f"; \
536 done
537
538 uninstall-info-am:
539 @$(PRE_UNINSTALL)
540 @if test -d '$(DESTDIR)$(infodir)' && $(am__can_run_installinfo); then \
541 list='$(INFO_DEPS)'; \
542 for file in $$list; do \
543 relfile=`echo "$$file" | sed 's|^.*/||'`; \
544 echo " install-info --info-dir='$(DESTDIR)$(infodir)' --remove '$(DESTDIR)$(infodir)/$$relfile'"; \
545 if install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$$relfile"; \
546 then :; else test ! -f "$(DESTDIR)$(infodir)/$$relfile" || exit 1; fi; \
547 done; \
548 else :; fi
549 @$(NORMAL_UNINSTALL)
550 @list='$(INFO_DEPS)'; \
551 for file in $$list; do \
552 relfile=`echo "$$file" | sed 's|^.*/||'`; \
553 relfile_i=`echo "$$relfile" | sed 's|\.info$$||;s|$$|.i|'`; \
554 (if test -d "$(DESTDIR)$(infodir)" && cd "$(DESTDIR)$(infodir)"; then \
555 echo " cd '$(DESTDIR)$(infodir)' && rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]"; \
556 rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]; \
557 else :; fi); \
558 done
559
560 uninstall-pdf-am:
561 @$(NORMAL_UNINSTALL)
562 @list='$(PDFS)'; test -n "$(pdfdir)" || list=; \
563 for p in $$list; do \
564 $(am__strip_dir) \
565 echo " rm -f '$(DESTDIR)$(pdfdir)/$$f'"; \
566 rm -f "$(DESTDIR)$(pdfdir)/$$f"; \
567 done
568
569 uninstall-ps-am:
570 @$(NORMAL_UNINSTALL)
571 @list='$(PSS)'; test -n "$(psdir)" || list=; \
572 for p in $$list; do \
573 $(am__strip_dir) \
574 echo " rm -f '$(DESTDIR)$(psdir)/$$f'"; \
575 rm -f "$(DESTDIR)$(psdir)/$$f"; \
576 done
577
578 dist-info: $(INFO_DEPS)
579 @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
580 list='$(INFO_DEPS)'; \
581 for base in $$list; do \
582 case $$base in \
583 $(srcdir)/*) base=`echo "$$base" | sed "s|^$$srcdirstrip/||"`;; \
584 esac; \
585 if test -f $$base; then d=.; else d=$(srcdir); fi; \
586 base_i=`echo "$$base" | sed 's|\.info$$||;s|$$|.i|'`; \
587 for file in $$d/$$base $$d/$$base-[0-9] $$d/$$base-[0-9][0-9] $$d/$$base_i[0-9] $$d/$$base_i[0-9][0-9]; do \
588 if test -f $$file; then \
589 relfile=`expr "$$file" : "$$d/\(.*\)"`; \
590 test -f "$(distdir)/$$relfile" || \
591 cp -p $$file "$(distdir)/$$relfile"; \
592 else :; fi; \
593 done; \
594 done
595
596 mostlyclean-aminfo:
597 -rm -rf gpgme.t2d gpgme.t2p
598
599 clean-aminfo:
600 -test -z "gpgme.dvi gpgme.pdf gpgme.ps gpgme.html" \
601 || rm -rf gpgme.dvi gpgme.pdf gpgme.ps gpgme.html
602
603 maintainer-clean-aminfo:
604 @list='$(INFO_DEPS)'; for i in $$list; do \
605 i_i=`echo "$$i" | sed 's|\.info$$||;s|$$|.i|'`; \
606 echo " rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]"; \
607 rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]; \
608 done
609 tags TAGS:
610
611 ctags CTAGS:
612
613 cscope cscopelist:
614
615
616 distdir: $(BUILT_SOURCES)
617 $(MAKE) $(AM_MAKEFLAGS) distdir-am
618
619 distdir-am: $(DISTFILES)
620 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
621 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
622 list='$(DISTFILES)'; \
623 dist_files=`for file in $$list; do echo $$file; done | \
624 sed -e "s|^$$srcdirstrip/||;t" \
625 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
626 case $$dist_files in \
627 */*) $(MKDIR_P) `echo "$$dist_files" | \
628 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
629 sort -u` ;; \
630 esac; \
631 for file in $$dist_files; do \
632 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
633 if test -d $$d/$$file; then \
634 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
635 if test -d "$(distdir)/$$file"; then \
636 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
637 fi; \
638 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
639 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
640 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
641 fi; \
642 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
643 else \
644 test -f "$(distdir)/$$file" \
645 || cp -p $$d/$$file "$(distdir)/$$file" \
646 || exit 1; \
647 fi; \
648 done
649 $(MAKE) $(AM_MAKEFLAGS) \
650 top_distdir="$(top_distdir)" distdir="$(distdir)" \
651 dist-info dist-hook
652 check-am: all-am
653 check: $(BUILT_SOURCES)
654 $(MAKE) $(AM_MAKEFLAGS) check-am
655 all-am: Makefile $(INFO_DEPS)
656 installdirs:
657 for dir in "$(DESTDIR)$(infodir)"; do \
658 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
659 done
660 install: $(BUILT_SOURCES)
661 $(MAKE) $(AM_MAKEFLAGS) install-am
662 install-exec: $(BUILT_SOURCES)
663 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
664 install-data: install-data-am
665 uninstall: uninstall-am
666
667 install-am: all-am
668 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
669
670 installcheck: installcheck-am
671 install-strip:
672 if test -z '$(STRIP)'; then \
673 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
674 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
675 install; \
676 else \
677 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
678 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
679 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
680 fi
681 mostlyclean-generic:
682
683 clean-generic:
684 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
685
686 distclean-generic:
687 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
688 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
689 -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
690
691 maintainer-clean-generic:
692 @echo "This command is intended for maintainers to use"
693 @echo "it deletes files that may require special tools to rebuild."
694 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
695 clean: clean-am
696
697 clean-am: clean-aminfo clean-generic clean-libtool mostlyclean-am
698
699 distclean: distclean-am
700 -rm -f Makefile
701 distclean-am: clean-am distclean-generic
702
703 dvi: dvi-am
704
705 dvi-am: $(DVIS)
706
707 html: html-am
708
709 html-am: $(HTMLS)
710
711 info: info-am
712
713 info-am: $(INFO_DEPS)
714
715 install-data-am: install-info-am
716
717 install-dvi: install-dvi-am
718
719 install-dvi-am: $(DVIS)
720 @$(NORMAL_INSTALL)
721 @list='$(DVIS)'; test -n "$(dvidir)" || list=; \
722 if test -n "$$list"; then \
723 echo " $(MKDIR_P) '$(DESTDIR)$(dvidir)'"; \
724 $(MKDIR_P) "$(DESTDIR)$(dvidir)" || exit 1; \
725 fi; \
726 for p in $$list; do \
727 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
728 echo "$$d$$p"; \
729 done | $(am__base_list) | \
730 while read files; do \
731 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(dvidir)'"; \
732 $(INSTALL_DATA) $$files "$(DESTDIR)$(dvidir)" || exit $$?; \
733 done
734 install-exec-am:
735
736 install-html: install-html-am
737
738 install-html-am: $(HTMLS)
739 @$(NORMAL_INSTALL)
740 @list='$(HTMLS)'; list2=; test -n "$(htmldir)" || list=; \
741 if test -n "$$list"; then \
742 echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \
743 $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \
744 fi; \
745 for p in $$list; do \
746 if test -f "$$p" || test -d "$$p"; then d=; else d="$(srcdir)/"; fi; \
747 $(am__strip_dir) \
748 d2=$$d$$p; \
749 if test -d "$$d2"; then \
750 echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)/$$f'"; \
751 $(MKDIR_P) "$(DESTDIR)$(htmldir)/$$f" || exit 1; \
752 echo " $(INSTALL_DATA) '$$d2'/* '$(DESTDIR)$(htmldir)/$$f'"; \
753 $(INSTALL_DATA) "$$d2"/* "$(DESTDIR)$(htmldir)/$$f" || exit $$?; \
754 else \
755 list2="$$list2 $$d2"; \
756 fi; \
757 done; \
758 test -z "$$list2" || { echo "$$list2" | $(am__base_list) | \
759 while read files; do \
760 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \
761 $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \
762 done; }
763 install-info: install-info-am
764
765 install-info-am: $(INFO_DEPS)
766 @$(NORMAL_INSTALL)
767 @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
768 list='$(INFO_DEPS)'; test -n "$(infodir)" || list=; \
769 if test -n "$$list"; then \
770 echo " $(MKDIR_P) '$(DESTDIR)$(infodir)'"; \
771 $(MKDIR_P) "$(DESTDIR)$(infodir)" || exit 1; \
772 fi; \
773 for file in $$list; do \
774 case $$file in \
775 $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
776 esac; \
777 if test -f $$file; then d=.; else d=$(srcdir); fi; \
778 file_i=`echo "$$file" | sed 's|\.info$$||;s|$$|.i|'`; \
779 for ifile in $$d/$$file $$d/$$file-[0-9] $$d/$$file-[0-9][0-9] \
780 $$d/$$file_i[0-9] $$d/$$file_i[0-9][0-9] ; do \
781 if test -f $$ifile; then \
782 echo "$$ifile"; \
783 else : ; fi; \
784 done; \
785 done | $(am__base_list) | \
786 while read files; do \
787 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(infodir)'"; \
788 $(INSTALL_DATA) $$files "$(DESTDIR)$(infodir)" || exit $$?; done
789 @$(POST_INSTALL)
790 @if $(am__can_run_installinfo); then \
791 list='$(INFO_DEPS)'; test -n "$(infodir)" || list=; \
792 for file in $$list; do \
793 relfile=`echo "$$file" | sed 's|^.*/||'`; \
794 echo " install-info --info-dir='$(DESTDIR)$(infodir)' '$(DESTDIR)$(infodir)/$$relfile'";\
795 install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$$relfile" || :;\
796 done; \
797 else : ; fi
798 install-man:
799
800 install-pdf: install-pdf-am
801
802 install-pdf-am: $(PDFS)
803 @$(NORMAL_INSTALL)
804 @list='$(PDFS)'; test -n "$(pdfdir)" || list=; \
805 if test -n "$$list"; then \
806 echo " $(MKDIR_P) '$(DESTDIR)$(pdfdir)'"; \
807 $(MKDIR_P) "$(DESTDIR)$(pdfdir)" || exit 1; \
808 fi; \
809 for p in $$list; do \
810 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
811 echo "$$d$$p"; \
812 done | $(am__base_list) | \
813 while read files; do \
814 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pdfdir)'"; \
815 $(INSTALL_DATA) $$files "$(DESTDIR)$(pdfdir)" || exit $$?; done
816 install-ps: install-ps-am
817
818 install-ps-am: $(PSS)
819 @$(NORMAL_INSTALL)
820 @list='$(PSS)'; test -n "$(psdir)" || list=; \
821 if test -n "$$list"; then \
822 echo " $(MKDIR_P) '$(DESTDIR)$(psdir)'"; \
823 $(MKDIR_P) "$(DESTDIR)$(psdir)" || exit 1; \
824 fi; \
825 for p in $$list; do \
826 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
827 echo "$$d$$p"; \
828 done | $(am__base_list) | \
829 while read files; do \
830 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(psdir)'"; \
831 $(INSTALL_DATA) $$files "$(DESTDIR)$(psdir)" || exit $$?; done
832 installcheck-am:
833
834 maintainer-clean: maintainer-clean-am
835 -rm -f Makefile
836 maintainer-clean-am: distclean-am maintainer-clean-aminfo \
837 maintainer-clean-generic
838
839 mostlyclean: mostlyclean-am
840
841 mostlyclean-am: mostlyclean-aminfo mostlyclean-generic \
842 mostlyclean-libtool
843
844 pdf: pdf-am
845
846 pdf-am: $(PDFS)
847
848 ps: ps-am
849
850 ps-am: $(PSS)
851
852 uninstall-am: uninstall-dvi-am uninstall-html-am uninstall-info-am \
853 uninstall-pdf-am uninstall-ps-am
854
855 .MAKE: all check install install-am install-exec install-strip
856
857 .PHONY: all all-am check check-am clean clean-aminfo clean-generic \
858 clean-libtool cscopelist-am ctags-am dist-hook dist-info \
859 distclean distclean-generic distclean-libtool distdir dvi \
860 dvi-am html html-am info info-am install install-am \
861 install-data install-data-am install-dvi install-dvi-am \
862 install-exec install-exec-am install-html install-html-am \
863 install-info install-info-am install-man install-pdf \
864 install-pdf-am install-ps install-ps-am install-strip \
865 installcheck installcheck-am installdirs maintainer-clean \
866 maintainer-clean-aminfo maintainer-clean-generic mostlyclean \
867 mostlyclean-aminfo mostlyclean-generic mostlyclean-libtool pdf \
868 pdf-am ps ps-am tags-am uninstall uninstall-am \
869 uninstall-dvi-am uninstall-html-am uninstall-info-am \
870 uninstall-pdf-am uninstall-ps-am
871
872 .PRECIOUS: Makefile
873
874
875 gpgme.texi : defs.inc
876
877 mkdefsinc: mkdefsinc.c Makefile $(top_builddir)/conf/config.h
878 $(CC_FOR_BUILD) -I. -I$(top_builddir)/conf -I$(srcdir) \
879 $(AM_CPPFLAGS) -o $@ $(srcdir)/mkdefsinc.c
880
881 dist-hook: defsincdate
882
883 defsincdate: $(gpgme_TEXINFOS)
884 : >defsincdate ; \
885 if test -e $(top_srcdir)/.git; then \
886 (cd $(srcdir) && git log -1 --format='%ct' -- \
887 $(info_TEXINFOS) $(gpgme_TEXINFOS) 2>/dev/null) >>defsincdate; \
888 fi
889
890 defs.inc: defsincdate Makefile mkdefsinc
891 incd="`test -f defsincdate || echo '$(srcdir)/'`defsincdate"; \
892 ./mkdefsinc -C $(srcdir) --date "`cat $$incd 2>/dev/null`" \
893 $(info_TEXINFOS) $(gpgme_TEXINFOS) >$@
894
895 online: gpgme.html gpgme.pdf
896 set -e; \
897 echo "Uploading current manuals to www.gnupg.org ..."; \
898 user=werner ; \
899 (cd gpgme.html && rsync -vr --exclude='.svn' . \
900 $${user}@ftp.gnupg.org:webspace/manuals/gpgme/ ); \
901 rsync -v gpgme.pdf $${user}@ftp.gnupg.org:webspace/manuals/
902
903 # Tell versions [3.59,3.63) of GNU make to not export all variables.
904 # Otherwise a system limit (for SysV at least) may be exceeded.
905 .NOEXPORT:
0 1624372503
0 1643900190
0 This is gpgme.info, produced by makeinfo version 6.5 from gpgme.texi.
1
2 Copyright © 2002–2008, 2010, 2012–2018 g10 Code GmbH.
3
4 Permission is granted to copy, distribute and/or modify this
5 document under the terms of the GNU General Public License as
6 published by the Free Software Foundation; either version 3 of the
7 License, or (at your option) any later version. The text of the
8 license can be found in the section entitled “Copying”.
9
10 This document is distributed in the hope that it will be useful, but
11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
13 Public License for more details.
14 INFO-DIR-SECTION GNU Libraries
15 START-INFO-DIR-ENTRY
16 * GPGME: (gpgme). Adding support for cryptography to your program.
17 END-INFO-DIR-ENTRY
18
19 This file documents the GPGME library.
20
21 This is Edition 1.17.0, last updated 3 February 2022, of ‘The ‘GnuPG
22 Made Easy’ Reference Manual’, for Version 1.17.0.
23
24 Copyright © 2002–2008, 2010, 2012–2018 g10 Code GmbH.
25
26 Permission is granted to copy, distribute and/or modify this
27 document under the terms of the GNU General Public License as
28 published by the Free Software Foundation; either version 3 of the
29 License, or (at your option) any later version. The text of the
30 license can be found in the section entitled “Copying”.
31
32 This document is distributed in the hope that it will be useful, but
33 WITHOUT ANY WARRANTY; without even the implied warranty of
34 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
35 Public License for more details.
36
37 
38 Indirect:
39 gpgme.info-1: 1673
40 gpgme.info-2: 303842
41 
42 Tag Table:
43 (Indirect)
44 Node: Top1673
45 Node: Introduction9037
46 Node: Getting Started9827
47 Node: Features11288
48 Node: Overview12600
49 Node: Preparation13709
50 Node: Header14706
51 Node: Building the Source15453
52 Node: Largefile Support (LFS)17597
53 Node: Using Automake23013
54 Node: Using Libtool25566
55 Node: Library Version Check25928
56 Node: Signal Handling31988
57 Node: Multi-Threading33258
58 Ref: Multi-Threading-Footnote-134674
59 Node: Protocols and Engines35097
60 Node: Engine Version Check37848
61 Node: Engine Information40731
62 Node: Engine Configuration44591
63 Node: OpenPGP45895
64 Node: Cryptographic Message Syntax46235
65 Node: Assuan46548
66 Node: Algorithms46922
67 Ref: Algorithms-Footnote-147401
68 Node: Public Key Algorithms47529
69 Node: Hash Algorithms50131
70 Node: Error Handling51345
71 Node: Error Values53219
72 Node: Error Sources58422
73 Node: Error Codes60862
74 Node: Error Strings65655
75 Node: Exchanging Data67462
76 Node: Creating Data Buffers69347
77 Node: Memory Based Data Buffers69863
78 Node: File Based Data Buffers73296
79 Node: Callback Based Data Buffers76409
80 Node: Destroying Data Buffers80600
81 Node: Manipulating Data Buffers82107
82 Node: Data Buffer I/O Operations82599
83 Node: Data Buffer Meta-Data84972
84 Node: Data Buffer Convenience90291
85 Node: Contexts92511
86 Node: Creating Contexts93630
87 Node: Destroying Contexts94477
88 Node: Result Management94816
89 Node: Context Attributes96397
90 Node: Protocol Selection97564
91 Node: Crypto Engine98610
92 Node: Setting the Sender100499
93 Node: ASCII Armor102012
94 Node: Text Mode102641
95 Node: Offline Mode103575
96 Node: Pinentry Mode105073
97 Node: Included Certificates106967
98 Node: Key Listing Mode108413
99 Node: Passphrase Callback113537
100 Node: Progress Meter Callback117099
101 Node: Status Message Callback119084
102 Node: Context Flags120849
103 Node: Locale128340
104 Node: Additional Logs129932
105 Node: Key Management132130
106 Node: Key objects133354
107 Node: Listing Keys148360
108 Node: Information About Keys157013
109 Node: Manipulating Keys158321
110 Node: Generating Keys161219
111 Node: Signing Keys179539
112 Node: Exporting Keys185298
113 Node: Importing Keys192887
114 Ref: Importing Keys-Footnote-1201753
115 Node: Deleting Keys201881
116 Node: Changing Passphrases204161
117 Node: Changing TOFU Data205488
118 Node: Advanced Key Editing207596
119 Node: Crypto Operations210329
120 Node: Decrypt211586
121 Node: Verify218866
122 Node: Decrypt and Verify231959
123 Node: Sign234814
124 Node: Selecting Signers235378
125 Node: Creating a Signature236784
126 Node: Signature Notation Data241554
127 Node: Encrypt243839
128 Node: Encrypting a Plaintext244195
129 Node: Miscellaneous258607
130 Node: Running other Programs259019
131 Node: Using the Assuan protocol261182
132 Node: Checking for updates263980
133 Node: Run Control268797
134 Node: Waiting For Completion269541
135 Node: Using External Event Loops271666
136 Node: I/O Callback Interface273638
137 Node: Registering I/O Callbacks278566
138 Node: I/O Callback Example280605
139 Node: I/O Callback Example GTK+287230
140 Node: I/O Callback Example GDK289019
141 Node: I/O Callback Example Qt290661
142 Node: Cancellation292949
143 Node: UI Server Protocol295257
144 Ref: UI Server Protocol-Footnote-1296692
145 Node: UI Server Encrypt296811
146 Node: UI Server Sign303842
147 Node: UI Server Decrypt306195
148 Node: UI Server Verify307850
149 Node: UI Server Set Input Files311422
150 Node: UI Server Sign/Encrypt Files312492
151 Node: UI Server Verify/Decrypt Files314300
152 Node: UI Server Import/Export Keys316176
153 Node: UI Server Checksum Files317238
154 Node: Miscellaneous UI Server Commands319456
155 Ref: command SENDER321387
156 Node: Debugging323089
157 Node: Deprecated Functions324838
158 Node: Library Copying347847
159 Node: Copying376067
160 Node: Concept Index413817
161 Node: Function and Data Index428529
162 
163 End Tag Table
164
165 
166 Local Variables:
167 coding: utf-8
168 End:
0 This is gpgme.info, produced by makeinfo version 6.5 from gpgme.texi.
1
2 Copyright © 2002–2008, 2010, 2012–2018 g10 Code GmbH.
3
4 Permission is granted to copy, distribute and/or modify this
5 document under the terms of the GNU General Public License as
6 published by the Free Software Foundation; either version 3 of the
7 License, or (at your option) any later version. The text of the
8 license can be found in the section entitled “Copying”.
9
10 This document is distributed in the hope that it will be useful, but
11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
13 Public License for more details.
14 INFO-DIR-SECTION GNU Libraries
15 START-INFO-DIR-ENTRY
16 * GPGME: (gpgme). Adding support for cryptography to your program.
17 END-INFO-DIR-ENTRY
18
19 This file documents the GPGME library.
20
21 This is Edition 1.17.0, last updated 3 February 2022, of ‘The ‘GnuPG
22 Made Easy’ Reference Manual’, for Version 1.17.0.
23
24 Copyright © 2002–2008, 2010, 2012–2018 g10 Code GmbH.
25
26 Permission is granted to copy, distribute and/or modify this
27 document under the terms of the GNU General Public License as
28 published by the Free Software Foundation; either version 3 of the
29 License, or (at your option) any later version. The text of the
30 license can be found in the section entitled “Copying”.
31
32 This document is distributed in the hope that it will be useful, but
33 WITHOUT ANY WARRANTY; without even the implied warranty of
34 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
35 Public License for more details.
36
37 
38 File: gpgme.info, Node: Top, Next: Introduction, Up: (dir)
39
40 Main Menu
41 *********
42
43 This is Edition 1.17.0, last updated 3 February 2022, of ‘The ‘GnuPG
44 Made Easy’ Reference Manual’, for Version 1.17.0 of the GPGME library.
45
46 * Menu:
47
48 * Introduction:: How to use this manual.
49 * Preparation:: What you should do before using the library.
50 * Protocols and Engines:: Supported crypto protocols.
51 * Algorithms:: Supported algorithms.
52 * Error Handling:: Error numbers and their meanings.
53 * Exchanging Data:: Passing data to and from GPGME.
54 * Contexts:: Handling GPGME contexts.
55
56 Appendices
57
58 * UI Server Protocol:: The GnuPG UI Server Protocol.
59 * Debugging:: How to solve problems.
60 * Deprecated Functions:: Documentation of deprecated functions.
61
62 * Library Copying:: The GNU Lesser General Public License says
63 how you can copy and share ‘GnuPG Made Easy’.
64 * Copying:: The GNU General Public License says how you
65 can copy and share this manual.
66
67 Indices
68
69 * Concept Index:: Index of concepts and programs.
70 * Function and Data Index:: Index of functions, variables and data types.
71
72 — The Detailed Node Listing —
73
74 Introduction
75
76 * Getting Started:: Purpose of the manual, and how to use it.
77 * Features:: Reasons to install and use GPGME.
78 * Overview:: Basic architecture of the GPGME library.
79
80 Preparation
81
82 * Header:: What header file you need to include.
83 * Building the Source:: Compiler options to be used.
84 * Largefile Support (LFS):: How to use GPGME with LFS.
85 * Using Automake:: Compiler options to be used the easy way.
86 * Using Libtool:: Avoiding compiler options entirely.
87 * Library Version Check:: Getting and verifying the library version.
88 * Signal Handling:: How GPGME affects signal handling.
89 * Multi-Threading:: How GPGME can be used in an MT environment.
90
91 Protocols and Engines
92
93 * Engine Version Check:: Verifying the engine version.
94 * Engine Information:: Obtaining more information about the engines.
95 * Engine Configuration:: Changing the engine configuration.
96 * OpenPGP:: Support for the OpenPGP protocol.
97 * Cryptographic Message Syntax:: Support for the CMS.
98
99 Algorithms
100
101 * Public Key Algorithms:: A list of all public key algorithms.
102 * Hash Algorithms:: A list of all hash algorithms.
103
104 Error Handling
105
106 * Error Values:: The error value and what it means.
107 * Error Codes:: A list of important error codes.
108 * Error Sources:: A list of important error sources.
109 * Error Strings:: How to get a descriptive string from a value.
110
111 Exchanging Data
112
113 * Creating Data Buffers:: Creating new data buffers.
114 * Destroying Data Buffers:: Releasing data buffers.
115 * Manipulating Data Buffers:: Operations on data buffers.
116
117 Creating Data Buffers
118
119 * Memory Based Data Buffers:: Creating memory based data buffers.
120 * File Based Data Buffers:: Creating file based data buffers.
121 * Callback Based Data Buffers:: Creating callback based data buffers.
122
123 Manipulating Data Buffers
124
125 * Data Buffer I/O Operations:: I/O operations on data buffers.
126 * Data Buffer Meta-Data:: Meta-data manipulation of data buffers.
127 * Data Buffer Convenience:: Convenience function for data buffers.
128
129 Contexts
130
131 * Creating Contexts:: Creating new GPGME contexts.
132 * Destroying Contexts:: Releasing GPGME contexts.
133 * Result Management:: Managing the result of crypto operations.
134 * Context Attributes:: Setting properties of a context.
135 * Key Management:: Managing keys with GPGME.
136 * Crypto Operations:: Using a context for cryptography.
137 * Miscellaneous:: Miscellaneous operations.
138 * Run Control:: Controlling how operations are run.
139
140 Context Attributes
141
142 * Protocol Selection:: Selecting the protocol used by a context.
143 * Crypto Engine:: Configuring the crypto engine.
144 * Setting the Sender:: How to tell the engine the sender.
145 * ASCII Armor:: Requesting ASCII armored output.
146 * Text Mode:: Choosing canonical text mode.
147 * Offline Mode:: Choosing offline mode.
148 * Included Certificates:: Including a number of certificates.
149 * Key Listing Mode:: Selecting key listing mode.
150 * Passphrase Callback:: Getting the passphrase from the user.
151 * Progress Meter Callback:: Being informed about the progress.
152 * Status Message Callback:: Status messages received from gpg.
153 * Locale:: Setting the locale of a context.
154
155 Key Management
156
157 * Key objects:: Description of the key structures.
158 * Listing Keys:: Browsing the list of available keys.
159 * Information About Keys:: Requesting detailed information about keys.
160 * Manipulating Keys:: Operations on keys.
161 * Generating Keys:: Creating new key pairs.
162 * Signing Keys:: Adding key signatures to public keys.
163 * Exporting Keys:: Retrieving key data from the key ring.
164 * Importing Keys:: Adding keys to the key ring.
165 * Deleting Keys:: Removing keys from the key ring.
166 * Changing Passphrases:: Change the passphrase of a key.
167 * Changing TOFU Data:: Changing data pertaining to TOFU.
168 * Advanced Key Editing:: Advanced key edit operation.
169
170 Crypto Operations
171
172 * Decrypt:: Decrypting a ciphertext.
173 * Verify:: Verifying a signature.
174 * Decrypt and Verify:: Decrypting a signed ciphertext.
175 * Sign:: Creating a signature.
176 * Encrypt:: Encrypting a plaintext.
177
178 Sign
179
180 * Selecting Signers:: How to choose the keys to sign with.
181 * Creating a Signature:: How to create a signature.
182 * Signature Notation Data:: How to add notation data to a signature.
183
184 Encrypt
185
186 * Encrypting a Plaintext:: How to encrypt a plaintext.
187
188 Miscellaneous
189
190 * Running other Programs:: Running other Programs.
191 * Using the Assuan protocol:: Using the Assuan protocol.
192 * Checking for updates:: How to check for software updates.
193
194 Run Control
195
196 * Waiting For Completion:: Waiting until an operation is completed.
197 * Using External Event Loops:: Advanced control over what happens when.
198 * Cancellation:: How to end pending operations prematurely.
199
200 Using External Event Loops
201
202 * I/O Callback Interface:: How I/O callbacks are registered.
203 * Registering I/O Callbacks:: How to use I/O callbacks for a context.
204 * I/O Callback Example:: An example how to use I/O callbacks.
205 * I/O Callback Example GTK+:: How to integrate GPGME in GTK+.
206 * I/O Callback Example GDK:: How to integrate GPGME in GDK.
207 * I/O Callback Example Qt:: How to integrate GPGME in Qt.
208
209
210 
211 File: gpgme.info, Node: Introduction, Next: Preparation, Prev: Top, Up: Top
212
213 1 Introduction
214 **************
215
216 ‘GnuPG Made Easy’ (GPGME) is a C language library that allows to add
217 support for cryptography to a program. It is designed to make access to
218 public key crypto engines like GnuPG or GpgSM easier for applications.
219 GPGME provides a high-level crypto API for encryption, decryption,
220 signing, signature verification and key management.
221
222 GPGME uses GnuPG and GpgSM as its backends to support OpenPGP and the
223 Cryptographic Message Syntax (CMS).
224
225 * Menu:
226
227 * Getting Started:: Purpose of the manual, and how to use it.
228 * Features:: Reasons to install and use GPGME.
229 * Overview:: Basic architecture of the GPGME library.
230
231 
232 File: gpgme.info, Node: Getting Started, Next: Features, Up: Introduction
233
234 1.1 Getting Started
235 ===================
236
237 This manual documents the GPGME library programming interface. All
238 functions and data types provided by the library are explained.
239
240 The reader is assumed to possess basic knowledge about cryptography
241 in general, and public key cryptography in particular. The underlying
242 cryptographic engines that are used by the library are not explained,
243 but where necessary, special features or requirements by an engine are
244 mentioned as far as they are relevant to GPGME or its users.
245
246 This manual can be used in several ways. If read from the beginning
247 to the end, it gives a good introduction into the library and how it can
248 be used in an application. Forward references are included where
249 necessary. Later on, the manual can be used as a reference manual to
250 get just the information needed about any particular interface of the
251 library. Experienced programmers might want to start looking at the
252 examples at the end of the manual, and then only read up those parts of
253 the interface which are unclear.
254
255 The documentation for the language bindings is currently not included
256 in this manual. Those languages bindings follow the general programming
257 model of GPGME but may provide some extra high level abstraction on top
258 of the GPGME style API. For now please see the README files in the
259 ‘lang/’ directory of the source distribution.
260
261 
262 File: gpgme.info, Node: Features, Next: Overview, Prev: Getting Started, Up: Introduction
263
264 1.2 Features
265 ============
266
267 GPGME has a couple of advantages over other libraries doing a similar
268 job, and over implementing support for GnuPG or other crypto engines
269 into your application directly.
270
271 it’s free software
272 Anybody can use, modify, and redistribute it under the terms of the
273 GNU Lesser General Public License (*note Library Copying::).
274
275 it’s flexible
276 GPGME provides transparent support for several cryptographic
277 protocols by different engines. Currently, GPGME supports the
278 OpenPGP protocol using GnuPG as the backend, and the Cryptographic
279 Message Syntax using GpgSM as the backend.
280
281 it’s easy
282 GPGME hides the differences between the protocols and engines from
283 the programmer behind an easy-to-use interface. This way the
284 programmer can focus on the other parts of the program, and still
285 integrate strong cryptography in his application. Once support for
286 GPGME has been added to a program, it is easy to add support for
287 other crypto protocols once GPGME backends provide them.
288
289 it’s language friendly
290 GPGME comes with languages bindings for several common programming
291 languages: Common Lisp, C++, Python 2, and Python 3.
292
293 
294 File: gpgme.info, Node: Overview, Prev: Features, Up: Introduction
295
296 1.3 Overview
297 ============
298
299 GPGME provides a data abstraction that is used to pass data to the
300 crypto engine, and receive returned data from it. Data can be read from
301 memory or from files, but it can also be provided by a callback
302 function.
303
304 The actual cryptographic operations are always set within a context.
305 A context provides configuration parameters that define the behaviour of
306 all operations performed within it. Only one operation per context is
307 allowed at any time, but when one operation is finished, you can run the
308 next operation in the same context. There can be more than one context,
309 and all can run different operations at the same time.
310
311 Furthermore, GPGME has rich key management facilities including
312 listing keys, querying their attributes, generating, importing,
313 exporting and deleting keys, and acquiring information about the trust
314 path.
315
316 With some precautions, GPGME can be used in a multi-threaded
317 environment, although it is not completely thread safe and thus needs
318 the support of the application.
319
320 
321 File: gpgme.info, Node: Preparation, Next: Protocols and Engines, Prev: Introduction, Up: Top
322
323 2 Preparation
324 *************
325
326 To use GPGME, you have to perform some changes to your sources and the
327 build system. The necessary changes are small and explained in the
328 following sections. At the end of this chapter, it is described how the
329 library is initialized, and how the requirements of the library are
330 verified.
331
332 * Menu:
333
334 * Header:: What header file you need to include.
335 * Building the Source:: Compiler options to be used.
336 * Largefile Support (LFS):: How to use GPGME with LFS.
337 * Using Automake:: Compiler options to be used the easy way.
338 * Using Libtool:: Avoiding compiler options entirely.
339 * Library Version Check:: Getting and verifying the library version.
340 * Signal Handling:: How GPGME affects signal handling.
341 * Multi-Threading:: How GPGME can be used in an MT environment.
342
343 
344 File: gpgme.info, Node: Header, Next: Building the Source, Up: Preparation
345
346 2.1 Header
347 ==========
348
349 All interfaces (data types and functions) of the library are defined in
350 the header file ‘gpgme.h’. You must include this in all programs using
351 the library, either directly or through some other header file, like
352 this:
353
354 #include <gpgme.h>
355
356 The name space of GPGME is ‘gpgme_*’ for function names and data
357 types and ‘GPGME_*’ for other symbols. Symbols internal to GPGME take
358 the form ‘_gpgme_*’ and ‘_GPGME_*’.
359
360 Because GPGME makes use of the GPG Error library, using GPGME will
361 also use the ‘GPG_ERR_*’ name space directly, and the ‘gpg_err*’,
362 ‘gpg_str*’, and ‘gpgrt_*’ name space indirectly.
363
364 
365 File: gpgme.info, Node: Building the Source, Next: Largefile Support (LFS), Prev: Header, Up: Preparation
366
367 2.2 Building the Source
368 =======================
369
370 If you want to compile a source file including the ‘gpgme.h’ header
371 file, you must make sure that the compiler can find it in the directory
372 hierarchy. This is accomplished by adding the path to the directory in
373 which the header file is located to the compilers include file search
374 path (via the ‘-I’ option).
375
376 However, the path to the include file is determined at the time the
377 source is configured. To solve this problem, gpgme ships with a small
378 helper program ‘gpgme-config’ that knows about the path to the include
379 file and other configuration options. The options that need to be added
380 to the compiler invocation at compile time are output by the ‘--cflags’
381 option to ‘gpgme-config’. The following example shows how it can be
382 used at the command line:
383
384 gcc -c foo.c `gpgme-config --cflags`
385
386 Adding the output of ‘gpgme-config --cflags’ to the compiler command
387 line will ensure that the compiler can find the GPGME header file.
388
389 A similar problem occurs when linking the program with the library.
390 Again, the compiler has to find the library files. For this to work,
391 the path to the library files has to be added to the library search path
392 (via the ‘-L’ option). For this, the option ‘--libs’ to ‘gpgme-config’
393 can be used. For convenience, this option also outputs all other
394 options that are required to link the program with GPGME (in particular,
395 the ‘-lgpgme’ option). The example shows how to link ‘foo.o’ with the
396 GPGME library to a program ‘foo’.
397
398 gcc -o foo foo.o `gpgme-config --libs`
399
400 Of course you can also combine both examples to a single command by
401 specifying both options to ‘gpgme-config’:
402
403 gcc -o foo foo.c `gpgme-config --cflags --libs`
404
405 If you need to detect the installed language bindings you can use
406 list them using:
407
408 gpgme-config --print-lang
409
410 or test for the availability using
411
412 gpgme-config --have-lang=python && echo 'Bindings for Pythons available'
413
414 
415 File: gpgme.info, Node: Largefile Support (LFS), Next: Using Automake, Prev: Building the Source, Up: Preparation
416
417 2.3 Largefile Support (LFS)
418 ===========================
419
420 GPGME is compiled with largefile support by default, if it is available
421 on the system. This means that GPGME supports files larger than two
422 gigabyte in size, if the underlying operating system can. On some
423 systems, largefile support is already the default. On such systems,
424 nothing special is required. However, some systems provide only support
425 for files up to two gigabyte in size by default. Support for larger
426 file sizes has to be specifically enabled.
427
428 To make a difficult situation even more complex, such systems provide
429 two different types of largefile support. You can either get all
430 relevant functions replaced with alternatives that are largefile
431 capable, or you can get new functions and data types for largefile
432 support added. Those new functions have the same name as their
433 smallfile counterparts, but with a suffix of 64.
434
435 An example: The data type ‘off_t’ is 32 bit wide on GNU/Linux PC
436 systems. To address offsets in large files, you can either enable
437 largefile support add-on. Then a new data type ‘off64_t’ is provided,
438 which is 64 bit wide. Or you can replace the existing ‘off_t’ data type
439 with its 64 bit wide counterpart. All occurrences of ‘off_t’ are then
440 automagically replaced.
441
442 As if matters were not complex enough, there are also two different
443 types of file descriptors in such systems. This is important because if
444 file descriptors are exchanged between programs that use a different
445 maximum file size, certain errors must be produced on some file
446 descriptors to prevent subtle overflow bugs from occurring.
447
448 As you can see, supporting two different maximum file sizes at the
449 same time is not at all an easy task. However, the maximum file size
450 does matter for GPGME, because some data types it uses in its interfaces
451 are affected by that. For example, the ‘off_t’ data type is used in the
452 ‘gpgme_data_seek’ function, to match its POSIX counterpart. This
453 affects the call-frame of the function, and thus the ABI of the library.
454 Furthermore, file descriptors can be exchanged between GPGME and the
455 application.
456
457 For you as the user of the library, this means that your program must
458 be compiled in the same file size mode as the library. Luckily, there
459 is absolutely no valid reason for new programs to not enable largefile
460 support by default and just use that. The compatibility modes (small
461 file sizes or dual mode) can be considered an historic artefact, only
462 useful to allow for a transitional period.
463
464 On POSIX platforms GPGME is compiled using largefile support by
465 default. This means that your application must do the same, at least as
466 far as it is relevant for using the ‘gpgme.h’ header file. All types in
467 this header files refer to their largefile counterparts, if they are
468 different from any default types on the system.
469
470 On 32 and 64 bit Windows platforms ‘off_t’ is declared as 32 bit
471 signed integer. There is no specific support for LFS in the C library.
472 The recommendation from Microsoft is to use the native interface
473 (‘CreateFile’ et al.) for large files. Released binary versions of
474 GPGME (libgpgme-11.dll) have always been build with a 32 bit ‘off_t’.
475 To avoid an ABI break we stick to this convention for 32 bit Windows by
476 using ‘long’ there. GPGME versions for 64 bit Windows have never been
477 released and thus we are able to use ‘int64_t’ instead of ‘off_t’ there.
478 For easier migration the typedef ‘gpgme_off_t’ has been defined. The
479 reason we cannot use ‘off_t’ directly is that some toolchains (e.g.
480 mingw64) introduce a POSIX compatible hack for ‘off_t’. Some widely
481 used toolkits make use of this hack and in turn GPGME would need to use
482 it also. However, this would introduce an ABI break and existing
483 software making use of libgpgme might suffer from a severe break. Thus
484 with version 1.4.2 we redefined all functions using ‘off_t’ to use
485 ‘gpgme_off_t’ which is defined as explained above. This way we keep the
486 ABI well defined and independent of any toolchain hacks. The bottom
487 line is that LFS support in GPGME is only available on 64 bit versions
488 of Windows.
489
490 On POSIX platforms you can enable largefile support, if it is
491 different from the default on the system the application is compiled on,
492 by using the Autoconf macro ‘AC_SYS_LARGEFILE’. If you do this, then
493 you don’t need to worry about anything else: It will just work. In this
494 case you might also want to use ‘AC_FUNC_FSEEKO’ to take advantage of
495 some new interfaces, and ‘AC_TYPE_OFF_T’ (just in case).
496
497 If you do not use Autoconf, you can define the preprocessor symbol
498 ‘_FILE_OFFSET_BITS’ to 64 _before_ including any header files, for
499 example by specifying the option ‘-D_FILE_OFFSET_BITS=64’ on the
500 compiler command line. You will also want to define the preprocessor
501 symbol ‘LARGEFILE_SOURCE’ to 1 in this case, to take advantage of some
502 new interfaces.
503
504 If you do not want to do either of the above, you probably know
505 enough about the issue to invent your own solution. Just keep in mind
506 that the GPGME header file expects that largefile support is enabled, if
507 it is available. In particular, we do not support dual mode
508 (‘_LARGEFILE64_SOURCE’).
509
510 
511 File: gpgme.info, Node: Using Automake, Next: Using Libtool, Prev: Largefile Support (LFS), Up: Preparation
512
513 2.4 Using Automake
514 ==================
515
516 It is much easier if you use GNU Automake instead of writing your own
517 Makefiles. If you do that you do not have to worry about finding and
518 invoking the ‘gpgme-config’ script at all. GPGME provides an extension
519 to Automake that does all the work for you.
520
521 -- Macro: AM_PATH_GPGME ([MINIMUM-VERSION], [ACTION-IF-FOUND],
522 [ACTION-IF-NOT-FOUND])
523 -- Macro: AM_PATH_GPGME_PTH ([MINIMUM-VERSION], [ACTION-IF-FOUND],
524 [ACTION-IF-NOT-FOUND])
525 -- Macro: AM_PATH_GPGME_PTHREAD ([MINIMUM-VERSION], [ACTION-IF-FOUND],
526 [ACTION-IF-NOT-FOUND])
527 Check whether GPGME (at least version MINIMUM-VERSION, if given)
528 exists on the host system. If it is found, execute
529 ACTION-IF-FOUND, otherwise do ACTION-IF-NOT-FOUND, if given.
530
531 Additionally, the function defines ‘GPGME_CFLAGS’ to the flags
532 needed for compilation of the program to find the ‘gpgme.h’ header
533 file, and ‘GPGME_LIBS’ to the linker flags needed to link the
534 program to the GPGME library. If the used helper script does not
535 match the target type you are building for a warning is printed and
536 the string ‘libgcrypt’ is appended to the variable
537 ‘gpg_config_script_warn’.
538
539 ‘AM_PATH_GPGME_PTH’ checks for the version of GPGME that can be
540 used with GNU Pth, and defines ‘GPGME_PTH_CFLAGS’ and
541 ‘GPGME_PTH_LIBS’.
542
543 ‘AM_PATH_GPGME_PTHREAD’ checks for the version of GPGME that can be
544 used with the native pthread implementation, and defines
545 ‘GPGME_PTHREAD_CFLAGS’ and ‘GPGME_PTHREAD_LIBS’. Since version
546 1.8.0 this is no longer required to GPGME_PTHREAD as GPGME itself
547 is thread safe.
548
549 This macro searches for ‘gpgme-config’ along the PATH. If you are
550 cross-compiling, it is useful to set the environment variable
551 ‘SYSROOT’ to the top directory of your target. The macro will then
552 first look for the helper program in the ‘bin’ directory below that
553 top directory. An absolute directory name must be used for
554 ‘SYSROOT’. Finally, if the configure command line option
555 ‘--with-gpgme-prefix’ is used, only its value is used for the top
556 directory below which the helper script is expected.
557
558 You can use the defined Autoconf variables like this in your
559 ‘Makefile.am’:
560
561 AM_CPPFLAGS = $(GPGME_CFLAGS)
562 LDADD = $(GPGME_LIBS)
563
564 
565 File: gpgme.info, Node: Using Libtool, Next: Library Version Check, Prev: Using Automake, Up: Preparation
566
567 2.5 Using Libtool
568 =================
569
570 The easiest way is to just use GNU Libtool. If you use libtool, and
571 link to ‘libgpgme.la’, ‘libgpgme-pth.la’ or ‘libgpgme-pthread.la’
572 respectively, everything will be done automatically by Libtool.
573
574 
575 File: gpgme.info, Node: Library Version Check, Next: Signal Handling, Prev: Using Libtool, Up: Preparation
576
577 2.6 Library Version Check
578 =========================
579
580 -- Function: const char * gpgme_check_version
581 (const char *REQUIRED_VERSION)
582 The function ‘gpgme_check_version’ has four purposes. It can be
583 used to retrieve the version number of the library. In addition it
584 can verify that the version number is higher than a certain
585 required version number. In either case, the function initializes
586 some sub-systems, and for this reason alone it must be invoked
587 early in your program, before you make use of the other functions
588 in GPGME. The last purpose is to run selftests.
589
590 As a side effect for W32 based systems, the socket layer will get
591 initialized.
592
593 If REQUIRED_VERSION is ‘NULL’, the function returns a pointer to a
594 statically allocated string containing the version number of the
595 library.
596
597 If REQUIRED_VERSION is not ‘NULL’, it should point to a string
598 containing a version number, and the function checks that the
599 version of the library is at least as high as the version number
600 provided. In this case, the function returns a pointer to a
601 statically allocated string containing the version number of the
602 library. If REQUIRED_VERSION is not a valid version number, or if
603 the version requirement is not met, the function returns ‘NULL’.
604
605 If you use a version of a library that is backwards compatible with
606 older releases, but contains additional interfaces which your
607 program uses, this function provides a run-time check if the
608 necessary features are provided by the installed version of the
609 library.
610
611 If a selftest fails, the function may still succeed. Selftest
612 errors are returned later when invoking ‘gpgme_new’ or
613 ‘gpgme-data_new’, so that a detailed error code can be returned
614 (historically, ‘gpgme_check_version’ does not return a detailed
615 error code).
616
617 -- Function: int gpgme_set_global_flag (const char *NAME,
618 const char *VALUE)
619
620 SINCE: 1.4.0
621
622 On some systems it is not easy to set environment variables and
623 thus hard to use GPGME’s internal trace facility for debugging.
624 This function has been introduced as an alternative way to enable
625 debugging and for a couple of other rarely used tweaks. It is
626 important to assure that only one thread accesses GPGME functions
627 between a call to this function and after the return from the call
628 to ‘gpgme_check_version’.
629
630 All currently supported features require that this function is
631 called as early as possible — even before ‘gpgme_check_version’.
632 The features are identified by the following values for NAME:
633
634 ‘debug’
635 To enable debugging use the string “debug” for NAME and VALUE
636 identical to the value used with the environment variable
637 ‘GPGME_DEBUG’.
638
639 ‘disable-gpgconf’
640 Using this feature with any VALUE disables the detection of
641 the gpgconf program and thus forces GPGME to fallback into the
642 simple OpenPGP only mode. It may be used to force the use of
643 GnuPG-1 on systems which have both GPG versions installed.
644 Note that in general the use of ‘gpgme_set_engine_info’ is a
645 better way to select a specific engine version.
646
647 ‘gpgconf-name’
648 ‘gpg-name’
649 Set the name of the gpgconf respective gpg binary. The
650 defaults are ‘GNU/GnuPG/gpgconf’ and ‘GNU/GnuPG/gpg’. Under
651 Unix the leading directory part is ignored. Under Windows the
652 leading directory part is used as the default installation
653 directory; the ‘.exe’ suffix is added by GPGME. Use forward
654 slashed even under Windows.
655
656 ‘require-gnupg’
657 Set the minimum version of the required GnuPG engine. If that
658 version is not met, GPGME fails early instead of trying to use
659 the existent version. The given version must be a string with
660 major, minor, and micro number. Example: "2.1.0".
661
662 ‘w32-inst-dir’
663 On Windows GPGME needs to know its installation directory to
664 find its spawn helper. This is in general no problem because
665 a DLL has this information. Some applications however link
666 statically to GPGME and thus GPGME can only figure out the
667 installation directory of this application which may be wrong
668 in certain cases. By supplying an installation directory as
669 value to this flag, GPGME will assume that that directory is
670 the installation directory. This flag has no effect on
671 non-Windows platforms.
672
673 This function returns ‘0’ on success. In contrast to other
674 functions the non-zero return value on failure does not convey any
675 error code. For setting “debug” the only possible error cause is
676 an out of memory condition; which would exhibit itself later
677 anyway. Thus the return value may be ignored.
678
679 After initializing GPGME, you should set the locale information to
680 the locale required for your output terminal. This locale information
681 is needed for example for the curses and Gtk pinentry. Here is an
682 example of a complete initialization:
683
684 #include <locale.h>
685 #include <gpgme.h>
686
687 void
688 init_gpgme (void)
689 {
690 /* Initialize the locale environment. */
691 setlocale (LC_ALL, "");
692 gpgme_check_version (NULL);
693 gpgme_set_locale (NULL, LC_CTYPE, setlocale (LC_CTYPE, NULL));
694 #ifdef LC_MESSAGES
695 gpgme_set_locale (NULL, LC_MESSAGES, setlocale (LC_MESSAGES, NULL));
696 #endif
697 }
698
699 Note that you are highly recommended to initialize the locale
700 settings like this. GPGME can not do this for you because it would not
701 be thread safe. The conditional on LC_MESSAGES is only necessary for
702 portability to W32 systems.
703
704 
705 File: gpgme.info, Node: Signal Handling, Next: Multi-Threading, Prev: Library Version Check, Up: Preparation
706
707 2.7 Signal Handling
708 ===================
709
710 The GPGME library communicates with child processes (the crypto
711 engines). If a child process dies unexpectedly, for example due to a
712 bug, or system problem, a ‘SIGPIPE’ signal will be delivered to the
713 application. The default action is to abort the program. To protect
714 against this, ‘gpgme_check_version’ sets the ‘SIGPIPE’ signal action to
715 ‘SIG_IGN’, which means that the signal will be ignored.
716
717 GPGME will only do that if the signal action for ‘SIGPIPE’ is
718 ‘SIG_DEF’ at the time ‘gpgme_check_version’ is called. If it is
719 something different, ‘GPGME’ will take no action.
720
721 This means that if your application does not install any signal
722 handler for ‘SIGPIPE’, you don’t need to take any precautions. If you
723 do install a signal handler for ‘SIGPIPE’, you must be prepared to
724 handle any ‘SIGPIPE’ events that occur due to GPGME writing to a defunct
725 pipe. Furthermore, if your application is multi-threaded, and you
726 install a signal action for ‘SIGPIPE’, you must make sure you do this
727 either before ‘gpgme_check_version’ is called or afterwards.
728
729 
730 File: gpgme.info, Node: Multi-Threading, Prev: Signal Handling, Up: Preparation
731
732 2.8 Multi-Threading
733 ===================
734
735 The GPGME library is mostly thread-safe, and can be used in a
736 multi-threaded environment but there are some requirements for
737 multi-threaded use:
738
739 • The function ‘gpgme_check_version’ must be called before any other
740 function in the library, because it initializes the thread support
741 subsystem in GPGME. To achieve this in multi-threaded programs,
742 you must synchronize the memory with respect to other threads that
743 also want to use GPGME. For this, it is sufficient to call
744 ‘gpgme_check_version’ before creating the other threads using
745 GPGME(1).
746
747 • Any ‘gpgme_data_t’ and ‘gpgme_ctx_t’ object must only be accessed
748 by one thread at a time. If multiple threads want to deal with the
749 same object, the caller has to make sure that operations on that
750 object are fully synchronized.
751
752 • Only one thread at any time is allowed to call ‘gpgme_wait’. If
753 multiple threads call this function, the caller must make sure that
754 all invocations are fully synchronized. It is safe to start
755 asynchronous operations while a thread is running in gpgme_wait.
756
757 • The function ‘gpgme_strerror’ is not thread safe. You have to use
758 ‘gpgme_strerror_r’ instead.
759
760 ---------- Footnotes ----------
761
762 (1) At least this is true for POSIX threads, as ‘pthread_create’ is a
763 function that synchronizes memory with respects to other threads. There
764 are many functions which have this property, a complete list can be
765 found in POSIX, IEEE Std 1003.1-2003, Base Definitions, Issue 6, in the
766 definition of the term “Memory Synchronization”. For other thread
767 packages other, more relaxed or more strict rules may apply.
768
769 
770 File: gpgme.info, Node: Protocols and Engines, Next: Algorithms, Prev: Preparation, Up: Top
771
772 3 Protocols and Engines
773 ***********************
774
775 GPGME supports several cryptographic protocols, however, it does not
776 implement them. Rather it uses backends (also called engines) which
777 implement the protocol. GPGME uses inter-process communication to pass
778 data back and forth between the application and the backend, but the
779 details of the communication protocol and invocation of the backend is
780 completely hidden by the interface. All complexity is handled by GPGME.
781 Where an exchange of information between the application and the backend
782 is necessary, GPGME provides the necessary callback function hooks and
783 further interfaces.
784
785 -- Data type: enum gpgme_protocol_t
786 The ‘gpgme_protocol_t’ type specifies the set of possible protocol
787 values that are supported by GPGME. The following protocols are
788 supported:
789
790 ‘GPGME_PROTOCOL_OpenPGP’
791 ‘GPGME_PROTOCOL_OPENPGP’
792 This specifies the OpenPGP protocol.
793
794 ‘GPGME_PROTOCOL_CMS’
795 This specifies the Cryptographic Message Syntax.
796
797 ‘GPGME_PROTOCOL_GPGCONF’
798 Under development. Please ask on <gnupg-devel@gnupg.org> for
799 help.
800
801 ‘GPGME_PROTOCOL_ASSUAN’
802 SINCE: 1.2.0
803
804 This specifies the raw Assuan protocol.
805
806 ‘GPGME_PROTOCOL_G13’
807 SINCE: 1.3.0
808
809 Under development. Please ask on <gnupg-devel@gnupg.org> for
810 help.
811
812 ‘GPGME_PROTOCOL_UISERVER’
813 Under development. Please ask on <gnupg-devel@gnupg.org> for
814 help.
815
816 ‘GPGME_PROTOCOL_SPAWN’
817 SINCE: 1.5.0
818
819 Special protocol for use with ‘gpgme_op_spawn’.
820
821 ‘GPGME_PROTOCOL_UNKNOWN’
822 Reserved for future extension. You may use this to indicate
823 that the used protocol is not known to the application.
824 Currently, GPGME does not accept this value in any operation,
825 though, except for ‘gpgme_get_protocol_name’.
826
827 -- Function: const char * gpgme_get_protocol_name
828 (gpgme_protocol_t PROTOCOL)
829 The function ‘gpgme_get_protocol_name’ returns a statically
830 allocated string describing the protocol PROTOCOL, or ‘NULL’ if the
831 protocol number is not valid.
832
833 * Menu:
834
835 * Engine Version Check:: Verifying the engine version.
836 * Engine Information:: Obtaining more information about the engines.
837 * Engine Configuration:: Changing the engine configuration.
838 * OpenPGP:: Support for the OpenPGP protocol.
839 * Cryptographic Message Syntax:: Support for the CMS.
840 * Assuan:: Support for the raw Assuan protocol.
841
842 
843 File: gpgme.info, Node: Engine Version Check, Next: Engine Information, Up: Protocols and Engines
844
845 3.1 Engine Version Check
846 ========================
847
848 -- Function: const char * gpgme_get_dirinfo (cons char *WHAT)
849 SINCE: 1.5.0
850
851 The function ‘gpgme_get_dirinfo’ returns a statically allocated
852 string with the value associated to WHAT. The returned values are
853 the defaults and won’t change even after ‘gpgme_set_engine_info’
854 has been used to configure a different engine. ‘NULL’ is returned
855 if no value is available. Commonly supported values for WHAT are:
856
857 ‘homedir’
858 Return the default home directory.
859
860 ‘sysconfdir’
861 Return the name of the system configuration directory
862
863 ‘bindir’
864 Return the name of the directory with GnuPG program files.
865
866 ‘libdir’
867 Return the name of the directory with GnuPG related library
868 files.
869
870 ‘libexecdir’
871 Return the name of the directory with GnuPG helper program
872 files.
873
874 ‘datadir’
875 Return the name of the directory with GnuPG shared data.
876
877 ‘localedir’
878 Return the name of the directory with GnuPG locale data.
879
880 ‘agent-socket’
881 Return the name of the socket to connect to the gpg-agent.
882
883 ‘agent-ssh-socket’
884 Return the name of the socket to connect to the ssh-agent
885 component of gpg-agent.
886
887 ‘dirmngr-socket’
888 Return the name of the socket to connect to the dirmngr.
889
890 ‘uiserver-socket’
891 Return the name of the socket to connect to the user interface
892 server.
893
894 ‘gpgconf-name’
895 Return the file name of the engine configuration tool.
896
897 ‘gpg-name’
898 Return the file name of the OpenPGP engine.
899
900 ‘gpgsm-name’
901 Return the file name of the CMS engine.
902
903 ‘g13-name’
904 Return the name of the file container encryption engine.
905
906 ‘keyboxd-name’
907 Return the name of the key database daemon.
908
909 ‘agent-name’
910 Return the name of gpg-agent.
911
912 ‘scdaemon-name’
913 Return the name of the smart card daemon.
914
915 ‘dirmngr-name’
916 Return the name of dirmngr.
917
918 ‘pinentry-name’
919 Return the name of the pinentry program.
920
921 ‘gpg-wks-client-name’
922 Return the name of the Web Key Service tool.
923
924 -- Function: gpgme_error_t gpgme_engine_check_version
925 (gpgme_protocol_t PROTOCOL)
926 The function ‘gpgme_engine_check_version’ verifies that the engine
927 implementing the protocol PROTOCOL is installed in the expected
928 path and meets the version requirement of GPGME.
929
930 This function returns the error code ‘GPG_ERR_NO_ERROR’ if the
931 engine is available and ‘GPG_ERR_INV_ENGINE’ if it is not.
932
933 
934 File: gpgme.info, Node: Engine Information, Next: Engine Configuration, Prev: Engine Version Check, Up: Protocols and Engines
935
936 3.2 Engine Information
937 ======================
938
939 -- Data type: gpgme_engine_info_t
940 The ‘gpgme_engine_info_t’ type specifies a pointer to a structure
941 describing a crypto engine. The structure contains the following
942 elements:
943
944 ‘gpgme_engine_info_t next’
945 This is a pointer to the next engine info structure in the
946 linked list, or ‘NULL’ if this is the last element.
947
948 ‘gpgme_protocol_t protocol’
949 This is the protocol for which the crypto engine is used. You
950 can convert this to a string with ‘gpgme_get_protocol_name’
951 for printing.
952
953 ‘const char *file_name’
954 This is a string holding the file name of the executable of
955 the crypto engine. Currently, it is never ‘NULL’, but using
956 ‘NULL’ is reserved for future use, so always check before you
957 use it.
958
959 ‘const char *home_dir’
960 This is a string holding the directory name of the crypto
961 engine’s configuration directory. If it is ‘NULL’, then the
962 default directory is used. See ‘gpgme_get_dirinfo’ on how to
963 get the default directory.
964
965 ‘const char *version’
966 This is a string containing the version number of the crypto
967 engine. It might be ‘NULL’ if the version number can not be
968 determined, for example because the executable doesn’t exist
969 or is invalid.
970
971 ‘const char *req_version’
972 This is a string containing the minimum required version
973 number of the crypto engine for GPGME to work correctly. This
974 is the version number that ‘gpgme_engine_check_version’
975 verifies against. Currently, it is never ‘NULL’, but using
976 ‘NULL’ is reserved for future use, so always check before you
977 use it.
978
979 -- Function: gpgme_error_t gpgme_get_engine_info
980 (gpgme_engine_info_t *INFO)
981 The function ‘gpgme_get_engine_info’ returns a linked list of
982 engine info structures in INFO. Each info structure describes the
983 defaults of one configured backend.
984
985 The memory for the info structures is allocated the first time this
986 function is invoked, and must not be freed by the caller.
987
988 This function returns the error code ‘GPG_ERR_NO_ERROR’ if
989 successful, and a system error if the memory could not be
990 allocated.
991
992 Here is an example how you can provide more diagnostics if you
993 receive an error message which indicates that the crypto engine is
994 invalid.
995
996 gpgme_ctx_t ctx;
997 gpgme_error_t err;
998
999 [...]
1000
1001 if (gpgme_err_code (err) == GPG_ERR_INV_ENGINE)
1002 {
1003 gpgme_engine_info_t info;
1004 err = gpgme_get_engine_info (&info);
1005 if (!err)
1006 {
1007 while (info && info->protocol != gpgme_get_protocol (ctx))
1008 info = info->next;
1009 if (!info)
1010 fprintf (stderr, "GPGME compiled without support for protocol %s",
1011 gpgme_get_protocol_name (info->protocol));
1012 else if (info->file_name && !info->version)
1013 fprintf (stderr, "Engine %s not installed properly",
1014 info->file_name);
1015 else if (info->file_name && info->version && info->req_version)
1016 fprintf (stderr, "Engine %s version %s installed, "
1017 "but at least version %s required", info->file_name,
1018 info->version, info->req_version);
1019 else
1020 fprintf (stderr, "Unknown problem with engine for protocol %s",
1021 gpgme_get_protocol_name (info->protocol));
1022 }
1023 }
1024
1025 
1026 File: gpgme.info, Node: Engine Configuration, Next: OpenPGP, Prev: Engine Information, Up: Protocols and Engines
1027
1028 3.3 Engine Configuration
1029 ========================
1030
1031 You can change the configuration of a backend engine, and thus change
1032 the executable program and configuration directory to be used. You can
1033 make these changes the default or set them for some contexts
1034 individually.
1035
1036 -- Function: gpgme_error_t gpgme_set_engine_info
1037 (gpgme_protocol_t PROTO, const char *FILE_NAME,
1038 const char *HOME_DIR)
1039 SINCE: 1.1.0
1040
1041 The function ‘gpgme_set_engine_info’ changes the default
1042 configuration of the crypto engine implementing the protocol PROTO.
1043
1044 FILE_NAME is the file name of the executable program implementing
1045 this protocol, and HOME_DIR is the directory name of the
1046 configuration directory for this crypto engine. If HOME_DIR is
1047 ‘NULL’, the engine’s default will be used.
1048
1049 The new defaults are not applied to already created GPGME contexts.
1050
1051 This function returns the error code ‘GPG_ERR_NO_ERROR’ if
1052 successful, or an error code on failure.
1053
1054 The functions ‘gpgme_ctx_get_engine_info’ and
1055 ‘gpgme_ctx_set_engine_info’ can be used to change the engine
1056 configuration per context. *Note Crypto Engine::.
1057
1058 
1059 File: gpgme.info, Node: OpenPGP, Next: Cryptographic Message Syntax, Prev: Engine Configuration, Up: Protocols and Engines
1060
1061 3.4 OpenPGP
1062 ===========
1063
1064 OpenPGP is implemented by GnuPG, the GNU Privacy Guard. This is the
1065 first protocol that was supported by GPGME.
1066
1067 The OpenPGP protocol is specified by ‘GPGME_PROTOCOL_OpenPGP’.
1068
1069 
1070 File: gpgme.info, Node: Cryptographic Message Syntax, Next: Assuan, Prev: OpenPGP, Up: Protocols and Engines
1071
1072 3.5 Cryptographic Message Syntax
1073 ================================
1074
1075 CMS is implemented by GpgSM, the S/MIME implementation for GnuPG.
1076
1077 The CMS protocol is specified by ‘GPGME_PROTOCOL_CMS’.
1078
1079 
1080 File: gpgme.info, Node: Assuan, Prev: Cryptographic Message Syntax, Up: Protocols and Engines
1081
1082 3.6 Assuan
1083 ==========
1084
1085 Assuan is the RPC library used by the various GnuPG components. The
1086 Assuan protocol allows one to talk to arbitrary Assuan servers using
1087 GPGME. *Note Using the Assuan protocol::.
1088
1089 The ASSUAN protocol is specified by ‘GPGME_PROTOCOL_ASSUAN’.
1090
1091 
1092 File: gpgme.info, Node: Algorithms, Next: Error Handling, Prev: Protocols and Engines, Up: Top
1093
1094 4 Algorithms
1095 ************
1096
1097 The crypto backends support a variety of algorithms used in public key
1098 cryptography.(1) The following sections list the identifiers used to
1099 denote such an algorithm.
1100
1101 * Menu:
1102
1103 * Public Key Algorithms:: A list of all public key algorithms.
1104 * Hash Algorithms:: A list of all hash algorithms.
1105
1106 ---------- Footnotes ----------
1107
1108 (1) Some engines also provide symmetric only encryption; see the
1109 description of the encryption function on how to use this.
1110
1111 
1112 File: gpgme.info, Node: Public Key Algorithms, Next: Hash Algorithms, Up: Algorithms
1113
1114 4.1 Public Key Algorithms
1115 =========================
1116
1117 Public key algorithms are used for encryption, decryption, signing and
1118 verification of signatures.
1119
1120 -- Data type: enum gpgme_pubkey_algo_t
1121 The ‘gpgme_pubkey_algo_t’ type specifies the set of all public key
1122 algorithms that are supported by GPGME. Possible values are:
1123
1124 ‘GPGME_PK_RSA’
1125 This value indicates the RSA (Rivest, Shamir, Adleman)
1126 algorithm.
1127
1128 ‘GPGME_PK_RSA_E’
1129 Deprecated. This value indicates the RSA (Rivest, Shamir,
1130 Adleman) algorithm for encryption and decryption only.
1131
1132 ‘GPGME_PK_RSA_S’
1133 Deprecated. This value indicates the RSA (Rivest, Shamir,
1134 Adleman) algorithm for signing and verification only.
1135
1136 ‘GPGME_PK_DSA’
1137 This value indicates DSA, the Digital Signature Algorithm.
1138
1139 ‘GPGME_PK_ELG’
1140 This value indicates ElGamal.
1141
1142 ‘GPGME_PK_ELG_E’
1143 This value also indicates ElGamal and is used specifically in
1144 GnuPG.
1145
1146 ‘GPGME_PK_ECC’
1147 SINCE: 1.5.0
1148
1149 This value is a generic indicator for ellipic curve
1150 algorithms.
1151
1152 ‘GPGME_PK_ECDSA’
1153 SINCE: 1.3.0
1154
1155 This value indicates ECDSA, the Elliptic Curve Digital
1156 Signature Algorithm as defined by FIPS 186-2 and RFC-6637.
1157
1158 ‘GPGME_PK_ECDH’
1159 SINCE: 1.3.0
1160
1161 This value indicates ECDH, the Eliptic Curve Diffie-Hellmann
1162 encryption algorithm as defined by RFC-6637.
1163
1164 ‘GPGME_PK_EDDSA’
1165 SINCE: 1.7.0
1166
1167 This value indicates the EdDSA algorithm.
1168
1169 -- Function: const char * gpgme_pubkey_algo_name
1170 (gpgme_pubkey_algo_t ALGO)
1171 The function ‘gpgme_pubkey_algo_name’ returns a pointer to a
1172 statically allocated string containing a description of the public
1173 key algorithm ALGO. This string can be used to output the name of
1174 the public key algorithm to the user.
1175
1176 If ALGO is not a valid public key algorithm, ‘NULL’ is returned.
1177
1178 -- Function: char * gpgme_pubkey_algo_string (gpgme_subkey_t KEY)
1179 SINCE: 1.7.0
1180
1181 The function ‘gpgme_pubkey_algo_string’ is a convenience function
1182 to build and return an algorithm string in the same way GnuPG does
1183 (e.g. “rsa2048” or “ed25519”). The caller must free the result
1184 using ‘gpgme_free’. On error (e.g. invalid argument or memory
1185 exhausted), the function returns NULL and sets ‘ERRNO’.
1186
1187 
1188 File: gpgme.info, Node: Hash Algorithms, Prev: Public Key Algorithms, Up: Algorithms
1189
1190 4.2 Hash Algorithms
1191 ===================
1192
1193 Hash (message digest) algorithms are used to compress a long message to
1194 make it suitable for public key cryptography.
1195
1196 -- Data type: enum gpgme_hash_algo_t
1197 The ‘gpgme_hash_algo_t’ type specifies the set of all hash
1198 algorithms that are supported by GPGME. Possible values are:
1199
1200 ‘GPGME_MD_MD5’
1201 ‘GPGME_MD_SHA1’
1202 ‘GPGME_MD_RMD160’
1203 ‘GPGME_MD_MD2’
1204 ‘GPGME_MD_TIGER’
1205 ‘GPGME_MD_HAVAL’
1206 ‘GPGME_MD_SHA256’
1207 ‘GPGME_MD_SHA384’
1208 ‘GPGME_MD_SHA512’
1209 ‘GPGME_MD_SHA224’
1210 SINCE: 1.5.0
1211
1212 ‘GPGME_MD_MD4’
1213 ‘GPGME_MD_CRC32’
1214 ‘GPGME_MD_CRC32_RFC1510’
1215 ‘GPGME_MD_CRC24_RFC2440’
1216
1217 -- Function: const char * gpgme_hash_algo_name (gpgme_hash_algo_t ALGO)
1218 The function ‘gpgme_hash_algo_name’ returns a pointer to a
1219 statically allocated string containing a description of the hash
1220 algorithm ALGO. This string can be used to output the name of the
1221 hash algorithm to the user.
1222
1223 If ALGO is not a valid hash algorithm, ‘NULL’ is returned.
1224
1225 
1226 File: gpgme.info, Node: Error Handling, Next: Exchanging Data, Prev: Algorithms, Up: Top
1227
1228 5 Error Handling
1229 ****************
1230
1231 Many functions in GPGME can return an error if they fail. For this
1232 reason, the application should always catch the error condition and take
1233 appropriate measures, for example by releasing the resources and passing
1234 the error up to the caller, or by displaying a descriptive message to
1235 the user and cancelling the operation.
1236
1237 Some error values do not indicate a system error or an error in the
1238 operation, but the result of an operation that failed properly. For
1239 example, if you try to decrypt a tempered message, the decryption will
1240 fail. Another error value actually means that the end of a data buffer
1241 or list has been reached. The following descriptions explain for many
1242 error codes what they mean usually. Some error values have specific
1243 meanings if returned by a certain functions. Such cases are described
1244 in the documentation of those functions.
1245
1246 GPGME uses the ‘libgpg-error’ library. This allows to share the
1247 error codes with other components of the GnuPG system, and thus pass
1248 error values transparently from the crypto engine, or some helper
1249 application of the crypto engine, to the user. This way no information
1250 is lost. As a consequence, GPGME does not use its own identifiers for
1251 error codes, but uses those provided by ‘libgpg-error’. They usually
1252 start with ‘GPG_ERR_’.
1253
1254 However, GPGME does provide aliases for the functions defined in
1255 libgpg-error, which might be preferred for name space consistency.
1256
1257 * Menu:
1258
1259 * Error Values:: The error value and what it means.
1260 * Error Sources:: A list of important error sources.
1261 * Error Codes:: A list of important error codes.
1262 * Error Strings:: How to get a descriptive string from a value.
1263
1264 
1265 File: gpgme.info, Node: Error Values, Next: Error Sources, Up: Error Handling
1266
1267 5.1 Error Values
1268 ================
1269
1270 -- Data type: gpgme_err_code_t
1271 The ‘gpgme_err_code_t’ type is an alias for the ‘libgpg-error’ type
1272 ‘gpg_err_code_t’. The error code indicates the type of an error,
1273 or the reason why an operation failed.
1274
1275 A list of important error codes can be found in the next section.
1276
1277 -- Data type: gpgme_err_source_t
1278 The ‘gpgme_err_source_t’ type is an alias for the ‘libgpg-error’
1279 type ‘gpg_err_source_t’. The error source has not a precisely
1280 defined meaning. Sometimes it is the place where the error
1281 happened, sometimes it is the place where an error was encoded into
1282 an error value. Usually the error source will give an indication
1283 to where to look for the problem. This is not always true, but it
1284 is attempted to achieve this goal.
1285
1286 A list of important error sources can be found in the next section.
1287
1288 -- Data type: gpgme_error_t
1289 The ‘gpgme_error_t’ type is an alias for the ‘libgpg-error’ type
1290 ‘gpg_error_t’. An error value like this has always two components,
1291 an error code and an error source. Both together form the error
1292 value.
1293
1294 Thus, the error value can not be directly compared against an error
1295 code, but the accessor functions described below must be used.
1296 However, it is guaranteed that only 0 is used to indicate success
1297 (‘GPG_ERR_NO_ERROR’), and that in this case all other parts of the
1298 error value are set to 0, too.
1299
1300 Note that in GPGME, the error source is used purely for
1301 diagnostical purposes. Only the error code should be checked to
1302 test for a certain outcome of a function. The manual only
1303 documents the error code part of an error value. The error source
1304 is left unspecified and might be anything.
1305
1306 -- Function: static inline gpgme_err_code_t gpgme_err_code
1307 (gpgme_error_t ERR)
1308 The static inline function ‘gpgme_err_code’ returns the
1309 ‘gpgme_err_code_t’ component of the error value ERR. This function
1310 must be used to extract the error code from an error value in order
1311 to compare it with the ‘GPG_ERR_*’ error code macros.
1312
1313 -- Function: static inline gpgme_err_source_t gpgme_err_source
1314 (gpgme_error_t ERR)
1315 The static inline function ‘gpgme_err_source’ returns the
1316 ‘gpgme_err_source_t’ component of the error value ERR. This
1317 function must be used to extract the error source from an error
1318 value in order to compare it with the ‘GPG_ERR_SOURCE_*’ error
1319 source macros.
1320
1321 -- Function: static inline gpgme_error_t gpgme_err_make
1322 (gpgme_err_source_t SOURCE, gpgme_err_code_t CODE)
1323 The static inline function ‘gpgme_err_make’ returns the error value
1324 consisting of the error source SOURCE and the error code CODE.
1325
1326 This function can be used in callback functions to construct an
1327 error value to return it to the library.
1328
1329 -- Function: static inline gpgme_error_t gpgme_error
1330 (gpgme_err_code_t CODE)
1331 The static inline function ‘gpgme_error’ returns the error value
1332 consisting of the default error source and the error code CODE.
1333
1334 For GPGME applications, the default error source is
1335 ‘GPG_ERR_SOURCE_USER_1’. You can define ‘GPGME_ERR_SOURCE_DEFAULT’
1336 before including ‘gpgme.h’ to change this default.
1337
1338 This function can be used in callback functions to construct an
1339 error value to return it to the library.
1340
1341 The ‘libgpg-error’ library provides error codes for all system error
1342 numbers it knows about. If ERR is an unknown error number, the error
1343 code ‘GPG_ERR_UNKNOWN_ERRNO’ is used. The following functions can be
1344 used to construct error values from system errnor numbers.
1345
1346 -- Function: gpgme_error_t gpgme_err_make_from_errno
1347 (gpgme_err_source_t SOURCE, int ERR)
1348 The function ‘gpgme_err_make_from_errno’ is like ‘gpgme_err_make’,
1349 but it takes a system error like ‘errno’ instead of a
1350 ‘gpgme_err_code_t’ error code.
1351
1352 -- Function: gpgme_error_t gpgme_error_from_errno (int ERR)
1353 The function ‘gpgme_error_from_errno’ is like ‘gpgme_error’, but it
1354 takes a system error like ‘errno’ instead of a ‘gpgme_err_code_t’
1355 error code.
1356
1357 Sometimes you might want to map system error numbers to error codes
1358 directly, or map an error code representing a system error back to the
1359 system error number. The following functions can be used to do that.
1360
1361 -- Function: gpgme_err_code_t gpgme_err_code_from_errno (int ERR)
1362 The function ‘gpgme_err_code_from_errno’ returns the error code for
1363 the system error ERR. If ERR is not a known system error, the
1364 function returns ‘GPG_ERR_UNKNOWN_ERRNO’.
1365
1366 -- Function: int gpgme_err_code_to_errno (gpgme_err_code_t ERR)
1367 The function ‘gpgme_err_code_to_errno’ returns the system error for
1368 the error code ERR. If ERR is not an error code representing a
1369 system error, or if this system error is not defined on this
1370 system, the function returns ‘0’.
1371
1372 
1373 File: gpgme.info, Node: Error Sources, Next: Error Codes, Prev: Error Values, Up: Error Handling
1374
1375 5.2 Error Sources
1376 =================
1377
1378 The library ‘libgpg-error’ defines an error source for every component
1379 of the GnuPG system. The error source part of an error value is not
1380 well defined. As such it is mainly useful to improve the diagnostic
1381 error message for the user.
1382
1383 If the error code part of an error value is ‘0’, the whole error
1384 value will be ‘0’. In this case the error source part is of course
1385 ‘GPG_ERR_SOURCE_UNKNOWN’.
1386
1387 The list of error sources that might occur in applications using
1388 GPGME is:
1389
1390 ‘GPG_ERR_SOURCE_UNKNOWN’
1391 The error source is not known. The value of this error source is
1392 ‘0’.
1393
1394 ‘GPG_ERR_SOURCE_GPGME’
1395 The error source is GPGME itself. This is the default for errors
1396 that occur in the GPGME library.
1397
1398 ‘GPG_ERR_SOURCE_GPG’
1399 The error source is GnuPG, which is the crypto engine used for the
1400 OpenPGP protocol.
1401
1402 ‘GPG_ERR_SOURCE_GPGSM’
1403 The error source is GPGSM, which is the crypto engine used for the
1404 CMS protocol.
1405
1406 ‘GPG_ERR_SOURCE_GCRYPT’
1407 The error source is ‘libgcrypt’, which is used by crypto engines to
1408 perform cryptographic operations.
1409
1410 ‘GPG_ERR_SOURCE_GPGAGENT’
1411 The error source is ‘gpg-agent’, which is used by crypto engines to
1412 perform operations with the secret key.
1413
1414 ‘GPG_ERR_SOURCE_PINENTRY’
1415 The error source is ‘pinentry’, which is used by ‘gpg-agent’ to
1416 query the passphrase to unlock a secret key.
1417
1418 ‘GPG_ERR_SOURCE_SCD’
1419 The error source is the SmartCard Daemon, which is used by
1420 ‘gpg-agent’ to delegate operations with the secret key to a
1421 SmartCard.
1422
1423 ‘GPG_ERR_SOURCE_KEYBOX’
1424 The error source is ‘libkbx’, a library used by the crypto engines
1425 to manage local keyrings.
1426
1427 ‘GPG_ERR_SOURCE_USER_1’
1428 ‘GPG_ERR_SOURCE_USER_2’
1429 ‘GPG_ERR_SOURCE_USER_3’
1430 ‘GPG_ERR_SOURCE_USER_4’
1431 These error sources are not used by any GnuPG component and can be
1432 used by other software. For example, applications using GPGME can
1433 use them to mark error values coming from callback handlers. Thus
1434 ‘GPG_ERR_SOURCE_USER_1’ is the default for errors created with
1435 ‘gpgme_error’ and ‘gpgme_error_from_errno’, unless you define
1436 ‘GPGME_ERR_SOURCE_DEFAULT’ before including ‘gpgme.h’.
1437
1438 
1439 File: gpgme.info, Node: Error Codes, Next: Error Strings, Prev: Error Sources, Up: Error Handling
1440
1441 5.3 Error Codes
1442 ===============
1443
1444 The library ‘libgpg-error’ defines many error values. Most of them are
1445 not used by ‘GPGME’ directly, but might be returned by GPGME because it
1446 received them from the crypto engine. The below list only includes such
1447 error codes that have a specific meaning in ‘GPGME’, or which are so
1448 common that you should know about them.
1449
1450 ‘GPG_ERR_EOF’
1451 This value indicates the end of a list, buffer or file.
1452
1453 ‘GPG_ERR_NO_ERROR’
1454 This value indicates success. The value of this error code is ‘0’.
1455 Also, it is guaranteed that an error value made from the error code
1456 ‘0’ will be ‘0’ itself (as a whole). This means that the error
1457 source information is lost for this error code, however, as this
1458 error code indicates that no error occurred, this is generally not
1459 a problem.
1460
1461 ‘GPG_ERR_GENERAL’
1462 This value means that something went wrong, but either there is not
1463 enough information about the problem to return a more useful error
1464 value, or there is no separate error value for this type of
1465 problem.
1466
1467 ‘GPG_ERR_ENOMEM’
1468 This value means that an out-of-memory condition occurred.
1469
1470 ‘GPG_ERR_E...’
1471 System errors are mapped to GPG_ERR_FOO where FOO is the symbol for
1472 the system error.
1473
1474 ‘GPG_ERR_INV_VALUE’
1475 This value means that some user provided data was out of range.
1476 This can also refer to objects. For example, if an empty
1477 ‘gpgme_data_t’ object was expected, but one containing data was
1478 provided, this error value is returned.
1479
1480 ‘GPG_ERR_UNUSABLE_PUBKEY’
1481 This value means that some recipients for a message were invalid.
1482
1483 ‘GPG_ERR_UNUSABLE_SECKEY’
1484 This value means that some signers were invalid.
1485
1486 ‘GPG_ERR_NO_DATA’
1487 This value means that a ‘gpgme_data_t’ object which was expected to
1488 have content was found empty.
1489
1490 ‘GPG_ERR_CONFLICT’
1491 This value means that a conflict of some sort occurred.
1492
1493 ‘GPG_ERR_NOT_IMPLEMENTED’
1494 This value indicates that the specific function (or operation) is
1495 not implemented. This error should never happen. It can only
1496 occur if you use certain values or configuration options which do
1497 not work, but for which we think that they should work at some
1498 later time.
1499
1500 ‘GPG_ERR_DECRYPT_FAILED’
1501 This value indicates that a decryption operation was unsuccessful.
1502
1503 ‘GPG_ERR_BAD_PASSPHRASE’
1504 This value means that the user did not provide a correct passphrase
1505 when requested.
1506
1507 ‘GPG_ERR_CANCELED’
1508 This value means that the operation was canceled.
1509
1510 ‘GPG_ERR_INV_ENGINE’
1511 This value means that the engine that implements the desired
1512 protocol is currently not available. This can either be because
1513 the sources were configured to exclude support for this engine, or
1514 because the engine is not installed properly.
1515
1516 ‘GPG_ERR_AMBIGUOUS_NAME’
1517 This value indicates that a user ID or other specifier did not
1518 specify a unique key.
1519
1520 ‘GPG_ERR_WRONG_KEY_USAGE’
1521 This value indicates that a key is not used appropriately.
1522
1523 ‘GPG_ERR_CERT_REVOKED’
1524 This value indicates that a key signature was revoced.
1525
1526 ‘GPG_ERR_CERT_EXPIRED’
1527 This value indicates that a key signature expired.
1528
1529 ‘GPG_ERR_NO_CRL_KNOWN’
1530 This value indicates that no certificate revocation list is known
1531 for the certificate.
1532
1533 ‘GPG_ERR_NO_POLICY_MATCH’
1534 This value indicates that a policy issue occurred.
1535
1536 ‘GPG_ERR_NO_SECKEY’
1537 This value indicates that no secret key for the user ID is
1538 available.
1539
1540 ‘GPG_ERR_MISSING_CERT’
1541 This value indicates that a key could not be imported because the
1542 issuer certificate is missing.
1543
1544 ‘GPG_ERR_BAD_CERT_CHAIN’
1545 This value indicates that a key could not be imported because its
1546 certificate chain is not good, for example it could be too long.
1547
1548 ‘GPG_ERR_UNSUPPORTED_ALGORITHM’
1549 This value means a verification failed because the cryptographic
1550 algorithm is not supported by the crypto backend.
1551
1552 ‘GPG_ERR_BAD_SIGNATURE’
1553 This value means a verification failed because the signature is
1554 bad.
1555
1556 ‘GPG_ERR_NO_PUBKEY’
1557 This value means a verification failed because the public key is
1558 not available.
1559
1560 ‘GPG_ERR_USER_1’
1561 ‘GPG_ERR_USER_2’
1562 ‘...’
1563 ‘GPG_ERR_USER_16’
1564 These error codes are not used by any GnuPG component and can be
1565 freely used by other software. Applications using GPGME might use
1566 them to mark specific errors returned by callback handlers if no
1567 suitable error codes (including the system errors) for these errors
1568 exist already.
1569
1570 
1571 File: gpgme.info, Node: Error Strings, Prev: Error Codes, Up: Error Handling
1572
1573 5.4 Error Strings
1574 =================
1575
1576 -- Function: const char * gpgme_strerror (gpgme_error_t ERR)
1577 The function ‘gpgme_strerror’ returns a pointer to a statically
1578 allocated string containing a description of the error code
1579 contained in the error value ERR. This string can be used to
1580 output a diagnostic message to the user.
1581
1582 This function is not thread safe. Use ‘gpgme_strerror_r’ in
1583 multi-threaded programs.
1584
1585 -- Function: int gpgme_strerror_r (gpgme_error_t ERR, char *BUF,
1586 size_t BUFLEN)
1587 The function ‘gpgme_strerror_r’ returns the error string for ERR in
1588 the user-supplied buffer BUF of size BUFLEN. This function is, in
1589 contrast to ‘gpgme_strerror’, thread-safe if a thread-safe
1590 ‘strerror_r’ function is provided by the system. If the function
1591 succeeds, 0 is returned and BUF contains the string describing the
1592 error. If the buffer was not large enough, ERANGE is returned and
1593 BUF contains as much of the beginning of the error string as fits
1594 into the buffer.
1595
1596 -- Function: const char * gpgme_strsource (gpgme_error_t ERR)
1597 The function ‘gpgme_strerror’ returns a pointer to a statically
1598 allocated string containing a description of the error source
1599 contained in the error value ERR. This string can be used to
1600 output a diagnostic message to the user.
1601
1602 The following example illustrates the use of ‘gpgme_strerror’:
1603
1604 gpgme_ctx_t ctx;
1605 gpgme_error_t err = gpgme_new (&ctx);
1606 if (err)
1607 {
1608 fprintf (stderr, "%s: creating GpgME context failed: %s: %s\n",
1609 argv[0], gpgme_strsource (err), gpgme_strerror (err));
1610 exit (1);
1611 }
1612
1613 
1614 File: gpgme.info, Node: Exchanging Data, Next: Contexts, Prev: Error Handling, Up: Top
1615
1616 6 Exchanging Data
1617 *****************
1618
1619 A lot of data has to be exchanged between the user and the crypto
1620 engine, like plaintext messages, ciphertext, signatures and information
1621 about the keys. The technical details about exchanging the data
1622 information are completely abstracted by GPGME. The user provides and
1623 receives the data via ‘gpgme_data_t’ objects, regardless of the
1624 communication protocol between GPGME and the crypto engine in use.
1625
1626 -- Data type: gpgme_data_t
1627 The ‘gpgme_data_t’ type is a handle for a container for generic
1628 data, which is used by GPGME to exchange data with the user.
1629
1630 ‘gpgme_data_t’ objects do not provide notifications on events. It is
1631 assumed that read and write operations are blocking until data is
1632 available. If this is undesirable, the application must ensure that all
1633 GPGME data operations always have data available, for example by using
1634 memory buffers or files rather than pipes or sockets. This might be
1635 relevant, for example, if the external event loop mechanism is used.
1636
1637 -- Data type: gpgme_off_t
1638 SINCE: 1.4.1
1639
1640 On POSIX platforms the ‘gpgme_off_t’ type is an alias for ‘off_t’;
1641 it may be used interchangeable. On Windows platforms ‘gpgme_off_t’
1642 is defined as a long (i.e. 32 bit) for 32 bit Windows and as a 64
1643 bit signed integer for 64 bit Windows.
1644
1645 -- Data type: gpgme_ssize_t
1646 The ‘gpgme_ssize_t’ type is an alias for ‘ssize_t’. It has only
1647 been introduced to overcome portability problems pertaining to the
1648 declaration of ‘ssize_t’ by different toolchains.
1649
1650 * Menu:
1651
1652 * Creating Data Buffers:: Creating new data buffers.
1653 * Destroying Data Buffers:: Releasing data buffers.
1654 * Manipulating Data Buffers:: Operations on data buffers.
1655
1656 
1657 File: gpgme.info, Node: Creating Data Buffers, Next: Destroying Data Buffers, Up: Exchanging Data
1658
1659 6.1 Creating Data Buffers
1660 =========================
1661
1662 Data objects can be based on memory, files, or callback functions
1663 provided by the user. Not all operations are supported by all objects.
1664
1665 * Menu:
1666
1667 * Memory Based Data Buffers:: Creating memory based data buffers.
1668 * File Based Data Buffers:: Creating file based data buffers.
1669 * Callback Based Data Buffers:: Creating callback based data buffers.
1670
1671 
1672 File: gpgme.info, Node: Memory Based Data Buffers, Next: File Based Data Buffers, Up: Creating Data Buffers
1673
1674 6.1.1 Memory Based Data Buffers
1675 -------------------------------
1676
1677 Memory based data objects store all data in allocated memory. This is
1678 convenient, but only practical for an amount of data that is a fraction
1679 of the available physical memory. The data has to be copied from its
1680 source and to its destination, which can often be avoided by using one
1681 of the other data object
1682
1683 -- Function: gpgme_error_t gpgme_data_new (gpgme_data_t *DH)
1684 The function ‘gpgme_data_new’ creates a new ‘gpgme_data_t’ object
1685 and returns a handle for it in DH. The data object is memory based
1686 and initially empty.
1687
1688 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1689 object was successfully created, ‘GPG_ERR_INV_VALUE’ if DH is not a
1690 valid pointer, and ‘GPG_ERR_ENOMEM’ if not enough memory is
1691 available.
1692
1693 -- Function: gpgme_error_t gpgme_data_new_from_mem (gpgme_data_t *DH,
1694 const char *BUFFER, size_t SIZE, int COPY)
1695 The function ‘gpgme_data_new_from_mem’ creates a new ‘gpgme_data_t’
1696 object and fills it with SIZE bytes starting from BUFFER.
1697
1698 If COPY is not zero, a private copy of the data is made. If COPY
1699 is zero, the data is taken from the specified buffer as needed, and
1700 the user has to ensure that the buffer remains valid for the whole
1701 life span of the data object.
1702
1703 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1704 object was successfully created, ‘GPG_ERR_INV_VALUE’ if DH or
1705 BUFFER is not a valid pointer, and ‘GPG_ERR_ENOMEM’ if not enough
1706 memory is available.
1707
1708 -- Function: gpgme_error_t gpgme_data_new_from_file (gpgme_data_t *DH,
1709 const char *FILENAME, int COPY)
1710 The function ‘gpgme_data_new_from_file’ creates a new
1711 ‘gpgme_data_t’ object and fills it with the content of the file
1712 FILENAME.
1713
1714 If COPY is not zero, the whole file is read in at initialization
1715 time and the file is not used anymore after that. This is the only
1716 mode supported currently. Later, a value of zero for COPY might
1717 cause all reads to be delayed until the data is needed, but this is
1718 not yet implemented.
1719
1720 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1721 object was successfully created, ‘GPG_ERR_INV_VALUE’ if DH or
1722 FILENAME is not a valid pointer, ‘GPG_ERR_NOT_IMPLEMENTED’ if CODE
1723 is zero, and ‘GPG_ERR_ENOMEM’ if not enough memory is available.
1724
1725 -- Function: gpgme_error_t gpgme_data_new_from_filepart
1726 (gpgme_data_t *DH, const char *FILENAME, FILE *FP,
1727 off_t OFFSET, size_t LENGTH)
1728 The function ‘gpgme_data_new_from_filepart’ creates a new
1729 ‘gpgme_data_t’ object and fills it with a part of the file
1730 specified by FILENAME or FP.
1731
1732 Exactly one of FILENAME and FP must be non-zero, the other must be
1733 zero. The argument that is not zero specifies the file from which
1734 LENGTH bytes are read into the data object, starting from OFFSET.
1735
1736 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1737 object was successfully created, ‘GPG_ERR_INV_VALUE’ if DH and
1738 exactly one of FILENAME and FP is not a valid pointer, and
1739 ‘GPG_ERR_ENOMEM’ if not enough memory is available.
1740
1741 
1742 File: gpgme.info, Node: File Based Data Buffers, Next: Callback Based Data Buffers, Prev: Memory Based Data Buffers, Up: Creating Data Buffers
1743
1744 6.1.2 File Based Data Buffers
1745 -----------------------------
1746
1747 File based data objects operate directly on file descriptors or streams.
1748 Only a small amount of data is stored in core at any time, so the size
1749 of the data objects is not limited by GPGME.
1750
1751 -- Function: gpgme_error_t gpgme_data_new_from_fd (gpgme_data_t *DH,
1752 int FD)
1753 The function ‘gpgme_data_new_from_fd’ creates a new ‘gpgme_data_t’
1754 object and uses the file descriptor FD to read from (if used as an
1755 input data object) and write to (if used as an output data object).
1756
1757 When using the data object as an input buffer, the function might
1758 read a bit more from the file descriptor than is actually needed by
1759 the crypto engine in the desired operation because of internal
1760 buffering.
1761
1762 Note that GPGME assumes that the file descriptor is set to blocking
1763 mode. Errors during I/O operations, except for EINTR, are usually
1764 fatal for crypto operations.
1765
1766 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1767 object was successfully created, and ‘GPG_ERR_ENOMEM’ if not enough
1768 memory is available.
1769
1770 -- Function: gpgme_error_t gpgme_data_new_from_stream
1771 (gpgme_data_t *DH, FILE *STREAM)
1772 The function ‘gpgme_data_new_from_stream’ creates a new
1773 ‘gpgme_data_t’ object and uses the I/O stream STREAM to read from
1774 (if used as an input data object) and write to (if used as an
1775 output data object).
1776
1777 When using the data object as an input buffer, the function might
1778 read a bit more from the stream than is actually needed by the
1779 crypto engine in the desired operation because of internal
1780 buffering.
1781
1782 Note that GPGME assumes that the stream is in blocking mode.
1783 Errors during I/O operations, except for EINTR, are usually fatal
1784 for crypto operations.
1785
1786 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1787 object was successfully created, and ‘GPG_ERR_ENOMEM’ if not enough
1788 memory is available.
1789
1790 -- Function: gpgme_error_t gpgme_data_new_from_estream
1791 (gpgme_data_t *DH, gpgrt_stream_t STREAM)
1792 The function ‘gpgme_data_new_from_estream’ creates a new
1793 ‘gpgme_data_t’ object and uses the gpgrt stream STREAM to read from
1794 (if used as an input data object) and write to (if used as an
1795 output data object).
1796
1797 When using the data object as an input buffer, the function might
1798 read a bit more from the stream than is actually needed by the
1799 crypto engine in the desired operation because of internal
1800 buffering.
1801
1802 Note that GPGME assumes that the stream is in blocking mode.
1803 Errors during I/O operations, except for EINTR, are usually fatal
1804 for crypto operations.
1805
1806 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1807 object was successfully created, and ‘GPG_ERR_ENOMEM’ if not enough
1808 memory is available.
1809
1810 
1811 File: gpgme.info, Node: Callback Based Data Buffers, Prev: File Based Data Buffers, Up: Creating Data Buffers
1812
1813 6.1.3 Callback Based Data Buffers
1814 ---------------------------------
1815
1816 If neither memory nor file based data objects are a good fit for your
1817 application, you can implement the functions a data object provides
1818 yourself and create a data object from these callback functions.
1819
1820 -- Data type: ssize_t (*gpgme_data_read_cb_t) (void *HANDLE,
1821 void *BUFFER, size_t SIZE)
1822 The ‘gpgme_data_read_cb_t’ type is the type of functions which
1823 GPGME calls if it wants to read data from a user-implemented data
1824 object. The function should read up to SIZE bytes from the current
1825 read position into the space starting at BUFFER. The HANDLE is
1826 provided by the user at data object creation time.
1827
1828 Note that GPGME assumes that the read blocks until data is
1829 available. Errors during I/O operations, except for EINTR, are
1830 usually fatal for crypto operations.
1831
1832 The function should return the number of bytes read, 0 on EOF, and
1833 -1 on error. If an error occurs, ERRNO should be set to describe
1834 the type of the error.
1835
1836 -- Data type: ssize_t (*gpgme_data_write_cb_t) (void *HANDLE,
1837 const void *BUFFER, size_t SIZE)
1838 The ‘gpgme_data_write_cb_t’ type is the type of functions which
1839 GPGME calls if it wants to write data to a user-implemented data
1840 object. The function should write up to SIZE bytes to the current
1841 write position from the space starting at BUFFER. The HANDLE is
1842 provided by the user at data object creation time.
1843
1844 Note that GPGME assumes that the write blocks until data is
1845 available. Errors during I/O operations, except for EINTR, are
1846 usually fatal for crypto operations.
1847
1848 The function should return the number of bytes written, and -1 on
1849 error. If an error occurs, ERRNO should be set to describe the
1850 type of the error.
1851
1852 -- Data type: off_t (*gpgme_data_seek_cb_t) (void *HANDLE,
1853 off_t OFFSET, int WHENCE)
1854 The ‘gpgme_data_seek_cb_t’ type is the type of functions which
1855 GPGME calls if it wants to change the current read/write position
1856 in a user-implemented data object, just like the ‘lseek’ function.
1857
1858 The function should return the new read/write position, and -1 on
1859 error. If an error occurs, ERRNO should be set to describe the
1860 type of the error.
1861
1862 -- Data type: void (*gpgme_data_release_cb_t) (void *HANDLE)
1863 The ‘gpgme_data_release_cb_t’ type is the type of functions which
1864 GPGME calls if it wants to destroy a user-implemented data object.
1865 The HANDLE is provided by the user at data object creation time.
1866
1867 -- Data type: struct gpgme_data_cbs
1868 This structure is used to store the data callback interface
1869 functions described above. It has the following members:
1870
1871 ‘gpgme_data_read_cb_t read’
1872 This is the function called by GPGME to read data from the
1873 data object. It is only required for input data object.
1874
1875 ‘gpgme_data_write_cb_t write’
1876 This is the function called by GPGME to write data to the data
1877 object. It is only required for output data object.
1878
1879 ‘gpgme_data_seek_cb_t seek’
1880 This is the function called by GPGME to change the current
1881 read/write pointer in the data object (if available). It is
1882 optional.
1883
1884 ‘gpgme_data_release_cb_t release’
1885 This is the function called by GPGME to release a data object.
1886 It is optional.
1887
1888 -- Function: gpgme_error_t gpgme_data_new_from_cbs (gpgme_data_t *DH,
1889 gpgme_data_cbs_t CBS, void *HANDLE)
1890 The function ‘gpgme_data_new_from_cbs’ creates a new ‘gpgme_data_t’
1891 object and uses the user-provided callback functions to operate on
1892 the data object.
1893
1894 The handle HANDLE is passed as first argument to the callback
1895 functions. This can be used to identify this data object.
1896
1897 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the data
1898 object was successfully created, and ‘GPG_ERR_ENOMEM’ if not enough
1899 memory is available.
1900
1901 
1902 File: gpgme.info, Node: Destroying Data Buffers, Next: Manipulating Data Buffers, Prev: Creating Data Buffers, Up: Exchanging Data
1903
1904 6.2 Destroying Data Buffers
1905 ===========================
1906
1907 -- Function: void gpgme_data_release (gpgme_data_t DH)
1908 The function ‘gpgme_data_release’ destroys the data object with the
1909 handle DH. It releases all associated resources that were not
1910 provided by the user in the first place.
1911
1912 -- Function: char * gpgme_data_release_and_get_mem (gpgme_data_t DH,
1913 size_t *LENGTH)
1914 The function ‘gpgme_data_release_and_get_mem’ is like
1915 ‘gpgme_data_release’, except that it returns the data buffer and
1916 its length that was provided by the object.
1917
1918 The user has to release the buffer with ‘gpgme_free’. In case the
1919 user provided the data buffer in non-copy mode, a copy will be made
1920 for this purpose.
1921
1922 In case an error returns, or there is no suitable data buffer that
1923 can be returned to the user, the function will return ‘NULL’. In
1924 any case, the data object DH is destroyed.
1925
1926 -- Function: void gpgme_free (void *BUFFER)
1927 SINCE: 1.1.1
1928
1929 The function ‘gpgme_free’ releases the memory returned by
1930 ‘gpgme_data_release_and_get_mem’ and ‘gpgme_pubkey_algo_string’.
1931 It should be used instead of the system libraries ‘free’ function
1932 in case different allocators are used by a program. This is often
1933 the case if gpgme is used under Windows as a DLL.
1934
1935 
1936 File: gpgme.info, Node: Manipulating Data Buffers, Prev: Destroying Data Buffers, Up: Exchanging Data
1937
1938 6.3 Manipulating Data Buffers
1939 =============================
1940
1941 Data buffers contain data and meta-data. The following operations can
1942 be used to manipulate both.
1943
1944 * Menu:
1945
1946 * Data Buffer I/O Operations:: I/O operations on data buffers.
1947 * Data Buffer Meta-Data:: Meta-data manipulation of data buffers.
1948 * Data Buffer Convenience:: Convenience function for data buffers.
1949
1950 
1951 File: gpgme.info, Node: Data Buffer I/O Operations, Next: Data Buffer Meta-Data, Up: Manipulating Data Buffers
1952
1953 6.3.1 Data Buffer I/O Operations
1954 --------------------------------
1955
1956 -- Function: ssize_t gpgme_data_read (gpgme_data_t DH, void *BUFFER,
1957 size_t LENGTH)
1958 The function ‘gpgme_data_read’ reads up to LENGTH bytes from the
1959 data object with the handle DH into the space starting at BUFFER.
1960
1961 If no error occurs, the actual amount read is returned. If the end
1962 of the data object is reached, the function returns 0.
1963
1964 In all other cases, the function returns -1 and sets ERRNO.
1965
1966 -- Function: ssize_t gpgme_data_write (gpgme_data_t DH,
1967 const void *BUFFER, size_t SIZE)
1968 The function ‘gpgme_data_write’ writes up to SIZE bytes starting
1969 from BUFFER into the data object with the handle DH at the current
1970 write position.
1971
1972 The function returns the number of bytes actually written, or -1 if
1973 an error occurs. If an error occurs, ERRNO is set.
1974
1975 -- Function: off_t gpgme_data_seek (gpgme_data_t DH, off_t OFFSET,
1976 int WHENCE)
1977 The function ‘gpgme_data_seek’ changes the current read/write
1978 position.
1979
1980 The WHENCE argument specifies how the OFFSET should be interpreted.
1981 It must be one of the following symbolic constants:
1982
1983 ‘SEEK_SET’
1984 Specifies that OFFSET is a count of characters from the
1985 beginning of the data object.
1986
1987 ‘SEEK_CUR’
1988 Specifies that OFFSET is a count of characters from the
1989 current file position. This count may be positive or
1990 negative.
1991
1992 ‘SEEK_END’
1993 Specifies that OFFSET is a count of characters from the end of
1994 the data object. A negative count specifies a position within
1995 the current extent of the data object; a positive count
1996 specifies a position past the current end. If you set the
1997 position past the current end, and actually write data, you
1998 will extend the data object with zeros up to that position.
1999
2000 If successful, the function returns the resulting file position,
2001 measured in bytes from the beginning of the data object. You can
2002 use this feature together with ‘SEEK_CUR’ to read the current
2003 read/write position.
2004
2005 If the function fails, -1 is returned and ERRNO is set.
2006
2007 
2008 File: gpgme.info, Node: Data Buffer Meta-Data, Next: Data Buffer Convenience, Prev: Data Buffer I/O Operations, Up: Manipulating Data Buffers
2009
2010 6.3.2 Data Buffer Meta-Data
2011 ---------------------------
2012
2013 -- Function: char * gpgme_data_get_file_name (gpgme_data_t DH)
2014 SINCE: 1.1.0
2015
2016 The function ‘gpgme_data_get_file_name’ returns a pointer to a
2017 string containing the file name associated with the data object.
2018 The file name will be stored in the output when encrypting or
2019 signing the data and will be returned to the user when decrypting
2020 or verifying the output data.
2021
2022 If no error occurs, the string containing the file name is
2023 returned. Otherwise, ‘NULL’ will be returned.
2024
2025 -- Function: gpgme_error_t gpgme_data_set_file_name (gpgme_data_t DH,
2026 const char *FILE_NAME)
2027 SINCE: 1.1.0
2028
2029 The function ‘gpgme_data_set_file_name’ sets the file name
2030 associated with the data object. The file name will be stored in
2031 the output when encrypting or signing the data and will be returned
2032 to the user when decrypting or verifying the output data.
2033
2034 The function returns the error code ‘GPG_ERR_INV_VALUE’ if DH is
2035 not a valid pointer and ‘GPG_ERR_ENOMEM’ if not enough memory is
2036 available.
2037
2038 -- Data type: enum gpgme_data_encoding_t
2039 The ‘gpgme_data_encoding_t’ type specifies the encoding of a
2040 ‘gpgme_data_t’ object. For input data objects, the encoding is
2041 useful to give the backend a hint on the type of data. For output
2042 data objects, the encoding can specify the output data format on
2043 certain operations. Please note that not all backends support all
2044 encodings on all operations. The following data types are
2045 available:
2046
2047 ‘GPGME_DATA_ENCODING_NONE’
2048 This specifies that the encoding is not known. This is the
2049 default for a new data object. The backend will try its best
2050 to detect the encoding automatically.
2051
2052 ‘GPGME_DATA_ENCODING_BINARY’
2053 This specifies that the data is encoding in binary form; i.e.
2054 there is no special encoding.
2055
2056 ‘GPGME_DATA_ENCODING_BASE64’
2057 This specifies that the data is encoded using the Base-64
2058 encoding scheme as used by MIME and other protocols.
2059
2060 ‘GPGME_DATA_ENCODING_ARMOR’
2061 This specifies that the data is encoded in an armored form as
2062 used by OpenPGP and PEM.
2063
2064 ‘GPGME_DATA_ENCODING_MIME’
2065 SINCE: 1.7.0
2066
2067 This specifies that the data is encoded as a MIME part.
2068
2069 ‘GPGME_DATA_ENCODING_URL’
2070 SINCE: 1.2.0
2071
2072 The data is a list of linefeed delimited URLs. This is only
2073 useful with ‘gpgme_op_import’.
2074
2075 ‘GPGME_DATA_ENCODING_URL0’
2076 SINCE: 1.2.0
2077
2078 The data is a list of binary zero delimited URLs. This is
2079 only useful with ‘gpgme_op_import’.
2080
2081 ‘GPGME_DATA_ENCODING_URLESC’
2082 SINCE: 1.2.0
2083
2084 The data is a list of linefeed delimited URLs with all control
2085 and space characters percent escaped. This mode is is not yet
2086 implemented.
2087
2088 -- Function: gpgme_data_encoding_t gpgme_data_get_encoding
2089 (gpgme_data_t DH)
2090 The function ‘gpgme_data_get_encoding’ returns the encoding of the
2091 data object with the handle DH. If DH is not a valid pointer (e.g.
2092 ‘NULL’) ‘GPGME_DATA_ENCODING_NONE’ is returned.
2093
2094 -- Function: gpgme_error_t gpgme_data_set_encoding
2095 (gpgme_data_t DH, gpgme_data_encoding_t ENC)
2096 The function ‘gpgme_data_set_encoding’ changes the encoding of the
2097 data object with the handle DH to ENC.
2098
2099 -- Function: gpgme_error_t gpgme_data_set_flag (gpgme_data_t DH,
2100 const char *NAME, const char *VALUE)
2101
2102 SINCE: 1.7.0
2103
2104 Some minor properties of the data object can be controlled with
2105 flags set by this function. The properties are identified by the
2106 following values for NAME:
2107
2108 ‘size-hint’
2109 The value is a decimal number with the length gpgme shall
2110 assume for this data object. This is useful if the data is
2111 provided by callbacks or via file descriptors but the
2112 applications knows the total size of the data. If this is set
2113 the OpenPGP engine may use this to decide on buffer allocation
2114 strategies and to provide a total value for its progress
2115 information.
2116
2117 ‘io-buffer-size’
2118 The value is a decimal number with the length of internal
2119 buffers to used for internal I/O operations. The value is
2120 capped at 1048576 (1 MiB). In certain environments large
2121 buffers can yield a performance boost for callback bases data
2122 object, but the details depend a lot on the circumstances and
2123 the operating system. This flag may only be set once and must
2124 be set before any actual I/O happens ion the data objects.
2125
2126 ‘sensitive’
2127 If the numeric value is not 0 the data object is considered to
2128 contain sensitive information like passwords or key material.
2129 If this is set the internal buffers are securely overwritten
2130 with zeroes by gpgme_data_release.
2131
2132 This function returns ‘0’ on success.
2133
2134 
2135 File: gpgme.info, Node: Data Buffer Convenience, Prev: Data Buffer Meta-Data, Up: Manipulating Data Buffers
2136
2137 6.3.3 Data Buffer Convenience Functions
2138 ---------------------------------------
2139
2140 -- Data type: enum gpgme_data_type_t
2141 SINCE: 1.4.3
2142
2143 The ‘gpgme_data_type_t’ type is used to return the detected type of
2144 the content of a data buffer.
2145
2146 ‘GPGME_DATA_TYPE_INVALID’
2147 This is returned by ‘gpgme_data_identify’ if it was not possible to
2148 identify the data. Reasons for this might be a non-seekable stream
2149 or a memory problem. The value is 0.
2150 ‘GPGME_DATA_TYPE_UNKNOWN’
2151 The type of the data is not known.
2152 ‘GPGME_DATA_TYPE_PGP_SIGNED’
2153 The data is an OpenPGP signed message. This may be a binary
2154 signature, a detached one or a cleartext signature.
2155 ‘GPGME_DATA_TYPE_PGP_ENCRYPTED’
2156 SINCE: 1.7.0
2157
2158 The data is an OpenPGP encrypted message.
2159 ‘GPGME_DATA_TYPE_PGP_SIGNATURE’
2160 SINCE: 1.7.0
2161
2162 The data is an OpenPGP detached signature.
2163 ‘GPGME_DATA_TYPE_PGP_OTHER’
2164 This is a generic OpenPGP message. In most cases this will be
2165 encrypted data.
2166 ‘GPGME_DATA_TYPE_PGP_KEY’
2167 This is an OpenPGP key (private or public).
2168 ‘GPGME_DATA_TYPE_CMS_SIGNED’
2169 This is a CMS signed message.
2170 ‘GPGME_DATA_TYPE_CMS_ENCRYPTED’
2171 This is a CMS encrypted (enveloped data) message.
2172 ‘GPGME_DATA_TYPE_CMS_OTHER’
2173 This is used for other CMS message types.
2174 ‘GPGME_DATA_TYPE_X509_CERT’
2175 The data is a X.509 certificate
2176 ‘GPGME_DATA_TYPE_PKCS12’
2177 The data is a PKCS#12 message. This is commonly used to exchange
2178 private keys for X.509.
2179
2180 -- Function: gpgme_data_type_t gpgme_data_identify (gpgme_data_t DH)
2181 SINCE: 1.4.3
2182
2183 The function ‘gpgme_data_identify’ returns the type of the data
2184 with the handle DH. If it is not possible to perform the
2185 identification, the function returns zero
2186 (‘GPGME_DATA_TYPE_INVALID’). Note that depending on how the data
2187 object has been created the identification may not be possible or
2188 the data object may change its internal state (file pointer moved).
2189 For file or memory based data object, the state should not change.
2190
2191 
2192 File: gpgme.info, Node: Contexts, Next: UI Server Protocol, Prev: Exchanging Data, Up: Top
2193
2194 7 Contexts
2195 **********
2196
2197 All cryptographic operations in GPGME are performed within a context,
2198 which contains the internal state of the operation as well as
2199 configuration parameters. By using several contexts you can run several
2200 cryptographic operations in parallel, with different configuration.
2201
2202 -- Data type: gpgme_ctx_t
2203 The ‘gpgme_ctx_t’ type is a handle for a GPGME context, which is
2204 used to hold the configuration, status and result of cryptographic
2205 operations.
2206
2207 * Menu:
2208
2209 * Creating Contexts:: Creating new GPGME contexts.
2210 * Destroying Contexts:: Releasing GPGME contexts.
2211 * Result Management:: Managing the result of crypto operations.
2212 * Context Attributes:: Setting properties of a context.
2213 * Key Management:: Managing keys with GPGME.
2214 * Crypto Operations:: Using a context for cryptography.
2215 * Miscellaneous:: Miscellaneous operations
2216 * Run Control:: Controlling how operations are run.
2217
2218 
2219 File: gpgme.info, Node: Creating Contexts, Next: Destroying Contexts, Up: Contexts
2220
2221 7.1 Creating Contexts
2222 =====================
2223
2224 -- Function: gpgme_error_t gpgme_new (gpgme_ctx_t *CTX)
2225 The function ‘gpgme_new’ creates a new ‘gpgme_ctx_t’ object and
2226 returns a handle for it in CTX.
2227
2228 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
2229 context was successfully created, ‘GPG_ERR_INV_VALUE’ if CTX is not
2230 a valid pointer, and ‘GPG_ERR_ENOMEM’ if not enough memory is
2231 available. Also, it returns ‘GPG_ERR_NOT_OPERATIONAL’ if
2232 ‘gpgme_check_version’ was not called to initialize GPGME, and
2233 ‘GPG_ERR_SELFTEST_FAILED’ if a selftest failed. Currently, the
2234 only selftest is for Windows MingW32 targets to see if
2235 ‘-mms-bitfields’ was used (as required).
2236
2237 
2238 File: gpgme.info, Node: Destroying Contexts, Next: Result Management, Prev: Creating Contexts, Up: Contexts
2239
2240 7.2 Destroying Contexts
2241 =======================
2242
2243 -- Function: void gpgme_release (gpgme_ctx_t CTX)
2244 The function ‘gpgme_release’ destroys the context with the handle
2245 CTX and releases all associated resources.
2246
2247 
2248 File: gpgme.info, Node: Result Management, Next: Context Attributes, Prev: Destroying Contexts, Up: Contexts
2249
2250 7.3 Result Management
2251 =====================
2252
2253 The detailed result of an operation is returned in operation-specific
2254 structures such as ‘gpgme_decrypt_result_t’. The corresponding
2255 retrieval functions such as ‘gpgme_op_decrypt_result’ provide static
2256 access to the results after an operation completes. Those structures
2257 shall be considered read-only and an application must not allocate such
2258 a structure on its own. The following interfaces make it possible to
2259 detach a result structure from its associated context and give it a
2260 lifetime beyond that of the current operation or context.
2261
2262 -- Function: void gpgme_result_ref (void *RESULT)
2263 SINCE: 1.2.0
2264
2265 The function ‘gpgme_result_ref’ acquires an additional reference
2266 for the result RESULT, which may be of any type ‘gpgme_*_result_t’.
2267 As long as the user holds a reference, the result structure is
2268 guaranteed to be valid and unmodified.
2269
2270 -- Function: void gpgme_result_unref (void *RESULT)
2271 SINCE: 1.2.0
2272
2273 The function ‘gpgme_result_unref’ releases a reference for the
2274 result RESULT. If this was the last reference, the result
2275 structure will be destroyed and all resources associated to it will
2276 be released.
2277
2278 Note that a context may hold its own references to result structures,
2279 typically until the context is destroyed or the next operation is
2280 started. In fact, these references are accessed through the
2281 ‘gpgme_op_*_result’ functions.
2282
2283 
2284 File: gpgme.info, Node: Context Attributes, Next: Key Management, Prev: Result Management, Up: Contexts
2285
2286 7.4 Context Attributes
2287 ======================
2288
2289 * Menu:
2290
2291 * Protocol Selection:: Selecting the protocol used by a context.
2292 * Crypto Engine:: Configuring the crypto engine.
2293 * Setting the Sender:: How to tell the engine the sender.
2294 * ASCII Armor:: Requesting ASCII armored output.
2295 * Text Mode:: Choosing canonical text mode.
2296 * Offline Mode:: Choosing offline mode.
2297 * Pinentry Mode:: Choosing the pinentry mode.
2298 * Included Certificates:: Including a number of certificates.
2299 * Key Listing Mode:: Selecting key listing mode.
2300 * Passphrase Callback:: Getting the passphrase from the user.
2301 * Progress Meter Callback:: Being informed about the progress.
2302 * Status Message Callback:: Status messages received from gpg.
2303 * Context Flags:: Additional flags for a context.
2304 * Locale:: Setting the locale of a context.
2305 * Additional Logs:: Additional logs of a context.
2306
2307 
2308 File: gpgme.info, Node: Protocol Selection, Next: Crypto Engine, Up: Context Attributes
2309
2310 7.4.1 Protocol Selection
2311 ------------------------
2312
2313 -- Function: gpgme_error_t gpgme_set_protocol (gpgme_ctx_t CTX,
2314 gpgme_protocol_t PROTO)
2315 The function ‘gpgme_set_protocol’ sets the protocol used within the
2316 context CTX to PROTO. All crypto operations will be performed by
2317 the crypto engine configured for that protocol. *Note Protocols
2318 and Engines::.
2319
2320 Setting the protocol with ‘gpgme_set_protocol’ does intentionally
2321 not check if the crypto engine for that protocol is available and
2322 installed correctly. *Note Engine Version Check::.
2323
2324 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
2325 protocol could be set successfully, and ‘GPG_ERR_INV_VALUE’ if
2326 PROTOCOL is not a valid protocol.
2327
2328 -- Function: gpgme_protocol_t gpgme_get_protocol (gpgme_ctx_t CTX)
2329 The function ‘gpgme_get_protocol’ retrieves the protocol currently
2330 use with the context CTX.
2331
2332 
2333 File: gpgme.info, Node: Crypto Engine, Next: Setting the Sender, Prev: Protocol Selection, Up: Context Attributes
2334
2335 7.4.2 Crypto Engine
2336 -------------------
2337
2338 The following functions can be used to set and retrieve the
2339 configuration of the crypto engines of a specific context. The default
2340 can also be retrieved without any particular context. *Note Engine
2341 Information::. The default can also be changed globally. *Note Engine
2342 Configuration::.
2343
2344 -- Function: gpgme_engine_info_t gpgme_ctx_get_engine_info
2345 (gpgme_ctx_t CTX)
2346 SINCE: 1.1.0
2347
2348 The function ‘gpgme_ctx_get_engine_info’ returns a linked list of
2349 engine info structures. Each info structure describes the
2350 configuration of one configured backend, as used by the context
2351 CTX.
2352
2353 The result is valid until the next invocation of
2354 ‘gpgme_ctx_set_engine_info’ for this particular context.
2355
2356 This function can not fail.
2357
2358 -- Function: gpgme_error_t gpgme_ctx_set_engine_info (gpgme_ctx_t CTX,
2359 gpgme_protocol_t PROTO, const char *FILE_NAME,
2360 const char *HOME_DIR)
2361 SINCE: 1.1.0
2362
2363 The function ‘gpgme_ctx_set_engine_info’ changes the configuration
2364 of the crypto engine implementing the protocol PROTO for the
2365 context CTX.
2366
2367 FILE_NAME is the file name of the executable program implementing
2368 this protocol, and HOME_DIR is the directory name of the
2369 configuration directory for this crypto engine. If HOME_DIR is
2370 ‘NULL’, the engine’s default will be used.
2371
2372 Currently this function must be used before starting the first
2373 crypto operation. It is unspecified if and when the changes will
2374 take effect if the function is called after starting the first
2375 operation on the context CTX.
2376
2377 This function returns the error code ‘GPG_ERR_NO_ERROR’ if
2378 successful, or an error code on failure.
2379
2380 
2381 File: gpgme.info, Node: Setting the Sender, Next: ASCII Armor, Prev: Crypto Engine, Up: Context Attributes
2382
2383 7.4.3 How to tell the engine the sender.
2384 ----------------------------------------
2385
2386 Some engines can make use of the sender’s address, for example to figure
2387 out the best user id in certain trust models. For verification and
2388 signing of mails, it is thus suggested to let the engine know the sender
2389 ("From:") address. GPGME provides two functions to accomplish that.
2390 Note that the esoteric use of multiple "From:" addresses is not
2391 supported.
2392
2393 -- Function: gpgme_error_t gpgme_set_sender (gpgme_ctx_t CTX,
2394 int ADDRESS)
2395
2396 SINCE: 1.8.0
2397
2398 The function ‘gpgme_set_sender’ specifies the sender address for
2399 use in sign and verify operations. ADDRESS is expected to be the
2400 “addr-spec” part of an address but my also be a complete mailbox
2401 address, in which case this function extracts the “addr-spec” from
2402 it. Using ‘NULL’ for ADDRESS clears the sender address.
2403
2404 The function returns 0 on success or an error code on failure. The
2405 most likely failure is that no valid “addr-spec” was found in
2406 ADDRESS.
2407
2408 -- Function: const char * gpgme_get_sender (gpgme_ctx_t CTX)
2409
2410 SINCE: 1.8.0
2411
2412 The function ‘gpgme_get_sender’ returns the current sender address
2413 from the context, or NULL if none was set. The returned value is
2414 valid as long as the CTX is valid and ‘gpgme_set_sender’ has not
2415 been called again.
2416
2417 
2418 File: gpgme.info, Node: ASCII Armor, Next: Text Mode, Prev: Setting the Sender, Up: Context Attributes
2419
2420 7.4.4 ASCII Armor
2421 -----------------
2422
2423 -- Function: void gpgme_set_armor (gpgme_ctx_t CTX, int YES)
2424 The function ‘gpgme_set_armor’ specifies if the output should be
2425 ASCII armored. By default, output is not ASCII armored.
2426
2427 ASCII armored output is disabled if YES is zero, and enabled
2428 otherwise.
2429
2430 -- Function: int gpgme_get_armor (gpgme_ctx_t CTX)
2431 The function ‘gpgme_get_armor’ returns 1 if the output is ASCII
2432 armored, and ‘0’ if it is not, or if CTX is not a valid pointer.
2433
2434 
2435 File: gpgme.info, Node: Text Mode, Next: Offline Mode, Prev: ASCII Armor, Up: Context Attributes
2436
2437 7.4.5 Text Mode
2438 ---------------
2439
2440 -- Function: void gpgme_set_textmode (gpgme_ctx_t CTX, int YES)
2441 The function ‘gpgme_set_textmode’ specifies if canonical text mode
2442 should be used. By default, text mode is not used.
2443
2444 Text mode is for example used for the RFC2015 signatures; note that
2445 the updated RFC 3156 mandates that the mail user agent does some
2446 preparations so that text mode is not needed anymore.
2447
2448 This option is only relevant to the OpenPGP crypto engine, and
2449 ignored by all other engines.
2450
2451 Canonical text mode is disabled if YES is zero, and enabled
2452 otherwise.
2453
2454 -- Function: int gpgme_get_textmode (gpgme_ctx_t CTX)
2455 The function ‘gpgme_get_textmode’ returns 1 if canonical text mode
2456 is enabled, and ‘0’ if it is not, or if CTX is not a valid pointer.
2457
2458 
2459 File: gpgme.info, Node: Offline Mode, Next: Pinentry Mode, Prev: Text Mode, Up: Context Attributes
2460
2461 7.4.6 Offline Mode
2462 ------------------
2463
2464 -- Function: void gpgme_set_offline (gpgme_ctx_t CTX, int YES)
2465 SINCE: 1.6.0
2466
2467 The function ‘gpgme_set_offline’ specifies if offline mode should
2468 be used. Offline mode is disabled if YES is zero, and enabled
2469 otherwise. By default, offline mode is disabled.
2470
2471 The details of the offline mode depend on the used protocol and its
2472 backend engine. It may eventually be extended to be more stricter
2473 and for example completely disable the use of Dirmngr for any
2474 engine.
2475
2476 For the CMS protocol the offline mode specifies whether Dirmngr
2477 shall be used to do additional validation that might require
2478 connecting external services (e.g. CRL / OCSP checks). Here the
2479 offline mode only affects the keylist mode
2480 ‘GPGME_KEYLIST_MODE_VALIDATE’.
2481
2482 For the OpenPGP protocol offline mode entirely disables the use of
2483 the Dirmngr and will thus guarantee that no network connections are
2484 done as part of an operation on this context. It has only an
2485 effect with GnuPG versions 2.1.23 or later.
2486
2487 For all other protocols the offline mode is currently ignored.
2488
2489 -- Function: int gpgme_get_offline (gpgme_ctx_t CTX)
2490 SINCE: 1.6.0
2491
2492 The function ‘gpgme_get_offline’ returns 1 if offline mode is
2493 enabled, and ‘0’ if it is not, or if CTX is not a valid pointer.
2494
2495 
2496 File: gpgme.info, Node: Pinentry Mode, Next: Included Certificates, Prev: Offline Mode, Up: Context Attributes
2497
2498 7.4.7 Pinentry Mode
2499 -------------------
2500
2501 -- Function: gpgme_error_t gpgme_set_pinentry_mode (gpgme_ctx_t CTX,
2502 gpgme_pinentry_mode_t MODE)
2503
2504 SINCE: 1.4.0
2505
2506 The function ‘gpgme_set_pinentry_mode’ specifies the pinentry mode
2507 to be used.
2508
2509 For GnuPG >= 2.1 this option is required to be set to
2510 ‘GPGME_PINENTRY_MODE_LOOPBACK’ to enable the passphrase callback
2511 mechanism in GPGME through ‘gpgme_set_passphrase_cb’.
2512
2513 -- Function: gpgme_pinentry_mode_t gpgme_get_pinentry_mode
2514 (gpgme_ctx_t CTX)
2515 SINCE: 1.4.0
2516
2517 The function ‘gpgme_get_pinenty_mode’ returns the mode set for the
2518 context.
2519
2520 -- Data type: enum gpgme_pinentry_mode_t
2521 SINCE: 1.4.0
2522
2523 The ‘gpgme_minentry_mode_t’ type specifies the set of possible
2524 pinentry modes that are supported by GPGME if GnuPG >= 2.1 is used.
2525 The following modes are supported:
2526
2527 ‘GPGME_PINENTRY_MODE_DEFAULT’
2528 SINCE: 1.4.0
2529
2530 Use the default of the agent, which is ask.
2531
2532 ‘GPGME_PINENTRY_MODE_ASK’
2533 SINCE: 1.4.0
2534
2535 Force the use of the Pinentry.
2536
2537 ‘GPGME_PINENTRY_MODE_CANCEL’
2538 SINCE: 1.4.0
2539
2540 Emulate use of Pinentry’s cancel button.
2541
2542 ‘GPGME_PINENTRY_MODE_ERROR’
2543 SINCE: 1.4.0
2544
2545 Return a Pinentry error ‘No Pinentry’.
2546
2547 ‘GPGME_PINENTRY_MODE_LOOPBACK’
2548 SINCE: 1.4.0
2549
2550 Redirect Pinentry queries to the caller. This enables the use
2551 of ‘gpgme_set_passphrase_cb’ because pinentry queries are
2552 redirected to gpgme.
2553
2554 Note: For 2.1.0 - 2.1.12 this mode requires
2555 ‘allow-loopback-pinentry’ to be enabled in the
2556 ‘gpg-agent.conf’ or an agent started with that option.
2557
2558 
2559 File: gpgme.info, Node: Included Certificates, Next: Key Listing Mode, Prev: Pinentry Mode, Up: Context Attributes
2560
2561 7.4.8 Included Certificates
2562 ---------------------------
2563
2564 -- Function: void gpgme_set_include_certs (gpgme_ctx_t CTX,
2565 int NR_OF_CERTS)
2566 The function ‘gpgme_set_include_certs’ specifies how many
2567 certificates should be included in an S/MIME signed message. By
2568 default, only the sender’s certificate is included. The possible
2569 values of NR_OF_CERTS are:
2570
2571 ‘GPGME_INCLUDE_CERTS_DEFAULT’
2572 SINCE: 1.0.3
2573
2574 Fall back to the default of the crypto backend. This is the
2575 default for GPGME.
2576 ‘-2’
2577 Include all certificates except the root certificate.
2578 ‘-1’
2579 Include all certificates.
2580 ‘0’
2581 Include no certificates.
2582 ‘1’
2583 Include the sender’s certificate only.
2584 ‘n’
2585 Include the first n certificates of the certificates path,
2586 starting from the sender’s certificate. The number ‘n’ must
2587 be positive.
2588
2589 Values of NR_OF_CERTS smaller than -2 are undefined.
2590
2591 This option is only relevant to the CMS crypto engine, and ignored
2592 by all other engines.
2593
2594 -- Function: int gpgme_get_include_certs (gpgme_ctx_t CTX)
2595 The function ‘gpgme_get_include_certs’ returns the number of
2596 certificates to include into an S/MIME signed message.
2597
2598 
2599 File: gpgme.info, Node: Key Listing Mode, Next: Passphrase Callback, Prev: Included Certificates, Up: Context Attributes
2600
2601 7.4.9 Key Listing Mode
2602 ----------------------
2603
2604 -- Function: gpgme_error_t gpgme_set_keylist_mode (gpgme_ctx_t CTX,
2605 gpgme_keylist_mode_t MODE)
2606 The function ‘gpgme_set_keylist_mode’ changes the default behaviour
2607 of the key listing functions. The value in MODE is a bitwise-or
2608 combination of one or multiple of the following bit values:
2609
2610 ‘GPGME_KEYLIST_MODE_LOCAL’
2611 The ‘GPGME_KEYLIST_MODE_LOCAL’ symbol specifies that the local
2612 keyring should be searched for keys in the keylisting
2613 operation. This is the default.
2614
2615 Using only this option results in a ‘--list-keys’.
2616
2617 ‘GPGME_KEYLIST_MODE_EXTERN’
2618 The ‘GPGME_KEYLIST_MODE_EXTERN’ symbol specifies that an
2619 external source should be searched for keys in the keylisting
2620 operation. The type of external source is dependent on the
2621 crypto engine used and whether it is combined with
2622 ‘GPGME_KEYLIST_MODE_LOCAL’. For example, it can be a remote
2623 keyserver or LDAP certificate server.
2624
2625 Using only this option results in a ‘--search-keys’ for
2626 ‘GPGME_PROTOCOL_OpenPGP’ and something similar to
2627 ‘--list-external-keys’ for ‘GPGME_PROTOCOL_CMS’.
2628
2629 ‘GPGME_KEYLIST_MODE_LOCATE’
2630 This is a shortcut for the combination of
2631 ‘GPGME_KEYLIST_MODE_LOCAL’ and ‘GPGME_KEYLIST_MODE_EXTERN’,
2632 which results in a ‘--locate-keys’ for
2633 ‘GPGME_PROTOCOL_OpenPGP’.
2634
2635 ‘GPGME_KEYLIST_MODE_SIGS’
2636 The ‘GPGME_KEYLIST_MODE_SIGS’ symbol specifies that the key
2637 signatures should be included in the listed keys.
2638
2639 ‘GPGME_KEYLIST_MODE_SIG_NOTATIONS’
2640 SINCE: 1.1.1
2641
2642 The ‘GPGME_KEYLIST_MODE_SIG_NOTATIONS’ symbol specifies that
2643 the signature notations on key signatures should be included
2644 in the listed keys. This only works if
2645 ‘GPGME_KEYLIST_MODE_SIGS’ is also enabled.
2646
2647 ‘GPGME_KEYLIST_MODE_WITH_TOFU’
2648 SINCE: 1.7.0
2649
2650 The ‘GPGME_KEYLIST_MODE_WITH_TOFU’ symbol specifies that
2651 information pertaining to the TOFU trust model should be
2652 included in the listed keys.
2653
2654 ‘GPGME_KEYLIST_MODE_WITH_KEYGRIP’
2655 SINCE: 1.14.0
2656
2657 The ‘GPGME_KEYLIST_MODE_WITH_KEYRIP’ symbol specifies that the
2658 keygrip is always included in the listing. The default
2659 depends on the version of the backend and the used protocol.
2660
2661 ‘GPGME_KEYLIST_MODE_WITH_SECRET’
2662 SINCE: 1.5.1
2663
2664 The ‘GPGME_KEYLIST_MODE_WITH_SECRET’ returns information about
2665 the presence of a corresponding secret key in a public key
2666 listing. A public key listing with this mode is slower than a
2667 standard listing but can be used instead of a second run to
2668 list the secret keys. This is only supported for GnuPG
2669 versions >= 2.1. Note that using this option also makes sure
2670 that the keygrip is available in the output.
2671
2672 ‘GPGME_KEYLIST_MODE_EPHEMERAL’
2673 SINCE: 1.2.0
2674
2675 The ‘GPGME_KEYLIST_MODE_EPHEMERAL’ symbol specifies that keys
2676 flagged as ephemeral are included in the listing.
2677
2678 ‘GPGME_KEYLIST_MODE_VALIDATE’
2679 SINCE: 0.4.5
2680
2681 The ‘GPGME_KEYLIST_MODE_VALIDATE’ symbol specifies that the
2682 backend should do key or certificate validation and not just
2683 get the validity information from an internal cache. This
2684 might be an expensive operation and is in general not useful.
2685 Currently only implemented for the S/MIME backend and ignored
2686 for other backends.
2687
2688 At least one of ‘GPGME_KEYLIST_MODE_LOCAL’ and
2689 ‘GPGME_KEYLIST_MODE_EXTERN’ must be specified. For future binary
2690 compatibility, you should get the current mode with
2691 ‘gpgme_get_keylist_mode’ and modify it by setting or clearing the
2692 appropriate bits, and then using that calculated value in the
2693 ‘gpgme_set_keylisting_mode’ operation. This will leave all other
2694 bits in the mode value intact (in particular those that are not
2695 used in the current version of the library).
2696
2697 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the mode
2698 could be set correctly, and ‘GPG_ERR_INV_VALUE’ if CTX is not a
2699 valid pointer or MODE is not a valid mode.
2700
2701 -- Function: gpgme_keylist_mode_t gpgme_get_keylist_mode
2702 (gpgme_ctx_t CTX)
2703 The function ‘gpgme_get_keylist_mode’ returns the current key
2704 listing mode of the context CTX. This value can then be modified
2705 and used in a subsequent ‘gpgme_set_keylist_mode’ operation to only
2706 affect the desired bits (and leave all others intact).
2707
2708 The function returns 0 if CTX is not a valid pointer, and the
2709 current mode otherwise. Note that 0 is not a valid mode value.
2710
2711 
2712 File: gpgme.info, Node: Passphrase Callback, Next: Progress Meter Callback, Prev: Key Listing Mode, Up: Context Attributes
2713
2714 7.4.10 Passphrase Callback
2715 --------------------------
2716
2717 -- Data type: gpgme_error_t (*gpgme_passphrase_cb_t)(void *HOOK, const
2718 char *UID_HINT, const char *PASSPHRASE_INFO, int PREV_WAS_BAD,
2719 int FD)
2720 The ‘gpgme_passphrase_cb_t’ type is the type of functions usable as
2721 passphrase callback function.
2722
2723 The argument UID_HINT might contain a string that gives an
2724 indication for which user ID the passphrase is required. If this
2725 is not available, or not applicable (in the case of symmetric
2726 encryption, for example), UID_HINT will be ‘NULL’.
2727
2728 The argument PASSPHRASE_INFO, if not ‘NULL’, will give further
2729 information about the context in which the passphrase is required.
2730 This information is engine and operation specific.
2731
2732 If this is the repeated attempt to get the passphrase, because
2733 previous attempts failed, then PREV_WAS_BAD is 1, otherwise it will
2734 be 0.
2735
2736 The user must write the passphrase, followed by a newline
2737 character, to the file descriptor FD. The function
2738 ‘gpgme_io_writen’ should be used for the write operation. Note
2739 that if the user returns 0 to indicate success, the user must at
2740 least write a newline character before returning from the callback.
2741
2742 If an error occurs, return the corresponding ‘gpgme_error_t’ value.
2743 You can use the error code ‘GPG_ERR_CANCELED’ to abort the
2744 operation. Otherwise, return ‘0’.
2745
2746 Note: The passphrase_cb only works with GnuPG 1.x and 2.1.x and not
2747 with the 2.0.x series. See ‘gpgme_set_pinentry_mode’ for more
2748 details on 2.1.x usage.
2749
2750 -- Function: void gpgme_set_passphrase_cb (gpgme_ctx_t CTX,
2751 gpgme_passphrase_cb_t PASSFUNC, void *HOOK_VALUE)
2752 The function ‘gpgme_set_passphrase_cb’ sets the function that is
2753 used when a passphrase needs to be provided by the user to
2754 PASSFUNC. The function PASSFUNC needs to implemented by the user,
2755 and whenever it is called, it is called with its first argument
2756 being HOOK_VALUE. By default, no passphrase callback function is
2757 set.
2758
2759 Not all crypto engines require this callback to retrieve the
2760 passphrase. It is better if the engine retrieves the passphrase
2761 from a trusted agent (a daemon process), rather than having each
2762 user to implement their own passphrase query. Some engines do not
2763 even support an external passphrase callback at all, in this case
2764 the error code ‘GPG_ERR_NOT_SUPPORTED’ is returned.
2765
2766 For GnuPG >= 2.1 the pinentry mode has to be set to
2767 ‘GPGME_PINENTRY_MODE_LOOPBACK’ to enable the passphrase callback.
2768 See ‘gpgme_set_pinentry_mode’.
2769
2770 The user can disable the use of a passphrase callback function by
2771 calling ‘gpgme_set_passphrase_cb’ with PASSFUNC being ‘NULL’.
2772
2773 -- Function: void gpgme_get_passphrase_cb (gpgme_ctx_t CTX,
2774 gpgme_passphrase_cb_t *PASSFUNC, void **HOOK_VALUE)
2775 The function ‘gpgme_get_passphrase_cb’ returns the function that is
2776 used when a passphrase needs to be provided by the user in
2777 *PASSFUNC, and the first argument for this function in *HOOK_VALUE.
2778 If no passphrase callback is set, or CTX is not a valid pointer,
2779 ‘NULL’ is returned in both variables.
2780
2781 PASSFUNC or HOOK_VALUE can be ‘NULL’. In this case, the
2782 corresponding value will not be returned.
2783
2784 
2785 File: gpgme.info, Node: Progress Meter Callback, Next: Status Message Callback, Prev: Passphrase Callback, Up: Context Attributes
2786
2787 7.4.11 Progress Meter Callback
2788 ------------------------------
2789
2790 -- Data type: void (*gpgme_progress_cb_t)(void *HOOK, const char *WHAT,
2791 int TYPE, int CURRENT, int TOTAL)
2792 The ‘gpgme_progress_cb_t’ type is the type of functions usable as
2793 progress callback function.
2794
2795 The arguments are specific to the crypto engine. More information
2796 about the progress information returned from the GnuPG engine can
2797 be found in the GnuPG source code in the file ‘doc/DETAILS’ in the
2798 section PROGRESS.
2799
2800 -- Function: void gpgme_set_progress_cb (gpgme_ctx_t CTX,
2801 gpgme_progress_cb_t PROGFUNC, void *HOOK_VALUE)
2802 The function ‘gpgme_set_progress_cb’ sets the function that is used
2803 when progress information about a cryptographic operation is
2804 available. The function PROGFUNC needs to implemented by the user,
2805 and whenever it is called, it is called with its first argument
2806 being HOOK_VALUE. By default, no progress callback function is
2807 set.
2808
2809 Setting a callback function allows an interactive program to
2810 display progress information about a long operation to the user.
2811
2812 The user can disable the use of a progress callback function by
2813 calling ‘gpgme_set_progress_cb’ with PROGFUNC being ‘NULL’.
2814
2815 -- Function: void gpgme_get_progress_cb (gpgme_ctx_t CTX,
2816 gpgme_progress_cb_t *PROGFUNC, void **HOOK_VALUE)
2817 The function ‘gpgme_get_progress_cb’ returns the function that is
2818 used to inform the user about the progress made in *PROGFUNC, and
2819 the first argument for this function in *HOOK_VALUE. If no
2820 progress callback is set, or CTX is not a valid pointer, ‘NULL’ is
2821 returned in both variables.
2822
2823 PROGFUNC or HOOK_VALUE can be ‘NULL’. In this case, the
2824 corresponding value will not be returned.
2825
2826 
2827 File: gpgme.info, Node: Status Message Callback, Next: Context Flags, Prev: Progress Meter Callback, Up: Context Attributes
2828
2829 7.4.12 Status Message Callback
2830 ------------------------------
2831
2832 -- Data type: gpgme_error_t (*gpgme_status_cb_t)(void *HOOK, const char
2833 *KEYWORD, const char *ARGS)
2834 The ‘gpgme_status_cb_t’ type is the type of function usable as a
2835 status message callback function.
2836
2837 The argument KEYWORD is the name of the status message while the
2838 ARGS argument contains any arguments for the status message.
2839
2840 If an error occurs, return the corresponding ‘gpgme_error_t’ value.
2841 Otherwise, return ‘0’.
2842
2843 -- Function: void gpgme_set_status_cb (gpgme_ctx_t CTX,
2844 gpgme_status_cb_t STATUSFUNC, void *HOOK_VALUE)
2845 SINCE: 1.6.0
2846
2847 The function ‘gpgme_set_status_cb’ sets the function that is used
2848 when a status message is received from gpg to STATUSFUNC. The
2849 function STATUSFUNC needs to be implemented by the user, and
2850 whenever it is called, it is called with its first argument being
2851 HOOK_VALUE. By default, no status message callback function is
2852 set.
2853
2854 The user can disable the use of a status message callback function
2855 by calling ‘gpgme_set_status_cb’ with STATUSFUNC being ‘NULL’.
2856
2857 -- Function: void gpgme_get_status_cb (gpgme_ctx_t CTX,
2858 gpgme_status_cb_t *STATUSFUNC, void **HOOK_VALUE)
2859 SINCE: 1.6.0
2860
2861 The function ‘gpgme_get_status_cb’ returns the function that is
2862 used to process status messages from gpg in *STATUSFUNC, and the
2863 first argument for this function in *HOOK_VALUE. If no status
2864 message callback is set, or CTX is not a valid pointer, ‘NULL’ is
2865 returned in both variables.
2866
2867 
2868 File: gpgme.info, Node: Context Flags, Next: Locale, Prev: Status Message Callback, Up: Context Attributes
2869
2870 7.4.13 Context Flags
2871 --------------------
2872
2873 -- Function: gpgme_error_t gpgme_set_ctx_flag (gpgme_ctx_t CTX,
2874 const char *NAME, const char *VALUE)
2875
2876 SINCE: 1.7.0
2877
2878 Some minor properties of the context can be controlled with flags
2879 set by this function. The properties are identified by the
2880 following values for NAME:
2881
2882 ‘"redraw"’
2883 This flag is normally not changed by the caller because GPGME
2884 sets and clears it automatically: The flag is cleared before
2885 an operation and set if an operation noticed that the engine
2886 has launched a Pinentry. A Curses based application may use
2887 this information to redraw the screen; for example:
2888
2889 err = gpgme_op_keylist_start (ctx, "foo@example.org", 0);
2890 while (!err)
2891 {
2892 err = gpgme_op_keylist_next (ctx, &key);
2893 if (err)
2894 break;
2895 show_key (key);
2896 gpgme_key_release (key);
2897 }
2898 if ((s = gpgme_get_ctx_flag (ctx, "redraw")) && *s)
2899 redraw_screen ();
2900 gpgme_release (ctx);
2901
2902 ‘"full-status"’
2903 Using a VALUE of "1" the status callback set by
2904 gpgme_set_status_cb returns all status lines with the
2905 exception of PROGRESS lines. With the default of "0" the
2906 status callback is only called in certain situations.
2907
2908 ‘"raw-description"’
2909 Setting the VALUE to "1" returns human readable strings in a
2910 raw format. For example the non breaking space characters
2911 ("~") will not be removed from the ‘description’ field of the
2912 ‘gpgme_tofu_info_t’ object.
2913
2914 ‘"export-session-key"’
2915 Using a VALUE of "1" specifies that the context should try to
2916 export the symmetric session key when decrypting data. By
2917 default, or when using an empty string or "0" for VALUE,
2918 session keys are not exported.
2919
2920 ‘"override-session-key"’
2921 The string given in VALUE is passed to the GnuPG engine to
2922 override the session key for decryption. The format of that
2923 session key is specific to GnuPG and can be retrieved during a
2924 decrypt operation when the context flag "export-session-key"
2925 is enabled. Please be aware that using this feature with
2926 GnuPG < 2.1.16 will leak the session key on many platforms via
2927 ps(1).
2928
2929 ‘"auto-key-retrieve"’
2930 Setting the VALUE to "1" asks the backend to automatically
2931 retrieve a key for signature verification if possible. Note
2932 that this option makes a "web bug" like behavior possible.
2933 Keyserver or Web Key Directory operators can see which keys
2934 you request, so by sending you a message signed by a brand new
2935 key (which you naturally will not have on your local keyring),
2936 the operator can tell both your IP address and the time when
2937 you verified the signature.
2938
2939 ‘"auto-key-import"’
2940 Setting the VALUE to "1" forces the GPG backend to
2941 automatically import a missing key for signature verification
2942 from the signature.
2943
2944 ‘"include-key-block"’
2945 Setting the VALUE to "1" forces the GPG backend to embed the
2946 signing key as well as an encryption subkey into the the
2947 signature.
2948
2949 ‘"request-origin"’
2950 The string given in VALUE is passed to the GnuPG engines to
2951 request restrictions based on the origin of the request.
2952 Valid values are documented in the GnuPG manual and the gpg
2953 man page under the option ‘--request-origin’. Requires at
2954 least GnuPG 2.2.6 to have an effect.
2955
2956 ‘"no-symkey-cache"’
2957 For OpenPGP disable the passphrase cache used for symmetrical
2958 en- and decryption. This cache is based on the message
2959 specific salt value. Requires at least GnuPG 2.2.7 to have an
2960 effect.
2961
2962 ‘"ignore-mdc-error"’
2963 This flag passes the option ‘--ignore-mdc-error’ to gpg. This
2964 can be used to force decryption of a message which failed due
2965 to a missing integrity check. This flag must be used with
2966 great caution and only if it is a known non-corrupted old
2967 message and the decryption result of the former try had the
2968 decryption result flag ‘legacy_cipher_nomdc’ set. For
2969 failsafe reasons this flag is reset after each operation.
2970
2971 ‘"auto-key-locate"’
2972 The string given in VALUE is passed to gpg. This can be used
2973 to change the behavior of a ‘GPGME_KEYLIST_MODE_LOCATE’
2974 keylisting. Valid values are documented in the GnuPG manual
2975 and the gpg man page under the option ‘--auto-key-locate’.
2976 Requires at least GnuPG 2.1.18.
2977
2978 Note: Keys retrieved through ‘auto-key-locate’ are
2979 automatically imported in the keyring.
2980
2981 ‘trust-model’
2982 SINCE: 1.11.2
2983
2984 Change the trust-model for all GnuPG engine operations. An
2985 empty string sets the trust-model back to the users default.
2986 If the trust-model is not supported by GnuPG the behavior is
2987 undefined and will likely cause all operations to fail.
2988 Example: "tofu+pgp".
2989
2990 This options should be used carefully with a strict version
2991 requirement. In some versions of GnuPG setting the
2992 trust-model changes the default trust-model for future
2993 operations. A change in the trust-model also can have
2994 unintended side effects, like rebuilding the trust-db.
2995
2996 ‘"extended-edit"’
2997 This flag passes the option ‘--expert’ to gpg key edit. This
2998 can be used to get additional callbacks in ‘gpgme_op_edit’.
2999
3000 ‘"cert-expire"’
3001 SINCE: 1.15.2 The string given in VALUE is passed to the GnuPG
3002 engine to set the expiration time to use for key signature
3003 expiration. Valid values are documented in the GnuPG manual
3004 and the gpg man page under the option ‘--default-cert-expire’.
3005
3006 ‘"key-origin"’
3007 SINCE: 1.16.1 The string given in VALUE is passed to the GnuPG
3008 engine to set the origin of imported keys. Valid values are
3009 documented in the GnuPG manual and the gpg man page under the
3010 option ‘--key-origin’.
3011
3012 ‘"import-filter"’
3013 SINCE: 1.16.1 The string given in VALUE is passed to the GnuPG
3014 engine to use as filter when importing keys. Valid values are
3015 documented in the GnuPG manual and the gpg man page under the
3016 option ‘--import-filter’.
3017
3018 This function returns ‘0’ on success.
3019
3020 -- Function: const char * gpgme_get_ctx_flag (gpgme_ctx_t CTX,
3021 const char *NAME)
3022
3023 SINCE: 1.8.0
3024
3025 The value of flags settable by ‘gpgme_set_ctx_flag’ can be
3026 retrieved by this function. If NAME is unknown the function
3027 returns ‘NULL’. For boolean flags an empty string is returned for
3028 False and the string "1" is returned for True; either atoi(3) or a
3029 test for an empty string can be used to get the boolean value.
3030
3031 
3032 File: gpgme.info, Node: Locale, Next: Additional Logs, Prev: Context Flags, Up: Context Attributes
3033
3034 7.4.14 Locale
3035 -------------
3036
3037 A locale setting can be associated with a context. This locale is
3038 passed to the crypto engine, and used for applications like the PIN
3039 entry, which is displayed to the user when entering a passphrase is
3040 required.
3041
3042 The default locale is used to initialize the locale setting of all
3043 contexts created afterwards.
3044
3045 -- Function: gpgme_error_t gpgme_set_locale (gpgme_ctx_t CTX,
3046 int CATEGORY, const char *VALUE)
3047 SINCE: 0.4.3
3048
3049 The function ‘gpgme_set_locale’ sets the locale of the context CTX,
3050 or the default locale if CTX is a null pointer.
3051
3052 The locale settings that should be changed are specified by
3053 CATEGORY. Supported categories are ‘LC_CTYPE’, ‘LC_MESSAGES’, and
3054 ‘LC_ALL’, which is a wildcard you can use if you want to change all
3055 the categories at once.
3056
3057 The value to be used for the locale setting is VALUE, which will be
3058 copied to GPGME’s internal data structures. VALUE can be a null
3059 pointer, which disables setting the locale, and will make PIN entry
3060 and other applications use their default setting, which is usually
3061 not what you want.
3062
3063 Note that the settings are only used if the application runs on a
3064 text terminal, and that the settings should fit the configuration
3065 of the output terminal. Normally, it is sufficient to initialize
3066 the default value at startup.
3067
3068 The function returns an error if not enough memory is available.
3069
3070 
3071 File: gpgme.info, Node: Additional Logs, Prev: Locale, Up: Context Attributes
3072
3073 7.4.15 Additional Logs
3074 ----------------------
3075
3076 Additional logs can be associated with a context. These logs are engine
3077 specific and can be be obtained with ‘gpgme_op_getauditlog’.
3078
3079 -- Function: gpgme_error_t gpgme_op_getauditlog (gpgme_ctx_t CTX,
3080 gpgme_data_t OUTPUT, unsigned int FLAGS)
3081 SINCE: 1.1.1
3082
3083 The function ‘gpgme_op_getauditlog’ is used to obtain additional
3084 logs as specified by FLAGS into the OUTPUT data. If
3085
3086 The function returns the error code ‘GPG_ERR_NO_ERROR’ if a log
3087 could be queried from the engine, and ‘GPG_ERR_NOT_IMPLEMENTED’ if
3088 the log specified in FLAGS is not available for this engine. If no
3089 log is available ‘GPG_ERR_NO_DATA’ is returned.
3090
3091 The value in FLAGS is a bitwise-or combination of one or multiple
3092 of the following bit values:
3093
3094 ‘GPGME_AUDITLOG_DIAG’
3095 SINCE: 1.11.2
3096
3097 Obtain diagnostic output which would be written to ‘stderr’ in
3098 interactive use of the engine. This can be used to provide
3099 additional diagnostic information in case of errors in other
3100 operations.
3101
3102 Note: If log-file has been set in the configuration the log
3103 will be empty and ‘GPG_ERR_NO_DATA’ will be returned.
3104
3105 Implemented for: ‘GPGME_PROTOCOL_OpenPGP’
3106
3107 ‘GPGME_AUDITLOG_DEFAULT’
3108 SINCE: 1.11.2
3109
3110 This flag has the value 0 for compatibility reasons. Obtains
3111 additional information from the engine by issuing the
3112 ‘GETAUDITLOG’ command. For ‘GPGME_PROTOCOL_CMS’ this provides
3113 additional information about the X509 certificate chain.
3114
3115 Implemented for: ‘GPGME_PROTOCOL_CMS’
3116
3117 ‘GPGME_AUDITLOG_HTML’
3118 SINCE: 1.1.1
3119
3120 Same as ‘GPGME_AUDITLOG_DEFAULT’ but in HTML.
3121
3122 Implemented for: ‘GPGME_PROTOCOL_CMS’
3123
3124 -- Function: gpgme_error_t gpgme_op_getauditlog_start (gpgme_ctx_t CTX,
3125 gpgme_data_t OUTPUT, unsigned int FLAGS)
3126 SINCE: 1.1.1
3127
3128 This is the asynchronous variant of ‘gpgme_op_getauditlog’.
3129
3130 
3131 File: gpgme.info, Node: Key Management, Next: Crypto Operations, Prev: Context Attributes, Up: Contexts
3132
3133 7.5 Key Management
3134 ==================
3135
3136 Some of the cryptographic operations require that recipients or signers
3137 are specified. This is always done by specifying the respective keys
3138 that should be used for the operation. The following section describes
3139 how such keys can be selected and manipulated.
3140
3141 * Menu:
3142
3143 * Key objects:: Description of the key structures.
3144 * Listing Keys:: Browsing the list of available keys.
3145 * Information About Keys:: Requesting detailed information about keys.
3146 * Manipulating Keys:: Operations on keys.
3147 * Generating Keys:: Creating new key pairs.
3148 * Signing Keys:: Adding key signatures to public keys.
3149 * Exporting Keys:: Retrieving key data from the key ring.
3150 * Importing Keys:: Adding keys to the key ring.
3151 * Deleting Keys:: Removing keys from the key ring.
3152 * Changing Passphrases:: Change the passphrase of a key.
3153 * Changing TOFU Data:: Changing data pertaining to TOFU.
3154 * Advanced Key Editing:: Advanced key edit operation.
3155
3156 
3157 File: gpgme.info, Node: Key objects, Next: Listing Keys, Up: Key Management
3158
3159 7.5.1 Key objects
3160 -----------------
3161
3162 The keys are represented in GPGME by structures which may only be read
3163 by the application but never be allocated or changed. They are valid as
3164 long as the key object itself is valid.
3165
3166 -- Data type: gpgme_key_t
3167
3168 The ‘gpgme_key_t’ type is a pointer to a key object. It has the
3169 following members:
3170
3171 ‘gpgme_keylist_mode_t keylist_mode’
3172 SINCE: 0.9.0
3173
3174 The keylist mode that was active when the key was retrieved.
3175
3176 ‘unsigned int revoked : 1’
3177 This is true if the key is revoked.
3178
3179 ‘unsigned int expired : 1’
3180 This is true if the key is expired.
3181
3182 ‘unsigned int disabled : 1’
3183 This is true if the key is disabled.
3184
3185 ‘unsigned int invalid : 1’
3186 This is true if the key is invalid. This might have several
3187 reasons, for a example for the S/MIME backend, it will be set
3188 during key listings if the key could not be validated due to
3189 missing certificates or unmatched policies.
3190
3191 ‘unsigned int can_encrypt : 1’
3192 This is true if the key (ie one of its subkeys) can be used
3193 for encryption.
3194
3195 ‘unsigned int can_sign : 1’
3196 This is true if the key (ie one of its subkeys) can be used to
3197 create data signatures.
3198
3199 ‘unsigned int can_certify : 1’
3200 This is true if the key (ie one of its subkeys) can be used to
3201 create key certificates.
3202
3203 ‘unsigned int can_authenticate : 1’
3204 SINCE: 0.4.5
3205
3206 This is true if the key (ie one of its subkeys) can be used
3207 for authentication.
3208
3209 ‘unsigned int is_qualified : 1’
3210 SINCE: 1.1.0
3211
3212 This is true if the key can be used for qualified signatures
3213 according to local government regulations.
3214
3215 ‘unsigned int secret : 1’
3216 This is true if the key is a secret key. Note, that this will
3217 always be true even if the corresponding subkey flag may be
3218 false (offline/stub keys). This is only set if a listing of
3219 secret keys has been requested or if
3220 ‘GPGME_KEYLIST_MODE_WITH_SECRET’ is active.
3221
3222 ‘unsigned int origin : 5’
3223 SINCE: 1.8.0
3224
3225 Reserved for the origin of this key.
3226
3227 ‘gpgme_protocol_t protocol’
3228 This is the protocol supported by this key.
3229
3230 ‘char *issuer_serial’
3231 If ‘protocol’ is ‘GPGME_PROTOCOL_CMS’, then this is the issuer
3232 serial.
3233
3234 ‘char *issuer_name’
3235 If ‘protocol’ is ‘GPGME_PROTOCOL_CMS’, then this is the issuer
3236 name.
3237
3238 ‘char *chain_id’
3239 If ‘protocol’ is ‘GPGME_PROTOCOL_CMS’, then this is the chain
3240 ID, which can be used to built the certificate chain.
3241
3242 ‘gpgme_validity_t owner_trust’
3243 If ‘protocol’ is ‘GPGME_PROTOCOL_OpenPGP’, then this is the
3244 owner trust.
3245
3246 ‘gpgme_subkey_t subkeys’
3247 This is a linked list with the subkeys of the key. The first
3248 subkey in the list is the primary key and usually available.
3249
3250 ‘gpgme_user_id_t uids’
3251 This is a linked list with the user IDs of the key. The first
3252 user ID in the list is the main (or primary) user ID.
3253
3254 ‘char *fpr’
3255 SINCE: 1.7.0
3256
3257 This field gives the fingerprint of the primary key. Note
3258 that this is a copy of the fingerprint of the first subkey.
3259 For an incomplete key (for example from a verification result)
3260 a subkey may be missing but this field may be set
3261 nevertheless.
3262
3263 ‘unsigned long last_update’
3264 SINCE: 1.8.0
3265
3266 Reserved for the time of the last update of this key.
3267
3268 -- Data type: gpgme_subkey_t
3269 SINCE: 1.5.0
3270
3271 The ‘gpgme_subkey_t’ type is a pointer to a subkey structure.
3272 Subkeys are one component of a ‘gpgme_key_t’ object. In fact,
3273 subkeys are those parts that contains the real information about
3274 the individual cryptographic keys that belong to the same key
3275 object. One ‘gpgme_key_t’ can contain several subkeys. The first
3276 subkey in the linked list is also called the primary key.
3277
3278 The subkey structure has the following members:
3279
3280 ‘gpgme_subkey_t next’
3281 This is a pointer to the next subkey structure in the linked
3282 list, or ‘NULL’ if this is the last element.
3283
3284 ‘unsigned int revoked : 1’
3285 This is true if the subkey is revoked.
3286
3287 ‘unsigned int expired : 1’
3288 This is true if the subkey is expired.
3289
3290 ‘unsigned int disabled : 1’
3291 This is true if the subkey is disabled.
3292
3293 ‘unsigned int invalid : 1’
3294 This is true if the subkey is invalid.
3295
3296 ‘unsigned int can_encrypt : 1’
3297 This is true if the subkey can be used for encryption.
3298
3299 ‘unsigned int can_sign : 1’
3300 This is true if the subkey can be used to create data
3301 signatures.
3302
3303 ‘unsigned int can_certify : 1’
3304 This is true if the subkey can be used to create key
3305 certificates.
3306
3307 ‘unsigned int can_authenticate : 1’
3308 SINCE: 0.4.5
3309
3310 This is true if the subkey can be used for authentication.
3311
3312 ‘unsigned int is_qualified : 1’
3313 SINCE: 1.1.0
3314
3315 This is true if the subkey can be used for qualified
3316 signatures according to local government regulations.
3317
3318 ‘unsigned int is_de_vs : 1’
3319 SINCE: 1.8.0
3320
3321 This is true if the subkey complies with the rules for
3322 classified information in Germany at the restricted level
3323 (VS-NfD). This are currently RSA keys of at least 2048 bits or
3324 ECDH/ECDSA keys using a Brainpool curve.
3325
3326 ‘unsigned int secret : 1’
3327 This is true if the subkey is a secret key. Note that it will
3328 be false if the key is actually a stub key; i.e. a secret key
3329 operation is currently not possible (offline-key). This is
3330 only set if a listing of secret keys has been requested or if
3331 ‘GPGME_KEYLIST_MODE_WITH_SECRET’ is active.
3332
3333 ‘gpgme_pubkey_algo_t pubkey_algo’
3334 This is the public key algorithm supported by this subkey.
3335
3336 ‘unsigned int length’
3337 This is the length of the subkey (in bits).
3338
3339 ‘char *keyid’
3340 This is the key ID of the subkey in hexadecimal digits.
3341
3342 ‘char *fpr’
3343 This is the fingerprint of the subkey in hexadecimal digits,
3344 if available.
3345
3346 ‘char *keygrip’
3347 SINCE: 1.7.0
3348
3349 The keygrip of the subkey in hex digit form or ‘NULL’ if not
3350 available.
3351
3352 ‘long int timestamp’
3353 This is the creation timestamp of the subkey. This is -1 if
3354 the timestamp is invalid, and 0 if it is not available.
3355
3356 ‘long int expires’
3357 This is the expiration timestamp of the subkey, or 0 if the
3358 subkey does not expire.
3359
3360 ‘unsigned int is_cardkey : 1’
3361 SINCE: 1.2.0
3362
3363 True if the secret key is stored on a smart card.
3364
3365 ‘char *card_number’
3366 SINCE: 1.2.0
3367
3368 The serial number of a smart card holding this key or ‘NULL’.
3369
3370 ‘char *curve’
3371 For ECC algorithms the name of the curve.
3372
3373 -- Data type: gpgme_user_id_t
3374
3375 A user ID is a component of a ‘gpgme_key_t’ object. One key can
3376 have many user IDs. The first one in the list is the main (or
3377 primary) user ID.
3378
3379 The user ID structure has the following members.
3380
3381 ‘gpgme_user_id_t next’
3382 This is a pointer to the next user ID structure in the linked
3383 list, or ‘NULL’ if this is the last element.
3384
3385 ‘unsigned int revoked : 1’
3386 This is true if the user ID is revoked.
3387
3388 ‘unsigned int invalid : 1’
3389 This is true if the user ID is invalid.
3390
3391 ‘gpgme_validity_t validity’
3392 This specifies the validity of the user ID.
3393
3394 ‘char *uid’
3395 This is the user ID string.
3396
3397 ‘char *name’
3398 This is the name component of ‘uid’, if available.
3399
3400 ‘char *comment’
3401 This is the comment component of ‘uid’, if available.
3402
3403 ‘char *email’
3404 This is the email component of ‘uid’, if available.
3405
3406 ‘char *address;’
3407 The mail address (addr-spec from RFC-5322) of the user ID
3408 string. This is general the same as the ‘email’ part of this
3409 structure but might be slightly different. If no mail address
3410 is available ‘NULL’ is stored.
3411
3412 ‘gpgme_tofu_info_t tofu’
3413 SINCE: 1.7.0
3414
3415 If not ‘NULL’ information from the TOFU database pertaining to
3416 this user id.
3417
3418 ‘gpgme_key_sig_t signatures’
3419 This is a linked list with the signatures on this user ID.
3420
3421 ‘unsigned int origin : 5’
3422 SINCE: 1.8.0
3423
3424 Reserved for the origin of this user ID.
3425
3426 ‘unsigned long last_update’
3427 SINCE: 1.8.0
3428
3429 Reserved for the time of the last update of this user ID.
3430
3431 ‘char *uidhash;’
3432 A string used by gpg to identify a user ID. This string can be
3433 used at certain prompts of ‘gpgme_op_edit’ to select a user
3434 ID. Users must be prepared to see a ‘NULL’ value here. The
3435 format of the value is not specified and may depend on the
3436 GPGME or GnuPG version.
3437
3438 -- Data type: gpgme_tofu_info_t
3439
3440 SINCE: 1.7.0
3441
3442 The ‘gpgme_tofu_info_t’ type is a pointer to a tofu info structure.
3443 Tofu info structures are one component of a ‘gpgme_user_id_t’
3444 object, and provide information from the TOFU database pertaining
3445 to the user ID.
3446
3447 The tofu info structure has the following members:
3448
3449 ‘gpgme_tofu_info_t next’
3450 This is a pointer to the next tofu info structure in the
3451 linked list, or ‘NULL’ if this is the last element.
3452
3453 ‘unsigned int validity : 3’
3454 This is the TOFU validity. It can have the following values:
3455
3456 ‘0’
3457 The value ‘0’ indicates a conflict.
3458
3459 ‘1’
3460 The value ‘1’ indicates a key without history.
3461
3462 ‘2’
3463 The value ‘2’ indicates a key with too little history.
3464
3465 ‘3’
3466 The value ‘3’ indicates a key with enough history for
3467 basic trust.
3468
3469 ‘4’
3470 The value ‘4’ indicates a key with a lot of history.
3471
3472 ‘unsigned int policy : 4’
3473 This is the TOFU policy, see ‘gpgme_tofu_policy_t’.
3474
3475 ‘unsigned short signcount’
3476 This is the number of signatures seen for this binding (or
3477 ‘USHRT_MAX’ if there are more than that).
3478
3479 ‘unsigned short encrcount’
3480 This is the number of encryptions done with this binding (or
3481 ‘USHRT_MAX’ if there are more than that).
3482
3483 ‘unsigned long signfirst’
3484 Number of seconds since Epoch when the first signature was
3485 seen with this binding.
3486
3487 ‘unsigned long signlast’
3488 Number of seconds since Epoch when the last signature was seen
3489 with this binding.
3490
3491 ‘unsigned long encrfirst’
3492 Number of seconds since Epoch when the first encryption was
3493 done with this binding.
3494
3495 ‘unsigned long encrlast’
3496 Number of seconds since Epoch when the last encryption was
3497 done with this binding.
3498
3499 ‘char *description’
3500 A human-readable string summarizing the TOFU data (or NULL).
3501
3502 -- Data type: gpgme_key_sig_t
3503
3504 The ‘gpgme_key_sig_t’ type is a pointer to a key signature
3505 structure. Key signatures are one component of a ‘gpgme_key_t’
3506 object, and validate user IDs on the key in the OpenPGP protocol.
3507
3508 The signatures on a key are only available if the key was retrieved
3509 via a listing operation with the ‘GPGME_KEYLIST_MODE_SIGS’ mode
3510 enabled, because it can be expensive to retrieve all signatures of
3511 a key.
3512
3513 The signature notations on a key signature are only available if
3514 the key was retrieved via a listing operation with the
3515 ‘GPGME_KEYLIST_MODE_SIG_NOTATIONS’ mode enabled, because it can be
3516 expensive to retrieve all signature notations.
3517
3518 The key signature structure has the following members:
3519
3520 ‘gpgme_key_sig_t next’
3521 This is a pointer to the next key signature structure in the
3522 linked list, or ‘NULL’ if this is the last element.
3523
3524 ‘unsigned int revoked : 1’
3525 This is true if the key signature is a revocation signature.
3526
3527 ‘unsigned int expired : 1’
3528 This is true if the key signature is expired.
3529
3530 ‘unsigned int invalid : 1’
3531 This is true if the key signature is invalid.
3532
3533 ‘unsigned int exportable : 1’
3534 This is true if the key signature is exportable.
3535
3536 ‘unsigned int trust_depth : 8’
3537 This is the depth of a trust signature, or 0 if the key
3538 signature is not a trust signature.
3539
3540 ‘unsigned int trust_value : 8’
3541 This is the trust amount of a trust signature.
3542
3543 ‘gpgme_pubkey_algo_t pubkey_algo’
3544 This is the public key algorithm used to create the signature.
3545
3546 ‘char *keyid’
3547 This is the key ID of the key (in hexadecimal digits) used to
3548 create the signature.
3549
3550 ‘long int timestamp’
3551 This is the creation timestamp of the key signature. This is
3552 -1 if the timestamp is invalid, and 0 if it is not available.
3553
3554 ‘long int expires’
3555 This is the expiration timestamp of the key signature, or 0 if
3556 the key signature does not expire.
3557
3558 ‘char *trust_scope’
3559 This is a regular expression that limits the scope of a trust
3560 signature. Users must be prepared to see a ‘NULL’ value here.
3561
3562 ‘gpgme_error_t status’
3563 This is the status of the signature and has the same meaning
3564 as the member of the same name in a ‘gpgme_signature_t’
3565 object.
3566
3567 ‘unsigned int sig_class’
3568 This specifies the signature class of the key signature. The
3569 meaning is specific to the crypto engine.
3570
3571 ‘char *uid’
3572 This is the main user ID of the key used to create the
3573 signature.
3574
3575 ‘char *name’
3576 This is the name component of ‘uid’, if available.
3577
3578 ‘char *comment’
3579 This is the comment component of ‘uid’, if available.
3580
3581 ‘char *email’
3582 This is the email component of ‘uid’, if available.
3583
3584 ‘gpgme_sig_notation_t notations’
3585 This is a linked list with the notation data and policy URLs.
3586
3587 
3588 File: gpgme.info, Node: Listing Keys, Next: Information About Keys, Prev: Key objects, Up: Key Management
3589
3590 7.5.2 Listing Keys
3591 ------------------
3592
3593 -- Function: gpgme_error_t gpgme_op_keylist_start (gpgme_ctx_t CTX,
3594 const char *PATTERN, int SECRET_ONLY)
3595
3596 The function ‘gpgme_op_keylist_start’ initiates a key listing
3597 operation inside the context CTX. It sets everything up so that
3598 subsequent invocations of ‘gpgme_op_keylist_next’ return the keys
3599 in the list.
3600
3601 If PATTERN is ‘NULL’, all available keys are returned. Otherwise,
3602 PATTERN contains an engine specific expression that is used to
3603 limit the list to all keys matching the pattern. Note that the
3604 total length of the pattern is restricted to an engine-specific
3605 maximum (a couple of hundred characters are usually accepted). The
3606 pattern should be used to restrict the search to a certain common
3607 name or user, not to list many specific keys at once by listing
3608 their fingerprints or key IDs.
3609
3610 If SECRET_ONLY is not ‘0’, the list is restricted to secret keys
3611 only.
3612
3613 The context will be busy until either all keys are received (and
3614 ‘gpgme_op_keylist_next’ returns ‘GPG_ERR_EOF’), or
3615 ‘gpgme_op_keylist_end’ is called to finish the operation.
3616
3617 The function returns the error code ‘GPG_ERR_INV_VALUE’ if CTX is
3618 not a valid pointer, and passes through any errors that are
3619 reported by the crypto engine support routines.
3620
3621 -- Function: gpgme_error_t gpgme_op_keylist_ext_start (gpgme_ctx_t CTX,
3622 const char *PATTERN[], int SECRET_ONLY, int RESERVED)
3623
3624 The function ‘gpgme_op_keylist_ext_start’ initiates an extended key
3625 listing operation inside the context CTX. It sets everything up so
3626 that subsequent invocations of ‘gpgme_op_keylist_next’ return the
3627 keys in the list.
3628
3629 If PATTERN or *PATTERN is ‘NULL’, all available keys are returned.
3630 Otherwise, PATTERN is a ‘NULL’ terminated array of strings that are
3631 used to limit the list to all keys matching at least one of the
3632 patterns verbatim. Note that the total length of all patterns is
3633 restricted to an engine-specific maximum (the exact limit also
3634 depends on the number of patterns and amount of quoting required,
3635 but a couple of hundred characters are usually accepted). Patterns
3636 should be used to restrict the search to a certain common name or
3637 user, not to list many specific keys at once by listing their
3638 fingerprints or key IDs.
3639
3640 If SECRET_ONLY is not ‘0’, the list is restricted to secret keys
3641 only.
3642
3643 The value of RESERVED must be ‘0’.
3644
3645 The context will be busy until either all keys are received (and
3646 ‘gpgme_op_keylist_next’ returns ‘GPG_ERR_EOF’), or
3647 ‘gpgme_op_keylist_end’ is called to finish the operation.
3648
3649 The function returns the error code ‘GPG_ERR_INV_VALUE’ if CTX is
3650 not a valid pointer, and passes through any errors that are
3651 reported by the crypto engine support routines.
3652
3653 -- Function: gpgme_error_t gpgme_op_keylist_from_data_start
3654 (gpgme_ctx_t CTX, gpgme_data_t DATA, int RESERVED)
3655
3656 SINCE: 1.8.0
3657
3658 The function ‘gpgme_op_keylist_from_data_start’ initiates a key
3659 listing operation inside the context CTX. In contrast to the other
3660 key listing operation the keys are read from the supplied DATA and
3661 not from the local key database. The keys are also not imported
3662 into the local key database. The function sets everything up so
3663 that subsequent invocations of ‘gpgme_op_keylist_next’ return the
3664 keys from DATA.
3665
3666 The value of RESERVED must be ‘0’.
3667
3668 This function requires at least GnuPG version 2.1.14 and currently
3669 works only with OpenPGP keys.
3670
3671 The context will be busy until either all keys are received (and
3672 ‘gpgme_op_keylist_next’ returns ‘GPG_ERR_EOF’), or
3673 ‘gpgme_op_keylist_end’ is called to finish the operation. While
3674 the context is busy DATA may not be released.
3675
3676 The function returns the error code ‘GPG_ERR_INV_VALUE’ if CTX is
3677 not a valid pointer, and passes through any errors that are
3678 reported by the crypto engine support routines.
3679
3680 -- Function: gpgme_error_t gpgme_op_keylist_next (gpgme_ctx_t CTX,
3681 gpgme_key_t *R_KEY)
3682
3683 The function ‘gpgme_op_keylist_next’ returns the next key in the
3684 list created by a previous ‘gpgme_op_keylist_start’ operation in
3685 the context CTX. The key will have one reference for the user.
3686 *Note Manipulating Keys::.
3687
3688 This is the only way to get at ‘gpgme_key_t’ objects in GPGME.
3689
3690 If the last key in the list has already been returned,
3691 ‘gpgme_op_keylist_next’ returns ‘GPG_ERR_EOF’.
3692
3693 The function returns the error code ‘GPG_ERR_INV_VALUE’ if CTX or
3694 R_KEY is not a valid pointer, and ‘GPG_ERR_ENOMEM’ if there is not
3695 enough memory for the operation.
3696
3697 -- Function: gpgme_error_t gpgme_op_keylist_end (gpgme_ctx_t CTX)
3698
3699 The function ‘gpgme_op_keylist_end’ ends a pending key list
3700 operation in the context CTX.
3701
3702 After the operation completed successfully, the result of the key
3703 listing operation can be retrieved with ‘gpgme_op_keylist_result’.
3704
3705 The function returns the error code ‘GPG_ERR_INV_VALUE’ if CTX is
3706 not a valid pointer, and ‘GPG_ERR_ENOMEM’ if at some time during
3707 the operation there was not enough memory available.
3708
3709 The following example illustrates how all keys containing a certain
3710 string (‘g10code’) can be listed with their key ID and the name and
3711 email address of the main user ID:
3712
3713 gpgme_ctx_t ctx;
3714 gpgme_key_t key;
3715 gpgme_error_t err = gpgme_new (&ctx);
3716
3717 if (!err)
3718 {
3719 err = gpgme_op_keylist_start (ctx, "g10code", 0);
3720 while (!err)
3721 {
3722 err = gpgme_op_keylist_next (ctx, &key);
3723 if (err)
3724 break;
3725 printf ("%s:", key->subkeys->keyid);
3726 if (key->uids && key->uids->name)
3727 printf (" %s", key->uids->name);
3728 if (key->uids && key->uids->email)
3729 printf (" <%s>", key->uids->email);
3730 putchar ('\n');
3731 gpgme_key_release (key);
3732 }
3733 gpgme_release (ctx);
3734 }
3735 if (gpg_err_code (err) != GPG_ERR_EOF)
3736 {
3737 fprintf (stderr, "can not list keys: %s\n", gpgme_strerror (err));
3738 exit (1);
3739 }
3740
3741 -- Data type: gpgme_keylist_result_t
3742 This is a pointer to a structure used to store the result of a
3743 ‘gpgme_op_keylist_*’ operation. After successfully ending a key
3744 listing operation, you can retrieve the pointer to the result with
3745 ‘gpgme_op_keylist_result’. The structure contains the following
3746 member:
3747
3748 ‘unsigned int truncated : 1’
3749 This is true if the crypto backend had to truncate the result,
3750 and less than the desired keys could be listed.
3751
3752 -- Function: gpgme_keylist_result_t gpgme_op_keylist_result
3753 (gpgme_ctx_t CTX)
3754 The function ‘gpgme_op_keylist_result’ returns a
3755 ‘gpgme_keylist_result_t’ pointer to a structure holding the result
3756 of a ‘gpgme_op_keylist_*’ operation. The pointer is only valid if
3757 the last operation on the context was a key listing operation, and
3758 if this operation finished successfully. The returned pointer is
3759 only valid until the next operation is started on the context.
3760
3761 In a simple program, for which a blocking operation is acceptable,
3762 the following function can be used to retrieve a single key.
3763
3764 -- Function: gpgme_error_t gpgme_get_key (gpgme_ctx_t CTX,
3765 const char *FPR, gpgme_key_t *R_KEY, int SECRET)
3766 The function ‘gpgme_get_key’ gets the key with the fingerprint (or
3767 key ID) FPR from the crypto backend and return it in R_KEY. If
3768 SECRET is true, get the secret key. The currently active keylist
3769 mode is used to retrieve the key. The key will have one reference
3770 for the user.
3771
3772 If the key is not found in the keyring, ‘gpgme_get_key’ returns the
3773 error code ‘GPG_ERR_EOF’ and *R_KEY will be set to ‘NULL’.
3774
3775 The function returns the error code ‘GPG_ERR_INV_VALUE’ if CTX or
3776 R_KEY is not a valid pointer or FPR is not a fingerprint or key ID,
3777 ‘GPG_ERR_AMBIGUOUS_NAME’ if the key ID was not a unique specifier
3778 for a key, and ‘GPG_ERR_ENOMEM’ if at some time during the
3779 operation there was not enough memory available.
3780
3781 
3782 File: gpgme.info, Node: Information About Keys, Next: Manipulating Keys, Prev: Listing Keys, Up: Key Management
3783
3784 7.5.3 Information About Keys
3785 ----------------------------
3786
3787 Please see the beginning of this section for more information about
3788 ‘gpgme_key_t’ objects.
3789
3790 -- Data type: gpgme_validity_t
3791 The ‘gpgme_validity_t’ type is used to specify the validity of a
3792 user ID in a key. The following validities are defined:
3793
3794 ‘GPGME_VALIDITY_UNKNOWN’
3795 The user ID is of unknown validity. The string representation
3796 of this validity is “?”.
3797
3798 ‘GPGME_VALIDITY_UNDEFINED’
3799 The validity of the user ID is undefined. The string
3800 representation of this validity is “q”.
3801
3802 ‘GPGME_VALIDITY_NEVER’
3803 The user ID is never valid. The string representation of this
3804 validity is “n”.
3805
3806 ‘GPGME_VALIDITY_MARGINAL’
3807 The user ID is marginally valid. The string representation of
3808 this validity is “m”.
3809
3810 ‘GPGME_VALIDITY_FULL’
3811 The user ID is fully valid. The string representation of this
3812 validity is “f”.
3813
3814 ‘GPGME_VALIDITY_ULTIMATE’
3815 The user ID is ultimately valid. The string representation of
3816 this validity is “u”.
3817
3818 
3819 File: gpgme.info, Node: Manipulating Keys, Next: Generating Keys, Prev: Information About Keys, Up: Key Management
3820
3821 7.5.4 Manipulating Keys
3822 -----------------------
3823
3824 -- Function: void gpgme_key_ref (gpgme_key_t KEY)
3825 The function ‘gpgme_key_ref’ acquires an additional reference for
3826 the key KEY.
3827
3828 -- Function: void gpgme_key_unref (gpgme_key_t KEY)
3829 The function ‘gpgme_key_unref’ releases a reference for the key
3830 KEY. If this was the last reference, the key will be destroyed and
3831 all resources associated to it will be released.
3832
3833 -- Function: gpgme_error_t gpgme_op_setexpire (gpgme_ctx_t CTX,
3834 gpgme_key_t KEY, unsigned long EXPIRES, const char *SUBFPRS,
3835 unsigned int RESERVED);
3836
3837 SINCE: 1.14.1
3838
3839 The function ‘gpgme_op_setexpire’ sets the expiration time of the
3840 key KEY or of the specified subkeys. This function requires at
3841 least version 2.1.22 of GnuPG.
3842
3843 KEY specifies the key to operate on.
3844
3845 EXPIRES specifies the expiration time in seconds from now. To be
3846 similar to other usages where expiration times are provided in
3847 unsigned long this is similar to the key creation date and so it is
3848 in seconds from NOW.
3849
3850 The common case is to use 0 to not set an expiration time. Note
3851 that this parameter takes an unsigned long value and not a ‘time_t’
3852 to avoid problems on systems which use a signed 32 bit ‘time_t’.
3853 Note further that the OpenPGP protocol uses 32 bit values for
3854 timestamps and thus can only encode dates up to the year 2106.
3855
3856 SUBFPRS selects the subkey(s) for which the expiration time should
3857 be set. If SUBFPRS is set to ‘NULL’, then the expiration time of
3858 the primary key is set. If SUBFPRS is an asterisk (‘*’), then the
3859 expiration times of all non-revoked and not yet expired subkeys are
3860 set. To select more than one subkey put all subkey fingerprints
3861 into one string separated by linefeeds characters (‘\n’).
3862
3863 RESERVED is reserved for later use and must be ‘0’.
3864
3865 -- Function: gpgme_error_t gpgme_op_setexpire_start (gpgme_ctx_t CTX,
3866 gpgme_key_t KEY, unsigned long EXPIRES, const char *SUBFPRS,
3867 unsigned int FLAGS);
3868
3869 SINCE: 1.14.1
3870
3871 The function ‘gpgme_op_setexpire_start’ initiates a
3872 ‘gpgme_op_setexpire’ operation; see there for details. It must be
3873 completed by calling ‘gpgme_wait’ on the context. *Note Waiting
3874 For Completion::.
3875
3876 -- Function: gpgme_error_t gpgme_op_revuid_start (gpgme_ctx_t CTX,
3877 gpgme_key_t KEY, const char *USERID, unsigned int FLAGS);
3878
3879 SINCE: 1.14.1
3880
3881 The function ‘gpgme_op_setexpire_start’ initiates a
3882 ‘gpgme_op_setexpire’ operation; see there for details. It must be
3883 completed by calling ‘gpgme_wait’ on the context. *Note Waiting
3884 For Completion::.
3885
3886 
3887 File: gpgme.info, Node: Generating Keys, Next: Signing Keys, Prev: Manipulating Keys, Up: Key Management
3888
3889 7.5.5 Generating Keys
3890 ---------------------
3891
3892 GPGME provides a set of functions to create public key pairs. Most of
3893 these functions require the use of GnuPG 2.1 and later; for older GnuPG
3894 versions the ‘gpgme_op_genkey’ function can be used. Existing code
3895 which wants to update to the new functions or new code which shall
3896 supports older GnuPG versions may try the new functions first and
3897 provide a fallback to the old function if the error code
3898 ‘GPG_ERR_NOT_SUPPORTED’ is received.
3899
3900 -- Function: gpgme_error_t gpgme_op_createkey (gpgme_ctx_t CTX,
3901 const char *USERID, const char *ALGO, unsigned long RESERVED,
3902 unsigned long EXPIRES, gpgme_key_t EXTRAKEY,
3903 unsigned int FLAGS);
3904
3905 SINCE: 1.7.0
3906
3907 The function ‘gpgme_op_createkey’ generates a new key for the
3908 procotol active in the context CTX. As of now this function does
3909 only work for OpenPGP and requires at least version 2.1.13 of
3910 GnuPG.
3911
3912 USERID is commonly the mail address associated with the key. GPGME
3913 does not require a specific syntax but if more than a mail address
3914 is given, RFC-822 style format is suggested. The value is expected
3915 to be in UTF-8 encoding (i.e. no IDN encoding for mail addresses).
3916 This is a required parameter.
3917
3918 ALGO specifies the algorithm for the new key (actually a keypair of
3919 public and private key). For a list of supported algorithms, see
3920 the GnuPG manual. If ALGO is ‘NULL’ or the string "default", the
3921 key is generated using the default algorithm of the engine. If the
3922 string "future-default" is used the engine may use an algorithm
3923 which is planned to be the default in a future release of the
3924 engine; however existing implementation of the protocol may not be
3925 able to already handle such future algorithms. For the OpenPGP
3926 protocol, the specification of a default algorithm, without
3927 requesting a non-default usage via FLAGS, triggers the creation of
3928 a primary key plus a secondary key (subkey).
3929
3930 RESERVED must be set to zero.
3931
3932 EXPIRES specifies the expiration time in seconds. If you supply 0,
3933 a reasonable expiration time is chosen. Use the flag
3934 ‘GPGME_CREATE_NOEXPIRE’ to create keys that do not expire. Note
3935 that this parameter takes an unsigned long value and not a ‘time_t’
3936 to avoid problems on systems which use a signed 32 bit ‘time_t’.
3937 Note further that the OpenPGP protocol uses 32 bit values for
3938 timestamps and thus can only encode dates up to the year 2106.
3939
3940 EXTRAKEY is currently not used and must be set to ‘NULL’. A future
3941 version of GPGME may use this parameter to create X.509 keys.
3942
3943 FLAGS can be set to the bit-wise OR of the following flags:
3944
3945 ‘GPGME_CREATE_SIGN’
3946 ‘GPGME_CREATE_ENCR’
3947 ‘GPGME_CREATE_CERT’
3948 ‘GPGME_CREATE_AUTH’
3949 SINCE: 1.7.0
3950
3951 Do not create the key with the default capabilities (key
3952 usage) of the requested algorithm but use those explicitly
3953 given by these flags: “signing”, “encryption”,
3954 “certification”, or “authentication”. The allowed
3955 combinations depend on the algorithm.
3956
3957 If any of these flags are set and a default algorithm has been
3958 selected only one key is created in the case of the OpenPGP
3959 protocol.
3960
3961 ‘GPGME_CREATE_NOPASSWD’
3962 SINCE: 1.7.0
3963
3964 Request generation of the key without password protection.
3965
3966 ‘GPGME_CREATE_SELFSIGNED’
3967 SINCE: 1.7.0
3968
3969 For an X.509 key do not create a CSR but a self-signed
3970 certificate. This has not yet been implemented.
3971
3972 ‘GPGME_CREATE_NOSTORE’
3973 SINCE: 1.7.0
3974
3975 Do not store the created key in the local key database. This
3976 has not yet been implemented.
3977
3978 ‘GPGME_CREATE_WANTPUB’
3979 ‘GPGME_CREATE_WANTSEC’
3980 SINCE: 1.7.0
3981
3982 Return the public or secret key as part of the result
3983 structure. This has not yet been implemented.
3984
3985 ‘GPGME_CREATE_FORCE’
3986 SINCE: 1.7.0
3987
3988 The engine does not allow the creation of a key with a user ID
3989 already existing in the local key database. This flag can be
3990 used to override this check.
3991
3992 ‘GPGME_CREATE_NOEXPIRE’
3993 SINCE: 1.9.0
3994
3995 Request generation of keys that do not expire.
3996
3997 After the operation completed successfully, information about the
3998 created key can be retrieved with ‘gpgme_op_genkey_result’.
3999
4000 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4001 the engine does not support the command, or a bunch of other error
4002 codes.
4003
4004 -- Function: gpgme_error_t gpgme_op_createkey_start (gpgme_ctx_t CTX,
4005 const char *USERID, const char *ALGO, unsigned long RESERVED,
4006 unsigned long EXPIRES, gpgme_key_t EXTRAKEY,
4007 unsigned int FLAGS);
4008
4009 SINCE: 1.7.0
4010
4011 The function ‘gpgme_op_createkey_start’ initiates a
4012 ‘gpgme_op_createkey’ operation; see there for details. It must be
4013 completed by calling ‘gpgme_wait’ on the context. *Note Waiting
4014 For Completion::.
4015
4016 -- Function: gpgme_error_t gpgme_op_createsubkey (gpgme_ctx_t CTX,
4017 gpgme_key_t KEY, const char *ALGO, unsigned long RESERVED,
4018 unsigned long EXPIRES, unsigned int FLAGS);
4019
4020 SINCE: 1.7.0
4021
4022 The function ‘gpgme_op_createsubkey’ creates and adds a new subkey
4023 to the primary OpenPGP key given by KEY. The only allowed protocol
4024 in CTX is ‘GPGME_PROTOCOL_OPENPGP’. Subkeys (aka secondary keys)
4025 are a concept in the OpenPGP protocol to bind several keys to a
4026 primary key. As of now this function requires at least version
4027 2.1.13 of GnuPG.
4028
4029 KEY specifies the key to operate on.
4030
4031 ALGO specifies the algorithm for the new subkey. For a list of
4032 supported algorithms, see the GnuPG manual. If ALGO is ‘NULL’ or
4033 the string "default", the subkey is generated using the default
4034 algorithm for an encryption subkey of the engine. If the string
4035 "future-default" is used the engine may use an encryption algorithm
4036 which is planned to be the default in a future release of the
4037 engine; however existing implementation of the protocol may not be
4038 able to already handle such future algorithms.
4039
4040 RESERVED must be set to zero.
4041
4042 EXPIRES specifies the expiration time in seconds. If you supply 0,
4043 a reasonable expiration time is chosen. Use the flag
4044 ‘GPGME_CREATE_NOEXPIRE’ to create keys that do not expire. Note
4045 that this parameter takes an unsigned long value and not a ‘time_t’
4046 to avoid problems on systems which use a signed 32 bit ‘time_t’.
4047 Note further that the OpenPGP protocol uses 32 bit values for
4048 timestamps and thus can only encode dates up to the year 2106.
4049
4050 FLAGS takes the same values as described above for
4051 ‘gpgme_op_createkey’.
4052
4053 After the operation completed successfully, information about the
4054 created key can be retrieved with ‘gpgme_op_genkey_result’.
4055
4056 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4057 the engine does not support the command, or a bunch of other error
4058 codes.
4059
4060 -- Function: gpgme_error_t gpgme_op_createsubkey_start
4061 (gpgme_ctx_t CTX, gpgme_key_t KEY, const char *ALGO,
4062 unsigned long RESERVED, unsigned long EXPIRES,
4063 unsigned int FLAGS);
4064
4065 SINCE: 1.7.0
4066
4067 The function ‘gpgme_op_createsubkey_start’ initiates a
4068 ‘gpgme_op_createsubkey’ operation; see there for details. It must
4069 be completed by calling ‘gpgme_wait’ on the context. *Note Waiting
4070 For Completion::.
4071
4072 -- Function: gpgme_error_t gpgme_op_adduid (gpgme_ctx_t CTX,
4073 gpgme_key_t KEY, const char *USERID, unsigned int FLAGS);
4074
4075 SINCE: 1.7.0
4076
4077 The function ‘gpgme_op_adduid’ adds a new user ID to the OpenPGP
4078 key given by KEY. Adding additional user IDs after key creation is
4079 a feature of the OpenPGP protocol and thus the protocol for the
4080 context CTX must be set to OpenPGP. As of now this function
4081 requires at least version 2.1.13 of GnuPG.
4082
4083 KEY specifies the key to operate on.
4084
4085 USERID is the user ID to add to the key. A user ID is commonly the
4086 mail address to be associated with the key. GPGME does not require
4087 a specific syntax but if more than a mail address is given, RFC-822
4088 style format is suggested. The value is expected to be in UTF-8
4089 encoding (i.e. no IDN encoding for mail addresses). This is a
4090 required parameter.
4091
4092 FLAGS are currently not used and must be set to zero.
4093
4094 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4095 the engine does not support the command, or a bunch of other error
4096 codes.
4097
4098 -- Function: gpgme_error_t gpgme_op_adduid_start (gpgme_ctx_t CTX,
4099 gpgme_key_t KEY, const char *USERID, unsigned int FLAGS);
4100
4101 SINCE: 1.7.0
4102
4103 The function ‘gpgme_op_adduid_start’ initiates a ‘gpgme_op_adduid’
4104 operation; see there for details. It must be completed by calling
4105 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4106
4107 -- Function: gpgme_error_t gpgme_op_revuid (gpgme_ctx_t CTX,
4108 gpgme_key_t KEY, const char *USERID, unsigned int FLAGS);
4109
4110 SINCE: 1.7.0
4111
4112 The function ‘gpgme_op_revuid’ revokes a user ID from the OpenPGP
4113 key given by KEY. Revoking user IDs after key creation is a
4114 feature of the OpenPGP protocol and thus the protocol for the
4115 context CTX must be set to OpenPGP. As of now this function
4116 requires at least version 2.1.13 of GnuPG.
4117
4118 KEY specifies the key to operate on.
4119
4120 USERID is the user ID to be revoked from the key. The user ID must
4121 be given verbatim because the engine does an exact and case
4122 sensitive match. Thus the ‘uid’ field from the user ID object
4123 (‘gpgme_user_id_t’) is to be used. This is a required parameter.
4124
4125 FLAGS are currently not used and must be set to zero.
4126
4127 Note that the engine won’t allow to revoke the last valid user ID.
4128 To change a user ID is better to first add the new user ID, then
4129 revoke the old one, and finally publish the key.
4130
4131 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4132 the engine does not support the command, or a bunch of other error
4133 codes.
4134
4135 -- Function: gpgme_error_t gpgme_op_revuid_start (gpgme_ctx_t CTX,
4136 gpgme_key_t KEY, const char *USERID, unsigned int FLAGS);
4137
4138 SINCE: 1.7.0
4139
4140 The function ‘gpgme_op_revuid_start’ initiates a ‘gpgme_op_revuid’
4141 operation; see there for details. It must be completed by calling
4142 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4143
4144 -- Function: gpgme_error_t gpgme_op_set_ui_flag (gpgme_ctx_t CTX,
4145 gpgme_key_t KEY, const char *USERID, cons char * NAME,
4146 cons char * VALUE);
4147
4148 SINCE: 1.8.0
4149
4150 The function ‘gpgme_op_set_uid_flag’ is used to set flags on a user
4151 ID from the OpenPGP key given by KEY. Setting flags on user IDs
4152 after key creation is a feature of the OpenPGP protocol and thus
4153 the protocol for the context CTX must be set to OpenPGP.
4154
4155 KEY specifies the key to operate on. This parameters is required.
4156
4157 USERID is the user ID of the key to be manipulated. This user ID
4158 must be given verbatim because the engine does an exact and case
4159 sensitive match. Thus the ‘uid’ field from the user ID object
4160 (‘gpgme_user_id_t’) is to be used. This is a required parameter.
4161
4162 NAME names the flag which is to be changed. The only currently
4163 supported flag is:
4164
4165 ‘primary’
4166 This sets the primary key flag on the given user ID. All other
4167 primary key flag on other user IDs are removed. VALUE must be
4168 given as NULL. For technical reasons this functions bumps the
4169 creation timestamp of all affected self-signatures up by one
4170 second. At least GnuPG version 2.1.20 is required.
4171
4172 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4173 the engine does not support the command, or a bunch of other error
4174 codes.
4175
4176 -- Function: gpgme_error_t gpgme_op_set_uid_flag_start
4177 (gpgme_ctx_t CTX, gpgme_key_t KEY, const char *USERID,
4178 cons char * NAME, cons char * VALUE);
4179
4180 SINCE: 1.8.0
4181
4182 The function ‘gpgme_op_set_uid_flag_start’ initiates a
4183 ‘gpgme_op_set_uid_flag’ operation; see there for details. It must
4184 be completed by calling ‘gpgme_wait’ on the context. *Note Waiting
4185 For Completion::.
4186
4187 -- Function: gpgme_error_t gpgme_op_genkey (gpgme_ctx_t CTX,
4188 const char *PARMS, gpgme_data_t PUBLIC, gpgme_data_t SECRET)
4189
4190 The function ‘gpgme_op_genkey’ generates a new key pair in the
4191 context CTX. The meaning of PUBLIC and SECRET depends on the
4192 crypto backend.
4193
4194 GPG does not support PUBLIC and SECRET, they should be ‘NULL’.
4195 GnuPG will generate a key pair and add it to the standard key ring.
4196 The fingerprint of the generated key is available with
4197 ‘gpgme_op_genkey_result’.
4198
4199 GpgSM requires PUBLIC to be a writable data object. GpgSM will
4200 generate a secret key (which will be stored by ‘gpg-agent’, and
4201 return a certificate request in PUBLIC, which then needs to be
4202 signed by the certification authority and imported before it can be
4203 used. GpgSM does not make the fingerprint available.
4204
4205 The argument PARMS specifies parameters for the key in an string
4206 that looks something like XML. The details about the format of
4207 PARMS are specific to the crypto engine used by CTX. The first
4208 line of the parameters must be ‘<GnupgKeyParams format="internal">’
4209 and the last line must be ‘</GnupgKeyParams>’. Every line in
4210 between the first and last lines is treated as a Header: Value
4211 pair. In particular, no XML escaping is necessary if you need to
4212 include the characters ‘<’, ‘>’, or ‘&’.
4213
4214 Here is an example for GnuPG as the crypto engine (all parameters
4215 of OpenPGP key generation are documented in the GPG manual):
4216
4217 <GnupgKeyParms format="internal">
4218 Key-Type: default
4219 Subkey-Type: default
4220 Name-Real: Joe Tester
4221 Name-Comment: with stupid passphrase
4222 Name-Email: joe@foo.bar
4223 Expire-Date: 0
4224 Passphrase: abc
4225 </GnupgKeyParms>
4226
4227 Here is an example for GpgSM as the crypto engine (all parameters
4228 of OpenPGP key generation are documented in the GPGSM manual):
4229
4230 <GnupgKeyParms format="internal">
4231 Key-Type: RSA
4232 Key-Length: 1024
4233 Name-DN: C=de,O=g10 code,OU=Testlab,CN=Joe 2 Tester
4234 Name-Email: joe@foo.bar
4235 </GnupgKeyParms>
4236
4237 Strings should be given in UTF-8 encoding. The only format
4238 supported for now is “internal”. The content of the
4239 ‘GnupgKeyParms’ container is passed verbatim to the crypto backend.
4240 Control statements are not allowed.
4241
4242 After the operation completed successfully, the result can be
4243 retrieved with ‘gpgme_op_genkey_result’.
4244
4245 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4246 operation could be started successfully, ‘GPG_ERR_INV_VALUE’ if
4247 PARMS is not a well-formed string (e.g. does not have the expected
4248 tag-like headers and footers), ‘GPG_ERR_NOT_SUPPORTED’ if PUBLIC or
4249 SECRET is not valid, and ‘GPG_ERR_GENERAL’ if no key was created by
4250 the backend.
4251
4252 -- Function: gpgme_error_t gpgme_op_genkey_start (gpgme_ctx_t CTX,
4253 const char *PARMS, gpgme_data_t PUBLIC, gpgme_data_t SECRET)
4254
4255 The function ‘gpgme_op_genkey_start’ initiates a ‘gpgme_op_genkey’
4256 operation. It can be completed by calling ‘gpgme_wait’ on the
4257 context. *Note Waiting For Completion::.
4258
4259 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4260 operation could be started successfully, ‘GPG_ERR_INV_VALUE’ if
4261 PARMS is not a valid XML string, and ‘GPG_ERR_NOT_SUPPORTED’ if
4262 PUBLIC or SECRET is not ‘NULL’.
4263
4264 -- Data type: gpgme_genkey_result_t
4265
4266 This is a pointer to a structure used to store the result of a
4267 ‘gpgme_op_genkey’ operation. After successfully generating a key,
4268 you can retrieve the pointer to the result with
4269 ‘gpgme_op_genkey_result’. The structure contains the following
4270 members:
4271
4272 ‘unsigned int primary : 1’
4273 This flag is set to 1 if a primary key was created and to 0 if
4274 not.
4275
4276 ‘unsigned int sub : 1’
4277 This flag is set to 1 if a subkey was created and to 0 if not.
4278
4279 ‘unsigned int uid : 1’
4280 This flag is set to 1 if a user ID was created and to 0 if
4281 not.
4282
4283 ‘char *fpr’
4284 This is the fingerprint of the key that was created. If both
4285 a primary and a subkey were generated, the fingerprint of the
4286 primary key will be returned. If the crypto engine does not
4287 provide the fingerprint, ‘fpr’ will be a null pointer.
4288
4289 ‘gpgme_data_t pubkey’
4290 SINCE: 1.7.0
4291
4292 This will eventually be used to return the public key. It is
4293 currently not used.
4294
4295 ‘gpgme_data_t seckey’
4296 SINCE: 1.7.0
4297
4298 This will eventually be used to return the secret key. It is
4299 currently not used.
4300
4301 -- Function: gpgme_genkey_result_t gpgme_op_genkey_result
4302 (gpgme_ctx_t CTX)
4303
4304 The function ‘gpgme_op_genkey_result’ returns a
4305 ‘gpgme_genkey_result_t’ pointer to a structure holding the result
4306 of a ‘gpgme_op_genkey’ operation. The pointer is only valid if the
4307 last operation on the context was a ‘gpgme_op_genkey’ or
4308 ‘gpgme_op_genkey_start’ operation, and if this operation finished
4309 successfully. The returned pointer is only valid until the next
4310 operation is started on the context.
4311
4312 
4313 File: gpgme.info, Node: Signing Keys, Next: Exporting Keys, Prev: Generating Keys, Up: Key Management
4314
4315 7.5.6 Signing Keys
4316 ------------------
4317
4318 Key signatures are a unique concept of the OpenPGP protocol. They can
4319 be used to certify the validity of a key and are used to create the
4320 Web-of-Trust (WoT). Instead of using the ‘gpgme_op_interact’ function
4321 along with a finite state machine, GPGME provides a convenient function
4322 to create key signatures when using modern GnuPG versions.
4323
4324 -- Function: gpgme_error_t gpgme_op_keysign (gpgme_ctx_t CTX,
4325 gpgme_key_t KEY, const char *USERID, unsigned long EXPIRES,
4326 unsigned int FLAGS);
4327
4328 SINCE: 1.7.0
4329
4330 The function ‘gpgme_op_keysign’ adds a new key signature to the
4331 public key KEY. This function requires at least version 2.1.12 of
4332 GnuPG.
4333
4334 CTX is the usual context which describes the protocol to use (which
4335 must be OpenPGP) and has also the list of signer keys to be used
4336 for the signature. The common case is to use the default key for
4337 signing other keys. If another key or more than one key shall be
4338 used for a key signature, ‘gpgme_signers_add’ can be used. *Note
4339 Selecting Signers::.
4340
4341 KEY specifies the key to operate on.
4342
4343 USERID selects the user ID or user IDs to be signed. If USERID is
4344 set to ‘NULL’ all valid user IDs are signed. The user ID must be
4345 given verbatim because the engine does an exact and case sensitive
4346 match. Thus the ‘uid’ field from the user ID object
4347 (‘gpgme_user_id_t’) is to be used. To select more than one user ID
4348 put them all into one string separated by linefeeds characters
4349 (‘\n’) and set the flag ‘GPGME_KEYSIGN_LFSEP’.
4350
4351 EXPIRES specifies the expiration time of the new signature in
4352 seconds. The common case is to use 0 to not set an expiration
4353 date. However, if the configuration of the engine defines a
4354 default expiration for key signatures, that is still used unless
4355 the flag ‘GPGME_KEYSIGN_NOEXPIRE’ is used. Note that this
4356 parameter takes an unsigned long value and not a ‘time_t’ to avoid
4357 problems on systems which use a signed 32 bit ‘time_t’. Note
4358 further that the OpenPGP protocol uses 32 bit values for timestamps
4359 and thus can only encode dates up to the year 2106.
4360
4361 FLAGS can be set to the bit-wise OR of the following flags:
4362
4363 ‘GPGME_KEYSIGN_LOCAL’
4364 SINCE: 1.7.0
4365
4366 Instead of creating an exportable key signature, create a key
4367 signature which is is marked as non-exportable.
4368
4369 ‘GPGME_KEYSIGN_LFSEP’
4370 SINCE: 1.7.0
4371
4372 Although linefeeds are uncommon in user IDs this flag is
4373 required to explicitly declare that USERID may contain several
4374 linefeed separated user IDs.
4375
4376 ‘GPGME_KEYSIGN_NOEXPIRE’
4377 Force the creation of a key signature without an expiration
4378 date. This overrides EXPIRE and any local configuration of
4379 the engine.
4380
4381 ‘GPGME_KEYSIGN_FORCE’
4382 Force the creation of a new signature even if one already
4383 exists. This flag has an effect only if the gpg version is at
4384 least 2.2.28 but won’t return an error with older versions.
4385
4386 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4387 the engine does not support the command, or a bunch of other error
4388 codes.
4389
4390 -- Function: gpgme_error_t gpgme_op_keysign_start (gpgme_ctx_t CTX,
4391 gpgme_key_t KEY, const char *USERID, unsigned long EXPIRES,
4392 unsigned int FLAGS);
4393
4394 SINCE: 1.7.0
4395
4396 The function ‘gpgme_op_keysign_start’ initiates a
4397 ‘gpgme_op_keysign’ operation; see there for details. It must be
4398 completed by calling ‘gpgme_wait’ on the context. *Note Waiting
4399 For Completion::.
4400
4401 -- Function: gpgme_error_t gpgme_op_revsig (gpgme_ctx_t CTX,
4402 gpgme_key_t KEY, gpgme_key_t SIGNING_KEY, const char *USERID,
4403 unsigned int FLAGS);
4404
4405 SINCE: 1.14.1
4406
4407 The function ‘gpgme_op_revsig’ revokes key signatures of the public
4408 key KEY made with the key SIGNING_KEY. This function requires at
4409 least version 2.2.24 of GnuPG.
4410
4411 KEY specifies the key to operate on.
4412
4413 SIGNING_KEY specifies the key whose signatures shall be revoked.
4414
4415 USERID selects the user ID or user IDs whose signatures shall be
4416 revoked. If USERID is set to ‘NULL’ the signatures on all user IDs
4417 are revoked. The user ID must be given verbatim because the engine
4418 does an exact and case sensitive match. Thus the ‘uid’ field from
4419 the user ID object (‘gpgme_user_id_t’) is to be used. To select
4420 more than one user ID put them all into one string separated by
4421 linefeeds characters (‘\n’) and set the flag ‘GPGME_REVSIG_LFSEP’.
4422
4423 FLAGS can be set to the bit-wise OR of the following flags:
4424
4425 ‘GPGME_REVSIG_LFSEP’
4426 SINCE: 1.14.1
4427
4428 Although linefeeds are uncommon in user IDs this flag is
4429 required to explicitly declare that USERID may contain several
4430 linefeed separated user IDs.
4431
4432 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4433 the engine does not support the command, or a bunch of other error
4434 codes.
4435
4436 -- Function: gpgme_error_t gpgme_op_revsig_start (gpgme_ctx_t CTX,
4437 gpgme_key_t KEY, gpgme_key_t SIGNING_KEY, const char *USERID,
4438 unsigned int FLAGS);
4439
4440 SINCE: 1.14.1
4441
4442 The function ‘gpgme_op_revsig_start’ initiates a ‘gpgme_op_revsig’
4443 operation; see there for details. It must be completed by calling
4444 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4445
4446 
4447 File: gpgme.info, Node: Exporting Keys, Next: Importing Keys, Prev: Signing Keys, Up: Key Management
4448
4449 7.5.7 Exporting Keys
4450 --------------------
4451
4452 Exporting keys means the same as running ‘gpg’ with the command
4453 ‘--export’. However, a mode flag can be used to change the way the
4454 export works. The available mode flags are described below, they may be
4455 or-ed together.
4456
4457 ‘GPGME_EXPORT_MODE_EXTERN’
4458 If this bit is set, the output is send directly to the default
4459 keyserver. This is currently only allowed for OpenPGP keys. It is
4460 good practise to not send more than a few dozens key to a keyserver
4461 at one time. Using this flag requires that the KEYDATA argument of
4462 the export function is set to ‘NULL’.
4463
4464 ‘GPGME_EXPORT_MODE_MINIMAL’
4465 SINCE: 1.3.1
4466
4467 If this bit is set, the smallest possible key is exported. For
4468 OpenPGP keys it removes all signatures except for the latest
4469 self-signatures. For X.509 keys it has no effect.
4470
4471 ‘GPGME_EXPORT_MODE_SSH’
4472 SINCE: 1.4.0
4473
4474 If this bit is set, the latest authentication key of the requested
4475 OpenPGP key is exported in the OpenSSH public key format. This
4476 accepts just a single key; to force the export of a specific subkey
4477 a fingerprint pattern with an appended exclamation mark may be
4478 used.
4479
4480 ‘GPGME_EXPORT_MODE_SECRET’
4481 SINCE: 1.6.0
4482
4483 Instead of exporting the public key, the secret key is exported.
4484 This may not be combined with ‘GPGME_EXPORT_MODE_EXTERN’. For
4485 X.509 the export format is PKCS#8.
4486
4487 ‘GPGME_EXPORT_MODE_SECRET_SUBKEY’
4488 SINCE: 1.17.0
4489
4490 If this bit is set, then a secret subkey is exported. The subkey
4491 to export must be specified with fingerprint pattern with an
4492 appended exclamation mark. This is currently only allowed for
4493 OpenPGP keys. This flag may not be combined with
4494 ‘GPGME_EXPORT_MODE_EXTERN’. This flag is not supported by the
4495 export functions that take an array of keys.
4496
4497 ‘GPGME_EXPORT_MODE_RAW’
4498 SINCE: 1.6.0
4499
4500 If this flag is used with ‘GPGME_EXPORT_MODE_SECRET’ for an X.509
4501 key the export format will be changed to PKCS#1. This flag may not
4502 be used with OpenPGP.
4503
4504 ‘GPGME_EXPORT_MODE_PKCS12’
4505 SINCE: 1.6.0
4506
4507 If this flag is used with ‘GPGME_EXPORT_MODE_SECRET’ for an X.509
4508 key the export format will be changed to PKCS#12 which also
4509 includes the certificate. This flag may not be used with OpenPGP.
4510
4511 -- Function: gpgme_error_t gpgme_op_export (gpgme_ctx_t CTX,
4512 const char *PATTERN, gpgme_export_mode_t MODE,
4513 gpgme_data_t KEYDATA)
4514 The function ‘gpgme_op_export’ extracts public keys and returns
4515 them in the data buffer KEYDATA. The output format of the key data
4516 returned is determined by the ASCII armor attribute set for the
4517 context CTX, or, if that is not set, by the encoding specified for
4518 KEYDATA.
4519
4520 If PATTERN is ‘NULL’, all available keys are returned. Otherwise,
4521 PATTERN contains an engine specific expression that is used to
4522 limit the list to all keys matching the pattern.
4523
4524 MODE is usually 0; other values are described above.
4525
4526 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4527 operation completed successfully, ‘GPG_ERR_INV_VALUE’ if KEYDATA is
4528 not a valid empty data buffer, and passes through any errors that
4529 are reported by the crypto engine support routines.
4530
4531 -- Function: gpgme_error_t gpgme_op_export_start (gpgme_ctx_t CTX,
4532 const char *PATTERN, gpgme_export_mode_t MODE,
4533 gpgme_data_t KEYDATA)
4534 The function ‘gpgme_op_export_start’ initiates a ‘gpgme_op_export’
4535 operation. It can be completed by calling ‘gpgme_wait’ on the
4536 context. *Note Waiting For Completion::.
4537
4538 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4539 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
4540 KEYDATA is not a valid empty data buffer.
4541
4542 -- Function: gpgme_error_t gpgme_op_export_ext (gpgme_ctx_t CTX,
4543 const char *PATTERN[], gpgme_export_mode_t MODE,
4544 gpgme_data_t KEYDATA)
4545 The function ‘gpgme_op_export’ extracts public keys and returns
4546 them in the data buffer KEYDATA. The output format of the key data
4547 returned is determined by the ASCII armor attribute set for the
4548 context CTX, or, if that is not set, by the encoding specified for
4549 KEYDATA.
4550
4551 If PATTERN or *PATTERN is ‘NULL’, all available keys are returned.
4552 Otherwise, PATTERN is a ‘NULL’ terminated array of strings that are
4553 used to limit the list to all keys matching at least one of the
4554 patterns verbatim.
4555
4556 MODE is usually 0; other values are described above.
4557
4558 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4559 operation completed successfully, ‘GPG_ERR_INV_VALUE’ if KEYDATA is
4560 not a valid empty data buffer, and passes through any errors that
4561 are reported by the crypto engine support routines.
4562
4563 -- Function: gpgme_error_t gpgme_op_export_ext_start (gpgme_ctx_t CTX,
4564 const char *PATTERN[], gpgme_export_mode_t MODE,
4565 gpgme_data_t KEYDATA)
4566 The function ‘gpgme_op_export_ext_start’ initiates a
4567 ‘gpgme_op_export_ext’ operation. It can be completed by calling
4568 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4569
4570 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4571 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
4572 KEYDATA is not a valid empty data buffer.
4573
4574 -- Function: gpgme_error_t gpgme_op_export_keys (gpgme_ctx_t CTX,
4575 gpgme_key_t keys[], gpgme_export_mode_t MODE,
4576 gpgme_data_t KEYDATA)
4577 SINCE: 1.2.0
4578
4579 The function ‘gpgme_op_export_keys’ extracts public keys and
4580 returns them in the data buffer KEYDATA. The output format of the
4581 key data returned is determined by the ASCII armor attribute set
4582 for the context CTX, or, if that is not set, by the encoding
4583 specified for KEYDATA.
4584
4585 The keys to export are taken form the ‘NULL’ terminated array KEYS.
4586 Only keys of the currently selected protocol of CTX which do have a
4587 fingerprint set are considered for export. Other keys specified by
4588 the KEYS are ignored. In particular OpenPGP keys retrieved via an
4589 external key listing are not included.
4590
4591 MODE is usually 0; other values are described above.
4592
4593 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4594 operation completed successfully, ‘GPG_ERR_INV_VALUE’ if KEYDATA is
4595 not a valid empty data buffer, ‘GPG_ERR_NO_DATA’ if no useful keys
4596 are in KEYS and passes through any errors that are reported by the
4597 crypto engine support routines.
4598
4599 -- Function: gpgme_error_t gpgme_op_export_keys_start (gpgme_ctx_t CTX,
4600 gpgme_key_t KEYS[], gpgme_export_mode_t MODE,
4601 gpgme_data_t KEYDATA)
4602 SINCE: 1.2.0
4603
4604 The function ‘gpgme_op_export_keys_start’ initiates a
4605 ‘gpgme_op_export_ext’ operation. It can be completed by calling
4606 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4607
4608 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4609 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
4610 KEYDATA is not a valid empty data buffer, ‘GPG_ERR_NO_DATA’ if no
4611 useful keys are in KEYS and passes through any errors that are
4612 reported by the crypto engine support routines.
4613
4614 
4615 File: gpgme.info, Node: Importing Keys, Next: Deleting Keys, Prev: Exporting Keys, Up: Key Management
4616
4617 7.5.8 Importing Keys
4618 --------------------
4619
4620 Importing keys means the same as running ‘gpg’ with the command
4621 ‘--import’.
4622
4623 -- Function: gpgme_error_t gpgme_op_import (gpgme_ctx_t CTX,
4624 gpgme_data_t KEYDATA)
4625 The function ‘gpgme_op_import’ adds the keys in the data buffer
4626 KEYDATA to the key ring of the crypto engine used by CTX. The
4627 format of KEYDATA can be ASCII armored, for example, but the
4628 details are specific to the crypto engine.
4629
4630 After the operation completed successfully, the result can be
4631 retrieved with ‘gpgme_op_import_result’.
4632
4633 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4634 import was completed successfully, ‘GPG_ERR_INV_VALUE’ if CTX or
4635 KEYDATA is not a valid pointer, and ‘GPG_ERR_NO_DATA’ if KEYDATA is
4636 an empty data buffer.
4637
4638 -- Function: gpgme_error_t gpgme_op_import_start (gpgme_ctx_t CTX,
4639 gpgme_data_t KEYDATA)
4640 The function ‘gpgme_op_import_start’ initiates a ‘gpgme_op_import’
4641 operation. It can be completed by calling ‘gpgme_wait’ on the
4642 context. *Note Waiting For Completion::.
4643
4644 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4645 import could be started successfully, ‘GPG_ERR_INV_VALUE’ if CTX or
4646 KEYDATA is not a valid pointer, and ‘GPG_ERR_NO_DATA’ if KEYDATA is
4647 an empty data buffer.
4648
4649 -- Function: gpgme_error_t gpgme_op_import_keys (gpgme_ctx_t CTX,
4650 gpgme_key_t *KEYS)
4651 SINCE: 1.2.0
4652
4653 The function ‘gpgme_op_import_keys’ adds the keys described by the
4654 ‘NULL’ terminated array KEYS to the key ring of the crypto engine
4655 used by CTX. It is used to actually import and make keys permanent
4656 which have been retrieved from an external source (i.e. using
4657 ‘GPGME_KEYLIST_MODE_EXTERN’) earlier. The external keylisting must
4658 have been made with the same context configuration (in particular
4659 the same home directory). (1) Note that for OpenPGP this may
4660 require another access to the keyserver over the network.
4661
4662 Only keys of the currently selected protocol of CTX are considered
4663 for import. Other keys specified by the KEYS are ignored. As of
4664 now all considered keys must have been retrieved using the same
4665 method, i.e. the used key listing mode must be identical.
4666
4667 After the operation completed successfully, the result can be
4668 retrieved with ‘gpgme_op_import_result’.
4669
4670 To move keys from one home directory to another, export and import
4671 the keydata using ‘gpgme_op_export’ and ‘gpgme_op_import’.
4672
4673 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4674 import was completed successfully, ‘GPG_ERR_INV_VALUE’ if CTX is
4675 not a valid pointer, ‘GPG_ERR_CONFLICT’ if the key listing mode
4676 does not match, and ‘GPG_ERR_NO_DATA’ if no keys were considered
4677 for import.
4678
4679 -- Function: gpgme_error_t gpgme_op_import_keys_start (gpgme_ctx_t CTX,
4680 gpgme_key_t *KEYS)
4681 SINCE: 1.2.0
4682
4683 The function ‘gpgme_op_import_keys_start’ initiates a
4684 ‘gpgme_op_import_keys’ operation. It can be completed by calling
4685 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4686
4687 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4688 import was started successfully, ‘GPG_ERR_INV_VALUE’ if CTX is not
4689 a valid pointer, ‘GPG_ERR_CONFLICT’ if the key listing mode does
4690 not match, and ‘GPG_ERR_NO_DATA’ if no keys were considered for
4691 import.
4692
4693 -- Function: gpgme_error_t gpgme_op_receive_keys (gpgme_ctx_t CTX,
4694 const char *KEYIDS[])
4695 SINCE: 1.17.0
4696
4697 The function ‘gpgme_op_receive_keys’ adds the keys described by the
4698 ‘NULL’ terminated array KEYIDS to the key ring of the crypto engine
4699 used by CTX. It is used to retrieve and import keys from an
4700 external source. This function currently works only for OpenPGP.
4701
4702 After the operation completed successfully, the result can be
4703 retrieved with ‘gpgme_op_import_result’.
4704
4705 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4706 import was completed successfully, ‘GPG_ERR_INV_VALUE’ if CTX is
4707 not a valid pointer, and ‘GPG_ERR_NO_DATA’ if no keys were
4708 considered for import.
4709
4710 -- Function: gpgme_error_t gpgme_op_receive_keys_start
4711 (gpgme_ctx_t CTX, const char *KEYIDS[])
4712 SINCE: 1.17.0
4713
4714 The function ‘gpgme_op_receive_keys_start’ initiates a
4715 ‘gpgme_op_receive_keys’ operation. It can be completed by calling
4716 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4717
4718 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4719 import was started successfully, ‘GPG_ERR_INV_VALUE’ if CTX is not
4720 a valid pointer, and ‘GPG_ERR_NO_DATA’ if no keys were considered
4721 for import.
4722
4723 -- Data type: gpgme_import_status_t
4724 This is a pointer to a structure used to store a part of the result
4725 of a ‘gpgme_op_import’ operation. For each considered key one
4726 status is added that contains information about the result of the
4727 import. The structure contains the following members:
4728
4729 ‘gpgme_import_status_t next’
4730 This is a pointer to the next status structure in the linked
4731 list, or ‘NULL’ if this is the last element.
4732
4733 ‘char *fpr’
4734 This is the fingerprint of the key that was considered, or
4735 ‘NULL’ if the fingerprint of the key is not known, e.g.
4736 because the key to import was encrypted and decryption failed.
4737
4738 ‘gpgme_error_t result’
4739 If the import was not successful, this is the error value that
4740 caused the import to fail. Otherwise the error code is
4741 ‘GPG_ERR_NO_ERROR’.
4742
4743 ‘unsigned int status’
4744 This is a bit-wise OR of the following flags that give more
4745 information about what part of the key was imported. If the
4746 key was already known, this might be 0.
4747
4748 ‘GPGME_IMPORT_NEW’
4749 The key was new.
4750
4751 ‘GPGME_IMPORT_UID’
4752 The key contained new user IDs.
4753
4754 ‘GPGME_IMPORT_SIG’
4755 The key contained new signatures.
4756
4757 ‘GPGME_IMPORT_SUBKEY’
4758 The key contained new sub keys.
4759
4760 ‘GPGME_IMPORT_SECRET’
4761 The key contained a secret key.
4762
4763 -- Data type: gpgme_import_result_t
4764 This is a pointer to a structure used to store the result of a
4765 ‘gpgme_op_import’ operation. After a successful import operation,
4766 you can retrieve the pointer to the result with
4767 ‘gpgme_op_import_result’. The structure contains the following
4768 members:
4769
4770 ‘int considered’
4771 The total number of considered keys.
4772
4773 ‘int no_user_id’
4774 The number of keys without user ID.
4775
4776 ‘int imported’
4777 The total number of imported keys.
4778
4779 ‘int imported_rsa’
4780 The number of imported RSA keys.
4781
4782 ‘int unchanged’
4783 The number of unchanged keys.
4784
4785 ‘int new_user_ids’
4786 The number of new user IDs.
4787
4788 ‘int new_sub_keys’
4789 The number of new sub keys.
4790
4791 ‘int new_signatures’
4792 The number of new signatures.
4793
4794 ‘int new_revocations’
4795 The number of new revocations.
4796
4797 ‘int secret_read’
4798 The total number of secret keys read.
4799
4800 ‘int secret_imported’
4801 The number of imported secret keys.
4802
4803 ‘int secret_unchanged’
4804 The number of unchanged secret keys.
4805
4806 ‘int not_imported’
4807 The number of keys not imported.
4808
4809 ‘gpgme_import_status_t imports’
4810 A list of gpgme_import_status_t objects which contain more
4811 information about the keys for which an import was attempted.
4812
4813 ‘int skipped_v3_keys’
4814 For security reasons modern versions of GnuPG do not anymore
4815 support v3 keys (created with PGP 2.x) and ignores them on
4816 import. This counter provides the number of such skipped v3
4817 keys.
4818
4819 -- Function: gpgme_import_result_t gpgme_op_import_result
4820 (gpgme_ctx_t CTX)
4821 The function ‘gpgme_op_import_result’ returns a
4822 ‘gpgme_import_result_t’ pointer to a structure holding the result
4823 of a ‘gpgme_op_import’ operation. The pointer is only valid if the
4824 last operation on the context was a ‘gpgme_op_import’ or
4825 ‘gpgme_op_import_start’ operation, and if this operation finished
4826 successfully. The returned pointer is only valid until the next
4827 operation is started on the context.
4828
4829 ---------- Footnotes ----------
4830
4831 (1) Thus it is a replacement for the usual workaround of exporting
4832 and then importing a key to make an X.509 key permanent.
4833
4834 
4835 File: gpgme.info, Node: Deleting Keys, Next: Changing Passphrases, Prev: Importing Keys, Up: Key Management
4836
4837 7.5.9 Deleting Keys
4838 -------------------
4839
4840 -- Function: gpgme_error_t gpgme_op_delete_ext (gpgme_ctx_t CTX,
4841 const gpgme_key_t KEY, unsigned int FLAGS)
4842 SINCE: 1.9.1
4843
4844 The function ‘gpgme_op_delete_ext’ deletes the key KEY from the key
4845 ring of the crypto engine used by CTX.
4846
4847 FLAGS can be set to the bit-wise OR of the following flags:
4848
4849 ‘GPGME_DELETE_ALLOW_SECRET’
4850 SINCE: 1.9.1
4851
4852 If not set, only public keys are deleted. If set, secret keys
4853 are deleted as well, if that is supported.
4854
4855 ‘GPGME_DELETE_FORCE’
4856 SINCE: 1.9.1
4857
4858 If set, the user is not asked to confirm the deletion.
4859
4860 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the key
4861 was deleted successfully, ‘GPG_ERR_INV_VALUE’ if CTX or KEY is not
4862 a valid pointer, ‘GPG_ERR_NO_PUBKEY’ if KEY could not be found in
4863 the keyring, ‘GPG_ERR_AMBIGUOUS_NAME’ if the key was not specified
4864 unambiguously, and ‘GPG_ERR_CONFLICT’ if the secret key for KEY is
4865 available, but ALLOW_SECRET is zero.
4866
4867 -- Function: gpgme_error_t gpgme_op_delete_ext_start (gpgme_ctx_t CTX,
4868 const gpgme_key_t KEY, unsigned int FLAGS)
4869 SINCE: 1.9.1
4870
4871 The function ‘gpgme_op_delete_ext_start’ initiates a
4872 ‘gpgme_op_delete’ operation. It can be completed by calling
4873 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4874
4875 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
4876 operation was started successfully, and ‘GPG_ERR_INV_VALUE’ if CTX
4877 or KEY is not a valid pointer.
4878
4879 The following functions allow only to use one particular flag.
4880
4881 -- Function: gpgme_error_t gpgme_op_delete (gpgme_ctx_t CTX,
4882 const gpgme_key_t KEY, int ALLOW_SECRET)
4883 Similar to ‘gpgme_op_delete_ext’, but only the flag
4884 ‘GPGME_DELETE_ALLOW_SECRET’ can be provided.
4885
4886 -- Function: gpgme_error_t gpgme_op_delete_start (gpgme_ctx_t CTX,
4887 const gpgme_key_t KEY, int ALLOW_SECRET)
4888 Similar to ‘gpgme_op_delete_ext_start’, but only the flag
4889 ‘GPGME_DELETE_ALLOW_SECRET’ can be provided.
4890
4891 
4892 File: gpgme.info, Node: Changing Passphrases, Next: Changing TOFU Data, Prev: Deleting Keys, Up: Key Management
4893
4894 7.5.10 Changing Passphrases
4895 ---------------------------
4896
4897 -- Function: gpgme_error_t gpgme_op_passwd (gpgme_ctx_t CTX,
4898 const gpgme_key_t KEY, unsigned int FLAGS)
4899
4900 SINCE: 1.3.0
4901
4902 The function ‘gpgme_op_passwd’ changes the passphrase of the
4903 private key associated with KEY. The only allowed value for FLAGS
4904 is ‘0’. The backend engine will usually popup a window to ask for
4905 the old and the new passphrase. Thus this function is not useful
4906 in a server application (where passphrases are not required
4907 anyway).
4908
4909 Note that old ‘gpg’ engines (before version 2.0.15) do not support
4910 this command and will silently ignore it.
4911
4912 -- Function: gpgme_error_t gpgme_op_passwd_start (gpgme_ctx_t CTX,
4913 const gpgme_key_t KEY, unsigned int FLAGS)
4914
4915 SINCE: 1.3.0
4916
4917 The function ‘gpgme_op_passwd_start’ initiates a ‘gpgme_op_passwd’
4918 operation. It can be completed by calling ‘gpgme_wait’ on the
4919 context. *Note Waiting For Completion::.
4920
4921 The function returns ‘0’ if the operation was started successfully,
4922 and an error code if one of the arguments is not valid or the
4923 oepration could not be started.
4924
4925 
4926 File: gpgme.info, Node: Changing TOFU Data, Next: Advanced Key Editing, Prev: Changing Passphrases, Up: Key Management
4927
4928 7.5.11 Changing TOFU Data
4929 -------------------------
4930
4931 The OpenPGP engine features a Trust-On-First-Use (TOFU) key validation
4932 model. For resolving conflicts it is necessary to declare the policy
4933 for a key. See the GnuPG manual for details on the TOFU implementation.
4934
4935 -- Data type: enum gpgme_tofu_policy_t
4936 SINCE: 1.7.0
4937
4938 The ‘gpgme_tofu_policy_t’ type specifies the set of possible policy
4939 values that are supported by GPGME:
4940
4941 ‘GPGME_TOFU_POLICY_AUTO’
4942 Set the policy to “auto”.
4943 ‘GPGME_TOFU_POLICY_GOOD’
4944 Set the policy to “good”.
4945 ‘GPGME_TOFU_POLICY_BAD’
4946 Set the policy to “bad”.
4947 ‘GPGME_TOFU_POLICY_ASK’
4948 Set the policy to “ask”.
4949 ‘GPGME_TOFU_POLICY_UNKNOWN’
4950 Set the policy to “unknown”.
4951
4952 To change the policy for a key the following functions can be used:
4953
4954 -- Function: gpgme_error_t gpgme_op_tofu_policy (gpgme_ctx_t CTX,
4955 const gpgme_key_t KEY, gpgme_tofu_policy_t POLICY)
4956
4957 SINCE: 1.7.0
4958
4959 The function ‘gpgme_op_tofu_policy’ changes the TOFU policy of KEY.
4960 The valid values for POLICY are listed above. As of now this
4961 function does only work for OpenPGP and requires at least version
4962 2.1.10 of GnuPG.
4963
4964 The function returns zero on success, ‘GPG_ERR_NOT_SUPPORTED’ if
4965 the engine does not support the command, or a bunch of other error
4966 codes.
4967
4968 -- Function: gpgme_error_t gpgme_op_tofu_policy_start (gpgme_ctx_t CTX,
4969 const gpgme_key_t KEY, gpgme_tofu_policy_t POLICY)
4970
4971 SINCE: 1.7.0
4972
4973 The function ‘gpgme_op_tofu_policy_start’ initiates a
4974 ‘gpgme_op_tofu_policy’ operation. It can be completed by calling
4975 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
4976
4977 The function returns ‘0’ if the operation was started successfully,
4978 and an error code if one of the arguments is not valid or the
4979 oepration could not be started.
4980
4981 
4982 File: gpgme.info, Node: Advanced Key Editing, Prev: Changing TOFU Data, Up: Key Management
4983
4984 7.5.12 Advanced Key Editing
4985 ---------------------------
4986
4987 -- Data type: gpgme_error_t (*gpgme_interact_cb_t) (void *HANDLE,
4988 const char *STATUS, const char *ARGS, int FD)
4989
4990 SINCE: 1.7.0
4991
4992 The ‘gpgme_interact_cb_t’ type is the type of functions which GPGME
4993 calls if it a key interact operation is on-going. The status
4994 keyword STATUS and the argument line ARGS are passed through by
4995 GPGME from the crypto engine. An empty string represents EOF. The
4996 file descriptor FD is -1 for normal status messages. If STATUS
4997 indicates a command rather than a status message, the response to
4998 the command should be written to FD. The HANDLE is provided by the
4999 user at start of operation.
5000
5001 The function should return ‘GPG_ERR_FALSE’ if it did not handle the
5002 status code, ‘0’ for success, or any other error value.
5003
5004 -- Function: gpgme_error_t gpgme_op_interact (gpgme_ctx_t CTX,
5005 gpgme_key_t KEY, unsigned int FLAGS, gpgme_interact_cb_t FNC,
5006 void *HANDLE, gpgme_data_t OUT)
5007
5008 SINCE: 1.7.0
5009
5010 The function ‘gpgme_op_interact’ processes the key KEY
5011 interactively, using the interact callback function FNC with the
5012 handle HANDLE. The callback is invoked for every status and
5013 command request from the crypto engine. The output of the crypto
5014 engine is written to the data object OUT.
5015
5016 Note that the protocol between the callback function and the crypto
5017 engine is specific to the crypto engine and no further support in
5018 implementing this protocol correctly is provided by GPGME.
5019
5020 FLAGS modifies the behaviour of the function; the only defined bit
5021 value is:
5022
5023 ‘GPGME_INTERACT_CARD’
5024 SINCE: 1.7.0
5025
5026 This is used for smartcard based keys and uses gpg’s
5027 ‘--card-edit’ command.
5028
5029 The function returns ‘0’ if the edit operation completes
5030 successfully, ‘GPG_ERR_INV_VALUE’ if CTX or KEY is not a valid
5031 pointer, and any error returned by the crypto engine or the edit
5032 callback handler.
5033
5034 -- Function: gpgme_error_t gpgme_op_interact_start (gpgme_ctx_t CTX,
5035 gpgme_key_t KEY, unsigned int FLAGS, gpgme_interact_cb_t FNC,
5036 void *HANDLE, gpgme_data_t OUT)
5037
5038 SINCE: 1.7.0
5039
5040 The function ‘gpgme_op_interact_start’ initiates a
5041 ‘gpgme_op_interact’ operation. It can be completed by calling
5042 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
5043
5044 The function returns ‘0’ if the operation was started successfully,
5045 and ‘GPG_ERR_INV_VALUE’ if CTX or KEY is not a valid pointer.
5046
5047 
5048 File: gpgme.info, Node: Crypto Operations, Next: Miscellaneous, Prev: Key Management, Up: Contexts
5049
5050 7.6 Crypto Operations
5051 =====================
5052
5053 Sometimes, the result of a crypto operation returns a list of invalid
5054 keys encountered in processing the request. The following structure is
5055 used to hold information about such a key.
5056
5057 -- Data type: gpgme_invalid_key_t
5058 This is a pointer to a structure used to store a part of the result
5059 of a crypto operation which takes user IDs as one input parameter.
5060 The structure contains the following members:
5061
5062 ‘gpgme_invalid_key_t next’
5063 This is a pointer to the next invalid key structure in the
5064 linked list, or ‘NULL’ if this is the last element.
5065
5066 ‘char *fpr’
5067 The fingerprint or key ID of the invalid key encountered.
5068
5069 ‘gpgme_error_t reason’
5070 An error code describing the reason why the key was found
5071 invalid.
5072
5073 * Menu:
5074
5075 * Decrypt:: Decrypting a ciphertext.
5076 * Verify:: Verifying a signature.
5077 * Decrypt and Verify:: Decrypting a signed ciphertext.
5078 * Sign:: Creating a signature.
5079 * Encrypt:: Encrypting a plaintext.
5080
5081 
5082 File: gpgme.info, Node: Decrypt, Next: Verify, Up: Crypto Operations
5083
5084 7.6.1 Decrypt
5085 -------------
5086
5087 -- Function: gpgme_error_t gpgme_op_decrypt (gpgme_ctx_t CTX,
5088 gpgme_data_t CIPHER, gpgme_data_t PLAIN)
5089 The function ‘gpgme_op_decrypt’ decrypts the ciphertext in the data
5090 object CIPHER and stores it into the data object PLAIN.
5091
5092 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5093 ciphertext could be decrypted successfully, ‘GPG_ERR_INV_VALUE’ if
5094 CTX, CIPHER or PLAIN is not a valid pointer, ‘GPG_ERR_NO_DATA’ if
5095 CIPHER does not contain any data to decrypt,
5096 ‘GPG_ERR_DECRYPT_FAILED’ if CIPHER is not a valid cipher text,
5097 ‘GPG_ERR_BAD_PASSPHRASE’ if the passphrase for the secret key could
5098 not be retrieved, and passes through some errors that are reported
5099 by the crypto engine support routines.
5100
5101 -- Function: gpgme_error_t gpgme_op_decrypt_start (gpgme_ctx_t CTX,
5102 gpgme_data_t CIPHER, gpgme_data_t PLAIN)
5103 The function ‘gpgme_op_decrypt_start’ initiates a
5104 ‘gpgme_op_decrypt’ operation. It can be completed by calling
5105 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
5106
5107 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5108 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
5109 CIPHER or PLAIN is not a valid pointer.
5110
5111 -- Function: gpgme_error_t gpgme_op_decrypt_ext ( gpgme_ctx_t CTX,
5112 gpgme_decrypt_flags_t FLAGS, gpgme_data_t CIPHER,
5113 gpgme_data_t PLAIN)
5114
5115 SINCE: 1.8.0
5116
5117 The function ‘gpgme_op_decrypt_ext’ is the same as
5118 ‘gpgme_op_decrypt’ but has an additional argument FLAGS. If FLAGS
5119 is 0 both function behave identically.
5120
5121 The value in FLAGS is a bitwise-or combination of one or multiple
5122 of the following bit values:
5123
5124 ‘GPGME_DECRYPT_VERIFY’
5125 SINCE: 1.8.0
5126
5127 The ‘GPGME_DECRYPT_VERIFY’ symbol specifies that this function
5128 shall exactly act as ‘gpgme_op_decrypt_verify’.
5129
5130 ‘GPGME_DECRYPT_UNWRAP’
5131 SINCE: 1.8.0
5132
5133 The ‘GPGME_DECRYPT_UNWRAP’ symbol specifies that the output
5134 shall be an OpenPGP message with only the encryption layer
5135 removed. This requires GnuPG 2.1.12 and works only for
5136 OpenPGP. This is the counterpart to ‘GPGME_ENCRYPT_WRAP’.
5137
5138 The function returns the error codes as described for
5139 ‘gpgme_op_decrypt’.
5140
5141 -- Function: gpgme_error_t gpgme_op_decrypt_ext_start (
5142 gpgme_ctx_t CTX, gpgme_decrypt_flags_t FLAGS,
5143 gpgme_data_t CIPHER, gpgme_data_t PLAIN)
5144
5145 SINCE: 1.8.0
5146
5147 The function ‘gpgme_op_decrypt_ext_start’ initiates a
5148 ‘gpgme_op_decrypt_ext’ operation. It can be completed by calling
5149 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
5150
5151 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5152 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
5153 CIPHER or PLAIN is not a valid pointer.
5154
5155 -- Data type: gpgme_recipient_t
5156 SINCE: 1.1.0
5157
5158 This is a pointer to a structure used to store information about
5159 the recipient of an encrypted text which is decrypted in a
5160 ‘gpgme_op_decrypt’ operation. This information (except for the
5161 status field) is even available before the operation finished
5162 successfully, for example in a passphrase callback. The structure
5163 contains the following members:
5164
5165 ‘gpgme_recipient_t next’
5166 This is a pointer to the next recipient structure in the
5167 linked list, or ‘NULL’ if this is the last element.
5168
5169 ‘gpgme_pubkey_algo_t’
5170 The public key algorithm used in the encryption.
5171
5172 ‘char *keyid’
5173 This is the key ID of the key (in hexadecimal digits) used as
5174 recipient.
5175
5176 ‘gpgme_error_t status’
5177 This is an error number with the error code GPG_ERR_NO_SECKEY
5178 if the secret key for this recipient is not available, and 0
5179 otherwise.
5180
5181 -- Data type: gpgme_decrypt_result_t
5182 This is a pointer to a structure used to store the result of a
5183 ‘gpgme_op_decrypt’ operation. After successfully decrypting data,
5184 you can retrieve the pointer to the result with
5185 ‘gpgme_op_decrypt_result’. As with all result structures, it this
5186 structure shall be considered read-only and an application must not
5187 allocate such a strucure on its own. The structure contains the
5188 following members:
5189
5190 ‘char *unsupported_algorithm’
5191 If an unsupported algorithm was encountered, this string
5192 describes the algorithm that is not supported.
5193
5194 ‘unsigned int wrong_key_usage : 1’
5195 SINCE: 0.9.0 This is true if the key was not used according to
5196 its policy.
5197
5198 ‘unsigned int legacy_cipher_nomdc : 1’
5199 SINCE: 1.11.2 The message was made by a legacy algorithm
5200 without any integrity protection. This might be an old but
5201 legitimate message.
5202
5203 ‘unsigned int is_mime : 1;’
5204 SINCE: 1.11.0 The message claims that the content is a MIME
5205 object.
5206
5207 ‘unsigned int is_de_vs : 1;’
5208 SINCE: 1.10.0 The message was encrypted in a VS-NfD compliant
5209 way. This is a specification in Germany for a restricted
5210 communication level.
5211
5212 ‘gpgme_recipient_t recipients’
5213 SINCE: 1.1.0
5214
5215 This is a linked list of recipients to which this message was
5216 encrypted.
5217
5218 ‘char *file_name’
5219 This is the filename of the original plaintext message file if
5220 it is known, otherwise this is a null pointer.
5221
5222 ‘char *session_key’
5223 SINCE: 1.8.0
5224
5225 A textual representation (nul-terminated string) of the
5226 session key used in symmetric encryption of the message, if
5227 the context has been set to export session keys (see
5228 ‘gpgme_set_ctx_flag, "export-session-key"’), and a session key
5229 was available for the most recent decryption operation.
5230 Otherwise, this is a null pointer.
5231
5232 You must not try to access this member of the struct unless
5233 ‘gpgme_set_ctx_flag (ctx, "export-session-key")’ returns
5234 success or ‘gpgme_get_ctx_flag (ctx, "export-session-key")’
5235 returns true (non-empty string).
5236
5237 ‘char *symkey_algo’
5238 SINCE: 1.11.0
5239
5240 A string with the symmetric encryption algorithm and mode
5241 using the format "<algo>.<mode>". Note that the deprecated
5242 non-MDC encryption mode of OpenPGP is given as "PGPCFB".
5243
5244 -- Function: gpgme_decrypt_result_t gpgme_op_decrypt_result
5245 (gpgme_ctx_t CTX)
5246 The function ‘gpgme_op_decrypt_result’ returns a
5247 ‘gpgme_decrypt_result_t’ pointer to a structure holding the result
5248 of a ‘gpgme_op_decrypt’ operation. The pointer is only valid if
5249 the last operation on the context was a ‘gpgme_op_decrypt’ or
5250 ‘gpgme_op_decrypt_start’ operation. If the operation failed this
5251 might be a ‘NULL’ pointer. The returned pointer is only valid
5252 until the next operation is started on the context.
5253
5254 
5255 File: gpgme.info, Node: Verify, Next: Decrypt and Verify, Prev: Decrypt, Up: Crypto Operations
5256
5257 7.6.2 Verify
5258 ------------
5259
5260 -- Function: gpgme_error_t gpgme_op_verify (gpgme_ctx_t CTX,
5261 gpgme_data_t SIG, gpgme_data_t SIGNED_TEXT,
5262 gpgme_data_t PLAIN)
5263 The function ‘gpgme_op_verify’ verifies that the signature in the
5264 data object SIG is a valid signature. If SIG is a detached
5265 signature, then the signed text should be provided in SIGNED_TEXT
5266 and PLAIN should be a null pointer. Otherwise, if SIG is a normal
5267 (or cleartext) signature, SIGNED_TEXT should be a null pointer and
5268 PLAIN should be a writable data object that will contain the
5269 plaintext after successful verification.
5270
5271 The results of the individual signature verifications can be
5272 retrieved with ‘gpgme_op_verify_result’.
5273
5274 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5275 operation could be completed successfully, ‘GPG_ERR_INV_VALUE’ if
5276 CTX, SIG or PLAIN is not a valid pointer, ‘GPG_ERR_NO_DATA’ if SIG
5277 does not contain any data to verify, and passes through any errors
5278 that are reported by the crypto engine support routines.
5279
5280 -- Function: gpgme_error_t gpgme_op_verify_start (gpgme_ctx_t CTX,
5281 gpgme_data_t SIG, gpgme_data_t SIGNED_TEXT,
5282 gpgme_data_t PLAIN)
5283 The function ‘gpgme_op_verify_start’ initiates a ‘gpgme_op_verify’
5284 operation. It can be completed by calling ‘gpgme_wait’ on the
5285 context. *Note Waiting For Completion::.
5286
5287 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5288 operation could be started successfully, ‘GPG_ERR_INV_VALUE’ if
5289 CTX, SIG or PLAIN is not a valid pointer, and ‘GPG_ERR_NO_DATA’ if
5290 SIG or PLAIN does not contain any data to verify.
5291
5292 -- Data type: gpgme_sig_notation_t
5293 This is a pointer to a structure used to store a part of the result
5294 of a ‘gpgme_op_verify’ operation. The structure contains the
5295 following members:
5296
5297 ‘gpgme_sig_notation_t next’
5298 This is a pointer to the next new signature notation structure
5299 in the linked list, or ‘NULL’ if this is the last element.
5300
5301 ‘char *name’
5302 The name of the notation field. If this is ‘NULL’, then the
5303 member ‘value’ will contain a policy URL.
5304
5305 ‘int name_len’
5306 The length of the ‘name’ field. For strings the length is
5307 counted without the trailing binary zero.
5308
5309 ‘char *value’
5310 The value of the notation field. If ‘name’ is ‘NULL’, then
5311 this is a policy URL.
5312
5313 ‘int value_len’
5314 The length of the ‘value’ field. For strings the length is
5315 counted without the trailing binary zero.
5316
5317 ‘gpgme_sig_notation_flags_t flags’
5318 The accumulated flags field. This field contains the flags
5319 associated with the notation data in an accumulated form which
5320 can be used as an argument to the function
5321 ‘gpgme_sig_notation_add’. The value ‘flags’ is a bitwise-or
5322 combination of one or multiple of the following bit values:
5323
5324 ‘GPGME_SIG_NOTATION_HUMAN_READABLE’
5325 SINCE: 1.1.0
5326
5327 The ‘GPGME_SIG_NOTATION_HUMAN_READABLE’ symbol specifies
5328 that the notation data is in human readable form
5329
5330 ‘GPGME_SIG_NOTATION_CRITICAL’
5331 SINCE: 1.1.0
5332
5333 The ‘GPGME_SIG_NOTATION_CRITICAL’ symbol specifies that
5334 the notation data is critical.
5335
5336 ‘unsigned int human_readable : 1’
5337 This is true if the ‘GPGME_SIG_NOTATION_HUMAN_READABLE’ flag
5338 is set and false otherwise. This flag is only valid for
5339 notation data, not for policy URLs.
5340
5341 ‘unsigned int critical : 1’
5342 This is true if the ‘GPGME_SIG_NOTATION_CRITICAL’ flag is set
5343 and false otherwise. This flag is valid for notation data and
5344 policy URLs.
5345
5346 -- Data type: gpgme_signature_t
5347 This is a pointer to a structure used to store a part of the result
5348 of a ‘gpgme_op_verify’ operation. The structure contains the
5349 following members:
5350
5351 ‘gpgme_signature_t next’
5352 This is a pointer to the next new signature structure in the
5353 linked list, or ‘NULL’ if this is the last element.
5354
5355 ‘gpgme_sigsum_t summary’
5356 This is a bit vector giving a summary of the signature status.
5357 It provides an easy interface to a defined semantic of the
5358 signature status. Checking just one bit is sufficient to see
5359 whether a signature is valid without any restrictions. This
5360 means that you can check for GPGME_SIGSUM_VALID like this:
5361
5362 if ((sig.summary & GPGME_SIGSUM_VALID))
5363 {
5364 ..do stuff if valid..
5365 }
5366 else
5367 {
5368 ..do stuff if not fully valid..
5369 }
5370
5371 The defined bits are:
5372 ‘GPGME_SIGSUM_VALID’
5373 The signature is fully valid.
5374
5375 ‘GPGME_SIGSUM_GREEN’
5376 The signature is good but one might want to display some
5377 extra information. Check the other bits.
5378
5379 ‘GPGME_SIGSUM_RED’
5380 The signature is bad. It might be useful to check other
5381 bits and display more information, i.e. a revoked
5382 certificate might not render a signature invalid when the
5383 message was received prior to the cause for the
5384 revocation.
5385
5386 ‘GPGME_SIGSUM_KEY_REVOKED’
5387 The key or at least one certificate has been revoked.
5388
5389 ‘GPGME_SIGSUM_KEY_EXPIRED’
5390 The key or one of the certificates has expired. It is
5391 probably a good idea to display the date of the
5392 expiration.
5393
5394 ‘GPGME_SIGSUM_SIG_EXPIRED’
5395 The signature has expired.
5396
5397 ‘GPGME_SIGSUM_KEY_MISSING’
5398 Can’t verify due to a missing key or certificate.
5399
5400 ‘GPGME_SIGSUM_CRL_MISSING’
5401 The CRL (or an equivalent mechanism) is not available.
5402
5403 ‘GPGME_SIGSUM_CRL_TOO_OLD’
5404 Available CRL is too old.
5405
5406 ‘GPGME_SIGSUM_BAD_POLICY’
5407 A policy requirement was not met.
5408
5409 ‘GPGME_SIGSUM_SYS_ERROR’
5410 A system error occurred.
5411
5412 ‘GPGME_SIGSUM_TOFU_CONFLICT’
5413 A TOFU conflict was detected.
5414
5415 ‘char *fpr’
5416 This is the fingerprint or key ID of the signature.
5417
5418 ‘gpgme_error_t status’
5419 This is the status of the signature. In particular, the
5420 following status codes are of interest:
5421
5422 ‘GPG_ERR_NO_ERROR’
5423 This status indicates that the signature could be
5424 verified or that there is no signature. For the combined
5425 result this status means that all signatures could be
5426 verified.
5427
5428 Note: This does not mean that a valid signature could be
5429 found. Check the ‘summary’ field for that.
5430
5431 For example a ‘gpgme_op_decrypt_verify’ returns a
5432 verification result with GPG_ERR_NO_ERROR for encrypted
5433 but unsigned data.
5434
5435 ‘GPG_ERR_SIG_EXPIRED’
5436 This status indicates that the signature is valid but
5437 expired. For the combined result this status means that
5438 all signatures are valid and expired.
5439
5440 ‘GPG_ERR_KEY_EXPIRED’
5441 This status indicates that the signature is valid but the
5442 key used to verify the signature has expired. For the
5443 combined result this status means that all signatures are
5444 valid and all keys are expired.
5445
5446 ‘GPG_ERR_CERT_REVOKED’
5447 This status indicates that the signature is valid but the
5448 key used to verify the signature has been revoked. For
5449 the combined result this status means that all signatures
5450 are valid and all keys are revoked.
5451
5452 ‘GPG_ERR_BAD_SIGNATURE’
5453 This status indicates that the signature is invalid. For
5454 the combined result this status means that all signatures
5455 are invalid.
5456
5457 ‘GPG_ERR_NO_PUBKEY’
5458 This status indicates that the signature could not be
5459 verified due to a missing key. For the combined result
5460 this status means that all signatures could not be
5461 checked due to missing keys.
5462
5463 ‘GPG_ERR_GENERAL’
5464 This status indicates that there was some other error
5465 which prevented the signature verification.
5466
5467 ‘gpgme_sig_notation_t notations’
5468 This is a linked list with the notation data and policy URLs.
5469
5470 ‘unsigned long timestamp’
5471 The creation timestamp of this signature.
5472
5473 ‘unsigned long exp_timestamp’
5474 The expiration timestamp of this signature, or 0 if the
5475 signature does not expire.
5476
5477 ‘unsigned int wrong_key_usage : 1’
5478 This is true if the key was not used according to its policy.
5479
5480 ‘unsigned int pka_trust : 2’
5481 This is set to the trust information gained by means of the
5482 PKA system. Values are:
5483 ‘0’
5484 No PKA information available or verification not
5485 possible.
5486 ‘1’
5487 PKA verification failed.
5488 ‘2’
5489 PKA verification succeeded.
5490 ‘3’
5491 Reserved for future use.
5492 Depending on the configuration of the engine, this metric may
5493 also be reflected by the validity of the signature.
5494
5495 ‘unsigned int chain_model : 1’
5496 SINCE: 1.1.6
5497
5498 This is true if the validity of the signature has been checked
5499 using the chain model. In the chain model the time the
5500 signature has been created must be within the validity period
5501 of the certificate and the time the certificate itself has
5502 been created must be within the validity period of the issuing
5503 certificate. In contrast the default validation model checks
5504 the validity of signature as well at the entire certificate
5505 chain at the current time.
5506
5507 ‘gpgme_validity_t validity’
5508 The validity of the signature.
5509
5510 ‘gpgme_error_t validity_reason’
5511 If a signature is not valid, this provides a reason why.
5512
5513 ‘gpgme_pubkey_algo_t’
5514 The public key algorithm used to create this signature.
5515
5516 ‘gpgme_hash_algo_t’
5517 The hash algorithm used to create this signature.
5518
5519 ‘char *pka_address’
5520 The mailbox from the PKA information or ‘NULL’.
5521
5522 ‘gpgme_key_t key’
5523 SINCE: 1.7.0
5524
5525 An object describing the key used to create the signature.
5526 This key object may be incomplete in that it only conveys
5527 information availabale directly with a signature. It may also
5528 be ‘NULL’ if such information is not readily available.
5529
5530 -- Data type: gpgme_verify_result_t
5531 This is a pointer to a structure used to store the result of a
5532 ‘gpgme_op_verify’ operation. After verifying a signature, you can
5533 retrieve the pointer to the result with ‘gpgme_op_verify_result’.
5534 If the operation failed this might be a ‘NULL’ pointer. The
5535 structure contains the following member:
5536
5537 ‘gpgme_signature_t signatures’
5538 A linked list with information about all signatures for which
5539 a verification was attempted.
5540
5541 ‘char *file_name’
5542 This is the filename of the original plaintext message file if
5543 it is known, otherwise this is a null pointer. Warning: The
5544 filename is not covered by the signature.
5545
5546 ‘unsigned int is_mime : 1;’
5547 SINCE: 1.11.0
5548
5549 The message claims that the content is a MIME object.
5550 Warning: This flag is not covered by the signature.
5551
5552 -- Function: gpgme_verify_result_t gpgme_op_verify_result
5553 (gpgme_ctx_t CTX)
5554 The function ‘gpgme_op_verify_result’ returns a
5555 ‘gpgme_verify_result_t’ pointer to a structure holding the result
5556 of a ‘gpgme_op_verify’ operation. The pointer is only valid if the
5557 last operation on the context was a ‘gpgme_op_verify’,
5558 ‘gpgme_op_verify_start’, ‘gpgme_op_decrypt_verify’ or
5559 ‘gpgme_op_decrypt_verify_start’ operation, and if this operation
5560 finished successfully (for ‘gpgme_op_decrypt_verify’ and
5561 ‘gpgme_op_decrypt_verify_start’, the error code ‘GPG_ERR_NO_DATA’
5562 counts as successful in this context). The returned pointer is
5563 only valid until the next operation is started on the context.
5564
5565 
5566 File: gpgme.info, Node: Decrypt and Verify, Next: Sign, Prev: Verify, Up: Crypto Operations
5567
5568 7.6.3 Decrypt and Verify
5569 ------------------------
5570
5571 -- Function: gpgme_error_t gpgme_op_decrypt_verify (gpgme_ctx_t CTX,
5572 gpgme_data_t CIPHER, gpgme_data_t PLAIN)
5573 The function ‘gpgme_op_decrypt_verify’ decrypts the ciphertext in
5574 the data object CIPHER and stores it into the data object PLAIN.
5575 If CIPHER contains signatures, they will be verified.
5576
5577 After the operation completed, ‘gpgme_op_decrypt_result’ and
5578 ‘gpgme_op_verify_result’ can be used to retrieve more information
5579 about the signatures.
5580
5581 If the error code ‘GPG_ERR_NO_DATA’ is returned, CIPHER does not
5582 contain any data to decrypt. However, it might still be signed.
5583 The information about detected signatures is available with
5584 ‘gpgme_op_verify_result’ in this case.
5585
5586 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5587 ciphertext could be decrypted successfully, ‘GPG_ERR_INV_VALUE’ if
5588 CTX, CIPHER or PLAIN is not a valid pointer, ‘GPG_ERR_NO_DATA’ if
5589 CIPHER does not contain any data to decrypt,
5590 ‘GPG_ERR_DECRYPT_FAILED’ if CIPHER is not a valid cipher text,
5591 ‘GPG_ERR_BAD_PASSPHRASE’ if the passphrase for the secret key could
5592 not be retrieved, and passes through any errors that are reported
5593 by the crypto engine support routines.
5594
5595 -- Function: gpgme_error_t gpgme_op_decrypt_verify_start
5596 (gpgme_ctx_t CTX, gpgme_data_t CIPHER, gpgme_data_t PLAIN)
5597 The function ‘gpgme_op_decrypt_verify_start’ initiates a
5598 ‘gpgme_op_decrypt_verify’ operation. It can be completed by
5599 calling ‘gpgme_wait’ on the context. *Note Waiting For
5600 Completion::.
5601
5602 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5603 operation could be started successfully, ‘GPG_ERR_INV_VALUE’ if
5604 CTX, CIPHER, PLAIN or R_STAT is not a valid pointer, and
5605 ‘GPG_ERR_NO_DATA’ if CIPHER does not contain any data to decrypt.
5606
5607 When processing mails it is sometimes useful to extract the actual
5608 mail address (the “addr-spec”) from a string. GPGME provides this
5609 helper function which uses the same semantics as the internal functions
5610 in GPGME and GnuPG:
5611
5612 -- Function: char * gpgme_addrspec_from_uid (const char *UID)
5613
5614 SINCE: 1.7.1
5615
5616 Return the mail address (called “addr-spec” in RFC-5322) from the
5617 string UID which is assumed to be a user id (called “address” in
5618 RFC-5322). All plain ASCII characters (i.e. those with bit 7
5619 cleared) in the result are converted to lowercase. Caller must
5620 free the result using ‘gpgme_free’. Returns ‘NULL’ if no valid
5621 address was found (in which case ‘ERRNO’ is set to ‘EINVAL’) or for
5622 other errors.
5623
5624 
5625 File: gpgme.info, Node: Sign, Next: Encrypt, Prev: Decrypt and Verify, Up: Crypto Operations
5626
5627 7.6.4 Sign
5628 ----------
5629
5630 A signature can contain signatures by one or more keys. The set of keys
5631 used to create a signatures is contained in a context, and is applied to
5632 all following signing operations in this context (until the set is
5633 changed).
5634
5635 * Menu:
5636
5637 * Selecting Signers:: How to choose the keys to sign with.
5638 * Creating a Signature:: How to create a signature.
5639 * Signature Notation Data:: How to add notation data to a signature.
5640
5641 
5642 File: gpgme.info, Node: Selecting Signers, Next: Creating a Signature, Up: Sign
5643
5644 7.6.4.1 Selecting Signers
5645 .........................
5646
5647 The key or the keys used to create a signature are stored in the
5648 context. The following functions can be used to manipulate this list.
5649 If no signer has been set into the context a default key is used for
5650 signing.
5651
5652 -- Function: void gpgme_signers_clear (gpgme_ctx_t CTX)
5653 The function ‘gpgme_signers_clear’ releases a reference for each
5654 key on the signers list and removes the list of signers from the
5655 context CTX.
5656
5657 Every context starts with an empty list.
5658
5659 -- Function: gpgme_error_t gpgme_signers_add (gpgme_ctx_t CTX,
5660 const gpgme_key_t KEY)
5661 The function ‘gpgme_signers_add’ adds the key KEY to the list of
5662 signers in the context CTX.
5663
5664 Calling this function acquires an additional reference for the key.
5665
5666 -- Function: unsigned int gpgme_signers_count (const gpgme_ctx_t CTX)
5667 SINCE: 1.4.3
5668
5669 The function ‘gpgme_signers_count’ returns the number of signer
5670 keys in the context CTX.
5671
5672 -- Function: gpgme_key_t gpgme_signers_enum (const gpgme_ctx_t CTX,
5673 int SEQ)
5674 The function ‘gpgme_signers_enum’ returns the SEQth key in the list
5675 of signers in the context CTX. An additional reference is acquired
5676 for the user.
5677
5678 If SEQ is out of range, ‘NULL’ is returned.
5679
5680 
5681 File: gpgme.info, Node: Creating a Signature, Next: Signature Notation Data, Prev: Selecting Signers, Up: Sign
5682
5683 7.6.4.2 Creating a Signature
5684 ............................
5685
5686 -- Data type: enum gpgme_sig_mode_t
5687 The ‘gpgme_sig_mode_t’ type is used to specify the desired type of
5688 a signature. The following modes are available:
5689
5690 ‘GPGME_SIG_MODE_NORMAL’
5691 A normal signature is made, the output includes the plaintext
5692 and the signature.
5693
5694 ‘GPGME_SIG_MODE_DETACH’
5695 A detached signature is made.
5696
5697 ‘GPGME_SIG_MODE_CLEAR’
5698 A clear text signature is made. The ASCII armor and text mode
5699 settings of the context are ignored.
5700
5701 -- Function: gpgme_error_t gpgme_op_sign (gpgme_ctx_t CTX,
5702 gpgme_data_t PLAIN, gpgme_data_t SIG, gpgme_sig_mode_t MODE)
5703 The function ‘gpgme_op_sign’ creates a signature for the text in
5704 the data object PLAIN and returns it in the data object SIG. The
5705 type of the signature created is determined by the ASCII armor (or,
5706 if that is not set, by the encoding specified for SIG), the text
5707 mode attributes set for the context CTX and the requested signature
5708 mode MODE.
5709
5710 After the operation completed successfully, the result can be
5711 retrieved with ‘gpgme_op_sign_result’.
5712
5713 If an S/MIME signed message is created using the CMS crypto engine,
5714 the number of certificates to include in the message can be
5715 specified with ‘gpgme_set_include_certs’. *Note Included
5716 Certificates::.
5717
5718 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5719 signature could be created successfully, ‘GPG_ERR_INV_VALUE’ if
5720 CTX, PLAIN or SIG is not a valid pointer, ‘GPG_ERR_NO_DATA’ if the
5721 signature could not be created, ‘GPG_ERR_BAD_PASSPHRASE’ if the
5722 passphrase for the secret key could not be retrieved,
5723 ‘GPG_ERR_UNUSABLE_SECKEY’ if there are invalid signers, and passes
5724 through any errors that are reported by the crypto engine support
5725 routines.
5726
5727 -- Function: gpgme_error_t gpgme_op_sign_start (gpgme_ctx_t CTX,
5728 gpgme_data_t PLAIN, gpgme_data_t SIG, gpgme_sig_mode_t MODE)
5729 The function ‘gpgme_op_sign_start’ initiates a ‘gpgme_op_sign’
5730 operation. It can be completed by calling ‘gpgme_wait’ on the
5731 context. *Note Waiting For Completion::.
5732
5733 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5734 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
5735 CTX, PLAIN or SIG is not a valid pointer.
5736
5737 -- Data type: gpgme_new_signature_t
5738 This is a pointer to a structure used to store a part of the result
5739 of a ‘gpgme_op_sign’ operation. The structure contains the
5740 following members:
5741
5742 ‘gpgme_new_signature_t next’
5743 This is a pointer to the next new signature structure in the
5744 linked list, or ‘NULL’ if this is the last element.
5745
5746 ‘gpgme_sig_mode_t type’
5747 The type of this signature.
5748
5749 ‘gpgme_pubkey_algo_t pubkey_algo’
5750 The public key algorithm used to create this signature.
5751
5752 ‘gpgme_hash_algo_t hash_algo’
5753 The hash algorithm used to create this signature.
5754
5755 ‘unsigned int sig_class’
5756 The signature class of this signature.
5757
5758 ‘long int timestamp’
5759 The creation timestamp of this signature.
5760
5761 ‘char *fpr’
5762 The fingerprint of the key which was used to create this
5763 signature.
5764
5765 -- Data type: gpgme_sign_result_t
5766 This is a pointer to a structure used to store the result of a
5767 ‘gpgme_op_sign’ operation. After successfully generating a
5768 signature, you can retrieve the pointer to the result with
5769 ‘gpgme_op_sign_result’. The structure contains the following
5770 members:
5771
5772 ‘gpgme_invalid_key_t invalid_signers’
5773 A linked list with information about all invalid keys for
5774 which a signature could not be created.
5775
5776 ‘gpgme_new_signature_t signatures’
5777 A linked list with information about all signatures created.
5778
5779 -- Function: gpgme_sign_result_t gpgme_op_sign_result (gpgme_ctx_t CTX)
5780 The function ‘gpgme_op_sign_result’ returns a ‘gpgme_sign_result_t’
5781 pointer to a structure holding the result of a ‘gpgme_op_sign’
5782 operation. The pointer is only valid if the last operation on the
5783 context was a ‘gpgme_op_sign’, ‘gpgme_op_sign_start’,
5784 ‘gpgme_op_encrypt_sign’ or ‘gpgme_op_encrypt_sign_start’ operation.
5785 If that operation failed, the function might return a ‘NULL’
5786 pointer. The returned pointer is only valid until the next
5787 operation is started on the context.
5788
5789 
5790 File: gpgme.info, Node: Signature Notation Data, Prev: Creating a Signature, Up: Sign
5791
5792 7.6.4.3 Signature Notation Data
5793 ...............................
5794
5795 Using the following functions, you can attach arbitrary notation data to
5796 a signature. This information is then available to the user when the
5797 signature is verified.
5798
5799 -- Function: void gpgme_sig_notation_clear (gpgme_ctx_t CTX)
5800 SINCE: 1.1.0
5801
5802 The function ‘gpgme_sig_notation_clear’ removes the notation data
5803 from the context CTX. Subsequent signing operations from this
5804 context will not include any notation data.
5805
5806 Every context starts with an empty notation data list.
5807
5808 -- Function: gpgme_error_t gpgme_sig_notation_add (gpgme_ctx_t CTX,
5809 const char *NAME, const char *VALUE,
5810 gpgme_sig_notation_flags_t FLAGS)
5811 SINCE: 1.1.0
5812
5813 The function ‘gpgme_sig_notation_add’ adds the notation data with
5814 the name NAME and the value VALUE to the context CTX.
5815
5816 Subsequent signing operations will include this notation data, as
5817 well as any other notation data that was added since the creation
5818 of the context or the last ‘gpgme_sig_notation_clear’ operation.
5819
5820 The arguments NAME and VALUE must be ‘NUL’-terminated strings in
5821 human-readable form. The flag ‘GPGME_SIG_NOTATION_HUMAN_READABLE’
5822 is implied (non-human-readable notation data is currently not
5823 supported). The strings must be in UTF-8 encoding.
5824
5825 If NAME is ‘NULL’, then VALUE should be a policy URL.
5826
5827 The function ‘gpgme_sig_notation_add’ returns the error code
5828 ‘GPG_ERR_NO_ERROR’ if the notation data could be added
5829 successfully, ‘GPG_ERR_INV_VALUE’ if CTX is not a valid pointer, or
5830 if NAME, VALUE and FLAGS are an invalid combination. The function
5831 also passes through any errors that are reported by the crypto
5832 engine support routines.
5833
5834 -- Function: gpgme_sig_notation_t gpgme_sig_notation_get
5835 (const gpgme_ctx_t CTX)
5836 SINCE: 1.1.0
5837
5838 The function ‘gpgme_sig_notation_get’ returns the linked list of
5839 notation data structures that are contained in the context CTX.
5840
5841 If CTX is not a valid pointer, or there is no notation data added
5842 for this context, ‘NULL’ is returned.
5843
5844 
5845 File: gpgme.info, Node: Encrypt, Prev: Sign, Up: Crypto Operations
5846
5847 7.6.5 Encrypt
5848 -------------
5849
5850 One plaintext can be encrypted for several recipients at the same time.
5851 The list of recipients is created independently of any context, and then
5852 passed to the encryption operation.
5853
5854 * Menu:
5855
5856 * Encrypting a Plaintext:: How to encrypt a plaintext.
5857
5858 
5859 File: gpgme.info, Node: Encrypting a Plaintext, Up: Encrypt
5860
5861 7.6.5.1 Encrypting a Plaintext
5862 ..............................
5863
5864 -- Function: gpgme_error_t gpgme_op_encrypt (gpgme_ctx_t CTX,
5865 gpgme_key_t RECP[], gpgme_encrypt_flags_t FLAGS,
5866 gpgme_data_t PLAIN, gpgme_data_t CIPHER)
5867 The function ‘gpgme_op_encrypt’ encrypts the plaintext in the data
5868 object PLAIN for the recipients RECP and stores the ciphertext in
5869 the data object CIPHER. The type of the ciphertext created is
5870 determined by the ASCII armor (or, if that is not set, by the
5871 encoding specified for CIPHER) and the text mode attributes set for
5872 the context CTX.
5873
5874 RECP must be a ‘NULL’-terminated array of keys. The user must keep
5875 references for all keys during the whole duration of the call (but
5876 see ‘gpgme_op_encrypt_start’ for the requirements with the
5877 asynchronous variant).
5878
5879 The value in FLAGS is a bitwise-or combination of one or multiple
5880 of the following bit values:
5881
5882 ‘GPGME_ENCRYPT_ALWAYS_TRUST’
5883 The ‘GPGME_ENCRYPT_ALWAYS_TRUST’ symbol specifies that all the
5884 recipients in RECP should be trusted, even if the keys do not
5885 have a high enough validity in the keyring. This flag should
5886 be used with care; in general it is not a good idea to use any
5887 untrusted keys.
5888
5889 ‘GPGME_ENCRYPT_NO_ENCRYPT_TO’
5890 SINCE: 1.2.0
5891
5892 The ‘GPGME_ENCRYPT_NO_ENCRYPT_TO’ symbol specifies that no
5893 default or hidden default recipients as configured in the
5894 crypto backend should be included. This can be useful for
5895 managing different user profiles.
5896
5897 ‘GPGME_ENCRYPT_NO_COMPRESS’
5898 SINCE: 1.5.0
5899
5900 The ‘GPGME_ENCRYPT_NO_COMPRESS’ symbol specifies that the
5901 plaintext shall not be compressed before it is encrypted.
5902 This is in some cases useful if the length of the encrypted
5903 message may reveal information about the plaintext.
5904
5905 ‘GPGME_ENCRYPT_PREPARE’
5906 ‘GPGME_ENCRYPT_EXPECT_SIGN’
5907 The ‘GPGME_ENCRYPT_PREPARE’ symbol is used with the UI Server
5908 protocol to prepare an encryption (i.e. sending the
5909 ‘PREP_ENCRYPT’ command). With the ‘GPGME_ENCRYPT_EXPECT_SIGN’
5910 symbol the UI Server is advised to also expect a sign command.
5911
5912 ‘GPGME_ENCRYPT_SYMMETRIC’
5913 SINCE: 1.7.0
5914
5915 The ‘GPGME_ENCRYPT_SYMMETRIC’ symbol specifies that the output
5916 should be additionally encrypted symmetrically even if
5917 recipients are provided. This feature is only supported for
5918 the OpenPGP crypto engine.
5919
5920 ‘GPGME_ENCRYPT_THROW_KEYIDS’
5921 SINCE: 1.8.0
5922
5923 The ‘GPGME_ENCRYPT_THROW_KEYIDS’ symbols requests that the
5924 identifiers for the decrption keys are not included in the
5925 ciphertext. On the receiving side, the use of this flag may
5926 slow down the decryption process because all available secret
5927 keys must be tried. This flag is only honored for OpenPGP
5928 encryption.
5929
5930 ‘GPGME_ENCRYPT_WRAP’
5931 SINCE: 1.8.0
5932
5933 The ‘GPGME_ENCRYPT_WRAP’ symbol specifies that the input is an
5934 OpenPGP message and not a plain data. This is the counterpart
5935 to ‘GPGME_DECRYPT_UNWRAP’.
5936
5937 ‘GPGME_ENCRYPT_WANT_ADDRESS’
5938 SINCE: 1.11.0
5939
5940 The ‘GPGME_ENCRYPT_WANT_ADDRESS’ symbol requests that all
5941 supplied keys or key specifications include a syntactically
5942 valid mail address. If this is not the case the operation is
5943 not even tried and the error code ‘GPG_ERR_INV_USER_ID’ is
5944 returned. Only the address part of the key specification is
5945 conveyed to the backend. As of now the key must be specified
5946 using the RECPSTRING argument of the extended encrypt
5947 functions. This feature is currently only supported for the
5948 OpenPGP crypto engine.
5949
5950 If ‘GPG_ERR_UNUSABLE_PUBKEY’ is returned, some recipients in RECP
5951 are invalid, but not all. In this case the plaintext might be
5952 encrypted for all valid recipients and returned in CIPHER (if this
5953 happens depends on the crypto engine). More information about the
5954 invalid recipients is available with ‘gpgme_op_encrypt_result’.
5955
5956 If RECP is ‘NULL’, symmetric rather than public key encryption is
5957 performed. Symmetrically encrypted cipher text can be deciphered
5958 with ‘gpgme_op_decrypt’. Note that in this case the crypto backend
5959 needs to retrieve a passphrase from the user. Symmetric encryption
5960 is currently only supported for the OpenPGP crypto backend.
5961
5962 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5963 ciphertext could be created successfully, ‘GPG_ERR_INV_VALUE’ if
5964 CTX, RECP, PLAIN or CIPHER is not a valid pointer,
5965 ‘GPG_ERR_UNUSABLE_PUBKEY’ if RECP contains some invalid recipients,
5966 ‘GPG_ERR_BAD_PASSPHRASE’ if the passphrase for the symmetric key
5967 could not be retrieved, and passes through any errors that are
5968 reported by the crypto engine support routines.
5969
5970 -- Function: gpgme_error_t gpgme_op_encrypt_start (gpgme_ctx_t CTX,
5971 gpgme_key_t RECP[], gpgme_encrypt_flags_t FLAGS,
5972 gpgme_data_t PLAIN, gpgme_data_t CIPHER)
5973 The function ‘gpgme_op_encrypt_start’ initiates a
5974 ‘gpgme_op_encrypt’ operation. It can be completed by calling
5975 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
5976
5977 References to the keys only need to be held for the duration of
5978 this call. The user can release its references to the keys after
5979 this function returns, even if the operation is not yet finished.
5980
5981 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
5982 operation could be started successfully, ‘GPG_ERR_INV_VALUE’ if
5983 CTX, RSET, PLAIN or CIPHER is not a valid pointer, and
5984 ‘GPG_ERR_UNUSABLE_PUBKEY’ if RSET does not contain any valid
5985 recipients.
5986
5987 -- Function: gpgme_error_t gpgme_op_encrypt_ext (gpgme_ctx_t CTX,
5988 gpgme_key_t RECP[], const char *RECPSTRING,
5989 gpgme_encrypt_flags_t FLAGS, gpgme_data_t PLAIN,
5990 gpgme_data_t CIPHER)
5991
5992 SINCE: 1.11.0
5993
5994 This is an extended version of ‘gpgme_op_encrypt’ with RECPSTRING
5995 as additional parameter. If RECP is NULL and RECPSTRING is not
5996 NULL, the latter is expected to be a linefeed delimited string with
5997 the set of key specifications. In contrast to RECP the keys are
5998 given directly as strings and there is no need to first create key
5999 objects. Leading and trailing white space is remove from each line
6000 in RECPSTRING. The keys are then passed verbatim to the backend
6001 engine.
6002
6003 For the OpenPGP backend several special keywords are supported to
6004 modify the operation. These keywords are given instead of a key
6005 specification. The currently supported keywords are:
6006
6007 ‘--hidden’
6008 ‘--no-hidden’
6009 These keywords toggle between normal and hidden recipients for
6010 all following key specifications. When a hidden recipient is
6011 requested the gpg option ‘-R’ (or ‘-F’ in file mode) is used
6012 instead of ‘-r’ (‘-f’ in file mode).
6013
6014 ‘--file’
6015 ‘--no-file’
6016 These keywords toggle between regular and file mode for all
6017 following key specification. In file mode the option ‘-f’ or
6018 ‘-F’ is passed to gpg. At least GnuPG version 2.1.14 is
6019 required to handle these options. The
6020 ‘GPGME_ENCRYPT_WANT_ADDRESS’ flag is ignored in file mode.
6021
6022 ‘--’
6023 This keyword disables all keyword detection up to the end of
6024 the string. All keywords are treated as verbatim arguments.
6025
6026 To create a RECPSTRING it is often useful to employ a strconcat
6027 style function. For example this function creates a string to
6028 encrypt to two keys:
6029
6030 char *
6031 xbuild_recpstring (const char *key1, const char *key2)
6032 {
6033 char *result = gpgrt_strconcat ("--\n", key1, "\n", key2, NULL);
6034 if (!result)
6035 { perror ("strconcat failed"); exit (2); }
6036 return result;
6037 }
6038
6039 Note the use of the double dash here; unless you want to specify a
6040 keyword, it is a good idea to avoid any possible trouble with key
6041 specifications starting with a double dash. The used strconcat
6042 function is available in Libgpg-error 1.28 and later; Libgpg-error
6043 (aka Gpgrt) is a dependency of GPGME. The number of arguments to
6044 ‘gpgrt_strconcat’ is limited to 47 but that should always be
6045 sufficient. In case a larger and non-fixed number of keys are to
6046 be supplied the following code can be used:
6047
6048 char *
6049 xbuild_long_recpstring (void)
6050 {
6051 gpgrt_stream_t memfp;
6052 const char *s;
6053 void *result;
6054
6055 memfp = gpgrt_fopenmem (0, "w+b");
6056 if (!memfp)
6057 { perror ("fopenmem failed"); exit (2); }
6058 gpgrt_fputs ("--", memfp);
6059 while ((s = get_next_keyspec ()))
6060 {
6061 gpgrt_fputc ('\n', memfp);
6062 gpgrt_fputs (s, memfp);
6063 }
6064 gpgrt_fputc (0, memfp);
6065 if (gpgrt_ferror (memfp))
6066 { perror ("writing to memstream failed"); exit (2); }
6067 if (gpgrt_fclose_snatch (memfp, &result, NULL))
6068 { perror ("fclose_snatch failed"); exit (2); }
6069 return result;
6070 }
6071
6072 In this example ‘get_next_keyspec’ is expected to return the next
6073 key to be added to the string. Please take care: Encrypting to a
6074 large number of recipients is often questionable due to security
6075 reasons and also for the technicality that all keys are currently
6076 passed on the command line to ‘gpg’ which has as a platform
6077 specific length limitation.
6078
6079 -- Function: gpgme_error_t gpgme_op_encrypt_ext_start (gpgme_ctx_t CTX,
6080 gpgme_key_t RECP[], const char *RECPSTRING,
6081 gpgme_encrypt_flags_t FLAGS, gpgme_data_t PLAIN,
6082 gpgme_data_t CIPHER)
6083
6084 SINCE: 1.11.0
6085
6086 This is an extended version of ‘gpgme_op_encrypt_start’ with
6087 RECPSTRING as additional parameter. If RECP is NULL and RECPSTRING
6088 is not NULL, the latter is expected to be a linefeed delimited
6089 string with the set of key specifications. In contrast to RECP the
6090 keys are given directly as strings and there is no need to first
6091 create key objects. The keys are passed verbatim to the backend
6092 engine.
6093
6094 -- Data type: gpgme_encrypt_result_t
6095 This is a pointer to a structure used to store the result of a
6096 ‘gpgme_op_encrypt’ operation. After successfully encrypting data,
6097 you can retrieve the pointer to the result with
6098 ‘gpgme_op_encrypt_result’. The structure contains the following
6099 members:
6100
6101 ‘gpgme_invalid_key_t invalid_recipients’
6102 A linked list with information about all invalid keys for
6103 which the data could not be encrypted.
6104
6105 -- Function: gpgme_encrypt_result_t gpgme_op_encrypt_result
6106 (gpgme_ctx_t CTX)
6107 The function ‘gpgme_op_encrypt_result’ returns a
6108 ‘gpgme_encrypt_result_t’ pointer to a structure holding the result
6109 of a ‘gpgme_op_encrypt’ operation. The pointer is only valid if
6110 the last operation on the context was a ‘gpgme_op_encrypt’,
6111 ‘gpgme_op_encrypt_start’, ‘gpgme_op_sign’ or ‘gpgme_op_sign_start’
6112 operation. If this operation failed, this might be a ‘NULL’
6113 pointer. The returned pointer is only valid until the next
6114 operation is started on the context.
6115
6116 -- Function: gpgme_error_t gpgme_op_encrypt_sign (gpgme_ctx_t CTX,
6117 gpgme_key_t RECP[], gpgme_encrypt_flags_t FLAGS,
6118 gpgme_data_t PLAIN, gpgme_data_t CIPHER)
6119 The function ‘gpgme_op_encrypt_sign’ does a combined encrypt and
6120 sign operation. It is used like ‘gpgme_op_encrypt’, but the
6121 ciphertext also contains signatures for the signers listed in CTX.
6122
6123 The combined encrypt and sign operation is currently only available
6124 for the OpenPGP crypto engine.
6125
6126 -- Function: gpgme_error_t gpgme_op_encrypt_sign_start
6127 (gpgme_ctx_t CTX, gpgme_key_t RECP[],
6128 gpgme_encrypt_flags_t FLAGS, gpgme_data_t PLAIN,
6129 gpgme_data_t CIPHER)
6130 The function ‘gpgme_op_encrypt_sign_start’ initiates a
6131 ‘gpgme_op_encrypt_sign’ operation. It can be completed by calling
6132 ‘gpgme_wait’ on the context. *Note Waiting For Completion::.
6133
6134 The function returns the error code ‘GPG_ERR_NO_ERROR’ if the
6135 operation could be started successfully, and ‘GPG_ERR_INV_VALUE’ if
6136 CTX, RSET, PLAIN or CIPHER is not a valid pointer.
6137
6138 -- Function: gpgme_error_t gpgme_op_encrypt_sign_ext (gpgme_ctx_t CTX,
6139 gpgme_key_t RECP[], const char *RECPSTRING,
6140 gpgme_encrypt_flags_t FLAGS, gpgme_data_t PLAIN,
6141 gpgme_data_t CIPHER)
6142
6143 SINCE: 1.11.0
6144
6145 This is an extended version of ‘gpgme_op_encrypt_sign’ with
6146 RECPSTRING as additional parameter. If RECP is NULL and RECPSTRING
6147 is not NULL, the latter is expected to be a linefeed delimited
6148 string with the set of key specifications. In contrast to RECP the
6149 keys are given directly as strings and there is no need to first
6150 create the key objects. The keys are passed verbatim to the
6151 backend engine.
6152
6153 -- Function: gpgme_error_t gpgme_op_encrypt_sign_ext_start
6154 (gpgme_ctx_t CTX, gpgme_key_t RECP[], const char *RECPSTRING,
6155 gpgme_encrypt_flags_t FLAGS, gpgme_data_t PLAIN,
6156 gpgme_data_t CIPHER)
6157
6158 SINCE: 1.11.0
6159
6160 This is an extended version of ‘gpgme_op_encrypt_sign_start’ with
6161 RECPSTRING as additional parameter. If RECP is NULL and RECPSTRING
6162 is not NULL, the latter is expected to be a linefeed delimited
6163 string with the set of key specifications. In contrast to RECP the
6164 keys are given directly as strings and there is no need to first
6165 create the key objects. The keys are passed verbatim to the
6166 backend engine.
6167
6168 
6169 File: gpgme.info, Node: Miscellaneous, Next: Run Control, Prev: Crypto Operations, Up: Contexts
6170
6171 7.7 Miscellaneous operations
6172 ============================
6173
6174 Here are some support functions which are sometimes useful.
6175
6176 * Menu:
6177
6178 * Running other Programs:: Running other Programs
6179 * Using the Assuan protocol:: Using the Assuan protocol
6180 * Checking for updates:: How to check for software updates
6181
6182 
6183 File: gpgme.info, Node: Running other Programs, Next: Using the Assuan protocol, Up: Miscellaneous
6184
6185 7.7.1 Running other Programs
6186 ----------------------------
6187
6188 GPGME features an internal subsystem to run the actual backend engines.
6189 Along with data abstraction object this subsystem can be used to run
6190 arbitrary simple programs which even need not be related to
6191 cryptographic features. It may for example be used to run tools which
6192 are part of the GnuPG system but are not directly accessible with the
6193 GPGME API.
6194
6195 -- Function: gpgme_error_t gpgme_op_spawn (gpgme_ctx_t CTX,
6196 const char *FILE, const char *ARGV[], gpgme_data_t DATAIN,
6197 gpgme_data_t DATAOUT, gpgme_data_t DATAERR,
6198 unsigned int FLAGS)
6199
6200 SINCE: 1.5.0
6201
6202 The function ‘gpgme_op_spawn’ runs the program FILE with the
6203 arguments taken from the NULL terminated array ARGV. If no
6204 arguments are required ARGV may be given as ‘NULL’. In the latter
6205 case or if ‘argv[0]’ is the empty string, GPGME uses the basename
6206 of FILE for ‘argv[0]’. The file descriptors ‘stdin’, ‘stdout’, and
6207 ‘stderr’ are connected to the data objects DATAIN, DATAOUT, and
6208 DATAERR. If NULL is passed for one of these data objects the
6209 corresponding file descriptor is connected to ‘/dev/null’.
6210
6211 The value in FLAGS is a bitwise-or combination of one or multiple
6212 of the following bit values:
6213
6214 ‘GPGME_SPAWN_DETACHED’
6215 SINCE: 1.5.0
6216
6217 Under Windows this flag inhibits the allocation of a new
6218 console for the program. This is useful for a GUI application
6219 which needs to call a command line helper tool.
6220
6221 ‘GPGME_SPAWN_ALLOW_SET_FG’
6222 SINCE: 1.5.0
6223
6224 Under Windows this flag allows the called program to put
6225 itself into the foreground.
6226
6227 -- Function: gpgme_error_t gpgme_op_spawn_start (gpgme_ctx_t CTX,
6228 const char *FILE, const char *ARGV[], gpgme_data_t DATAIN,
6229 gpgme_data_t DATAOUT, gpgme_data_t DATAERR,
6230 unsigned int FLAGS)
6231
6232 SINCE: 1.5.0
6233
6234 This is the asynchronous variant of ‘gpgme_op_spawn’.
6235
6236 
6237 File: gpgme.info, Node: Using the Assuan protocol, Next: Checking for updates, Prev: Running other Programs, Up: Miscellaneous
6238
6239 7.7.2 Using the Assuan protocol
6240 -------------------------------
6241
6242 The Assuan protocol can be used to talk to arbitrary Assuan servers. By
6243 default it is connected to the GnuPG agent, but it may be connected to
6244 arbitrary servers by using ‘gpgme_ctx_set_engine_info’, passing the
6245 location of the servers socket as FILE_NAME argument, and an empty
6246 string as HOME_DIR argument.
6247
6248 The Assuan protocol functions use three kinds of callbacks to
6249 transfer data:
6250
6251 -- Data type: gpgme_error_t (*gpgme_assuan_data_cb_t) (void *OPAQUE,
6252 const void *DATA, size_t DATALEN)
6253
6254 SINCE: 1.2.0
6255
6256 This callback receives any data sent by the server. OPAQUE is the
6257 pointer passed to ‘gpgme_op_assuan_transact_start’, DATA of length
6258 DATALEN refers to the data sent.
6259
6260 -- Data type: gpgme_error_t (*gpgme_assuan_inquire_cb_t) (void *OPAQUE,
6261 const char *NAME, const char *ARGS, gpgme_data_t *R_DATA)
6262
6263 SINCE: 1.2.0
6264
6265 This callback is used to provide additional data to the Assuan
6266 server. OPAQUE is the pointer passed to
6267 ‘gpgme_op_assuan_transact_start’, NAME and ARGS specify what kind
6268 of data the server requested, and R_DATA is used to return the
6269 actual data.
6270
6271 Note: Returning data is currently not implemented in GPGME.
6272
6273 -- Data type: gpgme_error_t (*gpgme_assuan_status_cb_t) (void *OPAQUE,
6274 const char *STATUS, const char *ARGS)
6275
6276 SINCE: 1.2.0
6277
6278 This callback receives any status lines sent by the server. OPAQUE
6279 is the pointer passed to ‘gpgme_op_assuan_transact_start’, STATUS
6280 and ARGS denote the status update sent.
6281
6282 -- Function: gpgme_error_t gpgme_op_assuan_transact_start
6283 (gpgme_ctx_t CTX, const char *COMMAND,
6284 gpgme_assuan_data_cb_t DATA_CB, void * DATA_CB_VALUE,
6285 gpgme_assuan_inquire_cb_t INQUIRE_CB, void * INQUIRE_CB_VALUE,
6286 gpgme_assuan_status_cb_t STATUS_CB, void * STATUS_CB_VALUE)
6287
6288 SINCE: 1.2.0
6289
6290 Send the Assuan COMMAND and return results via the callbacks. Any
6291 callback may be ‘NULL’. The result of the operation may be
6292 retrieved using ‘gpgme_wait_ext’.
6293
6294 Asynchronous variant.
6295
6296 -- Function: gpgme_error_t gpgme_op_assuan_transact_ext
6297 (gpgme_ctx_t CTX, const char *COMMAND,
6298 gpgme_assuan_data_cb_t DATA_CB, void * DATA_CB_VALUE,
6299 gpgme_assuan_inquire_cb_t INQUIRE_CB, void * INQUIRE_CB_VALUE,
6300 gpgme_assuan_status_cb_t STATUS_CB, void * STATUS_CB_VALUE,
6301 gpgme_error_t *OP_ERR)
6302
6303 Send the Assuan COMMAND and return results via the callbacks. The
6304 result of the operation is returned in OP_ERR.
6305
6306 Synchronous variant.
6307
6308 
6309 File: gpgme.info, Node: Checking for updates, Prev: Using the Assuan protocol, Up: Miscellaneous
6310
6311 7.7.3 How to check for software updates
6312 ---------------------------------------
6313
6314 The GnuPG Project operates a server to query the current versions of
6315 software packages related to GnuPG. GPGME can be used to access this
6316 online database and check whether a new version of a software package is
6317 available.
6318
6319 -- Data type: gpgme_query_swdb_result_t
6320 SINCE: 1.8.0
6321
6322 This is a pointer to a structure used to store the result of a
6323 ‘gpgme_op_query_swdb’ operation. After success full call to that
6324 function, you can retrieve the pointer to the result with
6325 ‘gpgme_op_query_swdb_result’. The structure contains the following
6326 member:
6327
6328 ‘name’
6329 This is the name of the package.
6330
6331 ‘iversion’
6332 The currently installed version or an empty string. This
6333 value is either a copy of the argument given to
6334 ‘gpgme_op_query_swdb’ or the version of the installed software
6335 as figured out by GPGME or GnuPG.
6336
6337 ‘created’
6338 This gives the date the file with the list of version numbers
6339 has originally be created by the GnuPG project.
6340
6341 ‘retrieved’
6342 This gives the date the file was downloaded.
6343
6344 ‘warning’
6345 If this flag is set either an error has occurred or some of
6346 the information in this structure are not properly set. For
6347 example if the version number of the installed software could
6348 not be figured out, the ‘update’ flag may not reflect a
6349 required update status.
6350
6351 ‘update’
6352 If this flag is set an update of the software is available.
6353
6354 ‘urgent’
6355 If this flag is set an available update is important.
6356
6357 ‘noinfo’
6358 If this flag is set, no valid information could be retrieved.
6359
6360 ‘unknown’
6361 If this flag is set the given ‘name’ is not known.
6362
6363 ‘tooold’
6364 If this flag is set the available information is not fresh
6365 enough.
6366
6367 ‘error’
6368 If this flag is set some other error has occurred.
6369
6370 ‘version’
6371 The version string of the latest released version.
6372
6373 ‘reldate’
6374 The release date of the latest released version.
6375
6376 -- Function: gpgme_error_t gpgme_op_query_swdb (gpgme_ctx_t CTX,
6377 const char *NAME, const char *IVERSION, gpgme_data_t RESERVED)
6378
6379 SINCE: 1.8.0
6380
6381 Query the software version database for software package NAME and
6382 check against the installed version given by IVERSION. If IVERSION
6383 is given as ‘NULL’ a check is only done if GPGME can figure out the
6384 version by itself (for example when using "gpgme" or "gnupg"). If
6385 ‘NULL’ is used for NAME the current gpgme version is checked.
6386 RESERVED must be set to 0.
6387
6388 -- Function: gpgme_query_swdb_result_t gpgme_op_query_swdb_result
6389 (gpgme_ctx_t CTX)
6390
6391 SINCE: 1.8.0
6392
6393 The function ‘gpgme_op_query_swdb_result’ returns a
6394 ‘gpgme_query_swdb_result_t’ pointer to a structure holding the
6395 result of a ‘gpgme_op_query_swdb’ operation. The pointer is only
6396 valid if the last operation on the context was a successful call to
6397 ‘gpgme_op_query_swdb’. If that call failed, the result might be a
6398 ‘NULL’ pointer. The returned pointer is only valid until the next
6399 operation is started on the context CTX.
6400
6401 Here is an example on how to check whether GnuPG is current:
6402
6403 #include <gpgme.h>
6404
6405 int
6406 main (void)
6407 {
6408 gpg_error_t err;
6409 gpgme_ctx_t ctx;
6410 gpgme_query_swdb_result_t result;
6411
6412 gpgme_check_version (NULL);
6413 err = gpgme_new (&ctx);
6414 if (err)
6415 fprintf (stderr, "error creating context: %s\n", gpg_strerror (err));
6416 else
6417 {
6418 gpgme_set_protocol (ctx, GPGME_PROTOCOL_GPGCONF);
6419
6420 err = gpgme_op_query_swdb (ctx, "gnupg", NULL, 0);
6421 if (err)
6422 fprintf (stderr, "error querying swdb: %s\n", gpg_strerror (err));
6423 else
6424 {
6425 result = gpgme_op_query_swdb_result (ctx);
6426 if (!result)
6427 fprintf (stderr, "error querying swdb\n");
6428 if (!result->warning && !result->update)
6429 printf ("GnuPG version %s is current\n",
6430 result->iversion);
6431 else if (!result->warning && result->update)
6432 printf ("GnuPG version %s can be updated to %s\n",
6433 result->iversion, result->version);
6434 else
6435 fprintf (stderr, "error finding the update status\n");
6436 }
6437 gpgme_release (ctx);
6438 }
6439 return 0;
6440 }
6441
6442 
6443 File: gpgme.info, Node: Run Control, Prev: Miscellaneous, Up: Contexts
6444
6445 7.8 Run Control
6446 ===============
6447
6448 GPGME supports running operations synchronously and asynchronously. You
6449 can use asynchronous operation to set up a context up to initiating the
6450 desired operation, but delay performing it to a later point.
6451
6452 Furthermore, you can use an external event loop to control exactly
6453 when GPGME runs. This ensures that GPGME only runs when necessary and
6454 also prevents it from blocking for a long time.
6455
6456 * Menu:
6457
6458 * Waiting For Completion:: Waiting until an operation is completed.
6459 * Using External Event Loops:: Advanced control over what happens when.
6460 * Cancellation:: How to end pending operations prematurely.
6461
6462 
6463 File: gpgme.info, Node: Waiting For Completion, Next: Using External Event Loops, Up: Run Control
6464
6465 7.8.1 Waiting For Completion
6466 ----------------------------
6467
6468 -- Function: gpgme_ctx_t gpgme_wait (gpgme_ctx_t CTX,
6469 gpgme_error_t *STATUS, int HANG)
6470 The function ‘gpgme_wait’ continues the pending operation within
6471 the context CTX. In particular, it ensures the data exchange
6472 between GPGME and the crypto backend and watches over the run time
6473 status of the backend process.
6474
6475 If HANG is true, the function does not return until the operation
6476 is completed or cancelled. Otherwise the function will not block
6477 for a long time.
6478
6479 The error status of the finished operation is returned in STATUS if
6480 ‘gpgme_wait’ does not return ‘NULL’.
6481
6482 The CTX argument can be ‘NULL’. In that case, ‘gpgme_wait’ waits
6483 for any context to complete its operation.
6484
6485 ‘gpgme_wait’ can be used only in conjunction with any context that
6486 has a pending operation initiated with one of the
6487 ‘gpgme_op_*_start’ functions except ‘gpgme_op_keylist_start’ and
6488 ‘gpgme_op_trustlist_start’ (for which you should use the
6489 corresponding ‘gpgme_op_*_next’ functions). If CTX is ‘NULL’, all
6490 of such contexts are waited upon and possibly returned.
6491 Synchronous operations running in parallel, as well as key and
6492 trust item list operations, do not affect ‘gpgme_wait’.
6493
6494 In a multi-threaded environment, only one thread should ever call
6495 ‘gpgme_wait’ at any time, regardless of whether CTX is specified or
6496 not. This means that all calls to this function should be fully
6497 synchronized by locking primitives. It is safe to start
6498 asynchronous operations while a thread is running in ‘gpgme_wait’.
6499
6500 The function returns the CTX of the context which has finished the
6501 operation. If HANG is false, and the timeout expires, ‘NULL’ is
6502 returned and ‘*status’ will be set to 0. If an error occurs,
6503 ‘NULL’ is returned and the error is returned in ‘*status’.
6504
6505 
6506 File: gpgme.info, Node: Using External Event Loops, Next: Cancellation, Prev: Waiting For Completion, Up: Run Control
6507
6508 7.8.2 Using External Event Loops
6509 --------------------------------
6510
6511 GPGME hides the complexity of the communication between the library and
6512 the crypto engine. The price of this convenience is that the calling
6513 thread can block arbitrary long waiting for the data returned by the
6514 crypto engine. In single-threaded programs, in particular if they are
6515 interactive, this is an unwanted side-effect. OTOH, if ‘gpgme_wait’ is
6516 used without the HANG option being enabled, it might be called
6517 unnecessarily often, wasting CPU time that could be used otherwise.
6518
6519 The I/O callback interface described in this section lets the user
6520 take control over what happens when. GPGME will provide the user with
6521 the file descriptors that should be monitored, and the callback
6522 functions that should be invoked when a file descriptor is ready for
6523 reading or writing. It is then the user’s responsibility to decide when
6524 to check the file descriptors and when to invoke the callback functions.
6525 Usually this is done in an event loop, that also checks for events in
6526 other parts of the program. If the callback functions are only called
6527 when the file descriptors are ready, GPGME will never block. This gives
6528 the user more control over the program flow, and allows to perform other
6529 tasks when GPGME would block otherwise.
6530
6531 By using this advanced mechanism, GPGME can be integrated smoothly
6532 into GUI toolkits like GTK+ even for single-threaded programs.
6533
6534 * Menu:
6535
6536 * I/O Callback Interface:: How I/O callbacks are registered.
6537 * Registering I/O Callbacks:: How to use I/O callbacks for a context.
6538 * I/O Callback Example:: An example how to use I/O callbacks.
6539 * I/O Callback Example GTK+:: How to use GPGME with GTK+.
6540 * I/O Callback Example GDK:: How to use GPGME with GDK.
6541 * I/O Callback Example Qt:: How to use GPGME with Qt.
6542
6543 
6544 File: gpgme.info, Node: I/O Callback Interface, Next: Registering I/O Callbacks, Up: Using External Event Loops
6545
6546 7.8.2.1 I/O Callback Interface
6547 ..............................
6548
6549 -- Data type: gpgme_error_t (*gpgme_io_cb_t) (void *DATA, int FD)
6550 The ‘gpgme_io_cb_t’ type is the type of functions which GPGME wants
6551 to register as I/O callback handlers using the
6552 ‘gpgme_register_io_cb_t’ functions provided by the user.
6553
6554 DATA and FD are provided by GPGME when the I/O callback handler is
6555 registered, and should be passed through to the handler when it is
6556 invoked by the user because it noticed activity on the file
6557 descriptor FD.
6558
6559 The callback handler always returns ‘0’, but you should consider
6560 the return value to be reserved for later use.
6561
6562 -- Data type: gpgme_error_t (*gpgme_register_io_cb_t) (void *DATA,
6563 int FD, int DIR, gpgme_io_cb_t FNC, void *FNC_DATA,
6564 void **TAG)
6565 The ‘gpgme_register_io_cb_t’ type is the type of functions which
6566 can be called by GPGME to register an I/O callback function FNC for
6567 the file descriptor FD with the user. FNC_DATA should be passed as
6568 the first argument to FNC when the handler is invoked (the second
6569 argument should be FD). If DIR is 0, FNC should be called by the
6570 user when FD is ready for writing. If DIR is 1, FNC should be
6571 called when FD is ready for reading.
6572
6573 DATA was provided by the user when registering the
6574 ‘gpgme_register_io_cb_t’ function with GPGME and will always be
6575 passed as the first argument when registering a callback function.
6576 For example, the user can use this to determine the event loop to
6577 which the file descriptor should be added.
6578
6579 GPGME will call this function when a crypto operation is initiated
6580 in a context for which the user has registered I/O callback handler
6581 functions with ‘gpgme_set_io_cbs’. It can also call this function
6582 when it is in an I/O callback handler for a file descriptor
6583 associated to this context.
6584
6585 The user should return a unique handle in TAG identifying this I/O
6586 callback registration, which will be passed to the
6587 ‘gpgme_register_io_cb_t’ function without interpretation when the
6588 file descriptor should not be monitored anymore.
6589
6590 -- Data type: void (*gpgme_remove_io_cb_t) (void *TAG)
6591 The ‘gpgme_remove_io_cb_t’ type is the type of functions which can
6592 be called by GPGME to remove an I/O callback handler that was
6593 registered before. TAG is the handle that was returned by the
6594 ‘gpgme_register_io_cb_t’ for this I/O callback.
6595
6596 GPGME can call this function when a crypto operation is in an I/O
6597 callback. It will also call this function when the context is
6598 destroyed while an operation is pending.
6599
6600 -- Data type: enum gpgme_event_io_t
6601 The ‘gpgme_event_io_t’ type specifies the type of an event that is
6602 reported to the user by GPGME as a consequence of an I/O operation.
6603 The following events are defined:
6604
6605 ‘GPGME_EVENT_START’
6606 The operation is fully initialized now, and you can start to
6607 run the registered I/O callback handlers now. Note that
6608 registered I/O callback handlers must not be run before this
6609 event is signalled. TYPE_DATA is ‘NULL’ and reserved for
6610 later use.
6611
6612 ‘GPGME_EVENT_DONE’
6613 The operation is finished, the last I/O callback for this
6614 operation was removed. The accompanying TYPE_DATA points to a
6615 ‘struct gpgme_io_event_done_data’ variable that contains the
6616 status of the operation that finished. This event is
6617 signalled after the last I/O callback has been removed.
6618
6619 ‘GPGME_EVENT_NEXT_KEY’
6620 In a ‘gpgme_op_keylist_start’ operation, the next key was
6621 received from the crypto engine. The accompanying TYPE_DATA
6622 is a ‘gpgme_key_t’ variable that contains the key with one
6623 reference for the user.
6624
6625 -- Data type: void (*gpgme_event_io_cb_t) (void *DATA,
6626 gpgme_event_io_t TYPE, void *TYPE_DATA)
6627 The ‘gpgme_event_io_cb_t’ type is the type of functions which can
6628 be called by GPGME to signal an event for an operation running in a
6629 context which has I/O callback functions registered by the user.
6630
6631 DATA was provided by the user when registering the
6632 ‘gpgme_event_io_cb_t’ function with GPGME and will always be passed
6633 as the first argument when registering a callback function. For
6634 example, the user can use this to determine the context in which
6635 this event has occurred.
6636
6637 TYPE will specify the type of event that has occurred. TYPE_DATA
6638 specifies the event further, as described in the above list of
6639 possible ‘gpgme_event_io_t’ types.
6640
6641 GPGME can call this function in an I/O callback handler.
6642
6643 
6644 File: gpgme.info, Node: Registering I/O Callbacks, Next: I/O Callback Example, Prev: I/O Callback Interface, Up: Using External Event Loops
6645
6646 7.8.2.2 Registering I/O Callbacks
6647 .................................
6648
6649 -- Data type: struct gpgme_io_cbs
6650 This structure is used to store the I/O callback interface
6651 functions described in the previous section. It has the following
6652 members:
6653
6654 ‘gpgme_register_io_cb_t add’
6655 This is the function called by GPGME to register an I/O
6656 callback handler. It must be specified.
6657
6658 ‘void *add_priv’
6659 This is passed as the first argument to the ‘add’ function
6660 when it is called by GPGME. For example, it can be used to
6661 determine the event loop to which the file descriptor should
6662 be added.
6663
6664 ‘gpgme_remove_io_cb_t remove’
6665 This is the function called by GPGME to remove an I/O callback
6666 handler. It must be specified.
6667
6668 ‘gpgme_event_io_cb_t event’
6669 This is the function called by GPGME to signal an event for an
6670 operation. It must be specified, because at least the start
6671 event must be processed.
6672
6673 ‘void *event_priv’
6674 This is passed as the first argument to the ‘event’ function
6675 when it is called by GPGME. For example, it can be used to
6676 determine the context in which the event has occurred.
6677
6678 -- Function: void gpgme_set_io_cbs (gpgme_ctx_t CTX,
6679 struct gpgme_io_cbs *IO_CBS)
6680 The function ‘gpgme_set_io_cbs’ enables the I/O callback interface
6681 for the context CTX. The I/O callback functions are specified by
6682 IO_CBS.
6683
6684 If IO_CBS->‘add’ is ‘NULL’, the I/O callback interface is disabled
6685 for the context, and normal operation is restored.
6686
6687 -- Function: void gpgme_get_io_cbs (gpgme_ctx_t CTX,
6688 struct gpgme_io_cbs *IO_CBS)
6689 The function ‘gpgme_get_io_cbs’ returns the I/O callback functions
6690 set with ‘gpgme_set_io_cbs’ in IO_CBS.
6691
6692 
6693 File: gpgme.info, Node: I/O Callback Example, Next: I/O Callback Example GTK+, Prev: Registering I/O Callbacks, Up: Using External Event Loops
6694
6695 7.8.2.3 I/O Callback Example
6696 ............................
6697
6698 To actually use an external event loop, you have to implement the I/O
6699 callback functions that are used by GPGME to register and unregister
6700 file descriptors. Furthermore, you have to actually monitor these file
6701 descriptors for activity and call the appropriate I/O callbacks.
6702
6703 The following example illustrates how to do that. The example uses
6704 locking to show in which way the callbacks and the event loop can run
6705 concurrently. For the event loop, we use a fixed array. For a
6706 real-world implementation, you should use a dynamically sized structure
6707 because the number of file descriptors needed for a crypto operation in
6708 GPGME is not predictable.
6709
6710 #include <assert.h>
6711 #include <errno.h>
6712 #include <stdlib.h>
6713 #include <pthread.h>
6714 #include <sys/types.h>
6715 #include <gpgme.h>
6716
6717 /* The following structure holds the result of a crypto operation. */
6718 struct op_result
6719 {
6720 int done;
6721 gpgme_error_t err;
6722 };
6723
6724 /* The following structure holds the data associated with one I/O
6725 callback. */
6726 struct one_fd
6727 {
6728 int fd;
6729 int dir;
6730 gpgme_io_cb_t fnc;
6731 void *fnc_data;
6732 void *loop;
6733 };
6734
6735 struct event_loop
6736 {
6737 pthread_mutex_t lock;
6738 #define MAX_FDS 32
6739 /* Unused slots are marked with FD being -1. */
6740 struct one_fd fds[MAX_FDS];
6741 };
6742
6743 The following functions implement the I/O callback interface.
6744
6745 gpgme_error_t
6746 add_io_cb (void *data, int fd, int dir, gpgme_io_cb_t fnc, void *fnc_data,
6747 void **r_tag)
6748 {
6749 struct event_loop *loop = data;
6750 struct one_fd *fds = loop->fds;
6751 int i;
6752
6753 pthread_mutex_lock (&loop->lock);
6754 for (i = 0; i < MAX_FDS; i++)
6755 {
6756 if (fds[i].fd == -1)
6757 {
6758 fds[i].fd = fd;
6759 fds[i].dir = dir;
6760 fds[i].fnc = fnc;
6761 fds[i].fnc_data = fnc_data;
6762 fds[i].loop = loop;
6763 break;
6764 }
6765 }
6766 pthread_mutex_unlock (&loop->lock);
6767 if (i == MAX_FDS)
6768 return gpg_error (GPG_ERR_GENERAL);
6769 *r_tag = &fds[i];
6770 return 0;
6771 }
6772
6773 void
6774 remove_io_cb (void *tag)
6775 {
6776 struct one_fd *fd = tag;
6777 struct event_loop *loop = fd->loop;
6778
6779 pthread_mutex_lock (&loop->lock);
6780 fd->fd = -1;
6781 pthread_mutex_unlock (&loop->lock);
6782 }
6783
6784 void
6785 event_io_cb (void *data, gpgme_event_io_t type, void *type_data)
6786 {
6787 struct op_result *result = data;
6788
6789 /* We don't support list operations here. */
6790 if (type == GPGME_EVENT_DONE)
6791 {
6792 result->done = 1;
6793 result->err = *type_data;
6794 }
6795 }
6796
6797 The final missing piece is the event loop, which will be presented
6798 next. We only support waiting for the success of a single operation.
6799
6800 int
6801 do_select (struct event_loop *loop)
6802 {
6803 fd_set rfds;
6804 fd_set wfds;
6805 int i, n;
6806 int any = 0;
6807 struct timeval tv;
6808 struct one_fd *fdlist = loop->fds;
6809
6810 pthread_mutex_lock (&loop->lock);
6811 FD_ZERO (&rfds);
6812 FD_ZERO (&wfds);
6813 for (i = 0; i < MAX_FDS; i++)
6814 if (fdlist[i].fd != -1)
6815 FD_SET (fdlist[i].fd, fdlist[i].dir ? &rfds : &wfds);
6816 pthread_mutex_unlock (&loop->lock);
6817
6818 tv.tv_sec = 0;
6819 tv.tv_usec = 1000;
6820
6821 do
6822 {
6823 n = select (FD_SETSIZE, &rfds, &wfds, NULL, &tv);
6824 }
6825 while (n < 0 && errno == EINTR);
6826
6827 if (n < 0)
6828 return n; /* Error or timeout. */
6829
6830 pthread_mutex_lock (&loop->lock);
6831 for (i = 0; i < MAX_FDS && n; i++)
6832 {
6833 if (fdlist[i].fd != -1)
6834 {
6835 if (FD_ISSET (fdlist[i].fd, fdlist[i].dir ? &rfds : &wfds))
6836 {
6837 assert (n);
6838 n--;
6839 any = 1;
6840 /* The I/O callback handler can register/remove callbacks,
6841 so we have to unlock the file descriptor list. */
6842 pthread_mutex_unlock (&loop->lock);
6843 (*fdlist[i].fnc) (fdlist[i].fnc_data, fdlist[i].fd);
6844 pthread_mutex_lock (&loop->lock);
6845 }
6846 }
6847 }
6848 pthread_mutex_unlock (&loop->lock);
6849 return any;
6850 }
6851
6852 void
6853 wait_for_op (struct event_loop *loop, struct op_result *result)
6854 {
6855 int ret;
6856
6857 do
6858 {
6859 ret = do_select (loop);
6860 }
6861 while (ret >= 0 && !result->done);
6862 }
6863
6864 The main function shows how to put it all together.
6865
6866 int
6867 main (int argc, char *argv[])
6868 {
6869 struct event_loop loop;
6870 struct op_result result;
6871 gpgme_ctx_t ctx;
6872 gpgme_error_t err;
6873 gpgme_data_t sig, text;
6874 int i;
6875 pthread_mutexattr_t attr;
6876 struct gpgme_io_cbs io_cbs =
6877 {
6878 add_io_cb,
6879 &loop,
6880 remove_io_cb,
6881 event_io_cb,
6882 &result
6883 };
6884
6885 init_gpgme ();
6886
6887 /* Initialize the loop structure. */
6888
6889 /* The mutex must be recursive, since remove_io_cb (which acquires a
6890 lock) can be called while holding a lock acquired in do_select. */
6891 pthread_mutexattr_init (&attr);
6892 pthread_mutexattr_settype (&attr, PTHREAD_MUTEX_RECURSIVE);
6893 pthread_mutex_init (&loop.lock, &attr);
6894 pthread_mutexattr_destroy (&attr);
6895
6896 for (i = 0; i < MAX_FDS; i++)
6897 loop.fds[i].fd = -1;
6898
6899 /* Initialize the result structure. */
6900 result.done = 0;
6901
6902 err = gpgme_data_new_from_file (&sig, "signature", 1);
6903 if (!err)
6904 err = gpgme_data_new_from_file (&text, "text", 1);
6905 if (!err)
6906 err = gpgme_new (&ctx);
6907 if (!err)
6908 {
6909 gpgme_set_io_cbs (ctx, &io_cbs);
6910 err = gpgme_op_verify_start (ctx, sig, text, NULL);
6911 }
6912 if (err)
6913 {
6914 fprintf (stderr, "gpgme error: %s: %s\n",
6915 gpgme_strsource (err), gpgme_strerror (err));
6916 exit (1);
6917 }
6918
6919 wait_for_op (&loop, &result);
6920 if (!result.done)
6921 {
6922 fprintf (stderr, "select error\n");
6923 exit (1);
6924 }
6925 if (!result.err)
6926 {
6927 fprintf (stderr, "verification failed: %s: %s\n",
6928 gpgme_strsource (result.err), gpgme_strerror (result.err));
6929 exit (1);
6930 }
6931 /* Evaluate verify result. */
6932 ...
6933 return 0;
6934 }
6935
6936 
6937 File: gpgme.info, Node: I/O Callback Example GTK+, Next: I/O Callback Example GDK, Prev: I/O Callback Example, Up: Using External Event Loops
6938
6939 7.8.2.4 I/O Callback Example GTK+
6940 .................................
6941
6942 The I/O callback interface can be used to integrate GPGME with the GTK+
6943 event loop. The following code snippets shows how this can be done
6944 using the appropriate register and remove I/O callback functions. In
6945 this example, the private data of the register I/O callback function is
6946 unused. The event notifications is missing because it does not require
6947 any GTK+ specific setup.
6948
6949 #include <gtk/gtk.h>
6950
6951 struct my_gpgme_io_cb
6952 {
6953 gpgme_io_cb_t fnc;
6954 void *fnc_data;
6955 guint input_handler_id
6956 };
6957
6958 void
6959 my_gpgme_io_cb (gpointer data, gint source, GdkInputCondition condition)
6960 {
6961 struct my_gpgme_io_cb *iocb = data;
6962 (*(iocb->fnc)) (iocb->data, source);
6963 }
6964
6965 void
6966 my_gpgme_remove_io_cb (void *data)
6967 {
6968 struct my_gpgme_io_cb *iocb = data;
6969 gtk_input_remove (data->input_handler_id);
6970 }
6971
6972 void
6973 my_gpgme_register_io_callback (void *data, int fd, int dir, gpgme_io_cb_t fnc,
6974 void *fnc_data, void **tag)
6975 {
6976 struct my_gpgme_io_cb *iocb = g_malloc (sizeof (struct my_gpgme_io_cb));
6977 iocb->fnc = fnc;
6978 iocb->data = fnc_data;
6979 iocb->input_handler_id = gtk_input_add_full (fd, dir
6980 ? GDK_INPUT_READ
6981 : GDK_INPUT_WRITE,
6982 my_gpgme_io_callback,
6983 0, iocb, NULL);
6984 *tag = iocb;
6985 return 0;
6986 }
6987
6988 
6989 File: gpgme.info, Node: I/O Callback Example GDK, Next: I/O Callback Example Qt, Prev: I/O Callback Example GTK+, Up: Using External Event Loops
6990
6991 7.8.2.5 I/O Callback Example GDK
6992 ................................
6993
6994 The I/O callback interface can also be used to integrate GPGME with the
6995 GDK event loop. The following code snippets shows how this can be done
6996 using the appropriate register and remove I/O callback functions. In
6997 this example, the private data of the register I/O callback function is
6998 unused. The event notifications is missing because it does not require
6999 any GDK specific setup.
7000
7001 It is very similar to the GTK+ example in the previous section.
7002
7003 #include <gdk/gdk.h>
7004
7005 struct my_gpgme_io_cb
7006 {
7007 gpgme_io_cb_t fnc;
7008 void *fnc_data;
7009 gint tag;
7010 };
7011
7012 void
7013 my_gpgme_io_cb (gpointer data, gint source, GdkInputCondition condition)
7014 {
7015 struct my_gpgme_io_cb *iocb = data;
7016 (*(iocb->fnc)) (iocb->data, source);
7017 }
7018
7019 void
7020 my_gpgme_remove_io_cb (void *data)
7021 {
7022 struct my_gpgme_io_cb *iocb = data;
7023 gdk_input_remove (data->tag);
7024 }
7025
7026 void
7027 my_gpgme_register_io_callback (void *data, int fd, int dir, gpgme_io_cb_t fnc,
7028 void *fnc_data, void **tag)
7029 {
7030 struct my_gpgme_io_cb *iocb = g_malloc (sizeof (struct my_gpgme_io_cb));
7031 iocb->fnc = fnc;
7032 iocb->data = fnc_data;
7033 iocb->tag = gtk_input_add_full (fd, dir ? GDK_INPUT_READ : GDK_INPUT_WRITE,
7034 my_gpgme_io_callback, iocb, NULL);
7035 *tag = iocb;
7036 return 0;
7037 }
7038
7039 
7040 File: gpgme.info, Node: I/O Callback Example Qt, Prev: I/O Callback Example GDK, Up: Using External Event Loops
7041
7042 7.8.2.6 I/O Callback Example Qt
7043 ...............................
7044
7045 The I/O callback interface can also be used to integrate GPGME with the
7046 Qt event loop. The following code snippets show how this can be done
7047 using the appropriate register and remove I/O callback functions. In
7048 this example, the private data of the register I/O callback function is
7049 unused. The event notifications is missing because it does not require
7050 any Qt specific setup.
7051
7052 #include <qsocketnotifier.h>
7053 #include <qapplication.h>
7054
7055 struct IOCB {
7056 IOCB( GpgmeIOCb f, void * d, QSocketNotifier * n )
7057 : func( f ), data( d ), notifier( n ) {}
7058 GpgmeIOCb func;
7059 void * data;
7060 QSocketNotifier * notifier;
7061 }
7062
7063 class MyApp : public QApplication {
7064
7065 // ...
7066
7067 static void registerGpgmeIOCallback( void * data, int fd, int dir,
7068 GpgmeIOCb func, void * func_data,
7069 void ** tag ) {
7070 QSocketNotifier * n =
7071 new QSocketNotifier( fd, dir ? QSocketNotifier::Read
7072 : QSocketNotifier::Write );
7073 connect( n, SIGNAL(activated(int)),
7074 qApp, SLOT(slotGpgmeIOCallback(int)) );
7075 qApp->mIOCBs.push_back( IOCB( func, func_data, n ) );
7076 *tag = (void*)n;
7077 }
7078
7079 static void removeGpgmeIOCallback( void * tag ) {
7080 if ( !tag ) return;
7081 QSocketNotifier * n = static_cast<QSocketNotifier*>( tag );
7082 for ( QValueList<IOCB>::iterator it = qApp->mIOCBs.begin() ;
7083 it != qApp->mIOCBs.end() ; ++it )
7084 if ( it->notifier == n ) {
7085 delete it->notifier;
7086 qApp->mIOCBs.erase( it );
7087 return;
7088 }
7089 }
7090
7091 public slots:
7092 void slotGpgmeIOCallback( int fd ) {
7093 for ( QValueList<IOCB>::const_iterator it = mIOCBs.begin() ;
7094 it != mIOCBs.end() ; ++it )
7095 if ( it->notifier && it->notifier->socket() == fd )
7096 (*(it->func)) ( it->func_data, fd );
7097 }
7098
7099 // ...
7100
7101 private:
7102 QValueList<IOCB> mIOCBs;
7103 // ...
7104 };
7105
7106 
7107 File: gpgme.info, Node: Cancellation, Prev: Using External Event Loops, Up: Run Control
7108
7109 7.8.3 Cancellation
7110 ------------------
7111
7112 Sometimes you do not want to wait for an operation to finish. GPGME
7113 provides two different functions to achieve that. The function
7114 ‘gpgme_cancel’ takes effect immediately. When it returns, the operation
7115 is effectively canceled. However, it has some limitations and can not
7116 be used with synchronous operations. In contrast, the function
7117 ‘gpgme_cancel_async’ can be used with any context and from any thread,
7118 but it is not guaranteed to take effect immediately. Instead,
7119 cancellation occurs at the next possible time (typically the next time
7120 I/O occurs in the target context).
7121
7122 -- Function: gpgme_ctx_t gpgme_cancel (gpgme_ctx_t CTX)
7123 SINCE: 0.4.5
7124
7125 The function ‘gpgme_cancel’ attempts to cancel a pending operation
7126 in the context CTX. This only works if you use the global event
7127 loop or your own event loop.
7128
7129 If you use the global event loop, you must not call ‘gpgme_wait’
7130 during cancellation. After successful cancellation, you can call
7131 ‘gpgme_wait’ (optionally waiting on CTX), and the context CTX will
7132 appear as if it had finished with the error code ‘GPG_ERR_CANCEL’.
7133
7134 If you use an external event loop, you must ensure that no I/O
7135 callbacks are invoked for this context (for example by halting the
7136 event loop). On successful cancellation, all registered I/O
7137 callbacks for this context will be unregistered, and a
7138 ‘GPGME_EVENT_DONE’ event with the error code ‘GPG_ERR_CANCEL’ will
7139 be signalled.
7140
7141 The function returns an error code if the cancellation failed (in
7142 this case the state of CTX is not modified).
7143
7144 -- Function: gpgme_ctx_t gpgme_cancel_async (gpgme_ctx_t CTX)
7145 SINCE: 1.1.7
7146
7147 The function ‘gpgme_cancel_async’ attempts to cancel a pending
7148 operation in the context CTX. This can be called by any thread at
7149 any time after starting an operation on the context, but will not
7150 take effect immediately. The actual cancellation happens at the
7151 next time GPGME processes I/O in that context.
7152
7153 The function returns an error code if the cancellation failed (in
7154 this case the state of CTX is not modified).
7155
7156 
7157 File: gpgme.info, Node: UI Server Protocol, Next: Debugging, Prev: Contexts, Up: Top
7158
7159 Appendix A The GnuPG UI Server Protocol
7160 ***************************************
7161
7162 This section specifies the protocol used between clients and a User
7163 Interface Server (UI server). This protocol helps to build a system
7164 where all cryptographic operations are done by a server and the server
7165 is responsible for all dialogs. Although GPGME has no direct support
7166 for this protocol it is believed that servers will utilize the GPGME
7167 library; thus having the specification included in this manual is an
7168 appropriate choice. This protocol should be referenced as ‘The GnuPG UI
7169 Server Protocol’.
7170
7171 A server needs to implement these commands:(1)
7172
7173 * Menu:
7174
7175 * UI Server Encrypt:: Encrypt a message.
7176 * UI Server Sign:: Sign a message.
7177 * UI Server Decrypt:: Decrypt a message.
7178 * UI Server Verify:: Verify a message.
7179 * UI Server Set Input Files:: Specifying the input files to operate on.
7180 * UI Server Sign/Encrypt Files:: Encrypting and signing files.
7181 * UI Server Verify/Decrypt Files:: Decrypting and verifying files.
7182 * UI Server Import/Export Keys:: Managing certificates.
7183 * UI Server Checksum Files:: Create and verify checksums for files.
7184 * Miscellaneous UI Server Commands:: Commands not related to a specific operation.
7185
7186 ---------- Footnotes ----------
7187
7188 (1) In all examples we assume that the connection has already been
7189 established; see the Assuan manual for details.
7190
7191 
7192 File: gpgme.info, Node: UI Server Encrypt, Next: UI Server Sign, Up: UI Server Protocol
7193
7194 A.1 UI Server: Encrypt a Message
7195 ================================
7196
7197 Before encryption can be done the recipients must be set using the
7198 command:
7199
7200 -- Command: RECIPIENT STRING
7201
7202 Set the recipient for the encryption. STRING is an RFC-2822
7203 recipient name ("mailbox" as per section 3.4). This command may or
7204 may not check the recipient for validity right away; if it does not
7205 all recipients are expected to be checked at the time of the
7206 ‘ENCRYPT’ command. All ‘RECIPIENT’ commands are cumulative until a
7207 successful ‘ENCRYPT’ command or until a ‘RESET’ command. Linefeeds
7208 are obviously not allowed in STRING and should be folded into
7209 spaces (which are equivalent).
7210
7211 To tell the server the source and destination of the data, the next two
7212 commands are to be used:
7213
7214 -- Command: INPUT FD=N
7215 Set the file descriptor for the message to be encrypted to N. The
7216 message send to the server is binary encoded.
7217
7218 GpgOL is a Windows only program, thus N is not a libc file
7219 descriptor but a regular system handle. Given that the Assuan
7220 connection works over a socket, it is not possible to use regular
7221 inheritance to make the file descriptor available to the server.
7222 Thus ‘DuplicateHandle’ needs to be used to duplicate a handle to
7223 the server process. This is the reason that the server needs to
7224 implement the ‘GETINFO pid’ command. Sending this command a second
7225 time replaces the file descriptor set by the last one.
7226
7227 -- Command: OUTPUT FD=N [--binary]
7228 Set the file descriptor to be used for the output (i.e. the
7229 encrypted message) to N. If the option ‘--binary’ is given the
7230 output shall be in binary format; if not given, the output for
7231 OpenPGP needs to be ASCII armored and for CMS Base-64 encoded. For
7232 details on the file descriptor, see the ‘INPUT’ command.
7233
7234 The setting of the recipients, the data source and destination may
7235 happen in any order, even intermixed. If this has been done the actual
7236 encryption operation is called using:
7237
7238 -- Command: ENCRYPT --protocol=NAME
7239
7240 This command reads the plaintext from the file descriptor set by
7241 the ‘INPUT’ command, encrypts it and writes the ciphertext to the
7242 file descriptor set by the ‘OUTPUT’ command. The server may (and
7243 should) overlap reading and writing. The recipients used for the
7244 encryption are all the recipients set so far. If any recipient is
7245 not usable the server should take appropriate measures to notify
7246 the user about the problem and may cancel the operation by
7247 returning an error code. The used file descriptors are void after
7248 this command; the recipient list is only cleared if the server
7249 returns success.
7250
7251 Because GpgOL uses a streaming mode of operation the server is not
7252 allowed to auto select the protocol and must obey to the mandatory
7253 PROTOCOL parameter:
7254
7255 ‘OpenPGP’
7256 Use the OpenPGP protocol (RFC-2440).
7257 ‘CMS’
7258 Use the CMS (PKCS#7) protocol (RFC-3852).
7259
7260 To support automagically selection of the protocol depending on the
7261 selected keys, the server MAY implement the command:
7262
7263 -- Command: PREP_ENCRYPT [--protocol=NAME] [--expect-sign]
7264
7265 This commands considers all recipients set so far and decides
7266 whether it is able to take input and start the actual encryption.
7267 This is kind of a dry-run ‘ENCRYPT’ without requiring or using the
7268 input and output file descriptors. The server shall cache the
7269 result of any user selection to avoid asking this again when the
7270 actual ‘ENCRYPT’ command is send. The ‘--protocol’ option is
7271 optional; if it is not given, the server should allow the user to
7272 select the protocol to be used based on the recipients given or by
7273 any other means.
7274
7275 If ‘--expect-sign’ is given the server should expect that the
7276 message will also be signed and use this hint to present a unified
7277 recipient and signer selection dialog if possible and desired. A
7278 selected signer should then be cached for the expected SIGN command
7279 (which is expected in the same session but possible on another
7280 connection).
7281
7282 If this command is given again before a successful ‘ENCRYPT’
7283 command, the second one takes effect.
7284
7285 Before sending the OK response the server shall tell the client the
7286 protocol to be used (either the one given by the argument or the
7287 one selected by the user) by means of a status line:
7288
7289 -- Status line: PROTOCOL NAME
7290 Advise the client to use the protocol NAME for the ‘ENCRYPT’
7291 command. The valid protocol names are listed under the description
7292 of the ‘ENCRYPT’ command. The server shall emit exactly one
7293 PROTOCOL status line.
7294
7295 Here is an example of a complete encryption sequence; client lines are
7296 indicated by a C:, server responses by C::
7297
7298 C: RESET
7299 S: OK
7300 C: RECIPIENT foo@example.net
7301 S: OK
7302 C: RECIPIENT bar@example.com
7303 S: OK
7304 C: PREP_ENCRYPT
7305 S: S PROTOCOL OpenPGP
7306 S: OK
7307 C: INPUT FD=17
7308 S: OK
7309 C: OUTPUT FD=18
7310 S: OK
7311 C: ENCRYPT
7312 S: OK
7313
Binary diff not shown
988988
989989 @item g13-name
990990 Return the name of the file container encryption engine.
991
992 @item keyboxd-name
993 Return the name of the key database daemon.
994
995 @item agent-name
996 Return the name of gpg-agent.
997
998 @item scdaemon-name
999 Return the name of the smart card daemon.
1000
1001 @item dirmngr-name
1002 Return the name of dirmngr.
1003
1004 @item pinentry-name
1005 Return the name of the pinentry program.
9911006
9921007 @item gpg-wks-client-name
9931008 Return the name of the Web Key Service tool.
31853200 are documented in the GnuPG manual and the gpg man page under
31863201 the option @option{--default-cert-expire}.
31873202
3203 @item "key-origin"
3204 @since{1.16.1}
3205 The string given in @var{value} is passed to the GnuPG engine to set
3206 the origin of imported keys. Valid values are documented in the GnuPG
3207 manual and the gpg man page under the option @option{--key-origin}.
3208
3209 @item "import-filter"
3210 @since{1.16.1}
3211 The string given in @var{value} is passed to the GnuPG engine to use as
3212 filter when importing keys. Valid values are documented in the GnuPG
3213 manual and the gpg man page under the option @option{--import-filter}.
31883214
31893215 @end table
31903216
36353661 The tofu info structure has the following members:
36363662
36373663 @table @code
3638 @item gpgme_key_sig_t next
3664 @item gpgme_tofu_info_t next
36393665 This is a pointer to the next tofu info structure in the linked
36403666 list, or @code{NULL} if this is the last element.
36413667
48664892 accepts just a single key; to force the export of a specific subkey
48674893 a fingerprint pattern with an appended exclamation mark may be used.
48684894
4869
48704895 @item GPGME_EXPORT_MODE_SECRET
48714896 @since{1.6.0}
48724897
48744899 may not be combined with @code{GPGME_EXPORT_MODE_EXTERN}. For X.509
48754900 the export format is PKCS#8.
48764901
4902 @item GPGME_EXPORT_MODE_SECRET_SUBKEY
4903 @since{1.17.0}
4904
4905 If this bit is set, then a secret subkey is exported. The subkey to
4906 export must be specified with fingerprint pattern with an appended
4907 exclamation mark. This is currently only allowed for OpenPGP keys.
4908 This flag may not be combined with @code{GPGME_EXPORT_MODE_EXTERN}.
4909 This flag is not supported by the export functions that take an array
4910 of keys.
4911
48774912 @item GPGME_EXPORT_MODE_RAW
48784913 @since{1.6.0}
48794914
48874922 If this flag is used with @code{GPGME_EXPORT_MODE_SECRET} for an X.509
48884923 key the export format will be changed to PKCS#12 which also includes
48894924 the certificate. This flag may not be used with OpenPGP.
4890
4891 @item GPGME_EXPORT_MODE_NOUID
4892 @since{1.12.0 - experimental}
4893 Do not export user ids. Works only with certain gpg version.
48944925
48954926 @end table
48964927
50155046
50165047 The function returns the error code @code{GPG_ERR_NO_ERROR} if the
50175048 import was completed successfully, @code{GPG_ERR_INV_VALUE} if
5018 @var{keydata} if @var{ctx} or @var{keydata} is not a valid pointer,
5049 @var{ctx} or @var{keydata} is not a valid pointer,
50195050 and @code{GPG_ERR_NO_DATA} if @var{keydata} is an empty data buffer.
50205051 @end deftypefun
50215052
50585089 The function returns the error code @code{GPG_ERR_NO_ERROR} if the
50595090 import was completed successfully, @code{GPG_ERR_INV_VALUE} if
50605091 @var{ctx} is not a valid pointer, @code{GPG_ERR_CONFLICT} if the key
5061 listing mode does not match, and @code{GPG_ERR_NO_DATA} if no keys are
5062 considered for export.
5092 listing mode does not match, and @code{GPG_ERR_NO_DATA} if no keys were
5093 considered for import.
50635094 @end deftypefun
50645095
50655096 @deftypefun gpgme_error_t gpgme_op_import_keys_start (@w{gpgme_ctx_t @var{ctx}}, @w{gpgme_key_t *@var{keys}})
50705101 @code{gpgme_wait} on the context. @xref{Waiting For Completion}.
50715102
50725103 The function returns the error code @code{GPG_ERR_NO_ERROR} if the
5104 import was started successfully, @code{GPG_ERR_INV_VALUE} if
5105 @var{ctx} is not a valid pointer, @code{GPG_ERR_CONFLICT} if the key
5106 listing mode does not match, and @code{GPG_ERR_NO_DATA} if no keys were
5107 considered for import.
5108 @end deftypefun
5109
5110 @deftypefun gpgme_error_t gpgme_op_receive_keys (@w{gpgme_ctx_t @var{ctx}}, @w{const char *@var{keyids}[]})
5111 @since{1.17.0}
5112
5113 The function @code{gpgme_op_receive_keys} adds the keys described by
5114 the @code{NULL} terminated array @var{keyids} to the key ring of the
5115 crypto engine used by @var{ctx}. It is used to retrieve and import keys
5116 from an external source. This function currently works only for OpenPGP.
5117
5118 After the operation completed successfully, the result can be
5119 retrieved with @code{gpgme_op_import_result}.
5120
5121 The function returns the error code @code{GPG_ERR_NO_ERROR} if the
50735122 import was completed successfully, @code{GPG_ERR_INV_VALUE} if
5074 @var{keydata} if @var{ctx} or @var{keydata} is not a valid pointer,
5075 @code{GPG_ERR_CONFLICT} if the key listing mode does not match, and
5076 @code{GPG_ERR_NO_DATA} if no keys are considered for export.
5123 @var{ctx} is not a valid pointer, and @code{GPG_ERR_NO_DATA} if no keys
5124 were considered for import.
5125 @end deftypefun
5126
5127 @deftypefun gpgme_error_t gpgme_op_receive_keys_start (@w{gpgme_ctx_t @var{ctx}}, @w{const char *@var{keyids}[]})
5128 @since{1.17.0}
5129
5130 The function @code{gpgme_op_receive_keys_start} initiates a
5131 @code{gpgme_op_receive_keys} operation. It can be completed by calling
5132 @code{gpgme_wait} on the context. @xref{Waiting For Completion}.
5133
5134 The function returns the error code @code{GPG_ERR_NO_ERROR} if the
5135 import was started successfully, @code{GPG_ERR_INV_VALUE} if
5136 @var{ctx} is not a valid pointer, and @code{GPG_ERR_NO_DATA} if no keys
5137 were considered for import.
50775138 @end deftypefun
50785139
50795140 @deftp {Data type} {gpgme_import_status_t}
50885149 @code{NULL} if this is the last element.
50895150
50905151 @item char *fpr
5091 This is the fingerprint of the key that was considered.
5152 This is the fingerprint of the key that was considered, or @code{NULL}
5153 if the fingerprint of the key is not known, e.g. because the key to
5154 import was encrypted and decryption failed.
50925155
50935156 @item gpgme_error_t result
50945157 If the import was not successful, this is the error value that caused
00 # This is a template. The dist target uses it to create the real file.
11 Summary: GPGME - GnuPG Made Easy
22 Name: gpgme
3 Version: 1.16.0
3 Version: 1.17.0
44 Release: 1
55 URL: https://gnupg.org/gpgme.html
66 Source: https://www.gnupg.org/ftp/gcrypt/gpgme/%{name}-%{version}.tar.gz
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for gpgme/lang.
17 # Copyright (C) 2003, 2006 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES =
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
143 ctags-recursive dvi-recursive html-recursive info-recursive \
144 install-data-recursive install-dvi-recursive \
145 install-exec-recursive install-html-recursive \
146 install-info-recursive install-pdf-recursive \
147 install-ps-recursive install-recursive installcheck-recursive \
148 installdirs-recursive pdf-recursive ps-recursive \
149 tags-recursive uninstall-recursive
150 am__can_run_installinfo = \
151 case $$AM_UPDATE_INFO_DIR in \
152 n|no|NO) false;; \
153 *) (install-info --version) >/dev/null 2>&1;; \
154 esac
155 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
156 distclean-recursive maintainer-clean-recursive
157 am__recursive_targets = \
158 $(RECURSIVE_TARGETS) \
159 $(RECURSIVE_CLEAN_TARGETS) \
160 $(am__extra_recursive_targets)
161 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
162 distdir distdir-am
163 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
164 # Read a list of newline-separated strings from the standard input,
165 # and print each of them once, without duplicates. Input order is
166 # *not* preserved.
167 am__uniquify_input = $(AWK) '\
168 BEGIN { nonempty = 0; } \
169 { items[$$0] = 1; nonempty = 1; } \
170 END { if (nonempty) { for (i in items) print i; }; } \
171 '
172 # Make sure the list of sources is unique. This is necessary because,
173 # e.g., the same source file might be shared among _SOURCES variables
174 # for different programs/libraries.
175 am__define_uniq_tagged_files = \
176 list='$(am__tagged_files)'; \
177 unique=`for i in $$list; do \
178 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
179 done | $(am__uniquify_input)`
180 ETAGS = etags
181 CTAGS = ctags
182 am__DIST_COMMON = $(srcdir)/Makefile.in \
183 $(top_srcdir)/build-aux/mkinstalldirs README
184 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
185 am__relativize = \
186 dir0=`pwd`; \
187 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
188 sed_rest='s,^[^/]*/*,,'; \
189 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
190 sed_butlast='s,/*[^/]*$$,,'; \
191 while test -n "$$dir1"; do \
192 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
193 if test "$$first" != "."; then \
194 if test "$$first" = ".."; then \
195 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
196 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
197 else \
198 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
199 if test "$$first2" = "$$first"; then \
200 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
201 else \
202 dir2="../$$dir2"; \
203 fi; \
204 dir0="$$dir0"/"$$first"; \
205 fi; \
206 fi; \
207 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
208 done; \
209 reldir="$$dir2"
210 ACLOCAL = @ACLOCAL@
211 AMTAR = @AMTAR@
212 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
213 AR = @AR@
214 AS = @AS@
215 AUTOCONF = @AUTOCONF@
216 AUTOHEADER = @AUTOHEADER@
217 AUTOMAKE = @AUTOMAKE@
218 AWK = @AWK@
219 BUILD_FILEVERSION = @BUILD_FILEVERSION@
220 BUILD_REVISION = @BUILD_REVISION@
221 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
222 BUILD_VERSION = @BUILD_VERSION@
223 CC = @CC@
224 CCDEPMODE = @CCDEPMODE@
225 CC_FOR_BUILD = @CC_FOR_BUILD@
226 CFLAGS = @CFLAGS@
227 CPP = @CPP@
228 CPPFLAGS = @CPPFLAGS@
229 CXX = @CXX@
230 CXXCPP = @CXXCPP@
231 CXXDEPMODE = @CXXDEPMODE@
232 CXXFLAGS = @CXXFLAGS@
233 CYGPATH_W = @CYGPATH_W@
234 DEFS = @DEFS@
235 DEPDIR = @DEPDIR@
236 DLLTOOL = @DLLTOOL@
237 DOXYGEN = @DOXYGEN@
238 DSYMUTIL = @DSYMUTIL@
239 DUMPBIN = @DUMPBIN@
240 ECHO_C = @ECHO_C@
241 ECHO_N = @ECHO_N@
242 ECHO_T = @ECHO_T@
243 EGREP = @EGREP@
244 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
245 EXEEXT = @EXEEXT@
246 FGREP = @FGREP@
247 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
248 GLIBC21 = @GLIBC21@
249 GLIB_CFLAGS = @GLIB_CFLAGS@
250 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
251 GLIB_LIBS = @GLIB_LIBS@
252 GLIB_MKENUMS = @GLIB_MKENUMS@
253 GOBJECT_QUERY = @GOBJECT_QUERY@
254 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
255 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
256 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
257 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
258 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
259 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
260 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
261 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
262 GPGME_QT_LIBS = @GPGME_QT_LIBS@
263 GPGRT_CONFIG = @GPGRT_CONFIG@
264 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
265 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
266 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
267 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
268 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
269 GRAPHVIZ = @GRAPHVIZ@
270 GREP = @GREP@
271 HAVE_CXX11 = @HAVE_CXX11@
272 HAVE_DOT = @HAVE_DOT@
273 INSTALL = @INSTALL@
274 INSTALL_DATA = @INSTALL_DATA@
275 INSTALL_PROGRAM = @INSTALL_PROGRAM@
276 INSTALL_SCRIPT = @INSTALL_SCRIPT@
277 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
278 LD = @LD@
279 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
280 LDFLAGS = @LDFLAGS@
281 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
282 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
283 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
284 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
285 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
286 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
287 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
288 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
289 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
290 LIBOBJS = @LIBOBJS@
291 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
292 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
293 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
294 LIBS = @LIBS@
295 LIBTOOL = @LIBTOOL@
296 LIPO = @LIPO@
297 LN_S = @LN_S@
298 LTLIBOBJS = @LTLIBOBJS@
299 MAINT = @MAINT@
300 MAKEINFO = @MAKEINFO@
301 MANIFEST_TOOL = @MANIFEST_TOOL@
302 MKDIR_P = @MKDIR_P@
303 MOC = @MOC@
304 MOC2 = @MOC2@
305 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
306 NM = @NM@
307 NMEDIT = @NMEDIT@
308 OBJDUMP = @OBJDUMP@
309 OBJEXT = @OBJEXT@
310 OTOOL = @OTOOL@
311 OTOOL64 = @OTOOL64@
312 PACKAGE = @PACKAGE@
313 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
314 PACKAGE_NAME = @PACKAGE_NAME@
315 PACKAGE_STRING = @PACKAGE_STRING@
316 PACKAGE_TARNAME = @PACKAGE_TARNAME@
317 PACKAGE_URL = @PACKAGE_URL@
318 PACKAGE_VERSION = @PACKAGE_VERSION@
319 PATH_SEPARATOR = @PATH_SEPARATOR@
320 PKG_CONFIG = @PKG_CONFIG@
321 PYTHON = @PYTHON@
322 PYTHONS = @PYTHONS@
323 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
324 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
325 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
326 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
327 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
328 PYTHON_PLATFORM = @PYTHON_PLATFORM@
329 PYTHON_PREFIX = @PYTHON_PREFIX@
330 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
331 PYTHON_VERSION = @PYTHON_VERSION@
332 QTCHOOSER = @QTCHOOSER@
333 RANLIB = @RANLIB@
334 RC = @RC@
335 SED = @SED@
336 SET_MAKE = @SET_MAKE@
337 SHELL = @SHELL@
338 STRIP = @STRIP@
339 SWIG = @SWIG@
340 SWIG_LIB = @SWIG_LIB@
341 SYSROOT = @SYSROOT@
342 VERSION = @VERSION@
343 VERSION_MAJOR = @VERSION_MAJOR@
344 VERSION_MICRO = @VERSION_MICRO@
345 VERSION_MINOR = @VERSION_MINOR@
346 VERSION_NUMBER = @VERSION_NUMBER@
347 abs_builddir = @abs_builddir@
348 abs_srcdir = @abs_srcdir@
349 abs_top_builddir = @abs_top_builddir@
350 abs_top_srcdir = @abs_top_srcdir@
351 ac_ct_AR = @ac_ct_AR@
352 ac_ct_CC = @ac_ct_CC@
353 ac_ct_CXX = @ac_ct_CXX@
354 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
355 am__include = @am__include@
356 am__leading_dot = @am__leading_dot@
357 am__quote = @am__quote@
358 am__tar = @am__tar@
359 am__untar = @am__untar@
360 bindir = @bindir@
361 build = @build@
362 build_alias = @build_alias@
363 build_cpu = @build_cpu@
364 build_os = @build_os@
365 build_vendor = @build_vendor@
366 builddir = @builddir@
367 datadir = @datadir@
368 datarootdir = @datarootdir@
369 docdir = @docdir@
370 dvidir = @dvidir@
371 emacs_local_vars_begin = @emacs_local_vars_begin@
372 emacs_local_vars_end = @emacs_local_vars_end@
373 emacs_local_vars_read_only = @emacs_local_vars_read_only@
374 exec_prefix = @exec_prefix@
375 host = @host@
376 host_alias = @host_alias@
377 host_cpu = @host_cpu@
378 host_os = @host_os@
379 host_vendor = @host_vendor@
380 htmldir = @htmldir@
381 includedir = @includedir@
382 infodir = @infodir@
383 install_sh = @install_sh@
384 libdir = @libdir@
385 libexecdir = @libexecdir@
386 localedir = @localedir@
387 localstatedir = @localstatedir@
388 mandir = @mandir@
389 mkdir_p = @mkdir_p@
390 oldincludedir = @oldincludedir@
391 pdfdir = @pdfdir@
392 pkgpyexecdir = @pkgpyexecdir@
393 pkgpythondir = @pkgpythondir@
394 prefix = @prefix@
395 program_transform_name = @program_transform_name@
396 psdir = @psdir@
397 pyexecdir = @pyexecdir@
398 pythondir = @pythondir@
399 runstatedir = @runstatedir@
400 sbindir = @sbindir@
401 sharedstatedir = @sharedstatedir@
402 srcdir = @srcdir@
403 sysconfdir = @sysconfdir@
404 target_alias = @target_alias@
405 top_build_prefix = @top_build_prefix@
406 top_builddir = @top_builddir@
407 top_srcdir = @top_srcdir@
408 SUBDIRS = $(ENABLED_LANGUAGES)
409 DIST_SUBDIRS = cl cpp qt python js
410 EXTRA_DIST = README
411 all: all-recursive
412
413 .SUFFIXES:
414 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
415 @for dep in $?; do \
416 case '$(am__configure_deps)' in \
417 *$$dep*) \
418 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
419 && { if test -f $@; then exit 0; else break; fi; }; \
420 exit 1;; \
421 esac; \
422 done; \
423 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/Makefile'; \
424 $(am__cd) $(top_srcdir) && \
425 $(AUTOMAKE) --gnu lang/Makefile
426 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
427 @case '$?' in \
428 *config.status*) \
429 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
430 *) \
431 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
432 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
433 esac;
434
435 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
436 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
437
438 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
439 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
440 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
441 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
442 $(am__aclocal_m4_deps):
443
444 mostlyclean-libtool:
445 -rm -f *.lo
446
447 clean-libtool:
448 -rm -rf .libs _libs
449
450 # This directory's subdirectories are mostly independent; you can cd
451 # into them and run 'make' without going through this Makefile.
452 # To change the values of 'make' variables: instead of editing Makefiles,
453 # (1) if the variable is set in 'config.status', edit 'config.status'
454 # (which will cause the Makefiles to be regenerated when you run 'make');
455 # (2) otherwise, pass the desired values on the 'make' command line.
456 $(am__recursive_targets):
457 @fail=; \
458 if $(am__make_keepgoing); then \
459 failcom='fail=yes'; \
460 else \
461 failcom='exit 1'; \
462 fi; \
463 dot_seen=no; \
464 target=`echo $@ | sed s/-recursive//`; \
465 case "$@" in \
466 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
467 *) list='$(SUBDIRS)' ;; \
468 esac; \
469 for subdir in $$list; do \
470 echo "Making $$target in $$subdir"; \
471 if test "$$subdir" = "."; then \
472 dot_seen=yes; \
473 local_target="$$target-am"; \
474 else \
475 local_target="$$target"; \
476 fi; \
477 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
478 || eval $$failcom; \
479 done; \
480 if test "$$dot_seen" = "no"; then \
481 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
482 fi; test -z "$$fail"
483
484 ID: $(am__tagged_files)
485 $(am__define_uniq_tagged_files); mkid -fID $$unique
486 tags: tags-recursive
487 TAGS: tags
488
489 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
490 set x; \
491 here=`pwd`; \
492 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
493 include_option=--etags-include; \
494 empty_fix=.; \
495 else \
496 include_option=--include; \
497 empty_fix=; \
498 fi; \
499 list='$(SUBDIRS)'; for subdir in $$list; do \
500 if test "$$subdir" = .; then :; else \
501 test ! -f $$subdir/TAGS || \
502 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
503 fi; \
504 done; \
505 $(am__define_uniq_tagged_files); \
506 shift; \
507 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
508 test -n "$$unique" || unique=$$empty_fix; \
509 if test $$# -gt 0; then \
510 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
511 "$$@" $$unique; \
512 else \
513 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
514 $$unique; \
515 fi; \
516 fi
517 ctags: ctags-recursive
518
519 CTAGS: ctags
520 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
521 $(am__define_uniq_tagged_files); \
522 test -z "$(CTAGS_ARGS)$$unique" \
523 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
524 $$unique
525
526 GTAGS:
527 here=`$(am__cd) $(top_builddir) && pwd` \
528 && $(am__cd) $(top_srcdir) \
529 && gtags -i $(GTAGS_ARGS) "$$here"
530 cscopelist: cscopelist-recursive
531
532 cscopelist-am: $(am__tagged_files)
533 list='$(am__tagged_files)'; \
534 case "$(srcdir)" in \
535 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
536 *) sdir=$(subdir)/$(srcdir) ;; \
537 esac; \
538 for i in $$list; do \
539 if test -f "$$i"; then \
540 echo "$(subdir)/$$i"; \
541 else \
542 echo "$$sdir/$$i"; \
543 fi; \
544 done >> $(top_builddir)/cscope.files
545
546 distclean-tags:
547 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
548
549 distdir: $(BUILT_SOURCES)
550 $(MAKE) $(AM_MAKEFLAGS) distdir-am
551
552 distdir-am: $(DISTFILES)
553 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
554 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
555 list='$(DISTFILES)'; \
556 dist_files=`for file in $$list; do echo $$file; done | \
557 sed -e "s|^$$srcdirstrip/||;t" \
558 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
559 case $$dist_files in \
560 */*) $(MKDIR_P) `echo "$$dist_files" | \
561 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
562 sort -u` ;; \
563 esac; \
564 for file in $$dist_files; do \
565 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
566 if test -d $$d/$$file; then \
567 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
568 if test -d "$(distdir)/$$file"; then \
569 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
570 fi; \
571 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
572 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
573 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
574 fi; \
575 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
576 else \
577 test -f "$(distdir)/$$file" \
578 || cp -p $$d/$$file "$(distdir)/$$file" \
579 || exit 1; \
580 fi; \
581 done
582 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
583 if test "$$subdir" = .; then :; else \
584 $(am__make_dryrun) \
585 || test -d "$(distdir)/$$subdir" \
586 || $(MKDIR_P) "$(distdir)/$$subdir" \
587 || exit 1; \
588 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
589 $(am__relativize); \
590 new_distdir=$$reldir; \
591 dir1=$$subdir; dir2="$(top_distdir)"; \
592 $(am__relativize); \
593 new_top_distdir=$$reldir; \
594 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
595 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
596 ($(am__cd) $$subdir && \
597 $(MAKE) $(AM_MAKEFLAGS) \
598 top_distdir="$$new_top_distdir" \
599 distdir="$$new_distdir" \
600 am__remove_distdir=: \
601 am__skip_length_check=: \
602 am__skip_mode_fix=: \
603 distdir) \
604 || exit 1; \
605 fi; \
606 done
607 check-am: all-am
608 check: check-recursive
609 all-am: Makefile
610 installdirs: installdirs-recursive
611 installdirs-am:
612 install: install-recursive
613 install-exec: install-exec-recursive
614 install-data: install-data-recursive
615 uninstall: uninstall-recursive
616
617 install-am: all-am
618 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
619
620 installcheck: installcheck-recursive
621 install-strip:
622 if test -z '$(STRIP)'; then \
623 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
624 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
625 install; \
626 else \
627 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
628 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
629 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
630 fi
631 mostlyclean-generic:
632
633 clean-generic:
634
635 distclean-generic:
636 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
637 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
638
639 maintainer-clean-generic:
640 @echo "This command is intended for maintainers to use"
641 @echo "it deletes files that may require special tools to rebuild."
642 clean: clean-recursive
643
644 clean-am: clean-generic clean-libtool mostlyclean-am
645
646 distclean: distclean-recursive
647 -rm -f Makefile
648 distclean-am: clean-am distclean-generic distclean-tags
649
650 dvi: dvi-recursive
651
652 dvi-am:
653
654 html: html-recursive
655
656 html-am:
657
658 info: info-recursive
659
660 info-am:
661
662 install-data-am:
663
664 install-dvi: install-dvi-recursive
665
666 install-dvi-am:
667
668 install-exec-am:
669
670 install-html: install-html-recursive
671
672 install-html-am:
673
674 install-info: install-info-recursive
675
676 install-info-am:
677
678 install-man:
679
680 install-pdf: install-pdf-recursive
681
682 install-pdf-am:
683
684 install-ps: install-ps-recursive
685
686 install-ps-am:
687
688 installcheck-am:
689
690 maintainer-clean: maintainer-clean-recursive
691 -rm -f Makefile
692 maintainer-clean-am: distclean-am maintainer-clean-generic
693
694 mostlyclean: mostlyclean-recursive
695
696 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
697
698 pdf: pdf-recursive
699
700 pdf-am:
701
702 ps: ps-recursive
703
704 ps-am:
705
706 uninstall-am:
707
708 .MAKE: $(am__recursive_targets) install-am install-strip
709
710 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
711 check-am clean clean-generic clean-libtool cscopelist-am ctags \
712 ctags-am distclean distclean-generic distclean-libtool \
713 distclean-tags distdir dvi dvi-am html html-am info info-am \
714 install install-am install-data install-data-am install-dvi \
715 install-dvi-am install-exec install-exec-am install-html \
716 install-html-am install-info install-info-am install-man \
717 install-pdf install-pdf-am install-ps install-ps-am \
718 install-strip installcheck installcheck-am installdirs \
719 installdirs-am maintainer-clean maintainer-clean-generic \
720 mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
721 ps ps-am tags tags-am uninstall uninstall-am
722
723 .PRECIOUS: Makefile
724
725
726 # Tell versions [3.59,3.63) of GNU make to not export all variables.
727 # Otherwise a system limit (for SysV at least) may be exceeded.
728 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for GPGME-CL.
17 # Copyright (C) 2003, 2006 g10 Code GmbH
18 #
19 # This file is part of GPGME-CL.
20 #
21 # GPGME-CL is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU General Public License as published by
23 # the Free Software Foundation; either version 2 of the License, or
24 # (at your option) any later version.
25 #
26 # GPGME-CL is distributed in the hope that it will be useful,
27 # but WITHOUT ANY WARRANTY; without even the implied warranty of
28 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29 # GNU Lesser General Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = lang/cl
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(dist_clfiles_DATA) \
125 $(am__DIST_COMMON)
126 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
127 CONFIG_HEADER = $(top_builddir)/conf/config.h
128 CONFIG_CLEAN_FILES = gpgme.asd
129 CONFIG_CLEAN_VPATH_FILES =
130 AM_V_P = $(am__v_P_@AM_V@)
131 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
132 am__v_P_0 = false
133 am__v_P_1 = :
134 AM_V_GEN = $(am__v_GEN_@AM_V@)
135 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
136 am__v_GEN_0 = @echo " GEN " $@;
137 am__v_GEN_1 =
138 AM_V_at = $(am__v_at_@AM_V@)
139 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
140 am__v_at_0 = @
141 am__v_at_1 =
142 SOURCES =
143 DIST_SOURCES =
144 am__can_run_installinfo = \
145 case $$AM_UPDATE_INFO_DIR in \
146 n|no|NO) false;; \
147 *) (install-info --version) >/dev/null 2>&1;; \
148 esac
149 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
150 am__vpath_adj = case $$p in \
151 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
152 *) f=$$p;; \
153 esac;
154 am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
155 am__install_max = 40
156 am__nobase_strip_setup = \
157 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
158 am__nobase_strip = \
159 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
160 am__nobase_list = $(am__nobase_strip_setup); \
161 for p in $$list; do echo "$$p $$p"; done | \
162 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
163 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
164 if (++n[$$2] == $(am__install_max)) \
165 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
166 END { for (dir in files) print dir, files[dir] }'
167 am__base_list = \
168 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
169 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
170 am__uninstall_files_from_dir = { \
171 test -z "$$files" \
172 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
173 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
174 $(am__cd) "$$dir" && rm -f $$files; }; \
175 }
176 am__installdirs = "$(DESTDIR)$(clfilesdir)"
177 DATA = $(dist_clfiles_DATA)
178 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
179 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/gpgme.asd.in \
180 $(top_srcdir)/build-aux/mkinstalldirs README
181 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
182 ACLOCAL = @ACLOCAL@
183 AMTAR = @AMTAR@
184 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
185 AR = @AR@
186 AS = @AS@
187 AUTOCONF = @AUTOCONF@
188 AUTOHEADER = @AUTOHEADER@
189 AUTOMAKE = @AUTOMAKE@
190 AWK = @AWK@
191 BUILD_FILEVERSION = @BUILD_FILEVERSION@
192 BUILD_REVISION = @BUILD_REVISION@
193 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
194 BUILD_VERSION = @BUILD_VERSION@
195 CC = @CC@
196 CCDEPMODE = @CCDEPMODE@
197 CC_FOR_BUILD = @CC_FOR_BUILD@
198 CFLAGS = @CFLAGS@
199 CPP = @CPP@
200 CPPFLAGS = @CPPFLAGS@
201 CXX = @CXX@
202 CXXCPP = @CXXCPP@
203 CXXDEPMODE = @CXXDEPMODE@
204 CXXFLAGS = @CXXFLAGS@
205 CYGPATH_W = @CYGPATH_W@
206 DEFS = @DEFS@
207 DEPDIR = @DEPDIR@
208 DLLTOOL = @DLLTOOL@
209 DOXYGEN = @DOXYGEN@
210 DSYMUTIL = @DSYMUTIL@
211 DUMPBIN = @DUMPBIN@
212 ECHO_C = @ECHO_C@
213 ECHO_N = @ECHO_N@
214 ECHO_T = @ECHO_T@
215 EGREP = @EGREP@
216 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
217 EXEEXT = @EXEEXT@
218 FGREP = @FGREP@
219 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
220 GLIBC21 = @GLIBC21@
221 GLIB_CFLAGS = @GLIB_CFLAGS@
222 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
223 GLIB_LIBS = @GLIB_LIBS@
224 GLIB_MKENUMS = @GLIB_MKENUMS@
225 GOBJECT_QUERY = @GOBJECT_QUERY@
226 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
227 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
228 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
229 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
230 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
231 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
232 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
233 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
234 GPGME_QT_LIBS = @GPGME_QT_LIBS@
235 GPGRT_CONFIG = @GPGRT_CONFIG@
236 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
237 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
238 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
239 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
240 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
241 GRAPHVIZ = @GRAPHVIZ@
242 GREP = @GREP@
243 HAVE_CXX11 = @HAVE_CXX11@
244 HAVE_DOT = @HAVE_DOT@
245 INSTALL = @INSTALL@
246 INSTALL_DATA = @INSTALL_DATA@
247 INSTALL_PROGRAM = @INSTALL_PROGRAM@
248 INSTALL_SCRIPT = @INSTALL_SCRIPT@
249 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
250 LD = @LD@
251 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
252 LDFLAGS = @LDFLAGS@
253 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
254 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
255 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
256 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
257 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
258 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
259 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
260 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
261 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
262 LIBOBJS = @LIBOBJS@
263 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
264 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
265 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
266 LIBS = @LIBS@
267 LIBTOOL = @LIBTOOL@
268 LIPO = @LIPO@
269 LN_S = @LN_S@
270 LTLIBOBJS = @LTLIBOBJS@
271 MAINT = @MAINT@
272 MAKEINFO = @MAKEINFO@
273 MANIFEST_TOOL = @MANIFEST_TOOL@
274 MKDIR_P = @MKDIR_P@
275 MOC = @MOC@
276 MOC2 = @MOC2@
277 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
278 NM = @NM@
279 NMEDIT = @NMEDIT@
280 OBJDUMP = @OBJDUMP@
281 OBJEXT = @OBJEXT@
282 OTOOL = @OTOOL@
283 OTOOL64 = @OTOOL64@
284 PACKAGE = @PACKAGE@
285 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
286 PACKAGE_NAME = @PACKAGE_NAME@
287 PACKAGE_STRING = @PACKAGE_STRING@
288 PACKAGE_TARNAME = @PACKAGE_TARNAME@
289 PACKAGE_URL = @PACKAGE_URL@
290 PACKAGE_VERSION = @PACKAGE_VERSION@
291 PATH_SEPARATOR = @PATH_SEPARATOR@
292 PKG_CONFIG = @PKG_CONFIG@
293 PYTHON = @PYTHON@
294 PYTHONS = @PYTHONS@
295 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
296 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
297 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
298 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
299 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
300 PYTHON_PLATFORM = @PYTHON_PLATFORM@
301 PYTHON_PREFIX = @PYTHON_PREFIX@
302 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
303 PYTHON_VERSION = @PYTHON_VERSION@
304 QTCHOOSER = @QTCHOOSER@
305 RANLIB = @RANLIB@
306 RC = @RC@
307 SED = @SED@
308 SET_MAKE = @SET_MAKE@
309 SHELL = @SHELL@
310 STRIP = @STRIP@
311 SWIG = @SWIG@
312 SWIG_LIB = @SWIG_LIB@
313 SYSROOT = @SYSROOT@
314 VERSION = @VERSION@
315 VERSION_MAJOR = @VERSION_MAJOR@
316 VERSION_MICRO = @VERSION_MICRO@
317 VERSION_MINOR = @VERSION_MINOR@
318 VERSION_NUMBER = @VERSION_NUMBER@
319 abs_builddir = @abs_builddir@
320 abs_srcdir = @abs_srcdir@
321 abs_top_builddir = @abs_top_builddir@
322 abs_top_srcdir = @abs_top_srcdir@
323 ac_ct_AR = @ac_ct_AR@
324 ac_ct_CC = @ac_ct_CC@
325 ac_ct_CXX = @ac_ct_CXX@
326 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
327 am__include = @am__include@
328 am__leading_dot = @am__leading_dot@
329 am__quote = @am__quote@
330 am__tar = @am__tar@
331 am__untar = @am__untar@
332 bindir = @bindir@
333 build = @build@
334 build_alias = @build_alias@
335 build_cpu = @build_cpu@
336 build_os = @build_os@
337 build_vendor = @build_vendor@
338 builddir = @builddir@
339 datadir = @datadir@
340 datarootdir = @datarootdir@
341 docdir = @docdir@
342 dvidir = @dvidir@
343 emacs_local_vars_begin = @emacs_local_vars_begin@
344 emacs_local_vars_end = @emacs_local_vars_end@
345 emacs_local_vars_read_only = @emacs_local_vars_read_only@
346 exec_prefix = @exec_prefix@
347 host = @host@
348 host_alias = @host_alias@
349 host_cpu = @host_cpu@
350 host_os = @host_os@
351 host_vendor = @host_vendor@
352 htmldir = @htmldir@
353 includedir = @includedir@
354 infodir = @infodir@
355 install_sh = @install_sh@
356 libdir = @libdir@
357 libexecdir = @libexecdir@
358 localedir = @localedir@
359 localstatedir = @localstatedir@
360 mandir = @mandir@
361 mkdir_p = @mkdir_p@
362 oldincludedir = @oldincludedir@
363 pdfdir = @pdfdir@
364 pkgpyexecdir = @pkgpyexecdir@
365 pkgpythondir = @pkgpythondir@
366 prefix = @prefix@
367 program_transform_name = @program_transform_name@
368 psdir = @psdir@
369 pyexecdir = @pyexecdir@
370 pythondir = @pythondir@
371 runstatedir = @runstatedir@
372 sbindir = @sbindir@
373 sharedstatedir = @sharedstatedir@
374 srcdir = @srcdir@
375 sysconfdir = @sysconfdir@
376 target_alias = @target_alias@
377 top_build_prefix = @top_build_prefix@
378 top_builddir = @top_builddir@
379 top_srcdir = @top_srcdir@
380 clfiles = gpgme.asd gpgme-package.lisp gpgme-grovel.lisp gpgme.lisp
381
382 # FIXME: Should be configurable.
383 clfilesdir = $(datadir)/common-lisp/source/gpgme
384 dist_clfiles_DATA = $(clfiles)
385 EXTRA_DIST = README ChangeLog-2011
386 all: all-am
387
388 .SUFFIXES:
389 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
390 @for dep in $?; do \
391 case '$(am__configure_deps)' in \
392 *$$dep*) \
393 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
394 && { if test -f $@; then exit 0; else break; fi; }; \
395 exit 1;; \
396 esac; \
397 done; \
398 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/cl/Makefile'; \
399 $(am__cd) $(top_srcdir) && \
400 $(AUTOMAKE) --gnu lang/cl/Makefile
401 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
402 @case '$?' in \
403 *config.status*) \
404 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
405 *) \
406 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
407 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
408 esac;
409
410 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
411 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
412
413 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
414 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
415 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
416 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
417 $(am__aclocal_m4_deps):
418 gpgme.asd: $(top_builddir)/config.status $(srcdir)/gpgme.asd.in
419 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
420
421 mostlyclean-libtool:
422 -rm -f *.lo
423
424 clean-libtool:
425 -rm -rf .libs _libs
426 install-dist_clfilesDATA: $(dist_clfiles_DATA)
427 @$(NORMAL_INSTALL)
428 @list='$(dist_clfiles_DATA)'; test -n "$(clfilesdir)" || list=; \
429 if test -n "$$list"; then \
430 echo " $(MKDIR_P) '$(DESTDIR)$(clfilesdir)'"; \
431 $(MKDIR_P) "$(DESTDIR)$(clfilesdir)" || exit 1; \
432 fi; \
433 for p in $$list; do \
434 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
435 echo "$$d$$p"; \
436 done | $(am__base_list) | \
437 while read files; do \
438 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(clfilesdir)'"; \
439 $(INSTALL_DATA) $$files "$(DESTDIR)$(clfilesdir)" || exit $$?; \
440 done
441
442 uninstall-dist_clfilesDATA:
443 @$(NORMAL_UNINSTALL)
444 @list='$(dist_clfiles_DATA)'; test -n "$(clfilesdir)" || list=; \
445 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
446 dir='$(DESTDIR)$(clfilesdir)'; $(am__uninstall_files_from_dir)
447 tags TAGS:
448
449 ctags CTAGS:
450
451 cscope cscopelist:
452
453
454 distdir: $(BUILT_SOURCES)
455 $(MAKE) $(AM_MAKEFLAGS) distdir-am
456
457 distdir-am: $(DISTFILES)
458 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
459 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
460 list='$(DISTFILES)'; \
461 dist_files=`for file in $$list; do echo $$file; done | \
462 sed -e "s|^$$srcdirstrip/||;t" \
463 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
464 case $$dist_files in \
465 */*) $(MKDIR_P) `echo "$$dist_files" | \
466 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
467 sort -u` ;; \
468 esac; \
469 for file in $$dist_files; do \
470 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
471 if test -d $$d/$$file; then \
472 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
473 if test -d "$(distdir)/$$file"; then \
474 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
475 fi; \
476 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
477 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
478 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
479 fi; \
480 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
481 else \
482 test -f "$(distdir)/$$file" \
483 || cp -p $$d/$$file "$(distdir)/$$file" \
484 || exit 1; \
485 fi; \
486 done
487 check-am: all-am
488 check: check-am
489 all-am: Makefile $(DATA)
490 installdirs:
491 for dir in "$(DESTDIR)$(clfilesdir)"; do \
492 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
493 done
494 install: install-am
495 install-exec: install-exec-am
496 install-data: install-data-am
497 uninstall: uninstall-am
498
499 install-am: all-am
500 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
501
502 installcheck: installcheck-am
503 install-strip:
504 if test -z '$(STRIP)'; then \
505 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
506 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
507 install; \
508 else \
509 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
510 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
511 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
512 fi
513 mostlyclean-generic:
514
515 clean-generic:
516
517 distclean-generic:
518 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
519 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
520
521 maintainer-clean-generic:
522 @echo "This command is intended for maintainers to use"
523 @echo "it deletes files that may require special tools to rebuild."
524 clean: clean-am
525
526 clean-am: clean-generic clean-libtool mostlyclean-am
527
528 distclean: distclean-am
529 -rm -f Makefile
530 distclean-am: clean-am distclean-generic
531
532 dvi: dvi-am
533
534 dvi-am:
535
536 html: html-am
537
538 html-am:
539
540 info: info-am
541
542 info-am:
543
544 install-data-am: install-dist_clfilesDATA
545
546 install-dvi: install-dvi-am
547
548 install-dvi-am:
549
550 install-exec-am:
551
552 install-html: install-html-am
553
554 install-html-am:
555
556 install-info: install-info-am
557
558 install-info-am:
559
560 install-man:
561
562 install-pdf: install-pdf-am
563
564 install-pdf-am:
565
566 install-ps: install-ps-am
567
568 install-ps-am:
569
570 installcheck-am:
571
572 maintainer-clean: maintainer-clean-am
573 -rm -f Makefile
574 maintainer-clean-am: distclean-am maintainer-clean-generic
575
576 mostlyclean: mostlyclean-am
577
578 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
579
580 pdf: pdf-am
581
582 pdf-am:
583
584 ps: ps-am
585
586 ps-am:
587
588 uninstall-am: uninstall-dist_clfilesDATA
589
590 .MAKE: install-am install-strip
591
592 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
593 cscopelist-am ctags-am distclean distclean-generic \
594 distclean-libtool distdir dvi dvi-am html html-am info info-am \
595 install install-am install-data install-data-am \
596 install-dist_clfilesDATA install-dvi install-dvi-am \
597 install-exec install-exec-am install-html install-html-am \
598 install-info install-info-am install-man install-pdf \
599 install-pdf-am install-ps install-ps-am install-strip \
600 installcheck installcheck-am installdirs maintainer-clean \
601 maintainer-clean-generic mostlyclean mostlyclean-generic \
602 mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \
603 uninstall-am uninstall-dist_clfilesDATA
604
605 .PRECIOUS: Makefile
606
607
608 # Tell versions [3.59,3.63) of GNU make to not export all variables.
609 # Otherwise a system limit (for SysV at least) may be exceeded.
610 .NOEXPORT:
0 ;;; -*- Mode: lisp -*-
1
2 ;;; Copyright (C) 2006 g10 Code GmbH
3 ;;;
4 ;;; This file is part of GPGME.
5 ;;;
6 ;;; GPGME is free software; you can redistribute it and/or
7 ;;; modify it under the terms of the GNU Lesser General Public License
8 ;;; as published by the Free Software Foundation; either version 2.1 of
9 ;;; the License, or (at your option) any later version.
10 ;;;
11 ;;; GPGME is distributed in the hope that it will be useful, but
12 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
13 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 ;;; Lesser General Public License for more details.
15 ;;;
16 ;;; You should have received a copy of the GNU Lesser General Public
17 ;;; License along with GPGME; if not, write to the Free
18 ;;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
19 ;;; 02111-1307, USA.
20
21 (defpackage #:gpgme-system
22 (:use #:common-lisp #:asdf))
23
24 (in-package #:gpgme-system)
25
26 (defsystem gpgme
27 :description "GnuPG Made Easy."
28 :author "g10 Code GmbH"
29 :version "1.17.0"
30 :licence "GPL"
31 :defsystem-depends-on ("cffi-grovel")
32 :depends-on ("cffi" "gpg-error" "trivial-garbage")
33 :components ((:file "gpgme-package")
34 (:cffi-grovel-file "gpgme-grovel"
35 :depends-on ("gpgme-package"))
36 (:file "gpgme"
37 :depends-on ("gpgme-package" "gpgme-grovel"))))
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for GPGMEPP.
17 # Copyright (C) 2016 Bundesamt für Sicherheit in der Informationstechnik
18 # Software engineering by Intevation GmbH
19 #
20 # This file is part of GPGMEPP.
21 #
22 # GPGME-CL is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU General Public License as published by
24 # the Free Software Foundation; either version 2 of the License, or
25 # (at your option) any later version.
26 #
27 # GPGME-CL is distributed in the hope that it will be useful,
28 # but WITHOUT ANY WARRANTY; without even the implied warranty of
29 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 # GNU Lesser General Public License for more details.
31 #
32 # You should have received a copy of the GNU Lesser General Public
33 # License along with this program; if not, see <https://gnu.org/licenses/>.
34 # SPDX-License-Identifier: LGPL-2.1-or-later
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = lang/cpp
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
125 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
126 CONFIG_HEADER = $(top_builddir)/conf/config.h
127 CONFIG_CLEAN_FILES =
128 CONFIG_CLEAN_VPATH_FILES =
129 AM_V_P = $(am__v_P_@AM_V@)
130 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
131 am__v_P_0 = false
132 am__v_P_1 = :
133 AM_V_GEN = $(am__v_GEN_@AM_V@)
134 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
135 am__v_GEN_0 = @echo " GEN " $@;
136 am__v_GEN_1 =
137 AM_V_at = $(am__v_at_@AM_V@)
138 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
139 am__v_at_0 = @
140 am__v_at_1 =
141 SOURCES =
142 DIST_SOURCES =
143 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
144 ctags-recursive dvi-recursive html-recursive info-recursive \
145 install-data-recursive install-dvi-recursive \
146 install-exec-recursive install-html-recursive \
147 install-info-recursive install-pdf-recursive \
148 install-ps-recursive install-recursive installcheck-recursive \
149 installdirs-recursive pdf-recursive ps-recursive \
150 tags-recursive uninstall-recursive
151 am__can_run_installinfo = \
152 case $$AM_UPDATE_INFO_DIR in \
153 n|no|NO) false;; \
154 *) (install-info --version) >/dev/null 2>&1;; \
155 esac
156 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
157 distclean-recursive maintainer-clean-recursive
158 am__recursive_targets = \
159 $(RECURSIVE_TARGETS) \
160 $(RECURSIVE_CLEAN_TARGETS) \
161 $(am__extra_recursive_targets)
162 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
163 distdir distdir-am
164 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
165 # Read a list of newline-separated strings from the standard input,
166 # and print each of them once, without duplicates. Input order is
167 # *not* preserved.
168 am__uniquify_input = $(AWK) '\
169 BEGIN { nonempty = 0; } \
170 { items[$$0] = 1; nonempty = 1; } \
171 END { if (nonempty) { for (i in items) print i; }; } \
172 '
173 # Make sure the list of sources is unique. This is necessary because,
174 # e.g., the same source file might be shared among _SOURCES variables
175 # for different programs/libraries.
176 am__define_uniq_tagged_files = \
177 list='$(am__tagged_files)'; \
178 unique=`for i in $$list; do \
179 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
180 done | $(am__uniquify_input)`
181 ETAGS = etags
182 CTAGS = ctags
183 DIST_SUBDIRS = $(SUBDIRS)
184 am__DIST_COMMON = $(srcdir)/Makefile.in \
185 $(top_srcdir)/build-aux/mkinstalldirs README
186 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
187 am__relativize = \
188 dir0=`pwd`; \
189 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
190 sed_rest='s,^[^/]*/*,,'; \
191 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
192 sed_butlast='s,/*[^/]*$$,,'; \
193 while test -n "$$dir1"; do \
194 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
195 if test "$$first" != "."; then \
196 if test "$$first" = ".."; then \
197 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
198 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
199 else \
200 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
201 if test "$$first2" = "$$first"; then \
202 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
203 else \
204 dir2="../$$dir2"; \
205 fi; \
206 dir0="$$dir0"/"$$first"; \
207 fi; \
208 fi; \
209 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
210 done; \
211 reldir="$$dir2"
212 ACLOCAL = @ACLOCAL@
213 AMTAR = @AMTAR@
214 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
215 AR = @AR@
216 AS = @AS@
217 AUTOCONF = @AUTOCONF@
218 AUTOHEADER = @AUTOHEADER@
219 AUTOMAKE = @AUTOMAKE@
220 AWK = @AWK@
221 BUILD_FILEVERSION = @BUILD_FILEVERSION@
222 BUILD_REVISION = @BUILD_REVISION@
223 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
224 BUILD_VERSION = @BUILD_VERSION@
225 CC = @CC@
226 CCDEPMODE = @CCDEPMODE@
227 CC_FOR_BUILD = @CC_FOR_BUILD@
228 CFLAGS = @CFLAGS@
229 CPP = @CPP@
230 CPPFLAGS = @CPPFLAGS@
231 CXX = @CXX@
232 CXXCPP = @CXXCPP@
233 CXXDEPMODE = @CXXDEPMODE@
234 CXXFLAGS = @CXXFLAGS@
235 CYGPATH_W = @CYGPATH_W@
236 DEFS = @DEFS@
237 DEPDIR = @DEPDIR@
238 DLLTOOL = @DLLTOOL@
239 DOXYGEN = @DOXYGEN@
240 DSYMUTIL = @DSYMUTIL@
241 DUMPBIN = @DUMPBIN@
242 ECHO_C = @ECHO_C@
243 ECHO_N = @ECHO_N@
244 ECHO_T = @ECHO_T@
245 EGREP = @EGREP@
246 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
247 EXEEXT = @EXEEXT@
248 FGREP = @FGREP@
249 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
250 GLIBC21 = @GLIBC21@
251 GLIB_CFLAGS = @GLIB_CFLAGS@
252 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
253 GLIB_LIBS = @GLIB_LIBS@
254 GLIB_MKENUMS = @GLIB_MKENUMS@
255 GOBJECT_QUERY = @GOBJECT_QUERY@
256 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
257 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
258 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
259 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
260 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
261 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
262 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
263 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
264 GPGME_QT_LIBS = @GPGME_QT_LIBS@
265 GPGRT_CONFIG = @GPGRT_CONFIG@
266 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
267 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
268 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
269 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
270 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
271 GRAPHVIZ = @GRAPHVIZ@
272 GREP = @GREP@
273 HAVE_CXX11 = @HAVE_CXX11@
274 HAVE_DOT = @HAVE_DOT@
275 INSTALL = @INSTALL@
276 INSTALL_DATA = @INSTALL_DATA@
277 INSTALL_PROGRAM = @INSTALL_PROGRAM@
278 INSTALL_SCRIPT = @INSTALL_SCRIPT@
279 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
280 LD = @LD@
281 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
282 LDFLAGS = @LDFLAGS@
283 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
284 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
285 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
286 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
287 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
288 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
289 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
290 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
291 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
292 LIBOBJS = @LIBOBJS@
293 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
294 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
295 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
296 LIBS = @LIBS@
297 LIBTOOL = @LIBTOOL@
298 LIPO = @LIPO@
299 LN_S = @LN_S@
300 LTLIBOBJS = @LTLIBOBJS@
301 MAINT = @MAINT@
302 MAKEINFO = @MAKEINFO@
303 MANIFEST_TOOL = @MANIFEST_TOOL@
304 MKDIR_P = @MKDIR_P@
305 MOC = @MOC@
306 MOC2 = @MOC2@
307 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
308 NM = @NM@
309 NMEDIT = @NMEDIT@
310 OBJDUMP = @OBJDUMP@
311 OBJEXT = @OBJEXT@
312 OTOOL = @OTOOL@
313 OTOOL64 = @OTOOL64@
314 PACKAGE = @PACKAGE@
315 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
316 PACKAGE_NAME = @PACKAGE_NAME@
317 PACKAGE_STRING = @PACKAGE_STRING@
318 PACKAGE_TARNAME = @PACKAGE_TARNAME@
319 PACKAGE_URL = @PACKAGE_URL@
320 PACKAGE_VERSION = @PACKAGE_VERSION@
321 PATH_SEPARATOR = @PATH_SEPARATOR@
322 PKG_CONFIG = @PKG_CONFIG@
323 PYTHON = @PYTHON@
324 PYTHONS = @PYTHONS@
325 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
326 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
327 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
328 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
329 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
330 PYTHON_PLATFORM = @PYTHON_PLATFORM@
331 PYTHON_PREFIX = @PYTHON_PREFIX@
332 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
333 PYTHON_VERSION = @PYTHON_VERSION@
334 QTCHOOSER = @QTCHOOSER@
335 RANLIB = @RANLIB@
336 RC = @RC@
337 SED = @SED@
338 SET_MAKE = @SET_MAKE@
339 SHELL = @SHELL@
340 STRIP = @STRIP@
341 SWIG = @SWIG@
342 SWIG_LIB = @SWIG_LIB@
343 SYSROOT = @SYSROOT@
344 VERSION = @VERSION@
345 VERSION_MAJOR = @VERSION_MAJOR@
346 VERSION_MICRO = @VERSION_MICRO@
347 VERSION_MINOR = @VERSION_MINOR@
348 VERSION_NUMBER = @VERSION_NUMBER@
349 abs_builddir = @abs_builddir@
350 abs_srcdir = @abs_srcdir@
351 abs_top_builddir = @abs_top_builddir@
352 abs_top_srcdir = @abs_top_srcdir@
353 ac_ct_AR = @ac_ct_AR@
354 ac_ct_CC = @ac_ct_CC@
355 ac_ct_CXX = @ac_ct_CXX@
356 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
357 am__include = @am__include@
358 am__leading_dot = @am__leading_dot@
359 am__quote = @am__quote@
360 am__tar = @am__tar@
361 am__untar = @am__untar@
362 bindir = @bindir@
363 build = @build@
364 build_alias = @build_alias@
365 build_cpu = @build_cpu@
366 build_os = @build_os@
367 build_vendor = @build_vendor@
368 builddir = @builddir@
369 datadir = @datadir@
370 datarootdir = @datarootdir@
371 docdir = @docdir@
372 dvidir = @dvidir@
373 emacs_local_vars_begin = @emacs_local_vars_begin@
374 emacs_local_vars_end = @emacs_local_vars_end@
375 emacs_local_vars_read_only = @emacs_local_vars_read_only@
376 exec_prefix = @exec_prefix@
377 host = @host@
378 host_alias = @host_alias@
379 host_cpu = @host_cpu@
380 host_os = @host_os@
381 host_vendor = @host_vendor@
382 htmldir = @htmldir@
383 includedir = @includedir@
384 infodir = @infodir@
385 install_sh = @install_sh@
386 libdir = @libdir@
387 libexecdir = @libexecdir@
388 localedir = @localedir@
389 localstatedir = @localstatedir@
390 mandir = @mandir@
391 mkdir_p = @mkdir_p@
392 oldincludedir = @oldincludedir@
393 pdfdir = @pdfdir@
394 pkgpyexecdir = @pkgpyexecdir@
395 pkgpythondir = @pkgpythondir@
396 prefix = @prefix@
397 program_transform_name = @program_transform_name@
398 psdir = @psdir@
399 pyexecdir = @pyexecdir@
400 pythondir = @pythondir@
401 runstatedir = @runstatedir@
402 sbindir = @sbindir@
403 sharedstatedir = @sharedstatedir@
404 srcdir = @srcdir@
405 sysconfdir = @sysconfdir@
406 target_alias = @target_alias@
407 top_build_prefix = @top_build_prefix@
408 top_builddir = @top_builddir@
409 top_srcdir = @top_srcdir@
410 SUBDIRS = src tests
411 EXTRA_DIST = README
412 all: all-recursive
413
414 .SUFFIXES:
415 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
416 @for dep in $?; do \
417 case '$(am__configure_deps)' in \
418 *$$dep*) \
419 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
420 && { if test -f $@; then exit 0; else break; fi; }; \
421 exit 1;; \
422 esac; \
423 done; \
424 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/cpp/Makefile'; \
425 $(am__cd) $(top_srcdir) && \
426 $(AUTOMAKE) --gnu lang/cpp/Makefile
427 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
428 @case '$?' in \
429 *config.status*) \
430 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
431 *) \
432 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
433 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
434 esac;
435
436 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
437 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
438
439 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
440 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
441 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
442 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
443 $(am__aclocal_m4_deps):
444
445 mostlyclean-libtool:
446 -rm -f *.lo
447
448 clean-libtool:
449 -rm -rf .libs _libs
450
451 # This directory's subdirectories are mostly independent; you can cd
452 # into them and run 'make' without going through this Makefile.
453 # To change the values of 'make' variables: instead of editing Makefiles,
454 # (1) if the variable is set in 'config.status', edit 'config.status'
455 # (which will cause the Makefiles to be regenerated when you run 'make');
456 # (2) otherwise, pass the desired values on the 'make' command line.
457 $(am__recursive_targets):
458 @fail=; \
459 if $(am__make_keepgoing); then \
460 failcom='fail=yes'; \
461 else \
462 failcom='exit 1'; \
463 fi; \
464 dot_seen=no; \
465 target=`echo $@ | sed s/-recursive//`; \
466 case "$@" in \
467 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
468 *) list='$(SUBDIRS)' ;; \
469 esac; \
470 for subdir in $$list; do \
471 echo "Making $$target in $$subdir"; \
472 if test "$$subdir" = "."; then \
473 dot_seen=yes; \
474 local_target="$$target-am"; \
475 else \
476 local_target="$$target"; \
477 fi; \
478 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
479 || eval $$failcom; \
480 done; \
481 if test "$$dot_seen" = "no"; then \
482 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
483 fi; test -z "$$fail"
484
485 ID: $(am__tagged_files)
486 $(am__define_uniq_tagged_files); mkid -fID $$unique
487 tags: tags-recursive
488 TAGS: tags
489
490 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
491 set x; \
492 here=`pwd`; \
493 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
494 include_option=--etags-include; \
495 empty_fix=.; \
496 else \
497 include_option=--include; \
498 empty_fix=; \
499 fi; \
500 list='$(SUBDIRS)'; for subdir in $$list; do \
501 if test "$$subdir" = .; then :; else \
502 test ! -f $$subdir/TAGS || \
503 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
504 fi; \
505 done; \
506 $(am__define_uniq_tagged_files); \
507 shift; \
508 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
509 test -n "$$unique" || unique=$$empty_fix; \
510 if test $$# -gt 0; then \
511 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
512 "$$@" $$unique; \
513 else \
514 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
515 $$unique; \
516 fi; \
517 fi
518 ctags: ctags-recursive
519
520 CTAGS: ctags
521 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
522 $(am__define_uniq_tagged_files); \
523 test -z "$(CTAGS_ARGS)$$unique" \
524 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
525 $$unique
526
527 GTAGS:
528 here=`$(am__cd) $(top_builddir) && pwd` \
529 && $(am__cd) $(top_srcdir) \
530 && gtags -i $(GTAGS_ARGS) "$$here"
531 cscopelist: cscopelist-recursive
532
533 cscopelist-am: $(am__tagged_files)
534 list='$(am__tagged_files)'; \
535 case "$(srcdir)" in \
536 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
537 *) sdir=$(subdir)/$(srcdir) ;; \
538 esac; \
539 for i in $$list; do \
540 if test -f "$$i"; then \
541 echo "$(subdir)/$$i"; \
542 else \
543 echo "$$sdir/$$i"; \
544 fi; \
545 done >> $(top_builddir)/cscope.files
546
547 distclean-tags:
548 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
549
550 distdir: $(BUILT_SOURCES)
551 $(MAKE) $(AM_MAKEFLAGS) distdir-am
552
553 distdir-am: $(DISTFILES)
554 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
555 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
556 list='$(DISTFILES)'; \
557 dist_files=`for file in $$list; do echo $$file; done | \
558 sed -e "s|^$$srcdirstrip/||;t" \
559 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
560 case $$dist_files in \
561 */*) $(MKDIR_P) `echo "$$dist_files" | \
562 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
563 sort -u` ;; \
564 esac; \
565 for file in $$dist_files; do \
566 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
567 if test -d $$d/$$file; then \
568 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
569 if test -d "$(distdir)/$$file"; then \
570 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
571 fi; \
572 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
573 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
574 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
575 fi; \
576 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
577 else \
578 test -f "$(distdir)/$$file" \
579 || cp -p $$d/$$file "$(distdir)/$$file" \
580 || exit 1; \
581 fi; \
582 done
583 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
584 if test "$$subdir" = .; then :; else \
585 $(am__make_dryrun) \
586 || test -d "$(distdir)/$$subdir" \
587 || $(MKDIR_P) "$(distdir)/$$subdir" \
588 || exit 1; \
589 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
590 $(am__relativize); \
591 new_distdir=$$reldir; \
592 dir1=$$subdir; dir2="$(top_distdir)"; \
593 $(am__relativize); \
594 new_top_distdir=$$reldir; \
595 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
596 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
597 ($(am__cd) $$subdir && \
598 $(MAKE) $(AM_MAKEFLAGS) \
599 top_distdir="$$new_top_distdir" \
600 distdir="$$new_distdir" \
601 am__remove_distdir=: \
602 am__skip_length_check=: \
603 am__skip_mode_fix=: \
604 distdir) \
605 || exit 1; \
606 fi; \
607 done
608 check-am: all-am
609 check: check-recursive
610 all-am: Makefile
611 installdirs: installdirs-recursive
612 installdirs-am:
613 install: install-recursive
614 install-exec: install-exec-recursive
615 install-data: install-data-recursive
616 uninstall: uninstall-recursive
617
618 install-am: all-am
619 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
620
621 installcheck: installcheck-recursive
622 install-strip:
623 if test -z '$(STRIP)'; then \
624 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
625 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
626 install; \
627 else \
628 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
629 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
630 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
631 fi
632 mostlyclean-generic:
633
634 clean-generic:
635
636 distclean-generic:
637 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
638 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
639
640 maintainer-clean-generic:
641 @echo "This command is intended for maintainers to use"
642 @echo "it deletes files that may require special tools to rebuild."
643 clean: clean-recursive
644
645 clean-am: clean-generic clean-libtool mostlyclean-am
646
647 distclean: distclean-recursive
648 -rm -f Makefile
649 distclean-am: clean-am distclean-generic distclean-tags
650
651 dvi: dvi-recursive
652
653 dvi-am:
654
655 html: html-recursive
656
657 html-am:
658
659 info: info-recursive
660
661 info-am:
662
663 install-data-am:
664
665 install-dvi: install-dvi-recursive
666
667 install-dvi-am:
668
669 install-exec-am:
670
671 install-html: install-html-recursive
672
673 install-html-am:
674
675 install-info: install-info-recursive
676
677 install-info-am:
678
679 install-man:
680
681 install-pdf: install-pdf-recursive
682
683 install-pdf-am:
684
685 install-ps: install-ps-recursive
686
687 install-ps-am:
688
689 installcheck-am:
690
691 maintainer-clean: maintainer-clean-recursive
692 -rm -f Makefile
693 maintainer-clean-am: distclean-am maintainer-clean-generic
694
695 mostlyclean: mostlyclean-recursive
696
697 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
698
699 pdf: pdf-recursive
700
701 pdf-am:
702
703 ps: ps-recursive
704
705 ps-am:
706
707 uninstall-am:
708
709 .MAKE: $(am__recursive_targets) install-am install-strip
710
711 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
712 check-am clean clean-generic clean-libtool cscopelist-am ctags \
713 ctags-am distclean distclean-generic distclean-libtool \
714 distclean-tags distdir dvi dvi-am html html-am info info-am \
715 install install-am install-data install-data-am install-dvi \
716 install-dvi-am install-exec install-exec-am install-html \
717 install-html-am install-info install-info-am install-man \
718 install-pdf install-pdf-am install-ps install-ps-am \
719 install-strip installcheck installcheck-am installdirs \
720 installdirs-am maintainer-clean maintainer-clean-generic \
721 mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
722 ps ps-am tags tags-am uninstall uninstall-am
723
724 .PRECIOUS: Makefile
725
726
727 # Tell versions [3.59,3.63) of GNU make to not export all variables.
728 # Otherwise a system limit (for SysV at least) may be exceeded.
729 .NOEXPORT:
3232 engineinfo.cpp gpgsetexpirytimeeditinteractor.cpp \
3333 gpgsetownertrusteditinteractor.cpp gpgsignkeyeditinteractor.cpp \
3434 gpgadduserideditinteractor.cpp gpggencardkeyinteractor.cpp \
35 gpgaddexistingsubkeyeditinteractor.cpp \
3536 defaultassuantransaction.cpp \
3637 scdgetinfoassuantransaction.cpp gpgagentgetinfoassuantransaction.cpp \
3738 statusconsumerassuantransaction.cpp \
38 vfsmountresult.cpp configuration.cpp tofuinfo.cpp swdbresult.cpp
39 vfsmountresult.cpp configuration.cpp tofuinfo.cpp swdbresult.cpp \
40 util.cpp
3941
4042 gpgmepp_headers = \
4143 configuration.h context.h data.h decryptionresult.h \
4547 gpgmefw.h gpgsetexpirytimeeditinteractor.h \
4648 gpgsetownertrusteditinteractor.h gpgsignkeyeditinteractor.h \
4749 gpggencardkeyinteractor.h \
50 gpgaddexistingsubkeyeditinteractor.h \
4851 importresult.h keygenerationresult.h key.h keylistresult.h \
4952 notation.h result.h scdgetinfoassuantransaction.h signingresult.h \
5053 statusconsumerassuantransaction.h \
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for GPGMEPP.
17 # Copyright (C) 2016 Bundesamt für Sicherheit in der Informationstechnik
18 # Software engineering by Intevation GmbH
19 #
20 # This file is part of GPGMEPP.
21 #
22 # GPGME-CL is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU General Public License as published by
24 # the Free Software Foundation; either version 2 of the License, or
25 # (at your option) any later version.
26 #
27 # GPGME-CL is distributed in the hope that it will be useful,
28 # but WITHOUT ANY WARRANTY; without even the implied warranty of
29 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 # GNU Lesser General Public License for more details.
31 #
32 # You should have received a copy of the GNU General Public License
33 # along with this program; if not, write to the Free Software
34 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
35 # 02111-1307, USA
36
37
38 VPATH = @srcdir@
39 am__is_gnu_make = { \
40 if test -z '$(MAKELEVEL)'; then \
41 false; \
42 elif test -n '$(MAKE_HOST)'; then \
43 true; \
44 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
45 true; \
46 else \
47 false; \
48 fi; \
49 }
50 am__make_running_with_option = \
51 case $${target_option-} in \
52 ?) ;; \
53 *) echo "am__make_running_with_option: internal error: invalid" \
54 "target option '$${target_option-}' specified" >&2; \
55 exit 1;; \
56 esac; \
57 has_opt=no; \
58 sane_makeflags=$$MAKEFLAGS; \
59 if $(am__is_gnu_make); then \
60 sane_makeflags=$$MFLAGS; \
61 else \
62 case $$MAKEFLAGS in \
63 *\\[\ \ ]*) \
64 bs=\\; \
65 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
66 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
67 esac; \
68 fi; \
69 skip_next=no; \
70 strip_trailopt () \
71 { \
72 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
73 }; \
74 for flg in $$sane_makeflags; do \
75 test $$skip_next = yes && { skip_next=no; continue; }; \
76 case $$flg in \
77 *=*|--*) continue;; \
78 -*I) strip_trailopt 'I'; skip_next=yes;; \
79 -*I?*) strip_trailopt 'I';; \
80 -*O) strip_trailopt 'O'; skip_next=yes;; \
81 -*O?*) strip_trailopt 'O';; \
82 -*l) strip_trailopt 'l'; skip_next=yes;; \
83 -*l?*) strip_trailopt 'l';; \
84 -[dEDm]) skip_next=yes;; \
85 -[JT]) skip_next=yes;; \
86 esac; \
87 case $$flg in \
88 *$$target_option*) has_opt=yes; break;; \
89 esac; \
90 done; \
91 test $$has_opt = yes
92 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
93 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
94 pkgdatadir = $(datadir)/@PACKAGE@
95 pkgincludedir = $(includedir)/@PACKAGE@
96 pkglibdir = $(libdir)/@PACKAGE@
97 pkglibexecdir = $(libexecdir)/@PACKAGE@
98 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
99 install_sh_DATA = $(install_sh) -c -m 644
100 install_sh_PROGRAM = $(install_sh) -c
101 install_sh_SCRIPT = $(install_sh) -c
102 INSTALL_HEADER = $(INSTALL_DATA)
103 transform = $(program_transform_name)
104 NORMAL_INSTALL = :
105 PRE_INSTALL = :
106 POST_INSTALL = :
107 NORMAL_UNINSTALL = :
108 PRE_UNINSTALL = :
109 POST_UNINSTALL = :
110 build_triplet = @build@
111 host_triplet = @host@
112 subdir = lang/cpp/src
113 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
114 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
115 $(top_srcdir)/m4/ax_pkg_swig.m4 \
116 $(top_srcdir)/m4/ax_python_devel.m4 \
117 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
118 $(top_srcdir)/m4/gnupg-ttyname.m4 \
119 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
120 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
121 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
122 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
123 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
124 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
125 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
126 $(ACLOCAL_M4)
127 DIST_COMMON = $(srcdir)/Makefile.am $(gpgmeppinclude_HEADERS) \
128 $(nobase_gpgmeppinclude_HEADERS) $(am__DIST_COMMON)
129 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
130 CONFIG_HEADER = $(top_builddir)/conf/config.h
131 CONFIG_CLEAN_FILES = GpgmeppConfig-w32.cmake.in GpgmeppConfig.cmake.in \
132 GpgmeppConfigVersion.cmake gpgmepp_version.h
133 CONFIG_CLEAN_VPATH_FILES =
134 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
135 am__vpath_adj = case $$p in \
136 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
137 *) f=$$p;; \
138 esac;
139 am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
140 am__install_max = 40
141 am__nobase_strip_setup = \
142 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
143 am__nobase_strip = \
144 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
145 am__nobase_list = $(am__nobase_strip_setup); \
146 for p in $$list; do echo "$$p $$p"; done | \
147 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
148 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
149 if (++n[$$2] == $(am__install_max)) \
150 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
151 END { for (dir in files) print dir, files[dir] }'
152 am__base_list = \
153 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
154 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
155 am__uninstall_files_from_dir = { \
156 test -z "$$files" \
157 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
158 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
159 $(am__cd) "$$dir" && rm -f $$files; }; \
160 }
161 am__installdirs = "$(DESTDIR)$(libdir)" \
162 "$(DESTDIR)$(gpgmeppincludedir)" \
163 "$(DESTDIR)$(gpgmeppincludedir)" \
164 "$(DESTDIR)$(gpgmeppincludedir)"
165 LTLIBRARIES = $(lib_LTLIBRARIES)
166 libgpgmepp_la_DEPENDENCIES = ../../../src/libgpgme.la
167 am__objects_1 = exception.lo context.lo key.lo trustitem.lo data.lo \
168 callbacks.lo eventloopinteractor.lo editinteractor.lo \
169 keylistresult.lo keygenerationresult.lo importresult.lo \
170 decryptionresult.lo verificationresult.lo signingresult.lo \
171 encryptionresult.lo engineinfo.lo \
172 gpgsetexpirytimeeditinteractor.lo \
173 gpgsetownertrusteditinteractor.lo gpgsignkeyeditinteractor.lo \
174 gpgadduserideditinteractor.lo gpggencardkeyinteractor.lo \
175 gpgaddexistingsubkeyeditinteractor.lo \
176 defaultassuantransaction.lo scdgetinfoassuantransaction.lo \
177 gpgagentgetinfoassuantransaction.lo \
178 statusconsumerassuantransaction.lo vfsmountresult.lo \
179 configuration.lo tofuinfo.lo swdbresult.lo util.lo
180 am__objects_2 =
181 am_libgpgmepp_la_OBJECTS = $(am__objects_1) $(am__objects_2) \
182 context_vanilla.lo $(am__objects_2) $(am__objects_2)
183 libgpgmepp_la_OBJECTS = $(am_libgpgmepp_la_OBJECTS)
184 AM_V_lt = $(am__v_lt_@AM_V@)
185 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
186 am__v_lt_0 = --silent
187 am__v_lt_1 =
188 libgpgmepp_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \
189 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \
190 $(AM_CXXFLAGS) $(CXXFLAGS) $(libgpgmepp_la_LDFLAGS) $(LDFLAGS) \
191 -o $@
192 AM_V_P = $(am__v_P_@AM_V@)
193 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
194 am__v_P_0 = false
195 am__v_P_1 = :
196 AM_V_GEN = $(am__v_GEN_@AM_V@)
197 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
198 am__v_GEN_0 = @echo " GEN " $@;
199 am__v_GEN_1 =
200 AM_V_at = $(am__v_at_@AM_V@)
201 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
202 am__v_at_0 = @
203 am__v_at_1 =
204 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
205 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
206 am__maybe_remake_depfiles = depfiles
207 am__depfiles_remade = ./$(DEPDIR)/callbacks.Plo \
208 ./$(DEPDIR)/configuration.Plo ./$(DEPDIR)/context.Plo \
209 ./$(DEPDIR)/context_vanilla.Plo ./$(DEPDIR)/data.Plo \
210 ./$(DEPDIR)/decryptionresult.Plo \
211 ./$(DEPDIR)/defaultassuantransaction.Plo \
212 ./$(DEPDIR)/editinteractor.Plo \
213 ./$(DEPDIR)/encryptionresult.Plo ./$(DEPDIR)/engineinfo.Plo \
214 ./$(DEPDIR)/eventloopinteractor.Plo ./$(DEPDIR)/exception.Plo \
215 ./$(DEPDIR)/gpgaddexistingsubkeyeditinteractor.Plo \
216 ./$(DEPDIR)/gpgadduserideditinteractor.Plo \
217 ./$(DEPDIR)/gpgagentgetinfoassuantransaction.Plo \
218 ./$(DEPDIR)/gpggencardkeyinteractor.Plo \
219 ./$(DEPDIR)/gpgsetexpirytimeeditinteractor.Plo \
220 ./$(DEPDIR)/gpgsetownertrusteditinteractor.Plo \
221 ./$(DEPDIR)/gpgsignkeyeditinteractor.Plo \
222 ./$(DEPDIR)/importresult.Plo ./$(DEPDIR)/key.Plo \
223 ./$(DEPDIR)/keygenerationresult.Plo \
224 ./$(DEPDIR)/keylistresult.Plo \
225 ./$(DEPDIR)/scdgetinfoassuantransaction.Plo \
226 ./$(DEPDIR)/signingresult.Plo \
227 ./$(DEPDIR)/statusconsumerassuantransaction.Plo \
228 ./$(DEPDIR)/swdbresult.Plo ./$(DEPDIR)/tofuinfo.Plo \
229 ./$(DEPDIR)/trustitem.Plo ./$(DEPDIR)/util.Plo \
230 ./$(DEPDIR)/verificationresult.Plo \
231 ./$(DEPDIR)/vfsmountresult.Plo
232 am__mv = mv -f
233 CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
234 $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
235 LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
236 $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \
237 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
238 $(AM_CXXFLAGS) $(CXXFLAGS)
239 AM_V_CXX = $(am__v_CXX_@AM_V@)
240 am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@)
241 am__v_CXX_0 = @echo " CXX " $@;
242 am__v_CXX_1 =
243 CXXLD = $(CXX)
244 CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
245 $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
246 $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
247 AM_V_CXXLD = $(am__v_CXXLD_@AM_V@)
248 am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@)
249 am__v_CXXLD_0 = @echo " CXXLD " $@;
250 am__v_CXXLD_1 =
251 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
252 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
253 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
254 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
255 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
256 $(AM_CFLAGS) $(CFLAGS)
257 AM_V_CC = $(am__v_CC_@AM_V@)
258 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
259 am__v_CC_0 = @echo " CC " $@;
260 am__v_CC_1 =
261 CCLD = $(CC)
262 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
263 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
264 $(AM_LDFLAGS) $(LDFLAGS) -o $@
265 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
266 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
267 am__v_CCLD_0 = @echo " CCLD " $@;
268 am__v_CCLD_1 =
269 SOURCES = $(libgpgmepp_la_SOURCES)
270 DIST_SOURCES = $(libgpgmepp_la_SOURCES)
271 am__can_run_installinfo = \
272 case $$AM_UPDATE_INFO_DIR in \
273 n|no|NO) false;; \
274 *) (install-info --version) >/dev/null 2>&1;; \
275 esac
276 HEADERS = $(gpgmeppinclude_HEADERS) $(nobase_gpgmeppinclude_HEADERS) \
277 $(nodist_gpgmeppinclude_HEADERS)
278 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
279 # Read a list of newline-separated strings from the standard input,
280 # and print each of them once, without duplicates. Input order is
281 # *not* preserved.
282 am__uniquify_input = $(AWK) '\
283 BEGIN { nonempty = 0; } \
284 { items[$$0] = 1; nonempty = 1; } \
285 END { if (nonempty) { for (i in items) print i; }; } \
286 '
287 # Make sure the list of sources is unique. This is necessary because,
288 # e.g., the same source file might be shared among _SOURCES variables
289 # for different programs/libraries.
290 am__define_uniq_tagged_files = \
291 list='$(am__tagged_files)'; \
292 unique=`for i in $$list; do \
293 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
294 done | $(am__uniquify_input)`
295 ETAGS = etags
296 CTAGS = ctags
297 am__DIST_COMMON = $(srcdir)/GpgmeppConfig-w32.cmake.in.in \
298 $(srcdir)/GpgmeppConfig.cmake.in.in \
299 $(srcdir)/GpgmeppConfigVersion.cmake.in $(srcdir)/Makefile.in \
300 $(srcdir)/gpgmepp_version.h.in $(top_srcdir)/build-aux/depcomp \
301 $(top_srcdir)/build-aux/mkinstalldirs
302 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
303 ACLOCAL = @ACLOCAL@
304 AMTAR = @AMTAR@
305 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
306 AR = @AR@
307 AS = @AS@
308 AUTOCONF = @AUTOCONF@
309 AUTOHEADER = @AUTOHEADER@
310 AUTOMAKE = @AUTOMAKE@
311 AWK = @AWK@
312 BUILD_FILEVERSION = @BUILD_FILEVERSION@
313 BUILD_REVISION = @BUILD_REVISION@
314 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
315 BUILD_VERSION = @BUILD_VERSION@
316 CC = @CC@
317 CCDEPMODE = @CCDEPMODE@
318 CC_FOR_BUILD = @CC_FOR_BUILD@
319 CFLAGS = @CFLAGS@
320 CPP = @CPP@
321 CPPFLAGS = @CPPFLAGS@
322 CXX = @CXX@
323 CXXCPP = @CXXCPP@
324 CXXDEPMODE = @CXXDEPMODE@
325 CXXFLAGS = @CXXFLAGS@
326 CYGPATH_W = @CYGPATH_W@
327 DEFS = @DEFS@
328 DEPDIR = @DEPDIR@
329 DLLTOOL = @DLLTOOL@
330 DOXYGEN = @DOXYGEN@
331 DSYMUTIL = @DSYMUTIL@
332 DUMPBIN = @DUMPBIN@
333 ECHO_C = @ECHO_C@
334 ECHO_N = @ECHO_N@
335 ECHO_T = @ECHO_T@
336 EGREP = @EGREP@
337 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
338 EXEEXT = @EXEEXT@
339 FGREP = @FGREP@
340 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
341 GLIBC21 = @GLIBC21@
342 GLIB_CFLAGS = @GLIB_CFLAGS@
343 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
344 GLIB_LIBS = @GLIB_LIBS@
345 GLIB_MKENUMS = @GLIB_MKENUMS@
346 GOBJECT_QUERY = @GOBJECT_QUERY@
347 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
348 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
349 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
350 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
351 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
352 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
353 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
354 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
355 GPGME_QT_LIBS = @GPGME_QT_LIBS@
356 GPGRT_CONFIG = @GPGRT_CONFIG@
357 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
358 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
359 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
360 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
361 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
362 GRAPHVIZ = @GRAPHVIZ@
363 GREP = @GREP@
364 HAVE_CXX11 = @HAVE_CXX11@
365 HAVE_DOT = @HAVE_DOT@
366 INSTALL = @INSTALL@
367 INSTALL_DATA = @INSTALL_DATA@
368 INSTALL_PROGRAM = @INSTALL_PROGRAM@
369 INSTALL_SCRIPT = @INSTALL_SCRIPT@
370 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
371 LD = @LD@
372 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
373 LDFLAGS = @LDFLAGS@
374 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
375 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
376 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
377 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
378 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
379 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
380 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
381 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
382 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
383 LIBOBJS = @LIBOBJS@
384 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
385 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
386 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
387 LIBS = @LIBS@
388 LIBTOOL = @LIBTOOL@
389 LIPO = @LIPO@
390 LN_S = @LN_S@
391 LTLIBOBJS = @LTLIBOBJS@
392 MAINT = @MAINT@
393 MAKEINFO = @MAKEINFO@
394 MANIFEST_TOOL = @MANIFEST_TOOL@
395 MKDIR_P = @MKDIR_P@
396 MOC = @MOC@
397 MOC2 = @MOC2@
398 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
399 NM = @NM@
400 NMEDIT = @NMEDIT@
401 OBJDUMP = @OBJDUMP@
402 OBJEXT = @OBJEXT@
403 OTOOL = @OTOOL@
404 OTOOL64 = @OTOOL64@
405 PACKAGE = @PACKAGE@
406 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
407 PACKAGE_NAME = @PACKAGE_NAME@
408 PACKAGE_STRING = @PACKAGE_STRING@
409 PACKAGE_TARNAME = @PACKAGE_TARNAME@
410 PACKAGE_URL = @PACKAGE_URL@
411 PACKAGE_VERSION = @PACKAGE_VERSION@
412 PATH_SEPARATOR = @PATH_SEPARATOR@
413 PKG_CONFIG = @PKG_CONFIG@
414 PYTHON = @PYTHON@
415 PYTHONS = @PYTHONS@
416 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
417 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
418 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
419 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
420 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
421 PYTHON_PLATFORM = @PYTHON_PLATFORM@
422 PYTHON_PREFIX = @PYTHON_PREFIX@
423 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
424 PYTHON_VERSION = @PYTHON_VERSION@
425 QTCHOOSER = @QTCHOOSER@
426 RANLIB = @RANLIB@
427 RC = @RC@
428 SED = @SED@
429 SET_MAKE = @SET_MAKE@
430 SHELL = @SHELL@
431 STRIP = @STRIP@
432 SWIG = @SWIG@
433 SWIG_LIB = @SWIG_LIB@
434 SYSROOT = @SYSROOT@
435 VERSION = @VERSION@
436 VERSION_MAJOR = @VERSION_MAJOR@
437 VERSION_MICRO = @VERSION_MICRO@
438 VERSION_MINOR = @VERSION_MINOR@
439 VERSION_NUMBER = @VERSION_NUMBER@
440 abs_builddir = @abs_builddir@
441 abs_srcdir = @abs_srcdir@
442 abs_top_builddir = @abs_top_builddir@
443 abs_top_srcdir = @abs_top_srcdir@
444 ac_ct_AR = @ac_ct_AR@
445 ac_ct_CC = @ac_ct_CC@
446 ac_ct_CXX = @ac_ct_CXX@
447 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
448 am__include = @am__include@
449 am__leading_dot = @am__leading_dot@
450 am__quote = @am__quote@
451 am__tar = @am__tar@
452 am__untar = @am__untar@
453 bindir = @bindir@
454 build = @build@
455 build_alias = @build_alias@
456 build_cpu = @build_cpu@
457 build_os = @build_os@
458 build_vendor = @build_vendor@
459 builddir = @builddir@
460 datadir = @datadir@
461 datarootdir = @datarootdir@
462 docdir = @docdir@
463 dvidir = @dvidir@
464 emacs_local_vars_begin = @emacs_local_vars_begin@
465 emacs_local_vars_end = @emacs_local_vars_end@
466 emacs_local_vars_read_only = @emacs_local_vars_read_only@
467 exec_prefix = @exec_prefix@
468 host = @host@
469 host_alias = @host_alias@
470 host_cpu = @host_cpu@
471 host_os = @host_os@
472 host_vendor = @host_vendor@
473 htmldir = @htmldir@
474 includedir = @includedir@
475 infodir = @infodir@
476 install_sh = @install_sh@
477 libdir = @libdir@
478 libexecdir = @libexecdir@
479 localedir = @localedir@
480 localstatedir = @localstatedir@
481 mandir = @mandir@
482 mkdir_p = @mkdir_p@
483 oldincludedir = @oldincludedir@
484 pdfdir = @pdfdir@
485 pkgpyexecdir = @pkgpyexecdir@
486 pkgpythondir = @pkgpythondir@
487 prefix = @prefix@
488 program_transform_name = @program_transform_name@
489 psdir = @psdir@
490 pyexecdir = @pyexecdir@
491 pythondir = @pythondir@
492 runstatedir = @runstatedir@
493 sbindir = @sbindir@
494 sharedstatedir = @sharedstatedir@
495 srcdir = @srcdir@
496 sysconfdir = @sysconfdir@
497 target_alias = @target_alias@
498 top_build_prefix = @top_build_prefix@
499 top_builddir = @top_builddir@
500 top_srcdir = @top_srcdir@
501 EXTRA_DIST = GpgmeppConfig.cmake.in.in GpgmeppConfigVersion.cmake.in \
502 gpgmepp_version.h.in GpgmeppConfig-w32.cmake.in.in
503
504 lib_LTLIBRARIES = libgpgmepp.la
505 main_sources = \
506 exception.cpp context.cpp key.cpp trustitem.cpp data.cpp callbacks.cpp \
507 eventloopinteractor.cpp editinteractor.cpp \
508 keylistresult.cpp keygenerationresult.cpp importresult.cpp \
509 decryptionresult.cpp verificationresult.cpp \
510 signingresult.cpp encryptionresult.cpp \
511 engineinfo.cpp gpgsetexpirytimeeditinteractor.cpp \
512 gpgsetownertrusteditinteractor.cpp gpgsignkeyeditinteractor.cpp \
513 gpgadduserideditinteractor.cpp gpggencardkeyinteractor.cpp \
514 gpgaddexistingsubkeyeditinteractor.cpp \
515 defaultassuantransaction.cpp \
516 scdgetinfoassuantransaction.cpp gpgagentgetinfoassuantransaction.cpp \
517 statusconsumerassuantransaction.cpp \
518 vfsmountresult.cpp configuration.cpp tofuinfo.cpp swdbresult.cpp \
519 util.cpp
520
521 gpgmepp_headers = \
522 configuration.h context.h data.h decryptionresult.h \
523 defaultassuantransaction.h editinteractor.h encryptionresult.h \
524 engineinfo.h error.h eventloopinteractor.h exception.h global.h \
525 gpgadduserideditinteractor.h gpgagentgetinfoassuantransaction.h \
526 gpgmefw.h gpgsetexpirytimeeditinteractor.h \
527 gpgsetownertrusteditinteractor.h gpgsignkeyeditinteractor.h \
528 gpggencardkeyinteractor.h \
529 gpgaddexistingsubkeyeditinteractor.h \
530 importresult.h keygenerationresult.h key.h keylistresult.h \
531 notation.h result.h scdgetinfoassuantransaction.h signingresult.h \
532 statusconsumerassuantransaction.h \
533 trustitem.h verificationresult.h vfsmountresult.h gpgmepp_export.h \
534 tofuinfo.h swdbresult.h
535
536 private_gpgmepp_headers = \
537 result_p.h context_p.h util.h callbacks.h data_p.h
538
539 interface_headers = \
540 interfaces/assuantransaction.h interfaces/dataprovider.h \
541 interfaces/passphraseprovider.h interfaces/progressprovider.h \
542 interfaces/statusconsumer.h
543
544 gpgmeppincludedir = $(includedir)/gpgme++
545 gpgmeppinclude_HEADERS = $(gpgmepp_headers)
546 nobase_gpgmeppinclude_HEADERS = $(interface_headers)
547 nodist_gpgmeppinclude_HEADERS = gpgmepp_version.h
548 libgpgmepp_la_SOURCES = $(main_sources) $(gpgmepp_headers) context_vanilla.cpp \
549 $(interface_headers) $(private_gpgmepp_headers)
550
551 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@ @LIBASSUAN_CFLAGS@ \
552 -DBUILDING_GPGMEPP -Wsuggest-override \
553 -Wzero-as-null-pointer-constant
554
555 libgpgmepp_la_LIBADD = ../../../src/libgpgme.la @LIBASSUAN_LIBS@
556 libgpgmepp_la_LDFLAGS = -no-undefined -version-info \
557 @LIBGPGMEPP_LT_CURRENT@:@LIBGPGMEPP_LT_REVISION@:@LIBGPGMEPP_LT_AGE@
558
559 @HAVE_MACOS_SYSTEM_FALSE@libsuffix = .so
560 @HAVE_MACOS_SYSTEM_TRUE@libsuffix = .dylib
561 CLEANFILES = GpgmeppConfig.cmake GpgmeppConfigVersion.cmake \
562 gpgmepp_version.h GpgmeppConfig.cmake.in
563
564 all: all-am
565
566 .SUFFIXES:
567 .SUFFIXES: .cpp .lo .o .obj
568 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
569 @for dep in $?; do \
570 case '$(am__configure_deps)' in \
571 *$$dep*) \
572 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
573 && { if test -f $@; then exit 0; else break; fi; }; \
574 exit 1;; \
575 esac; \
576 done; \
577 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/cpp/src/Makefile'; \
578 $(am__cd) $(top_srcdir) && \
579 $(AUTOMAKE) --gnu lang/cpp/src/Makefile
580 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
581 @case '$?' in \
582 *config.status*) \
583 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
584 *) \
585 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
586 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
587 esac;
588
589 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
590 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
591
592 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
593 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
594 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
595 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
596 $(am__aclocal_m4_deps):
597 GpgmeppConfig-w32.cmake.in: $(top_builddir)/config.status $(srcdir)/GpgmeppConfig-w32.cmake.in.in
598 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
599 GpgmeppConfig.cmake.in: $(top_builddir)/config.status $(srcdir)/GpgmeppConfig.cmake.in.in
600 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
601 GpgmeppConfigVersion.cmake: $(top_builddir)/config.status $(srcdir)/GpgmeppConfigVersion.cmake.in
602 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
603 gpgmepp_version.h: $(top_builddir)/config.status $(srcdir)/gpgmepp_version.h.in
604 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
605
606 install-libLTLIBRARIES: $(lib_LTLIBRARIES)
607 @$(NORMAL_INSTALL)
608 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
609 list2=; for p in $$list; do \
610 if test -f $$p; then \
611 list2="$$list2 $$p"; \
612 else :; fi; \
613 done; \
614 test -z "$$list2" || { \
615 echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
616 $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
617 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
618 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
619 }
620
621 uninstall-libLTLIBRARIES:
622 @$(NORMAL_UNINSTALL)
623 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
624 for p in $$list; do \
625 $(am__strip_dir) \
626 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
627 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
628 done
629
630 clean-libLTLIBRARIES:
631 -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
632 @list='$(lib_LTLIBRARIES)'; \
633 locs=`for p in $$list; do echo $$p; done | \
634 sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
635 sort -u`; \
636 test -z "$$locs" || { \
637 echo rm -f $${locs}; \
638 rm -f $${locs}; \
639 }
640
641 libgpgmepp.la: $(libgpgmepp_la_OBJECTS) $(libgpgmepp_la_DEPENDENCIES) $(EXTRA_libgpgmepp_la_DEPENDENCIES)
642 $(AM_V_CXXLD)$(libgpgmepp_la_LINK) -rpath $(libdir) $(libgpgmepp_la_OBJECTS) $(libgpgmepp_la_LIBADD) $(LIBS)
643
644 mostlyclean-compile:
645 -rm -f *.$(OBJEXT)
646
647 distclean-compile:
648 -rm -f *.tab.c
649
650 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks.Plo@am__quote@ # am--include-marker
651 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/configuration.Plo@am__quote@ # am--include-marker
652 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/context.Plo@am__quote@ # am--include-marker
653 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/context_vanilla.Plo@am__quote@ # am--include-marker
654 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data.Plo@am__quote@ # am--include-marker
655 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decryptionresult.Plo@am__quote@ # am--include-marker
656 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/defaultassuantransaction.Plo@am__quote@ # am--include-marker
657 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/editinteractor.Plo@am__quote@ # am--include-marker
658 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/encryptionresult.Plo@am__quote@ # am--include-marker
659 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engineinfo.Plo@am__quote@ # am--include-marker
660 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/eventloopinteractor.Plo@am__quote@ # am--include-marker
661 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exception.Plo@am__quote@ # am--include-marker
662 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgaddexistingsubkeyeditinteractor.Plo@am__quote@ # am--include-marker
663 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgadduserideditinteractor.Plo@am__quote@ # am--include-marker
664 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgagentgetinfoassuantransaction.Plo@am__quote@ # am--include-marker
665 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpggencardkeyinteractor.Plo@am__quote@ # am--include-marker
666 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgsetexpirytimeeditinteractor.Plo@am__quote@ # am--include-marker
667 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgsetownertrusteditinteractor.Plo@am__quote@ # am--include-marker
668 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgsignkeyeditinteractor.Plo@am__quote@ # am--include-marker
669 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/importresult.Plo@am__quote@ # am--include-marker
670 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/key.Plo@am__quote@ # am--include-marker
671 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keygenerationresult.Plo@am__quote@ # am--include-marker
672 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keylistresult.Plo@am__quote@ # am--include-marker
673 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/scdgetinfoassuantransaction.Plo@am__quote@ # am--include-marker
674 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/signingresult.Plo@am__quote@ # am--include-marker
675 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/statusconsumerassuantransaction.Plo@am__quote@ # am--include-marker
676 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/swdbresult.Plo@am__quote@ # am--include-marker
677 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tofuinfo.Plo@am__quote@ # am--include-marker
678 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trustitem.Plo@am__quote@ # am--include-marker
679 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Plo@am__quote@ # am--include-marker
680 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/verificationresult.Plo@am__quote@ # am--include-marker
681 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vfsmountresult.Plo@am__quote@ # am--include-marker
682
683 $(am__depfiles_remade):
684 @$(MKDIR_P) $(@D)
685 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
686
687 am--depfiles: $(am__depfiles_remade)
688
689 .cpp.o:
690 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
691 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
692 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
693 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
694 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $<
695
696 .cpp.obj:
697 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
698 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
699 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
700 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
701 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
702
703 .cpp.lo:
704 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
705 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
706 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
707 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
708 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $<
709
710 mostlyclean-libtool:
711 -rm -f *.lo
712
713 clean-libtool:
714 -rm -rf .libs _libs
715 install-gpgmeppincludeHEADERS: $(gpgmeppinclude_HEADERS)
716 @$(NORMAL_INSTALL)
717 @list='$(gpgmeppinclude_HEADERS)'; test -n "$(gpgmeppincludedir)" || list=; \
718 if test -n "$$list"; then \
719 echo " $(MKDIR_P) '$(DESTDIR)$(gpgmeppincludedir)'"; \
720 $(MKDIR_P) "$(DESTDIR)$(gpgmeppincludedir)" || exit 1; \
721 fi; \
722 for p in $$list; do \
723 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
724 echo "$$d$$p"; \
725 done | $(am__base_list) | \
726 while read files; do \
727 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(gpgmeppincludedir)'"; \
728 $(INSTALL_HEADER) $$files "$(DESTDIR)$(gpgmeppincludedir)" || exit $$?; \
729 done
730
731 uninstall-gpgmeppincludeHEADERS:
732 @$(NORMAL_UNINSTALL)
733 @list='$(gpgmeppinclude_HEADERS)'; test -n "$(gpgmeppincludedir)" || list=; \
734 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
735 dir='$(DESTDIR)$(gpgmeppincludedir)'; $(am__uninstall_files_from_dir)
736 install-nobase_gpgmeppincludeHEADERS: $(nobase_gpgmeppinclude_HEADERS)
737 @$(NORMAL_INSTALL)
738 @list='$(nobase_gpgmeppinclude_HEADERS)'; test -n "$(gpgmeppincludedir)" || list=; \
739 if test -n "$$list"; then \
740 echo " $(MKDIR_P) '$(DESTDIR)$(gpgmeppincludedir)'"; \
741 $(MKDIR_P) "$(DESTDIR)$(gpgmeppincludedir)" || exit 1; \
742 fi; \
743 $(am__nobase_list) | while read dir files; do \
744 xfiles=; for file in $$files; do \
745 if test -f "$$file"; then xfiles="$$xfiles $$file"; \
746 else xfiles="$$xfiles $(srcdir)/$$file"; fi; done; \
747 test -z "$$xfiles" || { \
748 test "x$$dir" = x. || { \
749 echo " $(MKDIR_P) '$(DESTDIR)$(gpgmeppincludedir)/$$dir'"; \
750 $(MKDIR_P) "$(DESTDIR)$(gpgmeppincludedir)/$$dir"; }; \
751 echo " $(INSTALL_HEADER) $$xfiles '$(DESTDIR)$(gpgmeppincludedir)/$$dir'"; \
752 $(INSTALL_HEADER) $$xfiles "$(DESTDIR)$(gpgmeppincludedir)/$$dir" || exit $$?; }; \
753 done
754
755 uninstall-nobase_gpgmeppincludeHEADERS:
756 @$(NORMAL_UNINSTALL)
757 @list='$(nobase_gpgmeppinclude_HEADERS)'; test -n "$(gpgmeppincludedir)" || list=; \
758 $(am__nobase_strip_setup); files=`$(am__nobase_strip)`; \
759 dir='$(DESTDIR)$(gpgmeppincludedir)'; $(am__uninstall_files_from_dir)
760 install-nodist_gpgmeppincludeHEADERS: $(nodist_gpgmeppinclude_HEADERS)
761 @$(NORMAL_INSTALL)
762 @list='$(nodist_gpgmeppinclude_HEADERS)'; test -n "$(gpgmeppincludedir)" || list=; \
763 if test -n "$$list"; then \
764 echo " $(MKDIR_P) '$(DESTDIR)$(gpgmeppincludedir)'"; \
765 $(MKDIR_P) "$(DESTDIR)$(gpgmeppincludedir)" || exit 1; \
766 fi; \
767 for p in $$list; do \
768 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
769 echo "$$d$$p"; \
770 done | $(am__base_list) | \
771 while read files; do \
772 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(gpgmeppincludedir)'"; \
773 $(INSTALL_HEADER) $$files "$(DESTDIR)$(gpgmeppincludedir)" || exit $$?; \
774 done
775
776 uninstall-nodist_gpgmeppincludeHEADERS:
777 @$(NORMAL_UNINSTALL)
778 @list='$(nodist_gpgmeppinclude_HEADERS)'; test -n "$(gpgmeppincludedir)" || list=; \
779 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
780 dir='$(DESTDIR)$(gpgmeppincludedir)'; $(am__uninstall_files_from_dir)
781
782 ID: $(am__tagged_files)
783 $(am__define_uniq_tagged_files); mkid -fID $$unique
784 tags: tags-am
785 TAGS: tags
786
787 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
788 set x; \
789 here=`pwd`; \
790 $(am__define_uniq_tagged_files); \
791 shift; \
792 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
793 test -n "$$unique" || unique=$$empty_fix; \
794 if test $$# -gt 0; then \
795 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
796 "$$@" $$unique; \
797 else \
798 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
799 $$unique; \
800 fi; \
801 fi
802 ctags: ctags-am
803
804 CTAGS: ctags
805 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
806 $(am__define_uniq_tagged_files); \
807 test -z "$(CTAGS_ARGS)$$unique" \
808 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
809 $$unique
810
811 GTAGS:
812 here=`$(am__cd) $(top_builddir) && pwd` \
813 && $(am__cd) $(top_srcdir) \
814 && gtags -i $(GTAGS_ARGS) "$$here"
815 cscopelist: cscopelist-am
816
817 cscopelist-am: $(am__tagged_files)
818 list='$(am__tagged_files)'; \
819 case "$(srcdir)" in \
820 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
821 *) sdir=$(subdir)/$(srcdir) ;; \
822 esac; \
823 for i in $$list; do \
824 if test -f "$$i"; then \
825 echo "$(subdir)/$$i"; \
826 else \
827 echo "$$sdir/$$i"; \
828 fi; \
829 done >> $(top_builddir)/cscope.files
830
831 distclean-tags:
832 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
833
834 distdir: $(BUILT_SOURCES)
835 $(MAKE) $(AM_MAKEFLAGS) distdir-am
836
837 distdir-am: $(DISTFILES)
838 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
839 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
840 list='$(DISTFILES)'; \
841 dist_files=`for file in $$list; do echo $$file; done | \
842 sed -e "s|^$$srcdirstrip/||;t" \
843 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
844 case $$dist_files in \
845 */*) $(MKDIR_P) `echo "$$dist_files" | \
846 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
847 sort -u` ;; \
848 esac; \
849 for file in $$dist_files; do \
850 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
851 if test -d $$d/$$file; then \
852 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
853 if test -d "$(distdir)/$$file"; then \
854 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
855 fi; \
856 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
857 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
858 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
859 fi; \
860 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
861 else \
862 test -f "$(distdir)/$$file" \
863 || cp -p $$d/$$file "$(distdir)/$$file" \
864 || exit 1; \
865 fi; \
866 done
867 check-am: all-am
868 check: check-am
869 all-am: Makefile $(LTLIBRARIES) $(HEADERS)
870 installdirs:
871 for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(gpgmeppincludedir)" "$(DESTDIR)$(gpgmeppincludedir)" "$(DESTDIR)$(gpgmeppincludedir)"; do \
872 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
873 done
874 install: install-am
875 install-exec: install-exec-am
876 install-data: install-data-am
877 uninstall: uninstall-am
878
879 install-am: all-am
880 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
881
882 installcheck: installcheck-am
883 install-strip:
884 if test -z '$(STRIP)'; then \
885 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
886 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
887 install; \
888 else \
889 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
890 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
891 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
892 fi
893 mostlyclean-generic:
894
895 clean-generic:
896 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
897
898 distclean-generic:
899 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
900 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
901
902 maintainer-clean-generic:
903 @echo "This command is intended for maintainers to use"
904 @echo "it deletes files that may require special tools to rebuild."
905 clean: clean-am
906
907 clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
908 mostlyclean-am
909
910 distclean: distclean-am
911 -rm -f ./$(DEPDIR)/callbacks.Plo
912 -rm -f ./$(DEPDIR)/configuration.Plo
913 -rm -f ./$(DEPDIR)/context.Plo
914 -rm -f ./$(DEPDIR)/context_vanilla.Plo
915 -rm -f ./$(DEPDIR)/data.Plo
916 -rm -f ./$(DEPDIR)/decryptionresult.Plo
917 -rm -f ./$(DEPDIR)/defaultassuantransaction.Plo
918 -rm -f ./$(DEPDIR)/editinteractor.Plo
919 -rm -f ./$(DEPDIR)/encryptionresult.Plo
920 -rm -f ./$(DEPDIR)/engineinfo.Plo
921 -rm -f ./$(DEPDIR)/eventloopinteractor.Plo
922 -rm -f ./$(DEPDIR)/exception.Plo
923 -rm -f ./$(DEPDIR)/gpgaddexistingsubkeyeditinteractor.Plo
924 -rm -f ./$(DEPDIR)/gpgadduserideditinteractor.Plo
925 -rm -f ./$(DEPDIR)/gpgagentgetinfoassuantransaction.Plo
926 -rm -f ./$(DEPDIR)/gpggencardkeyinteractor.Plo
927 -rm -f ./$(DEPDIR)/gpgsetexpirytimeeditinteractor.Plo
928 -rm -f ./$(DEPDIR)/gpgsetownertrusteditinteractor.Plo
929 -rm -f ./$(DEPDIR)/gpgsignkeyeditinteractor.Plo
930 -rm -f ./$(DEPDIR)/importresult.Plo
931 -rm -f ./$(DEPDIR)/key.Plo
932 -rm -f ./$(DEPDIR)/keygenerationresult.Plo
933 -rm -f ./$(DEPDIR)/keylistresult.Plo
934 -rm -f ./$(DEPDIR)/scdgetinfoassuantransaction.Plo
935 -rm -f ./$(DEPDIR)/signingresult.Plo
936 -rm -f ./$(DEPDIR)/statusconsumerassuantransaction.Plo
937 -rm -f ./$(DEPDIR)/swdbresult.Plo
938 -rm -f ./$(DEPDIR)/tofuinfo.Plo
939 -rm -f ./$(DEPDIR)/trustitem.Plo
940 -rm -f ./$(DEPDIR)/util.Plo
941 -rm -f ./$(DEPDIR)/verificationresult.Plo
942 -rm -f ./$(DEPDIR)/vfsmountresult.Plo
943 -rm -f Makefile
944 distclean-am: clean-am distclean-compile distclean-generic \
945 distclean-tags
946
947 dvi: dvi-am
948
949 dvi-am:
950
951 html: html-am
952
953 html-am:
954
955 info: info-am
956
957 info-am:
958
959 install-data-am: install-data-local install-gpgmeppincludeHEADERS \
960 install-nobase_gpgmeppincludeHEADERS \
961 install-nodist_gpgmeppincludeHEADERS
962
963 install-dvi: install-dvi-am
964
965 install-dvi-am:
966
967 install-exec-am: install-libLTLIBRARIES
968
969 install-html: install-html-am
970
971 install-html-am:
972
973 install-info: install-info-am
974
975 install-info-am:
976
977 install-man:
978
979 install-pdf: install-pdf-am
980
981 install-pdf-am:
982
983 install-ps: install-ps-am
984
985 install-ps-am:
986
987 installcheck-am:
988
989 maintainer-clean: maintainer-clean-am
990 -rm -f ./$(DEPDIR)/callbacks.Plo
991 -rm -f ./$(DEPDIR)/configuration.Plo
992 -rm -f ./$(DEPDIR)/context.Plo
993 -rm -f ./$(DEPDIR)/context_vanilla.Plo
994 -rm -f ./$(DEPDIR)/data.Plo
995 -rm -f ./$(DEPDIR)/decryptionresult.Plo
996 -rm -f ./$(DEPDIR)/defaultassuantransaction.Plo
997 -rm -f ./$(DEPDIR)/editinteractor.Plo
998 -rm -f ./$(DEPDIR)/encryptionresult.Plo
999 -rm -f ./$(DEPDIR)/engineinfo.Plo
1000 -rm -f ./$(DEPDIR)/eventloopinteractor.Plo
1001 -rm -f ./$(DEPDIR)/exception.Plo
1002 -rm -f ./$(DEPDIR)/gpgaddexistingsubkeyeditinteractor.Plo
1003 -rm -f ./$(DEPDIR)/gpgadduserideditinteractor.Plo
1004 -rm -f ./$(DEPDIR)/gpgagentgetinfoassuantransaction.Plo
1005 -rm -f ./$(DEPDIR)/gpggencardkeyinteractor.Plo
1006 -rm -f ./$(DEPDIR)/gpgsetexpirytimeeditinteractor.Plo
1007 -rm -f ./$(DEPDIR)/gpgsetownertrusteditinteractor.Plo
1008 -rm -f ./$(DEPDIR)/gpgsignkeyeditinteractor.Plo
1009 -rm -f ./$(DEPDIR)/importresult.Plo
1010 -rm -f ./$(DEPDIR)/key.Plo
1011 -rm -f ./$(DEPDIR)/keygenerationresult.Plo
1012 -rm -f ./$(DEPDIR)/keylistresult.Plo
1013 -rm -f ./$(DEPDIR)/scdgetinfoassuantransaction.Plo
1014 -rm -f ./$(DEPDIR)/signingresult.Plo
1015 -rm -f ./$(DEPDIR)/statusconsumerassuantransaction.Plo
1016 -rm -f ./$(DEPDIR)/swdbresult.Plo
1017 -rm -f ./$(DEPDIR)/tofuinfo.Plo
1018 -rm -f ./$(DEPDIR)/trustitem.Plo
1019 -rm -f ./$(DEPDIR)/util.Plo
1020 -rm -f ./$(DEPDIR)/verificationresult.Plo
1021 -rm -f ./$(DEPDIR)/vfsmountresult.Plo
1022 -rm -f Makefile
1023 maintainer-clean-am: distclean-am maintainer-clean-generic
1024
1025 mostlyclean: mostlyclean-am
1026
1027 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
1028 mostlyclean-libtool
1029
1030 pdf: pdf-am
1031
1032 pdf-am:
1033
1034 ps: ps-am
1035
1036 ps-am:
1037
1038 uninstall-am: uninstall-gpgmeppincludeHEADERS uninstall-libLTLIBRARIES \
1039 uninstall-local uninstall-nobase_gpgmeppincludeHEADERS \
1040 uninstall-nodist_gpgmeppincludeHEADERS
1041
1042 .MAKE: install-am install-strip
1043
1044 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
1045 clean-generic clean-libLTLIBRARIES clean-libtool cscopelist-am \
1046 ctags ctags-am distclean distclean-compile distclean-generic \
1047 distclean-libtool distclean-tags distdir dvi dvi-am html \
1048 html-am info info-am install install-am install-data \
1049 install-data-am install-data-local install-dvi install-dvi-am \
1050 install-exec install-exec-am install-gpgmeppincludeHEADERS \
1051 install-html install-html-am install-info install-info-am \
1052 install-libLTLIBRARIES install-man \
1053 install-nobase_gpgmeppincludeHEADERS \
1054 install-nodist_gpgmeppincludeHEADERS install-pdf \
1055 install-pdf-am install-ps install-ps-am install-strip \
1056 installcheck installcheck-am installdirs maintainer-clean \
1057 maintainer-clean-generic mostlyclean mostlyclean-compile \
1058 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
1059 tags tags-am uninstall uninstall-am \
1060 uninstall-gpgmeppincludeHEADERS uninstall-libLTLIBRARIES \
1061 uninstall-local uninstall-nobase_gpgmeppincludeHEADERS \
1062 uninstall-nodist_gpgmeppincludeHEADERS
1063
1064 .PRECIOUS: Makefile
1065
1066
1067 @HAVE_W32_SYSTEM_TRUE@GpgmeppConfig.cmake: GpgmeppConfig-w32.cmake.in
1068 @HAVE_W32_SYSTEM_TRUE@ sed -e 's|[@]resolved_bindir@|$(bindir)|g' < "$<" | \
1069 @HAVE_W32_SYSTEM_TRUE@ sed -e 's|[@]resolved_libdir@|$(libdir)|g' | \
1070 @HAVE_W32_SYSTEM_TRUE@ sed -e 's|[@]resolved_includedir@|$(includedir)|g' > $@
1071 @HAVE_W32_SYSTEM_FALSE@GpgmeppConfig.cmake: GpgmeppConfig.cmake.in
1072 @HAVE_W32_SYSTEM_FALSE@ sed -e 's|[@]resolved_libdir@|$(libdir)|g' < "$<" | \
1073 @HAVE_W32_SYSTEM_FALSE@ sed -e 's|[@]libsuffix@|$(libsuffix)|g' | \
1074 @HAVE_W32_SYSTEM_FALSE@ sed -e 's|[@]resolved_includedir@|$(includedir)|g' > $@
1075 install-cmake-files: GpgmeppConfig.cmake GpgmeppConfigVersion.cmake
1076 -$(INSTALL) -d $(DESTDIR)$(libdir)/cmake/Gpgmepp
1077 $(INSTALL) -m 644 GpgmeppConfig.cmake \
1078 $(DESTDIR)$(libdir)/cmake/Gpgmepp/GpgmeppConfig.cmake
1079 $(INSTALL) -m 644 GpgmeppConfigVersion.cmake \
1080 $(DESTDIR)$(libdir)/cmake/Gpgmepp/GpgmeppConfigVersion.cmake
1081
1082 uninstall-cmake-files:
1083 -rm $(DESTDIR)$(libdir)/cmake/Gpgmepp/GpgmeppConfigVersion.cmake
1084 -rm $(DESTDIR)$(libdir)/cmake/Gpgmepp/GpgmeppConfig.cmake
1085 -rmdir $(DESTDIR)$(libdir)/cmake/Gpgmepp/
1086
1087 install-data-local: install-cmake-files
1088
1089 uninstall-local: uninstall-cmake-files
1090
1091 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1092 # Otherwise a system limit (for SysV at least) may be exceeded.
1093 .NOEXPORT:
4949
5050 #include <gpgme.h>
5151
52 #include <functional>
5253 #include <istream>
5354 #include <numeric>
5455 #ifndef NDEBUG
461462 return Error(d->lasterr = gpgme_set_locale(d->ctx, cat, val));
462463 }
463464
465 static GpgME::EngineInfo get_engine_info(gpgme_engine_info_t engineInfos, gpgme_protocol_t protocol)
466 {
467 if (!engineInfos) {
468 return EngineInfo{};
469 }
470
471 for (gpgme_engine_info_t i = engineInfos ; i ; i = i->next) {
472 if (i->protocol == protocol) {
473 return EngineInfo{i};
474 }
475 }
476
477 return EngineInfo{};
478 }
479
480 static GpgME::EngineInfo get_static_engine_info(gpgme_protocol_t protocol)
481 {
482 gpgme_engine_info_t ei = nullptr;
483 if (gpgme_get_engine_info(&ei)) {
484 return EngineInfo{};
485 }
486 return get_engine_info(ei, protocol);
487 }
488
464489 EngineInfo Context::engineInfo() const
465490 {
466 return EngineInfo(gpgme_ctx_get_engine_info(d->ctx));
491 return get_engine_info(gpgme_ctx_get_engine_info(d->ctx), gpgme_get_protocol(d->ctx));
467492 }
468493
469494 Error Context::setEngineFileName(const char *filename)
503528 Error Context::startKeyListing(const char *patterns[], bool secretOnly)
504529 {
505530 d->lastop = Private::KeyList;
506 #ifndef HAVE_GPGME_EXT_KEYLIST_MODE_EXTERNAL_NONBROKEN
507 if (!patterns || !patterns[0] || !patterns[1]) {
508 // max. one pattern -> use the non-ext version
509 return startKeyListing(patterns ? patterns[0] : nullptr, secretOnly);
510 }
511 #endif
512531 return Error(d->lasterr = gpgme_op_keylist_ext_start(d->ctx, patterns, int(secretOnly), 0));
513532 }
514533
563582 }
564583 }
565584
566 Error Context::exportPublicKeys(const char *pattern, Data &keyData, unsigned int flags)
585 Error Context::exportKeys(const char *pattern, Data &keyData, unsigned int mode)
567586 {
568587 d->lastop = Private::Export;
569588 Data::Private *const dp = keyData.impl();
570 return Error(d->lasterr = gpgme_op_export(d->ctx, pattern, flags, dp ? dp->data : nullptr));
571 }
572
573 Error Context::exportPublicKeys(const char *patterns[], Data &keyData, unsigned int flags)
574 {
575 d->lastop = Private::Export;
576 #ifndef HAVE_GPGME_EXT_KEYLIST_MODE_EXTERNAL_NONBROKEN
577 if (!patterns || !patterns[0] || !patterns[1]) {
578 // max. one pattern -> use the non-ext version
579 return exportPublicKeys(patterns ? patterns[0] : nullptr, keyData, flags);
580 }
581 #endif
582 Data::Private *const dp = keyData.impl();
583 return Error(d->lasterr = gpgme_op_export_ext(d->ctx, patterns, flags, dp ? dp->data : nullptr));
584 }
585
586 Error Context::startPublicKeyExport(const char *pattern, Data &keyData, unsigned int flags)
589 return Error(d->lasterr = gpgme_op_export(d->ctx, pattern, mode, dp ? dp->data : nullptr));
590 }
591
592 Error Context::exportKeys(const char *patterns[], Data &keyData, unsigned int mode)
587593 {
588594 d->lastop = Private::Export;
589595 Data::Private *const dp = keyData.impl();
590 return Error(d->lasterr = gpgme_op_export_start(d->ctx, pattern, flags, dp ? dp->data : nullptr));
591 }
592
593 Error Context::startPublicKeyExport(const char *patterns[], Data &keyData, unsigned int flags)
596 return Error(d->lasterr = gpgme_op_export_ext(d->ctx, patterns, mode, dp ? dp->data : nullptr));
597 }
598
599 Error Context::startKeyExport(const char *pattern, Data &keyData, unsigned int mode)
594600 {
595601 d->lastop = Private::Export;
596 #ifndef HAVE_GPGME_EXT_KEYLIST_MODE_EXTERNAL_NONBROKEN
597 if (!patterns || !patterns[0] || !patterns[1]) {
598 // max. one pattern -> use the non-ext version
599 return startPublicKeyExport(patterns ? patterns[0] : nullptr, keyData, flags);
600 }
601 #endif
602602 Data::Private *const dp = keyData.impl();
603 return Error(d->lasterr = gpgme_op_export_ext_start(d->ctx, patterns, flags, dp ? dp->data : nullptr));
604 }
605
606
607 /* Same as above but without flags */
603 return Error(d->lasterr = gpgme_op_export_start(d->ctx, pattern, mode, dp ? dp->data : nullptr));
604 }
605
606 Error Context::startKeyExport(const char *patterns[], Data &keyData, unsigned int mode)
607 {
608 d->lastop = Private::Export;
609 Data::Private *const dp = keyData.impl();
610 return Error(d->lasterr = gpgme_op_export_ext_start(d->ctx, patterns, mode, dp ? dp->data : nullptr));
611 }
612
613 Error Context::exportPublicKeys(const char *pattern, Data &keyData, unsigned int mode)
614 {
615 if (mode & (ExportSecret | ExportSecretSubkey)) {
616 return Error::fromCode(GPG_ERR_INV_FLAG);
617 }
618 return exportKeys(pattern, keyData, mode);
619 }
620
621 Error Context::exportPublicKeys(const char *patterns[], Data &keyData, unsigned int mode)
622 {
623 if (mode & (ExportSecret | ExportSecretSubkey)) {
624 return Error::fromCode(GPG_ERR_INV_FLAG);
625 }
626 return exportKeys(patterns, keyData, mode);
627 }
628
629 Error Context::startPublicKeyExport(const char *pattern, Data &keyData, unsigned int mode)
630 {
631 if (mode & (ExportSecret | ExportSecretSubkey)) {
632 return Error::fromCode(GPG_ERR_INV_FLAG);
633 }
634 return startKeyExport(pattern, keyData, mode);
635 }
636
637 Error Context::startPublicKeyExport(const char *patterns[], Data &keyData, unsigned int mode)
638 {
639 if (mode & (ExportSecret | ExportSecretSubkey)) {
640 return Error::fromCode(GPG_ERR_INV_FLAG);
641 }
642 return startKeyExport(patterns, keyData, mode);
643 }
644
645 /* Same as above but without mode */
608646 Error Context::exportPublicKeys(const char *pattern, Data &keyData)
609647 {
610648 return exportPublicKeys(pattern, keyData, 0);
623661 Error Context::startPublicKeyExport(const char *patterns[], Data &keyData)
624662 {
625663 return startPublicKeyExport(patterns, keyData, 0);
664 }
665
666 Error Context::exportSecretKeys(const char *pattern, Data &keyData, unsigned int mode)
667 {
668 if (mode & ExportSecretSubkey) {
669 return Error::fromCode(GPG_ERR_INV_FLAG);
670 }
671 return exportKeys(pattern, keyData, mode|ExportSecret);
672 }
673
674 Error Context::exportSecretKeys(const char *patterns[], Data &keyData, unsigned int mode)
675 {
676 if (mode & ExportSecretSubkey) {
677 return Error::fromCode(GPG_ERR_INV_FLAG);
678 }
679 return exportKeys(patterns, keyData, mode|ExportSecret);
680 }
681
682 Error Context::startSecretKeyExport(const char *pattern, Data &keyData, unsigned int mode)
683 {
684 if (mode & ExportSecretSubkey) {
685 return Error::fromCode(GPG_ERR_INV_FLAG);
686 }
687 return startKeyExport(pattern, keyData, mode|ExportSecret);
688 }
689
690 Error Context::startSecretKeyExport(const char *patterns[], Data &keyData, unsigned int mode)
691 {
692 if (mode & ExportSecretSubkey) {
693 return Error::fromCode(GPG_ERR_INV_FLAG);
694 }
695 return startKeyExport(patterns, keyData, mode|ExportSecret);
696 }
697
698 Error Context::exportSecretSubkeys(const char *pattern, Data &keyData, unsigned int mode)
699 {
700 return exportKeys(pattern, keyData, mode|ExportSecretSubkey);
701 }
702
703 Error Context::exportSecretSubkeys(const char *patterns[], Data &keyData, unsigned int mode)
704 {
705 return exportKeys(patterns, keyData, mode|ExportSecretSubkey);
706 }
707
708 Error Context::startSecretSubkeyExport(const char *pattern, Data &keyData, unsigned int mode)
709 {
710 return startKeyExport(pattern, keyData, mode|ExportSecretSubkey);
711 }
712
713 Error Context::startSecretSubkeyExport(const char *patterns[], Data &keyData, unsigned int mode)
714 {
715 return startKeyExport(patterns, keyData, mode|ExportSecretSubkey);
626716 }
627717
628718 ImportResult Context::importKeys(const Data &data)
709799 return err;
710800 }
711801
802 ImportResult Context::importKeys(const std::vector<std::string> &keyIds)
803 {
804 d->lastop = Private::Import;
805 const StringsToCStrings keyids{keyIds};
806 d->lasterr = gpgme_op_receive_keys(d->ctx, keyids.c_strs());
807 return ImportResult(d->ctx, Error(d->lasterr));
808 }
809
810 Error Context::startKeyImport(const std::vector<std::string> &keyIds)
811 {
812 d->lastop = Private::Import;
813 const StringsToCStrings keyids{keyIds};
814 d->lasterr = gpgme_op_receive_keys_start(d->ctx, keyids.c_strs());
815 return Error(d->lasterr);
816 }
817
712818 ImportResult Context::importResult() const
713819 {
714820 if (d->lastop & Private::Import) {
17931899
17941900 GpgME::EngineInfo GpgME::engineInfo(GpgME::Protocol proto)
17951901 {
1796 gpgme_engine_info_t ei = nullptr;
1797 if (gpgme_get_engine_info(&ei)) {
1798 return EngineInfo();
1799 }
1800
1801 const gpgme_protocol_t p = proto == CMS ? GPGME_PROTOCOL_CMS : GPGME_PROTOCOL_OpenPGP ;
1802
1803 for (gpgme_engine_info_t i = ei ; i ; i = i->next) {
1804 if (i->protocol == p) {
1805 return EngineInfo(i);
1806 }
1807 }
1808
1809 return EngineInfo();
1902 return get_static_engine_info(proto == CMS ? GPGME_PROTOCOL_CMS : GPGME_PROTOCOL_OpenPGP);
18101903 }
18111904
18121905 const char *GpgME::dirInfo(const char *what)
18441937
18451938 GpgME::EngineInfo GpgME::engineInfo(GpgME::Engine engine)
18461939 {
1847 gpgme_engine_info_t ei = nullptr;
1848 if (gpgme_get_engine_info(&ei)) {
1849 return EngineInfo();
1850 }
1851
1852 const gpgme_protocol_t p = engine2protocol(engine);
1853
1854 for (gpgme_engine_info_t i = ei ; i ; i = i->next) {
1855 if (i->protocol == p) {
1856 return EngineInfo(i);
1857 }
1858 }
1859
1860 return EngineInfo();
1940 return get_static_engine_info(engine2protocol(engine));
18611941 }
18621942
18631943 GpgME::Error GpgME::checkEngine(GpgME::Engine engine)
3030 #include "verificationresult.h" // for Signature::Notation
3131
3232 #include <memory>
33 #include <string>
3334 #include <vector>
3435 #include <utility>
3536 #include <iosfwd>
188189 ExportSecret = 16,
189190 ExportRaw = 32,
190191 ExportPKCS12 = 64,
191 ExportNoUID = 128,
192 ExportNoUID = 128, // obsolete; has no effect
192193 ExportSSH = 256,
194 ExportSecretSubkey = 512,
193195 };
194196
195197 GpgME::Error exportPublicKeys(const char *pattern, Data &keyData);
196 GpgME::Error exportPublicKeys(const char *pattern, Data &keyData, unsigned int flags);
198 GpgME::Error exportPublicKeys(const char *pattern, Data &keyData, unsigned int mode);
197199 GpgME::Error exportPublicKeys(const char *pattern[], Data &keyData);
198 GpgME::Error exportPublicKeys(const char *pattern[], Data &keyData, unsigned int export_mode);
200 GpgME::Error exportPublicKeys(const char *pattern[], Data &keyData, unsigned int mode);
199201 GpgME::Error startPublicKeyExport(const char *pattern, Data &keyData);
200 GpgME::Error startPublicKeyExport(const char *pattern, Data &keyData, unsigned int flags);
202 GpgME::Error startPublicKeyExport(const char *pattern, Data &keyData, unsigned int mode);
201203 GpgME::Error startPublicKeyExport(const char *pattern[], Data &keyData);
202 GpgME::Error startPublicKeyExport(const char *pattern[], Data &keyData, unsigned int export_mode);
204 GpgME::Error startPublicKeyExport(const char *pattern[], Data &keyData, unsigned int mode);
205
206 GpgME::Error exportSecretKeys(const char *pattern, Data &keyData, unsigned int mode = ExportSecret);
207 GpgME::Error exportSecretKeys(const char *pattern[], Data &keyData, unsigned int mode = ExportSecret);
208 GpgME::Error startSecretKeyExport(const char *pattern, Data &keyData, unsigned int mode = ExportSecret);
209 GpgME::Error startSecretKeyExport(const char *pattern[], Data &keyData, unsigned int mode = ExportSecret);
210
211 GpgME::Error exportSecretSubkeys(const char *pattern, Data &keyData, unsigned int mode = ExportSecretSubkey);
212 GpgME::Error exportSecretSubkeys(const char *pattern[], Data &keyData, unsigned int mode = ExportSecretSubkey);
213 GpgME::Error startSecretSubkeyExport(const char *pattern, Data &keyData, unsigned int mode = ExportSecretSubkey);
214 GpgME::Error startSecretSubkeyExport(const char *pattern[], Data &keyData, unsigned int mode = ExportSecretSubkey);
215
216 // generic export functions; prefer using the specific public/secret key export functions
217 GpgME::Error exportKeys(const char *pattern, Data &keyData, unsigned int mode = ExportDefault);
218 GpgME::Error exportKeys(const char *pattern[], Data &keyData, unsigned int mode = ExportDefault);
219 GpgME::Error startKeyExport(const char *pattern, Data &keyData, unsigned int mode = ExportDefault);
220 GpgME::Error startKeyExport(const char *pattern[], Data &keyData, unsigned int mode = ExportDefault);
203221
204222 //
205223 // Key Import
207225
208226 ImportResult importKeys(const Data &data);
209227 ImportResult importKeys(const std::vector<Key> &keys);
228 ImportResult importKeys(const std::vector<std::string> &keyIds);
210229 GpgME::Error startKeyImport(const Data &data);
211230 GpgME::Error startKeyImport(const std::vector<Key> &keys);
231 GpgME::Error startKeyImport(const std::vector<std::string> &keyIds);
212232 ImportResult importResult() const;
213233
214234 //
9090 homedir, sysconfdir, bindir, libexecdir, libdir,
9191 datadir, localedir, agent-socket, agent-ssh-socket,
9292 dirmngr-socket, uiserver-socket, gpgconf-name, gpg-name,
93 gpgsm-name, g13-name
93 gpgsm-name, g13-name, keyboxd-name, agent-name, scdaemon-name,
94 dirmngr-name, pinentry-name, socketdir.
9495
9596 This may be extended in the future.
9697 */
0 /*
1 gpgaddexistingsubkeyeditinteractor.cpp - Edit Interactor to add an existing subkey to an OpenPGP key
2 Copyright (c) 2022 g10 Code GmbH
3 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
4
5 This file is part of GPGME++.
6
7 GPGME++ is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 GPGME++ is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with GPGME++; see the file COPYING.LIB. If not, write to the
19 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21 */
22
23 #ifdef HAVE_CONFIG_H
24 #include "config.h"
25 #endif
26
27 #include "gpgaddexistingsubkeyeditinteractor.h"
28
29 #include "error.h"
30
31 #include <gpgme.h>
32
33 // avoid conflict (msvc)
34 #ifdef ERROR
35 # undef ERROR
36 #endif
37
38 using namespace GpgME;
39
40 class GpgAddExistingSubkeyEditInteractor::Private
41 {
42 enum {
43 START = EditInteractor::StartState,
44 COMMAND,
45 ADD_EXISTING_KEY,
46 KEYGRIP,
47 FLAGS,
48 VALID,
49 KEY_CREATED,
50 QUIT,
51 SAVE,
52
53 ERROR = EditInteractor::ErrorState
54 };
55
56 GpgAddExistingSubkeyEditInteractor *const q = nullptr;
57
58 public:
59 Private(GpgAddExistingSubkeyEditInteractor *q, const std::string &keygrip)
60 : q{q}
61 , keygrip{keygrip}
62 {
63 }
64
65 const char *action(Error &err) const;
66 unsigned int nextState(unsigned int statusCode, const char *args, Error &err) const;
67
68 std::string keygrip;
69 std::string expiry;
70 };
71
72 const char *GpgAddExistingSubkeyEditInteractor::Private::action(Error &err) const
73 {
74 switch (q->state()) {
75 case COMMAND:
76 return "addkey";
77 case ADD_EXISTING_KEY:
78 return "keygrip";
79 case KEYGRIP:
80 return keygrip.c_str();
81 case FLAGS:
82 return "Q"; // do not toggle any usage flags
83 case VALID:
84 return expiry.empty() ? "0" : expiry.c_str();
85 case QUIT:
86 return "quit";
87 case SAVE:
88 return "Y";
89 case START:
90 case KEY_CREATED:
91 case ERROR:
92 return nullptr;
93 default:
94 err = Error::fromCode(GPG_ERR_GENERAL);
95 return nullptr;
96 }
97 }
98
99 unsigned int GpgAddExistingSubkeyEditInteractor::Private::nextState(unsigned int status, const char *args, Error &err) const
100 {
101 using std::strcmp;
102
103 static const Error GENERAL_ERROR = Error::fromCode(GPG_ERR_GENERAL);
104 static const Error NO_KEY_ERROR = Error::fromCode(GPG_ERR_NO_KEY);
105 static const Error INV_TIME_ERROR = Error::fromCode(GPG_ERR_INV_TIME);
106
107 if (q->needsNoResponse(status)) {
108 return q->state();
109 }
110
111 switch (q->state()) {
112 case START:
113 if (status == GPGME_STATUS_GET_LINE &&
114 strcmp(args, "keyedit.prompt") == 0) {
115 return COMMAND;
116 }
117 err = GENERAL_ERROR;
118 return ERROR;
119 case COMMAND:
120 if (status == GPGME_STATUS_GET_LINE &&
121 strcmp(args, "keygen.algo") == 0) {
122 return ADD_EXISTING_KEY;
123 }
124 err = GENERAL_ERROR;
125 return ERROR;
126 case ADD_EXISTING_KEY:
127 if (status == GPGME_STATUS_GET_LINE &&
128 strcmp(args, "keygen.keygrip") == 0) {
129 return KEYGRIP;
130 }
131 err = GENERAL_ERROR;
132 return ERROR;
133 case KEYGRIP:
134 if (status == GPGME_STATUS_GET_LINE &&
135 strcmp(args, "keygen.flags") == 0) {
136 return FLAGS;
137 } else if (status == GPGME_STATUS_GET_LINE &&
138 strcmp(args, "keygen.keygrip")) {
139 err = NO_KEY_ERROR;
140 return ERROR;
141 }
142 err = GENERAL_ERROR;
143 return ERROR;
144 case FLAGS:
145 if (status == GPGME_STATUS_GET_LINE &&
146 strcmp(args, "keygen.valid") == 0) {
147 return VALID;
148 }
149 err = GENERAL_ERROR;
150 return ERROR;
151 case VALID:
152 if (status == GPGME_STATUS_KEY_CREATED) {
153 return KEY_CREATED;
154 }
155 if (status == GPGME_STATUS_GET_LINE &&
156 strcmp(args, "keyedit.prompt") == 0) {
157 return QUIT;
158 } else if (status == GPGME_STATUS_GET_LINE &&
159 strcmp(args, "keygen.valid")) {
160 err = INV_TIME_ERROR;
161 return ERROR;
162 }
163 err = GENERAL_ERROR;
164 return ERROR;
165 case KEY_CREATED:
166 return QUIT;
167 case QUIT:
168 if (status == GPGME_STATUS_GET_BOOL &&
169 strcmp(args, "keyedit.save.okay") == 0) {
170 return SAVE;
171 }
172 err = GENERAL_ERROR;
173 return ERROR;
174 case ERROR:
175 if (status == GPGME_STATUS_GET_LINE &&
176 strcmp(args, "keyedit.prompt") == 0) {
177 return QUIT;
178 }
179 err = q->lastError();
180 return ERROR;
181 default:
182 err = GENERAL_ERROR;
183 return ERROR;
184 }
185 }
186
187 GpgAddExistingSubkeyEditInteractor::GpgAddExistingSubkeyEditInteractor(const std::string &keygrip)
188 : EditInteractor{}
189 , d{new Private{this, keygrip}}
190 {
191 }
192
193 GpgAddExistingSubkeyEditInteractor::~GpgAddExistingSubkeyEditInteractor() = default;
194
195 void GpgAddExistingSubkeyEditInteractor::setExpiry(const std::string &timeString)
196 {
197 d->expiry = timeString;
198 }
199
200 const char *GpgAddExistingSubkeyEditInteractor::action(Error &err) const
201 {
202 return d->action(err);
203 }
204
205 unsigned int GpgAddExistingSubkeyEditInteractor::nextState(unsigned int status, const char *args, Error &err) const
206 {
207 return d->nextState(status, args, err);
208 }
0 /*
1 gpgaddexistingsubkeyeditinteractor.h - Edit Interactor to add an existing subkey to an OpenPGP key
2 Copyright (c) 2022 g10 Code GmbH
3 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
4
5 This file is part of GPGME++.
6
7 GPGME++ is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 GPGME++ is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with GPGME++; see the file COPYING.LIB. If not, write to the
19 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21 */
22
23 #ifndef __GPGMEPP_GPGADDEXISTINGSUBKEYEDITINTERACTOR_H__
24 #define __GPGMEPP_GPGADDEXISTINGSUBKEYEDITINTERACTOR_H__
25
26 #include "editinteractor.h"
27
28 #include <memory>
29
30 namespace GpgME
31 {
32
33 class GPGMEPP_EXPORT GpgAddExistingSubkeyEditInteractor : public EditInteractor
34 {
35 public:
36 /** Edit interactor to add the existing subkey with keygrip \a keygrip
37 * to the key a key edit operation is working on.
38 **/
39 explicit GpgAddExistingSubkeyEditInteractor(const std::string &keygrip);
40 ~GpgAddExistingSubkeyEditInteractor() override;
41
42 /** Sets the validity period of the added subkey. Use "0" for no expiration
43 * or a simplified ISO date string ("yyyymmddThhmmss") for setting an
44 * expiration date. */
45 void setExpiry(const std::string &timeString);
46
47 private:
48 const char *action(Error &err) const override;
49 unsigned int nextState(unsigned int statusCode, const char *args, Error &err) const override;
50
51 private:
52 class Private;
53 const std::unique_ptr<Private> d;
54 };
55
56 } // namespace GpgME
57
58 #endif // __GPGMEPP_GPGADDEXISTINGSUBKEYEDITINTERACTOR_H__
4747 // We just need to handle the pointers in the structs:
4848 for (gpgme_import_status_t is = r.imports ; is ; is = is->next) {
4949 gpgme_import_status_t copy = new _gpgme_import_status(*is);
50 copy->fpr = strdup(is->fpr);
50 if (is->fpr) {
51 copy->fpr = strdup(is->fpr);
52 }
5153 copy->next = nullptr;
5254 imports.push_back(copy);
5355 }
0 /*
1 util.cpp - some internal helpers
2 Copyright (c) 2022 g10 Code GmbH
3 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
4
5 This file is part of GPGME++.
6
7 GPGME++ is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 GPGME++ is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with GPGME++; see the file COPYING.LIB. If not, write to the
19 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21 */
22
23 #ifdef HAVE_CONFIG_H
24 #include "config.h"
25 #endif
26
27 #include "util.h"
28
29 #include <functional>
30
31 StringsToCStrings::StringsToCStrings(const std::vector<std::string>& v)
32 : m_strings{v}
33 {
34 }
35
36 const char **StringsToCStrings::c_strs() const
37 {
38 if (m_cstrings.empty()) {
39 m_cstrings.reserve(m_strings.size() + 1);
40 std::transform(std::begin(m_strings), std::end(m_strings),
41 std::back_inserter(m_cstrings),
42 std::mem_fn(&std::string::c_str));
43 m_cstrings.push_back(nullptr);
44 }
45 return m_cstrings.data();
46 }
00 /*
1 util.h - some inline helper functions
1 util.h - some internal helpers
22 Copyright (C) 2004 Klarälvdalens Datakonsult AB
33 2016 Bundesamt für Sicherheit in der Informationstechnik
44 Software engineering by Intevation GmbH
5 Copyright (c) 2022 g10 Code GmbH
6 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
57
68 This file is part of GPGME++.
79
174176 return static_cast<gpgme_sig_notation_flags_t>(result);
175177 }
176178
179 /**
180 * Adapter for passing a vector of strings as NULL-terminated array of
181 * const char* to the C-interface of gpgme.
182 */
183 class StringsToCStrings
184 {
185 public:
186 explicit StringsToCStrings(const std::vector<std::string> &v);
187 ~StringsToCStrings() = default;
188
189 StringsToCStrings(const StringsToCStrings &) = delete;
190 StringsToCStrings &operator=(const StringsToCStrings &) = delete;
191 StringsToCStrings(StringsToCStrings &&) = delete;
192 StringsToCStrings &operator=(StringsToCStrings &&) = delete;
193
194 const char **c_strs() const;
195 private:
196 const std::vector<std::string> m_strings;
197 mutable std::vector<const char *> m_cstrings;
198 };
199
177200 #endif // __GPGMEPP_UTIL_H__
3131 run_getkey_SOURCES = run-getkey.cpp
3232 run_keylist_SOURCES = run-keylist.cpp
3333 run_verify_SOURCES = run-verify.cpp
34 if !HAVE_W32_SYSTEM
35 run_wkdlookup_SOURCES = run-wkdlookup.cpp
36 endif
3437
35 noinst_PROGRAMS = run-getkey run-keylist run-verify
38 if HAVE_W32_SYSTEM
39 programs_unix =
40 else
41 programs_unix = run-wkdlookup
42 endif
43
44 noinst_PROGRAMS = run-getkey run-keylist run-verify $(programs_unix)
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am - Makefile for GPGME Cpp tests.
17 # Copyright (C) 2018 Intevation GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://www.gnu.org/licenses/>.
33
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 noinst_PROGRAMS = run-getkey$(EXEEXT) run-keylist$(EXEEXT) \
109 run-verify$(EXEEXT) $(am__EXEEXT_1)
110 subdir = lang/cpp/tests
111 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
112 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
113 $(top_srcdir)/m4/ax_pkg_swig.m4 \
114 $(top_srcdir)/m4/ax_python_devel.m4 \
115 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
116 $(top_srcdir)/m4/gnupg-ttyname.m4 \
117 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
118 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
119 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
120 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
121 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
122 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
123 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
124 $(ACLOCAL_M4)
125 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
126 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
127 CONFIG_HEADER = $(top_builddir)/conf/config.h
128 CONFIG_CLEAN_FILES =
129 CONFIG_CLEAN_VPATH_FILES =
130 @HAVE_W32_SYSTEM_FALSE@am__EXEEXT_1 = run-wkdlookup$(EXEEXT)
131 PROGRAMS = $(noinst_PROGRAMS)
132 am_run_getkey_OBJECTS = run-getkey.$(OBJEXT)
133 run_getkey_OBJECTS = $(am_run_getkey_OBJECTS)
134 run_getkey_LDADD = $(LDADD)
135 run_getkey_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
136 ../../../src/libgpgme.la
137 AM_V_lt = $(am__v_lt_@AM_V@)
138 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
139 am__v_lt_0 = --silent
140 am__v_lt_1 =
141 am_run_keylist_OBJECTS = run-keylist.$(OBJEXT)
142 run_keylist_OBJECTS = $(am_run_keylist_OBJECTS)
143 run_keylist_LDADD = $(LDADD)
144 run_keylist_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
145 ../../../src/libgpgme.la
146 am_run_verify_OBJECTS = run-verify.$(OBJEXT)
147 run_verify_OBJECTS = $(am_run_verify_OBJECTS)
148 run_verify_LDADD = $(LDADD)
149 run_verify_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
150 ../../../src/libgpgme.la
151 am__run_wkdlookup_SOURCES_DIST = run-wkdlookup.cpp
152 @HAVE_W32_SYSTEM_FALSE@am_run_wkdlookup_OBJECTS = \
153 @HAVE_W32_SYSTEM_FALSE@ run-wkdlookup.$(OBJEXT)
154 run_wkdlookup_OBJECTS = $(am_run_wkdlookup_OBJECTS)
155 run_wkdlookup_LDADD = $(LDADD)
156 run_wkdlookup_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
157 ../../../src/libgpgme.la
158 AM_V_P = $(am__v_P_@AM_V@)
159 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
160 am__v_P_0 = false
161 am__v_P_1 = :
162 AM_V_GEN = $(am__v_GEN_@AM_V@)
163 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
164 am__v_GEN_0 = @echo " GEN " $@;
165 am__v_GEN_1 =
166 AM_V_at = $(am__v_at_@AM_V@)
167 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
168 am__v_at_0 = @
169 am__v_at_1 =
170 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
171 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
172 am__maybe_remake_depfiles = depfiles
173 am__depfiles_remade = ./$(DEPDIR)/run-getkey.Po \
174 ./$(DEPDIR)/run-keylist.Po ./$(DEPDIR)/run-verify.Po \
175 ./$(DEPDIR)/run-wkdlookup.Po
176 am__mv = mv -f
177 CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
178 $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
179 LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
180 $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \
181 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
182 $(AM_CXXFLAGS) $(CXXFLAGS)
183 AM_V_CXX = $(am__v_CXX_@AM_V@)
184 am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@)
185 am__v_CXX_0 = @echo " CXX " $@;
186 am__v_CXX_1 =
187 CXXLD = $(CXX)
188 CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
189 $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
190 $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
191 AM_V_CXXLD = $(am__v_CXXLD_@AM_V@)
192 am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@)
193 am__v_CXXLD_0 = @echo " CXXLD " $@;
194 am__v_CXXLD_1 =
195 SOURCES = $(run_getkey_SOURCES) $(run_keylist_SOURCES) \
196 $(run_verify_SOURCES) $(run_wkdlookup_SOURCES)
197 DIST_SOURCES = $(run_getkey_SOURCES) $(run_keylist_SOURCES) \
198 $(run_verify_SOURCES) $(am__run_wkdlookup_SOURCES_DIST)
199 am__can_run_installinfo = \
200 case $$AM_UPDATE_INFO_DIR in \
201 n|no|NO) false;; \
202 *) (install-info --version) >/dev/null 2>&1;; \
203 esac
204 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
205 # Read a list of newline-separated strings from the standard input,
206 # and print each of them once, without duplicates. Input order is
207 # *not* preserved.
208 am__uniquify_input = $(AWK) '\
209 BEGIN { nonempty = 0; } \
210 { items[$$0] = 1; nonempty = 1; } \
211 END { if (nonempty) { for (i in items) print i; }; } \
212 '
213 # Make sure the list of sources is unique. This is necessary because,
214 # e.g., the same source file might be shared among _SOURCES variables
215 # for different programs/libraries.
216 am__define_uniq_tagged_files = \
217 list='$(am__tagged_files)'; \
218 unique=`for i in $$list; do \
219 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
220 done | $(am__uniquify_input)`
221 ETAGS = etags
222 CTAGS = ctags
223 am__DIST_COMMON = $(srcdir)/Makefile.in \
224 $(top_srcdir)/build-aux/depcomp \
225 $(top_srcdir)/build-aux/mkinstalldirs README
226 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
227 ACLOCAL = @ACLOCAL@
228 AMTAR = @AMTAR@
229 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
230 AR = @AR@
231 AS = @AS@
232 AUTOCONF = @AUTOCONF@
233 AUTOHEADER = @AUTOHEADER@
234 AUTOMAKE = @AUTOMAKE@
235 AWK = @AWK@
236 BUILD_FILEVERSION = @BUILD_FILEVERSION@
237 BUILD_REVISION = @BUILD_REVISION@
238 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
239 BUILD_VERSION = @BUILD_VERSION@
240 CC = @CC@
241 CCDEPMODE = @CCDEPMODE@
242 CC_FOR_BUILD = @CC_FOR_BUILD@
243 CFLAGS = @CFLAGS@
244 CPP = @CPP@
245 CPPFLAGS = @CPPFLAGS@
246 CXX = @CXX@
247 CXXCPP = @CXXCPP@
248 CXXDEPMODE = @CXXDEPMODE@
249 CXXFLAGS = @CXXFLAGS@
250 CYGPATH_W = @CYGPATH_W@
251 DEFS = @DEFS@
252 DEPDIR = @DEPDIR@
253 DLLTOOL = @DLLTOOL@
254 DOXYGEN = @DOXYGEN@
255 DSYMUTIL = @DSYMUTIL@
256 DUMPBIN = @DUMPBIN@
257 ECHO_C = @ECHO_C@
258 ECHO_N = @ECHO_N@
259 ECHO_T = @ECHO_T@
260 EGREP = @EGREP@
261 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
262 EXEEXT = @EXEEXT@
263 FGREP = @FGREP@
264 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
265 GLIBC21 = @GLIBC21@
266 GLIB_CFLAGS = @GLIB_CFLAGS@
267 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
268 GLIB_LIBS = @GLIB_LIBS@
269 GLIB_MKENUMS = @GLIB_MKENUMS@
270 GOBJECT_QUERY = @GOBJECT_QUERY@
271 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
272 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
273 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
274 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
275 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
276 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
277 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
278 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
279 GPGME_QT_LIBS = @GPGME_QT_LIBS@
280 GPGRT_CONFIG = @GPGRT_CONFIG@
281 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
282 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
283 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
284 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
285 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
286 GRAPHVIZ = @GRAPHVIZ@
287 GREP = @GREP@
288 HAVE_CXX11 = @HAVE_CXX11@
289 HAVE_DOT = @HAVE_DOT@
290 INSTALL = @INSTALL@
291 INSTALL_DATA = @INSTALL_DATA@
292 INSTALL_PROGRAM = @INSTALL_PROGRAM@
293 INSTALL_SCRIPT = @INSTALL_SCRIPT@
294 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
295 LD = @LD@
296 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
297 LDFLAGS = @LDFLAGS@
298 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
299 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
300 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
301 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
302 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
303 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
304 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
305 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
306 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
307 LIBOBJS = @LIBOBJS@
308 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
309 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
310 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
311 LIBS = @LIBS@
312 LIBTOOL = @LIBTOOL@
313 LIPO = @LIPO@
314 LN_S = @LN_S@
315 LTLIBOBJS = @LTLIBOBJS@
316 MAINT = @MAINT@
317 MAKEINFO = @MAKEINFO@
318 MANIFEST_TOOL = @MANIFEST_TOOL@
319 MKDIR_P = @MKDIR_P@
320 MOC = @MOC@
321 MOC2 = @MOC2@
322 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
323 NM = @NM@
324 NMEDIT = @NMEDIT@
325 OBJDUMP = @OBJDUMP@
326 OBJEXT = @OBJEXT@
327 OTOOL = @OTOOL@
328 OTOOL64 = @OTOOL64@
329 PACKAGE = @PACKAGE@
330 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
331 PACKAGE_NAME = @PACKAGE_NAME@
332 PACKAGE_STRING = @PACKAGE_STRING@
333 PACKAGE_TARNAME = @PACKAGE_TARNAME@
334 PACKAGE_URL = @PACKAGE_URL@
335 PACKAGE_VERSION = @PACKAGE_VERSION@
336 PATH_SEPARATOR = @PATH_SEPARATOR@
337 PKG_CONFIG = @PKG_CONFIG@
338 PYTHON = @PYTHON@
339 PYTHONS = @PYTHONS@
340 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
341 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
342 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
343 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
344 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
345 PYTHON_PLATFORM = @PYTHON_PLATFORM@
346 PYTHON_PREFIX = @PYTHON_PREFIX@
347 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
348 PYTHON_VERSION = @PYTHON_VERSION@
349 QTCHOOSER = @QTCHOOSER@
350 RANLIB = @RANLIB@
351 RC = @RC@
352 SED = @SED@
353 SET_MAKE = @SET_MAKE@
354 SHELL = @SHELL@
355 STRIP = @STRIP@
356 SWIG = @SWIG@
357 SWIG_LIB = @SWIG_LIB@
358 SYSROOT = @SYSROOT@
359 VERSION = @VERSION@
360 VERSION_MAJOR = @VERSION_MAJOR@
361 VERSION_MICRO = @VERSION_MICRO@
362 VERSION_MINOR = @VERSION_MINOR@
363 VERSION_NUMBER = @VERSION_NUMBER@
364 abs_builddir = @abs_builddir@
365 abs_srcdir = @abs_srcdir@
366 abs_top_builddir = @abs_top_builddir@
367 abs_top_srcdir = @abs_top_srcdir@
368 ac_ct_AR = @ac_ct_AR@
369 ac_ct_CC = @ac_ct_CC@
370 ac_ct_CXX = @ac_ct_CXX@
371 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
372 am__include = @am__include@
373 am__leading_dot = @am__leading_dot@
374 am__quote = @am__quote@
375 am__tar = @am__tar@
376 am__untar = @am__untar@
377 bindir = @bindir@
378 build = @build@
379 build_alias = @build_alias@
380 build_cpu = @build_cpu@
381 build_os = @build_os@
382 build_vendor = @build_vendor@
383 builddir = @builddir@
384 datadir = @datadir@
385 datarootdir = @datarootdir@
386 docdir = @docdir@
387 dvidir = @dvidir@
388 emacs_local_vars_begin = @emacs_local_vars_begin@
389 emacs_local_vars_end = @emacs_local_vars_end@
390 emacs_local_vars_read_only = @emacs_local_vars_read_only@
391 exec_prefix = @exec_prefix@
392 host = @host@
393 host_alias = @host_alias@
394 host_cpu = @host_cpu@
395 host_os = @host_os@
396 host_vendor = @host_vendor@
397 htmldir = @htmldir@
398 includedir = @includedir@
399 infodir = @infodir@
400 install_sh = @install_sh@
401 libdir = @libdir@
402 libexecdir = @libexecdir@
403 localedir = @localedir@
404 localstatedir = @localstatedir@
405 mandir = @mandir@
406 mkdir_p = @mkdir_p@
407 oldincludedir = @oldincludedir@
408 pdfdir = @pdfdir@
409 pkgpyexecdir = @pkgpyexecdir@
410 pkgpythondir = @pkgpythondir@
411 prefix = @prefix@
412 program_transform_name = @program_transform_name@
413 psdir = @psdir@
414 pyexecdir = @pyexecdir@
415 pythondir = @pythondir@
416 runstatedir = @runstatedir@
417 sbindir = @sbindir@
418 sharedstatedir = @sharedstatedir@
419 srcdir = @srcdir@
420 sysconfdir = @sysconfdir@
421 target_alias = @target_alias@
422 top_build_prefix = @top_build_prefix@
423 top_builddir = @top_builddir@
424 top_srcdir = @top_srcdir@
425 AM_LDFLAGS = -no-install
426 LDADD = ../../cpp/src/libgpgmepp.la \
427 ../../../src/libgpgme.la @GPG_ERROR_LIBS@ \
428 @LDADD_FOR_TESTS_KLUDGE@ -lstdc++
429
430 AM_CPPFLAGS = -I$(top_srcdir)/lang/cpp/src -I$(top_builddir)/src \
431 @GPG_ERROR_CFLAGS@ @GPG_ERROR_CFLAGS@ \
432 @LIBASSUAN_CFLAGS@ -DBUILDING_GPGMEPP \
433 -DTOP_SRCDIR="$(top_srcdir)"
434
435 run_getkey_SOURCES = run-getkey.cpp
436 run_keylist_SOURCES = run-keylist.cpp
437 run_verify_SOURCES = run-verify.cpp
438 @HAVE_W32_SYSTEM_FALSE@run_wkdlookup_SOURCES = run-wkdlookup.cpp
439 @HAVE_W32_SYSTEM_FALSE@programs_unix = run-wkdlookup
440 @HAVE_W32_SYSTEM_TRUE@programs_unix =
441 all: all-am
442
443 .SUFFIXES:
444 .SUFFIXES: .cpp .lo .o .obj
445 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
446 @for dep in $?; do \
447 case '$(am__configure_deps)' in \
448 *$$dep*) \
449 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
450 && { if test -f $@; then exit 0; else break; fi; }; \
451 exit 1;; \
452 esac; \
453 done; \
454 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/cpp/tests/Makefile'; \
455 $(am__cd) $(top_srcdir) && \
456 $(AUTOMAKE) --gnu lang/cpp/tests/Makefile
457 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
458 @case '$?' in \
459 *config.status*) \
460 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
461 *) \
462 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
463 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
464 esac;
465
466 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
467 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
468
469 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
470 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
471 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
472 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
473 $(am__aclocal_m4_deps):
474
475 clean-noinstPROGRAMS:
476 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
477 echo " rm -f" $$list; \
478 rm -f $$list || exit $$?; \
479 test -n "$(EXEEXT)" || exit 0; \
480 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
481 echo " rm -f" $$list; \
482 rm -f $$list
483
484 run-getkey$(EXEEXT): $(run_getkey_OBJECTS) $(run_getkey_DEPENDENCIES) $(EXTRA_run_getkey_DEPENDENCIES)
485 @rm -f run-getkey$(EXEEXT)
486 $(AM_V_CXXLD)$(CXXLINK) $(run_getkey_OBJECTS) $(run_getkey_LDADD) $(LIBS)
487
488 run-keylist$(EXEEXT): $(run_keylist_OBJECTS) $(run_keylist_DEPENDENCIES) $(EXTRA_run_keylist_DEPENDENCIES)
489 @rm -f run-keylist$(EXEEXT)
490 $(AM_V_CXXLD)$(CXXLINK) $(run_keylist_OBJECTS) $(run_keylist_LDADD) $(LIBS)
491
492 run-verify$(EXEEXT): $(run_verify_OBJECTS) $(run_verify_DEPENDENCIES) $(EXTRA_run_verify_DEPENDENCIES)
493 @rm -f run-verify$(EXEEXT)
494 $(AM_V_CXXLD)$(CXXLINK) $(run_verify_OBJECTS) $(run_verify_LDADD) $(LIBS)
495
496 run-wkdlookup$(EXEEXT): $(run_wkdlookup_OBJECTS) $(run_wkdlookup_DEPENDENCIES) $(EXTRA_run_wkdlookup_DEPENDENCIES)
497 @rm -f run-wkdlookup$(EXEEXT)
498 $(AM_V_CXXLD)$(CXXLINK) $(run_wkdlookup_OBJECTS) $(run_wkdlookup_LDADD) $(LIBS)
499
500 mostlyclean-compile:
501 -rm -f *.$(OBJEXT)
502
503 distclean-compile:
504 -rm -f *.tab.c
505
506 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-getkey.Po@am__quote@ # am--include-marker
507 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-keylist.Po@am__quote@ # am--include-marker
508 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-verify.Po@am__quote@ # am--include-marker
509 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-wkdlookup.Po@am__quote@ # am--include-marker
510
511 $(am__depfiles_remade):
512 @$(MKDIR_P) $(@D)
513 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
514
515 am--depfiles: $(am__depfiles_remade)
516
517 .cpp.o:
518 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
519 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
520 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
521 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
522 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $<
523
524 .cpp.obj:
525 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
526 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
527 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
528 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
529 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
530
531 .cpp.lo:
532 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
533 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
534 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
535 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
536 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $<
537
538 mostlyclean-libtool:
539 -rm -f *.lo
540
541 clean-libtool:
542 -rm -rf .libs _libs
543
544 ID: $(am__tagged_files)
545 $(am__define_uniq_tagged_files); mkid -fID $$unique
546 tags: tags-am
547 TAGS: tags
548
549 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
550 set x; \
551 here=`pwd`; \
552 $(am__define_uniq_tagged_files); \
553 shift; \
554 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
555 test -n "$$unique" || unique=$$empty_fix; \
556 if test $$# -gt 0; then \
557 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
558 "$$@" $$unique; \
559 else \
560 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
561 $$unique; \
562 fi; \
563 fi
564 ctags: ctags-am
565
566 CTAGS: ctags
567 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
568 $(am__define_uniq_tagged_files); \
569 test -z "$(CTAGS_ARGS)$$unique" \
570 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
571 $$unique
572
573 GTAGS:
574 here=`$(am__cd) $(top_builddir) && pwd` \
575 && $(am__cd) $(top_srcdir) \
576 && gtags -i $(GTAGS_ARGS) "$$here"
577 cscopelist: cscopelist-am
578
579 cscopelist-am: $(am__tagged_files)
580 list='$(am__tagged_files)'; \
581 case "$(srcdir)" in \
582 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
583 *) sdir=$(subdir)/$(srcdir) ;; \
584 esac; \
585 for i in $$list; do \
586 if test -f "$$i"; then \
587 echo "$(subdir)/$$i"; \
588 else \
589 echo "$$sdir/$$i"; \
590 fi; \
591 done >> $(top_builddir)/cscope.files
592
593 distclean-tags:
594 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
595
596 distdir: $(BUILT_SOURCES)
597 $(MAKE) $(AM_MAKEFLAGS) distdir-am
598
599 distdir-am: $(DISTFILES)
600 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
601 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
602 list='$(DISTFILES)'; \
603 dist_files=`for file in $$list; do echo $$file; done | \
604 sed -e "s|^$$srcdirstrip/||;t" \
605 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
606 case $$dist_files in \
607 */*) $(MKDIR_P) `echo "$$dist_files" | \
608 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
609 sort -u` ;; \
610 esac; \
611 for file in $$dist_files; do \
612 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
613 if test -d $$d/$$file; then \
614 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
615 if test -d "$(distdir)/$$file"; then \
616 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
617 fi; \
618 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
619 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
620 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
621 fi; \
622 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
623 else \
624 test -f "$(distdir)/$$file" \
625 || cp -p $$d/$$file "$(distdir)/$$file" \
626 || exit 1; \
627 fi; \
628 done
629 check-am: all-am
630 check: check-am
631 all-am: Makefile $(PROGRAMS)
632 installdirs:
633 install: install-am
634 install-exec: install-exec-am
635 install-data: install-data-am
636 uninstall: uninstall-am
637
638 install-am: all-am
639 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
640
641 installcheck: installcheck-am
642 install-strip:
643 if test -z '$(STRIP)'; then \
644 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
645 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
646 install; \
647 else \
648 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
649 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
650 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
651 fi
652 mostlyclean-generic:
653
654 clean-generic:
655
656 distclean-generic:
657 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
658 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
659
660 maintainer-clean-generic:
661 @echo "This command is intended for maintainers to use"
662 @echo "it deletes files that may require special tools to rebuild."
663 clean: clean-am
664
665 clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \
666 mostlyclean-am
667
668 distclean: distclean-am
669 -rm -f ./$(DEPDIR)/run-getkey.Po
670 -rm -f ./$(DEPDIR)/run-keylist.Po
671 -rm -f ./$(DEPDIR)/run-verify.Po
672 -rm -f ./$(DEPDIR)/run-wkdlookup.Po
673 -rm -f Makefile
674 distclean-am: clean-am distclean-compile distclean-generic \
675 distclean-tags
676
677 dvi: dvi-am
678
679 dvi-am:
680
681 html: html-am
682
683 html-am:
684
685 info: info-am
686
687 info-am:
688
689 install-data-am:
690
691 install-dvi: install-dvi-am
692
693 install-dvi-am:
694
695 install-exec-am:
696
697 install-html: install-html-am
698
699 install-html-am:
700
701 install-info: install-info-am
702
703 install-info-am:
704
705 install-man:
706
707 install-pdf: install-pdf-am
708
709 install-pdf-am:
710
711 install-ps: install-ps-am
712
713 install-ps-am:
714
715 installcheck-am:
716
717 maintainer-clean: maintainer-clean-am
718 -rm -f ./$(DEPDIR)/run-getkey.Po
719 -rm -f ./$(DEPDIR)/run-keylist.Po
720 -rm -f ./$(DEPDIR)/run-verify.Po
721 -rm -f ./$(DEPDIR)/run-wkdlookup.Po
722 -rm -f Makefile
723 maintainer-clean-am: distclean-am maintainer-clean-generic
724
725 mostlyclean: mostlyclean-am
726
727 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
728 mostlyclean-libtool
729
730 pdf: pdf-am
731
732 pdf-am:
733
734 ps: ps-am
735
736 ps-am:
737
738 uninstall-am:
739
740 .MAKE: install-am install-strip
741
742 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
743 clean-generic clean-libtool clean-noinstPROGRAMS cscopelist-am \
744 ctags ctags-am distclean distclean-compile distclean-generic \
745 distclean-libtool distclean-tags distdir dvi dvi-am html \
746 html-am info info-am install install-am install-data \
747 install-data-am install-dvi install-dvi-am install-exec \
748 install-exec-am install-html install-html-am install-info \
749 install-info-am install-man install-pdf install-pdf-am \
750 install-ps install-ps-am install-strip installcheck \
751 installcheck-am installdirs maintainer-clean \
752 maintainer-clean-generic mostlyclean mostlyclean-compile \
753 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
754 tags tags-am uninstall uninstall-am
755
756 .PRECIOUS: Makefile
757
758
759 # Tell versions [3.59,3.63) of GNU make to not export all variables.
760 # Otherwise a system limit (for SysV at least) may be exceeded.
761 .NOEXPORT:
0 /*
1 run-wkdlookup.cpp
2
3 This file is part of GpgMEpp's test suite.
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 GPGME++ is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 GPGME++ is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with GPGME++; see the file COPYING.LIB. If not, write to the
19 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21 */
22
23 #ifdef HAVE_CONFIG_H
24 #include "config.h"
25 #endif
26
27 #include "context.h"
28 #include "data.h"
29 #include "defaultassuantransaction.h"
30 #include "key.h"
31
32 #include <memory>
33 #include <sstream>
34 #include <iostream>
35 #include <thread>
36
37 using namespace GpgME;
38
39 static int
40 show_usage (int ex)
41 {
42 fputs ("usage: run-wkdlookup <email address>\n\n"
43 , stderr);
44 exit (ex);
45 }
46
47 int
48 main (int argc, char **argv)
49 {
50 int last_argc = -1;
51
52 if (argc) {
53 argc--; argv++;
54 }
55
56 while (argc && last_argc != argc ) {
57 last_argc = argc;
58 if (!strcmp (*argv, "--")) {
59 argc--; argv++;
60 break;
61 } else if (!strcmp (*argv, "--help")) {
62 show_usage (0);
63 } else if (!strncmp (*argv, "--", 2)) {
64 show_usage (1);
65 }
66 }
67
68 if (argc != 1) {
69 show_usage (1);
70 }
71
72 const std::string email{*argv};
73
74 GpgME::initializeLibrary();
75 Error err;
76 auto ctx = std::unique_ptr<Context>{Context::createForEngine(AssuanEngine, &err)};
77 if (!ctx) {
78 std::cerr << "Failed to get context (Error: " << err.asString() << ")\n";
79 return -1;
80 }
81
82 const std::string dirmngrSocket = GpgME::dirInfo("dirmngr-socket");
83 if ((err = ctx->setEngineFileName(dirmngrSocket.c_str()))) {
84 std::cerr << "Failed to set engine file name (Error: " << err.asString() << ")\n";
85 return -1;
86 }
87 if ((err = ctx->setEngineHomeDirectory(""))) {
88 std::cerr << "Failed to set engine home directory (Error: " << err.asString() << ")\n";
89 return -1;
90 }
91
92 // try do connect to dirmngr
93 err = ctx->assuanTransact("GETINFO version");
94 if (err && err.code() != GPG_ERR_ASS_CONNECT_FAILED) {
95 std::cerr << "Failed to start assuan transaction (Error: " << err.asString() << ")\n";
96 return -1;
97 }
98 if (err.code() == GPG_ERR_ASS_CONNECT_FAILED) {
99 std::cerr << "Starting dirmngr ...\n";
100 auto spawnCtx = std::unique_ptr<Context>{Context::createForEngine(SpawnEngine, &err)};
101 if (!spawnCtx) {
102 std::cerr << "Failed to get context for spawn engine (Error: " << err.asString() << ")\n";
103 return -1;
104 }
105
106 const auto dirmngrProgram = GpgME::dirInfo("dirmngr-name");
107 const auto homedir = GpgME::dirInfo("homedir");
108 const char *argv[] = {
109 dirmngrProgram,
110 "--homedir",
111 homedir,
112 "--daemon",
113 NULL
114 };
115 auto ignoreIO = Data{Data::null};
116 err = spawnCtx->spawnAsync(dirmngrProgram, argv,
117 ignoreIO, ignoreIO, ignoreIO,
118 Context::SpawnDetached);
119 if (err) {
120 std::cerr << "Failed to start dirmngr (Error: " << err.asString() << ")\n";
121 return -1;
122 }
123
124 // wait for socket to become available
125 int cnt = 0;
126 do {
127 ++cnt;
128 std::cerr << "Waiting for dirmngr to start ...\n";
129 std::this_thread::sleep_for(std::chrono::milliseconds{250 * cnt});
130 err = ctx->assuanTransact("GETINFO version");
131 } while (err.code() == GPG_ERR_ASS_CONNECT_FAILED && cnt < 5);
132 }
133
134 const auto cmd = std::string{"WKD_GET "} + email;
135 err = ctx->assuanTransact(cmd.c_str());
136 if (err && err.code() != GPG_ERR_NO_NAME && err.code() != GPG_ERR_NO_DATA) {
137 std::cerr << "Error: WKD_GET returned " << err.asString() << "\n";
138 return -1;
139 }
140
141 const auto transaction = std::unique_ptr<DefaultAssuanTransaction>(dynamic_cast<DefaultAssuanTransaction*>(ctx->takeLastAssuanTransaction().release()));
142 const auto source = transaction->firstStatusLine("SOURCE");
143 const auto rawData = transaction->data();
144 if (rawData.size() == 0) {
145 std::cout << "No key found for " << email << "\n";
146 } else {
147 const auto data = GpgME::Data{rawData.c_str(), rawData.size()};
148 const auto keys = data.toKeys(GpgME::OpenPGP);
149 for (const auto &key : keys) {
150 std::cout << "Found key for " << email << " at " << source << ":\n" << key << "\n";
151 }
152 }
153
154 return 0;
155 }
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for gpgme.js.
17 # Copyright (C) 2018 Intevation GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # gpgme.js is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU General Public License as published by
23 # the Free Software Foundation; either version 2 of the License, or
24 # (at your option) any later version.
25 #
26 # gpgme.js is distributed in the hope that it will be useful,
27 # but WITHOUT ANY WARRANTY; without even the implied warranty of
28 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29 # GNU Lesser General Public License for more details.
30 #
31 # You should have received a copy of the GNU General Public License
32 # along with this program; if not, write to the Free Software
33 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
34 # 02111-1307, USA
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = lang/js/BrowserTestExtension
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
125 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
126 CONFIG_HEADER = $(top_builddir)/conf/config.h
127 CONFIG_CLEAN_FILES =
128 CONFIG_CLEAN_VPATH_FILES =
129 AM_V_P = $(am__v_P_@AM_V@)
130 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
131 am__v_P_0 = false
132 am__v_P_1 = :
133 AM_V_GEN = $(am__v_GEN_@AM_V@)
134 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
135 am__v_GEN_0 = @echo " GEN " $@;
136 am__v_GEN_1 =
137 AM_V_at = $(am__v_at_@AM_V@)
138 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
139 am__v_at_0 = @
140 am__v_at_1 =
141 SOURCES =
142 DIST_SOURCES =
143 am__can_run_installinfo = \
144 case $$AM_UPDATE_INFO_DIR in \
145 n|no|NO) false;; \
146 *) (install-info --version) >/dev/null 2>&1;; \
147 esac
148 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
149 am__DIST_COMMON = $(srcdir)/Makefile.in \
150 $(top_srcdir)/build-aux/mkinstalldirs
151 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
152 ACLOCAL = @ACLOCAL@
153 AMTAR = @AMTAR@
154 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
155 AR = @AR@
156 AS = @AS@
157 AUTOCONF = @AUTOCONF@
158 AUTOHEADER = @AUTOHEADER@
159 AUTOMAKE = @AUTOMAKE@
160 AWK = @AWK@
161 BUILD_FILEVERSION = @BUILD_FILEVERSION@
162 BUILD_REVISION = @BUILD_REVISION@
163 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
164 BUILD_VERSION = @BUILD_VERSION@
165 CC = @CC@
166 CCDEPMODE = @CCDEPMODE@
167 CC_FOR_BUILD = @CC_FOR_BUILD@
168 CFLAGS = @CFLAGS@
169 CPP = @CPP@
170 CPPFLAGS = @CPPFLAGS@
171 CXX = @CXX@
172 CXXCPP = @CXXCPP@
173 CXXDEPMODE = @CXXDEPMODE@
174 CXXFLAGS = @CXXFLAGS@
175 CYGPATH_W = @CYGPATH_W@
176 DEFS = @DEFS@
177 DEPDIR = @DEPDIR@
178 DLLTOOL = @DLLTOOL@
179 DOXYGEN = @DOXYGEN@
180 DSYMUTIL = @DSYMUTIL@
181 DUMPBIN = @DUMPBIN@
182 ECHO_C = @ECHO_C@
183 ECHO_N = @ECHO_N@
184 ECHO_T = @ECHO_T@
185 EGREP = @EGREP@
186 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
187 EXEEXT = @EXEEXT@
188 FGREP = @FGREP@
189 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
190 GLIBC21 = @GLIBC21@
191 GLIB_CFLAGS = @GLIB_CFLAGS@
192 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
193 GLIB_LIBS = @GLIB_LIBS@
194 GLIB_MKENUMS = @GLIB_MKENUMS@
195 GOBJECT_QUERY = @GOBJECT_QUERY@
196 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
197 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
198 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
199 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
200 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
201 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
202 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
203 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
204 GPGME_QT_LIBS = @GPGME_QT_LIBS@
205 GPGRT_CONFIG = @GPGRT_CONFIG@
206 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
207 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
208 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
209 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
210 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
211 GRAPHVIZ = @GRAPHVIZ@
212 GREP = @GREP@
213 HAVE_CXX11 = @HAVE_CXX11@
214 HAVE_DOT = @HAVE_DOT@
215 INSTALL = @INSTALL@
216 INSTALL_DATA = @INSTALL_DATA@
217 INSTALL_PROGRAM = @INSTALL_PROGRAM@
218 INSTALL_SCRIPT = @INSTALL_SCRIPT@
219 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
220 LD = @LD@
221 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
222 LDFLAGS = @LDFLAGS@
223 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
224 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
225 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
226 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
227 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
228 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
229 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
230 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
231 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
232 LIBOBJS = @LIBOBJS@
233 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
234 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
235 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
236 LIBS = @LIBS@
237 LIBTOOL = @LIBTOOL@
238 LIPO = @LIPO@
239 LN_S = @LN_S@
240 LTLIBOBJS = @LTLIBOBJS@
241 MAINT = @MAINT@
242 MAKEINFO = @MAKEINFO@
243 MANIFEST_TOOL = @MANIFEST_TOOL@
244 MKDIR_P = @MKDIR_P@
245 MOC = @MOC@
246 MOC2 = @MOC2@
247 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
248 NM = @NM@
249 NMEDIT = @NMEDIT@
250 OBJDUMP = @OBJDUMP@
251 OBJEXT = @OBJEXT@
252 OTOOL = @OTOOL@
253 OTOOL64 = @OTOOL64@
254 PACKAGE = @PACKAGE@
255 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
256 PACKAGE_NAME = @PACKAGE_NAME@
257 PACKAGE_STRING = @PACKAGE_STRING@
258 PACKAGE_TARNAME = @PACKAGE_TARNAME@
259 PACKAGE_URL = @PACKAGE_URL@
260 PACKAGE_VERSION = @PACKAGE_VERSION@
261 PATH_SEPARATOR = @PATH_SEPARATOR@
262 PKG_CONFIG = @PKG_CONFIG@
263 PYTHON = @PYTHON@
264 PYTHONS = @PYTHONS@
265 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
266 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
267 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
268 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
269 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
270 PYTHON_PLATFORM = @PYTHON_PLATFORM@
271 PYTHON_PREFIX = @PYTHON_PREFIX@
272 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
273 PYTHON_VERSION = @PYTHON_VERSION@
274 QTCHOOSER = @QTCHOOSER@
275 RANLIB = @RANLIB@
276 RC = @RC@
277 SED = @SED@
278 SET_MAKE = @SET_MAKE@
279 SHELL = @SHELL@
280 STRIP = @STRIP@
281 SWIG = @SWIG@
282 SWIG_LIB = @SWIG_LIB@
283 SYSROOT = @SYSROOT@
284 VERSION = @VERSION@
285 VERSION_MAJOR = @VERSION_MAJOR@
286 VERSION_MICRO = @VERSION_MICRO@
287 VERSION_MINOR = @VERSION_MINOR@
288 VERSION_NUMBER = @VERSION_NUMBER@
289 abs_builddir = @abs_builddir@
290 abs_srcdir = @abs_srcdir@
291 abs_top_builddir = @abs_top_builddir@
292 abs_top_srcdir = @abs_top_srcdir@
293 ac_ct_AR = @ac_ct_AR@
294 ac_ct_CC = @ac_ct_CC@
295 ac_ct_CXX = @ac_ct_CXX@
296 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
297 am__include = @am__include@
298 am__leading_dot = @am__leading_dot@
299 am__quote = @am__quote@
300 am__tar = @am__tar@
301 am__untar = @am__untar@
302 bindir = @bindir@
303 build = @build@
304 build_alias = @build_alias@
305 build_cpu = @build_cpu@
306 build_os = @build_os@
307 build_vendor = @build_vendor@
308 builddir = @builddir@
309 datadir = @datadir@
310 datarootdir = @datarootdir@
311 docdir = @docdir@
312 dvidir = @dvidir@
313 emacs_local_vars_begin = @emacs_local_vars_begin@
314 emacs_local_vars_end = @emacs_local_vars_end@
315 emacs_local_vars_read_only = @emacs_local_vars_read_only@
316 exec_prefix = @exec_prefix@
317 host = @host@
318 host_alias = @host_alias@
319 host_cpu = @host_cpu@
320 host_os = @host_os@
321 host_vendor = @host_vendor@
322 htmldir = @htmldir@
323 includedir = @includedir@
324 infodir = @infodir@
325 install_sh = @install_sh@
326 libdir = @libdir@
327 libexecdir = @libexecdir@
328 localedir = @localedir@
329 localstatedir = @localstatedir@
330 mandir = @mandir@
331 mkdir_p = @mkdir_p@
332 oldincludedir = @oldincludedir@
333 pdfdir = @pdfdir@
334 pkgpyexecdir = @pkgpyexecdir@
335 pkgpythondir = @pkgpythondir@
336 prefix = @prefix@
337 program_transform_name = @program_transform_name@
338 psdir = @psdir@
339 pyexecdir = @pyexecdir@
340 pythondir = @pythondir@
341 runstatedir = @runstatedir@
342 sbindir = @sbindir@
343 sharedstatedir = @sharedstatedir@
344 srcdir = @srcdir@
345 sysconfdir = @sysconfdir@
346 target_alias = @target_alias@
347 top_build_prefix = @top_build_prefix@
348 top_builddir = @top_builddir@
349 top_srcdir = @top_srcdir@
350 EXTRA_DIST = browsertest.html \
351 index.html \
352 longTests.html \
353 Makefile.am \
354 manifest.json \
355 popup.html \
356 popup.js \
357 runbrowsertest.js \
358 rununittests.js \
359 setup_testing.js \
360 testicon.png \
361 testkey2.pub \
362 testkey.pub \
363 testkey.sec \
364 tests/decryptTest.js \
365 tests/encryptDecryptTest.js \
366 tests/encryptTest.js \
367 tests/inputvalues.js \
368 tests/KeyImportExport.js \
369 tests/KeyInfos.js \
370 tests/longRunningTests.js \
371 tests/signTest.js \
372 tests/startup.js \
373 tests/verifyTest.js \
374 unittests.html
375
376 all: all-am
377
378 .SUFFIXES:
379 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
380 @for dep in $?; do \
381 case '$(am__configure_deps)' in \
382 *$$dep*) \
383 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
384 && { if test -f $@; then exit 0; else break; fi; }; \
385 exit 1;; \
386 esac; \
387 done; \
388 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/js/BrowserTestExtension/Makefile'; \
389 $(am__cd) $(top_srcdir) && \
390 $(AUTOMAKE) --gnu lang/js/BrowserTestExtension/Makefile
391 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
392 @case '$?' in \
393 *config.status*) \
394 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
395 *) \
396 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
397 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
398 esac;
399
400 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
401 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
402
403 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
404 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
405 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
406 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
407 $(am__aclocal_m4_deps):
408
409 mostlyclean-libtool:
410 -rm -f *.lo
411
412 clean-libtool:
413 -rm -rf .libs _libs
414 tags TAGS:
415
416 ctags CTAGS:
417
418 cscope cscopelist:
419
420
421 distdir: $(BUILT_SOURCES)
422 $(MAKE) $(AM_MAKEFLAGS) distdir-am
423
424 distdir-am: $(DISTFILES)
425 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
426 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
427 list='$(DISTFILES)'; \
428 dist_files=`for file in $$list; do echo $$file; done | \
429 sed -e "s|^$$srcdirstrip/||;t" \
430 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
431 case $$dist_files in \
432 */*) $(MKDIR_P) `echo "$$dist_files" | \
433 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
434 sort -u` ;; \
435 esac; \
436 for file in $$dist_files; do \
437 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
438 if test -d $$d/$$file; then \
439 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
440 if test -d "$(distdir)/$$file"; then \
441 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
442 fi; \
443 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
444 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
445 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
446 fi; \
447 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
448 else \
449 test -f "$(distdir)/$$file" \
450 || cp -p $$d/$$file "$(distdir)/$$file" \
451 || exit 1; \
452 fi; \
453 done
454 check-am: all-am
455 check: check-am
456 all-am: Makefile
457 installdirs:
458 install: install-am
459 install-exec: install-exec-am
460 install-data: install-data-am
461 uninstall: uninstall-am
462
463 install-am: all-am
464 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
465
466 installcheck: installcheck-am
467 install-strip:
468 if test -z '$(STRIP)'; then \
469 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
470 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
471 install; \
472 else \
473 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
474 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
475 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
476 fi
477 mostlyclean-generic:
478
479 clean-generic:
480
481 distclean-generic:
482 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
483 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
484
485 maintainer-clean-generic:
486 @echo "This command is intended for maintainers to use"
487 @echo "it deletes files that may require special tools to rebuild."
488 clean: clean-am
489
490 clean-am: clean-generic clean-libtool mostlyclean-am
491
492 distclean: distclean-am
493 -rm -f Makefile
494 distclean-am: clean-am distclean-generic
495
496 dvi: dvi-am
497
498 dvi-am:
499
500 html: html-am
501
502 html-am:
503
504 info: info-am
505
506 info-am:
507
508 install-data-am:
509
510 install-dvi: install-dvi-am
511
512 install-dvi-am:
513
514 install-exec-am:
515
516 install-html: install-html-am
517
518 install-html-am:
519
520 install-info: install-info-am
521
522 install-info-am:
523
524 install-man:
525
526 install-pdf: install-pdf-am
527
528 install-pdf-am:
529
530 install-ps: install-ps-am
531
532 install-ps-am:
533
534 installcheck-am:
535
536 maintainer-clean: maintainer-clean-am
537 -rm -f Makefile
538 maintainer-clean-am: distclean-am maintainer-clean-generic
539
540 mostlyclean: mostlyclean-am
541
542 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
543
544 pdf: pdf-am
545
546 pdf-am:
547
548 ps: ps-am
549
550 ps-am:
551
552 uninstall-am:
553
554 .MAKE: install-am install-strip
555
556 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
557 cscopelist-am ctags-am distclean distclean-generic \
558 distclean-libtool distdir dvi dvi-am html html-am info info-am \
559 install install-am install-data install-data-am install-dvi \
560 install-dvi-am install-exec install-exec-am install-html \
561 install-html-am install-info install-info-am install-man \
562 install-pdf install-pdf-am install-ps install-ps-am \
563 install-strip installcheck installcheck-am installdirs \
564 maintainer-clean maintainer-clean-generic mostlyclean \
565 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
566 tags-am uninstall uninstall-am
567
568 .PRECIOUS: Makefile
569
570
571 # Tell versions [3.59,3.63) of GNU make to not export all variables.
572 # Otherwise a system limit (for SysV at least) may be exceeded.
573 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for gpgme.js.
17 # Copyright (C) 2018 Intevation GmbH
18 #
19 # This file is part of gpgme.js.
20 #
21 # gpgme.js is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU General Public License as published by
23 # the Free Software Foundation; either version 2 of the License, or
24 # (at your option) any later version.
25 #
26 # gpgme.js is distributed in the hope that it will be useful,
27 # but WITHOUT ANY WARRANTY; without even the implied warranty of
28 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29 # GNU Lesser General Public License for more details.
30 #
31 # You should have received a copy of the GNU General Public License
32 # along with this program; if not, write to the Free Software
33 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
34 # 02111-1307, USA
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = lang/js/DemoExtension
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
125 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
126 CONFIG_HEADER = $(top_builddir)/conf/config.h
127 CONFIG_CLEAN_FILES =
128 CONFIG_CLEAN_VPATH_FILES =
129 AM_V_P = $(am__v_P_@AM_V@)
130 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
131 am__v_P_0 = false
132 am__v_P_1 = :
133 AM_V_GEN = $(am__v_GEN_@AM_V@)
134 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
135 am__v_GEN_0 = @echo " GEN " $@;
136 am__v_GEN_1 =
137 AM_V_at = $(am__v_at_@AM_V@)
138 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
139 am__v_at_0 = @
140 am__v_at_1 =
141 SOURCES =
142 DIST_SOURCES =
143 am__can_run_installinfo = \
144 case $$AM_UPDATE_INFO_DIR in \
145 n|no|NO) false;; \
146 *) (install-info --version) >/dev/null 2>&1;; \
147 esac
148 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
149 am__DIST_COMMON = $(srcdir)/Makefile.in \
150 $(top_srcdir)/build-aux/mkinstalldirs
151 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
152 ACLOCAL = @ACLOCAL@
153 AMTAR = @AMTAR@
154 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
155 AR = @AR@
156 AS = @AS@
157 AUTOCONF = @AUTOCONF@
158 AUTOHEADER = @AUTOHEADER@
159 AUTOMAKE = @AUTOMAKE@
160 AWK = @AWK@
161 BUILD_FILEVERSION = @BUILD_FILEVERSION@
162 BUILD_REVISION = @BUILD_REVISION@
163 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
164 BUILD_VERSION = @BUILD_VERSION@
165 CC = @CC@
166 CCDEPMODE = @CCDEPMODE@
167 CC_FOR_BUILD = @CC_FOR_BUILD@
168 CFLAGS = @CFLAGS@
169 CPP = @CPP@
170 CPPFLAGS = @CPPFLAGS@
171 CXX = @CXX@
172 CXXCPP = @CXXCPP@
173 CXXDEPMODE = @CXXDEPMODE@
174 CXXFLAGS = @CXXFLAGS@
175 CYGPATH_W = @CYGPATH_W@
176 DEFS = @DEFS@
177 DEPDIR = @DEPDIR@
178 DLLTOOL = @DLLTOOL@
179 DOXYGEN = @DOXYGEN@
180 DSYMUTIL = @DSYMUTIL@
181 DUMPBIN = @DUMPBIN@
182 ECHO_C = @ECHO_C@
183 ECHO_N = @ECHO_N@
184 ECHO_T = @ECHO_T@
185 EGREP = @EGREP@
186 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
187 EXEEXT = @EXEEXT@
188 FGREP = @FGREP@
189 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
190 GLIBC21 = @GLIBC21@
191 GLIB_CFLAGS = @GLIB_CFLAGS@
192 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
193 GLIB_LIBS = @GLIB_LIBS@
194 GLIB_MKENUMS = @GLIB_MKENUMS@
195 GOBJECT_QUERY = @GOBJECT_QUERY@
196 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
197 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
198 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
199 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
200 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
201 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
202 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
203 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
204 GPGME_QT_LIBS = @GPGME_QT_LIBS@
205 GPGRT_CONFIG = @GPGRT_CONFIG@
206 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
207 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
208 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
209 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
210 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
211 GRAPHVIZ = @GRAPHVIZ@
212 GREP = @GREP@
213 HAVE_CXX11 = @HAVE_CXX11@
214 HAVE_DOT = @HAVE_DOT@
215 INSTALL = @INSTALL@
216 INSTALL_DATA = @INSTALL_DATA@
217 INSTALL_PROGRAM = @INSTALL_PROGRAM@
218 INSTALL_SCRIPT = @INSTALL_SCRIPT@
219 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
220 LD = @LD@
221 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
222 LDFLAGS = @LDFLAGS@
223 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
224 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
225 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
226 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
227 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
228 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
229 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
230 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
231 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
232 LIBOBJS = @LIBOBJS@
233 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
234 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
235 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
236 LIBS = @LIBS@
237 LIBTOOL = @LIBTOOL@
238 LIPO = @LIPO@
239 LN_S = @LN_S@
240 LTLIBOBJS = @LTLIBOBJS@
241 MAINT = @MAINT@
242 MAKEINFO = @MAKEINFO@
243 MANIFEST_TOOL = @MANIFEST_TOOL@
244 MKDIR_P = @MKDIR_P@
245 MOC = @MOC@
246 MOC2 = @MOC2@
247 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
248 NM = @NM@
249 NMEDIT = @NMEDIT@
250 OBJDUMP = @OBJDUMP@
251 OBJEXT = @OBJEXT@
252 OTOOL = @OTOOL@
253 OTOOL64 = @OTOOL64@
254 PACKAGE = @PACKAGE@
255 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
256 PACKAGE_NAME = @PACKAGE_NAME@
257 PACKAGE_STRING = @PACKAGE_STRING@
258 PACKAGE_TARNAME = @PACKAGE_TARNAME@
259 PACKAGE_URL = @PACKAGE_URL@
260 PACKAGE_VERSION = @PACKAGE_VERSION@
261 PATH_SEPARATOR = @PATH_SEPARATOR@
262 PKG_CONFIG = @PKG_CONFIG@
263 PYTHON = @PYTHON@
264 PYTHONS = @PYTHONS@
265 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
266 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
267 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
268 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
269 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
270 PYTHON_PLATFORM = @PYTHON_PLATFORM@
271 PYTHON_PREFIX = @PYTHON_PREFIX@
272 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
273 PYTHON_VERSION = @PYTHON_VERSION@
274 QTCHOOSER = @QTCHOOSER@
275 RANLIB = @RANLIB@
276 RC = @RC@
277 SED = @SED@
278 SET_MAKE = @SET_MAKE@
279 SHELL = @SHELL@
280 STRIP = @STRIP@
281 SWIG = @SWIG@
282 SWIG_LIB = @SWIG_LIB@
283 SYSROOT = @SYSROOT@
284 VERSION = @VERSION@
285 VERSION_MAJOR = @VERSION_MAJOR@
286 VERSION_MICRO = @VERSION_MICRO@
287 VERSION_MINOR = @VERSION_MINOR@
288 VERSION_NUMBER = @VERSION_NUMBER@
289 abs_builddir = @abs_builddir@
290 abs_srcdir = @abs_srcdir@
291 abs_top_builddir = @abs_top_builddir@
292 abs_top_srcdir = @abs_top_srcdir@
293 ac_ct_AR = @ac_ct_AR@
294 ac_ct_CC = @ac_ct_CC@
295 ac_ct_CXX = @ac_ct_CXX@
296 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
297 am__include = @am__include@
298 am__leading_dot = @am__leading_dot@
299 am__quote = @am__quote@
300 am__tar = @am__tar@
301 am__untar = @am__untar@
302 bindir = @bindir@
303 build = @build@
304 build_alias = @build_alias@
305 build_cpu = @build_cpu@
306 build_os = @build_os@
307 build_vendor = @build_vendor@
308 builddir = @builddir@
309 datadir = @datadir@
310 datarootdir = @datarootdir@
311 docdir = @docdir@
312 dvidir = @dvidir@
313 emacs_local_vars_begin = @emacs_local_vars_begin@
314 emacs_local_vars_end = @emacs_local_vars_end@
315 emacs_local_vars_read_only = @emacs_local_vars_read_only@
316 exec_prefix = @exec_prefix@
317 host = @host@
318 host_alias = @host_alias@
319 host_cpu = @host_cpu@
320 host_os = @host_os@
321 host_vendor = @host_vendor@
322 htmldir = @htmldir@
323 includedir = @includedir@
324 infodir = @infodir@
325 install_sh = @install_sh@
326 libdir = @libdir@
327 libexecdir = @libexecdir@
328 localedir = @localedir@
329 localstatedir = @localstatedir@
330 mandir = @mandir@
331 mkdir_p = @mkdir_p@
332 oldincludedir = @oldincludedir@
333 pdfdir = @pdfdir@
334 pkgpyexecdir = @pkgpyexecdir@
335 pkgpythondir = @pkgpythondir@
336 prefix = @prefix@
337 program_transform_name = @program_transform_name@
338 psdir = @psdir@
339 pyexecdir = @pyexecdir@
340 pythondir = @pythondir@
341 runstatedir = @runstatedir@
342 sbindir = @sbindir@
343 sharedstatedir = @sharedstatedir@
344 srcdir = @srcdir@
345 sysconfdir = @sysconfdir@
346 target_alias = @target_alias@
347 top_build_prefix = @top_build_prefix@
348 top_builddir = @top_builddir@
349 top_srcdir = @top_srcdir@
350 EXTRA_DIST = manifest.json \
351 popup.html \
352 entry.js \
353 maindemo.js \
354 mainui.html \
355 testicon.png \
356 ui.css
357
358 all: all-am
359
360 .SUFFIXES:
361 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
362 @for dep in $?; do \
363 case '$(am__configure_deps)' in \
364 *$$dep*) \
365 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
366 && { if test -f $@; then exit 0; else break; fi; }; \
367 exit 1;; \
368 esac; \
369 done; \
370 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/js/DemoExtension/Makefile'; \
371 $(am__cd) $(top_srcdir) && \
372 $(AUTOMAKE) --gnu lang/js/DemoExtension/Makefile
373 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
374 @case '$?' in \
375 *config.status*) \
376 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
377 *) \
378 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
379 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
380 esac;
381
382 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
383 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
384
385 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
386 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
387 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
388 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
389 $(am__aclocal_m4_deps):
390
391 mostlyclean-libtool:
392 -rm -f *.lo
393
394 clean-libtool:
395 -rm -rf .libs _libs
396 tags TAGS:
397
398 ctags CTAGS:
399
400 cscope cscopelist:
401
402
403 distdir: $(BUILT_SOURCES)
404 $(MAKE) $(AM_MAKEFLAGS) distdir-am
405
406 distdir-am: $(DISTFILES)
407 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
408 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
409 list='$(DISTFILES)'; \
410 dist_files=`for file in $$list; do echo $$file; done | \
411 sed -e "s|^$$srcdirstrip/||;t" \
412 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
413 case $$dist_files in \
414 */*) $(MKDIR_P) `echo "$$dist_files" | \
415 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
416 sort -u` ;; \
417 esac; \
418 for file in $$dist_files; do \
419 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
420 if test -d $$d/$$file; then \
421 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
422 if test -d "$(distdir)/$$file"; then \
423 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
424 fi; \
425 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
426 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
427 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
428 fi; \
429 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
430 else \
431 test -f "$(distdir)/$$file" \
432 || cp -p $$d/$$file "$(distdir)/$$file" \
433 || exit 1; \
434 fi; \
435 done
436 check-am: all-am
437 check: check-am
438 all-am: Makefile
439 installdirs:
440 install: install-am
441 install-exec: install-exec-am
442 install-data: install-data-am
443 uninstall: uninstall-am
444
445 install-am: all-am
446 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
447
448 installcheck: installcheck-am
449 install-strip:
450 if test -z '$(STRIP)'; then \
451 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
452 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
453 install; \
454 else \
455 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
456 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
457 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
458 fi
459 mostlyclean-generic:
460
461 clean-generic:
462
463 distclean-generic:
464 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
465 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
466
467 maintainer-clean-generic:
468 @echo "This command is intended for maintainers to use"
469 @echo "it deletes files that may require special tools to rebuild."
470 clean: clean-am
471
472 clean-am: clean-generic clean-libtool mostlyclean-am
473
474 distclean: distclean-am
475 -rm -f Makefile
476 distclean-am: clean-am distclean-generic
477
478 dvi: dvi-am
479
480 dvi-am:
481
482 html: html-am
483
484 html-am:
485
486 info: info-am
487
488 info-am:
489
490 install-data-am:
491
492 install-dvi: install-dvi-am
493
494 install-dvi-am:
495
496 install-exec-am:
497
498 install-html: install-html-am
499
500 install-html-am:
501
502 install-info: install-info-am
503
504 install-info-am:
505
506 install-man:
507
508 install-pdf: install-pdf-am
509
510 install-pdf-am:
511
512 install-ps: install-ps-am
513
514 install-ps-am:
515
516 installcheck-am:
517
518 maintainer-clean: maintainer-clean-am
519 -rm -f Makefile
520 maintainer-clean-am: distclean-am maintainer-clean-generic
521
522 mostlyclean: mostlyclean-am
523
524 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
525
526 pdf: pdf-am
527
528 pdf-am:
529
530 ps: ps-am
531
532 ps-am:
533
534 uninstall-am:
535
536 .MAKE: install-am install-strip
537
538 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
539 cscopelist-am ctags-am distclean distclean-generic \
540 distclean-libtool distdir dvi dvi-am html html-am info info-am \
541 install install-am install-data install-data-am install-dvi \
542 install-dvi-am install-exec install-exec-am install-html \
543 install-html-am install-info install-info-am install-man \
544 install-pdf install-pdf-am install-ps install-ps-am \
545 install-strip installcheck installcheck-am installdirs \
546 maintainer-clean maintainer-clean-generic mostlyclean \
547 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
548 tags-am uninstall uninstall-am
549
550 .PRECIOUS: Makefile
551
552
553 # Tell versions [3.59,3.63) of GNU make to not export all variables.
554 # Otherwise a system limit (for SysV at least) may be exceeded.
555 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for gpgme.js.
17 # Copyright (C) 2018 Bundesamt für Sicherheit in der Informationstechnik
18 #
19 # This file is part of gpgme.js.
20 #
21 # gpgme.js is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU General Public License as published by
23 # the Free Software Foundation; either version 2 of the License, or
24 # (at your option) any later version.
25 #
26 # gpgme.js is distributed in the hope that it will be useful,
27 # but WITHOUT ANY WARRANTY; without even the implied warranty of
28 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29 # GNU Lesser General Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang/js
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES =
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
143 ctags-recursive dvi-recursive html-recursive info-recursive \
144 install-data-recursive install-dvi-recursive \
145 install-exec-recursive install-html-recursive \
146 install-info-recursive install-pdf-recursive \
147 install-ps-recursive install-recursive installcheck-recursive \
148 installdirs-recursive pdf-recursive ps-recursive \
149 tags-recursive uninstall-recursive
150 am__can_run_installinfo = \
151 case $$AM_UPDATE_INFO_DIR in \
152 n|no|NO) false;; \
153 *) (install-info --version) >/dev/null 2>&1;; \
154 esac
155 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
156 distclean-recursive maintainer-clean-recursive
157 am__recursive_targets = \
158 $(RECURSIVE_TARGETS) \
159 $(RECURSIVE_CLEAN_TARGETS) \
160 $(am__extra_recursive_targets)
161 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
162 distdir distdir-am
163 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
164 # Read a list of newline-separated strings from the standard input,
165 # and print each of them once, without duplicates. Input order is
166 # *not* preserved.
167 am__uniquify_input = $(AWK) '\
168 BEGIN { nonempty = 0; } \
169 { items[$$0] = 1; nonempty = 1; } \
170 END { if (nonempty) { for (i in items) print i; }; } \
171 '
172 # Make sure the list of sources is unique. This is necessary because,
173 # e.g., the same source file might be shared among _SOURCES variables
174 # for different programs/libraries.
175 am__define_uniq_tagged_files = \
176 list='$(am__tagged_files)'; \
177 unique=`for i in $$list; do \
178 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
179 done | $(am__uniquify_input)`
180 ETAGS = etags
181 CTAGS = ctags
182 DIST_SUBDIRS = $(SUBDIRS)
183 am__DIST_COMMON = $(srcdir)/Makefile.in \
184 $(top_srcdir)/build-aux/mkinstalldirs README
185 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
186 am__relativize = \
187 dir0=`pwd`; \
188 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
189 sed_rest='s,^[^/]*/*,,'; \
190 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
191 sed_butlast='s,/*[^/]*$$,,'; \
192 while test -n "$$dir1"; do \
193 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
194 if test "$$first" != "."; then \
195 if test "$$first" = ".."; then \
196 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
197 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
198 else \
199 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
200 if test "$$first2" = "$$first"; then \
201 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
202 else \
203 dir2="../$$dir2"; \
204 fi; \
205 dir0="$$dir0"/"$$first"; \
206 fi; \
207 fi; \
208 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
209 done; \
210 reldir="$$dir2"
211 ACLOCAL = @ACLOCAL@
212 AMTAR = @AMTAR@
213 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
214 AR = @AR@
215 AS = @AS@
216 AUTOCONF = @AUTOCONF@
217 AUTOHEADER = @AUTOHEADER@
218 AUTOMAKE = @AUTOMAKE@
219 AWK = @AWK@
220 BUILD_FILEVERSION = @BUILD_FILEVERSION@
221 BUILD_REVISION = @BUILD_REVISION@
222 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
223 BUILD_VERSION = @BUILD_VERSION@
224 CC = @CC@
225 CCDEPMODE = @CCDEPMODE@
226 CC_FOR_BUILD = @CC_FOR_BUILD@
227 CFLAGS = @CFLAGS@
228 CPP = @CPP@
229 CPPFLAGS = @CPPFLAGS@
230 CXX = @CXX@
231 CXXCPP = @CXXCPP@
232 CXXDEPMODE = @CXXDEPMODE@
233 CXXFLAGS = @CXXFLAGS@
234 CYGPATH_W = @CYGPATH_W@
235 DEFS = @DEFS@
236 DEPDIR = @DEPDIR@
237 DLLTOOL = @DLLTOOL@
238 DOXYGEN = @DOXYGEN@
239 DSYMUTIL = @DSYMUTIL@
240 DUMPBIN = @DUMPBIN@
241 ECHO_C = @ECHO_C@
242 ECHO_N = @ECHO_N@
243 ECHO_T = @ECHO_T@
244 EGREP = @EGREP@
245 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
246 EXEEXT = @EXEEXT@
247 FGREP = @FGREP@
248 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
249 GLIBC21 = @GLIBC21@
250 GLIB_CFLAGS = @GLIB_CFLAGS@
251 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
252 GLIB_LIBS = @GLIB_LIBS@
253 GLIB_MKENUMS = @GLIB_MKENUMS@
254 GOBJECT_QUERY = @GOBJECT_QUERY@
255 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
256 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
257 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
258 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
259 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
260 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
261 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
262 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
263 GPGME_QT_LIBS = @GPGME_QT_LIBS@
264 GPGRT_CONFIG = @GPGRT_CONFIG@
265 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
266 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
267 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
268 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
269 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
270 GRAPHVIZ = @GRAPHVIZ@
271 GREP = @GREP@
272 HAVE_CXX11 = @HAVE_CXX11@
273 HAVE_DOT = @HAVE_DOT@
274 INSTALL = @INSTALL@
275 INSTALL_DATA = @INSTALL_DATA@
276 INSTALL_PROGRAM = @INSTALL_PROGRAM@
277 INSTALL_SCRIPT = @INSTALL_SCRIPT@
278 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
279 LD = @LD@
280 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
281 LDFLAGS = @LDFLAGS@
282 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
283 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
284 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
285 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
286 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
287 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
288 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
289 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
290 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
291 LIBOBJS = @LIBOBJS@
292 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
293 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
294 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
295 LIBS = @LIBS@
296 LIBTOOL = @LIBTOOL@
297 LIPO = @LIPO@
298 LN_S = @LN_S@
299 LTLIBOBJS = @LTLIBOBJS@
300 MAINT = @MAINT@
301 MAKEINFO = @MAKEINFO@
302 MANIFEST_TOOL = @MANIFEST_TOOL@
303 MKDIR_P = @MKDIR_P@
304 MOC = @MOC@
305 MOC2 = @MOC2@
306 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
307 NM = @NM@
308 NMEDIT = @NMEDIT@
309 OBJDUMP = @OBJDUMP@
310 OBJEXT = @OBJEXT@
311 OTOOL = @OTOOL@
312 OTOOL64 = @OTOOL64@
313 PACKAGE = @PACKAGE@
314 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
315 PACKAGE_NAME = @PACKAGE_NAME@
316 PACKAGE_STRING = @PACKAGE_STRING@
317 PACKAGE_TARNAME = @PACKAGE_TARNAME@
318 PACKAGE_URL = @PACKAGE_URL@
319 PACKAGE_VERSION = @PACKAGE_VERSION@
320 PATH_SEPARATOR = @PATH_SEPARATOR@
321 PKG_CONFIG = @PKG_CONFIG@
322 PYTHON = @PYTHON@
323 PYTHONS = @PYTHONS@
324 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
325 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
326 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
327 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
328 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
329 PYTHON_PLATFORM = @PYTHON_PLATFORM@
330 PYTHON_PREFIX = @PYTHON_PREFIX@
331 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
332 PYTHON_VERSION = @PYTHON_VERSION@
333 QTCHOOSER = @QTCHOOSER@
334 RANLIB = @RANLIB@
335 RC = @RC@
336 SED = @SED@
337 SET_MAKE = @SET_MAKE@
338 SHELL = @SHELL@
339 STRIP = @STRIP@
340 SWIG = @SWIG@
341 SWIG_LIB = @SWIG_LIB@
342 SYSROOT = @SYSROOT@
343 VERSION = @VERSION@
344 VERSION_MAJOR = @VERSION_MAJOR@
345 VERSION_MICRO = @VERSION_MICRO@
346 VERSION_MINOR = @VERSION_MINOR@
347 VERSION_NUMBER = @VERSION_NUMBER@
348 abs_builddir = @abs_builddir@
349 abs_srcdir = @abs_srcdir@
350 abs_top_builddir = @abs_top_builddir@
351 abs_top_srcdir = @abs_top_srcdir@
352 ac_ct_AR = @ac_ct_AR@
353 ac_ct_CC = @ac_ct_CC@
354 ac_ct_CXX = @ac_ct_CXX@
355 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
356 am__include = @am__include@
357 am__leading_dot = @am__leading_dot@
358 am__quote = @am__quote@
359 am__tar = @am__tar@
360 am__untar = @am__untar@
361 bindir = @bindir@
362 build = @build@
363 build_alias = @build_alias@
364 build_cpu = @build_cpu@
365 build_os = @build_os@
366 build_vendor = @build_vendor@
367 builddir = @builddir@
368 datadir = @datadir@
369 datarootdir = @datarootdir@
370 docdir = @docdir@
371 dvidir = @dvidir@
372 emacs_local_vars_begin = @emacs_local_vars_begin@
373 emacs_local_vars_end = @emacs_local_vars_end@
374 emacs_local_vars_read_only = @emacs_local_vars_read_only@
375 exec_prefix = @exec_prefix@
376 host = @host@
377 host_alias = @host_alias@
378 host_cpu = @host_cpu@
379 host_os = @host_os@
380 host_vendor = @host_vendor@
381 htmldir = @htmldir@
382 includedir = @includedir@
383 infodir = @infodir@
384 install_sh = @install_sh@
385 libdir = @libdir@
386 libexecdir = @libexecdir@
387 localedir = @localedir@
388 localstatedir = @localstatedir@
389 mandir = @mandir@
390 mkdir_p = @mkdir_p@
391 oldincludedir = @oldincludedir@
392 pdfdir = @pdfdir@
393 pkgpyexecdir = @pkgpyexecdir@
394 pkgpythondir = @pkgpythondir@
395 prefix = @prefix@
396 program_transform_name = @program_transform_name@
397 psdir = @psdir@
398 pyexecdir = @pyexecdir@
399 pythondir = @pythondir@
400 runstatedir = @runstatedir@
401 sbindir = @sbindir@
402 sharedstatedir = @sharedstatedir@
403 srcdir = @srcdir@
404 sysconfdir = @sysconfdir@
405 target_alias = @target_alias@
406 top_build_prefix = @top_build_prefix@
407 top_builddir = @top_builddir@
408 top_srcdir = @top_srcdir@
409 SUBDIRS = src BrowserTestExtension DemoExtension
410 EXTRA_DIST = build_extensions.sh \
411 jsdoc.conf \
412 jsdoc_index.md \
413 .eslintrc.json \
414 package.json \
415 README \
416 unittest_inputvalues.js \
417 unittests.js \
418 webpack.conf.js \
419 webpack.conf_unittests.js
420
421 all: all-recursive
422
423 .SUFFIXES:
424 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
425 @for dep in $?; do \
426 case '$(am__configure_deps)' in \
427 *$$dep*) \
428 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
429 && { if test -f $@; then exit 0; else break; fi; }; \
430 exit 1;; \
431 esac; \
432 done; \
433 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/js/Makefile'; \
434 $(am__cd) $(top_srcdir) && \
435 $(AUTOMAKE) --gnu lang/js/Makefile
436 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
437 @case '$?' in \
438 *config.status*) \
439 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
440 *) \
441 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
442 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
443 esac;
444
445 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
446 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
447
448 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
449 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
450 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
451 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
452 $(am__aclocal_m4_deps):
453
454 mostlyclean-libtool:
455 -rm -f *.lo
456
457 clean-libtool:
458 -rm -rf .libs _libs
459
460 # This directory's subdirectories are mostly independent; you can cd
461 # into them and run 'make' without going through this Makefile.
462 # To change the values of 'make' variables: instead of editing Makefiles,
463 # (1) if the variable is set in 'config.status', edit 'config.status'
464 # (which will cause the Makefiles to be regenerated when you run 'make');
465 # (2) otherwise, pass the desired values on the 'make' command line.
466 $(am__recursive_targets):
467 @fail=; \
468 if $(am__make_keepgoing); then \
469 failcom='fail=yes'; \
470 else \
471 failcom='exit 1'; \
472 fi; \
473 dot_seen=no; \
474 target=`echo $@ | sed s/-recursive//`; \
475 case "$@" in \
476 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
477 *) list='$(SUBDIRS)' ;; \
478 esac; \
479 for subdir in $$list; do \
480 echo "Making $$target in $$subdir"; \
481 if test "$$subdir" = "."; then \
482 dot_seen=yes; \
483 local_target="$$target-am"; \
484 else \
485 local_target="$$target"; \
486 fi; \
487 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
488 || eval $$failcom; \
489 done; \
490 if test "$$dot_seen" = "no"; then \
491 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
492 fi; test -z "$$fail"
493
494 ID: $(am__tagged_files)
495 $(am__define_uniq_tagged_files); mkid -fID $$unique
496 tags: tags-recursive
497 TAGS: tags
498
499 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
500 set x; \
501 here=`pwd`; \
502 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
503 include_option=--etags-include; \
504 empty_fix=.; \
505 else \
506 include_option=--include; \
507 empty_fix=; \
508 fi; \
509 list='$(SUBDIRS)'; for subdir in $$list; do \
510 if test "$$subdir" = .; then :; else \
511 test ! -f $$subdir/TAGS || \
512 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
513 fi; \
514 done; \
515 $(am__define_uniq_tagged_files); \
516 shift; \
517 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
518 test -n "$$unique" || unique=$$empty_fix; \
519 if test $$# -gt 0; then \
520 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
521 "$$@" $$unique; \
522 else \
523 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
524 $$unique; \
525 fi; \
526 fi
527 ctags: ctags-recursive
528
529 CTAGS: ctags
530 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
531 $(am__define_uniq_tagged_files); \
532 test -z "$(CTAGS_ARGS)$$unique" \
533 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
534 $$unique
535
536 GTAGS:
537 here=`$(am__cd) $(top_builddir) && pwd` \
538 && $(am__cd) $(top_srcdir) \
539 && gtags -i $(GTAGS_ARGS) "$$here"
540 cscopelist: cscopelist-recursive
541
542 cscopelist-am: $(am__tagged_files)
543 list='$(am__tagged_files)'; \
544 case "$(srcdir)" in \
545 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
546 *) sdir=$(subdir)/$(srcdir) ;; \
547 esac; \
548 for i in $$list; do \
549 if test -f "$$i"; then \
550 echo "$(subdir)/$$i"; \
551 else \
552 echo "$$sdir/$$i"; \
553 fi; \
554 done >> $(top_builddir)/cscope.files
555
556 distclean-tags:
557 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
558
559 distdir: $(BUILT_SOURCES)
560 $(MAKE) $(AM_MAKEFLAGS) distdir-am
561
562 distdir-am: $(DISTFILES)
563 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
564 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
565 list='$(DISTFILES)'; \
566 dist_files=`for file in $$list; do echo $$file; done | \
567 sed -e "s|^$$srcdirstrip/||;t" \
568 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
569 case $$dist_files in \
570 */*) $(MKDIR_P) `echo "$$dist_files" | \
571 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
572 sort -u` ;; \
573 esac; \
574 for file in $$dist_files; do \
575 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
576 if test -d $$d/$$file; then \
577 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
578 if test -d "$(distdir)/$$file"; then \
579 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
580 fi; \
581 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
582 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
583 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
584 fi; \
585 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
586 else \
587 test -f "$(distdir)/$$file" \
588 || cp -p $$d/$$file "$(distdir)/$$file" \
589 || exit 1; \
590 fi; \
591 done
592 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
593 if test "$$subdir" = .; then :; else \
594 $(am__make_dryrun) \
595 || test -d "$(distdir)/$$subdir" \
596 || $(MKDIR_P) "$(distdir)/$$subdir" \
597 || exit 1; \
598 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
599 $(am__relativize); \
600 new_distdir=$$reldir; \
601 dir1=$$subdir; dir2="$(top_distdir)"; \
602 $(am__relativize); \
603 new_top_distdir=$$reldir; \
604 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
605 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
606 ($(am__cd) $$subdir && \
607 $(MAKE) $(AM_MAKEFLAGS) \
608 top_distdir="$$new_top_distdir" \
609 distdir="$$new_distdir" \
610 am__remove_distdir=: \
611 am__skip_length_check=: \
612 am__skip_mode_fix=: \
613 distdir) \
614 || exit 1; \
615 fi; \
616 done
617 check-am: all-am
618 check: check-recursive
619 all-am: Makefile
620 installdirs: installdirs-recursive
621 installdirs-am:
622 install: install-recursive
623 install-exec: install-exec-recursive
624 install-data: install-data-recursive
625 uninstall: uninstall-recursive
626
627 install-am: all-am
628 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
629
630 installcheck: installcheck-recursive
631 install-strip:
632 if test -z '$(STRIP)'; then \
633 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
634 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
635 install; \
636 else \
637 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
638 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
639 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
640 fi
641 mostlyclean-generic:
642
643 clean-generic:
644
645 distclean-generic:
646 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
647 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
648
649 maintainer-clean-generic:
650 @echo "This command is intended for maintainers to use"
651 @echo "it deletes files that may require special tools to rebuild."
652 clean: clean-recursive
653
654 clean-am: clean-generic clean-libtool mostlyclean-am
655
656 distclean: distclean-recursive
657 -rm -f Makefile
658 distclean-am: clean-am distclean-generic distclean-tags
659
660 dvi: dvi-recursive
661
662 dvi-am:
663
664 html: html-recursive
665
666 html-am:
667
668 info: info-recursive
669
670 info-am:
671
672 install-data-am:
673
674 install-dvi: install-dvi-recursive
675
676 install-dvi-am:
677
678 install-exec-am:
679
680 install-html: install-html-recursive
681
682 install-html-am:
683
684 install-info: install-info-recursive
685
686 install-info-am:
687
688 install-man:
689
690 install-pdf: install-pdf-recursive
691
692 install-pdf-am:
693
694 install-ps: install-ps-recursive
695
696 install-ps-am:
697
698 installcheck-am:
699
700 maintainer-clean: maintainer-clean-recursive
701 -rm -f Makefile
702 maintainer-clean-am: distclean-am maintainer-clean-generic
703
704 mostlyclean: mostlyclean-recursive
705
706 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
707
708 pdf: pdf-recursive
709
710 pdf-am:
711
712 ps: ps-recursive
713
714 ps-am:
715
716 uninstall-am:
717
718 .MAKE: $(am__recursive_targets) install-am install-strip
719
720 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
721 check-am clean clean-generic clean-libtool cscopelist-am ctags \
722 ctags-am distclean distclean-generic distclean-libtool \
723 distclean-tags distdir dvi dvi-am html html-am info info-am \
724 install install-am install-data install-data-am install-dvi \
725 install-dvi-am install-exec install-exec-am install-html \
726 install-html-am install-info install-info-am install-man \
727 install-pdf install-pdf-am install-ps install-ps-am \
728 install-strip installcheck installcheck-am installdirs \
729 installdirs-am maintainer-clean maintainer-clean-generic \
730 mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
731 ps ps-am tags tags-am uninstall uninstall-am
732
733 .PRECIOUS: Makefile
734
735
736 # Tell versions [3.59,3.63) of GNU make to not export all variables.
737 # Otherwise a system limit (for SysV at least) may be exceeded.
738 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for gpgme.js.
17 # Copyright (C) 2018 Intevation GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # gpgme.js is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU General Public License as published by
23 # the Free Software Foundation; either version 2 of the License, or
24 # (at your option) any later version.
25 #
26 # gpgme.js is distributed in the hope that it will be useful,
27 # but WITHOUT ANY WARRANTY; without even the implied warranty of
28 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29 # GNU Lesser General Public License for more details.
30 #
31 # You should have received a copy of the GNU General Public License
32 # along with this program; if not, write to the Free Software
33 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
34 # 02111-1307, USA
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = lang/js/src
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
125 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
126 CONFIG_HEADER = $(top_builddir)/conf/config.h
127 CONFIG_CLEAN_FILES =
128 CONFIG_CLEAN_VPATH_FILES =
129 AM_V_P = $(am__v_P_@AM_V@)
130 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
131 am__v_P_0 = false
132 am__v_P_1 = :
133 AM_V_GEN = $(am__v_GEN_@AM_V@)
134 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
135 am__v_GEN_0 = @echo " GEN " $@;
136 am__v_GEN_1 =
137 AM_V_at = $(am__v_at_@AM_V@)
138 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
139 am__v_at_0 = @
140 am__v_at_1 =
141 SOURCES =
142 DIST_SOURCES =
143 am__can_run_installinfo = \
144 case $$AM_UPDATE_INFO_DIR in \
145 n|no|NO) false;; \
146 *) (install-info --version) >/dev/null 2>&1;; \
147 esac
148 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
149 am__DIST_COMMON = $(srcdir)/Makefile.in \
150 $(top_srcdir)/build-aux/mkinstalldirs
151 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
152 ACLOCAL = @ACLOCAL@
153 AMTAR = @AMTAR@
154 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
155 AR = @AR@
156 AS = @AS@
157 AUTOCONF = @AUTOCONF@
158 AUTOHEADER = @AUTOHEADER@
159 AUTOMAKE = @AUTOMAKE@
160 AWK = @AWK@
161 BUILD_FILEVERSION = @BUILD_FILEVERSION@
162 BUILD_REVISION = @BUILD_REVISION@
163 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
164 BUILD_VERSION = @BUILD_VERSION@
165 CC = @CC@
166 CCDEPMODE = @CCDEPMODE@
167 CC_FOR_BUILD = @CC_FOR_BUILD@
168 CFLAGS = @CFLAGS@
169 CPP = @CPP@
170 CPPFLAGS = @CPPFLAGS@
171 CXX = @CXX@
172 CXXCPP = @CXXCPP@
173 CXXDEPMODE = @CXXDEPMODE@
174 CXXFLAGS = @CXXFLAGS@
175 CYGPATH_W = @CYGPATH_W@
176 DEFS = @DEFS@
177 DEPDIR = @DEPDIR@
178 DLLTOOL = @DLLTOOL@
179 DOXYGEN = @DOXYGEN@
180 DSYMUTIL = @DSYMUTIL@
181 DUMPBIN = @DUMPBIN@
182 ECHO_C = @ECHO_C@
183 ECHO_N = @ECHO_N@
184 ECHO_T = @ECHO_T@
185 EGREP = @EGREP@
186 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
187 EXEEXT = @EXEEXT@
188 FGREP = @FGREP@
189 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
190 GLIBC21 = @GLIBC21@
191 GLIB_CFLAGS = @GLIB_CFLAGS@
192 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
193 GLIB_LIBS = @GLIB_LIBS@
194 GLIB_MKENUMS = @GLIB_MKENUMS@
195 GOBJECT_QUERY = @GOBJECT_QUERY@
196 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
197 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
198 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
199 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
200 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
201 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
202 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
203 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
204 GPGME_QT_LIBS = @GPGME_QT_LIBS@
205 GPGRT_CONFIG = @GPGRT_CONFIG@
206 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
207 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
208 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
209 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
210 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
211 GRAPHVIZ = @GRAPHVIZ@
212 GREP = @GREP@
213 HAVE_CXX11 = @HAVE_CXX11@
214 HAVE_DOT = @HAVE_DOT@
215 INSTALL = @INSTALL@
216 INSTALL_DATA = @INSTALL_DATA@
217 INSTALL_PROGRAM = @INSTALL_PROGRAM@
218 INSTALL_SCRIPT = @INSTALL_SCRIPT@
219 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
220 LD = @LD@
221 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
222 LDFLAGS = @LDFLAGS@
223 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
224 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
225 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
226 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
227 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
228 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
229 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
230 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
231 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
232 LIBOBJS = @LIBOBJS@
233 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
234 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
235 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
236 LIBS = @LIBS@
237 LIBTOOL = @LIBTOOL@
238 LIPO = @LIPO@
239 LN_S = @LN_S@
240 LTLIBOBJS = @LTLIBOBJS@
241 MAINT = @MAINT@
242 MAKEINFO = @MAKEINFO@
243 MANIFEST_TOOL = @MANIFEST_TOOL@
244 MKDIR_P = @MKDIR_P@
245 MOC = @MOC@
246 MOC2 = @MOC2@
247 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
248 NM = @NM@
249 NMEDIT = @NMEDIT@
250 OBJDUMP = @OBJDUMP@
251 OBJEXT = @OBJEXT@
252 OTOOL = @OTOOL@
253 OTOOL64 = @OTOOL64@
254 PACKAGE = @PACKAGE@
255 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
256 PACKAGE_NAME = @PACKAGE_NAME@
257 PACKAGE_STRING = @PACKAGE_STRING@
258 PACKAGE_TARNAME = @PACKAGE_TARNAME@
259 PACKAGE_URL = @PACKAGE_URL@
260 PACKAGE_VERSION = @PACKAGE_VERSION@
261 PATH_SEPARATOR = @PATH_SEPARATOR@
262 PKG_CONFIG = @PKG_CONFIG@
263 PYTHON = @PYTHON@
264 PYTHONS = @PYTHONS@
265 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
266 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
267 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
268 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
269 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
270 PYTHON_PLATFORM = @PYTHON_PLATFORM@
271 PYTHON_PREFIX = @PYTHON_PREFIX@
272 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
273 PYTHON_VERSION = @PYTHON_VERSION@
274 QTCHOOSER = @QTCHOOSER@
275 RANLIB = @RANLIB@
276 RC = @RC@
277 SED = @SED@
278 SET_MAKE = @SET_MAKE@
279 SHELL = @SHELL@
280 STRIP = @STRIP@
281 SWIG = @SWIG@
282 SWIG_LIB = @SWIG_LIB@
283 SYSROOT = @SYSROOT@
284 VERSION = @VERSION@
285 VERSION_MAJOR = @VERSION_MAJOR@
286 VERSION_MICRO = @VERSION_MICRO@
287 VERSION_MINOR = @VERSION_MINOR@
288 VERSION_NUMBER = @VERSION_NUMBER@
289 abs_builddir = @abs_builddir@
290 abs_srcdir = @abs_srcdir@
291 abs_top_builddir = @abs_top_builddir@
292 abs_top_srcdir = @abs_top_srcdir@
293 ac_ct_AR = @ac_ct_AR@
294 ac_ct_CC = @ac_ct_CC@
295 ac_ct_CXX = @ac_ct_CXX@
296 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
297 am__include = @am__include@
298 am__leading_dot = @am__leading_dot@
299 am__quote = @am__quote@
300 am__tar = @am__tar@
301 am__untar = @am__untar@
302 bindir = @bindir@
303 build = @build@
304 build_alias = @build_alias@
305 build_cpu = @build_cpu@
306 build_os = @build_os@
307 build_vendor = @build_vendor@
308 builddir = @builddir@
309 datadir = @datadir@
310 datarootdir = @datarootdir@
311 docdir = @docdir@
312 dvidir = @dvidir@
313 emacs_local_vars_begin = @emacs_local_vars_begin@
314 emacs_local_vars_end = @emacs_local_vars_end@
315 emacs_local_vars_read_only = @emacs_local_vars_read_only@
316 exec_prefix = @exec_prefix@
317 host = @host@
318 host_alias = @host_alias@
319 host_cpu = @host_cpu@
320 host_os = @host_os@
321 host_vendor = @host_vendor@
322 htmldir = @htmldir@
323 includedir = @includedir@
324 infodir = @infodir@
325 install_sh = @install_sh@
326 libdir = @libdir@
327 libexecdir = @libexecdir@
328 localedir = @localedir@
329 localstatedir = @localstatedir@
330 mandir = @mandir@
331 mkdir_p = @mkdir_p@
332 oldincludedir = @oldincludedir@
333 pdfdir = @pdfdir@
334 pkgpyexecdir = @pkgpyexecdir@
335 pkgpythondir = @pkgpythondir@
336 prefix = @prefix@
337 program_transform_name = @program_transform_name@
338 psdir = @psdir@
339 pyexecdir = @pyexecdir@
340 pythondir = @pythondir@
341 runstatedir = @runstatedir@
342 sbindir = @sbindir@
343 sharedstatedir = @sharedstatedir@
344 srcdir = @srcdir@
345 sysconfdir = @sysconfdir@
346 target_alias = @target_alias@
347 top_build_prefix = @top_build_prefix@
348 top_builddir = @top_builddir@
349 top_srcdir = @top_srcdir@
350 EXTRA_DIST = Connection.js \
351 Errors.js \
352 gpgmejs.js \
353 Helpers.js \
354 index.js \
355 Key.js \
356 Keyring.js \
357 Message.js \
358 permittedOperations.js \
359 Signature.js
360
361 all: all-am
362
363 .SUFFIXES:
364 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
365 @for dep in $?; do \
366 case '$(am__configure_deps)' in \
367 *$$dep*) \
368 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
369 && { if test -f $@; then exit 0; else break; fi; }; \
370 exit 1;; \
371 esac; \
372 done; \
373 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/js/src/Makefile'; \
374 $(am__cd) $(top_srcdir) && \
375 $(AUTOMAKE) --gnu lang/js/src/Makefile
376 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
377 @case '$?' in \
378 *config.status*) \
379 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
380 *) \
381 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
382 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
383 esac;
384
385 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
386 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
387
388 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
389 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
390 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
391 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
392 $(am__aclocal_m4_deps):
393
394 mostlyclean-libtool:
395 -rm -f *.lo
396
397 clean-libtool:
398 -rm -rf .libs _libs
399 tags TAGS:
400
401 ctags CTAGS:
402
403 cscope cscopelist:
404
405
406 distdir: $(BUILT_SOURCES)
407 $(MAKE) $(AM_MAKEFLAGS) distdir-am
408
409 distdir-am: $(DISTFILES)
410 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
411 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
412 list='$(DISTFILES)'; \
413 dist_files=`for file in $$list; do echo $$file; done | \
414 sed -e "s|^$$srcdirstrip/||;t" \
415 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
416 case $$dist_files in \
417 */*) $(MKDIR_P) `echo "$$dist_files" | \
418 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
419 sort -u` ;; \
420 esac; \
421 for file in $$dist_files; do \
422 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
423 if test -d $$d/$$file; then \
424 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
425 if test -d "$(distdir)/$$file"; then \
426 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
427 fi; \
428 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
429 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
430 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
431 fi; \
432 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
433 else \
434 test -f "$(distdir)/$$file" \
435 || cp -p $$d/$$file "$(distdir)/$$file" \
436 || exit 1; \
437 fi; \
438 done
439 check-am: all-am
440 check: check-am
441 all-am: Makefile
442 installdirs:
443 install: install-am
444 install-exec: install-exec-am
445 install-data: install-data-am
446 uninstall: uninstall-am
447
448 install-am: all-am
449 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
450
451 installcheck: installcheck-am
452 install-strip:
453 if test -z '$(STRIP)'; then \
454 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
455 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
456 install; \
457 else \
458 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
459 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
460 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
461 fi
462 mostlyclean-generic:
463
464 clean-generic:
465
466 distclean-generic:
467 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
468 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
469
470 maintainer-clean-generic:
471 @echo "This command is intended for maintainers to use"
472 @echo "it deletes files that may require special tools to rebuild."
473 clean: clean-am
474
475 clean-am: clean-generic clean-libtool mostlyclean-am
476
477 distclean: distclean-am
478 -rm -f Makefile
479 distclean-am: clean-am distclean-generic
480
481 dvi: dvi-am
482
483 dvi-am:
484
485 html: html-am
486
487 html-am:
488
489 info: info-am
490
491 info-am:
492
493 install-data-am:
494
495 install-dvi: install-dvi-am
496
497 install-dvi-am:
498
499 install-exec-am:
500
501 install-html: install-html-am
502
503 install-html-am:
504
505 install-info: install-info-am
506
507 install-info-am:
508
509 install-man:
510
511 install-pdf: install-pdf-am
512
513 install-pdf-am:
514
515 install-ps: install-ps-am
516
517 install-ps-am:
518
519 installcheck-am:
520
521 maintainer-clean: maintainer-clean-am
522 -rm -f Makefile
523 maintainer-clean-am: distclean-am maintainer-clean-generic
524
525 mostlyclean: mostlyclean-am
526
527 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
528
529 pdf: pdf-am
530
531 pdf-am:
532
533 ps: ps-am
534
535 ps-am:
536
537 uninstall-am:
538
539 .MAKE: install-am install-strip
540
541 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
542 cscopelist-am ctags-am distclean distclean-generic \
543 distclean-libtool distdir dvi dvi-am html html-am info info-am \
544 install install-am install-data install-data-am install-dvi \
545 install-dvi-am install-exec install-exec-am install-html \
546 install-html-am install-info install-info-am install-man \
547 install-pdf install-pdf-am install-ps install-ps-am \
548 install-strip installcheck installcheck-am installdirs \
549 maintainer-clean maintainer-clean-generic mostlyclean \
550 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
551 tags-am uninstall uninstall-am
552
553 .PRECIOUS: Makefile
554
555
556 # Tell versions [3.59,3.63) of GNU make to not export all variables.
557 # Otherwise a system limit (for SysV at least) may be exceeded.
558 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for the Python bindings.
17 # Copyright (C) 2016 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang/python
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES = version.py setup.py
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
143 ctags-recursive dvi-recursive html-recursive info-recursive \
144 install-data-recursive install-dvi-recursive \
145 install-exec-recursive install-html-recursive \
146 install-info-recursive install-pdf-recursive \
147 install-ps-recursive install-recursive installcheck-recursive \
148 installdirs-recursive pdf-recursive ps-recursive \
149 tags-recursive uninstall-recursive
150 am__can_run_installinfo = \
151 case $$AM_UPDATE_INFO_DIR in \
152 n|no|NO) false;; \
153 *) (install-info --version) >/dev/null 2>&1;; \
154 esac
155 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
156 distclean-recursive maintainer-clean-recursive
157 am__recursive_targets = \
158 $(RECURSIVE_TARGETS) \
159 $(RECURSIVE_CLEAN_TARGETS) \
160 $(am__extra_recursive_targets)
161 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
162 distdir distdir-am
163 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
164 # Read a list of newline-separated strings from the standard input,
165 # and print each of them once, without duplicates. Input order is
166 # *not* preserved.
167 am__uniquify_input = $(AWK) '\
168 BEGIN { nonempty = 0; } \
169 { items[$$0] = 1; nonempty = 1; } \
170 END { if (nonempty) { for (i in items) print i; }; } \
171 '
172 # Make sure the list of sources is unique. This is necessary because,
173 # e.g., the same source file might be shared among _SOURCES variables
174 # for different programs/libraries.
175 am__define_uniq_tagged_files = \
176 list='$(am__tagged_files)'; \
177 unique=`for i in $$list; do \
178 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
179 done | $(am__uniquify_input)`
180 ETAGS = etags
181 CTAGS = ctags
182 DIST_SUBDIRS = $(SUBDIRS)
183 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/setup.py.in \
184 $(srcdir)/version.py.in $(top_srcdir)/build-aux/mkinstalldirs \
185 README
186 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
187 am__relativize = \
188 dir0=`pwd`; \
189 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
190 sed_rest='s,^[^/]*/*,,'; \
191 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
192 sed_butlast='s,/*[^/]*$$,,'; \
193 while test -n "$$dir1"; do \
194 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
195 if test "$$first" != "."; then \
196 if test "$$first" = ".."; then \
197 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
198 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
199 else \
200 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
201 if test "$$first2" = "$$first"; then \
202 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
203 else \
204 dir2="../$$dir2"; \
205 fi; \
206 dir0="$$dir0"/"$$first"; \
207 fi; \
208 fi; \
209 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
210 done; \
211 reldir="$$dir2"
212 ACLOCAL = @ACLOCAL@
213 AMTAR = @AMTAR@
214 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
215 AR = @AR@
216 AS = @AS@
217 AUTOCONF = @AUTOCONF@
218 AUTOHEADER = @AUTOHEADER@
219 AUTOMAKE = @AUTOMAKE@
220 AWK = @AWK@
221 BUILD_FILEVERSION = @BUILD_FILEVERSION@
222 BUILD_REVISION = @BUILD_REVISION@
223 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
224 BUILD_VERSION = @BUILD_VERSION@
225 CC = @CC@
226 CCDEPMODE = @CCDEPMODE@
227 CC_FOR_BUILD = @CC_FOR_BUILD@
228 CFLAGS = @CFLAGS@
229 CPP = @CPP@
230 CPPFLAGS = @CPPFLAGS@
231 CXX = @CXX@
232 CXXCPP = @CXXCPP@
233 CXXDEPMODE = @CXXDEPMODE@
234 CXXFLAGS = @CXXFLAGS@
235 CYGPATH_W = @CYGPATH_W@
236 DEFS = @DEFS@
237 DEPDIR = @DEPDIR@
238 DLLTOOL = @DLLTOOL@
239 DOXYGEN = @DOXYGEN@
240 DSYMUTIL = @DSYMUTIL@
241 DUMPBIN = @DUMPBIN@
242 ECHO_C = @ECHO_C@
243 ECHO_N = @ECHO_N@
244 ECHO_T = @ECHO_T@
245 EGREP = @EGREP@
246 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
247 EXEEXT = @EXEEXT@
248 FGREP = @FGREP@
249 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
250 GLIBC21 = @GLIBC21@
251 GLIB_CFLAGS = @GLIB_CFLAGS@
252 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
253 GLIB_LIBS = @GLIB_LIBS@
254 GLIB_MKENUMS = @GLIB_MKENUMS@
255 GOBJECT_QUERY = @GOBJECT_QUERY@
256 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
257 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
258 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
259 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
260 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
261 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
262 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
263 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
264 GPGME_QT_LIBS = @GPGME_QT_LIBS@
265 GPGRT_CONFIG = @GPGRT_CONFIG@
266 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
267 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
268 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
269 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
270 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
271 GRAPHVIZ = @GRAPHVIZ@
272 GREP = @GREP@
273 HAVE_CXX11 = @HAVE_CXX11@
274 HAVE_DOT = @HAVE_DOT@
275 INSTALL = @INSTALL@
276 INSTALL_DATA = @INSTALL_DATA@
277 INSTALL_PROGRAM = @INSTALL_PROGRAM@
278 INSTALL_SCRIPT = @INSTALL_SCRIPT@
279 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
280 LD = @LD@
281 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
282 LDFLAGS = @LDFLAGS@
283 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
284 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
285 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
286 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
287 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
288 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
289 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
290 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
291 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
292 LIBOBJS = @LIBOBJS@
293 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
294 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
295 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
296 LIBS = @LIBS@
297 LIBTOOL = @LIBTOOL@
298 LIPO = @LIPO@
299 LN_S = @LN_S@
300 LTLIBOBJS = @LTLIBOBJS@
301 MAINT = @MAINT@
302 MAKEINFO = @MAKEINFO@
303 MANIFEST_TOOL = @MANIFEST_TOOL@
304 MKDIR_P = @MKDIR_P@
305 MOC = @MOC@
306 MOC2 = @MOC2@
307 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
308 NM = @NM@
309 NMEDIT = @NMEDIT@
310 OBJDUMP = @OBJDUMP@
311 OBJEXT = @OBJEXT@
312 OTOOL = @OTOOL@
313 OTOOL64 = @OTOOL64@
314 PACKAGE = @PACKAGE@
315 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
316 PACKAGE_NAME = @PACKAGE_NAME@
317 PACKAGE_STRING = @PACKAGE_STRING@
318 PACKAGE_TARNAME = @PACKAGE_TARNAME@
319 PACKAGE_URL = @PACKAGE_URL@
320 PACKAGE_VERSION = @PACKAGE_VERSION@
321 PATH_SEPARATOR = @PATH_SEPARATOR@
322 PKG_CONFIG = @PKG_CONFIG@
323 PYTHON = @PYTHON@
324 PYTHONS = @PYTHONS@
325 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
326 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
327 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
328 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
329 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
330 PYTHON_PLATFORM = @PYTHON_PLATFORM@
331 PYTHON_PREFIX = @PYTHON_PREFIX@
332 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
333 PYTHON_VERSION = @PYTHON_VERSION@
334 QTCHOOSER = @QTCHOOSER@
335 RANLIB = @RANLIB@
336 RC = @RC@
337 SED = @SED@
338 SET_MAKE = @SET_MAKE@
339 SHELL = @SHELL@
340 STRIP = @STRIP@
341 SWIG = @SWIG@
342 SWIG_LIB = @SWIG_LIB@
343 SYSROOT = @SYSROOT@
344 VERSION = @VERSION@
345 VERSION_MAJOR = @VERSION_MAJOR@
346 VERSION_MICRO = @VERSION_MICRO@
347 VERSION_MINOR = @VERSION_MINOR@
348 VERSION_NUMBER = @VERSION_NUMBER@
349 abs_builddir = @abs_builddir@
350 abs_srcdir = @abs_srcdir@
351 abs_top_builddir = @abs_top_builddir@
352 abs_top_srcdir = @abs_top_srcdir@
353 ac_ct_AR = @ac_ct_AR@
354 ac_ct_CC = @ac_ct_CC@
355 ac_ct_CXX = @ac_ct_CXX@
356 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
357 am__include = @am__include@
358 am__leading_dot = @am__leading_dot@
359 am__quote = @am__quote@
360 am__tar = @am__tar@
361 am__untar = @am__untar@
362 bindir = @bindir@
363 build = @build@
364 build_alias = @build_alias@
365 build_cpu = @build_cpu@
366 build_os = @build_os@
367 build_vendor = @build_vendor@
368 builddir = @builddir@
369 datadir = @datadir@
370 datarootdir = @datarootdir@
371 docdir = @docdir@
372 dvidir = @dvidir@
373 emacs_local_vars_begin = @emacs_local_vars_begin@
374 emacs_local_vars_end = @emacs_local_vars_end@
375 emacs_local_vars_read_only = @emacs_local_vars_read_only@
376 exec_prefix = @exec_prefix@
377 host = @host@
378 host_alias = @host_alias@
379 host_cpu = @host_cpu@
380 host_os = @host_os@
381 host_vendor = @host_vendor@
382 htmldir = @htmldir@
383 includedir = @includedir@
384 infodir = @infodir@
385 install_sh = @install_sh@
386 libdir = @libdir@
387 libexecdir = @libexecdir@
388 localedir = @localedir@
389 localstatedir = @localstatedir@
390 mandir = @mandir@
391 mkdir_p = @mkdir_p@
392 oldincludedir = @oldincludedir@
393 pdfdir = @pdfdir@
394 pkgpyexecdir = @pkgpyexecdir@
395 pkgpythondir = @pkgpythondir@
396 prefix = @prefix@
397 program_transform_name = @program_transform_name@
398 psdir = @psdir@
399 pyexecdir = @pyexecdir@
400 pythondir = @pythondir@
401 runstatedir = @runstatedir@
402 sbindir = @sbindir@
403 sharedstatedir = @sharedstatedir@
404 srcdir = @srcdir@
405 sysconfdir = @sysconfdir@
406 target_alias = @target_alias@
407 top_build_prefix = @top_build_prefix@
408 top_builddir = @top_builddir@
409 top_srcdir = @top_srcdir@
410 EXTRA_DIST = \
411 README \
412 MANIFEST.in \
413 gpgme.i \
414 helpers.c helpers.h private.h
415
416 SUBDIRS = . tests examples doc src
417 CLEANFILES = copystamp \
418 config.h \
419 data.h \
420 gpg
421
422 all: all-recursive
423
424 .SUFFIXES:
425 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
426 @for dep in $?; do \
427 case '$(am__configure_deps)' in \
428 *$$dep*) \
429 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
430 && { if test -f $@; then exit 0; else break; fi; }; \
431 exit 1;; \
432 esac; \
433 done; \
434 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/python/Makefile'; \
435 $(am__cd) $(top_srcdir) && \
436 $(AUTOMAKE) --gnu lang/python/Makefile
437 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
438 @case '$?' in \
439 *config.status*) \
440 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
441 *) \
442 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
443 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
444 esac;
445
446 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
447 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
448
449 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
450 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
451 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
452 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
453 $(am__aclocal_m4_deps):
454 version.py: $(top_builddir)/config.status $(srcdir)/version.py.in
455 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
456 setup.py: $(top_builddir)/config.status $(srcdir)/setup.py.in
457 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
458
459 mostlyclean-libtool:
460 -rm -f *.lo
461
462 clean-libtool:
463 -rm -rf .libs _libs
464
465 # This directory's subdirectories are mostly independent; you can cd
466 # into them and run 'make' without going through this Makefile.
467 # To change the values of 'make' variables: instead of editing Makefiles,
468 # (1) if the variable is set in 'config.status', edit 'config.status'
469 # (which will cause the Makefiles to be regenerated when you run 'make');
470 # (2) otherwise, pass the desired values on the 'make' command line.
471 $(am__recursive_targets):
472 @fail=; \
473 if $(am__make_keepgoing); then \
474 failcom='fail=yes'; \
475 else \
476 failcom='exit 1'; \
477 fi; \
478 dot_seen=no; \
479 target=`echo $@ | sed s/-recursive//`; \
480 case "$@" in \
481 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
482 *) list='$(SUBDIRS)' ;; \
483 esac; \
484 for subdir in $$list; do \
485 echo "Making $$target in $$subdir"; \
486 if test "$$subdir" = "."; then \
487 dot_seen=yes; \
488 local_target="$$target-am"; \
489 else \
490 local_target="$$target"; \
491 fi; \
492 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
493 || eval $$failcom; \
494 done; \
495 if test "$$dot_seen" = "no"; then \
496 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
497 fi; test -z "$$fail"
498
499 ID: $(am__tagged_files)
500 $(am__define_uniq_tagged_files); mkid -fID $$unique
501 tags: tags-recursive
502 TAGS: tags
503
504 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
505 set x; \
506 here=`pwd`; \
507 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
508 include_option=--etags-include; \
509 empty_fix=.; \
510 else \
511 include_option=--include; \
512 empty_fix=; \
513 fi; \
514 list='$(SUBDIRS)'; for subdir in $$list; do \
515 if test "$$subdir" = .; then :; else \
516 test ! -f $$subdir/TAGS || \
517 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
518 fi; \
519 done; \
520 $(am__define_uniq_tagged_files); \
521 shift; \
522 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
523 test -n "$$unique" || unique=$$empty_fix; \
524 if test $$# -gt 0; then \
525 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
526 "$$@" $$unique; \
527 else \
528 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
529 $$unique; \
530 fi; \
531 fi
532 ctags: ctags-recursive
533
534 CTAGS: ctags
535 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
536 $(am__define_uniq_tagged_files); \
537 test -z "$(CTAGS_ARGS)$$unique" \
538 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
539 $$unique
540
541 GTAGS:
542 here=`$(am__cd) $(top_builddir) && pwd` \
543 && $(am__cd) $(top_srcdir) \
544 && gtags -i $(GTAGS_ARGS) "$$here"
545 cscopelist: cscopelist-recursive
546
547 cscopelist-am: $(am__tagged_files)
548 list='$(am__tagged_files)'; \
549 case "$(srcdir)" in \
550 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
551 *) sdir=$(subdir)/$(srcdir) ;; \
552 esac; \
553 for i in $$list; do \
554 if test -f "$$i"; then \
555 echo "$(subdir)/$$i"; \
556 else \
557 echo "$$sdir/$$i"; \
558 fi; \
559 done >> $(top_builddir)/cscope.files
560
561 distclean-tags:
562 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
563
564 distdir: $(BUILT_SOURCES)
565 $(MAKE) $(AM_MAKEFLAGS) distdir-am
566
567 distdir-am: $(DISTFILES)
568 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
569 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
570 list='$(DISTFILES)'; \
571 dist_files=`for file in $$list; do echo $$file; done | \
572 sed -e "s|^$$srcdirstrip/||;t" \
573 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
574 case $$dist_files in \
575 */*) $(MKDIR_P) `echo "$$dist_files" | \
576 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
577 sort -u` ;; \
578 esac; \
579 for file in $$dist_files; do \
580 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
581 if test -d $$d/$$file; then \
582 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
583 if test -d "$(distdir)/$$file"; then \
584 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
585 fi; \
586 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
587 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
588 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
589 fi; \
590 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
591 else \
592 test -f "$(distdir)/$$file" \
593 || cp -p $$d/$$file "$(distdir)/$$file" \
594 || exit 1; \
595 fi; \
596 done
597 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
598 if test "$$subdir" = .; then :; else \
599 $(am__make_dryrun) \
600 || test -d "$(distdir)/$$subdir" \
601 || $(MKDIR_P) "$(distdir)/$$subdir" \
602 || exit 1; \
603 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
604 $(am__relativize); \
605 new_distdir=$$reldir; \
606 dir1=$$subdir; dir2="$(top_distdir)"; \
607 $(am__relativize); \
608 new_top_distdir=$$reldir; \
609 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
610 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
611 ($(am__cd) $$subdir && \
612 $(MAKE) $(AM_MAKEFLAGS) \
613 top_distdir="$$new_top_distdir" \
614 distdir="$$new_distdir" \
615 am__remove_distdir=: \
616 am__skip_length_check=: \
617 am__skip_mode_fix=: \
618 distdir) \
619 || exit 1; \
620 fi; \
621 done
622 check-am: all-am
623 check: check-recursive
624 all-am: Makefile all-local
625 installdirs: installdirs-recursive
626 installdirs-am:
627 install: install-recursive
628 install-exec: install-exec-recursive
629 install-data: install-data-recursive
630 uninstall: uninstall-recursive
631
632 install-am: all-am
633 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
634
635 installcheck: installcheck-recursive
636 install-strip:
637 if test -z '$(STRIP)'; then \
638 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
639 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
640 install; \
641 else \
642 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
643 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
644 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
645 fi
646 mostlyclean-generic:
647
648 clean-generic:
649 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
650
651 distclean-generic:
652 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
653 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
654
655 maintainer-clean-generic:
656 @echo "This command is intended for maintainers to use"
657 @echo "it deletes files that may require special tools to rebuild."
658 clean: clean-recursive
659
660 clean-am: clean-generic clean-libtool clean-local mostlyclean-am
661
662 distclean: distclean-recursive
663 -rm -f Makefile
664 distclean-am: clean-am distclean-generic distclean-tags
665
666 dvi: dvi-recursive
667
668 dvi-am:
669
670 html: html-recursive
671
672 html-am:
673
674 info: info-recursive
675
676 info-am:
677
678 install-data-am:
679
680 install-dvi: install-dvi-recursive
681
682 install-dvi-am:
683
684 install-exec-am: install-exec-local
685
686 install-html: install-html-recursive
687
688 install-html-am:
689
690 install-info: install-info-recursive
691
692 install-info-am:
693
694 install-man:
695
696 install-pdf: install-pdf-recursive
697
698 install-pdf-am:
699
700 install-ps: install-ps-recursive
701
702 install-ps-am:
703
704 installcheck-am:
705
706 maintainer-clean: maintainer-clean-recursive
707 -rm -f Makefile
708 maintainer-clean-am: distclean-am maintainer-clean-generic
709
710 mostlyclean: mostlyclean-recursive
711
712 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
713
714 pdf: pdf-recursive
715
716 pdf-am:
717
718 ps: ps-recursive
719
720 ps-am:
721
722 uninstall-am: uninstall-local
723
724 .MAKE: $(am__recursive_targets) install-am install-strip
725
726 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am all-local \
727 check check-am clean clean-generic clean-libtool clean-local \
728 cscopelist-am ctags ctags-am distclean distclean-generic \
729 distclean-libtool distclean-tags distdir dvi dvi-am html \
730 html-am info info-am install install-am install-data \
731 install-data-am install-dvi install-dvi-am install-exec \
732 install-exec-am install-exec-local install-html \
733 install-html-am install-info install-info-am install-man \
734 install-pdf install-pdf-am install-ps install-ps-am \
735 install-strip installcheck installcheck-am installdirs \
736 installdirs-am maintainer-clean maintainer-clean-generic \
737 mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
738 ps ps-am tags tags-am uninstall uninstall-am uninstall-local
739
740 .PRECIOUS: Makefile
741
742
743 .PHONY: prepare
744 prepare: copystamp
745
746 # For VPATH builds we need to copy some files because Python's
747 # distutils are not VPATH-aware.
748 copystamp:
749 ln -sf "$(top_srcdir)/src/data.h" .
750 ln -sf "$(top_builddir)/conf/config.h" .
751 ln -sf "$(srcdir)/src" gpg
752 touch $@
753
754 all-local: copystamp
755 set -e ; for PYTHON in $(PYTHONS); do \
756 CPP="$(CPP)" \
757 CFLAGS="$(CFLAGS)" \
758 srcdir="$(srcdir)" \
759 top_builddir="$(top_builddir)" \
760 $$PYTHON setup.py build --verbose --build-base="$$(basename "$${PYTHON}")-gpg" ; \
761 done
762
763 python$(PYTHON_VERSION)-gpg/dist/gpg-$(VERSION).tar.gz.asc: copystamp
764 $(MKDIR_P) python$(PYTHON_VERSION)-gpg-dist
765 CPP="$(CPP)" \
766 CFLAGS="$(CFLAGS)" \
767 srcdir="$(srcdir)" \
768 top_builddir="$(top_builddir)" \
769 $(PYTHON) setup.py sdist --verbose --dist-dir=python$(PYTHON_VERSION)-gpg-dist \
770 --manifest=python$(PYTHON_VERSION)-gpg-dist/MANIFEST
771 gpgbin=gpgconf --list-components | grep OpenPGP | sed -e 's/gpg:OpenPGP://g'
772 $(gpgbin) --detach-sign --armor python$(PYTHON_VERSION)-gpg-dist/gpg-$(VERSION).tar.gz
773
774 .PHONY: sdist
775 sdist: python$(PYTHON_VERSION)-gpg/dist/gpg-$(VERSION).tar.gz.asc
776
777 .PHONY: upload
778 upload: python$(PYTHON_VERSION)-gpg-dist/gpg-$(VERSION).tar.gz \
779 python$(PYTHON_VERSION)-gpg-dist/gpg-$(VERSION).tar.gz.asc
780 twine upload $^
781
782 # Remove the rest.
783 #
784 # 'make distclean' clears the write bit, breaking rm -rf. Fix the
785 # permissions.
786 clean-local:
787 rm -rf -- build
788 for PYTHON in $(PYTHONS); do \
789 find "$$(basename "$${PYTHON}")-gpg" -type d ! -perm -200 -exec chmod u+w {} ';' ; \
790 rm -rf -- "$$(basename "$${PYTHON}")-gpg" ; \
791 done
792
793 install-exec-local:
794 set -e ; for PYTHON in $(PYTHONS); do \
795 CPP="$(CPP)" \
796 CFLAGS="$(CFLAGS)" \
797 srcdir="$(srcdir)" \
798 top_builddir="$(top_builddir)" \
799 $$PYTHON setup.py \
800 build \
801 --build-base="$$(basename "$${PYTHON}")-gpg" \
802 install \
803 --prefix "$(DESTDIR)$(prefix)" \
804 --verbose ; \
805 done
806
807 uninstall-local:
808 set -x; GV=$$(echo $(VERSION) | tr - _); for PYTHON in $(PYTHONS); do \
809 PLATLIB="$(prefix)/$$("$${PYTHON}" -c 'import sysconfig, os; print(os.path.relpath(sysconfig.get_path("platlib", scheme="posix_prefix"), sysconfig.get_config_var("prefix")))')" ; \
810 rm -rf -- "$(DESTDIR)$${PLATLIB}/gpg" \
811 "$(DESTDIR)$${PLATLIB}"/gpg-$$GV-py*.egg-info ; \
812 done
813
814 # Tell versions [3.59,3.63) of GNU make to not export all variables.
815 # Otherwise a system limit (for SysV at least) may be exceeded.
816 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for the Python bindings.
17 # Copyright (C) 2019 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang/python/doc
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES =
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 am__can_run_installinfo = \
143 case $$AM_UPDATE_INFO_DIR in \
144 n|no|NO) false;; \
145 *) (install-info --version) >/dev/null 2>&1;; \
146 esac
147 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
148 am__DIST_COMMON = $(srcdir)/Makefile.in \
149 $(top_srcdir)/build-aux/mkinstalldirs README
150 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
151 ACLOCAL = @ACLOCAL@
152 AMTAR = @AMTAR@
153 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
154 AR = @AR@
155 AS = @AS@
156 AUTOCONF = @AUTOCONF@
157 AUTOHEADER = @AUTOHEADER@
158 AUTOMAKE = @AUTOMAKE@
159 AWK = @AWK@
160 BUILD_FILEVERSION = @BUILD_FILEVERSION@
161 BUILD_REVISION = @BUILD_REVISION@
162 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
163 BUILD_VERSION = @BUILD_VERSION@
164 CC = @CC@
165 CCDEPMODE = @CCDEPMODE@
166 CC_FOR_BUILD = @CC_FOR_BUILD@
167 CFLAGS = @CFLAGS@
168 CPP = @CPP@
169 CPPFLAGS = @CPPFLAGS@
170 CXX = @CXX@
171 CXXCPP = @CXXCPP@
172 CXXDEPMODE = @CXXDEPMODE@
173 CXXFLAGS = @CXXFLAGS@
174 CYGPATH_W = @CYGPATH_W@
175 DEFS = @DEFS@
176 DEPDIR = @DEPDIR@
177 DLLTOOL = @DLLTOOL@
178 DOXYGEN = @DOXYGEN@
179 DSYMUTIL = @DSYMUTIL@
180 DUMPBIN = @DUMPBIN@
181 ECHO_C = @ECHO_C@
182 ECHO_N = @ECHO_N@
183 ECHO_T = @ECHO_T@
184 EGREP = @EGREP@
185 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
186 EXEEXT = @EXEEXT@
187 FGREP = @FGREP@
188 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
189 GLIBC21 = @GLIBC21@
190 GLIB_CFLAGS = @GLIB_CFLAGS@
191 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
192 GLIB_LIBS = @GLIB_LIBS@
193 GLIB_MKENUMS = @GLIB_MKENUMS@
194 GOBJECT_QUERY = @GOBJECT_QUERY@
195 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
196 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
197 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
198 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
199 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
200 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
201 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
202 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
203 GPGME_QT_LIBS = @GPGME_QT_LIBS@
204 GPGRT_CONFIG = @GPGRT_CONFIG@
205 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
206 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
207 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
208 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
209 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
210 GRAPHVIZ = @GRAPHVIZ@
211 GREP = @GREP@
212 HAVE_CXX11 = @HAVE_CXX11@
213 HAVE_DOT = @HAVE_DOT@
214 INSTALL = @INSTALL@
215 INSTALL_DATA = @INSTALL_DATA@
216 INSTALL_PROGRAM = @INSTALL_PROGRAM@
217 INSTALL_SCRIPT = @INSTALL_SCRIPT@
218 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
219 LD = @LD@
220 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
221 LDFLAGS = @LDFLAGS@
222 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
223 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
224 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
225 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
226 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
227 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
228 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
229 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
230 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
231 LIBOBJS = @LIBOBJS@
232 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
233 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
234 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
235 LIBS = @LIBS@
236 LIBTOOL = @LIBTOOL@
237 LIPO = @LIPO@
238 LN_S = @LN_S@
239 LTLIBOBJS = @LTLIBOBJS@
240 MAINT = @MAINT@
241 MAKEINFO = @MAKEINFO@
242 MANIFEST_TOOL = @MANIFEST_TOOL@
243 MKDIR_P = @MKDIR_P@
244 MOC = @MOC@
245 MOC2 = @MOC2@
246 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
247 NM = @NM@
248 NMEDIT = @NMEDIT@
249 OBJDUMP = @OBJDUMP@
250 OBJEXT = @OBJEXT@
251 OTOOL = @OTOOL@
252 OTOOL64 = @OTOOL64@
253 PACKAGE = @PACKAGE@
254 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
255 PACKAGE_NAME = @PACKAGE_NAME@
256 PACKAGE_STRING = @PACKAGE_STRING@
257 PACKAGE_TARNAME = @PACKAGE_TARNAME@
258 PACKAGE_URL = @PACKAGE_URL@
259 PACKAGE_VERSION = @PACKAGE_VERSION@
260 PATH_SEPARATOR = @PATH_SEPARATOR@
261 PKG_CONFIG = @PKG_CONFIG@
262 PYTHON = @PYTHON@
263 PYTHONS = @PYTHONS@
264 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
265 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
266 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
267 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
268 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
269 PYTHON_PLATFORM = @PYTHON_PLATFORM@
270 PYTHON_PREFIX = @PYTHON_PREFIX@
271 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
272 PYTHON_VERSION = @PYTHON_VERSION@
273 QTCHOOSER = @QTCHOOSER@
274 RANLIB = @RANLIB@
275 RC = @RC@
276 SED = @SED@
277 SET_MAKE = @SET_MAKE@
278 SHELL = @SHELL@
279 STRIP = @STRIP@
280 SWIG = @SWIG@
281 SWIG_LIB = @SWIG_LIB@
282 SYSROOT = @SYSROOT@
283 VERSION = @VERSION@
284 VERSION_MAJOR = @VERSION_MAJOR@
285 VERSION_MICRO = @VERSION_MICRO@
286 VERSION_MINOR = @VERSION_MINOR@
287 VERSION_NUMBER = @VERSION_NUMBER@
288 abs_builddir = @abs_builddir@
289 abs_srcdir = @abs_srcdir@
290 abs_top_builddir = @abs_top_builddir@
291 abs_top_srcdir = @abs_top_srcdir@
292 ac_ct_AR = @ac_ct_AR@
293 ac_ct_CC = @ac_ct_CC@
294 ac_ct_CXX = @ac_ct_CXX@
295 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
296 am__include = @am__include@
297 am__leading_dot = @am__leading_dot@
298 am__quote = @am__quote@
299 am__tar = @am__tar@
300 am__untar = @am__untar@
301 bindir = @bindir@
302 build = @build@
303 build_alias = @build_alias@
304 build_cpu = @build_cpu@
305 build_os = @build_os@
306 build_vendor = @build_vendor@
307 builddir = @builddir@
308 datadir = @datadir@
309 datarootdir = @datarootdir@
310 docdir = @docdir@
311 dvidir = @dvidir@
312 emacs_local_vars_begin = @emacs_local_vars_begin@
313 emacs_local_vars_end = @emacs_local_vars_end@
314 emacs_local_vars_read_only = @emacs_local_vars_read_only@
315 exec_prefix = @exec_prefix@
316 host = @host@
317 host_alias = @host_alias@
318 host_cpu = @host_cpu@
319 host_os = @host_os@
320 host_vendor = @host_vendor@
321 htmldir = @htmldir@
322 includedir = @includedir@
323 infodir = @infodir@
324 install_sh = @install_sh@
325 libdir = @libdir@
326 libexecdir = @libexecdir@
327 localedir = @localedir@
328 localstatedir = @localstatedir@
329 mandir = @mandir@
330 mkdir_p = @mkdir_p@
331 oldincludedir = @oldincludedir@
332 pdfdir = @pdfdir@
333 pkgpyexecdir = @pkgpyexecdir@
334 pkgpythondir = @pkgpythondir@
335 prefix = @prefix@
336 program_transform_name = @program_transform_name@
337 psdir = @psdir@
338 pyexecdir = @pyexecdir@
339 pythondir = @pythondir@
340 runstatedir = @runstatedir@
341 sbindir = @sbindir@
342 sharedstatedir = @sharedstatedir@
343 srcdir = @srcdir@
344 sysconfdir = @sysconfdir@
345 target_alias = @target_alias@
346 top_build_prefix = @top_build_prefix@
347 top_builddir = @top_builddir@
348 top_srcdir = @top_srcdir@
349 EXTRA_DIST = README rst src texinfo
350 @MAINTAINER_MODE_TRUE@ORGSRCS = index.org gpgme-python-howto.org maintenance-mode.org \
351 @MAINTAINER_MODE_TRUE@ short-history.org what-is-new.org what-was-new.org
352
353 all: all-am
354
355 .SUFFIXES:
356 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
357 @for dep in $?; do \
358 case '$(am__configure_deps)' in \
359 *$$dep*) \
360 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
361 && { if test -f $@; then exit 0; else break; fi; }; \
362 exit 1;; \
363 esac; \
364 done; \
365 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/python/doc/Makefile'; \
366 $(am__cd) $(top_srcdir) && \
367 $(AUTOMAKE) --gnu lang/python/doc/Makefile
368 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
369 @case '$?' in \
370 *config.status*) \
371 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
372 *) \
373 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
374 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
375 esac;
376
377 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
378 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
379
380 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
381 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
382 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
383 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
384 $(am__aclocal_m4_deps):
385
386 mostlyclean-libtool:
387 -rm -f *.lo
388
389 clean-libtool:
390 -rm -rf .libs _libs
391 tags TAGS:
392
393 ctags CTAGS:
394
395 cscope cscopelist:
396
397
398 distdir: $(BUILT_SOURCES)
399 $(MAKE) $(AM_MAKEFLAGS) distdir-am
400
401 distdir-am: $(DISTFILES)
402 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
403 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
404 list='$(DISTFILES)'; \
405 dist_files=`for file in $$list; do echo $$file; done | \
406 sed -e "s|^$$srcdirstrip/||;t" \
407 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
408 case $$dist_files in \
409 */*) $(MKDIR_P) `echo "$$dist_files" | \
410 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
411 sort -u` ;; \
412 esac; \
413 for file in $$dist_files; do \
414 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
415 if test -d $$d/$$file; then \
416 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
417 if test -d "$(distdir)/$$file"; then \
418 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
419 fi; \
420 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
421 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
422 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
423 fi; \
424 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
425 else \
426 test -f "$(distdir)/$$file" \
427 || cp -p $$d/$$file "$(distdir)/$$file" \
428 || exit 1; \
429 fi; \
430 done
431 check-am: all-am
432 check: check-am
433 @MAINTAINER_MODE_FALSE@all-local:
434 all-am: Makefile all-local
435 installdirs:
436 install: install-am
437 install-exec: install-exec-am
438 install-data: install-data-am
439 uninstall: uninstall-am
440
441 install-am: all-am
442 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
443
444 installcheck: installcheck-am
445 install-strip:
446 if test -z '$(STRIP)'; then \
447 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
448 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
449 install; \
450 else \
451 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
452 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
453 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
454 fi
455 mostlyclean-generic:
456
457 clean-generic:
458
459 distclean-generic:
460 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
461 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
462
463 maintainer-clean-generic:
464 @echo "This command is intended for maintainers to use"
465 @echo "it deletes files that may require special tools to rebuild."
466 @MAINTAINER_MODE_FALSE@maintainer-clean-local:
467 clean: clean-am
468
469 clean-am: clean-generic clean-libtool mostlyclean-am
470
471 distclean: distclean-am
472 -rm -f Makefile
473 distclean-am: clean-am distclean-generic
474
475 dvi: dvi-am
476
477 dvi-am:
478
479 html: html-am
480
481 html-am:
482
483 info: info-am
484
485 info-am:
486
487 install-data-am:
488
489 install-dvi: install-dvi-am
490
491 install-dvi-am:
492
493 install-exec-am:
494
495 install-html: install-html-am
496
497 install-html-am:
498
499 install-info: install-info-am
500
501 install-info-am:
502
503 install-man:
504
505 install-pdf: install-pdf-am
506
507 install-pdf-am:
508
509 install-ps: install-ps-am
510
511 install-ps-am:
512
513 installcheck-am:
514
515 maintainer-clean: maintainer-clean-am
516 -rm -f Makefile
517 maintainer-clean-am: distclean-am maintainer-clean-generic \
518 maintainer-clean-local
519
520 mostlyclean: mostlyclean-am
521
522 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
523
524 pdf: pdf-am
525
526 pdf-am:
527
528 ps: ps-am
529
530 ps-am:
531
532 uninstall-am:
533
534 .MAKE: install-am install-strip
535
536 .PHONY: all all-am all-local check check-am clean clean-generic \
537 clean-libtool cscopelist-am ctags-am distclean \
538 distclean-generic distclean-libtool distdir dvi dvi-am html \
539 html-am info info-am install install-am install-data \
540 install-data-am install-dvi install-dvi-am install-exec \
541 install-exec-am install-html install-html-am install-info \
542 install-info-am install-man install-pdf install-pdf-am \
543 install-ps install-ps-am install-strip installcheck \
544 installcheck-am installdirs maintainer-clean \
545 maintainer-clean-generic maintainer-clean-local mostlyclean \
546 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
547 tags-am uninstall uninstall-am
548
549 .PRECIOUS: Makefile
550
551
552 # Make sure we have 'rst' and 'texinfo' dirs in build directory
553 @MAINTAINER_MODE_TRUE@.PHONY: the_doc_dirs gen_rst gen_texi
554
555 @MAINTAINER_MODE_TRUE@the_doc_dirs:
556 @MAINTAINER_MODE_TRUE@ @if test ! -d rst; then echo $(MKDIR_P) rst; $(MKDIR_P) rst; fi
557 @MAINTAINER_MODE_TRUE@ @if test ! -d texinfo; then echo $(MKDIR_P) texinfo; $(MKDIR_P) texinfo; fi
558
559 # Generate RST files from ORG
560 @MAINTAINER_MODE_TRUE@gen_rst:
561 @MAINTAINER_MODE_TRUE@ @for f in $(ORGSRCS); do if test ! -e rst/$${f%.org}.rst \
562 @MAINTAINER_MODE_TRUE@ -o rst/$${f%.org}.rst -ot $(srcdir)/src/$$f; then \
563 @MAINTAINER_MODE_TRUE@ echo pandoc -f org -t rst $(srcdir)/src/$$f -o rst/$${f%.org}.rst; \
564 @MAINTAINER_MODE_TRUE@ pandoc -f org -t rst $(srcdir)/src/$$f -o rst/$${f%.org}.rst; \
565 @MAINTAINER_MODE_TRUE@ fi; \
566 @MAINTAINER_MODE_TRUE@ done
567
568 # Generate Texinfo files from ORG
569 @MAINTAINER_MODE_TRUE@gen_texi:
570 @MAINTAINER_MODE_TRUE@ @for f in $(ORGSRCS); do if test ! -e texinfo/$${f%.org}.texi \
571 @MAINTAINER_MODE_TRUE@ -o texinfo/$${f%.org}.texi -ot $(srcdir)/src/$$f; then \
572 @MAINTAINER_MODE_TRUE@ echo pandoc -f org -t texinfo $(srcdir)/src/$$f -o texinfo/$${f%.org}.texi; \
573 @MAINTAINER_MODE_TRUE@ pandoc -f org -t texinfo $(srcdir)/src/$$f -o texinfo/$${f%.org}.texi; \
574 @MAINTAINER_MODE_TRUE@ fi; \
575 @MAINTAINER_MODE_TRUE@ done
576
577 @MAINTAINER_MODE_TRUE@all-local: gen_rst gen_texi
578
579 @MAINTAINER_MODE_TRUE@gen_rst gen_texi: the_doc_dirs
580
581 @MAINTAINER_MODE_TRUE@maintainer-clean-local:
582 @MAINTAINER_MODE_TRUE@ @for f in $(ORGSRCS); do \
583 @MAINTAINER_MODE_TRUE@ echo rm -f rst/$${f%.org}.rst texinfo/$${f%.org}.texi; \
584 @MAINTAINER_MODE_TRUE@ rm -f rst/$${f%.org}.rst texinfo/$${f%.org}.texi; \
585 @MAINTAINER_MODE_TRUE@ done
586
587 # Tell versions [3.59,3.63) of GNU make to not export all variables.
588 # Otherwise a system limit (for SysV at least) may be exceeded.
589 .NOEXPORT:
0 % Created 2019-01-18 Fri 10:10
1 % Intended LaTeX compiler: xelatex
2 \documentclass[12pt]{article}
3 \usepackage{graphicx}
4 \usepackage{grffile}
5 \usepackage{longtable}
6 \usepackage{wrapfig}
7 \usepackage{rotating}
8 \usepackage[normalem]{ulem}
9 \usepackage{amsmath}
10 \usepackage{textcomp}
11 \usepackage{amssymb}
12 \usepackage{capt-of}
13 \usepackage{hyperref}
14 \usepackage{xltxtra}
15 \usepackage[margin=1in]{geometry}
16 \setmainfont[Ligatures={Common}]{Times New Roman}
17 \author{Ben McGinnes <ben@gnupg.org>}
18 \author{Ben McGinnes}
19 \date{\today}
20 \title{GNU Privacy Guard (GnuPG) Made Easy Python Bindings HOWTO (English)}
21 \hypersetup{
22 pdfauthor={Ben McGinnes},
23 pdftitle={GNU Privacy Guard (GnuPG) Made Easy Python Bindings HOWTO (English)},
24 pdfkeywords={},
25 pdfsubject={},
26 pdfcreator={Emacs 26.1 (Org mode 9.1.14)},
27 pdflang={English}}
28 \begin{document}
29
30 \maketitle
31 \tableofcontents
32
33
34
35 \section{Introduction}
36 \label{sec:org8e5fa02}
37 \begin{center}
38 \begin{tabular}{ll}
39 Version: & 0.1.4\\
40 GPGME Version: & 1.12.1\\
41 Author: & Ben McGinnes <ben@gnupg.org>\\
42 Author GPG Key: & DB4724E6FA4286C92B4E55C4321E4E2373590E5D\\
43 Language: & Australian English, British English\\
44 Language codes: & en-AU, en-GB, en\\
45 \end{tabular}
46 \end{center}
47
48 This document provides basic instruction in how to use the GPGME
49 Python bindings to programmatically leverage the GPGME library.
50
51
52 \subsection{Python 2 versus Python 3}
53 \label{sec:org517cbf4}
54 Though the GPGME Python bindings themselves provide support for both
55 Python 2 and 3, the focus is unequivocally on Python 3 and
56 specifically from Python 3.4 and above. As a consequence all the
57 examples and instructions in this guide use Python 3 code.
58
59 Much of it will work with Python 2, but much of it also deals with
60 Python 3 byte literals, particularly when reading and writing data.
61 Developers concentrating on Python 2.7, and possibly even 2.6, will
62 need to make the appropriate modifications to support the older string
63 and unicode types as opposed to bytes.
64
65 There are multiple reasons for concentrating on Python 3; some of
66 which relate to the immediate integration of these bindings, some of
67 which relate to longer term plans for both GPGME and the python
68 bindings and some of which relate to the impending EOL period for
69 Python 2.7. Essentially, though, there is little value in tying the
70 bindings to a version of the language which is a dead end and the
71 advantages offered by Python 3 over Python 2 make handling the data
72 types with which GPGME deals considerably easier.
73
74
75 \subsection{Examples}
76 \label{sec:org2c08d53}
77 All of the examples found in this document can be found as Python 3
78 scripts in the \texttt{lang/python/examples/howto} directory.
79
80
81 \subsection{Unofficial Drafts}
82 \label{sec:orgceb2216}
83 In addition to shipping with each release of GPGME, there is a section
84 on locations to read or download \hyperref[sec:org080a94a]{draft editions} of this document from
85 at the end of it. These are unofficial versions produced in between
86 major releases.
87
88
89 \subsection{What's New}
90 \label{sec:orga79ddc2}
91 Full details of what is new are now available in the \href{what-is-new.org}{What's New} file
92 and archives of the preceding \emph{What's New} sections are available in
93 the \href{what-was-new}{What Was New} file.
94
95
96 \subsubsection{New in GPGME 1·13·0}
97 \label{sec:org746b75d}
98 See the \href{what-is-new\#new-stuff-1-13-0}{What's New} document for what is new in version 1.13.0.
99
100
101 \subsubsection{New in GPGME 1·12·0}
102 \label{sec:org7adcade}
103 See the \href{what-was-new\#new-stuff-1-12-0}{What Was New} document for what was new in version 1.12.0.
104
105
106 \section{GPGME Concepts}
107 \label{sec:orgb257fc1}
108 \subsection{A C API}
109 \label{sec:org4fe1dfa}
110 Unlike many modern APIs with which programmers will be more familiar
111 with these days, the GPGME API is a C API. The API is intended for
112 use by C coders who would be able to access its features by including
113 the \texttt{gpgme.h} header file with their own C source code and then access
114 its functions just as they would any other C headers.
115
116 This is a very effective method of gaining complete access to the API
117 and in the most efficient manner possible. It does, however, have the
118 drawback that it cannot be directly used by other languages without
119 some means of providing an interface to those languages. This is
120 where the need for bindings in various languages stems.
121
122
123 \subsection{Python bindings}
124 \label{sec:org0e49e52}
125 The Python bindings for GPGME provide a higher level means of
126 accessing the complete feature set of GPGME itself. It also provides
127 a more pythonic means of calling these API functions.
128
129 The bindings are generated dynamically with SWIG and the copy of
130 \texttt{gpgme.h} generated when GPGME is compiled.
131
132 This means that a version of the Python bindings is fundamentally tied
133 to the exact same version of GPGME used to generate that copy of
134 \texttt{gpgme.h}.
135
136
137 \subsection{Difference between the Python bindings and other GnuPG Python packages}
138 \label{sec:org97acfd7}
139 There have been numerous attempts to add GnuPG support to Python over
140 the years. Some of the most well known are listed here, along with
141 what differentiates them.
142
143
144 \subsubsection{The python-gnupg package maintained by Vinay Sajip}
145 \label{sec:org0136847}
146 This is arguably the most popular means of integrating GPG with
147 Python. The package utilises the \texttt{subprocess} module to implement
148 wrappers for the \texttt{gpg} and \texttt{gpg2} executables normally invoked on the
149 command line (\texttt{gpg.exe} and \texttt{gpg2.exe} on Windows).
150
151 The popularity of this package stemmed from its ease of use and
152 capability in providing the most commonly required features.
153
154 Unfortunately it has been beset by a number of security issues in the
155 past; most of which stemmed from using unsafe methods of accessing the
156 command line via the \texttt{subprocess} calls. While some effort has been
157 made over the last two to three years (as of 2018) to mitigate this,
158 particularly by no longer providing shell access through those
159 subprocess calls, the wrapper is still somewhat limited in the scope
160 of its GnuPG features coverage.
161
162 The python-gnupg package is available under the MIT license.
163
164
165 \subsubsection{The gnupg package created and maintained by Isis Lovecruft}
166 \label{sec:orgdc03987}
167 In 2015 Isis Lovecruft from the Tor Project forked and then
168 re-implemented the python-gnupg package as just gnupg. This new
169 package also relied on subprocess to call the \texttt{gpg} or \texttt{gpg2}
170 binaries, but did so somewhat more securely.
171
172 The naming and version numbering selected for this package, however,
173 resulted in conflicts with the original python-gnupg and since its
174 functions were called in a different manner to python-gnupg, the
175 release of this package also resulted in a great deal of consternation
176 when people installed what they thought was an upgrade that
177 subsequently broke the code relying on it.
178
179 The gnupg package is available under the GNU General Public License
180 version 3.0 (or any later version).
181
182
183 \subsubsection{The PyME package maintained by Martin Albrecht}
184 \label{sec:org715600b}
185 This package is the origin of these bindings, though they are somewhat
186 different now. For details of when and how the PyME package was
187 folded back into GPGME itself see the \href{short-history.org}{Short History} document.\footnote{\texttt{short-history} and/or \texttt{short-history.html}.}
188
189 The PyME package was first released in 2002 and was also the first
190 attempt to implement a low level binding to GPGME. In doing so it
191 provided access to considerably more functionality than either the
192 \texttt{python-gnupg} or \texttt{gnupg} packages.
193
194 The PyME package is only available for Python 2.6 and 2.7.
195
196 Porting the PyME package to Python 3.4 in 2015 is what resulted in it
197 being folded into the GPGME project and the current bindings are the
198 end result of that effort.
199
200 The PyME package is available under the same dual licensing as GPGME
201 itself: the GNU General Public License version 2.0 (or any later
202 version) and the GNU Lesser General Public License version 2.1 (or any
203 later version).
204
205
206 \section{GPGME Python bindings installation}
207 \label{sec:org73d8d6f}
208 \subsection{No PyPI}
209 \label{sec:orgec9a038}
210 Most third-party Python packages and modules are available and
211 distributed through the Python Package Installer, known as PyPI.
212
213 Due to the nature of what these bindings are and how they work, it is
214 infeasible to install the GPGME Python bindings in the same way.
215
216 This is because the bindings use SWIG to dynamically generate C
217 bindings against \texttt{gpgme.h} and \texttt{gpgme.h} is generated from
218 \texttt{gpgme.h.in} at compile time when GPGME is built from source. Thus to
219 include a package in PyPI which actually built correctly would require
220 either statically built libraries for every architecture bundled with
221 it or a full implementation of C for each architecture.
222
223 See the additional notes regarding \hyperref[sec:org645735a]{CFFI and SWIG} at the end of this
224 section for further details.
225
226
227 \subsection{Requirements}
228 \label{sec:org2f7f06c}
229 The GPGME Python bindings only have three requirements:
230
231 \begin{enumerate}
232 \item A suitable version of Python 2 or Python 3. With Python 2 that
233 means CPython 2.7 and with Python 3 that means CPython 3.4 or
234 higher.
235 \item \href{https://www.swig.org}{SWIG}.
236 \item GPGME itself. Which also means that all of GPGME's dependencies
237 must be installed too.
238 \end{enumerate}
239
240
241 \subsubsection{Recommended Additions}
242 \label{sec:org25bd7d4}
243 Though none of the following are absolute requirements, they are all
244 recommended for use with the Python bindings. In some cases these
245 recommendations refer to which version(s) of CPython to use the
246 bindings with, while others refer to third party modules which provide
247 a significant advantage in some way.
248
249 \begin{enumerate}
250 \item If possible, use Python 3 instead of 2.
251 \item Favour a more recent version of Python since even 3.4 is due to
252 reach EOL soon. In production systems and services, Python 3.6
253 should be robust enough to be relied on.
254 \item If possible add the following Python modules which are not part of
255 the standard library: \href{http://docs.python-requests.org/en/latest/index.html}{Requests}, \href{https://cython.org/}{Cython}, \href{https://pendulum.eustace.io/}{Pendulum} and \href{https://github.com/Selfnet/hkp4py}{hkp4py}.
256 \end{enumerate}
257
258 Chances are quite high that at least the first one and maybe two of
259 those will already be installed.
260
261 Note that, as with Cython, some of advanced use case scenarios will
262 bring with them additional requirements. Most of these will be fairly
263 well known and commonly installed ones, however, which are in many
264 cases likely to have already been installed on many systems or be
265 familiar to Python programmers.
266
267
268 \subsection{Installation}
269 \label{sec:orgf1c7587}
270 Installing the Python bindings is effectively achieved by compiling
271 and installing GPGME itself.
272
273 Once SWIG is installed with Python and all the dependencies for GPGME
274 are installed you only need to confirm that the version(s) of Python
275 you want the bindings installed for are in your \texttt{\$PATH}.
276
277 By default GPGME will attempt to install the bindings for the most
278 recent or highest version number of Python 2 and Python 3 it detects
279 in \texttt{\$PATH}. It specifically checks for the \texttt{python} and \texttt{python3}
280 executables first and then checks for specific version numbers.
281
282 For Python 2 it checks for these executables in this order: \texttt{python},
283 \texttt{python2} and \texttt{python2.7}.
284
285 For Python 3 it checks for these executables in this order: \texttt{python3},
286 \texttt{python3.7}, \texttt{python3.6}, \texttt{python3.5} and \texttt{python3.4}.\footnote{With no issues reported specific to Python 3.7, the release of
287 Python 3.7.1 at around the same time as GPGME 1.12.0 and the testing
288 with Python 3.7.1rc1, there is no reason to delay moving 3.7 ahead of
289 3.6 now. Production environments with more conservative requirements
290 will always enforce their own policies anyway and installation to each
291 supported minor release is quite possible too.}
292
293 On systems where \texttt{python} is actually \texttt{python3} and not \texttt{python2} it
294 may be possible that \texttt{python2} may be overlooked, but there have been
295 no reports of that actually occurring as yet.
296
297 In the three months or so since the release of Python 3.7.0 there has
298 been extensive testing and work with these bindings with no issues
299 specifically relating to the new version of Python or any of the new
300 features of either the language or the bindings. This has also been
301 the case with Python 3.7.1rc1. With that in mind and given the
302 release of Python 3.7.1 is scheduled for around the same time as GPGME
303 1.12.0, the order of preferred Python versions has been changed to
304 move Python 3.7 ahead of Python 3.6.
305
306
307 \subsubsection{Installing GPGME}
308 \label{sec:org903bd67}
309 See the GPGME \texttt{README} file for details of how to install GPGME from
310 source.
311
312
313 \subsection{Known Issues}
314 \label{sec:org0d2a332}
315 There are a few known issues with the current build process and the
316 Python bindings. For the most part these are easily addressed should
317 they be encountered.
318
319
320 \subsubsection{Breaking Builds}
321 \label{sec:orgbac75f3}
322 Occasionally when installing GPGME with the Python bindings included
323 it may be observed that the \texttt{make} portion of that process induces a
324 large very number of warnings and, eventually errors which end that
325 part of the build process. Yet following that with \texttt{make check} and
326 \texttt{make install} appears to work seamlessly.
327
328 The cause of this is related to the way SWIG needs to be called to
329 dynamically generate the C bindings for GPGME in the first place. So
330 the entire process will always produce \texttt{lang/python/python2-gpg/} and
331 \texttt{lang/python/python3-gpg/} directories. These should contain the
332 build output generated during compilation, including the complete
333 bindings and module installed into \texttt{site-packages}.
334
335 Occasionally the errors in the early part or some other conflict
336 (e.g. not installing as \textbf{\emph{root}} or \textbf{\emph{su}}) may result in nothing
337 being installed to the relevant \texttt{site-packages} directory and the
338 build directory missing a lot of expected files. Even when this
339 occurs, the solution is actually quite simple and will always work.
340
341 That solution is simply to run the following commands as either the
342 \textbf{root} user or prepended with \texttt{sudo -H}\footnote{Yes, even if you use virtualenv with everything you do in
343 Python. If you want to install this module as just your user account
344 then you will need to manually configure, compile and install the
345 \emph{entire} GnuPG stack as that user as well. This includes libraries
346 which are not often installed that way. It can be done and there are
347 circumstances under which it is worthwhile, but generally only on
348 POSIX systems which utilise single user mode (some even require it).} in the \texttt{lang/python/}
349 directory:
350
351 \begin{verbatim}
352 /path/to/pythonX.Y setup.py build
353 /path/to/pythonX.Y setup.py build
354 /path/to/pythonX.Y setup.py install
355 \end{verbatim}
356
357 Yes, the build command does need to be run twice. Yes, you still need
358 to run the potentially failing or incomplete steps during the
359 \texttt{configure}, \texttt{make} and \texttt{make install} steps with installing GPGME.
360 This is because those steps generate a lot of essential files needed,
361 both by and in order to create, the bindings (including both the
362 \texttt{setup.py} and \texttt{gpgme.h} files).
363
364
365 \begin{enumerate}
366 \item IMPORTANT Note
367 \label{sec:org37f3d4a}
368 If specifying a selected number of languages to create bindings for,
369 try to leave Python last. Currently the majority of the other
370 language bindings are also preceding Python of either version when
371 listed alphabetically (not counting the Qt bindings).
372
373 If Python is set to precede one of the other languages then it is
374 possible that the errors described here may interrupt the build
375 process before generating bindings for those other languages. In
376 these cases it may be preferable to configure all preferred language
377 bindings separately with alternative \texttt{configure} steps for GPGME using
378 the \texttt{-{}-enable-languages=\$LANGUAGE} option.
379
380 Alternatively \texttt{make} (or \texttt{gmake}, depending on your platform) may be
381 run with the the \texttt{-k} option, which tells make to keep going even if
382 errors are encountered. In that case the failure of one language's
383 set of bindings to build should not hamper another language's bindings
384 to build.
385 \end{enumerate}
386
387
388 \subsubsection{Reinstalling Responsibly}
389 \label{sec:org21e4dec}
390 Regardless of whether you're installing for one version of Python or
391 several, there will come a point where reinstallation is required.
392 With most Python module installations, the installed files go into the
393 relevant site-packages directory and are then forgotten about. Then
394 the module is upgraded, the new files are copied over the old and
395 that's the end of the matter.
396
397 While the same is true of these bindings, there have been intermittent
398 issues observed on some platforms which have benefited significantly
399 from removing all the previous installations of the bindings before
400 installing the updated versions.
401
402 Removing the previous version(s) is simply a matter of changing to the
403 relevant \texttt{site-packages} directory for the version of Python in
404 question and removing the \texttt{gpg/} directory and any accompanying
405 egg-info files for that module.
406
407 In most cases this will require root or administration privileges on
408 the system, but the same is true of installing the module in the first
409 place.
410
411
412 \subsubsection{Multiple installations}
413 \label{sec:org30b18bd}
414 For a variety of reasons it may be either necessary or just preferable
415 to install the bindings to alternative installed Python versions which
416 meet the requirements of these bindings.
417
418 On POSIX systems this will generally be most simply achieved by
419 running the manual installation commands (build, build, install) as
420 described in the previous section for each Python installation the
421 bindings need to be installed to.
422
423 As per the SWIG documentation: the compilers, libraries and runtime
424 used to build GPGME and the Python Bindings \textbf{must} match those used to
425 compile Python itself, including the version number(s) (at least going
426 by major version numbers and probably minor numbers too).
427
428 On most POSIX systems, including OS X, this will very likely be the
429 case in most, if not all, cases.
430
431 Note that from GPGME \href{https://dev.gnupg.org/rMff6ff616aea6f59b7f2ce1176492850ecdf3851e}{1.12.1} the default installation installs to each
432 version of Python it can find first. That is that it will currently
433 install for the first copies of Python versions 2.7, 3.4, 3.5, 3.6,
434 3.7 and 3.8 (dev branch) that it finds. Usually this will be in the
435 same prefix as GPGME itself, but is dictated by the \texttt{\$PATH} when the
436 installation is performed. The above instructions can still be
437 performed on other python installations which the installer does not
438 find, including alternative prefixes.
439
440
441
442 \subsubsection{Won't Work With Windows}
443 \label{sec:org0ebae3a}
444 There are semi-regular reports of Windows users having considerable
445 difficulty in installing and using the Python bindings at all. Very
446 often, possibly even always, these reports come from Cygwin users
447 and/or MinGW users and/or Msys2 users. Though not all of them have
448 been confirmed, it appears that these reports have also come from
449 people who installed Python using the Windows installer files from the
450 \href{https://python.org}{Python website} (i.e. mostly MSI installers, sometimes self-extracting
451 \texttt{.exe} files).
452
453 The Windows versions of Python are not built using Cygwin, MinGW or
454 Msys2; they're built using Microsoft Visual Studio. Furthermore the
455 version used is \emph{considerably} more advanced than the version which
456 MinGW obtained a small number of files from many years ago in order to
457 be able to compile anything at all. Not only that, but there are
458 changes to the version of Visual Studio between some micro releases,
459 though that is is particularly the case with Python 2.7, since it has
460 been kept around far longer than it should have been.
461
462 There are two theoretical solutions to this issue:
463
464 \begin{enumerate}
465 \item Compile and install the GnuPG stack, including GPGME and the
466 Python bindings using the same version of Microsoft Visual Studio
467 used by the Python Foundation to compile the version of Python
468 installed.
469
470 If there are multiple versions of Python then this will need to be
471 done with each different version of Visual Studio used for those
472 versions of Python.
473
474 \item Compile and install Python using the same tools used by choice,
475 such as MinGW or Msys2.
476 \end{enumerate}
477
478 Do \textbf{not} use the official Windows installer for Python unless
479 following the first method.
480
481 In this type of situation it may even be for the best to accept that
482 there are less limitations on permissive software than free software
483 and simply opt to use a recent version of the Community Edition of
484 Microsoft Visual Studio to compile and build all of it, no matter
485 what.
486
487 Investigations into the extent or the limitations of this issue are
488 ongoing.
489
490 The following table lists the version of Microsoft Visual Studio which
491 needs to be used when compiling GPGME and the Python bindings with
492 each version of the CPython binary released \href{https://www.python.org/downloads/windows/}{for Windows}:
493
494 \begin{center}
495 \begin{tabular}{rll}
496 CPython & Microsoft product name & runtime filename\\
497 2.7.6 & Visual Studio 2008 & MSVCR90.DLL\\
498 3.4.0 & Visual Studio 2010 & MSVCR100.DLL\\
499 3.5.0 & Visual Studio 2015 & \textbf{see below}\\
500 3.6.0 & Visual Studio 2015 & \textbf{see below}\\
501 3.7.0 & Visual Studio 2017* & \textbf{see below}\\
502 \end{tabular}
503 \end{center}
504
505 It is important to note that MingW and Msys2 ship with the Visual C
506 runtime from Microsoft Visual Studio 2005 and are thus \textbf{incompatible}
507 with all the versions of CPython which can be used with the GPGME
508 Python bindings.
509
510 It is also important to note that from CPython 3.5 onwards, the Python
511 Foundation has adopted the reworking of the Visual C runtime which was
512 performed for Visual Studio 2015 and aimed at resolving many of these
513 kinds of issues. Much greater detail on these issues and the correct
514 file(s) to link to are available from Matthew Brett's invaluable page,
515 \href{https://matthew-brett.github.io/pydagogue/python\_msvc.html}{Using Microsoft Visual C with Python}. It is also worth reading the
516 Microsoft Developer Network blog post on \href{http://blogs.msdn.com/b/vcblog/archive/2015/03/03/introducing-the-universal-crt.aspx}{the universal CRT} and Steve
517 Dower's blog posts on Python extensions (\href{http://stevedower.id.au/blog/building-for-python-3-5}{part 1} and \href{http://stevedower.id.au/blog/building-for-python-3-5-part-two}{part 2}).
518
519 The second of those two posts by Steve Dower contains the details of
520 specific configuration options required for compiling anything to be
521 used with official CPython releases. In addition to those
522 configuration and compiler settings to use, the versions of Visual
523 Studio prior to Visual Studio 2015 did not support 64-bit systems by
524 default. So compiling a 64-bit version of these bindings for a 64-bit
525 version of CPython 2.7 or 3.4 requires additional work.
526
527 In addition to the blog posts, the \href{https://wiki.python.org/moin/WindowsCompilers}{Windows compilers} wiki page on the
528 CPython wiki is another essential reference on the relevant versions
529 of Visual Studio to use and the degree of compatibility with CPython
530 releases.
531
532 Eventually someone will ask why there isn't an installable binary for
533 Windows, which the GPGME of the licenses do not preclude as long as
534 the source code is available in conjunction with such a release.
535
536 The sheer number of versions of Visual Studio in conjunction with
537 differing configuration options depending on the target Windows
538 version and whether the architecture is 64-bit or 32-bit makes it
539 difficult to provide a correct binary installer for Windows users. At
540 the bare minimum doing so would require the GnuPG project compile ten
541 different versions of the bindings with each release; both 32-bit and
542 64-bit versions for CPython 2.7 and 3.4, with 64-bit versions for both
543 x86-64 (i.e. Intel and AMD) and ARM architectures for CPython 3.5,
544 3.6, 3.7 and later releases. That's the bare \textbf{minimum}, it'd probably
545 be higher.
546
547 Additionally, with only a binary installation used in conjunction with
548 the CPython installer from \texttt{python.org} the advanced options available
549 which utilise \hyperref[sec:org3b53926]{Cython} will not be able to be used at all. Cython
550 depends on being able to compile the C code it generates and that too
551 would need to utilise a matching runtime to both the installed version
552 of CPython and these bindings in order to work with the bindings.
553
554 Considering all of that, what do we recommend?
555
556 \begin{enumerate}
557 \item Use a recent version of CPython; at least 3.5, but ideally 3.6 or
558 later.
559
560 \item Use Visual Studio 2015 or the standalone build tools for Visual
561 Studio 2017 (or later).
562
563 \item Compile both CPython and GPGME with these bindings using the tools
564 selected in step 2.
565
566 \item Ignore MingW, Msys2 and the official CPython binary installers.
567
568 \item Be thankful the answer to this question wasn't simply to say
569 something like, “install Linux” or “install FreeBSD” (or even
570 Apple's OS X).
571 \end{enumerate}
572
573
574 \subsubsection{CFFI is the Best™ and GPGME should use it instead of SWIG}
575 \label{sec:org645735a}
576 There are many reasons for favouring \href{https://cffi.readthedocs.io/en/latest/overview.html}{CFFI} and proponents of it are
577 quite happy to repeat these things as if all it would take to switch
578 from SWIG to CFFI is repeating that list as if it were a new concept.
579
580 The fact is that there are things which Python's CFFI implementation
581 cannot handle in the GPGME C code. Beyond that there are features of
582 SWIG which are simply not available with CFFI at all. SWIG generates
583 the bindings to Python using the \texttt{gpgme.h} file, but that file is not
584 a single version shipped with each release, it too is generated when
585 GPGME is compiled.
586
587 CFFI is currently unable to adapt to such a potentially mutable
588 codebase. If there were some means of applying SWIG's dynamic code
589 generation to produce the Python/CFFI API modes of accessing the GPGME
590 libraries (or the source source code directly), but such a thing does
591 not exist yet either and it currently appears that work is needed in
592 at least one of CFFI's dependencies before any of this can be
593 addressed.
594
595 So if you're a massive fan of CFFI; that's great, but if you want this
596 project to switch to CFFI then rather than just insisting that it
597 should, I'd suggest you volunteer to bring CFFI up to the level this
598 project needs.
599
600 If you're actually seriously considering doing so, then I'd suggest
601 taking the \texttt{gpgme-tool.c} file in the GPGME \texttt{src/} directory and
602 getting that to work with any of the CFFI API methods (not the ABI
603 methods, they'll work with pretty much anything). When you start
604 running into trouble with "ifdefs" then you'll know what sort of
605 things are lacking. That doesn't even take into account the amount of
606 work saved via SWIG's code generation techniques either.
607
608
609 \subsubsection{Virtualised Environments}
610 \label{sec:orgb0d56f5}
611 It is fairly common practice amongst Python developers to, as much as
612 possible, use packages like virtualenv to keep various things that are
613 to be installed from interfering with each other. Given how much of
614 the GPGME bindings is often at odds with the usual pythonic way of
615 doing things, it stands to reason that this would be called into
616 question too.
617
618 As it happens the answer as to whether or not the bindings can be used
619 with virtualenv, the answer is both yes and no.
620
621 In general we recommend installing to the relevant path and matching
622 prefix of GPGME itself. Which means that when GPGME, and ideally the
623 rest of the GnuPG stack, is installed to a prefix like \texttt{/usr/local} or
624 \texttt{/opt/local} then the bindings would need to be installed to the main
625 Python installation and not a virtualised abstraction. Attempts to
626 separate the two in the past have been known to cause weird and
627 intermittent errors ranging from minor annoyances to complete failures
628 in the build process.
629
630 As a consequence we only recommend building with and installing to the
631 main Python installations within the same prefix as GPGME is installed
632 to or which are found by GPGME's configuration stage immediately prior
633 to running the make commands. Which is exactly what the compiling and
634 installing process of GPGME does by default.
635
636 Once that is done, however, it appears that a copy of the compiled
637 module may be installed into a virtualenv of the same major and minor
638 version matching the build. Alternatively it is possible to utilise a
639 \texttt{sites.pth} file in the \texttt{site-packages/} directory of a virtualenv
640 installation, which links back to the system installations
641 corresponding directory in order to import anything installed system
642 wide. This may or may not be appropriate on a case by case basis.
643
644 Though extensive testing of either of these options is not yet
645 complete, preliminary testing of them indicates that both are viable
646 as long as the main installation is complete. Which means that
647 certain other options normally restricted to virtual environments are
648 also available, including integration with pythonic test suites
649 (e.g. \href{https://docs.pytest.org/en/latest/index.html}{pytest}) and other large projects.
650
651 That said, it is worth reiterating the warning regarding non-standard
652 installations. If one were to attempt to install the bindings only to
653 a virtual environment without somehow also including the full GnuPG
654 stack (or enough of it as to include GPGME) then it is highly likely
655 that errors would be encountered at some point and more than a little
656 likely that the build process itself would break.
657
658 If a degree of separation from the main operating system is still
659 required in spite of these warnings, then consider other forms of
660 virtualisation. Either a virtual machine (e.g. \href{https://www.virtualbox.org/}{VirtualBox}), a
661 hardware emulation layer (e.g. \href{https://www.qemu.org/}{QEMU}) or an application container
662 (e.g. \href{https://www.docker.com/why-docker}{Docker}).
663
664 Finally it should be noted that the limited tests conducted thus far
665 have been using the \texttt{virtualenv} command in a new directory to create
666 the virtual python environment. As opposed to the standard \texttt{python3
667 -m venv} and it is possible that this will make a difference depending
668 on the system and version of Python in use. Another option is to run
669 the command \texttt{python3 -m virtualenv /path/to/install/virtual/thingy}
670 instead.
671
672
673 \section{Fundamentals}
674 \label{sec:org832642e}
675 Before we can get to the fun stuff, there are a few matters regarding
676 GPGME's design which hold true whether you're dealing with the C code
677 directly or these Python bindings.
678
679
680 \subsection{No REST}
681 \label{sec:org3d694ba}
682 The first part of which is or will be fairly blatantly obvious upon
683 viewing the first example, but it's worth reiterating anyway. That
684 being that this API is \emph{\textbf{not}} a REST API. Nor indeed could it ever
685 be one.
686
687 Most, if not all, Python programmers (and not just Python programmers)
688 know how easy it is to work with a RESTful API. In fact they've
689 become so popular that many other APIs attempt to emulate REST-like
690 behaviour as much as they are able. Right down to the use of JSON
691 formatted output to facilitate the use of their API without having to
692 retrain developers.
693
694 This API does not do that. It would not be able to do that and also
695 provide access to the entire C API on which it's built. It does,
696 however, provide a very pythonic interface on top of the direct
697 bindings and it's this pythonic layer that this HOWTO deals with.
698
699
700 \subsection{Context}
701 \label{sec:org10e4004}
702 One of the reasons which prevents this API from being RESTful is that
703 most operations require more than one instruction to the API to
704 perform the task. Sure, there are certain functions which can be
705 performed simultaneously, particularly if the result known or strongly
706 anticipated (e.g. selecting and encrypting to a key known to be in the
707 public keybox).
708
709 There are many more, however, which cannot be manipulated so readily:
710 they must be performed in a specific sequence and the result of one
711 operation has a direct bearing on the outcome of subsequent
712 operations. Not merely by generating an error either.
713
714 When dealing with this type of persistent state on the web, full of
715 both the RESTful and REST-like, it's most commonly referred to as a
716 session. In GPGME, however, it is called a context and every
717 operation type has one.
718
719
720 \section{Working with keys}
721 \label{sec:orgff114ca}
722 \subsection{Key selection}
723 \label{sec:org6589217}
724 Selecting keys to encrypt to or to sign with will be a common
725 occurrence when working with GPGMe and the means available for doing
726 so are quite simple.
727
728 They do depend on utilising a Context; however once the data is
729 recorded in another variable, that Context does not need to be the
730 same one which subsequent operations are performed.
731
732 The easiest way to select a specific key is by searching for that
733 key's key ID or fingerprint, preferably the full fingerprint without
734 any spaces in it. A long key ID will probably be okay, but is not
735 advised and short key IDs are already a problem with some being
736 generated to match specific patterns. It does not matter whether the
737 pattern is upper or lower case.
738
739 So this is the best method:
740
741 \begin{verbatim}
742 import gpg
743
744 k = gpg.Context().keylist(pattern="258E88DCBD3CD44D8E7AB43F6ECB6AF0DEADBEEF")
745 keys = list(k)
746 \end{verbatim}
747
748 This is passable and very likely to be common:
749
750 \begin{verbatim}
751 import gpg
752
753 k = gpg.Context().keylist(pattern="0x6ECB6AF0DEADBEEF")
754 keys = list(k)
755 \end{verbatim}
756
757 And this is a really bad idea:
758
759 \begin{verbatim}
760 import gpg
761
762 k = gpg.Context().keylist(pattern="0xDEADBEEF")
763 keys = list(k)
764 \end{verbatim}
765
766 Alternatively it may be that the intention is to create a list of keys
767 which all match a particular search string. For instance all the
768 addresses at a particular domain, like this:
769
770 \begin{verbatim}
771 import gpg
772
773 ncsc = gpg.Context().keylist(pattern="ncsc.mil")
774 nsa = list(ncsc)
775 \end{verbatim}
776
777
778 \subsubsection{Counting keys}
779 \label{sec:org63a3d62}
780 Counting the number of keys in your public keybox (\texttt{pubring.kbx}), the
781 format which has superseded the old keyring format (\texttt{pubring.gpg} and
782 \texttt{secring.gpg}), or the number of secret keys is a very simple task.
783
784 \begin{verbatim}
785 import gpg
786
787 c = gpg.Context()
788 seckeys = c.keylist(pattern=None, secret=True)
789 pubkeys = c.keylist(pattern=None, secret=False)
790
791 seclist = list(seckeys)
792 secnum = len(seclist)
793
794 publist = list(pubkeys)
795 pubnum = len(publist)
796
797 print("""
798 Number of secret keys: {0}
799 Number of public keys: {1}
800 """.format(secnum, pubnum))
801 \end{verbatim}
802
803 NOTE: The \hyperref[sec:org3b53926]{Cython} introduction in the \hyperref[sec:org944cc00]{Advanced and Experimental}
804 section uses this same key counting code with Cython to demonstrate
805 some areas where Cython can improve performance even with the
806 bindings. Users with large public keyrings or keyboxes, for instance,
807 should consider these options if they are comfortable with using
808 Cython.
809
810
811 \subsection{Get key}
812 \label{sec:org26adb2e}
813 An alternative method of getting a single key via its fingerprint is
814 available directly within a Context with \texttt{Context().get\_key}. This is
815 the preferred method of selecting a key in order to modify it, sign or
816 certify it and for obtaining relevant data about a single key as a
817 part of other functions; when verifying a signature made by that key,
818 for instance.
819
820 By default this method will select public keys, but it can select
821 secret keys as well.
822
823 This first example demonstrates selecting the current key of Werner
824 Koch, which is due to expire at the end of 2018:
825
826 \begin{verbatim}
827 import gpg
828
829 fingerprint = "80615870F5BAD690333686D0F2AD85AC1E42B367"
830 key = gpg.Context().get_key(fingerprint)
831 \end{verbatim}
832
833 Whereas this example demonstrates selecting the author's current key
834 with the \texttt{secret} key word argument set to \texttt{True}:
835
836 \begin{verbatim}
837 import gpg
838
839 fingerprint = "DB4724E6FA4286C92B4E55C4321E4E2373590E5D"
840 key = gpg.Context().get_key(fingerprint, secret=True)
841 \end{verbatim}
842
843 It is, of course, quite possible to select expired, disabled and
844 revoked keys with this function, but only to effectively display
845 information about those keys.
846
847 It is also possible to use both unicode or string literals and byte
848 literals with the fingerprint when getting a key in this way.
849
850
851 \subsection{Importing keys}
852 \label{sec:org1ad598a}
853 Importing keys is possible with the \texttt{key\_import()} method and takes
854 one argument which is a bytes literal object containing either the
855 binary or ASCII armoured key data for one or more keys.
856
857 The following example retrieves one or more keys from the SKS
858 keyservers via the web using the requests module. Since requests
859 returns the content as a bytes literal object, we can then use that
860 directly to import the resulting data into our keybox.
861
862 \begin{verbatim}
863 import gpg
864 import os.path
865 import requests
866
867 c = gpg.Context()
868 url = "https://sks-keyservers.net/pks/lookup"
869 pattern = input("Enter the pattern to search for key or user IDs: ")
870 payload = {"op": "get", "search": pattern}
871
872 r = requests.get(url, verify=True, params=payload)
873 result = c.key_import(r.content)
874
875 if result is not None and hasattr(result, "considered") is False:
876 print(result)
877 elif result is not None and hasattr(result, "considered") is True:
878 num_keys = len(result.imports)
879 new_revs = result.new_revocations
880 new_sigs = result.new_signatures
881 new_subs = result.new_sub_keys
882 new_uids = result.new_user_ids
883 new_scrt = result.secret_imported
884 nochange = result.unchanged
885 print("""
886 The total number of keys considered for import was: {0}
887
888 Number of keys revoked: {1}
889 Number of new signatures: {2}
890 Number of new subkeys: {3}
891 Number of new user IDs: {4}
892 Number of new secret keys: {5}
893 Number of unchanged keys: {6}
894
895 The key IDs for all considered keys were:
896 """.format(num_keys, new_revs, new_sigs, new_subs, new_uids, new_scrt,
897 nochange))
898 for i in range(num_keys):
899 print("{0}\n".format(result.imports[i].fpr))
900 else:
901 pass
902 \end{verbatim}
903
904 NOTE: When searching for a key ID of any length or a fingerprint
905 (without spaces), the SKS servers require the the leading \texttt{0x}
906 indicative of hexadecimal be included. Also note that the old short
907 key IDs (e.g. \texttt{0xDEADBEEF}) should no longer be used due to the
908 relative ease by which such key IDs can be reproduced, as demonstrated
909 by the Evil32 Project in 2014 (which was subsequently exploited in
910 2016).
911
912 Testing for whether a string in any given search is or may be a
913 hexadecimal value which may be missing the leading \texttt{0x} is a simple
914 matter of using a try/except statement which attempts to convert the
915 string as hex to an integer and then back to hex; then using that to
916 search with. Raising a ValueError simply results in treating the
917 string as a string. This is the method and logic utilised in the
918 \texttt{import-keys-hkp.py} script (see below).
919
920
921 \subsubsection{Working with ProtonMail}
922 \label{sec:org27b0d6f}
923 Here is a variation on the example above which checks the constrained
924 ProtonMail keyserver for ProtonMail public keys.
925
926 \begin{verbatim}
927 import gpg
928 import requests
929 import sys
930
931 print("""
932 This script searches the ProtonMail key server for the specified key and
933 imports it.
934 """)
935
936 c = gpg.Context(armor=True)
937 url = "https://api.protonmail.ch/pks/lookup"
938 ksearch = []
939
940 if len(sys.argv) >= 2:
941 keyterm = sys.argv[1]
942 else:
943 keyterm = input("Enter the key ID, UID or search string: ")
944
945 if keyterm.count("@") == 2 and keyterm.startswith("@") is True:
946 ksearch.append(keyterm[1:])
947 ksearch.append(keyterm[1:])
948 ksearch.append(keyterm[1:])
949 elif keyterm.count("@") == 1 and keyterm.startswith("@") is True:
950 ksearch.append("{0}@protonmail.com".format(keyterm[1:]))
951 ksearch.append("{0}@protonmail.ch".format(keyterm[1:]))
952 ksearch.append("{0}@pm.me".format(keyterm[1:]))
953 elif keyterm.count("@") == 0:
954 ksearch.append("{0}@protonmail.com".format(keyterm))
955 ksearch.append("{0}@protonmail.ch".format(keyterm))
956 ksearch.append("{0}@pm.me".format(keyterm))
957 elif keyterm.count("@") == 2 and keyterm.startswith("@") is False:
958 uidlist = keyterm.split("@")
959 for uid in uidlist:
960 ksearch.append("{0}@protonmail.com".format(uid))
961 ksearch.append("{0}@protonmail.ch".format(uid))
962 ksearch.append("{0}@pm.me".format(uid))
963 elif keyterm.count("@") > 2:
964 uidlist = keyterm.split("@")
965 for uid in uidlist:
966 ksearch.append("{0}@protonmail.com".format(uid))
967 ksearch.append("{0}@protonmail.ch".format(uid))
968 ksearch.append("{0}@pm.me".format(uid))
969 else:
970 ksearch.append(keyterm)
971
972 for k in ksearch:
973 payload = {"op": "get", "search": k}
974 try:
975 r = requests.get(url, verify=True, params=payload)
976 if r.ok is True:
977 result = c.key_import(r.content)
978 elif r.ok is False:
979 result = r.content
980 except Exception as e:
981 result = None
982
983 if result is not None and hasattr(result, "considered") is False:
984 print("{0} for {1}".format(result.decode(), k))
985 elif result is not None and hasattr(result, "considered") is True:
986 num_keys = len(result.imports)
987 new_revs = result.new_revocations
988 new_sigs = result.new_signatures
989 new_subs = result.new_sub_keys
990 new_uids = result.new_user_ids
991 new_scrt = result.secret_imported
992 nochange = result.unchanged
993 print("""
994 The total number of keys considered for import was: {0}
995
996 With UIDs wholely or partially matching the following string:
997
998 {1}
999
1000 Number of keys revoked: {2}
1001 Number of new signatures: {3}
1002 Number of new subkeys: {4}
1003 Number of new user IDs: {5}
1004 Number of new secret keys: {6}
1005 Number of unchanged keys: {7}
1006
1007 The key IDs for all considered keys were:
1008 """.format(num_keys, k, new_revs, new_sigs, new_subs, new_uids, new_scrt,
1009 nochange))
1010 for i in range(num_keys):
1011 print(result.imports[i].fpr)
1012 print("")
1013 elif result is None:
1014 print(e)
1015 \end{verbatim}
1016
1017 Both the above example, \href{../examples/howto/pmkey-import.py}{pmkey-import.py}, and a version which prompts
1018 for an alternative GnuPG home directory, \href{../examples/howto/pmkey-import-alt.py}{pmkey-import-alt.py}, are
1019 available with the other examples and are executable scripts.
1020
1021 Note that while the ProtonMail servers are based on the SKS servers,
1022 their server is related more to their API and is not feature complete
1023 by comparison to the servers in the SKS pool. One notable difference
1024 being that the ProtonMail server does not permit non ProtonMail users
1025 to update their own keys, which could be a vector for attacking
1026 ProtonMail users who may not receive a key's revocation if it had been
1027 compromised.
1028
1029
1030 \subsubsection{Importing with HKP for Python}
1031 \label{sec:org592d7ab}
1032 Performing the same tasks with the \href{https://github.com/Selfnet/hkp4py}{hkp4py module} (available via PyPI)
1033 is not too much different, but does provide a number of options of
1034 benefit to end users. Not least of which being the ability to perform
1035 some checks on a key before importing it or not. For instance it may
1036 be the policy of a site or project to only import keys which have not
1037 been revoked. The hkp4py module permits such checks prior to the
1038 importing of the keys found.
1039
1040 \begin{verbatim}
1041 import gpg
1042 import hkp4py
1043 import sys
1044
1045 c = gpg.Context()
1046 server = hkp4py.KeyServer("hkps://hkps.pool.sks-keyservers.net")
1047 results = []
1048 keys = []
1049
1050 if len(sys.argv) > 2:
1051 pattern = " ".join(sys.argv[1:])
1052 elif len(sys.argv) == 2:
1053 pattern = sys.argv[1]
1054 else:
1055 pattern = input("Enter the pattern to search for keys or user IDs: ")
1056
1057
1058 if pattern is not None:
1059 try:
1060 key = server.search(hex(int(pattern, 16)))
1061 keyed = True
1062 except ValueError as ve:
1063 key = server.search(pattern)
1064 keyed = False
1065
1066 if key is not None:
1067 keys.append(key[0])
1068 if keyed is True:
1069 try:
1070 fob = server.search(pattern)
1071 except:
1072 fob = None
1073 if fob is not None:
1074 keys.append(fob[0])
1075 else:
1076 pass
1077 else:
1078 pass
1079
1080 for logrus in pattern.split():
1081 try:
1082 key = server.search(hex(int(logrus, 16)))
1083 hexed = True
1084 except ValueError as ve:
1085 key = server.search(logrus)
1086 hexed = False
1087
1088 if key is not None:
1089 keys.append(key[0])
1090 if hexed is True:
1091 try:
1092 fob = server.search(logrus)
1093 except:
1094 fob = None
1095 if fob is not None:
1096 keys.append(fob[0])
1097 else:
1098 pass
1099 else:
1100 pass
1101
1102
1103 if len(keys) > 0:
1104 for key in keys:
1105 import_result = c.key_import(key.key_blob)
1106 results.append(import_result)
1107
1108 for result in results:
1109 if result is not None and hasattr(result, "considered") is False:
1110 print(result)
1111 elif result is not None and hasattr(result, "considered") is True:
1112 num_keys = len(result.imports)
1113 new_revs = result.new_revocations
1114 new_sigs = result.new_signatures
1115 new_subs = result.new_sub_keys
1116 new_uids = result.new_user_ids
1117 new_scrt = result.secret_imported
1118 nochange = result.unchanged
1119 print("""
1120 The total number of keys considered for import was: {0}
1121
1122 Number of keys revoked: {1}
1123 Number of new signatures: {2}
1124 Number of new subkeys: {3}
1125 Number of new user IDs: {4}
1126 Number of new secret keys: {5}
1127 Number of unchanged keys: {6}
1128
1129 The key IDs for all considered keys were:
1130 """.format(num_keys, new_revs, new_sigs, new_subs, new_uids, new_scrt,
1131 nochange))
1132 for i in range(num_keys):
1133 print(result.imports[i].fpr)
1134 print("")
1135 else:
1136 pass
1137 \end{verbatim}
1138
1139 Since the hkp4py module handles multiple keys just as effectively as
1140 one (\texttt{keys} is a list of responses per matching key), the example
1141 above is able to do a little bit more with the returned data before
1142 anything is actually imported.
1143
1144
1145 \subsubsection{Importing from ProtonMail with HKP for Python}
1146 \label{sec:org3966a76}
1147 Though this can provide certain benefits even when working with
1148 ProtonMail, the scope is somewhat constrained there due to the
1149 limitations of the ProtonMail keyserver.
1150
1151 For instance, searching the SKS keyserver pool for the term "gnupg"
1152 produces hundreds of results from any time the word appears in any
1153 part of a user ID. Performing the same search on the ProtonMail
1154 keyserver returns zero results, even though there are at least two
1155 test accounts which include it as part of the username.
1156
1157 The cause of this discrepancy is the deliberate configuration of that
1158 server by ProtonMail to require an exact match of the full email
1159 address of the ProtonMail user whose key is being requested.
1160 Presumably this is intended to reduce breaches of privacy of their
1161 users as an email address must already be known before a key for that
1162 address can be obtained.
1163
1164
1165 \begin{enumerate}
1166 \item Import from ProtonMail via HKP for Python Example no. 1
1167 \label{sec:org6cd15c3}
1168 The following script is available with the rest of the examples under
1169 the somewhat less than original name, \texttt{pmkey-import-hkp.py}.
1170
1171 \begin{verbatim}
1172 import gpg
1173 import hkp4py
1174 import os.path
1175 import sys
1176
1177 print("""
1178 This script searches the ProtonMail key server for the specified key and
1179 imports it.
1180
1181 Usage: pmkey-import-hkp.py [search strings]
1182 """)
1183
1184 c = gpg.Context(armor=True)
1185 server = hkp4py.KeyServer("hkps://api.protonmail.ch")
1186 keyterms = []
1187 ksearch = []
1188 allkeys = []
1189 results = []
1190 paradox = []
1191 homeless = None
1192
1193 if len(sys.argv) > 2:
1194 keyterms = sys.argv[1:]
1195 elif len(sys.argv) == 2:
1196 keyterm = sys.argv[1]
1197 keyterms.append(keyterm)
1198 else:
1199 key_term = input("Enter the key ID, UID or search string: ")
1200 keyterms = key_term.split()
1201
1202 for keyterm in keyterms:
1203 if keyterm.count("@") == 2 and keyterm.startswith("@") is True:
1204 ksearch.append(keyterm[1:])
1205 ksearch.append(keyterm[1:])
1206 ksearch.append(keyterm[1:])
1207 elif keyterm.count("@") == 1 and keyterm.startswith("@") is True:
1208 ksearch.append("{0}@protonmail.com".format(keyterm[1:]))
1209 ksearch.append("{0}@protonmail.ch".format(keyterm[1:]))
1210 ksearch.append("{0}@pm.me".format(keyterm[1:]))
1211 elif keyterm.count("@") == 0:
1212 ksearch.append("{0}@protonmail.com".format(keyterm))
1213 ksearch.append("{0}@protonmail.ch".format(keyterm))
1214 ksearch.append("{0}@pm.me".format(keyterm))
1215 elif keyterm.count("@") == 2 and keyterm.startswith("@") is False:
1216 uidlist = keyterm.split("@")
1217 for uid in uidlist:
1218 ksearch.append("{0}@protonmail.com".format(uid))
1219 ksearch.append("{0}@protonmail.ch".format(uid))
1220 ksearch.append("{0}@pm.me".format(uid))
1221 elif keyterm.count("@") > 2:
1222 uidlist = keyterm.split("@")
1223 for uid in uidlist:
1224 ksearch.append("{0}@protonmail.com".format(uid))
1225 ksearch.append("{0}@protonmail.ch".format(uid))
1226 ksearch.append("{0}@pm.me".format(uid))
1227 else:
1228 ksearch.append(keyterm)
1229
1230 for k in ksearch:
1231 print("Checking for key for: {0}".format(k))
1232 try:
1233 keys = server.search(k)
1234 if isinstance(keys, list) is True:
1235 for key in keys:
1236 allkeys.append(key)
1237 try:
1238 import_result = c.key_import(key.key_blob)
1239 except Exception as e:
1240 import_result = c.key_import(key.key)
1241 else:
1242 paradox.append(keys)
1243 import_result = None
1244 except Exception as e:
1245 import_result = None
1246 results.append(import_result)
1247
1248 for result in results:
1249 if result is not None and hasattr(result, "considered") is False:
1250 print("{0} for {1}".format(result.decode(), k))
1251 elif result is not None and hasattr(result, "considered") is True:
1252 num_keys = len(result.imports)
1253 new_revs = result.new_revocations
1254 new_sigs = result.new_signatures
1255 new_subs = result.new_sub_keys
1256 new_uids = result.new_user_ids
1257 new_scrt = result.secret_imported
1258 nochange = result.unchanged
1259 print("""
1260 The total number of keys considered for import was: {0}
1261
1262 With UIDs wholely or partially matching the following string:
1263
1264 {1}
1265
1266 Number of keys revoked: {2}
1267 Number of new signatures: {3}
1268 Number of new subkeys: {4}
1269 Number of new user IDs: {5}
1270 Number of new secret keys: {6}
1271 Number of unchanged keys: {7}
1272
1273 The key IDs for all considered keys were:
1274 """.format(num_keys, k, new_revs, new_sigs, new_subs, new_uids, new_scrt,
1275 nochange))
1276 for i in range(num_keys):
1277 print(result.imports[i].fpr)
1278 print("")
1279 elif result is None:
1280 pass
1281 \end{verbatim}
1282
1283
1284 \item Import from ProtonMail via HKP for Python Example no. 2
1285 \label{sec:org3b674e5}
1286 Like its counterpart above, this script can also be found with the
1287 rest of the examples, by the name pmkey-import-hkp-alt.py.
1288
1289 With this script a modicum of effort has been made to treat anything
1290 passed as a \texttt{homedir} which either does not exist or which is not a
1291 directory, as also being a pssible user ID to check for. It's not
1292 guaranteed to pick up on all such cases, but it should cover most of
1293 them.
1294
1295 \begin{verbatim}
1296 import gpg
1297 import hkp4py
1298 import os.path
1299 import sys
1300
1301 print("""
1302 This script searches the ProtonMail key server for the specified key and
1303 imports it. Optionally enables specifying a different GnuPG home directory.
1304
1305 Usage: pmkey-import-hkp.py [homedir] [search string]
1306 or: pmkey-import-hkp.py [search string]
1307 """)
1308
1309 c = gpg.Context(armor=True)
1310 server = hkp4py.KeyServer("hkps://api.protonmail.ch")
1311 keyterms = []
1312 ksearch = []
1313 allkeys = []
1314 results = []
1315 paradox = []
1316 homeless = None
1317
1318 if len(sys.argv) > 3:
1319 homedir = sys.argv[1]
1320 keyterms = sys.argv[2:]
1321 elif len(sys.argv) == 3:
1322 homedir = sys.argv[1]
1323 keyterm = sys.argv[2]
1324 keyterms.append(keyterm)
1325 elif len(sys.argv) == 2:
1326 homedir = ""
1327 keyterm = sys.argv[1]
1328 keyterms.append(keyterm)
1329 else:
1330 keyterm = input("Enter the key ID, UID or search string: ")
1331 homedir = input("Enter the GPG configuration directory path (optional): ")
1332 keyterms.append(keyterm)
1333
1334 if len(homedir) == 0:
1335 homedir = None
1336 homeless = False
1337
1338 if homedir is not None:
1339 if homedir.startswith("~"):
1340 if os.path.exists(os.path.expanduser(homedir)) is True:
1341 if os.path.isdir(os.path.expanduser(homedir)) is True:
1342 c.home_dir = os.path.realpath(os.path.expanduser(homedir))
1343 else:
1344 homeless = True
1345 else:
1346 homeless = True
1347 elif os.path.exists(os.path.realpath(homedir)) is True:
1348 if os.path.isdir(os.path.realpath(homedir)) is True:
1349 c.home_dir = os.path.realpath(homedir)
1350 else:
1351 homeless = True
1352 else:
1353 homeless = True
1354
1355 # First check to see if the homedir really is a homedir and if not, treat it as
1356 # a search string.
1357 if homeless is True:
1358 keyterms.append(homedir)
1359 c.home_dir = None
1360 else:
1361 pass
1362
1363 for keyterm in keyterms:
1364 if keyterm.count("@") == 2 and keyterm.startswith("@") is True:
1365 ksearch.append(keyterm[1:])
1366 ksearch.append(keyterm[1:])
1367 ksearch.append(keyterm[1:])
1368 elif keyterm.count("@") == 1 and keyterm.startswith("@") is True:
1369 ksearch.append("{0}@protonmail.com".format(keyterm[1:]))
1370 ksearch.append("{0}@protonmail.ch".format(keyterm[1:]))
1371 ksearch.append("{0}@pm.me".format(keyterm[1:]))
1372 elif keyterm.count("@") == 0:
1373 ksearch.append("{0}@protonmail.com".format(keyterm))
1374 ksearch.append("{0}@protonmail.ch".format(keyterm))
1375 ksearch.append("{0}@pm.me".format(keyterm))
1376 elif keyterm.count("@") == 2 and keyterm.startswith("@") is False:
1377 uidlist = keyterm.split("@")
1378 for uid in uidlist:
1379 ksearch.append("{0}@protonmail.com".format(uid))
1380 ksearch.append("{0}@protonmail.ch".format(uid))
1381 ksearch.append("{0}@pm.me".format(uid))
1382 elif keyterm.count("@") > 2:
1383 uidlist = keyterm.split("@")
1384 for uid in uidlist:
1385 ksearch.append("{0}@protonmail.com".format(uid))
1386 ksearch.append("{0}@protonmail.ch".format(uid))
1387 ksearch.append("{0}@pm.me".format(uid))
1388 else:
1389 ksearch.append(keyterm)
1390
1391 for k in ksearch:
1392 print("Checking for key for: {0}".format(k))
1393 try:
1394 keys = server.search(k)
1395 if isinstance(keys, list) is True:
1396 for key in keys:
1397 allkeys.append(key)
1398 try:
1399 import_result = c.key_import(key.key_blob)
1400 except Exception as e:
1401 import_result = c.key_import(key.key)
1402 else:
1403 paradox.append(keys)
1404 import_result = None
1405 except Exception as e:
1406 import_result = None
1407 results.append(import_result)
1408
1409 for result in results:
1410 if result is not None and hasattr(result, "considered") is False:
1411 print("{0} for {1}".format(result.decode(), k))
1412 elif result is not None and hasattr(result, "considered") is True:
1413 num_keys = len(result.imports)
1414 new_revs = result.new_revocations
1415 new_sigs = result.new_signatures
1416 new_subs = result.new_sub_keys
1417 new_uids = result.new_user_ids
1418 new_scrt = result.secret_imported
1419 nochange = result.unchanged
1420 print("""
1421 The total number of keys considered for import was: {0}
1422
1423 With UIDs wholely or partially matching the following string:
1424
1425 {1}
1426
1427 Number of keys revoked: {2}
1428 Number of new signatures: {3}
1429 Number of new subkeys: {4}
1430 Number of new user IDs: {5}
1431 Number of new secret keys: {6}
1432 Number of unchanged keys: {7}
1433
1434 The key IDs for all considered keys were:
1435 """.format(num_keys, k, new_revs, new_sigs, new_subs, new_uids, new_scrt,
1436 nochange))
1437 for i in range(num_keys):
1438 print(result.imports[i].fpr)
1439 print("")
1440 elif result is None:
1441 pass
1442 \end{verbatim}
1443 \end{enumerate}
1444
1445
1446 \subsection{Exporting keys}
1447 \label{sec:org4596a77}
1448 Exporting keys remains a reasonably simple task, but has been
1449 separated into three different functions for the OpenPGP cryptographic
1450 engine. Two of those functions are for exporting public keys and the
1451 third is for exporting secret keys.
1452
1453
1454 \subsubsection{Exporting public keys}
1455 \label{sec:org873704f}
1456 There are two methods of exporting public keys, both of which are very
1457 similar to the other. The default method, \texttt{key\_export()}, will export
1458 a public key or keys matching a specified pattern as normal. The
1459 alternative, the \texttt{key\_export\_minimal()} method, will do the same thing
1460 except producing a minimised output with extra signatures and third
1461 party signatures or certifications removed.
1462
1463 \begin{verbatim}
1464 import gpg
1465 import os.path
1466 import sys
1467
1468 print("""
1469 This script exports one or more public keys.
1470 """)
1471
1472 c = gpg.Context(armor=True)
1473
1474 if len(sys.argv) >= 4:
1475 keyfile = sys.argv[1]
1476 logrus = sys.argv[2]
1477 homedir = sys.argv[3]
1478 elif len(sys.argv) == 3:
1479 keyfile = sys.argv[1]
1480 logrus = sys.argv[2]
1481 homedir = input("Enter the GPG configuration directory path (optional): ")
1482 elif len(sys.argv) == 2:
1483 keyfile = sys.argv[1]
1484 logrus = input("Enter the UID matching the key(s) to export: ")
1485 homedir = input("Enter the GPG configuration directory path (optional): ")
1486 else:
1487 keyfile = input("Enter the path and filename to save the secret key to: ")
1488 logrus = input("Enter the UID matching the key(s) to export: ")
1489 homedir = input("Enter the GPG configuration directory path (optional): ")
1490
1491 if homedir.startswith("~"):
1492 if os.path.exists(os.path.expanduser(homedir)) is True:
1493 c.home_dir = os.path.expanduser(homedir)
1494 else:
1495 pass
1496 elif os.path.exists(homedir) is True:
1497 c.home_dir = homedir
1498 else:
1499 pass
1500
1501 try:
1502 result = c.key_export(pattern=logrus)
1503 except:
1504 result = c.key_export(pattern=None)
1505
1506 if result is not None:
1507 with open(keyfile, "wb") as f:
1508 f.write(result)
1509 else:
1510 pass
1511 \end{verbatim}
1512
1513 It should be noted that the result will only return \texttt{None} when a
1514 search pattern has been entered, but has not matched any keys. When
1515 the search pattern itself is set to \texttt{None} this triggers the exporting
1516 of the entire public keybox.
1517
1518 \begin{verbatim}
1519 import gpg
1520 import os.path
1521 import sys
1522
1523 print("""
1524 This script exports one or more public keys in minimised form.
1525 """)
1526
1527 c = gpg.Context(armor=True)
1528
1529 if len(sys.argv) >= 4:
1530 keyfile = sys.argv[1]
1531 logrus = sys.argv[2]
1532 homedir = sys.argv[3]
1533 elif len(sys.argv) == 3:
1534 keyfile = sys.argv[1]
1535 logrus = sys.argv[2]
1536 homedir = input("Enter the GPG configuration directory path (optional): ")
1537 elif len(sys.argv) == 2:
1538 keyfile = sys.argv[1]
1539 logrus = input("Enter the UID matching the key(s) to export: ")
1540 homedir = input("Enter the GPG configuration directory path (optional): ")
1541 else:
1542 keyfile = input("Enter the path and filename to save the secret key to: ")
1543 logrus = input("Enter the UID matching the key(s) to export: ")
1544 homedir = input("Enter the GPG configuration directory path (optional): ")
1545
1546 if homedir.startswith("~"):
1547 if os.path.exists(os.path.expanduser(homedir)) is True:
1548 c.home_dir = os.path.expanduser(homedir)
1549 else:
1550 pass
1551 elif os.path.exists(homedir) is True:
1552 c.home_dir = homedir
1553 else:
1554 pass
1555
1556 try:
1557 result = c.key_export_minimal(pattern=logrus)
1558 except:
1559 result = c.key_export_minimal(pattern=None)
1560
1561 if result is not None:
1562 with open(keyfile, "wb") as f:
1563 f.write(result)
1564 else:
1565 pass
1566 \end{verbatim}
1567
1568
1569 \subsubsection{Exporting secret keys}
1570 \label{sec:org6c28d3d}
1571 Exporting secret keys is, functionally, very similar to exporting
1572 public keys; save for the invocation of \texttt{pinentry} via \texttt{gpg-agent} in
1573 order to securely enter the key's passphrase and authorise the export.
1574
1575 The following example exports the secret key to a file which is then
1576 set with the same permissions as the output files created by the
1577 command line secret key export options.
1578
1579 \begin{verbatim}
1580 import gpg
1581 import os
1582 import os.path
1583 import sys
1584
1585 print("""
1586 This script exports one or more secret keys.
1587
1588 The gpg-agent and pinentry are invoked to authorise the export.
1589 """)
1590
1591 c = gpg.Context(armor=True)
1592
1593 if len(sys.argv) >= 4:
1594 keyfile = sys.argv[1]
1595 logrus = sys.argv[2]
1596 homedir = sys.argv[3]
1597 elif len(sys.argv) == 3:
1598 keyfile = sys.argv[1]
1599 logrus = sys.argv[2]
1600 homedir = input("Enter the GPG configuration directory path (optional): ")
1601 elif len(sys.argv) == 2:
1602 keyfile = sys.argv[1]
1603 logrus = input("Enter the UID matching the secret key(s) to export: ")
1604 homedir = input("Enter the GPG configuration directory path (optional): ")
1605 else:
1606 keyfile = input("Enter the path and filename to save the secret key to: ")
1607 logrus = input("Enter the UID matching the secret key(s) to export: ")
1608 homedir = input("Enter the GPG configuration directory path (optional): ")
1609
1610 if len(homedir) == 0:
1611 homedir = None
1612 elif homedir.startswith("~"):
1613 userdir = os.path.expanduser(homedir)
1614 if os.path.exists(userdir) is True:
1615 homedir = os.path.realpath(userdir)
1616 else:
1617 homedir = None
1618 else:
1619 homedir = os.path.realpath(homedir)
1620
1621 if os.path.exists(homedir) is False:
1622 homedir = None
1623 else:
1624 if os.path.isdir(homedir) is False:
1625 homedir = None
1626 else:
1627 pass
1628
1629 if homedir is not None:
1630 c.home_dir = homedir
1631 else:
1632 pass
1633
1634 try:
1635 result = c.key_export_secret(pattern=logrus)
1636 except:
1637 result = c.key_export_secret(pattern=None)
1638
1639 if result is not None:
1640 with open(keyfile, "wb") as f:
1641 f.write(result)
1642 os.chmod(keyfile, 0o600)
1643 else:
1644 pass
1645 \end{verbatim}
1646
1647 Alternatively the approach of the following script can be used. This
1648 longer example saves the exported secret key(s) in files in the GnuPG
1649 home directory, in addition to setting the file permissions as only
1650 readable and writable by the user. It also exports the secret key(s)
1651 twice in order to output both GPG binary (\texttt{.gpg}) and ASCII armoured
1652 (\texttt{.asc}) files.
1653
1654 \begin{verbatim}
1655 import gpg
1656 import os
1657 import os.path
1658 import subprocess
1659 import sys
1660
1661 print("""
1662 This script exports one or more secret keys as both ASCII armored and binary
1663 file formats, saved in files within the user's GPG home directory.
1664
1665 The gpg-agent and pinentry are invoked to authorise the export.
1666 """)
1667
1668 if sys.platform == "win32":
1669 gpgconfcmd = "gpgconf.exe --list-dirs homedir"
1670 else:
1671 gpgconfcmd = "gpgconf --list-dirs homedir"
1672
1673 a = gpg.Context(armor=True)
1674 b = gpg.Context()
1675 c = gpg.Context()
1676
1677 if len(sys.argv) >= 4:
1678 keyfile = sys.argv[1]
1679 logrus = sys.argv[2]
1680 homedir = sys.argv[3]
1681 elif len(sys.argv) == 3:
1682 keyfile = sys.argv[1]
1683 logrus = sys.argv[2]
1684 homedir = input("Enter the GPG configuration directory path (optional): ")
1685 elif len(sys.argv) == 2:
1686 keyfile = sys.argv[1]
1687 logrus = input("Enter the UID matching the secret key(s) to export: ")
1688 homedir = input("Enter the GPG configuration directory path (optional): ")
1689 else:
1690 keyfile = input("Enter the filename to save the secret key to: ")
1691 logrus = input("Enter the UID matching the secret key(s) to export: ")
1692 homedir = input("Enter the GPG configuration directory path (optional): ")
1693
1694 if len(homedir) == 0:
1695 homedir = None
1696 elif homedir.startswith("~"):
1697 userdir = os.path.expanduser(homedir)
1698 if os.path.exists(userdir) is True:
1699 homedir = os.path.realpath(userdir)
1700 else:
1701 homedir = None
1702 else:
1703 homedir = os.path.realpath(homedir)
1704
1705 if os.path.exists(homedir) is False:
1706 homedir = None
1707 else:
1708 if os.path.isdir(homedir) is False:
1709 homedir = None
1710 else:
1711 pass
1712
1713 if homedir is not None:
1714 c.home_dir = homedir
1715 else:
1716 pass
1717
1718 if c.home_dir is not None:
1719 if c.home_dir.endswith("/"):
1720 gpgfile = "{0}{1}.gpg".format(c.home_dir, keyfile)
1721 ascfile = "{0}{1}.asc".format(c.home_dir, keyfile)
1722 else:
1723 gpgfile = "{0}/{1}.gpg".format(c.home_dir, keyfile)
1724 ascfile = "{0}/{1}.asc".format(c.home_dir, keyfile)
1725 else:
1726 if os.path.exists(os.environ["GNUPGHOME"]) is True:
1727 hd = os.environ["GNUPGHOME"]
1728 else:
1729 try:
1730 hd = subprocess.getoutput(gpgconfcmd)
1731 except:
1732 process = subprocess.Popen(gpgconfcmd.split(),
1733 stdout=subprocess.PIPE)
1734 procom = process.communicate()
1735 if sys.version_info[0] == 2:
1736 hd = procom[0].strip()
1737 else:
1738 hd = procom[0].decode().strip()
1739 gpgfile = "{0}/{1}.gpg".format(hd, keyfile)
1740 ascfile = "{0}/{1}.asc".format(hd, keyfile)
1741
1742 try:
1743 a_result = a.key_export_secret(pattern=logrus)
1744 b_result = b.key_export_secret(pattern=logrus)
1745 except:
1746 a_result = a.key_export_secret(pattern=None)
1747 b_result = b.key_export_secret(pattern=None)
1748
1749 if a_result is not None:
1750 with open(ascfile, "wb") as f:
1751 f.write(a_result)
1752 os.chmod(ascfile, 0o600)
1753 else:
1754 pass
1755
1756 if b_result is not None:
1757 with open(gpgfile, "wb") as f:
1758 f.write(b_result)
1759 os.chmod(gpgfile, 0o600)
1760 else:
1761 pass
1762 \end{verbatim}
1763
1764
1765 \subsubsection{Sending public keys to the SKS Keyservers}
1766 \label{sec:org82d4958}
1767 As with the previous section on importing keys, the \texttt{hkp4py} module
1768 adds another option with exporting keys in order to send them to the
1769 public keyservers.
1770
1771 The following example demonstrates how this may be done.
1772
1773 \begin{verbatim}
1774 import gpg
1775 import hkp4py
1776 import os.path
1777 import sys
1778
1779 print("""
1780 This script sends one or more public keys to the SKS keyservers and is
1781 essentially a slight variation on the export-key.py script.
1782 """)
1783
1784 c = gpg.Context(armor=True)
1785 server = hkp4py.KeyServer("hkps://hkps.pool.sks-keyservers.net")
1786
1787 if len(sys.argv) > 2:
1788 logrus = " ".join(sys.argv[1:])
1789 elif len(sys.argv) == 2:
1790 logrus = sys.argv[1]
1791 else:
1792 logrus = input("Enter the UID matching the key(s) to send: ")
1793
1794 if len(logrus) > 0:
1795 try:
1796 export_result = c.key_export(pattern=logrus)
1797 except Exception as e:
1798 print(e)
1799 export_result = None
1800 else:
1801 export_result = c.key_export(pattern=None)
1802
1803 if export_result is not None:
1804 try:
1805 try:
1806 send_result = server.add(export_result)
1807 except:
1808 send_result = server.add(export_result.decode())
1809 if send_result is not None:
1810 print(send_result)
1811 else:
1812 pass
1813 except Exception as e:
1814 print(e)
1815 else:
1816 pass
1817 \end{verbatim}
1818
1819 An expanded version of this script with additional functions for
1820 specifying an alternative homedir location is in the examples
1821 directory as \texttt{send-key-to-keyserver.py}.
1822
1823 The \texttt{hkp4py} module appears to handle both string and byte literal text
1824 data equally well, but the GPGME bindings deal primarily with byte
1825 literal data only and so this script sends in that format first, then
1826 tries the string literal form.
1827
1828
1829 \section{Basic Functions}
1830 \label{sec:orgb40b488}
1831 The most frequently called features of any cryptographic library will
1832 be the most fundamental tasks for encryption software. In this
1833 section we will look at how to programmatically encrypt data, decrypt
1834 it, sign it and verify signatures.
1835
1836
1837 \subsection{Encryption}
1838 \label{sec:org3170365}
1839 Encrypting is very straight forward. In the first example below the
1840 message, \texttt{text}, is encrypted to a single recipient's key. In the
1841 second example the message will be encrypted to multiple recipients.
1842
1843
1844 \subsubsection{Encrypting to one key}
1845 \label{sec:org8098c64}
1846 Once the the Context is set the main issues with encrypting data is
1847 essentially reduced to key selection and the keyword arguments
1848 specified in the \texttt{gpg.Context().encrypt()} method.
1849
1850 Those keyword arguments are: \texttt{recipients}, a list of keys encrypted to
1851 (covered in greater detail in the following section); \texttt{sign}, whether
1852 or not to sign the plaintext data, see subsequent sections on signing
1853 and verifying signatures below (defaults to \texttt{True}); \texttt{sink}, to write
1854 results or partial results to a secure sink instead of returning it
1855 (defaults to \texttt{None}); \texttt{passphrase}, only used when utilising symmetric
1856 encryption (defaults to \texttt{None}); \texttt{always\_trust}, used to override the
1857 trust model settings for recipient keys (defaults to \texttt{False});
1858 \texttt{add\_encrypt\_to}, utilises any preconfigured \texttt{encrypt-to} or
1859 \texttt{default-key} settings in the user's \texttt{gpg.conf} file (defaults to
1860 \texttt{False}); \texttt{prepare}, prepare for encryption (defaults to \texttt{False});
1861 \texttt{expect\_sign}, prepare for signing (defaults to \texttt{False}); \texttt{compress},
1862 compresses the plaintext prior to encryption (defaults to \texttt{True}).
1863
1864 \begin{verbatim}
1865 import gpg
1866
1867 a_key = "0x12345678DEADBEEF"
1868 text = b"""Some text to test with.
1869
1870 Since the text in this case must be bytes, it is most likely that
1871 the input form will be a separate file which is opened with "rb"
1872 as this is the simplest method of obtaining the correct data format.
1873 """
1874
1875 c = gpg.Context(armor=True)
1876 rkey = list(c.keylist(pattern=a_key, secret=False))
1877 ciphertext, result, sign_result = c.encrypt(text, recipients=rkey, sign=False)
1878
1879 with open("secret_plans.txt.asc", "wb") as afile:
1880 afile.write(ciphertext)
1881 \end{verbatim}
1882
1883 Though this is even more likely to be used like this; with the
1884 plaintext input read from a file, the recipient keys used for
1885 encryption regardless of key trust status and the encrypted output
1886 also encrypted to any preconfigured keys set in the \texttt{gpg.conf} file:
1887
1888 \begin{verbatim}
1889 import gpg
1890
1891 a_key = "0x12345678DEADBEEF"
1892
1893 with open("secret_plans.txt", "rb") as afile:
1894 text = afile.read()
1895
1896 c = gpg.Context(armor=True)
1897 rkey = list(c.keylist(pattern=a_key, secret=False))
1898 ciphertext, result, sign_result = c.encrypt(text, recipients=rkey, sign=True,
1899 always_trust=True,
1900 add_encrypt_to=True)
1901
1902 with open("secret_plans.txt.asc", "wb") as afile:
1903 afile.write(ciphertext)
1904 \end{verbatim}
1905
1906 If the \texttt{recipients} parameter is empty then the plaintext is encrypted
1907 symmetrically. If no \texttt{passphrase} is supplied as a parameter or via a
1908 callback registered with the \texttt{Context()} then an out-of-band prompt
1909 for the passphrase via pinentry will be invoked.
1910
1911
1912 \subsubsection{Encrypting to multiple keys}
1913 \label{sec:orgdcf6e47}
1914 Encrypting to multiple keys essentially just expands upon the key
1915 selection process and the recipients from the previous examples.
1916
1917 The following example encrypts a message (\texttt{text}) to everyone with an
1918 email address on the \texttt{gnupg.org} domain,\footnote{You probably don't really want to do this. Searching the
1919 keyservers for "gnupg.org" produces over 400 results, the majority of
1920 which aren't actually at the gnupg.org domain, but just included a
1921 comment regarding the project in their key somewhere.} but does \emph{not} encrypt
1922 to a default key or other key which is configured to normally encrypt
1923 to.
1924
1925 \begin{verbatim}
1926 import gpg
1927
1928 text = b"""Oh look, another test message.
1929
1930 The same rules apply as with the previous example and more likely
1931 than not, the message will actually be drawn from reading the
1932 contents of a file or, maybe, from entering data at an input()
1933 prompt.
1934
1935 Since the text in this case must be bytes, it is most likely that
1936 the input form will be a separate file which is opened with "rb"
1937 as this is the simplest method of obtaining the correct data
1938 format.
1939 """
1940
1941 c = gpg.Context(armor=True)
1942 rpattern = list(c.keylist(pattern="@gnupg.org", secret=False))
1943 logrus = []
1944
1945 for i in range(len(rpattern)):
1946 if rpattern[i].can_encrypt == 1:
1947 logrus.append(rpattern[i])
1948
1949 ciphertext, result, sign_result = c.encrypt(text, recipients=logrus,
1950 sign=False, always_trust=True)
1951
1952 with open("secret_plans.txt.asc", "wb") as afile:
1953 afile.write(ciphertext)
1954 \end{verbatim}
1955
1956 All it would take to change the above example to sign the message
1957 and also encrypt the message to any configured default keys would
1958 be to change the \texttt{c.encrypt} line to this:
1959
1960 \begin{verbatim}
1961 ciphertext, result, sign_result = c.encrypt(text, recipients=logrus,
1962 always_trust=True,
1963 add_encrypt_to=True)
1964 \end{verbatim}
1965
1966 The only keyword arguments requiring modification are those for which
1967 the default values are changing. The default value of \texttt{sign} is
1968 \texttt{True}, the default of \texttt{always\_trust} is \texttt{False}, the default of
1969 \texttt{add\_encrypt\_to} is \texttt{False}.
1970
1971 If \texttt{always\_trust} is not set to \texttt{True} and any of the recipient keys
1972 are not trusted (e.g. not signed or locally signed) then the
1973 encryption will raise an error. It is possible to mitigate this
1974 somewhat with something more like this:
1975
1976 \begin{verbatim}
1977 import gpg
1978
1979 with open("secret_plans.txt.asc", "rb") as afile:
1980 text = afile.read()
1981
1982 c = gpg.Context(armor=True)
1983 rpattern = list(c.keylist(pattern="@gnupg.org", secret=False))
1984 logrus = []
1985
1986 for i in range(len(rpattern)):
1987 if rpattern[i].can_encrypt == 1:
1988 logrus.append(rpattern[i])
1989
1990 try:
1991 ciphertext, result, sign_result = c.encrypt(text, recipients=logrus,
1992 add_encrypt_to=True)
1993 except gpg.errors.InvalidRecipients as e:
1994 for i in range(len(e.recipients)):
1995 for n in range(len(logrus)):
1996 if logrus[n].fpr == e.recipients[i].fpr:
1997 logrus.remove(logrus[n])
1998 else:
1999 pass
2000 try:
2001 ciphertext, result, sign_result = c.encrypt(text,
2002 recipients=logrus,
2003 add_encrypt_to=True)
2004 with open("secret_plans.txt.asc", "wb") as afile:
2005 afile.write(ciphertext)
2006 except:
2007 pass
2008 \end{verbatim}
2009
2010 This will attempt to encrypt to all the keys searched for, then remove
2011 invalid recipients if it fails and try again.
2012
2013
2014 \subsection{Decryption}
2015 \label{sec:org1282b3d}
2016 Decrypting something encrypted to a key in one's secret keyring is
2017 fairly straight forward.
2018
2019 In this example code, however, preconfiguring either \texttt{gpg.Context()}
2020 or \texttt{gpg.core.Context()} as \texttt{c} is unnecessary because there is no need
2021 to modify the Context prior to conducting the decryption and since the
2022 Context is only used once, setting it to \texttt{c} simply adds lines for no
2023 gain.
2024
2025 \begin{verbatim}
2026 import gpg
2027
2028 ciphertext = input("Enter path and filename of encrypted file: ")
2029 newfile = input("Enter path and filename of file to save decrypted data to: ")
2030
2031 with open(ciphertext, "rb") as cfile:
2032 try:
2033 plaintext, result, verify_result = gpg.Context().decrypt(cfile)
2034 except gpg.errors.GPGMEError as e:
2035 plaintext = None
2036 print(e)
2037
2038 if plaintext is not None:
2039 with open(newfile, "wb") as nfile:
2040 nfile.write(plaintext)
2041 else:
2042 pass
2043 \end{verbatim}
2044
2045 The data available in \texttt{plaintext} in this example is the decrypted
2046 content as a byte object, the recipient key IDs and algorithms in
2047 \texttt{result} and the results of verifying any signatures of the data in
2048 \texttt{verify\_result}.
2049
2050 If \texttt{gpg.Context().decrypt(cfile, verify=False)} is called instead,
2051 then \texttt{verify\_result} will be returned as \texttt{None} and the rest remains
2052 as described here.
2053
2054
2055 \subsection{Signing text and files}
2056 \label{sec:org59f1262}
2057 The following sections demonstrate how to specify keys to sign with.
2058
2059
2060 \subsubsection{Signing key selection}
2061 \label{sec:org909cb3c}
2062 By default GPGME and the Python bindings will use the default key
2063 configured for the user invoking the GPGME API. If there is no
2064 default key specified and there is more than one secret key available
2065 it may be necessary to specify the key or keys with which to sign
2066 messages and files.
2067
2068 \begin{verbatim}
2069 import gpg
2070
2071 logrus = input("Enter the email address or string to match signing keys to: ")
2072 hancock = gpg.Context().keylist(pattern=logrus, secret=True)
2073 sig_src = list(hancock)
2074 \end{verbatim}
2075
2076 The signing examples in the following sections include the explicitly
2077 designated \texttt{signers} parameter in two of the five examples; once where
2078 the resulting signature would be ASCII armoured and once where it
2079 would not be armoured.
2080
2081 While it would be possible to enter a key ID or fingerprint here to
2082 match a specific key, it is not possible to enter two fingerprints and
2083 match two keys since the patten expects a string, bytes or None and
2084 not a list. A string with two fingerprints won't match any single
2085 key.
2086
2087
2088 \subsubsection{Normal or default signing messages or files}
2089 \label{sec:org6ee259d}
2090 The normal or default signing process is essentially the same as is
2091 most often invoked when also encrypting a message or file. So when
2092 the encryption component is not utilised, the result is to produce an
2093 encoded and signed output which may or may not be ASCII armoured and
2094 which may or may not also be compressed.
2095
2096 By default compression will be used unless GnuPG detects that the
2097 plaintext is already compressed. ASCII armouring will be determined
2098 according to the value of \texttt{gpg.Context().armor}.
2099
2100 The compression algorithm is selected in much the same way as the
2101 symmetric encryption algorithm or the hash digest algorithm is when
2102 multiple keys are involved; from the preferences saved into the key
2103 itself or by comparison with the preferences with all other keys
2104 involved.
2105
2106 \begin{verbatim}
2107 import gpg
2108
2109 text0 = """Declaration of ... something.
2110
2111 """
2112 text = text0.encode()
2113
2114 c = gpg.Context(armor=True, signers=sig_src)
2115 signed_data, result = c.sign(text, mode=gpg.constants.sig.mode.NORMAL)
2116
2117 with open("/path/to/statement.txt.asc", "w") as afile:
2118 afile.write(signed_data.decode())
2119 \end{verbatim}
2120
2121 Though everything in this example is accurate, it is more likely that
2122 reading the input data from another file and writing the result to a
2123 new file will be performed more like the way it is done in the next
2124 example. Even if the output format is ASCII armoured.
2125
2126 \begin{verbatim}
2127 import gpg
2128
2129 with open("/path/to/statement.txt", "rb") as tfile:
2130 text = tfile.read()
2131
2132 c = gpg.Context()
2133 signed_data, result = c.sign(text, mode=gpg.constants.sig.mode.NORMAL)
2134
2135 with open("/path/to/statement.txt.sig", "wb") as afile:
2136 afile.write(signed_data)
2137 \end{verbatim}
2138
2139
2140 \subsubsection{Detached signing messages and files}
2141 \label{sec:org51049d4}
2142 Detached signatures will often be needed in programmatic uses of
2143 GPGME, either for signing files (e.g. tarballs of code releases) or as
2144 a component of message signing (e.g. PGP/MIME encoded email).
2145
2146 \begin{verbatim}
2147 import gpg
2148
2149 text0 = """Declaration of ... something.
2150
2151 """
2152 text = text0.encode()
2153
2154 c = gpg.Context(armor=True)
2155 signed_data, result = c.sign(text, mode=gpg.constants.sig.mode.DETACH)
2156
2157 with open("/path/to/statement.txt.asc", "w") as afile:
2158 afile.write(signed_data.decode())
2159 \end{verbatim}
2160
2161 As with normal signatures, detached signatures are best handled as
2162 byte literals, even when the output is ASCII armoured.
2163
2164 \begin{verbatim}
2165 import gpg
2166
2167 with open("/path/to/statement.txt", "rb") as tfile:
2168 text = tfile.read()
2169
2170 c = gpg.Context(signers=sig_src)
2171 signed_data, result = c.sign(text, mode=gpg.constants.sig.mode.DETACH)
2172
2173 with open("/path/to/statement.txt.sig", "wb") as afile:
2174 afile.write(signed_data)
2175 \end{verbatim}
2176
2177
2178 \subsubsection{Clearsigning messages or text}
2179 \label{sec:orgf528a20}
2180 Though PGP/in-line messages are no longer encouraged in favour of
2181 PGP/MIME, there is still sometimes value in utilising in-line
2182 signatures. This is where clear-signed messages or text is of value.
2183
2184 \begin{verbatim}
2185 import gpg
2186
2187 text0 = """Declaration of ... something.
2188
2189 """
2190 text = text0.encode()
2191
2192 c = gpg.Context()
2193 signed_data, result = c.sign(text, mode=gpg.constants.sig.mode.CLEAR)
2194
2195 with open("/path/to/statement.txt.asc", "w") as afile:
2196 afile.write(signed_data.decode())
2197 \end{verbatim}
2198
2199 In spite of the appearance of a clear-signed message, the data handled
2200 by GPGME in signing it must still be byte literals.
2201
2202 \begin{verbatim}
2203 import gpg
2204
2205 with open("/path/to/statement.txt", "rb") as tfile:
2206 text = tfile.read()
2207
2208 c = gpg.Context()
2209 signed_data, result = c.sign(text, mode=gpg.constants.sig.mode.CLEAR)
2210
2211 with open("/path/to/statement.txt.asc", "wb") as afile:
2212 afile.write(signed_data)
2213 \end{verbatim}
2214
2215
2216 \subsection{Signature verification}
2217 \label{sec:org6cd81af}
2218 Essentially there are two principal methods of verification of a
2219 signature. The first of these is for use with the normal or default
2220 signing method and for clear-signed messages. The second is for use
2221 with files and data with detached signatures.
2222
2223 The following example is intended for use with the default signing
2224 method where the file was not ASCII armoured:
2225
2226 \begin{verbatim}
2227 import gpg
2228 import time
2229
2230 filename = "statement.txt"
2231 gpg_file = "statement.txt.gpg"
2232
2233 c = gpg.Context()
2234
2235 try:
2236 data, result = c.verify(open(gpg_file))
2237 verified = True
2238 except gpg.errors.BadSignatures as e:
2239 verified = False
2240 print(e)
2241
2242 if verified is True:
2243 for i in range(len(result.signatures)):
2244 sign = result.signatures[i]
2245 print("""Good signature from:
2246 {0}
2247 with key {1}
2248 made at {2}
2249 """.format(c.get_key(sign.fpr).uids[0].uid, sign.fpr,
2250 time.ctime(sign.timestamp)))
2251 else:
2252 pass
2253 \end{verbatim}
2254
2255 Whereas this next example, which is almost identical would work with
2256 normal ASCII armoured files and with clear-signed files:
2257
2258 \begin{verbatim}
2259 import gpg
2260 import time
2261
2262 filename = "statement.txt"
2263 asc_file = "statement.txt.asc"
2264
2265 c = gpg.Context()
2266
2267 try:
2268 data, result = c.verify(open(asc_file))
2269 verified = True
2270 except gpg.errors.BadSignatures as e:
2271 verified = False
2272 print(e)
2273
2274 if verified is True:
2275 for i in range(len(result.signatures)):
2276 sign = result.signatures[i]
2277 print("""Good signature from:
2278 {0}
2279 with key {1}
2280 made at {2}
2281 """.format(c.get_key(sign.fpr).uids[0].uid, sign.fpr,
2282 time.ctime(sign.timestamp)))
2283 else:
2284 pass
2285 \end{verbatim}
2286
2287 In both of the previous examples it is also possible to compare the
2288 original data that was signed against the signed data in \texttt{data} to see
2289 if it matches with something like this:
2290
2291 \begin{verbatim}
2292 with open(filename, "rb") as afile:
2293 text = afile.read()
2294
2295 if text == data:
2296 print("Good signature.")
2297 else:
2298 pass
2299 \end{verbatim}
2300
2301 The following two examples, however, deal with detached signatures.
2302 With his method of verification the data that was signed does not get
2303 returned since it is already being explicitly referenced in the first
2304 argument of \texttt{c.verify}. So \texttt{data} is \texttt{None} and only the information
2305 in \texttt{result} is available.
2306
2307 \begin{verbatim}
2308 import gpg
2309 import time
2310
2311 filename = "statement.txt"
2312 sig_file = "statement.txt.sig"
2313
2314 c = gpg.Context()
2315
2316 try:
2317 data, result = c.verify(open(filename), open(sig_file))
2318 verified = True
2319 except gpg.errors.BadSignatures as e:
2320 verified = False
2321 print(e)
2322
2323 if verified is True:
2324 for i in range(len(result.signatures)):
2325 sign = result.signatures[i]
2326 print("""Good signature from:
2327 {0}
2328 with key {1}
2329 made at {2}
2330 """.format(c.get_key(sign.fpr).uids[0].uid, sign.fpr,
2331 time.ctime(sign.timestamp)))
2332 else:
2333 pass
2334 \end{verbatim}
2335
2336 \begin{verbatim}
2337 import gpg
2338 import time
2339
2340 filename = "statement.txt"
2341 asc_file = "statement.txt.asc"
2342
2343 c = gpg.Context()
2344
2345 try:
2346 data, result = c.verify(open(filename), open(asc_file))
2347 verified = True
2348 except gpg.errors.BadSignatures as e:
2349 verified = False
2350 print(e)
2351
2352 if verified is True:
2353 for i in range(len(result.signatures)):
2354 sign = result.signatures[i]
2355 print("""Good signature from:
2356 {0}
2357 with key {1}
2358 made at {2}
2359 """.format(c.get_key(sign.fpr).uids[0].uid, sign.fpr,
2360 time.ctime(sign.timestamp)))
2361 else:
2362 pass
2363 \end{verbatim}
2364
2365
2366 \section{Creating keys and subkeys}
2367 \label{sec:org754c6df}
2368 The one thing, aside from GnuPG itself, that GPGME depends on, of
2369 course, is the keys themselves. So it is necessary to be able to
2370 generate them and modify them by adding subkeys, revoking or disabling
2371 them, sometimes deleting them and doing the same for user IDs.
2372
2373 In the following examples a key will be created for the world's
2374 greatest secret agent, Danger Mouse. Since Danger Mouse is a secret
2375 agent he needs to be able to protect information to \texttt{SECRET} level
2376 clearance, so his keys will be 3072-bit keys.
2377
2378 The pre-configured \texttt{gpg.conf} file which sets cipher, digest and other
2379 preferences contains the following configuration parameters:
2380
2381 \begin{verbatim}
2382 expert
2383 allow-freeform-uid
2384 allow-secret-key-import
2385 trust-model tofu+pgp
2386 tofu-default-policy unknown
2387 enable-large-rsa
2388 enable-dsa2
2389 cert-digest-algo SHA512
2390 default-preference-list TWOFISH CAMELLIA256 AES256 CAMELLIA192 AES192 CAMELLIA128 AES BLOWFISH IDEA CAST5 3DES SHA512 SHA384 SHA256 SHA224 RIPEMD160 SHA1 ZLIB BZIP2 ZIP Uncompressed
2391 personal-cipher-preferences TWOFISH CAMELLIA256 AES256 CAMELLIA192 AES192 CAMELLIA128 AES BLOWFISH IDEA CAST5 3DES
2392 personal-digest-preferences SHA512 SHA384 SHA256 SHA224 RIPEMD160 SHA1
2393 personal-compress-preferences ZLIB BZIP2 ZIP Uncompressed
2394 \end{verbatim}
2395
2396
2397 \subsection{Primary key}
2398 \label{sec:org0185c23}
2399 Generating a primary key uses the \texttt{create\_key} method in a Context.
2400 It contains multiple arguments and keyword arguments, including:
2401 \texttt{userid}, \texttt{algorithm}, \texttt{expires\_in}, \texttt{expires}, \texttt{sign}, \texttt{encrypt},
2402 \texttt{certify}, \texttt{authenticate}, \texttt{passphrase} and \texttt{force}. The defaults for
2403 all of those except \texttt{userid}, \texttt{algorithm}, \texttt{expires\_in}, \texttt{expires} and
2404 \texttt{passphrase} is \texttt{False}. The defaults for \texttt{algorithm} and
2405 \texttt{passphrase} is \texttt{None}. The default for \texttt{expires\_in} is \texttt{0}. The
2406 default for \texttt{expires} is \texttt{True}. There is no default for \texttt{userid}.
2407
2408 If \texttt{passphrase} is left as \texttt{None} then the key will not be generated
2409 with a passphrase, if \texttt{passphrase} is set to a string then that will
2410 be the passphrase and if \texttt{passphrase} is set to \texttt{True} then gpg-agent
2411 will launch pinentry to prompt for a passphrase. For the sake of
2412 convenience, these examples will keep \texttt{passphrase} set to \texttt{None}.
2413
2414 \begin{verbatim}
2415 import gpg
2416
2417 c = gpg.Context()
2418
2419 c.home_dir = "~/.gnupg-dm"
2420 userid = "Danger Mouse <dm@secret.example.net>"
2421
2422 dmkey = c.create_key(userid, algorithm="rsa3072", expires_in=31536000,
2423 sign=True, certify=True)
2424 \end{verbatim}
2425
2426 One thing to note here is the use of setting the \texttt{c.home\_dir}
2427 parameter. This enables generating the key or keys in a different
2428 location. In this case to keep the new key data created for this
2429 example in a separate location rather than adding it to existing and
2430 active key store data. As with the default directory, \texttt{\textasciitilde{}/.gnupg}, any
2431 temporary or separate directory needs the permissions set to only
2432 permit access by the directory owner. On posix systems this means
2433 setting the directory permissions to 700.
2434
2435 The \texttt{temp-homedir-config.py} script in the HOWTO examples directory
2436 will create an alternative homedir with these configuration options
2437 already set and the correct directory and file permissions.
2438
2439 The successful generation of the key can be confirmed via the returned
2440 \texttt{GenkeyResult} object, which includes the following data:
2441
2442 \begin{verbatim}
2443 print("""
2444 Fingerprint: {0}
2445 Primary Key: {1}
2446 Public Key: {2}
2447 Secret Key: {3}
2448 Sub Key: {4}
2449 User IDs: {5}
2450 """.format(dmkey.fpr, dmkey.primary, dmkey.pubkey, dmkey.seckey, dmkey.sub,
2451 dmkey.uid))
2452 \end{verbatim}
2453
2454 Alternatively the information can be confirmed using the command line
2455 program:
2456
2457 \begin{verbatim}
2458 bash-4.4$ gpg --homedir ~/.gnupg-dm -K
2459 ~/.gnupg-dm/pubring.kbx
2460 ----------------------
2461 sec rsa3072 2018-03-15 [SC] [expires: 2019-03-15]
2462 177B7C25DB99745EE2EE13ED026D2F19E99E63AA
2463 uid [ultimate] Danger Mouse <dm@secret.example.net>
2464
2465 bash-4.4$
2466 \end{verbatim}
2467
2468 As with generating keys manually, to preconfigure expanded preferences
2469 for the cipher, digest and compression algorithms, the \texttt{gpg.conf} file
2470 must contain those details in the home directory in which the new key
2471 is being generated. I used a cut down version of my own \texttt{gpg.conf}
2472 file in order to be able to generate this:
2473
2474 \begin{verbatim}
2475 bash-4.4$ gpg --homedir ~/.gnupg-dm --edit-key 177B7C25DB99745EE2EE13ED026D2F19E99E63AA showpref quit
2476 Secret key is available.
2477
2478 sec rsa3072/026D2F19E99E63AA
2479 created: 2018-03-15 expires: 2019-03-15 usage: SC
2480 trust: ultimate validity: ultimate
2481 [ultimate] (1). Danger Mouse <dm@secret.example.net>
2482
2483 [ultimate] (1). Danger Mouse <dm@secret.example.net>
2484 Cipher: TWOFISH, CAMELLIA256, AES256, CAMELLIA192, AES192, CAMELLIA128, AES, BLOWFISH, IDEA, CAST5, 3DES
2485 Digest: SHA512, SHA384, SHA256, SHA224, RIPEMD160, SHA1
2486 Compression: ZLIB, BZIP2, ZIP, Uncompressed
2487 Features: MDC, Keyserver no-modify
2488
2489 bash-4.4$
2490 \end{verbatim}
2491
2492
2493 \subsection{Subkeys}
2494 \label{sec:org5e2acbc}
2495 Adding subkeys to a primary key is fairly similar to creating the
2496 primary key with the \texttt{create\_subkey} method. Most of the arguments
2497 are the same, but not quite all. Instead of the \texttt{userid} argument
2498 there is now a \texttt{key} argument for selecting which primary key to add
2499 the subkey to.
2500
2501 In the following example an encryption subkey will be added to the
2502 primary key. Since Danger Mouse is a security conscious secret agent,
2503 this subkey will only be valid for about six months, half the length
2504 of the primary key.
2505
2506 \begin{verbatim}
2507 import gpg
2508
2509 c = gpg.Context()
2510 c.home_dir = "~/.gnupg-dm"
2511
2512 key = c.get_key(dmkey.fpr, secret=True)
2513 dmsub = c.create_subkey(key, algorithm="rsa3072", expires_in=15768000,
2514 encrypt=True)
2515 \end{verbatim}
2516
2517 As with the primary key, the results here can be checked with:
2518
2519 \begin{verbatim}
2520 print("""
2521 Fingerprint: {0}
2522 Primary Key: {1}
2523 Public Key: {2}
2524 Secret Key: {3}
2525 Sub Key: {4}
2526 User IDs: {5}
2527 """.format(dmsub.fpr, dmsub.primary, dmsub.pubkey, dmsub.seckey, dmsub.sub,
2528 dmsub.uid))
2529 \end{verbatim}
2530
2531 As well as on the command line with:
2532
2533 \begin{verbatim}
2534 bash-4.4$ gpg --homedir ~/.gnupg-dm -K
2535 ~/.gnupg-dm/pubring.kbx
2536 ----------------------
2537 sec rsa3072 2018-03-15 [SC] [expires: 2019-03-15]
2538 177B7C25DB99745EE2EE13ED026D2F19E99E63AA
2539 uid [ultimate] Danger Mouse <dm@secret.example.net>
2540 ssb rsa3072 2018-03-15 [E] [expires: 2018-09-13]
2541
2542 bash-4.4$
2543 \end{verbatim}
2544
2545
2546 \subsection{User IDs}
2547 \label{sec:org4869c58}
2548 \subsubsection{Adding User IDs}
2549 \label{sec:orgebb13ca}
2550 By comparison to creating primary keys and subkeys, adding a new user
2551 ID to an existing key is much simpler. The method used to do this is
2552 \texttt{key\_add\_uid} and the only arguments it takes are for the \texttt{key} and
2553 the new \texttt{uid}.
2554
2555 \begin{verbatim}
2556 import gpg
2557
2558 c = gpg.Context()
2559 c.home_dir = "~/.gnupg-dm"
2560
2561 dmfpr = "177B7C25DB99745EE2EE13ED026D2F19E99E63AA"
2562 key = c.get_key(dmfpr, secret=True)
2563 uid = "Danger Mouse <danger.mouse@secret.example.net>"
2564
2565 c.key_add_uid(key, uid)
2566 \end{verbatim}
2567
2568 Unsurprisingly the result of this is:
2569
2570 \begin{verbatim}
2571 bash-4.4$ gpg --homedir ~/.gnupg-dm -K
2572 ~/.gnupg-dm/pubring.kbx
2573 ----------------------
2574 sec rsa3072 2018-03-15 [SC] [expires: 2019-03-15]
2575 177B7C25DB99745EE2EE13ED026D2F19E99E63AA
2576 uid [ultimate] Danger Mouse <danger.mouse@secret.example.net>
2577 uid [ultimate] Danger Mouse <dm@secret.example.net>
2578 ssb rsa3072 2018-03-15 [E] [expires: 2018-09-13]
2579
2580 bash-4.4$
2581 \end{verbatim}
2582
2583
2584 \subsubsection{Revoking User IDs}
2585 \label{sec:org1683695}
2586 Revoking a user ID is a fairly similar process, except that it uses
2587 the \texttt{key\_revoke\_uid} method.
2588
2589 \begin{verbatim}
2590 import gpg
2591
2592 c = gpg.Context()
2593 c.home_dir = "~/.gnupg-dm"
2594
2595 dmfpr = "177B7C25DB99745EE2EE13ED026D2F19E99E63AA"
2596 key = c.get_key(dmfpr, secret=True)
2597 uid = "Danger Mouse <danger.mouse@secret.example.net>"
2598
2599 c.key_revoke_uid(key, uid)
2600 \end{verbatim}
2601
2602
2603 \subsection{Key certification}
2604 \label{sec:orgf431bf8}
2605 Since key certification is more frequently referred to as key signing,
2606 the method used to perform this function is \texttt{key\_sign}.
2607
2608 The \texttt{key\_sign} method takes four arguments: \texttt{key}, \texttt{uids},
2609 \texttt{expires\_in} and \texttt{local}. The default value of \texttt{uids} is \texttt{None} and
2610 which results in all user IDs being selected. The default value of
2611 both \texttt{expires\_in} and \texttt{local} is \texttt{False}; which results in the
2612 signature never expiring and being able to be exported.
2613
2614 The \texttt{key} is the key being signed rather than the key doing the
2615 signing. To change the key doing the signing refer to the signing key
2616 selection above for signing messages and files.
2617
2618 If the \texttt{uids} value is not \texttt{None} then it must either be a string to
2619 match a single user ID or a list of strings to match multiple user
2620 IDs. In this case the matching of those strings must be precise and
2621 it is case sensitive.
2622
2623 To sign Danger Mouse's key for just the initial user ID with a
2624 signature which will last a little over a month, do this:
2625
2626 \begin{verbatim}
2627 import gpg
2628
2629 c = gpg.Context()
2630 uid = "Danger Mouse <dm@secret.example.net>"
2631
2632 dmfpr = "177B7C25DB99745EE2EE13ED026D2F19E99E63AA"
2633 key = c.get_key(dmfpr, secret=True)
2634 c.key_sign(key, uids=uid, expires_in=2764800)
2635 \end{verbatim}
2636
2637
2638 \subsubsection{Verifying key certifications}
2639 \label{sec:org87abdd3}
2640 \begin{verbatim}
2641 import gpg
2642 import time
2643
2644 c = gpg.Context()
2645 dmfpr = "177B7C25DB99745EE2EE13ED026D2F19E99E63AA"
2646 keys = list(c.keylist(pattern=dmuid, mode=gpg.constants.keylist.mode.SIGS))
2647 key = keys[0]
2648
2649 for user in key.uids:
2650 for sig in user.signatures:
2651 print("0x{0}".format(sig.keyid), "", time.ctime(sig.timestamp), "",
2652 sig.uid)
2653 \end{verbatim}
2654
2655 Which for Danger Mouse displays the following:
2656
2657 \begin{verbatim}
2658 0x92E3F6115435C65A Thu Mar 15 13:17:44 2018 Danger Mouse <dm@secret.example.net>
2659 0x321E4E2373590E5D Mon Nov 26 12:46:05 2018 Ben McGinnes <ben@adversary.org>
2660 \end{verbatim}
2661
2662 The two key signatures listed are for the self-certification of Danger
2663 Mouse's key made when the key was created in March, 2018; and the
2664 second is a signature made by the author and set to expire at the end
2665 of the year. Note that the second signature was made with the
2666 following code (including the preceding code to display the output of
2667 the certifications or key signatures):
2668
2669 \begin{verbatim}
2670 import gpg
2671 import math
2672 import pendulum
2673 import time
2674
2675 hd = "/home/dm/.gnupg"
2676 c = gpg.Context()
2677 d = gpg.Context(home_dir=hd)
2678 dmfpr = "177B7C25DB99745EE2EE13ED026D2F19E99E63AA"
2679 dmuid = "Danger Mouse <dm@secret.example.net>"
2680 dkeys = list(c.keylist(pattern=dmuid))
2681 dmkey = dkeys[0]
2682
2683 c.key_import(d.key_export(pattern=None))
2684
2685 tp = pendulum.period(pendulum.now(tz="local"), pendulum.datetime(2019, 1, 1))
2686 ts = tp.total_seconds()
2687 total_secs = math.ceil(ts)
2688 c.key_sign(dmkey, uids=dmuid, expires_in=total_secs)
2689
2690 d.key_import(c.key_export(pattern=dmuid))
2691 keys = list(c.keylist(pattern=dmuid, mode=gpg.constants.keylist.mode.SIGS))
2692 key = keys[0]
2693
2694 for user in key.uids:
2695 for sig in user.signatures:
2696 print("0x{0}".format(sig.keyid), "", time.ctime(sig.timestamp), "",
2697 sig.uid)
2698 \end{verbatim}
2699
2700 Note that this final code block includes the use of a module which is
2701 \emph{not} part of Python's standard library, the \href{https://pendulum.eustace.io/}{pendulum module}. Unlike
2702 the standard datetime module, pendulum makes working with dates and
2703 times significantly easier in Python; just as the requests module
2704 makes working with HTTP and HTTPS easier than the builtin modules do.
2705
2706 Though neither requests nor pendulum are required modules for using
2707 the GPGME Python bindings, they are both highly recommended more
2708 generally.
2709
2710
2711 \section{Advanced or Experimental Use Cases}
2712 \label{sec:org944cc00}
2713 \subsection{C plus Python plus SWIG plus Cython}
2714 \label{sec:org3b53926}
2715 In spite of the apparent incongruence of using Python bindings to a C
2716 interface only to generate more C from the Python; it is in fact quite
2717 possible to use the GPGME bindings with \href{http://docs.cython.org/en/latest/index.html}{Cython}. Though in many cases
2718 the benefits may not be obvious since the most computationally
2719 intensive work never leaves the level of the C code with which GPGME
2720 itself is interacting with.
2721
2722 Nevertheless, there are some situations where the benefits are
2723 demonstrable. One of the better and easier examples being the one of
2724 the early examples in this HOWTO, the \hyperref[sec:org63a3d62]{key counting} code. Running that
2725 example as an executable Python script, \texttt{keycount.py} (available in
2726 the \texttt{examples/howto/} directory), will take a noticeable amount of time
2727 to run on most systems where the public keybox or keyring contains a
2728 few thousand public keys.
2729
2730 Earlier in the evening, prior to starting this section, I ran that
2731 script on my laptop; as I tend to do periodically and timed it using
2732 \texttt{time} utility, with the following results:
2733
2734 \begin{verbatim}
2735 bash-4.4$ time keycount.py
2736
2737 Number of secret keys: 23
2738 Number of public keys: 12112
2739
2740
2741 real 11m52.945s
2742 user 0m0.913s
2743 sys 0m0.752s
2744
2745 bash-4.4$
2746 \end{verbatim}
2747
2748 Sometime after that I imported another key and followed it with a
2749 little test of Cython. This test was kept fairly basic, essentially
2750 lifting the material from the \href{http://docs.cython.org/en/latest/src/tutorial/cython\_tutorial.html}{Cython Basic Tutorial} to demonstrate
2751 compiling Python code to C. The first step was to take the example
2752 key counting code quoted previously, essentially from the importing of
2753 the \texttt{gpg} module to the end of the script:
2754
2755 \begin{verbatim}
2756 import gpg
2757
2758 c = gpg.Context()
2759 seckeys = c.keylist(pattern=None, secret=True)
2760 pubkeys = c.keylist(pattern=None, secret=False)
2761
2762 seclist = list(seckeys)
2763 secnum = len(seclist)
2764
2765 publist = list(pubkeys)
2766 pubnum = len(publist)
2767
2768 print("""
2769 Number of secret keys: {0}
2770 Number of public keys: {1}
2771
2772 """.format(secnum, pubnum))
2773 \end{verbatim}
2774
2775 Save that into a file called \texttt{keycount.pyx} and then create a
2776 \texttt{setup.py} file which contains this:
2777
2778 \begin{verbatim}
2779 from distutils.core import setup
2780 from Cython.Build import cythonize
2781
2782 setup(
2783 ext_modules = cythonize("keycount.pyx")
2784 )
2785 \end{verbatim}
2786
2787 Compile it:
2788
2789 \begin{verbatim}
2790 bash-4.4$ python setup.py build_ext --inplace
2791 bash-4.4$
2792 \end{verbatim}
2793
2794 Then run it in a similar manner to \texttt{keycount.py}:
2795
2796 \begin{verbatim}
2797 bash-4.4$ time python3.7 -c "import keycount"
2798
2799 Number of secret keys: 23
2800 Number of public keys: 12113
2801
2802
2803 real 6m47.905s
2804 user 0m0.785s
2805 sys 0m0.331s
2806
2807 bash-4.4$
2808 \end{verbatim}
2809
2810 Cython turned \texttt{keycount.pyx} into an 81KB \texttt{keycount.o} file in the
2811 \texttt{build/} directory, a 24KB \texttt{keycount.cpython-37m-darwin.so} file to be
2812 imported into Python 3.7 and a 113KB \texttt{keycount.c} generated C source
2813 code file of nearly three thousand lines. Quite a bit bigger than the
2814 314 bytes of the \texttt{keycount.pyx} file or the full 1,452 bytes of the
2815 full executable \texttt{keycount.py} example script.
2816
2817 On the other hand it ran in nearly half the time; taking 6 minutes and
2818 47.905 seconds to run. As opposed to the 11 minutes and 52.945 seconds
2819 which the CPython script alone took.
2820
2821 The \texttt{keycount.pyx} and \texttt{setup.py} files used to generate this example
2822 have been added to the \texttt{examples/howto/advanced/cython/} directory
2823 The example versions include some additional options to annotate the
2824 existing code and to detect Cython's use. The latter comes from the
2825 \href{http://docs.cython.org/en/latest/src/tutorial/pure.html\#magic-attributes-within-the-pxd}{Magic Attributes} section of the Cython documentation.
2826
2827
2828 \section{Miscellaneous extras and work-arounds}
2829 \label{sec:orgd72f7de}
2830 Most of the things in the following sections are here simply because
2831 there was no better place to put them, even though some are only
2832 peripherally related to the GPGME Python bindings. Some are also
2833 workarounds for functions not integrated with GPGME as yet. This is
2834 especially true of the first of these, dealing with \hyperref[sec:org83f4d00]{group lines}.
2835
2836
2837 \subsection{Group lines}
2838 \label{sec:org83f4d00}
2839 There is not yet an easy way to access groups configured in the
2840 gpg.conf file from within GPGME. As a consequence these central
2841 groupings of keys cannot be shared amongst multiple programs, such as
2842 MUAs readily.
2843
2844 The following code, however, provides a work-around for obtaining this
2845 information in Python.
2846
2847 \begin{verbatim}
2848 import subprocess
2849 import sys
2850
2851 if sys.platform == "win32":
2852 gpgconfcmd = "gpgconf.exe --list-options gpg"
2853 else:
2854 gpgconfcmd = "gpgconf --list-options gpg"
2855
2856 process = subprocess.Popen(gpgconfcmd.split(), stdout=subprocess.PIPE)
2857 procom = process.communicate()
2858
2859 if sys.version_info[0] == 2:
2860 lines = procom[0].splitlines()
2861 else:
2862 lines = procom[0].decode().splitlines()
2863
2864 for line in lines:
2865 if line.startswith("group") is True:
2866 break
2867
2868 groups = line.split(":")[-1].replace('"', '').split(',')
2869
2870 group_lines = []
2871 group_lists = []
2872
2873 for i in range(len(groups)):
2874 group_lines.append(groups[i].split("="))
2875 group_lists.append(groups[i].split("="))
2876
2877 for i in range(len(group_lists)):
2878 group_lists[i][1] = group_lists[i][1].split()
2879 \end{verbatim}
2880
2881 The result of that code is that \texttt{group\_lines} is a list of lists where
2882 \texttt{group\_lines[i][0]} is the name of the group and \texttt{group\_lines[i][1]}
2883 is the key IDs of the group as a string.
2884
2885 The \texttt{group\_lists} result is very similar in that it is a list of
2886 lists. The first part, \texttt{group\_lists[i][0]} matches
2887 \texttt{group\_lines[i][0]} as the name of the group, but \texttt{group\_lists[i][1]}
2888 is the key IDs of the group as a list.
2889
2890 A demonstration of using the \texttt{groups.py} module is also available in
2891 the form of the executable \texttt{mutt-groups.py} script. This second
2892 script reads all the group entries in a user's \texttt{gpg.conf} file and
2893 converts them into crypt-hooks suitable for use with the Mutt and
2894 Neomutt mail clients.
2895
2896
2897 \subsection{Keyserver access for Python}
2898 \label{sec:org5ad99aa}
2899 The \href{https://github.com/Selfnet/hkp4py}{hkp4py} module by Marcel Fest was originally a port of the old
2900 \href{https://github.com/dgladkov/python-hkp}{python-hkp} module from Python 2 to Python 3 and updated to use the
2901 \href{http://docs.python-requests.org/en/latest/index.html}{requests} module instead. It has since been modified to provide
2902 support for Python 2.7 as well and is available via PyPI.
2903
2904 Since it rewrites the \texttt{hkp} protocol prefix as \texttt{http} and \texttt{hkps} as
2905 \texttt{https}, the module is able to be used even with servers which do not
2906 support the full scope of keyserver functions.\footnote{Such as with ProtonMail servers. This also means that
2907 restricted servers which only advertise either HTTP or HTTPS end
2908 points and not HKP or HKPS end points must still be identified as as
2909 HKP or HKPS within the Python Code. The \texttt{hkp4py} module will rewrite
2910 these appropriately when the connection is made to the server.} It also works quite
2911 readily when incorporated into a \hyperref[sec:org3b53926]{Cython} generated and compiled version
2912 of any code.
2913
2914
2915 \subsubsection{Key import format}
2916 \label{sec:org1e47c97}
2917 The hkp4py module returns key data via requests as string literals
2918 (\texttt{r.text}) instead of byte literals (\texttt{r.content}). This means that
2919 the retrurned key data must be encoded to UTF-8 when importing that
2920 key material using a \texttt{gpg.Context().key\_import()} method.
2921
2922 For this reason an alternative method has been added to the \texttt{search}
2923 function of \texttt{hkp4py.KeyServer()} which returns the key in the correct
2924 format as expected by \texttt{key\_import}. When importing using this module,
2925 it is now possible to import with this:
2926
2927 \begin{verbatim}
2928 for key in keys:
2929 if key.revoked is False:
2930 gpg.Context().key_import(key.key_blob)
2931 else:
2932 pass
2933 \end{verbatim}
2934
2935 Without that recent addition it would have been necessary to encode
2936 the contents of each \texttt{hkp4py.KeyServer().search()[i].key} in
2937 \texttt{hkp4py.KeyServer().search()} before trying to import it.
2938
2939 An example of this is included in the \hyperref[sec:org1ad598a]{Importing Keys} section of this
2940 HOWTO and the corresponding executable version of that example is
2941 available in the \texttt{lang/python/examples/howto} directory as normal; the
2942 executable version is the \texttt{import-keys-hkp.py} file.
2943
2944
2945 \subsection{GPGME version checking}
2946 \label{sec:org18b8ef8}
2947 For various reasons it may be necessary to check which version of
2948 GPGME the bindings have been built against; including whether a
2949 minimum required version of GPGME is in use.
2950
2951 For the most part the \texttt{gpg.version.versionstr} and
2952 \texttt{gpg.version.versionlist} methods have been quite sufficient. The
2953 former returns the same string as \texttt{gpgme-config -{}-version}, while the
2954 latter returns the major, minor and patch values in a list.
2955
2956 To check if the installed bindings have actually been built against
2957 the current installed libgpgme version, this check can be performed:
2958
2959 \begin{verbatim}
2960 import gpg
2961 import subprocess
2962 import sys
2963
2964 gpgme_version_call = subprocess.Popen(["gpgme-config", "--version"],
2965 stdout=subprocess.PIPE,
2966 stderr=subprocess.PIPE)
2967 gpgme_version_str = gpgme_version_call.communicate()
2968
2969 if sys.version_info[0] == 2:
2970 gpgme_version = gpgme_version_str[0].strip()
2971 elif sys.version_info[0] >= 3:
2972 gpgme_version = gpgme_version_str[0].decode().strip()
2973 else:
2974 gpgme_version = None
2975
2976 if gpgme_version is not None:
2977 if gpgme_version == gpg.version.versionstr:
2978 print("The GPGME Python bindings match libgpgme.")
2979 else:
2980 print("The GPGME Python bindings do NOT match libgpgme.")
2981 else:
2982 print("Upgrade Python and reinstall the GPGME Python bindings.")
2983 \end{verbatim}
2984
2985 For many developers, however, the preferred checking means checking
2986 for a minimum version or point release. This is now readily available
2987 via the \texttt{gpg.version.versionintlist} method (added in version
2988 \texttt{1.12.1-beta79}). It is also now possible to easily check whether the
2989 installed GPGME Python bindings were built from a development or beta
2990 branch of the GPGME source code.
2991
2992 The following code demonstrates how both of those methods may be used:
2993
2994 \begin{verbatim}
2995 import gpg
2996
2997 try:
2998 if gpg.version.is_beta is True:
2999 print("The installed GPGME Python bindings were built from beta code.")
3000 else:
3001 print("The installed GPGME Python bindings are a released version.")
3002 except Exception as e:
3003 print(e)
3004
3005 try:
3006 if gpg.version.versionintlist[0] == 1:
3007 if gpg.version.versionintlist[1] == 12:
3008 if gpg.version.versionintlist[2] == 1:
3009 print("This is the minimum version for using versionintlist.")
3010 elif gpg.version.versionintlist[2] > 1:
3011 print("The versionintlist method is available.")
3012 else:
3013 pass
3014 elif gpg.version.versionintlist[1] > 12:
3015 print("The versionintlist method is available.")
3016 else:
3017 pass
3018 elif gpg.version.versionintlist[0] > 1:
3019 print("The versionintlist method is available.")
3020 else:
3021 pass
3022 except Exception as e:
3023 print(e)
3024 \end{verbatim}
3025
3026 The points where \texttt{pass} is used in the above example will most likely
3027 also produce an \texttt{Exception} error since those results should only
3028 occur in versions which do not have the \texttt{gpgme.version.is\_beta} and
3029 \texttt{gpgme.version.versionintlist} methods available.
3030
3031
3032 \section{Copyright and Licensing}
3033 \label{sec:org9d52a23}
3034 \subsection{Copyright}
3035 \label{sec:org26ed04d}
3036 Copyright © The GnuPG Project, 2018.
3037
3038 Copyright (C) The GnuPG Project, 2018.
3039
3040
3041 \subsection{Draft Editions of this HOWTO}
3042 \label{sec:org080a94a}
3043 Draft editions of this HOWTO may be periodically available directly
3044 from the author at any of the following URLs:
3045
3046 \begin{itemize}
3047 \item \href{https://files.au.adversary.org/crypto/gpgme-python-howto.html}{GPGME Python Bindings HOWTO draft (XHTML single file, AWS S3 SSL)}
3048 \item \href{http://files.au.adversary.org/crypto/gpgme-python-howto.html}{GPGME Python Bindings HOWTO draft (XHTML single file, AWS S3 no SSL)}
3049 \item \href{https://files.au.adversary.org/crypto/gpgme-python-howto-split/index.html}{GPGME Python Bindings HOWTO draft (XHTML multiple files, AWS S3 SSL)}
3050 \item \href{http://files.au.adversary.org/crypto/gpgme-python-howto/index.html}{GPGME Python Bindings HOWTO draft (XHTML multiple files, AWS S3 no SSL)}
3051 \end{itemize}
3052
3053 All of these draft versions except for one have been generated from
3054 this document via GNU Emacs \href{https://orgmode.org/}{Org mode} and \href{https://www.gnu.org/software/texinfo/}{GNU Texinfo}. Though it is
3055 likely that the specific \href{https://files.au.adversary.org/crypto/gpgme-python-howto}{file} \href{http://files.au.adversary.org/crypto/gpgme-python-howto.org}{version} used will be on the same server
3056 with the generated output formats.
3057
3058 The GNU Texinfo and reStructured Text versions ship with the software,
3059 while the GNU Emacs Info verseion is generated from the Texinfo
3060 version using GNU Texinfo or GNU Makeinfo. The Texinfo format is
3061 generated from the original Org mode source file in Org mode itself
3062 either within GNU Emacs or via the command line by invoking Emacs in
3063 batch mode:
3064
3065 \begin{verbatim}
3066 emacs gpgme-python-howto.org --batch -f org-texinfo-export-to-texinfo --kill
3067 emacs gpgme-python-howto --batch -f org-texinfo-export-to-texinfo --kill
3068 \end{verbatim}
3069
3070 The reStructuredText format is also generated from the Org-mode source
3071 file, except it is generated using \href{https://pandoc.org}{Pandoc} with either of the following
3072 commands:
3073
3074 \begin{verbatim}
3075 pandoc -f org -t rst+smart -o gpgme-python-howto.rst gpgme-python-howto.org
3076 pandoc -f org -t rst+smart -o gpgme-python-howto.rst gpgme-python-howto
3077 \end{verbatim}
3078
3079 In addition to these there is a significantly less frequently updated
3080 version as a HTML \href{https://files.au.adversary.org/crypto/gpgme-python/dita/webhelp/index.html}{WebHelp site} (AWS S3 SSL); generated from DITA XML
3081 source files, which can be found in \href{https://dev.gnupg.org/source/gpgme/browse/ben\%252Fhowto-dita/}{an alternative branch} of the GPGME
3082 git repository.
3083
3084 Various generated output formats may occasionally be found in
3085 subdirectories of the \href{https://s3.amazonaws.com/files.au.adversary.org/crypto/gpgme-python}{gpgme-python} directory. In particular within
3086 the \href{https://s3.amazonaws.com/files.au.adversary.org/crypto/gpgme-python/dita}{DITA}, \href{https://s3.amazonaws.com/files.au.adversary.org/crypto/gpgme-python/rst}{reStructuredText} and \href{https://s3.amazonaws.com/files.au.adversary.org/crypto/gpgme-python/texinfo}{Texinfo} subdirectories. The \texttt{rst}
3087 directory contains output files generated with Sphix and may include a
3088 considerable number of its possible output formats.
3089
3090 These draft editions are not official documents and the version of
3091 documentation in the master branch or which ships with released
3092 versions is the only official documentation. Nevertheless, these
3093 draft editions may occasionally be of use by providing more accessible
3094 web versions which are updated between releases. They are provided on
3095 the understanding that they may contain errors or may contain content
3096 subject to change prior to an official release.
3097
3098
3099 \subsection{License GPL compatible}
3100 \label{sec:orge78f3b7}
3101 This file is free software; as a special exception the author gives
3102 unlimited permission to copy and/or distribute it, with or without
3103 modifications, as long as this notice is preserved.
3104
3105 This file is distributed in the hope that it will be useful, but
3106 WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
3107 implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
3108 PURPOSE.
3109 \end{document}
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for the Python bindings.
17 # Copyright (C) 2019 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang/python/examples
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES =
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 am__can_run_installinfo = \
143 case $$AM_UPDATE_INFO_DIR in \
144 n|no|NO) false;; \
145 *) (install-info --version) >/dev/null 2>&1;; \
146 esac
147 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
148 am__DIST_COMMON = $(srcdir)/Makefile.in \
149 $(top_srcdir)/build-aux/mkinstalldirs
150 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
151 ACLOCAL = @ACLOCAL@
152 AMTAR = @AMTAR@
153 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
154 AR = @AR@
155 AS = @AS@
156 AUTOCONF = @AUTOCONF@
157 AUTOHEADER = @AUTOHEADER@
158 AUTOMAKE = @AUTOMAKE@
159 AWK = @AWK@
160 BUILD_FILEVERSION = @BUILD_FILEVERSION@
161 BUILD_REVISION = @BUILD_REVISION@
162 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
163 BUILD_VERSION = @BUILD_VERSION@
164 CC = @CC@
165 CCDEPMODE = @CCDEPMODE@
166 CC_FOR_BUILD = @CC_FOR_BUILD@
167 CFLAGS = @CFLAGS@
168 CPP = @CPP@
169 CPPFLAGS = @CPPFLAGS@
170 CXX = @CXX@
171 CXXCPP = @CXXCPP@
172 CXXDEPMODE = @CXXDEPMODE@
173 CXXFLAGS = @CXXFLAGS@
174 CYGPATH_W = @CYGPATH_W@
175 DEFS = @DEFS@
176 DEPDIR = @DEPDIR@
177 DLLTOOL = @DLLTOOL@
178 DOXYGEN = @DOXYGEN@
179 DSYMUTIL = @DSYMUTIL@
180 DUMPBIN = @DUMPBIN@
181 ECHO_C = @ECHO_C@
182 ECHO_N = @ECHO_N@
183 ECHO_T = @ECHO_T@
184 EGREP = @EGREP@
185 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
186 EXEEXT = @EXEEXT@
187 FGREP = @FGREP@
188 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
189 GLIBC21 = @GLIBC21@
190 GLIB_CFLAGS = @GLIB_CFLAGS@
191 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
192 GLIB_LIBS = @GLIB_LIBS@
193 GLIB_MKENUMS = @GLIB_MKENUMS@
194 GOBJECT_QUERY = @GOBJECT_QUERY@
195 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
196 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
197 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
198 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
199 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
200 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
201 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
202 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
203 GPGME_QT_LIBS = @GPGME_QT_LIBS@
204 GPGRT_CONFIG = @GPGRT_CONFIG@
205 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
206 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
207 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
208 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
209 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
210 GRAPHVIZ = @GRAPHVIZ@
211 GREP = @GREP@
212 HAVE_CXX11 = @HAVE_CXX11@
213 HAVE_DOT = @HAVE_DOT@
214 INSTALL = @INSTALL@
215 INSTALL_DATA = @INSTALL_DATA@
216 INSTALL_PROGRAM = @INSTALL_PROGRAM@
217 INSTALL_SCRIPT = @INSTALL_SCRIPT@
218 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
219 LD = @LD@
220 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
221 LDFLAGS = @LDFLAGS@
222 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
223 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
224 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
225 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
226 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
227 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
228 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
229 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
230 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
231 LIBOBJS = @LIBOBJS@
232 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
233 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
234 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
235 LIBS = @LIBS@
236 LIBTOOL = @LIBTOOL@
237 LIPO = @LIPO@
238 LN_S = @LN_S@
239 LTLIBOBJS = @LTLIBOBJS@
240 MAINT = @MAINT@
241 MAKEINFO = @MAKEINFO@
242 MANIFEST_TOOL = @MANIFEST_TOOL@
243 MKDIR_P = @MKDIR_P@
244 MOC = @MOC@
245 MOC2 = @MOC2@
246 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
247 NM = @NM@
248 NMEDIT = @NMEDIT@
249 OBJDUMP = @OBJDUMP@
250 OBJEXT = @OBJEXT@
251 OTOOL = @OTOOL@
252 OTOOL64 = @OTOOL64@
253 PACKAGE = @PACKAGE@
254 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
255 PACKAGE_NAME = @PACKAGE_NAME@
256 PACKAGE_STRING = @PACKAGE_STRING@
257 PACKAGE_TARNAME = @PACKAGE_TARNAME@
258 PACKAGE_URL = @PACKAGE_URL@
259 PACKAGE_VERSION = @PACKAGE_VERSION@
260 PATH_SEPARATOR = @PATH_SEPARATOR@
261 PKG_CONFIG = @PKG_CONFIG@
262 PYTHON = @PYTHON@
263 PYTHONS = @PYTHONS@
264 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
265 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
266 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
267 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
268 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
269 PYTHON_PLATFORM = @PYTHON_PLATFORM@
270 PYTHON_PREFIX = @PYTHON_PREFIX@
271 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
272 PYTHON_VERSION = @PYTHON_VERSION@
273 QTCHOOSER = @QTCHOOSER@
274 RANLIB = @RANLIB@
275 RC = @RC@
276 SED = @SED@
277 SET_MAKE = @SET_MAKE@
278 SHELL = @SHELL@
279 STRIP = @STRIP@
280 SWIG = @SWIG@
281 SWIG_LIB = @SWIG_LIB@
282 SYSROOT = @SYSROOT@
283 VERSION = @VERSION@
284 VERSION_MAJOR = @VERSION_MAJOR@
285 VERSION_MICRO = @VERSION_MICRO@
286 VERSION_MINOR = @VERSION_MINOR@
287 VERSION_NUMBER = @VERSION_NUMBER@
288 abs_builddir = @abs_builddir@
289 abs_srcdir = @abs_srcdir@
290 abs_top_builddir = @abs_top_builddir@
291 abs_top_srcdir = @abs_top_srcdir@
292 ac_ct_AR = @ac_ct_AR@
293 ac_ct_CC = @ac_ct_CC@
294 ac_ct_CXX = @ac_ct_CXX@
295 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
296 am__include = @am__include@
297 am__leading_dot = @am__leading_dot@
298 am__quote = @am__quote@
299 am__tar = @am__tar@
300 am__untar = @am__untar@
301 bindir = @bindir@
302 build = @build@
303 build_alias = @build_alias@
304 build_cpu = @build_cpu@
305 build_os = @build_os@
306 build_vendor = @build_vendor@
307 builddir = @builddir@
308 datadir = @datadir@
309 datarootdir = @datarootdir@
310 docdir = @docdir@
311 dvidir = @dvidir@
312 emacs_local_vars_begin = @emacs_local_vars_begin@
313 emacs_local_vars_end = @emacs_local_vars_end@
314 emacs_local_vars_read_only = @emacs_local_vars_read_only@
315 exec_prefix = @exec_prefix@
316 host = @host@
317 host_alias = @host_alias@
318 host_cpu = @host_cpu@
319 host_os = @host_os@
320 host_vendor = @host_vendor@
321 htmldir = @htmldir@
322 includedir = @includedir@
323 infodir = @infodir@
324 install_sh = @install_sh@
325 libdir = @libdir@
326 libexecdir = @libexecdir@
327 localedir = @localedir@
328 localstatedir = @localstatedir@
329 mandir = @mandir@
330 mkdir_p = @mkdir_p@
331 oldincludedir = @oldincludedir@
332 pdfdir = @pdfdir@
333 pkgpyexecdir = @pkgpyexecdir@
334 pkgpythondir = @pkgpythondir@
335 prefix = @prefix@
336 program_transform_name = @program_transform_name@
337 psdir = @psdir@
338 pyexecdir = @pyexecdir@
339 pythondir = @pythondir@
340 runstatedir = @runstatedir@
341 sbindir = @sbindir@
342 sharedstatedir = @sharedstatedir@
343 srcdir = @srcdir@
344 sysconfdir = @sysconfdir@
345 target_alias = @target_alias@
346 top_build_prefix = @top_build_prefix@
347 top_builddir = @top_builddir@
348 top_srcdir = @top_srcdir@
349
350 # Created by:
351 # find . -type f -print | sed 's/^.\// /;$q;s/$/ \\/' | sort
352 EXTRA_DIST = assuan.py \
353 decryption-filter.py \
354 delkey.py \
355 exportimport.py \
356 genkey.py \
357 howto/add-userid.py \
358 howto/advanced/cython/keycount.pyx \
359 howto/advanced/cython/requirements.txt \
360 howto/advanced/cython/setup.py \
361 howto/clear-sign-file.py \
362 howto/create-key.py \
363 howto/decrypt-file.py \
364 howto/detach-sign-file.py \
365 howto/encrypt-file.py \
366 howto/encrypt-sign-file.py \
367 howto/encrypt-to-group-gullible.py \
368 howto/encrypt-to-group.py \
369 howto/encrypt-to-group-trustno1.py \
370 howto/export-key.py \
371 howto/export-minimised-key.py \
372 howto/export-secret-key.py \
373 howto/export-secret-keys.py \
374 howto/groups.py \
375 howto/import-keybasekey.py \
376 howto/import-key.py \
377 howto/import-keys-hkp.py \
378 howto/import-keys.py \
379 howto/import-mailvelope-keys.py \
380 howto/keycount.py \
381 howto/local-sign-group.py \
382 howto/mutt-groups.py \
383 howto/pmkey-import-alt.py \
384 howto/pmkey-import-hkp-alt.py \
385 howto/pmkey-import-hkp.py \
386 howto/pmkey-import.py \
387 howto/post_installer.py \
388 howto/README.org \
389 howto/requirements.txt \
390 howto/revoke-userid.py \
391 howto/send-key-to-keyserver.py \
392 howto/sign-file.py \
393 howto/sign-key.py \
394 howto/symcrypt-file.py \
395 howto/temp-homedir-config.py \
396 howto/verify-signatures.py \
397 howto/verify-signed-file.py \
398 inter-edit.py \
399 low_level-encrypt_to_all.py \
400 sign.py \
401 signverify.py \
402 simple.py \
403 testCMSgetkey.py \
404 verifydetails.py
405
406 all: all-am
407
408 .SUFFIXES:
409 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
410 @for dep in $?; do \
411 case '$(am__configure_deps)' in \
412 *$$dep*) \
413 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
414 && { if test -f $@; then exit 0; else break; fi; }; \
415 exit 1;; \
416 esac; \
417 done; \
418 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/python/examples/Makefile'; \
419 $(am__cd) $(top_srcdir) && \
420 $(AUTOMAKE) --gnu lang/python/examples/Makefile
421 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
422 @case '$?' in \
423 *config.status*) \
424 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
425 *) \
426 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
427 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
428 esac;
429
430 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
431 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
432
433 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
434 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
435 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
436 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
437 $(am__aclocal_m4_deps):
438
439 mostlyclean-libtool:
440 -rm -f *.lo
441
442 clean-libtool:
443 -rm -rf .libs _libs
444 tags TAGS:
445
446 ctags CTAGS:
447
448 cscope cscopelist:
449
450
451 distdir: $(BUILT_SOURCES)
452 $(MAKE) $(AM_MAKEFLAGS) distdir-am
453
454 distdir-am: $(DISTFILES)
455 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
456 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
457 list='$(DISTFILES)'; \
458 dist_files=`for file in $$list; do echo $$file; done | \
459 sed -e "s|^$$srcdirstrip/||;t" \
460 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
461 case $$dist_files in \
462 */*) $(MKDIR_P) `echo "$$dist_files" | \
463 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
464 sort -u` ;; \
465 esac; \
466 for file in $$dist_files; do \
467 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
468 if test -d $$d/$$file; then \
469 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
470 if test -d "$(distdir)/$$file"; then \
471 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
472 fi; \
473 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
474 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
475 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
476 fi; \
477 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
478 else \
479 test -f "$(distdir)/$$file" \
480 || cp -p $$d/$$file "$(distdir)/$$file" \
481 || exit 1; \
482 fi; \
483 done
484 check-am: all-am
485 check: check-am
486 all-am: Makefile
487 installdirs:
488 install: install-am
489 install-exec: install-exec-am
490 install-data: install-data-am
491 uninstall: uninstall-am
492
493 install-am: all-am
494 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
495
496 installcheck: installcheck-am
497 install-strip:
498 if test -z '$(STRIP)'; then \
499 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
500 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
501 install; \
502 else \
503 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
504 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
505 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
506 fi
507 mostlyclean-generic:
508
509 clean-generic:
510
511 distclean-generic:
512 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
513 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
514
515 maintainer-clean-generic:
516 @echo "This command is intended for maintainers to use"
517 @echo "it deletes files that may require special tools to rebuild."
518 clean: clean-am
519
520 clean-am: clean-generic clean-libtool mostlyclean-am
521
522 distclean: distclean-am
523 -rm -f Makefile
524 distclean-am: clean-am distclean-generic
525
526 dvi: dvi-am
527
528 dvi-am:
529
530 html: html-am
531
532 html-am:
533
534 info: info-am
535
536 info-am:
537
538 install-data-am:
539
540 install-dvi: install-dvi-am
541
542 install-dvi-am:
543
544 install-exec-am:
545
546 install-html: install-html-am
547
548 install-html-am:
549
550 install-info: install-info-am
551
552 install-info-am:
553
554 install-man:
555
556 install-pdf: install-pdf-am
557
558 install-pdf-am:
559
560 install-ps: install-ps-am
561
562 install-ps-am:
563
564 installcheck-am:
565
566 maintainer-clean: maintainer-clean-am
567 -rm -f Makefile
568 maintainer-clean-am: distclean-am maintainer-clean-generic
569
570 mostlyclean: mostlyclean-am
571
572 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
573
574 pdf: pdf-am
575
576 pdf-am:
577
578 ps: ps-am
579
580 ps-am:
581
582 uninstall-am:
583
584 .MAKE: install-am install-strip
585
586 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
587 cscopelist-am ctags-am distclean distclean-generic \
588 distclean-libtool distdir dvi dvi-am html html-am info info-am \
589 install install-am install-data install-data-am install-dvi \
590 install-dvi-am install-exec install-exec-am install-html \
591 install-html-am install-info install-info-am install-man \
592 install-pdf install-pdf-am install-ps install-ps-am \
593 install-strip installcheck installcheck-am installdirs \
594 maintainer-clean maintainer-clean-generic mostlyclean \
595 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
596 tags-am uninstall uninstall-am
597
598 .PRECIOUS: Makefile
599
600
601 # Tell versions [3.59,3.63) of GNU make to not export all variables.
602 # Otherwise a system limit (for SysV at least) may be exceeded.
603 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for the Python bindings.
17 # Copyright (C) 2019 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang/python/src
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES =
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 am__can_run_installinfo = \
143 case $$AM_UPDATE_INFO_DIR in \
144 n|no|NO) false;; \
145 *) (install-info --version) >/dev/null 2>&1;; \
146 esac
147 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
148 am__DIST_COMMON = $(srcdir)/Makefile.in \
149 $(top_srcdir)/build-aux/mkinstalldirs
150 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
151 ACLOCAL = @ACLOCAL@
152 AMTAR = @AMTAR@
153 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
154 AR = @AR@
155 AS = @AS@
156 AUTOCONF = @AUTOCONF@
157 AUTOHEADER = @AUTOHEADER@
158 AUTOMAKE = @AUTOMAKE@
159 AWK = @AWK@
160 BUILD_FILEVERSION = @BUILD_FILEVERSION@
161 BUILD_REVISION = @BUILD_REVISION@
162 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
163 BUILD_VERSION = @BUILD_VERSION@
164 CC = @CC@
165 CCDEPMODE = @CCDEPMODE@
166 CC_FOR_BUILD = @CC_FOR_BUILD@
167 CFLAGS = @CFLAGS@
168 CPP = @CPP@
169 CPPFLAGS = @CPPFLAGS@
170 CXX = @CXX@
171 CXXCPP = @CXXCPP@
172 CXXDEPMODE = @CXXDEPMODE@
173 CXXFLAGS = @CXXFLAGS@
174 CYGPATH_W = @CYGPATH_W@
175 DEFS = @DEFS@
176 DEPDIR = @DEPDIR@
177 DLLTOOL = @DLLTOOL@
178 DOXYGEN = @DOXYGEN@
179 DSYMUTIL = @DSYMUTIL@
180 DUMPBIN = @DUMPBIN@
181 ECHO_C = @ECHO_C@
182 ECHO_N = @ECHO_N@
183 ECHO_T = @ECHO_T@
184 EGREP = @EGREP@
185 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
186 EXEEXT = @EXEEXT@
187 FGREP = @FGREP@
188 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
189 GLIBC21 = @GLIBC21@
190 GLIB_CFLAGS = @GLIB_CFLAGS@
191 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
192 GLIB_LIBS = @GLIB_LIBS@
193 GLIB_MKENUMS = @GLIB_MKENUMS@
194 GOBJECT_QUERY = @GOBJECT_QUERY@
195 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
196 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
197 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
198 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
199 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
200 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
201 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
202 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
203 GPGME_QT_LIBS = @GPGME_QT_LIBS@
204 GPGRT_CONFIG = @GPGRT_CONFIG@
205 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
206 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
207 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
208 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
209 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
210 GRAPHVIZ = @GRAPHVIZ@
211 GREP = @GREP@
212 HAVE_CXX11 = @HAVE_CXX11@
213 HAVE_DOT = @HAVE_DOT@
214 INSTALL = @INSTALL@
215 INSTALL_DATA = @INSTALL_DATA@
216 INSTALL_PROGRAM = @INSTALL_PROGRAM@
217 INSTALL_SCRIPT = @INSTALL_SCRIPT@
218 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
219 LD = @LD@
220 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
221 LDFLAGS = @LDFLAGS@
222 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
223 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
224 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
225 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
226 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
227 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
228 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
229 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
230 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
231 LIBOBJS = @LIBOBJS@
232 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
233 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
234 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
235 LIBS = @LIBS@
236 LIBTOOL = @LIBTOOL@
237 LIPO = @LIPO@
238 LN_S = @LN_S@
239 LTLIBOBJS = @LTLIBOBJS@
240 MAINT = @MAINT@
241 MAKEINFO = @MAKEINFO@
242 MANIFEST_TOOL = @MANIFEST_TOOL@
243 MKDIR_P = @MKDIR_P@
244 MOC = @MOC@
245 MOC2 = @MOC2@
246 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
247 NM = @NM@
248 NMEDIT = @NMEDIT@
249 OBJDUMP = @OBJDUMP@
250 OBJEXT = @OBJEXT@
251 OTOOL = @OTOOL@
252 OTOOL64 = @OTOOL64@
253 PACKAGE = @PACKAGE@
254 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
255 PACKAGE_NAME = @PACKAGE_NAME@
256 PACKAGE_STRING = @PACKAGE_STRING@
257 PACKAGE_TARNAME = @PACKAGE_TARNAME@
258 PACKAGE_URL = @PACKAGE_URL@
259 PACKAGE_VERSION = @PACKAGE_VERSION@
260 PATH_SEPARATOR = @PATH_SEPARATOR@
261 PKG_CONFIG = @PKG_CONFIG@
262 PYTHON = @PYTHON@
263 PYTHONS = @PYTHONS@
264 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
265 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
266 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
267 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
268 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
269 PYTHON_PLATFORM = @PYTHON_PLATFORM@
270 PYTHON_PREFIX = @PYTHON_PREFIX@
271 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
272 PYTHON_VERSION = @PYTHON_VERSION@
273 QTCHOOSER = @QTCHOOSER@
274 RANLIB = @RANLIB@
275 RC = @RC@
276 SED = @SED@
277 SET_MAKE = @SET_MAKE@
278 SHELL = @SHELL@
279 STRIP = @STRIP@
280 SWIG = @SWIG@
281 SWIG_LIB = @SWIG_LIB@
282 SYSROOT = @SYSROOT@
283 VERSION = @VERSION@
284 VERSION_MAJOR = @VERSION_MAJOR@
285 VERSION_MICRO = @VERSION_MICRO@
286 VERSION_MINOR = @VERSION_MINOR@
287 VERSION_NUMBER = @VERSION_NUMBER@
288 abs_builddir = @abs_builddir@
289 abs_srcdir = @abs_srcdir@
290 abs_top_builddir = @abs_top_builddir@
291 abs_top_srcdir = @abs_top_srcdir@
292 ac_ct_AR = @ac_ct_AR@
293 ac_ct_CC = @ac_ct_CC@
294 ac_ct_CXX = @ac_ct_CXX@
295 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
296 am__include = @am__include@
297 am__leading_dot = @am__leading_dot@
298 am__quote = @am__quote@
299 am__tar = @am__tar@
300 am__untar = @am__untar@
301 bindir = @bindir@
302 build = @build@
303 build_alias = @build_alias@
304 build_cpu = @build_cpu@
305 build_os = @build_os@
306 build_vendor = @build_vendor@
307 builddir = @builddir@
308 datadir = @datadir@
309 datarootdir = @datarootdir@
310 docdir = @docdir@
311 dvidir = @dvidir@
312 emacs_local_vars_begin = @emacs_local_vars_begin@
313 emacs_local_vars_end = @emacs_local_vars_end@
314 emacs_local_vars_read_only = @emacs_local_vars_read_only@
315 exec_prefix = @exec_prefix@
316 host = @host@
317 host_alias = @host_alias@
318 host_cpu = @host_cpu@
319 host_os = @host_os@
320 host_vendor = @host_vendor@
321 htmldir = @htmldir@
322 includedir = @includedir@
323 infodir = @infodir@
324 install_sh = @install_sh@
325 libdir = @libdir@
326 libexecdir = @libexecdir@
327 localedir = @localedir@
328 localstatedir = @localstatedir@
329 mandir = @mandir@
330 mkdir_p = @mkdir_p@
331 oldincludedir = @oldincludedir@
332 pdfdir = @pdfdir@
333 pkgpyexecdir = @pkgpyexecdir@
334 pkgpythondir = @pkgpythondir@
335 prefix = @prefix@
336 program_transform_name = @program_transform_name@
337 psdir = @psdir@
338 pyexecdir = @pyexecdir@
339 pythondir = @pythondir@
340 runstatedir = @runstatedir@
341 sbindir = @sbindir@
342 sharedstatedir = @sharedstatedir@
343 srcdir = @srcdir@
344 sysconfdir = @sysconfdir@
345 target_alias = @target_alias@
346 top_build_prefix = @top_build_prefix@
347 top_builddir = @top_builddir@
348 top_srcdir = @top_srcdir@
349
350 # Created by:
351 # find . -type f -print | sed 's/^.\// /;$q;s/$/ \\/' | sort
352 EXTRA_DIST = callbacks.py \
353 constants/create.py \
354 constants/data/encoding.py \
355 constants/data/__init__.py \
356 constants/event.py \
357 constants/import_type.py \
358 constants/__init__.py \
359 constants/keylist/__init__.py \
360 constants/keylist/mode.py \
361 constants/keysign.py \
362 constants/md.py \
363 constants/pk.py \
364 constants/protocol.py \
365 constants/sig/__init__.py \
366 constants/sig/mode.py \
367 constants/sig/notation.py \
368 constants/sigsum.py \
369 constants/status.py \
370 constants/tofu/__init__.py \
371 constants/tofu/policy.py \
372 constants/validity.py \
373 core.py \
374 errors.py \
375 __init__.py \
376 results.py \
377 util.py
378
379 all: all-am
380
381 .SUFFIXES:
382 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
383 @for dep in $?; do \
384 case '$(am__configure_deps)' in \
385 *$$dep*) \
386 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
387 && { if test -f $@; then exit 0; else break; fi; }; \
388 exit 1;; \
389 esac; \
390 done; \
391 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/python/src/Makefile'; \
392 $(am__cd) $(top_srcdir) && \
393 $(AUTOMAKE) --gnu lang/python/src/Makefile
394 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
395 @case '$?' in \
396 *config.status*) \
397 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
398 *) \
399 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
400 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
401 esac;
402
403 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
404 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
405
406 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
407 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
408 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
409 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
410 $(am__aclocal_m4_deps):
411
412 mostlyclean-libtool:
413 -rm -f *.lo
414
415 clean-libtool:
416 -rm -rf .libs _libs
417 tags TAGS:
418
419 ctags CTAGS:
420
421 cscope cscopelist:
422
423
424 distdir: $(BUILT_SOURCES)
425 $(MAKE) $(AM_MAKEFLAGS) distdir-am
426
427 distdir-am: $(DISTFILES)
428 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
429 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
430 list='$(DISTFILES)'; \
431 dist_files=`for file in $$list; do echo $$file; done | \
432 sed -e "s|^$$srcdirstrip/||;t" \
433 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
434 case $$dist_files in \
435 */*) $(MKDIR_P) `echo "$$dist_files" | \
436 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
437 sort -u` ;; \
438 esac; \
439 for file in $$dist_files; do \
440 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
441 if test -d $$d/$$file; then \
442 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
443 if test -d "$(distdir)/$$file"; then \
444 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
445 fi; \
446 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
447 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
448 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
449 fi; \
450 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
451 else \
452 test -f "$(distdir)/$$file" \
453 || cp -p $$d/$$file "$(distdir)/$$file" \
454 || exit 1; \
455 fi; \
456 done
457 check-am: all-am
458 check: check-am
459 all-am: Makefile
460 installdirs:
461 install: install-am
462 install-exec: install-exec-am
463 install-data: install-data-am
464 uninstall: uninstall-am
465
466 install-am: all-am
467 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
468
469 installcheck: installcheck-am
470 install-strip:
471 if test -z '$(STRIP)'; then \
472 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
473 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
474 install; \
475 else \
476 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
477 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
478 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
479 fi
480 mostlyclean-generic:
481
482 clean-generic:
483
484 distclean-generic:
485 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
486 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
487
488 maintainer-clean-generic:
489 @echo "This command is intended for maintainers to use"
490 @echo "it deletes files that may require special tools to rebuild."
491 clean: clean-am
492
493 clean-am: clean-generic clean-libtool mostlyclean-am
494
495 distclean: distclean-am
496 -rm -f Makefile
497 distclean-am: clean-am distclean-generic
498
499 dvi: dvi-am
500
501 dvi-am:
502
503 html: html-am
504
505 html-am:
506
507 info: info-am
508
509 info-am:
510
511 install-data-am:
512
513 install-dvi: install-dvi-am
514
515 install-dvi-am:
516
517 install-exec-am:
518
519 install-html: install-html-am
520
521 install-html-am:
522
523 install-info: install-info-am
524
525 install-info-am:
526
527 install-man:
528
529 install-pdf: install-pdf-am
530
531 install-pdf-am:
532
533 install-ps: install-ps-am
534
535 install-ps-am:
536
537 installcheck-am:
538
539 maintainer-clean: maintainer-clean-am
540 -rm -f Makefile
541 maintainer-clean-am: distclean-am maintainer-clean-generic
542
543 mostlyclean: mostlyclean-am
544
545 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
546
547 pdf: pdf-am
548
549 pdf-am:
550
551 ps: ps-am
552
553 ps-am:
554
555 uninstall-am:
556
557 .MAKE: install-am install-strip
558
559 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
560 cscopelist-am ctags-am distclean distclean-generic \
561 distclean-libtool distdir dvi dvi-am html html-am info info-am \
562 install install-am install-data install-data-am install-dvi \
563 install-dvi-am install-exec install-exec-am install-html \
564 install-html-am install-info install-info-am install-man \
565 install-pdf install-pdf-am install-ps install-ps-am \
566 install-strip installcheck installcheck-am installdirs \
567 maintainer-clean maintainer-clean-generic mostlyclean \
568 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
569 tags-am uninstall uninstall-am
570
571 .PRECIOUS: Makefile
572
573
574 # Tell versions [3.59,3.63) of GNU make to not export all variables.
575 # Otherwise a system limit (for SysV at least) may be exceeded.
576 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for the tests of the Python bindings.
17 # Copyright (C) 2016 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU General Public License as published by
23 # the Free Software Foundation; either version 2 of the License, or
24 # (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://www.gnu.org/licenses/>.
33 VPATH = @srcdir@
34 am__is_gnu_make = { \
35 if test -z '$(MAKELEVEL)'; then \
36 false; \
37 elif test -n '$(MAKE_HOST)'; then \
38 true; \
39 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
40 true; \
41 else \
42 false; \
43 fi; \
44 }
45 am__make_running_with_option = \
46 case $${target_option-} in \
47 ?) ;; \
48 *) echo "am__make_running_with_option: internal error: invalid" \
49 "target option '$${target_option-}' specified" >&2; \
50 exit 1;; \
51 esac; \
52 has_opt=no; \
53 sane_makeflags=$$MAKEFLAGS; \
54 if $(am__is_gnu_make); then \
55 sane_makeflags=$$MFLAGS; \
56 else \
57 case $$MAKEFLAGS in \
58 *\\[\ \ ]*) \
59 bs=\\; \
60 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
61 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
62 esac; \
63 fi; \
64 skip_next=no; \
65 strip_trailopt () \
66 { \
67 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
68 }; \
69 for flg in $$sane_makeflags; do \
70 test $$skip_next = yes && { skip_next=no; continue; }; \
71 case $$flg in \
72 *=*|--*) continue;; \
73 -*I) strip_trailopt 'I'; skip_next=yes;; \
74 -*I?*) strip_trailopt 'I';; \
75 -*O) strip_trailopt 'O'; skip_next=yes;; \
76 -*O?*) strip_trailopt 'O';; \
77 -*l) strip_trailopt 'l'; skip_next=yes;; \
78 -*l?*) strip_trailopt 'l';; \
79 -[dEDm]) skip_next=yes;; \
80 -[JT]) skip_next=yes;; \
81 esac; \
82 case $$flg in \
83 *$$target_option*) has_opt=yes; break;; \
84 esac; \
85 done; \
86 test $$has_opt = yes
87 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
88 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
89 pkgdatadir = $(datadir)/@PACKAGE@
90 pkgincludedir = $(includedir)/@PACKAGE@
91 pkglibdir = $(libdir)/@PACKAGE@
92 pkglibexecdir = $(libexecdir)/@PACKAGE@
93 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
94 install_sh_DATA = $(install_sh) -c -m 644
95 install_sh_PROGRAM = $(install_sh) -c
96 install_sh_SCRIPT = $(install_sh) -c
97 INSTALL_HEADER = $(INSTALL_DATA)
98 transform = $(program_transform_name)
99 NORMAL_INSTALL = :
100 PRE_INSTALL = :
101 POST_INSTALL = :
102 NORMAL_UNINSTALL = :
103 PRE_UNINSTALL = :
104 POST_UNINSTALL = :
105 build_triplet = @build@
106 host_triplet = @host@
107 subdir = lang/python/tests
108 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
109 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
110 $(top_srcdir)/m4/ax_pkg_swig.m4 \
111 $(top_srcdir)/m4/ax_python_devel.m4 \
112 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
113 $(top_srcdir)/m4/gnupg-ttyname.m4 \
114 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
115 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
116 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
117 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
118 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
119 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
120 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
121 $(ACLOCAL_M4)
122 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
123 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
124 CONFIG_HEADER = $(top_builddir)/conf/config.h
125 CONFIG_CLEAN_FILES =
126 CONFIG_CLEAN_VPATH_FILES =
127 AM_V_P = $(am__v_P_@AM_V@)
128 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
129 am__v_P_0 = false
130 am__v_P_1 = :
131 AM_V_GEN = $(am__v_GEN_@AM_V@)
132 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
133 am__v_GEN_0 = @echo " GEN " $@;
134 am__v_GEN_1 =
135 AM_V_at = $(am__v_at_@AM_V@)
136 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
137 am__v_at_0 = @
138 am__v_at_1 =
139 SOURCES =
140 DIST_SOURCES =
141 am__can_run_installinfo = \
142 case $$AM_UPDATE_INFO_DIR in \
143 n|no|NO) false;; \
144 *) (install-info --version) >/dev/null 2>&1;; \
145 esac
146 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
147 am__DIST_COMMON = $(srcdir)/Makefile.in \
148 $(top_srcdir)/build-aux/mkinstalldirs
149 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
150 ACLOCAL = @ACLOCAL@
151 AMTAR = @AMTAR@
152 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
153 AR = @AR@
154 AS = @AS@
155 AUTOCONF = @AUTOCONF@
156 AUTOHEADER = @AUTOHEADER@
157 AUTOMAKE = @AUTOMAKE@
158 AWK = @AWK@
159 BUILD_FILEVERSION = @BUILD_FILEVERSION@
160 BUILD_REVISION = @BUILD_REVISION@
161 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
162 BUILD_VERSION = @BUILD_VERSION@
163 CC = @CC@
164 CCDEPMODE = @CCDEPMODE@
165 CC_FOR_BUILD = @CC_FOR_BUILD@
166 CFLAGS = @CFLAGS@
167 CPP = @CPP@
168 CPPFLAGS = @CPPFLAGS@
169 CXX = @CXX@
170 CXXCPP = @CXXCPP@
171 CXXDEPMODE = @CXXDEPMODE@
172 CXXFLAGS = @CXXFLAGS@
173 CYGPATH_W = @CYGPATH_W@
174 DEFS = @DEFS@
175 DEPDIR = @DEPDIR@
176 DLLTOOL = @DLLTOOL@
177 DOXYGEN = @DOXYGEN@
178 DSYMUTIL = @DSYMUTIL@
179 DUMPBIN = @DUMPBIN@
180 ECHO_C = @ECHO_C@
181 ECHO_N = @ECHO_N@
182 ECHO_T = @ECHO_T@
183 EGREP = @EGREP@
184 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
185 EXEEXT = @EXEEXT@
186 FGREP = @FGREP@
187 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
188 GLIBC21 = @GLIBC21@
189 GLIB_CFLAGS = @GLIB_CFLAGS@
190 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
191 GLIB_LIBS = @GLIB_LIBS@
192 GLIB_MKENUMS = @GLIB_MKENUMS@
193 GOBJECT_QUERY = @GOBJECT_QUERY@
194 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
195 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
196 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
197 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
198 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
199 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
200 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
201 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
202 GPGME_QT_LIBS = @GPGME_QT_LIBS@
203 GPGRT_CONFIG = @GPGRT_CONFIG@
204 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
205 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
206 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
207 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
208 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
209 GRAPHVIZ = @GRAPHVIZ@
210 GREP = @GREP@
211 HAVE_CXX11 = @HAVE_CXX11@
212 HAVE_DOT = @HAVE_DOT@
213 INSTALL = @INSTALL@
214 INSTALL_DATA = @INSTALL_DATA@
215 INSTALL_PROGRAM = @INSTALL_PROGRAM@
216 INSTALL_SCRIPT = @INSTALL_SCRIPT@
217 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
218 LD = @LD@
219 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
220 LDFLAGS = @LDFLAGS@
221 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
222 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
223 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
224 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
225 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
226 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
227 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
228 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
229 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
230 LIBOBJS = @LIBOBJS@
231 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
232 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
233 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
234 LIBS = @LIBS@
235 LIBTOOL = @LIBTOOL@
236 LIPO = @LIPO@
237 LN_S = @LN_S@
238 LTLIBOBJS = @LTLIBOBJS@
239 MAINT = @MAINT@
240 MAKEINFO = @MAKEINFO@
241 MANIFEST_TOOL = @MANIFEST_TOOL@
242 MKDIR_P = @MKDIR_P@
243 MOC = @MOC@
244 MOC2 = @MOC2@
245 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
246 NM = @NM@
247 NMEDIT = @NMEDIT@
248 OBJDUMP = @OBJDUMP@
249 OBJEXT = @OBJEXT@
250 OTOOL = @OTOOL@
251 OTOOL64 = @OTOOL64@
252 PACKAGE = @PACKAGE@
253 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
254 PACKAGE_NAME = @PACKAGE_NAME@
255 PACKAGE_STRING = @PACKAGE_STRING@
256 PACKAGE_TARNAME = @PACKAGE_TARNAME@
257 PACKAGE_URL = @PACKAGE_URL@
258 PACKAGE_VERSION = @PACKAGE_VERSION@
259 PATH_SEPARATOR = @PATH_SEPARATOR@
260 PKG_CONFIG = @PKG_CONFIG@
261 PYTHON = @PYTHON@
262 PYTHONS = @PYTHONS@
263 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
264 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
265 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
266 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
267 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
268 PYTHON_PLATFORM = @PYTHON_PLATFORM@
269 PYTHON_PREFIX = @PYTHON_PREFIX@
270 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
271 PYTHON_VERSION = @PYTHON_VERSION@
272 QTCHOOSER = @QTCHOOSER@
273 RANLIB = @RANLIB@
274 RC = @RC@
275 SED = @SED@
276 SET_MAKE = @SET_MAKE@
277 SHELL = @SHELL@
278 STRIP = @STRIP@
279 SWIG = @SWIG@
280 SWIG_LIB = @SWIG_LIB@
281 SYSROOT = @SYSROOT@
282 VERSION = @VERSION@
283 VERSION_MAJOR = @VERSION_MAJOR@
284 VERSION_MICRO = @VERSION_MICRO@
285 VERSION_MINOR = @VERSION_MINOR@
286 VERSION_NUMBER = @VERSION_NUMBER@
287 abs_builddir = @abs_builddir@
288 abs_srcdir = @abs_srcdir@
289 abs_top_builddir = @abs_top_builddir@
290 abs_top_srcdir = @abs_top_srcdir@
291 ac_ct_AR = @ac_ct_AR@
292 ac_ct_CC = @ac_ct_CC@
293 ac_ct_CXX = @ac_ct_CXX@
294 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
295 am__include = @am__include@
296 am__leading_dot = @am__leading_dot@
297 am__quote = @am__quote@
298 am__tar = @am__tar@
299 am__untar = @am__untar@
300 bindir = @bindir@
301 build = @build@
302 build_alias = @build_alias@
303 build_cpu = @build_cpu@
304 build_os = @build_os@
305 build_vendor = @build_vendor@
306 builddir = @builddir@
307 datadir = @datadir@
308 datarootdir = @datarootdir@
309 docdir = @docdir@
310 dvidir = @dvidir@
311 emacs_local_vars_begin = @emacs_local_vars_begin@
312 emacs_local_vars_end = @emacs_local_vars_end@
313 emacs_local_vars_read_only = @emacs_local_vars_read_only@
314 exec_prefix = @exec_prefix@
315 host = @host@
316 host_alias = @host_alias@
317 host_cpu = @host_cpu@
318 host_os = @host_os@
319 host_vendor = @host_vendor@
320 htmldir = @htmldir@
321 includedir = @includedir@
322 infodir = @infodir@
323 install_sh = @install_sh@
324 libdir = @libdir@
325 libexecdir = @libexecdir@
326 localedir = @localedir@
327 localstatedir = @localstatedir@
328 mandir = @mandir@
329 mkdir_p = @mkdir_p@
330 oldincludedir = @oldincludedir@
331 pdfdir = @pdfdir@
332 pkgpyexecdir = @pkgpyexecdir@
333 pkgpythondir = @pkgpythondir@
334 prefix = @prefix@
335 program_transform_name = @program_transform_name@
336 psdir = @psdir@
337 pyexecdir = @pyexecdir@
338 pythondir = @pythondir@
339 runstatedir = @runstatedir@
340 sbindir = @sbindir@
341 sharedstatedir = @sharedstatedir@
342 srcdir = @srcdir@
343 sysconfdir = @sysconfdir@
344 target_alias = @target_alias@
345 top_build_prefix = @top_build_prefix@
346 top_builddir = @top_builddir@
347 top_srcdir = @top_srcdir@
348 GPG = gpg
349 GPG_AGENT = gpg-agent
350 test_srcdir = $(top_srcdir)/tests/gpg
351 GNUPGHOME = $(abs_builddir)
352 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME) \
353 LC_ALL=C GPG_AGENT_INFO= \
354 top_srcdir=$(top_srcdir) \
355 srcdir=$(srcdir) \
356 LD_LIBRARY_PATH="../../../src/.libs:$(LD_LIBRARY_PATH)"
357
358 XTESTS = initial.py $(py_tests) final.py
359 EXTRA_DIST = support.py $(XTESTS) encrypt-only.asc sign-only.asc \
360 run-tests.py
361
362 CLEANFILES = secring.gpg pubring.gpg pubring.kbx trustdb.gpg dirmngr.conf \
363 gpg-agent.conf pubring.kbx~ gpg.conf pubring.gpg~ \
364 random_seed .gpg-v21-migrated tofu.db \
365 pubring-stamp gpg-sample.stamp
366
367 private_keys = \
368 $(test_srcdir)/13CD0F3BDF24BE53FE192D62F18737256FF6E4FD \
369 $(test_srcdir)/76F7E2B35832976B50A27A282D9B87E44577EB66 \
370 $(test_srcdir)/A0747D5F9425E6664F4FFBEED20FBCA79FDED2BD \
371 $(test_srcdir)/13CBE3758AFE42B5E5E2AE4CED27AFA455E3F87F \
372 $(test_srcdir)/7A030357C0F253A5BBCD282FFC4E521B37558F5C
373
374 BUILT_SOURCES = gpg.conf gpg-agent.conf pubring-stamp \
375 gpg-sample.stamp
376
377 all: $(BUILT_SOURCES)
378 $(MAKE) $(AM_MAKEFLAGS) all-am
379
380 .SUFFIXES:
381 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
382 @for dep in $?; do \
383 case '$(am__configure_deps)' in \
384 *$$dep*) \
385 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
386 && { if test -f $@; then exit 0; else break; fi; }; \
387 exit 1;; \
388 esac; \
389 done; \
390 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/python/tests/Makefile'; \
391 $(am__cd) $(top_srcdir) && \
392 $(AUTOMAKE) --gnu lang/python/tests/Makefile
393 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
394 @case '$?' in \
395 *config.status*) \
396 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
397 *) \
398 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
399 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
400 esac;
401
402 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
403 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
404
405 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
406 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
407 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
408 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
409 $(am__aclocal_m4_deps):
410
411 mostlyclean-libtool:
412 -rm -f *.lo
413
414 clean-libtool:
415 -rm -rf .libs _libs
416 tags TAGS:
417
418 ctags CTAGS:
419
420 cscope cscopelist:
421
422
423 distdir: $(BUILT_SOURCES)
424 $(MAKE) $(AM_MAKEFLAGS) distdir-am
425
426 distdir-am: $(DISTFILES)
427 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
428 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
429 list='$(DISTFILES)'; \
430 dist_files=`for file in $$list; do echo $$file; done | \
431 sed -e "s|^$$srcdirstrip/||;t" \
432 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
433 case $$dist_files in \
434 */*) $(MKDIR_P) `echo "$$dist_files" | \
435 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
436 sort -u` ;; \
437 esac; \
438 for file in $$dist_files; do \
439 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
440 if test -d $$d/$$file; then \
441 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
442 if test -d "$(distdir)/$$file"; then \
443 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
444 fi; \
445 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
446 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
447 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
448 fi; \
449 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
450 else \
451 test -f "$(distdir)/$$file" \
452 || cp -p $$d/$$file "$(distdir)/$$file" \
453 || exit 1; \
454 fi; \
455 done
456 check-am: all-am
457 check: $(BUILT_SOURCES)
458 $(MAKE) $(AM_MAKEFLAGS) check-am
459 all-am: Makefile
460 installdirs:
461 install: $(BUILT_SOURCES)
462 $(MAKE) $(AM_MAKEFLAGS) install-am
463 install-exec: $(BUILT_SOURCES)
464 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
465 install-data: install-data-am
466 uninstall: uninstall-am
467
468 install-am: all-am
469 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
470
471 installcheck: installcheck-am
472 install-strip:
473 if test -z '$(STRIP)'; then \
474 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
475 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
476 install; \
477 else \
478 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
479 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
480 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
481 fi
482 mostlyclean-generic:
483
484 clean-generic:
485 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
486
487 distclean-generic:
488 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
489 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
490
491 maintainer-clean-generic:
492 @echo "This command is intended for maintainers to use"
493 @echo "it deletes files that may require special tools to rebuild."
494 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
495 clean: clean-am
496
497 clean-am: clean-generic clean-libtool clean-local mostlyclean-am
498
499 distclean: distclean-am
500 -rm -f Makefile
501 distclean-am: clean-am distclean-generic
502
503 dvi: dvi-am
504
505 dvi-am:
506
507 html: html-am
508
509 html-am:
510
511 info: info-am
512
513 info-am:
514
515 install-data-am:
516
517 install-dvi: install-dvi-am
518
519 install-dvi-am:
520
521 install-exec-am:
522
523 install-html: install-html-am
524
525 install-html-am:
526
527 install-info: install-info-am
528
529 install-info-am:
530
531 install-man:
532
533 install-pdf: install-pdf-am
534
535 install-pdf-am:
536
537 install-ps: install-ps-am
538
539 install-ps-am:
540
541 installcheck-am:
542
543 maintainer-clean: maintainer-clean-am
544 -rm -f Makefile
545 maintainer-clean-am: distclean-am maintainer-clean-generic
546
547 mostlyclean: mostlyclean-am
548
549 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
550
551 pdf: pdf-am
552
553 pdf-am:
554
555 ps: ps-am
556
557 ps-am:
558
559 uninstall-am:
560
561 .MAKE: all check install install-am install-exec install-strip
562
563 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
564 clean-local cscopelist-am ctags-am distclean distclean-generic \
565 distclean-libtool distdir dvi dvi-am html html-am info info-am \
566 install install-am install-data install-data-am install-dvi \
567 install-dvi-am install-exec install-exec-am install-html \
568 install-html-am install-info install-info-am install-man \
569 install-pdf install-pdf-am install-ps install-ps-am \
570 install-strip installcheck installcheck-am installdirs \
571 maintainer-clean maintainer-clean-generic mostlyclean \
572 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
573 tags-am uninstall uninstall-am
574
575 .PRECIOUS: Makefile
576
577
578 py_tests ?= t-wrapper.py \
579 t-callbacks.py \
580 t-data.py \
581 t-encrypt.py \
582 t-encrypt-sym.py \
583 t-encrypt-sign.py \
584 t-sign.py \
585 t-signers.py \
586 t-decrypt.py \
587 t-verify.py \
588 t-decrypt-verify.py \
589 t-sig-notation.py \
590 t-export.py \
591 t-import.py \
592 t-edit.py \
593 t-keylist.py \
594 t-keylist-from-data.py \
595 t-wait.py \
596 t-encrypt-large.py \
597 t-file-name.py \
598 t-idiomatic.py \
599 t-protocol-assuan.py \
600 t-quick-key-creation.py \
601 t-quick-subkey-creation.py \
602 t-quick-key-manipulation.py \
603 t-quick-key-signing.py
604
605 # XXX: Currently, one cannot override automake's 'check' target. As a
606 # workaround, we avoid defining 'TESTS', thus automake will not emit
607 # the 'check' target. For extra robustness, we merely define a
608 # dependency on 'xcheck', so this hack should also work even if
609 # automake would emit the 'check' target, as adding dependencies to
610 # targets is okay.
611 check: xcheck
612
613 .PHONY: xcheck
614
615 xcheck: all
616 $(TESTS_ENVIRONMENT) $(PYTHON) $(srcdir)/run-tests.py \
617 --interpreters="$(PYTHONS)" --srcdir=$(srcdir) $(TESTFLAGS) \
618 $(XTESTS)
619
620 clean-local:
621 -$(TESTS_ENVIRONMENT) $(top_srcdir)/tests/start-stop-agent --stop
622 -rm -fR -- private-keys-v1.d openpgp-revocs.d S.gpg-agent sshcontrol
623
624 gpg-sample.stamp: $(private_keys)
625 -$(TESTS_ENVIRONMENT) gpgconf --kill all
626 $(MKDIR_P) ./private-keys-v1.d
627 for k in $(private_keys); do \
628 cp $$k private-keys-v1.d/$${k#$(test_srcdir)/}.key; \
629 done
630 echo x > ./gpg-sample.stamp
631
632 pubring-stamp: $(test_srcdir)/pubdemo.asc gpg-sample.stamp
633 $(TESTS_ENVIRONMENT) $(GPG) --batch --no-permission-warning \
634 --import $(test_srcdir)/pubdemo.asc
635 -$(TESTS_ENVIRONMENT) $(GPG) --batch --no-permission-warning \
636 --import $(test_srcdir)/secdemo.asc
637 echo x > ./pubring-stamp
638
639 gpg.conf:
640 # This is required for t-sig-notations.
641 echo no-force-v3-sigs > ./gpg.conf
642 echo default-key A0FF4590BB6122EDEF6E3C542D727CC768697734 >> ./gpg.conf
643
644 gpg-agent.conf:
645 # This is required for gpg2, which does not support command fd.
646 echo pinentry-program $(abs_top_srcdir)/tests/gpg/pinentry >$@
647 echo disable-scdaemon >> $@
648
649 # end-of-file
650
651 # Tell versions [3.59,3.63) of GNU make to not export all variables.
652 # Otherwise a system limit (for SysV at least) may be exceeded.
653 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am for GPGMEPP.
17 # Copyright (C) 2016 Bundesamt für Sicherheit in der Informationstechnik
18 # Software engineering by Intevation GmbH
19 #
20 # This file is part of GPGMEPP.
21 #
22 # GPGME-CL is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU General Public License as published by
24 # the Free Software Foundation; either version 2 of the License, or
25 # (at your option) any later version.
26 #
27 # GPGME-CL is distributed in the hope that it will be useful,
28 # but WITHOUT ANY WARRANTY; without even the implied warranty of
29 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 # GNU Lesser General Public License for more details.
31 #
32 # You should have received a copy of the GNU Lesser General Public
33 # License along with this program; if not, see <https://gnu.org/licenses/>.
34 # SPDX-License-Identifier: LGPL-2.1-or-later
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 subdir = lang/qt
110 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
111 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
112 $(top_srcdir)/m4/ax_pkg_swig.m4 \
113 $(top_srcdir)/m4/ax_python_devel.m4 \
114 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
115 $(top_srcdir)/m4/gnupg-ttyname.m4 \
116 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
117 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
118 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
119 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
120 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
121 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
122 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
123 $(ACLOCAL_M4)
124 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
125 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
126 CONFIG_HEADER = $(top_builddir)/conf/config.h
127 CONFIG_CLEAN_FILES =
128 CONFIG_CLEAN_VPATH_FILES =
129 AM_V_P = $(am__v_P_@AM_V@)
130 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
131 am__v_P_0 = false
132 am__v_P_1 = :
133 AM_V_GEN = $(am__v_GEN_@AM_V@)
134 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
135 am__v_GEN_0 = @echo " GEN " $@;
136 am__v_GEN_1 =
137 AM_V_at = $(am__v_at_@AM_V@)
138 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
139 am__v_at_0 = @
140 am__v_at_1 =
141 SOURCES =
142 DIST_SOURCES =
143 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
144 ctags-recursive dvi-recursive html-recursive info-recursive \
145 install-data-recursive install-dvi-recursive \
146 install-exec-recursive install-html-recursive \
147 install-info-recursive install-pdf-recursive \
148 install-ps-recursive install-recursive installcheck-recursive \
149 installdirs-recursive pdf-recursive ps-recursive \
150 tags-recursive uninstall-recursive
151 am__can_run_installinfo = \
152 case $$AM_UPDATE_INFO_DIR in \
153 n|no|NO) false;; \
154 *) (install-info --version) >/dev/null 2>&1;; \
155 esac
156 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
157 distclean-recursive maintainer-clean-recursive
158 am__recursive_targets = \
159 $(RECURSIVE_TARGETS) \
160 $(RECURSIVE_CLEAN_TARGETS) \
161 $(am__extra_recursive_targets)
162 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
163 distdir distdir-am
164 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
165 # Read a list of newline-separated strings from the standard input,
166 # and print each of them once, without duplicates. Input order is
167 # *not* preserved.
168 am__uniquify_input = $(AWK) '\
169 BEGIN { nonempty = 0; } \
170 { items[$$0] = 1; nonempty = 1; } \
171 END { if (nonempty) { for (i in items) print i; }; } \
172 '
173 # Make sure the list of sources is unique. This is necessary because,
174 # e.g., the same source file might be shared among _SOURCES variables
175 # for different programs/libraries.
176 am__define_uniq_tagged_files = \
177 list='$(am__tagged_files)'; \
178 unique=`for i in $$list; do \
179 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
180 done | $(am__uniquify_input)`
181 ETAGS = etags
182 CTAGS = ctags
183 DIST_SUBDIRS = src tests doc
184 am__DIST_COMMON = $(srcdir)/Makefile.in \
185 $(top_srcdir)/build-aux/mkinstalldirs README
186 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
187 am__relativize = \
188 dir0=`pwd`; \
189 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
190 sed_rest='s,^[^/]*/*,,'; \
191 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
192 sed_butlast='s,/*[^/]*$$,,'; \
193 while test -n "$$dir1"; do \
194 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
195 if test "$$first" != "."; then \
196 if test "$$first" = ".."; then \
197 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
198 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
199 else \
200 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
201 if test "$$first2" = "$$first"; then \
202 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
203 else \
204 dir2="../$$dir2"; \
205 fi; \
206 dir0="$$dir0"/"$$first"; \
207 fi; \
208 fi; \
209 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
210 done; \
211 reldir="$$dir2"
212 ACLOCAL = @ACLOCAL@
213 AMTAR = @AMTAR@
214 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
215 AR = @AR@
216 AS = @AS@
217 AUTOCONF = @AUTOCONF@
218 AUTOHEADER = @AUTOHEADER@
219 AUTOMAKE = @AUTOMAKE@
220 AWK = @AWK@
221 BUILD_FILEVERSION = @BUILD_FILEVERSION@
222 BUILD_REVISION = @BUILD_REVISION@
223 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
224 BUILD_VERSION = @BUILD_VERSION@
225 CC = @CC@
226 CCDEPMODE = @CCDEPMODE@
227 CC_FOR_BUILD = @CC_FOR_BUILD@
228 CFLAGS = @CFLAGS@
229 CPP = @CPP@
230 CPPFLAGS = @CPPFLAGS@
231 CXX = @CXX@
232 CXXCPP = @CXXCPP@
233 CXXDEPMODE = @CXXDEPMODE@
234 CXXFLAGS = @CXXFLAGS@
235 CYGPATH_W = @CYGPATH_W@
236 DEFS = @DEFS@
237 DEPDIR = @DEPDIR@
238 DLLTOOL = @DLLTOOL@
239 DOXYGEN = @DOXYGEN@
240 DSYMUTIL = @DSYMUTIL@
241 DUMPBIN = @DUMPBIN@
242 ECHO_C = @ECHO_C@
243 ECHO_N = @ECHO_N@
244 ECHO_T = @ECHO_T@
245 EGREP = @EGREP@
246 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
247 EXEEXT = @EXEEXT@
248 FGREP = @FGREP@
249 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
250 GLIBC21 = @GLIBC21@
251 GLIB_CFLAGS = @GLIB_CFLAGS@
252 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
253 GLIB_LIBS = @GLIB_LIBS@
254 GLIB_MKENUMS = @GLIB_MKENUMS@
255 GOBJECT_QUERY = @GOBJECT_QUERY@
256 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
257 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
258 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
259 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
260 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
261 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
262 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
263 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
264 GPGME_QT_LIBS = @GPGME_QT_LIBS@
265 GPGRT_CONFIG = @GPGRT_CONFIG@
266 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
267 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
268 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
269 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
270 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
271 GRAPHVIZ = @GRAPHVIZ@
272 GREP = @GREP@
273 HAVE_CXX11 = @HAVE_CXX11@
274 HAVE_DOT = @HAVE_DOT@
275 INSTALL = @INSTALL@
276 INSTALL_DATA = @INSTALL_DATA@
277 INSTALL_PROGRAM = @INSTALL_PROGRAM@
278 INSTALL_SCRIPT = @INSTALL_SCRIPT@
279 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
280 LD = @LD@
281 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
282 LDFLAGS = @LDFLAGS@
283 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
284 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
285 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
286 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
287 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
288 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
289 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
290 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
291 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
292 LIBOBJS = @LIBOBJS@
293 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
294 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
295 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
296 LIBS = @LIBS@
297 LIBTOOL = @LIBTOOL@
298 LIPO = @LIPO@
299 LN_S = @LN_S@
300 LTLIBOBJS = @LTLIBOBJS@
301 MAINT = @MAINT@
302 MAKEINFO = @MAKEINFO@
303 MANIFEST_TOOL = @MANIFEST_TOOL@
304 MKDIR_P = @MKDIR_P@
305 MOC = @MOC@
306 MOC2 = @MOC2@
307 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
308 NM = @NM@
309 NMEDIT = @NMEDIT@
310 OBJDUMP = @OBJDUMP@
311 OBJEXT = @OBJEXT@
312 OTOOL = @OTOOL@
313 OTOOL64 = @OTOOL64@
314 PACKAGE = @PACKAGE@
315 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
316 PACKAGE_NAME = @PACKAGE_NAME@
317 PACKAGE_STRING = @PACKAGE_STRING@
318 PACKAGE_TARNAME = @PACKAGE_TARNAME@
319 PACKAGE_URL = @PACKAGE_URL@
320 PACKAGE_VERSION = @PACKAGE_VERSION@
321 PATH_SEPARATOR = @PATH_SEPARATOR@
322 PKG_CONFIG = @PKG_CONFIG@
323 PYTHON = @PYTHON@
324 PYTHONS = @PYTHONS@
325 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
326 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
327 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
328 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
329 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
330 PYTHON_PLATFORM = @PYTHON_PLATFORM@
331 PYTHON_PREFIX = @PYTHON_PREFIX@
332 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
333 PYTHON_VERSION = @PYTHON_VERSION@
334 QTCHOOSER = @QTCHOOSER@
335 RANLIB = @RANLIB@
336 RC = @RC@
337 SED = @SED@
338 SET_MAKE = @SET_MAKE@
339 SHELL = @SHELL@
340 STRIP = @STRIP@
341 SWIG = @SWIG@
342 SWIG_LIB = @SWIG_LIB@
343 SYSROOT = @SYSROOT@
344 VERSION = @VERSION@
345 VERSION_MAJOR = @VERSION_MAJOR@
346 VERSION_MICRO = @VERSION_MICRO@
347 VERSION_MINOR = @VERSION_MINOR@
348 VERSION_NUMBER = @VERSION_NUMBER@
349 abs_builddir = @abs_builddir@
350 abs_srcdir = @abs_srcdir@
351 abs_top_builddir = @abs_top_builddir@
352 abs_top_srcdir = @abs_top_srcdir@
353 ac_ct_AR = @ac_ct_AR@
354 ac_ct_CC = @ac_ct_CC@
355 ac_ct_CXX = @ac_ct_CXX@
356 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
357 am__include = @am__include@
358 am__leading_dot = @am__leading_dot@
359 am__quote = @am__quote@
360 am__tar = @am__tar@
361 am__untar = @am__untar@
362 bindir = @bindir@
363 build = @build@
364 build_alias = @build_alias@
365 build_cpu = @build_cpu@
366 build_os = @build_os@
367 build_vendor = @build_vendor@
368 builddir = @builddir@
369 datadir = @datadir@
370 datarootdir = @datarootdir@
371 docdir = @docdir@
372 dvidir = @dvidir@
373 emacs_local_vars_begin = @emacs_local_vars_begin@
374 emacs_local_vars_end = @emacs_local_vars_end@
375 emacs_local_vars_read_only = @emacs_local_vars_read_only@
376 exec_prefix = @exec_prefix@
377 host = @host@
378 host_alias = @host_alias@
379 host_cpu = @host_cpu@
380 host_os = @host_os@
381 host_vendor = @host_vendor@
382 htmldir = @htmldir@
383 includedir = @includedir@
384 infodir = @infodir@
385 install_sh = @install_sh@
386 libdir = @libdir@
387 libexecdir = @libexecdir@
388 localedir = @localedir@
389 localstatedir = @localstatedir@
390 mandir = @mandir@
391 mkdir_p = @mkdir_p@
392 oldincludedir = @oldincludedir@
393 pdfdir = @pdfdir@
394 pkgpyexecdir = @pkgpyexecdir@
395 pkgpythondir = @pkgpythondir@
396 prefix = @prefix@
397 program_transform_name = @program_transform_name@
398 psdir = @psdir@
399 pyexecdir = @pyexecdir@
400 pythondir = @pythondir@
401 runstatedir = @runstatedir@
402 sbindir = @sbindir@
403 sharedstatedir = @sharedstatedir@
404 srcdir = @srcdir@
405 sysconfdir = @sysconfdir@
406 target_alias = @target_alias@
407 top_build_prefix = @top_build_prefix@
408 top_builddir = @top_builddir@
409 top_srcdir = @top_srcdir@
410 @RUN_GPG_TESTS_FALSE@tests =
411 @RUN_GPG_TESTS_TRUE@tests = tests
412 SUBDIRS = src ${tests} doc
413 EXTRA_DIST = README
414 all: all-recursive
415
416 .SUFFIXES:
417 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
418 @for dep in $?; do \
419 case '$(am__configure_deps)' in \
420 *$$dep*) \
421 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
422 && { if test -f $@; then exit 0; else break; fi; }; \
423 exit 1;; \
424 esac; \
425 done; \
426 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/qt/Makefile'; \
427 $(am__cd) $(top_srcdir) && \
428 $(AUTOMAKE) --gnu lang/qt/Makefile
429 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
430 @case '$?' in \
431 *config.status*) \
432 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
433 *) \
434 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
435 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
436 esac;
437
438 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
439 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
440
441 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
442 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
443 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
444 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
445 $(am__aclocal_m4_deps):
446
447 mostlyclean-libtool:
448 -rm -f *.lo
449
450 clean-libtool:
451 -rm -rf .libs _libs
452
453 # This directory's subdirectories are mostly independent; you can cd
454 # into them and run 'make' without going through this Makefile.
455 # To change the values of 'make' variables: instead of editing Makefiles,
456 # (1) if the variable is set in 'config.status', edit 'config.status'
457 # (which will cause the Makefiles to be regenerated when you run 'make');
458 # (2) otherwise, pass the desired values on the 'make' command line.
459 $(am__recursive_targets):
460 @fail=; \
461 if $(am__make_keepgoing); then \
462 failcom='fail=yes'; \
463 else \
464 failcom='exit 1'; \
465 fi; \
466 dot_seen=no; \
467 target=`echo $@ | sed s/-recursive//`; \
468 case "$@" in \
469 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
470 *) list='$(SUBDIRS)' ;; \
471 esac; \
472 for subdir in $$list; do \
473 echo "Making $$target in $$subdir"; \
474 if test "$$subdir" = "."; then \
475 dot_seen=yes; \
476 local_target="$$target-am"; \
477 else \
478 local_target="$$target"; \
479 fi; \
480 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
481 || eval $$failcom; \
482 done; \
483 if test "$$dot_seen" = "no"; then \
484 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
485 fi; test -z "$$fail"
486
487 ID: $(am__tagged_files)
488 $(am__define_uniq_tagged_files); mkid -fID $$unique
489 tags: tags-recursive
490 TAGS: tags
491
492 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
493 set x; \
494 here=`pwd`; \
495 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
496 include_option=--etags-include; \
497 empty_fix=.; \
498 else \
499 include_option=--include; \
500 empty_fix=; \
501 fi; \
502 list='$(SUBDIRS)'; for subdir in $$list; do \
503 if test "$$subdir" = .; then :; else \
504 test ! -f $$subdir/TAGS || \
505 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
506 fi; \
507 done; \
508 $(am__define_uniq_tagged_files); \
509 shift; \
510 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
511 test -n "$$unique" || unique=$$empty_fix; \
512 if test $$# -gt 0; then \
513 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
514 "$$@" $$unique; \
515 else \
516 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
517 $$unique; \
518 fi; \
519 fi
520 ctags: ctags-recursive
521
522 CTAGS: ctags
523 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
524 $(am__define_uniq_tagged_files); \
525 test -z "$(CTAGS_ARGS)$$unique" \
526 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
527 $$unique
528
529 GTAGS:
530 here=`$(am__cd) $(top_builddir) && pwd` \
531 && $(am__cd) $(top_srcdir) \
532 && gtags -i $(GTAGS_ARGS) "$$here"
533 cscopelist: cscopelist-recursive
534
535 cscopelist-am: $(am__tagged_files)
536 list='$(am__tagged_files)'; \
537 case "$(srcdir)" in \
538 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
539 *) sdir=$(subdir)/$(srcdir) ;; \
540 esac; \
541 for i in $$list; do \
542 if test -f "$$i"; then \
543 echo "$(subdir)/$$i"; \
544 else \
545 echo "$$sdir/$$i"; \
546 fi; \
547 done >> $(top_builddir)/cscope.files
548
549 distclean-tags:
550 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
551
552 distdir: $(BUILT_SOURCES)
553 $(MAKE) $(AM_MAKEFLAGS) distdir-am
554
555 distdir-am: $(DISTFILES)
556 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
557 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
558 list='$(DISTFILES)'; \
559 dist_files=`for file in $$list; do echo $$file; done | \
560 sed -e "s|^$$srcdirstrip/||;t" \
561 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
562 case $$dist_files in \
563 */*) $(MKDIR_P) `echo "$$dist_files" | \
564 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
565 sort -u` ;; \
566 esac; \
567 for file in $$dist_files; do \
568 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
569 if test -d $$d/$$file; then \
570 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
571 if test -d "$(distdir)/$$file"; then \
572 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
573 fi; \
574 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
575 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
576 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
577 fi; \
578 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
579 else \
580 test -f "$(distdir)/$$file" \
581 || cp -p $$d/$$file "$(distdir)/$$file" \
582 || exit 1; \
583 fi; \
584 done
585 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
586 if test "$$subdir" = .; then :; else \
587 $(am__make_dryrun) \
588 || test -d "$(distdir)/$$subdir" \
589 || $(MKDIR_P) "$(distdir)/$$subdir" \
590 || exit 1; \
591 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
592 $(am__relativize); \
593 new_distdir=$$reldir; \
594 dir1=$$subdir; dir2="$(top_distdir)"; \
595 $(am__relativize); \
596 new_top_distdir=$$reldir; \
597 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
598 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
599 ($(am__cd) $$subdir && \
600 $(MAKE) $(AM_MAKEFLAGS) \
601 top_distdir="$$new_top_distdir" \
602 distdir="$$new_distdir" \
603 am__remove_distdir=: \
604 am__skip_length_check=: \
605 am__skip_mode_fix=: \
606 distdir) \
607 || exit 1; \
608 fi; \
609 done
610 check-am: all-am
611 check: check-recursive
612 all-am: Makefile
613 installdirs: installdirs-recursive
614 installdirs-am:
615 install: install-recursive
616 install-exec: install-exec-recursive
617 install-data: install-data-recursive
618 uninstall: uninstall-recursive
619
620 install-am: all-am
621 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
622
623 installcheck: installcheck-recursive
624 install-strip:
625 if test -z '$(STRIP)'; then \
626 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
627 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
628 install; \
629 else \
630 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
631 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
632 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
633 fi
634 mostlyclean-generic:
635
636 clean-generic:
637
638 distclean-generic:
639 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
640 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
641
642 maintainer-clean-generic:
643 @echo "This command is intended for maintainers to use"
644 @echo "it deletes files that may require special tools to rebuild."
645 clean: clean-recursive
646
647 clean-am: clean-generic clean-libtool mostlyclean-am
648
649 distclean: distclean-recursive
650 -rm -f Makefile
651 distclean-am: clean-am distclean-generic distclean-tags
652
653 dvi: dvi-recursive
654
655 dvi-am:
656
657 html: html-recursive
658
659 html-am:
660
661 info: info-recursive
662
663 info-am:
664
665 install-data-am:
666
667 install-dvi: install-dvi-recursive
668
669 install-dvi-am:
670
671 install-exec-am:
672
673 install-html: install-html-recursive
674
675 install-html-am:
676
677 install-info: install-info-recursive
678
679 install-info-am:
680
681 install-man:
682
683 install-pdf: install-pdf-recursive
684
685 install-pdf-am:
686
687 install-ps: install-ps-recursive
688
689 install-ps-am:
690
691 installcheck-am:
692
693 maintainer-clean: maintainer-clean-recursive
694 -rm -f Makefile
695 maintainer-clean-am: distclean-am maintainer-clean-generic
696
697 mostlyclean: mostlyclean-recursive
698
699 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
700
701 pdf: pdf-recursive
702
703 pdf-am:
704
705 ps: ps-recursive
706
707 ps-am:
708
709 uninstall-am:
710
711 .MAKE: $(am__recursive_targets) install-am install-strip
712
713 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
714 check-am clean clean-generic clean-libtool cscopelist-am ctags \
715 ctags-am distclean distclean-generic distclean-libtool \
716 distclean-tags distdir dvi dvi-am html html-am info info-am \
717 install install-am install-data install-data-am install-dvi \
718 install-dvi-am install-exec install-exec-am install-html \
719 install-html-am install-info install-info-am install-man \
720 install-pdf install-pdf-am install-ps install-ps-am \
721 install-strip installcheck installcheck-am installdirs \
722 installdirs-am maintainer-clean maintainer-clean-generic \
723 mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
724 ps ps-am tags tags-am uninstall uninstall-am
725
726 .PRECIOUS: Makefile
727
728
729 # Tell versions [3.59,3.63) of GNU make to not export all variables.
730 # Otherwise a system limit (for SysV at least) may be exceeded.
731 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am - Makefile for GPGME Qt docs.
17 # Copyright (C) 2016 Bundesamt für Sicherheit in der Informationstechnik
18 # Software engineering by Intevation GmbH
19 #
20 # This file is part of GPGME.
21 #
22 # GPGME is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU Lesser General Public License as
24 # published by the Free Software Foundation; either version 2.1 of the
25 # License, or (at your option) any later version.
26 #
27 # GPGME is distributed in the hope that it will be useful, but WITHOUT
28 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
29 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
30 # Public License for more details.
31 #
32 # You should have received a copy of the GNU Lesser General Public
33 # License along with this program; if not, see <https://www.gnu.org/licenses/>.
34 VPATH = @srcdir@
35 am__is_gnu_make = { \
36 if test -z '$(MAKELEVEL)'; then \
37 false; \
38 elif test -n '$(MAKE_HOST)'; then \
39 true; \
40 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
41 true; \
42 else \
43 false; \
44 fi; \
45 }
46 am__make_running_with_option = \
47 case $${target_option-} in \
48 ?) ;; \
49 *) echo "am__make_running_with_option: internal error: invalid" \
50 "target option '$${target_option-}' specified" >&2; \
51 exit 1;; \
52 esac; \
53 has_opt=no; \
54 sane_makeflags=$$MAKEFLAGS; \
55 if $(am__is_gnu_make); then \
56 sane_makeflags=$$MFLAGS; \
57 else \
58 case $$MAKEFLAGS in \
59 *\\[\ \ ]*) \
60 bs=\\; \
61 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
62 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
63 esac; \
64 fi; \
65 skip_next=no; \
66 strip_trailopt () \
67 { \
68 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
69 }; \
70 for flg in $$sane_makeflags; do \
71 test $$skip_next = yes && { skip_next=no; continue; }; \
72 case $$flg in \
73 *=*|--*) continue;; \
74 -*I) strip_trailopt 'I'; skip_next=yes;; \
75 -*I?*) strip_trailopt 'I';; \
76 -*O) strip_trailopt 'O'; skip_next=yes;; \
77 -*O?*) strip_trailopt 'O';; \
78 -*l) strip_trailopt 'l'; skip_next=yes;; \
79 -*l?*) strip_trailopt 'l';; \
80 -[dEDm]) skip_next=yes;; \
81 -[JT]) skip_next=yes;; \
82 esac; \
83 case $$flg in \
84 *$$target_option*) has_opt=yes; break;; \
85 esac; \
86 done; \
87 test $$has_opt = yes
88 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
89 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
90 pkgdatadir = $(datadir)/@PACKAGE@
91 pkgincludedir = $(includedir)/@PACKAGE@
92 pkglibdir = $(libdir)/@PACKAGE@
93 pkglibexecdir = $(libexecdir)/@PACKAGE@
94 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
95 install_sh_DATA = $(install_sh) -c -m 644
96 install_sh_PROGRAM = $(install_sh) -c
97 install_sh_SCRIPT = $(install_sh) -c
98 INSTALL_HEADER = $(INSTALL_DATA)
99 transform = $(program_transform_name)
100 NORMAL_INSTALL = :
101 PRE_INSTALL = :
102 POST_INSTALL = :
103 NORMAL_UNINSTALL = :
104 PRE_UNINSTALL = :
105 POST_UNINSTALL = :
106 build_triplet = @build@
107 host_triplet = @host@
108 subdir = lang/qt/doc
109 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
110 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
111 $(top_srcdir)/m4/ax_pkg_swig.m4 \
112 $(top_srcdir)/m4/ax_python_devel.m4 \
113 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
114 $(top_srcdir)/m4/gnupg-ttyname.m4 \
115 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
116 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
117 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
118 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
119 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
120 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
121 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
122 $(ACLOCAL_M4)
123 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
124 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
125 CONFIG_HEADER = $(top_builddir)/conf/config.h
126 CONFIG_CLEAN_FILES = Doxyfile
127 CONFIG_CLEAN_VPATH_FILES =
128 AM_V_P = $(am__v_P_@AM_V@)
129 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
130 am__v_P_0 = false
131 am__v_P_1 = :
132 AM_V_GEN = $(am__v_GEN_@AM_V@)
133 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
134 am__v_GEN_0 = @echo " GEN " $@;
135 am__v_GEN_1 =
136 AM_V_at = $(am__v_at_@AM_V@)
137 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
138 am__v_at_0 = @
139 am__v_at_1 =
140 SOURCES =
141 DIST_SOURCES =
142 am__can_run_installinfo = \
143 case $$AM_UPDATE_INFO_DIR in \
144 n|no|NO) false;; \
145 *) (install-info --version) >/dev/null 2>&1;; \
146 esac
147 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
148 am__DIST_COMMON = $(srcdir)/Doxyfile.in $(srcdir)/Makefile.in \
149 $(top_srcdir)/build-aux/mkinstalldirs
150 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
151 ACLOCAL = @ACLOCAL@
152 AMTAR = @AMTAR@
153 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
154 AR = @AR@
155 AS = @AS@
156 AUTOCONF = @AUTOCONF@
157 AUTOHEADER = @AUTOHEADER@
158 AUTOMAKE = @AUTOMAKE@
159 AWK = @AWK@
160 BUILD_FILEVERSION = @BUILD_FILEVERSION@
161 BUILD_REVISION = @BUILD_REVISION@
162 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
163 BUILD_VERSION = @BUILD_VERSION@
164 CC = @CC@
165 CCDEPMODE = @CCDEPMODE@
166 CC_FOR_BUILD = @CC_FOR_BUILD@
167 CFLAGS = @CFLAGS@
168 CPP = @CPP@
169 CPPFLAGS = @CPPFLAGS@
170 CXX = @CXX@
171 CXXCPP = @CXXCPP@
172 CXXDEPMODE = @CXXDEPMODE@
173 CXXFLAGS = @CXXFLAGS@
174 CYGPATH_W = @CYGPATH_W@
175 DEFS = @DEFS@
176 DEPDIR = @DEPDIR@
177 DLLTOOL = @DLLTOOL@
178 DOXYGEN = @DOXYGEN@
179 DSYMUTIL = @DSYMUTIL@
180 DUMPBIN = @DUMPBIN@
181 ECHO_C = @ECHO_C@
182 ECHO_N = @ECHO_N@
183 ECHO_T = @ECHO_T@
184 EGREP = @EGREP@
185 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
186 EXEEXT = @EXEEXT@
187 FGREP = @FGREP@
188 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
189 GLIBC21 = @GLIBC21@
190 GLIB_CFLAGS = @GLIB_CFLAGS@
191 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
192 GLIB_LIBS = @GLIB_LIBS@
193 GLIB_MKENUMS = @GLIB_MKENUMS@
194 GOBJECT_QUERY = @GOBJECT_QUERY@
195 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
196 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
197 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
198 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
199 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
200 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
201 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
202 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
203 GPGME_QT_LIBS = @GPGME_QT_LIBS@
204 GPGRT_CONFIG = @GPGRT_CONFIG@
205 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
206 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
207 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
208 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
209 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
210 GRAPHVIZ = @GRAPHVIZ@
211 GREP = @GREP@
212 HAVE_CXX11 = @HAVE_CXX11@
213 HAVE_DOT = @HAVE_DOT@
214 INSTALL = @INSTALL@
215 INSTALL_DATA = @INSTALL_DATA@
216 INSTALL_PROGRAM = @INSTALL_PROGRAM@
217 INSTALL_SCRIPT = @INSTALL_SCRIPT@
218 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
219 LD = @LD@
220 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
221 LDFLAGS = @LDFLAGS@
222 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
223 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
224 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
225 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
226 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
227 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
228 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
229 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
230 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
231 LIBOBJS = @LIBOBJS@
232 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
233 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
234 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
235 LIBS = @LIBS@
236 LIBTOOL = @LIBTOOL@
237 LIPO = @LIPO@
238 LN_S = @LN_S@
239 LTLIBOBJS = @LTLIBOBJS@
240 MAINT = @MAINT@
241 MAKEINFO = @MAKEINFO@
242 MANIFEST_TOOL = @MANIFEST_TOOL@
243 MKDIR_P = @MKDIR_P@
244 MOC = @MOC@
245 MOC2 = @MOC2@
246 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
247 NM = @NM@
248 NMEDIT = @NMEDIT@
249 OBJDUMP = @OBJDUMP@
250 OBJEXT = @OBJEXT@
251 OTOOL = @OTOOL@
252 OTOOL64 = @OTOOL64@
253 PACKAGE = @PACKAGE@
254 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
255 PACKAGE_NAME = @PACKAGE_NAME@
256 PACKAGE_STRING = @PACKAGE_STRING@
257 PACKAGE_TARNAME = @PACKAGE_TARNAME@
258 PACKAGE_URL = @PACKAGE_URL@
259 PACKAGE_VERSION = @PACKAGE_VERSION@
260 PATH_SEPARATOR = @PATH_SEPARATOR@
261 PKG_CONFIG = @PKG_CONFIG@
262 PYTHON = @PYTHON@
263 PYTHONS = @PYTHONS@
264 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
265 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
266 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
267 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
268 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
269 PYTHON_PLATFORM = @PYTHON_PLATFORM@
270 PYTHON_PREFIX = @PYTHON_PREFIX@
271 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
272 PYTHON_VERSION = @PYTHON_VERSION@
273 QTCHOOSER = @QTCHOOSER@
274 RANLIB = @RANLIB@
275 RC = @RC@
276 SED = @SED@
277 SET_MAKE = @SET_MAKE@
278 SHELL = @SHELL@
279 STRIP = @STRIP@
280 SWIG = @SWIG@
281 SWIG_LIB = @SWIG_LIB@
282 SYSROOT = @SYSROOT@
283 VERSION = @VERSION@
284 VERSION_MAJOR = @VERSION_MAJOR@
285 VERSION_MICRO = @VERSION_MICRO@
286 VERSION_MINOR = @VERSION_MINOR@
287 VERSION_NUMBER = @VERSION_NUMBER@
288 abs_builddir = @abs_builddir@
289 abs_srcdir = @abs_srcdir@
290 abs_top_builddir = @abs_top_builddir@
291 abs_top_srcdir = @abs_top_srcdir@
292 ac_ct_AR = @ac_ct_AR@
293 ac_ct_CC = @ac_ct_CC@
294 ac_ct_CXX = @ac_ct_CXX@
295 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
296 am__include = @am__include@
297 am__leading_dot = @am__leading_dot@
298 am__quote = @am__quote@
299 am__tar = @am__tar@
300 am__untar = @am__untar@
301 bindir = @bindir@
302 build = @build@
303 build_alias = @build_alias@
304 build_cpu = @build_cpu@
305 build_os = @build_os@
306 build_vendor = @build_vendor@
307 builddir = @builddir@
308 datadir = @datadir@
309 datarootdir = @datarootdir@
310 docdir = @docdir@
311 dvidir = @dvidir@
312 emacs_local_vars_begin = @emacs_local_vars_begin@
313 emacs_local_vars_end = @emacs_local_vars_end@
314 emacs_local_vars_read_only = @emacs_local_vars_read_only@
315 exec_prefix = @exec_prefix@
316 host = @host@
317 host_alias = @host_alias@
318 host_cpu = @host_cpu@
319 host_os = @host_os@
320 host_vendor = @host_vendor@
321 htmldir = @htmldir@
322 includedir = @includedir@
323 infodir = @infodir@
324 install_sh = @install_sh@
325 libdir = @libdir@
326 libexecdir = @libexecdir@
327 localedir = @localedir@
328 localstatedir = @localstatedir@
329 mandir = @mandir@
330 mkdir_p = @mkdir_p@
331 oldincludedir = @oldincludedir@
332 pdfdir = @pdfdir@
333 pkgpyexecdir = @pkgpyexecdir@
334 pkgpythondir = @pkgpythondir@
335 prefix = @prefix@
336 program_transform_name = @program_transform_name@
337 psdir = @psdir@
338 pyexecdir = @pyexecdir@
339 pythondir = @pythondir@
340 runstatedir = @runstatedir@
341 sbindir = @sbindir@
342 sharedstatedir = @sharedstatedir@
343 srcdir = @srcdir@
344 sysconfdir = @sysconfdir@
345 target_alias = @target_alias@
346 top_build_prefix = @top_build_prefix@
347 top_builddir = @top_builddir@
348 top_srcdir = @top_srcdir@
349 @HAVE_DOXYGEN_TRUE@CLEANFILES = doxyfile.stamp
350 all: all-am
351
352 .SUFFIXES:
353 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
354 @for dep in $?; do \
355 case '$(am__configure_deps)' in \
356 *$$dep*) \
357 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
358 && { if test -f $@; then exit 0; else break; fi; }; \
359 exit 1;; \
360 esac; \
361 done; \
362 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/qt/doc/Makefile'; \
363 $(am__cd) $(top_srcdir) && \
364 $(AUTOMAKE) --gnu lang/qt/doc/Makefile
365 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
366 @case '$?' in \
367 *config.status*) \
368 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
369 *) \
370 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
371 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
372 esac;
373
374 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
375 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
376
377 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
378 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
379 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
380 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
381 $(am__aclocal_m4_deps):
382 @HAVE_DOXYGEN_TRUE@Doxyfile: $(top_builddir)/config.status $(srcdir)/Doxyfile.in
383 @HAVE_DOXYGEN_TRUE@ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
384
385 mostlyclean-libtool:
386 -rm -f *.lo
387
388 clean-libtool:
389 -rm -rf .libs _libs
390 tags TAGS:
391
392 ctags CTAGS:
393
394 cscope cscopelist:
395
396
397 distdir: $(BUILT_SOURCES)
398 $(MAKE) $(AM_MAKEFLAGS) distdir-am
399
400 distdir-am: $(DISTFILES)
401 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
402 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
403 list='$(DISTFILES)'; \
404 dist_files=`for file in $$list; do echo $$file; done | \
405 sed -e "s|^$$srcdirstrip/||;t" \
406 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
407 case $$dist_files in \
408 */*) $(MKDIR_P) `echo "$$dist_files" | \
409 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
410 sort -u` ;; \
411 esac; \
412 for file in $$dist_files; do \
413 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
414 if test -d $$d/$$file; then \
415 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
416 if test -d "$(distdir)/$$file"; then \
417 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
418 fi; \
419 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
420 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
421 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
422 fi; \
423 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
424 else \
425 test -f "$(distdir)/$$file" \
426 || cp -p $$d/$$file "$(distdir)/$$file" \
427 || exit 1; \
428 fi; \
429 done
430 check-am: all-am
431 check: check-am
432 @HAVE_DOXYGEN_FALSE@all-local:
433 all-am: Makefile all-local
434 installdirs:
435 install: install-am
436 install-exec: install-exec-am
437 install-data: install-data-am
438 uninstall: uninstall-am
439
440 install-am: all-am
441 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
442
443 installcheck: installcheck-am
444 install-strip:
445 if test -z '$(STRIP)'; then \
446 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
447 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
448 install; \
449 else \
450 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
451 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
452 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
453 fi
454 mostlyclean-generic:
455
456 clean-generic:
457 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
458
459 distclean-generic:
460 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
461 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
462
463 maintainer-clean-generic:
464 @echo "This command is intended for maintainers to use"
465 @echo "it deletes files that may require special tools to rebuild."
466 @HAVE_DOXYGEN_FALSE@clean-local:
467 clean: clean-am
468
469 clean-am: clean-generic clean-libtool clean-local mostlyclean-am
470
471 distclean: distclean-am
472 -rm -f Makefile
473 distclean-am: clean-am distclean-generic
474
475 dvi: dvi-am
476
477 dvi-am:
478
479 html: html-am
480
481 html-am:
482
483 info: info-am
484
485 info-am:
486
487 install-data-am:
488
489 install-dvi: install-dvi-am
490
491 install-dvi-am:
492
493 install-exec-am:
494
495 install-html: install-html-am
496
497 install-html-am:
498
499 install-info: install-info-am
500
501 install-info-am:
502
503 install-man:
504
505 install-pdf: install-pdf-am
506
507 install-pdf-am:
508
509 install-ps: install-ps-am
510
511 install-ps-am:
512
513 installcheck-am:
514
515 maintainer-clean: maintainer-clean-am
516 -rm -f Makefile
517 maintainer-clean-am: distclean-am maintainer-clean-generic
518
519 mostlyclean: mostlyclean-am
520
521 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
522
523 pdf: pdf-am
524
525 pdf-am:
526
527 ps: ps-am
528
529 ps-am:
530
531 uninstall-am:
532
533 .MAKE: install-am install-strip
534
535 .PHONY: all all-am all-local check check-am clean clean-generic \
536 clean-libtool clean-local cscopelist-am ctags-am distclean \
537 distclean-generic distclean-libtool distdir dvi dvi-am html \
538 html-am info info-am install install-am install-data \
539 install-data-am install-dvi install-dvi-am install-exec \
540 install-exec-am install-html install-html-am install-info \
541 install-info-am install-man install-pdf install-pdf-am \
542 install-ps install-ps-am install-strip installcheck \
543 installcheck-am installdirs maintainer-clean \
544 maintainer-clean-generic mostlyclean mostlyclean-generic \
545 mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \
546 uninstall-am
547
548 .PRECIOUS: Makefile
549
550
551 @HAVE_DOXYGEN_TRUE@doxyfile.stamp:
552 @HAVE_DOXYGEN_TRUE@ $(DOXYGEN) Doxyfile
553 @HAVE_DOXYGEN_TRUE@ touch doxyfile.stamp
554
555 @HAVE_DOXYGEN_TRUE@all-local: doxyfile.stamp
556 @HAVE_DOXYGEN_TRUE@clean-local:
557 @HAVE_DOXYGEN_TRUE@ rm -rf $(abs_builddir)/generated
558
559 # Tell versions [3.59,3.63) of GNU make to not export all variables.
560 # Otherwise a system limit (for SysV at least) may be exceeded.
561 .NOEXPORT:
0 #include "qgpgme/abstractimportjob.h"
0 #include "qgpgme/addexistingsubkeyjob.h"
0 #include "qgpgme/adduseridjob.h"
0 #include "qgpgme/changeexpiryjob.h"
0 #include "qgpgme/changeownertrustjob.h"
0 #include "qgpgme/changepasswdjob.h"
0 #include "qgpgme/cryptoconfig.h"
0 #include "qgpgme/dn.h"
0 #include "qgpgme/dataprovider.h"
0 #include "qgpgme/decryptjob.h"
0 #include "qgpgme/decryptverifyjob.h"
0 #include "qgpgme/defaultkeygenerationjob.h"
0 #include "qgpgme/deletejob.h"
0 #include "qgpgme/downloadjob.h"
0 #include "qgpgme/encryptjob.h"
0 #include "qgpgme/exportjob.h"
0 #include "qgpgme/gpgcardjob.h"
0 #include "qgpgme/hierarchicalkeykistjob.h"
0 #include "qgpgme/importfromkeyserverjob.h"
0 #include "qgpgme/importjob.h"
0 #include "qgpgme/job.h"
0 #include "qgpgme/keyformailboxjob.h"
0 #include "qgpgme/keygenerationjob.h"
0 #include "qgpgme/keylistjob.h"
0 #include "qgpgme/listallkeysjob.h"
2626 dataprovider.cpp \
2727 debug.cpp \
2828 job.cpp multideletejob.cpp qgpgmeadduseridjob.cpp \
29 qgpgmeaddexistingsubkeyjob.cpp \
2930 qgpgmebackend.cpp qgpgmechangeexpiryjob.cpp qgpgmechangeownertrustjob.cpp \
3031 qgpgmechangepasswdjob.cpp qgpgmedecryptjob.cpp \
3132 qgpgmedecryptverifyjob.cpp qgpgmedeletejob.cpp qgpgmedownloadjob.cpp \
3233 qgpgmeencryptjob.cpp qgpgmeexportjob.cpp qgpgmeimportfromkeyserverjob.cpp \
3334 qgpgmeimportjob.cpp qgpgmekeygenerationjob.cpp qgpgmekeylistjob.cpp \
3435 qgpgmelistallkeysjob.cpp qgpgmenewcryptoconfig.cpp \
36 qgpgmereceivekeysjob.cpp \
3537 qgpgmerefreshkeysjob.cpp \
36 qgpgmesecretkeyexportjob.cpp qgpgmesignencryptjob.cpp \
38 qgpgmesignencryptjob.cpp \
3739 qgpgmesignjob.cpp qgpgmesignkeyjob.cpp qgpgmeverifydetachedjob.cpp \
38 qgpgmeverifyopaquejob.cpp threadedjobmixin.cpp \
40 qgpgmeverifyopaquejob.cpp qgpgmewkdlookupjob.cpp threadedjobmixin.cpp \
3941 qgpgmekeyformailboxjob.cpp qgpgme_debug.cpp \
4042 qgpgmetofupolicyjob.cpp qgpgmequickjob.cpp \
4143 defaultkeygenerationjob.cpp qgpgmewkspublishjob.cpp \
42 qgpgmegpgcardjob.cpp \
43 dn.cpp cryptoconfig.cpp
44 qgpgmegpgcardjob.cpp changeexpiryjob.cpp importjob.cpp \
45 dn.cpp cryptoconfig.cpp wkdlookupresult.cpp \
46 util.cpp
4447
4548 # If you add one here make sure that you also add one in camelcase
4649 qgpgme_headers= \
4750 abstractimportjob.h \
51 addexistingsubkeyjob.h \
4852 adduseridjob.h \
4953 changeexpiryjob.h \
5054 changeownertrustjob.h \
6468 qgpgme_export.h \
6569 qgpgmenewcryptoconfig.h \
6670 quickjob.h \
71 receivekeysjob.h \
6772 specialjob.h \
6873 signjob.h \
6974 signkeyjob.h \
8085 verifydetachedjob.h \
8186 defaultkeygenerationjob.h \
8287 tofupolicyjob.h \
88 wkdlookupjob.h \
89 wkdlookupresult.h \
8390 wkspublishjob.h \
8491 gpgcardjob.h \
8592 dn.h
8693
8794 camelcase_headers= \
95 AddExistingSubkeyJob \
8896 AddUserIDJob \
8997 AbstractImportJob \
9098 ChangeExpiryJob \
104112 Protocol \
105113 QGpgMENewCryptoConfig \
106114 QuickJob \
115 ReceiveKeysJob \
107116 SpecialJob \
108117 SignJob \
109118 SignKeyJob \
120129 VerifyDetachedJob \
121130 KeyForMailboxJob \
122131 DefaultKeyGenerationJob \
132 WKDLookupJob \
133 WKDLookupResult \
123134 WKSPublishJob \
124135 TofuPolicyJob \
125136 GpgCardJob
127138 private_qgpgme_headers = \
128139 qgpgme_export.h \
129140 protocol_p.h \
141 job_p.h \
142 qgpgmeaddexistingsubkeyjob.h \
130143 qgpgmeadduseridjob.h \
131144 qgpgmebackend.h \
132145 qgpgmechangeexpiryjob.h \
143156 qgpgmekeygenerationjob.h \
144157 qgpgmekeylistjob.h \
145158 qgpgmelistallkeysjob.h \
159 qgpgmereceivekeysjob.h \
146160 qgpgmerefreshkeysjob.h \
147 qgpgmesecretkeyexportjob.h \
148161 qgpgmesignencryptjob.h \
149162 qgpgmesignjob.h \
150163 qgpgmesignkeyjob.h \
151164 qgpgmeverifydetachedjob.h \
152165 qgpgmeverifyopaquejob.h \
166 qgpgmewkdlookupjob.h \
153167 qgpgmekeyformailboxjob.h \
154168 qgpgmewkspublishjob.h \
155169 qgpgmetofupolicyjob.h \
156170 qgpgmegpgcardjob.h \
157171 qgpgmequickjob.h \
158 threadedjobmixin.h
172 threadedjobmixin.h \
173 util.h
159174
160175 qgpgme_moc_sources = \
161176 abstractimportjob.moc \
177 addexistingsubkeyjob.moc \
162178 adduseridjob.moc \
163179 changeexpiryjob.moc \
164180 changeownertrustjob.moc \
177193 keylistjob.moc \
178194 listallkeysjob.moc \
179195 multideletejob.moc \
196 qgpgmeaddexistingsubkeyjob.moc \
180197 qgpgmeadduseridjob.moc \
181198 qgpgmechangeexpiryjob.moc \
182199 qgpgmechangeownertrustjob.moc \
192209 qgpgmekeygenerationjob.moc \
193210 qgpgmekeylistjob.moc \
194211 qgpgmelistallkeysjob.moc \
212 qgpgmereceivekeysjob.moc \
195213 qgpgmerefreshkeysjob.moc \
196 qgpgmesecretkeyexportjob.moc \
197214 qgpgmesignencryptjob.moc \
198215 qgpgmesignjob.moc \
199216 qgpgmesignkeyjob.moc \
200217 qgpgmeverifydetachedjob.moc \
201218 qgpgmeverifyopaquejob.moc \
219 qgpgmewkdlookupjob.moc \
202220 qgpgmewkspublishjob.moc \
203221 tofupolicyjob.moc \
204222 qgpgmetofupolicyjob.moc \
223 receivekeysjob.moc \
205224 refreshkeysjob.moc \
206225 signencryptjob.moc \
207226 signjob.moc \
209228 specialjob.moc \
210229 verifydetachedjob.moc \
211230 verifyopaquejob.moc \
231 wkdlookupjob.moc \
212232 keyformailboxjob.moc \
213233 wkspublishjob.moc \
214234 qgpgmekeyformailboxjob.moc \
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16
17 VPATH = @srcdir@
18 am__is_gnu_make = { \
19 if test -z '$(MAKELEVEL)'; then \
20 false; \
21 elif test -n '$(MAKE_HOST)'; then \
22 true; \
23 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
24 true; \
25 else \
26 false; \
27 fi; \
28 }
29 am__make_running_with_option = \
30 case $${target_option-} in \
31 ?) ;; \
32 *) echo "am__make_running_with_option: internal error: invalid" \
33 "target option '$${target_option-}' specified" >&2; \
34 exit 1;; \
35 esac; \
36 has_opt=no; \
37 sane_makeflags=$$MAKEFLAGS; \
38 if $(am__is_gnu_make); then \
39 sane_makeflags=$$MFLAGS; \
40 else \
41 case $$MAKEFLAGS in \
42 *\\[\ \ ]*) \
43 bs=\\; \
44 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
45 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
46 esac; \
47 fi; \
48 skip_next=no; \
49 strip_trailopt () \
50 { \
51 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
52 }; \
53 for flg in $$sane_makeflags; do \
54 test $$skip_next = yes && { skip_next=no; continue; }; \
55 case $$flg in \
56 *=*|--*) continue;; \
57 -*I) strip_trailopt 'I'; skip_next=yes;; \
58 -*I?*) strip_trailopt 'I';; \
59 -*O) strip_trailopt 'O'; skip_next=yes;; \
60 -*O?*) strip_trailopt 'O';; \
61 -*l) strip_trailopt 'l'; skip_next=yes;; \
62 -*l?*) strip_trailopt 'l';; \
63 -[dEDm]) skip_next=yes;; \
64 -[JT]) skip_next=yes;; \
65 esac; \
66 case $$flg in \
67 *$$target_option*) has_opt=yes; break;; \
68 esac; \
69 done; \
70 test $$has_opt = yes
71 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
72 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
73 pkgdatadir = $(datadir)/@PACKAGE@
74 pkgincludedir = $(includedir)/@PACKAGE@
75 pkglibdir = $(libdir)/@PACKAGE@
76 pkglibexecdir = $(libexecdir)/@PACKAGE@
77 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
78 install_sh_DATA = $(install_sh) -c -m 644
79 install_sh_PROGRAM = $(install_sh) -c
80 install_sh_SCRIPT = $(install_sh) -c
81 INSTALL_HEADER = $(INSTALL_DATA)
82 transform = $(program_transform_name)
83 NORMAL_INSTALL = :
84 PRE_INSTALL = :
85 POST_INSTALL = :
86 NORMAL_UNINSTALL = :
87 PRE_UNINSTALL = :
88 POST_UNINSTALL = :
89 build_triplet = @build@
90 host_triplet = @host@
91 subdir = lang/qt/src
92 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
93 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
94 $(top_srcdir)/m4/ax_pkg_swig.m4 \
95 $(top_srcdir)/m4/ax_python_devel.m4 \
96 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
97 $(top_srcdir)/m4/gnupg-ttyname.m4 \
98 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
99 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
100 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
101 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
102 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
103 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
104 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
105 $(ACLOCAL_M4)
106 DIST_COMMON = $(srcdir)/Makefile.am $(camelcaseinclude_HEADERS) \
107 $(qgpgmeinclude_HEADERS) $(am__DIST_COMMON)
108 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
109 CONFIG_HEADER = $(top_builddir)/conf/config.h
110 CONFIG_CLEAN_FILES = QGpgmeConfig-w32.cmake.in QGpgmeConfig.cmake.in \
111 QGpgmeConfigVersion.cmake qgpgme_version.h
112 CONFIG_CLEAN_VPATH_FILES =
113 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
114 am__vpath_adj = case $$p in \
115 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
116 *) f=$$p;; \
117 esac;
118 am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
119 am__install_max = 40
120 am__nobase_strip_setup = \
121 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
122 am__nobase_strip = \
123 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
124 am__nobase_list = $(am__nobase_strip_setup); \
125 for p in $$list; do echo "$$p $$p"; done | \
126 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
127 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
128 if (++n[$$2] == $(am__install_max)) \
129 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
130 END { for (dir in files) print dir, files[dir] }'
131 am__base_list = \
132 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
133 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
134 am__uninstall_files_from_dir = { \
135 test -z "$$files" \
136 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
137 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
138 $(am__cd) "$$dir" && rm -f $$files; }; \
139 }
140 am__installdirs = "$(DESTDIR)$(libdir)" \
141 "$(DESTDIR)$(camelcaseincludedir)" \
142 "$(DESTDIR)$(qgpgmeincludedir)" \
143 "$(DESTDIR)$(qgpgmeincludedir)"
144 LTLIBRARIES = $(lib_LTLIBRARIES)
145 libqgpgme_la_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
146 ../../../src/libgpgme.la
147 am__objects_1 = dataprovider.lo debug.lo job.lo multideletejob.lo \
148 qgpgmeadduseridjob.lo qgpgmeaddexistingsubkeyjob.lo \
149 qgpgmebackend.lo qgpgmechangeexpiryjob.lo \
150 qgpgmechangeownertrustjob.lo qgpgmechangepasswdjob.lo \
151 qgpgmedecryptjob.lo qgpgmedecryptverifyjob.lo \
152 qgpgmedeletejob.lo qgpgmedownloadjob.lo qgpgmeencryptjob.lo \
153 qgpgmeexportjob.lo qgpgmeimportfromkeyserverjob.lo \
154 qgpgmeimportjob.lo qgpgmekeygenerationjob.lo \
155 qgpgmekeylistjob.lo qgpgmelistallkeysjob.lo \
156 qgpgmenewcryptoconfig.lo qgpgmereceivekeysjob.lo \
157 qgpgmerefreshkeysjob.lo qgpgmesignencryptjob.lo \
158 qgpgmesignjob.lo qgpgmesignkeyjob.lo \
159 qgpgmeverifydetachedjob.lo qgpgmeverifyopaquejob.lo \
160 qgpgmewkdlookupjob.lo threadedjobmixin.lo \
161 qgpgmekeyformailboxjob.lo qgpgme_debug.lo \
162 qgpgmetofupolicyjob.lo qgpgmequickjob.lo \
163 defaultkeygenerationjob.lo qgpgmewkspublishjob.lo \
164 qgpgmegpgcardjob.lo changeexpiryjob.lo importjob.lo dn.lo \
165 cryptoconfig.lo wkdlookupresult.lo util.lo
166 am__objects_2 =
167 am_libqgpgme_la_OBJECTS = $(am__objects_1) $(am__objects_2) \
168 $(am__objects_2)
169 nodist_libqgpgme_la_OBJECTS = $(am__objects_2)
170 libqgpgme_la_OBJECTS = $(am_libqgpgme_la_OBJECTS) \
171 $(nodist_libqgpgme_la_OBJECTS)
172 AM_V_lt = $(am__v_lt_@AM_V@)
173 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
174 am__v_lt_0 = --silent
175 am__v_lt_1 =
176 libqgpgme_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
177 $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
178 $(CXXFLAGS) $(libqgpgme_la_LDFLAGS) $(LDFLAGS) -o $@
179 AM_V_P = $(am__v_P_@AM_V@)
180 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
181 am__v_P_0 = false
182 am__v_P_1 = :
183 AM_V_GEN = $(am__v_GEN_@AM_V@)
184 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
185 am__v_GEN_0 = @echo " GEN " $@;
186 am__v_GEN_1 =
187 AM_V_at = $(am__v_at_@AM_V@)
188 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
189 am__v_at_0 = @
190 am__v_at_1 =
191 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
192 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
193 am__maybe_remake_depfiles = depfiles
194 am__depfiles_remade = ./$(DEPDIR)/changeexpiryjob.Plo \
195 ./$(DEPDIR)/cryptoconfig.Plo ./$(DEPDIR)/dataprovider.Plo \
196 ./$(DEPDIR)/debug.Plo ./$(DEPDIR)/defaultkeygenerationjob.Plo \
197 ./$(DEPDIR)/dn.Plo ./$(DEPDIR)/importjob.Plo \
198 ./$(DEPDIR)/job.Plo ./$(DEPDIR)/multideletejob.Plo \
199 ./$(DEPDIR)/qgpgme_debug.Plo \
200 ./$(DEPDIR)/qgpgmeaddexistingsubkeyjob.Plo \
201 ./$(DEPDIR)/qgpgmeadduseridjob.Plo \
202 ./$(DEPDIR)/qgpgmebackend.Plo \
203 ./$(DEPDIR)/qgpgmechangeexpiryjob.Plo \
204 ./$(DEPDIR)/qgpgmechangeownertrustjob.Plo \
205 ./$(DEPDIR)/qgpgmechangepasswdjob.Plo \
206 ./$(DEPDIR)/qgpgmedecryptjob.Plo \
207 ./$(DEPDIR)/qgpgmedecryptverifyjob.Plo \
208 ./$(DEPDIR)/qgpgmedeletejob.Plo \
209 ./$(DEPDIR)/qgpgmedownloadjob.Plo \
210 ./$(DEPDIR)/qgpgmeencryptjob.Plo \
211 ./$(DEPDIR)/qgpgmeexportjob.Plo \
212 ./$(DEPDIR)/qgpgmegpgcardjob.Plo \
213 ./$(DEPDIR)/qgpgmeimportfromkeyserverjob.Plo \
214 ./$(DEPDIR)/qgpgmeimportjob.Plo \
215 ./$(DEPDIR)/qgpgmekeyformailboxjob.Plo \
216 ./$(DEPDIR)/qgpgmekeygenerationjob.Plo \
217 ./$(DEPDIR)/qgpgmekeylistjob.Plo \
218 ./$(DEPDIR)/qgpgmelistallkeysjob.Plo \
219 ./$(DEPDIR)/qgpgmenewcryptoconfig.Plo \
220 ./$(DEPDIR)/qgpgmequickjob.Plo \
221 ./$(DEPDIR)/qgpgmereceivekeysjob.Plo \
222 ./$(DEPDIR)/qgpgmerefreshkeysjob.Plo \
223 ./$(DEPDIR)/qgpgmesignencryptjob.Plo \
224 ./$(DEPDIR)/qgpgmesignjob.Plo ./$(DEPDIR)/qgpgmesignkeyjob.Plo \
225 ./$(DEPDIR)/qgpgmetofupolicyjob.Plo \
226 ./$(DEPDIR)/qgpgmeverifydetachedjob.Plo \
227 ./$(DEPDIR)/qgpgmeverifyopaquejob.Plo \
228 ./$(DEPDIR)/qgpgmewkdlookupjob.Plo \
229 ./$(DEPDIR)/qgpgmewkspublishjob.Plo \
230 ./$(DEPDIR)/threadedjobmixin.Plo ./$(DEPDIR)/util.Plo \
231 ./$(DEPDIR)/wkdlookupresult.Plo
232 am__mv = mv -f
233 CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
234 $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
235 LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
236 $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \
237 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
238 $(AM_CXXFLAGS) $(CXXFLAGS)
239 AM_V_CXX = $(am__v_CXX_@AM_V@)
240 am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@)
241 am__v_CXX_0 = @echo " CXX " $@;
242 am__v_CXX_1 =
243 CXXLD = $(CXX)
244 CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
245 $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
246 $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
247 AM_V_CXXLD = $(am__v_CXXLD_@AM_V@)
248 am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@)
249 am__v_CXXLD_0 = @echo " CXXLD " $@;
250 am__v_CXXLD_1 =
251 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
252 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
253 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
254 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
255 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
256 $(AM_CFLAGS) $(CFLAGS)
257 AM_V_CC = $(am__v_CC_@AM_V@)
258 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
259 am__v_CC_0 = @echo " CC " $@;
260 am__v_CC_1 =
261 CCLD = $(CC)
262 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
263 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
264 $(AM_LDFLAGS) $(LDFLAGS) -o $@
265 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
266 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
267 am__v_CCLD_0 = @echo " CCLD " $@;
268 am__v_CCLD_1 =
269 SOURCES = $(libqgpgme_la_SOURCES) $(nodist_libqgpgme_la_SOURCES)
270 DIST_SOURCES = $(libqgpgme_la_SOURCES)
271 am__can_run_installinfo = \
272 case $$AM_UPDATE_INFO_DIR in \
273 n|no|NO) false;; \
274 *) (install-info --version) >/dev/null 2>&1;; \
275 esac
276 HEADERS = $(camelcaseinclude_HEADERS) $(nodist_qgpgmeinclude_HEADERS) \
277 $(qgpgmeinclude_HEADERS)
278 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
279 # Read a list of newline-separated strings from the standard input,
280 # and print each of them once, without duplicates. Input order is
281 # *not* preserved.
282 am__uniquify_input = $(AWK) '\
283 BEGIN { nonempty = 0; } \
284 { items[$$0] = 1; nonempty = 1; } \
285 END { if (nonempty) { for (i in items) print i; }; } \
286 '
287 # Make sure the list of sources is unique. This is necessary because,
288 # e.g., the same source file might be shared among _SOURCES variables
289 # for different programs/libraries.
290 am__define_uniq_tagged_files = \
291 list='$(am__tagged_files)'; \
292 unique=`for i in $$list; do \
293 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
294 done | $(am__uniquify_input)`
295 ETAGS = etags
296 CTAGS = ctags
297 am__DIST_COMMON = $(srcdir)/Makefile.in \
298 $(srcdir)/QGpgmeConfig-w32.cmake.in.in \
299 $(srcdir)/QGpgmeConfig.cmake.in.in \
300 $(srcdir)/QGpgmeConfigVersion.cmake.in \
301 $(srcdir)/qgpgme_version.h.in $(top_srcdir)/build-aux/depcomp \
302 $(top_srcdir)/build-aux/mkinstalldirs
303 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
304 ACLOCAL = @ACLOCAL@
305 AMTAR = @AMTAR@
306 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
307 AR = @AR@
308 AS = @AS@
309 AUTOCONF = @AUTOCONF@
310 AUTOHEADER = @AUTOHEADER@
311 AUTOMAKE = @AUTOMAKE@
312 AWK = @AWK@
313 BUILD_FILEVERSION = @BUILD_FILEVERSION@
314 BUILD_REVISION = @BUILD_REVISION@
315 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
316 BUILD_VERSION = @BUILD_VERSION@
317 CC = @CC@
318 CCDEPMODE = @CCDEPMODE@
319 CC_FOR_BUILD = @CC_FOR_BUILD@
320 CFLAGS = @CFLAGS@
321 CPP = @CPP@
322 CPPFLAGS = @CPPFLAGS@
323 CXX = @CXX@
324 CXXCPP = @CXXCPP@
325 CXXDEPMODE = @CXXDEPMODE@
326 CXXFLAGS = @CXXFLAGS@
327 CYGPATH_W = @CYGPATH_W@
328 DEFS = @DEFS@
329 DEPDIR = @DEPDIR@
330 DLLTOOL = @DLLTOOL@
331 DOXYGEN = @DOXYGEN@
332 DSYMUTIL = @DSYMUTIL@
333 DUMPBIN = @DUMPBIN@
334 ECHO_C = @ECHO_C@
335 ECHO_N = @ECHO_N@
336 ECHO_T = @ECHO_T@
337 EGREP = @EGREP@
338 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
339 EXEEXT = @EXEEXT@
340 FGREP = @FGREP@
341 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
342 GLIBC21 = @GLIBC21@
343 GLIB_CFLAGS = @GLIB_CFLAGS@
344 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
345 GLIB_LIBS = @GLIB_LIBS@
346 GLIB_MKENUMS = @GLIB_MKENUMS@
347 GOBJECT_QUERY = @GOBJECT_QUERY@
348 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
349 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
350 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
351 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
352 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
353 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
354 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
355 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
356 GPGME_QT_LIBS = @GPGME_QT_LIBS@
357 GPGRT_CONFIG = @GPGRT_CONFIG@
358 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
359 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
360 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
361 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
362 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
363 GRAPHVIZ = @GRAPHVIZ@
364 GREP = @GREP@
365 HAVE_CXX11 = @HAVE_CXX11@
366 HAVE_DOT = @HAVE_DOT@
367 INSTALL = @INSTALL@
368 INSTALL_DATA = @INSTALL_DATA@
369 INSTALL_PROGRAM = @INSTALL_PROGRAM@
370 INSTALL_SCRIPT = @INSTALL_SCRIPT@
371 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
372 LD = @LD@
373 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
374 LDFLAGS = @LDFLAGS@
375 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
376 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
377 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
378 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
379 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
380 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
381 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
382 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
383 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
384 LIBOBJS = @LIBOBJS@
385 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
386 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
387 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
388 LIBS = @LIBS@
389 LIBTOOL = @LIBTOOL@
390 LIPO = @LIPO@
391 LN_S = @LN_S@
392 LTLIBOBJS = @LTLIBOBJS@
393 MAINT = @MAINT@
394 MAKEINFO = @MAKEINFO@
395 MANIFEST_TOOL = @MANIFEST_TOOL@
396 MKDIR_P = @MKDIR_P@
397 MOC = @MOC@
398 MOC2 = @MOC2@
399 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
400 NM = @NM@
401 NMEDIT = @NMEDIT@
402 OBJDUMP = @OBJDUMP@
403 OBJEXT = @OBJEXT@
404 OTOOL = @OTOOL@
405 OTOOL64 = @OTOOL64@
406 PACKAGE = @PACKAGE@
407 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
408 PACKAGE_NAME = @PACKAGE_NAME@
409 PACKAGE_STRING = @PACKAGE_STRING@
410 PACKAGE_TARNAME = @PACKAGE_TARNAME@
411 PACKAGE_URL = @PACKAGE_URL@
412 PACKAGE_VERSION = @PACKAGE_VERSION@
413 PATH_SEPARATOR = @PATH_SEPARATOR@
414 PKG_CONFIG = @PKG_CONFIG@
415 PYTHON = @PYTHON@
416 PYTHONS = @PYTHONS@
417 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
418 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
419 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
420 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
421 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
422 PYTHON_PLATFORM = @PYTHON_PLATFORM@
423 PYTHON_PREFIX = @PYTHON_PREFIX@
424 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
425 PYTHON_VERSION = @PYTHON_VERSION@
426 QTCHOOSER = @QTCHOOSER@
427 RANLIB = @RANLIB@
428 RC = @RC@
429 SED = @SED@
430 SET_MAKE = @SET_MAKE@
431 SHELL = @SHELL@
432 STRIP = @STRIP@
433 SWIG = @SWIG@
434 SWIG_LIB = @SWIG_LIB@
435 SYSROOT = @SYSROOT@
436 VERSION = @VERSION@
437 VERSION_MAJOR = @VERSION_MAJOR@
438 VERSION_MICRO = @VERSION_MICRO@
439 VERSION_MINOR = @VERSION_MINOR@
440 VERSION_NUMBER = @VERSION_NUMBER@
441 abs_builddir = @abs_builddir@
442 abs_srcdir = @abs_srcdir@
443 abs_top_builddir = @abs_top_builddir@
444 abs_top_srcdir = @abs_top_srcdir@
445 ac_ct_AR = @ac_ct_AR@
446 ac_ct_CC = @ac_ct_CC@
447 ac_ct_CXX = @ac_ct_CXX@
448 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
449 am__include = @am__include@
450 am__leading_dot = @am__leading_dot@
451 am__quote = @am__quote@
452 am__tar = @am__tar@
453 am__untar = @am__untar@
454 bindir = @bindir@
455 build = @build@
456 build_alias = @build_alias@
457 build_cpu = @build_cpu@
458 build_os = @build_os@
459 build_vendor = @build_vendor@
460 builddir = @builddir@
461 datadir = @datadir@
462 datarootdir = @datarootdir@
463 docdir = @docdir@
464 dvidir = @dvidir@
465 emacs_local_vars_begin = @emacs_local_vars_begin@
466 emacs_local_vars_end = @emacs_local_vars_end@
467 emacs_local_vars_read_only = @emacs_local_vars_read_only@
468 exec_prefix = @exec_prefix@
469 host = @host@
470 host_alias = @host_alias@
471 host_cpu = @host_cpu@
472 host_os = @host_os@
473 host_vendor = @host_vendor@
474 htmldir = @htmldir@
475 includedir = @includedir@
476 infodir = @infodir@
477 install_sh = @install_sh@
478 libdir = @libdir@
479 libexecdir = @libexecdir@
480 localedir = @localedir@
481 localstatedir = @localstatedir@
482 mandir = @mandir@
483 mkdir_p = @mkdir_p@
484 oldincludedir = @oldincludedir@
485 pdfdir = @pdfdir@
486 pkgpyexecdir = @pkgpyexecdir@
487 pkgpythondir = @pkgpythondir@
488 prefix = @prefix@
489 program_transform_name = @program_transform_name@
490 psdir = @psdir@
491 pyexecdir = @pyexecdir@
492 pythondir = @pythondir@
493 runstatedir = @runstatedir@
494 sbindir = @sbindir@
495 sharedstatedir = @sharedstatedir@
496 srcdir = @srcdir@
497 sysconfdir = @sysconfdir@
498 target_alias = @target_alias@
499 top_build_prefix = @top_build_prefix@
500 top_builddir = @top_builddir@
501 top_srcdir = @top_srcdir@
502
503 # Makefile.am for GPGMEPP.
504 # Copyright (C) 2016 Bundesamt für Sicherheit in der Informationstechnik
505 # Software engineering by Intevation GmbH
506 #
507 # This file is part of GPGMEPP.
508 #
509 # GPGME-CL is free software; you can redistribute it and/or modify it
510 # under the terms of the GNU General Public License as published by
511 # the Free Software Foundation; either version 2 of the License, or
512 # (at your option) any later version.
513 #
514 # GPGME-CL is distributed in the hope that it will be useful,
515 # but WITHOUT ANY WARRANTY; without even the implied warranty of
516 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
517 # GNU Lesser General Public License for more details.
518 #
519 # You should have received a copy of the GNU General Public License
520 # along with this program; if not, write to the Free Software
521 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
522 # 02111-1307, USA
523 lib_LTLIBRARIES = libqgpgme.la
524 EXTRA_DIST = QGpgmeConfig.cmake.in.in QGpgmeConfigVersion.cmake.in \
525 qgpgme_debug.h qgpgme_version.h.in \
526 QGpgmeConfig.cmake.in.in
527
528 qgpgme_sources = \
529 dataprovider.cpp \
530 debug.cpp \
531 job.cpp multideletejob.cpp qgpgmeadduseridjob.cpp \
532 qgpgmeaddexistingsubkeyjob.cpp \
533 qgpgmebackend.cpp qgpgmechangeexpiryjob.cpp qgpgmechangeownertrustjob.cpp \
534 qgpgmechangepasswdjob.cpp qgpgmedecryptjob.cpp \
535 qgpgmedecryptverifyjob.cpp qgpgmedeletejob.cpp qgpgmedownloadjob.cpp \
536 qgpgmeencryptjob.cpp qgpgmeexportjob.cpp qgpgmeimportfromkeyserverjob.cpp \
537 qgpgmeimportjob.cpp qgpgmekeygenerationjob.cpp qgpgmekeylistjob.cpp \
538 qgpgmelistallkeysjob.cpp qgpgmenewcryptoconfig.cpp \
539 qgpgmereceivekeysjob.cpp \
540 qgpgmerefreshkeysjob.cpp \
541 qgpgmesignencryptjob.cpp \
542 qgpgmesignjob.cpp qgpgmesignkeyjob.cpp qgpgmeverifydetachedjob.cpp \
543 qgpgmeverifyopaquejob.cpp qgpgmewkdlookupjob.cpp threadedjobmixin.cpp \
544 qgpgmekeyformailboxjob.cpp qgpgme_debug.cpp \
545 qgpgmetofupolicyjob.cpp qgpgmequickjob.cpp \
546 defaultkeygenerationjob.cpp qgpgmewkspublishjob.cpp \
547 qgpgmegpgcardjob.cpp changeexpiryjob.cpp importjob.cpp \
548 dn.cpp cryptoconfig.cpp wkdlookupresult.cpp \
549 util.cpp
550
551
552 # If you add one here make sure that you also add one in camelcase
553 qgpgme_headers = \
554 abstractimportjob.h \
555 addexistingsubkeyjob.h \
556 adduseridjob.h \
557 changeexpiryjob.h \
558 changeownertrustjob.h \
559 changepasswdjob.h \
560 dataprovider.h \
561 debug.h \
562 decryptjob.h \
563 decryptverifyjob.h \
564 downloadjob.h \
565 encryptjob.h \
566 exportjob.h \
567 hierarchicalkeylistjob.h \
568 job.h \
569 keyformailboxjob.h \
570 multideletejob.h \
571 protocol.h \
572 qgpgme_export.h \
573 qgpgmenewcryptoconfig.h \
574 quickjob.h \
575 receivekeysjob.h \
576 specialjob.h \
577 signjob.h \
578 signkeyjob.h \
579 signencryptjob.h \
580 verifyopaquejob.h \
581 refreshkeysjob.h \
582 cryptoconfig.h \
583 deletejob.h \
584 importfromkeyserverjob.h \
585 importjob.h \
586 keygenerationjob.h \
587 keylistjob.h \
588 listallkeysjob.h \
589 verifydetachedjob.h \
590 defaultkeygenerationjob.h \
591 tofupolicyjob.h \
592 wkdlookupjob.h \
593 wkdlookupresult.h \
594 wkspublishjob.h \
595 gpgcardjob.h \
596 dn.h
597
598 camelcase_headers = \
599 AddExistingSubkeyJob \
600 AddUserIDJob \
601 AbstractImportJob \
602 ChangeExpiryJob \
603 ChangeOwnerTrustJob \
604 ChangePasswdJob \
605 DataProvider \
606 Debug \
607 DecryptJob \
608 DecryptVerifyJob \
609 DN \
610 DownloadJob \
611 EncryptJob \
612 ExportJob \
613 HierarchicalKeyKistJob \
614 Job \
615 MultiDeleteJob \
616 Protocol \
617 QGpgMENewCryptoConfig \
618 QuickJob \
619 ReceiveKeysJob \
620 SpecialJob \
621 SignJob \
622 SignKeyJob \
623 SignEncryptJob \
624 VerifyOpaqueJob \
625 RefreshKeysJob \
626 CryptoConfig \
627 DeleteJob \
628 ImportFromKeyserverJob \
629 ImportJob \
630 KeyGenerationJob \
631 KeyListJob \
632 ListAllKeysJob \
633 VerifyDetachedJob \
634 KeyForMailboxJob \
635 DefaultKeyGenerationJob \
636 WKDLookupJob \
637 WKDLookupResult \
638 WKSPublishJob \
639 TofuPolicyJob \
640 GpgCardJob
641
642 private_qgpgme_headers = \
643 qgpgme_export.h \
644 protocol_p.h \
645 job_p.h \
646 qgpgmeaddexistingsubkeyjob.h \
647 qgpgmeadduseridjob.h \
648 qgpgmebackend.h \
649 qgpgmechangeexpiryjob.h \
650 qgpgmechangeownertrustjob.h \
651 qgpgmechangepasswdjob.h \
652 qgpgmedecryptjob.h \
653 qgpgmedecryptverifyjob.h \
654 qgpgmedeletejob.h \
655 qgpgmedownloadjob.h \
656 qgpgmeencryptjob.h \
657 qgpgmeexportjob.h \
658 qgpgmeimportfromkeyserverjob.h \
659 qgpgmeimportjob.h \
660 qgpgmekeygenerationjob.h \
661 qgpgmekeylistjob.h \
662 qgpgmelistallkeysjob.h \
663 qgpgmereceivekeysjob.h \
664 qgpgmerefreshkeysjob.h \
665 qgpgmesignencryptjob.h \
666 qgpgmesignjob.h \
667 qgpgmesignkeyjob.h \
668 qgpgmeverifydetachedjob.h \
669 qgpgmeverifyopaquejob.h \
670 qgpgmewkdlookupjob.h \
671 qgpgmekeyformailboxjob.h \
672 qgpgmewkspublishjob.h \
673 qgpgmetofupolicyjob.h \
674 qgpgmegpgcardjob.h \
675 qgpgmequickjob.h \
676 threadedjobmixin.h \
677 util.h
678
679 qgpgme_moc_sources = \
680 abstractimportjob.moc \
681 addexistingsubkeyjob.moc \
682 adduseridjob.moc \
683 changeexpiryjob.moc \
684 changeownertrustjob.moc \
685 changepasswdjob.moc \
686 decryptjob.moc \
687 decryptverifyjob.moc \
688 deletejob.moc \
689 downloadjob.moc \
690 encryptjob.moc \
691 exportjob.moc \
692 hierarchicalkeylistjob.moc \
693 importfromkeyserverjob.moc \
694 importjob.moc \
695 job.moc \
696 keygenerationjob.moc \
697 keylistjob.moc \
698 listallkeysjob.moc \
699 multideletejob.moc \
700 qgpgmeaddexistingsubkeyjob.moc \
701 qgpgmeadduseridjob.moc \
702 qgpgmechangeexpiryjob.moc \
703 qgpgmechangeownertrustjob.moc \
704 qgpgmechangepasswdjob.moc \
705 qgpgmedecryptjob.moc \
706 qgpgmedecryptverifyjob.moc \
707 qgpgmedeletejob.moc \
708 qgpgmedownloadjob.moc \
709 qgpgmeencryptjob.moc \
710 qgpgmeexportjob.moc \
711 qgpgmeimportfromkeyserverjob.moc \
712 qgpgmeimportjob.moc \
713 qgpgmekeygenerationjob.moc \
714 qgpgmekeylistjob.moc \
715 qgpgmelistallkeysjob.moc \
716 qgpgmereceivekeysjob.moc \
717 qgpgmerefreshkeysjob.moc \
718 qgpgmesignencryptjob.moc \
719 qgpgmesignjob.moc \
720 qgpgmesignkeyjob.moc \
721 qgpgmeverifydetachedjob.moc \
722 qgpgmeverifyopaquejob.moc \
723 qgpgmewkdlookupjob.moc \
724 qgpgmewkspublishjob.moc \
725 tofupolicyjob.moc \
726 qgpgmetofupolicyjob.moc \
727 receivekeysjob.moc \
728 refreshkeysjob.moc \
729 signencryptjob.moc \
730 signjob.moc \
731 signkeyjob.moc \
732 specialjob.moc \
733 verifydetachedjob.moc \
734 verifyopaquejob.moc \
735 wkdlookupjob.moc \
736 keyformailboxjob.moc \
737 wkspublishjob.moc \
738 qgpgmekeyformailboxjob.moc \
739 defaultkeygenerationjob.moc \
740 quickjob.moc \
741 qgpgmequickjob.moc \
742 gpgcardjob.moc \
743 qgpgmegpgcardjob.moc
744
745 qgpgmeincludedir = $(includedir)/qgpgme
746 qgpgmeinclude_HEADERS = $(qgpgme_headers)
747 camelcaseincludedir = $(includedir)/QGpgME
748 camelcaseinclude_HEADERS = $(camelcase_headers)
749 nodist_qgpgmeinclude_HEADERS = qgpgme_version.h
750 libqgpgme_la_SOURCES = $(qgpgme_sources) $(qgpgme_headers) $(private_qgpgme_headers)
751 AM_CPPFLAGS = -I$(top_srcdir)/lang/cpp/src -I$(top_builddir)/src \
752 @GPGME_QT_CFLAGS@ @GPG_ERROR_CFLAGS@ @LIBASSUAN_CFLAGS@ \
753 -DBUILDING_QGPGME -Wsuggest-override \
754 -Wzero-as-null-pointer-constant
755
756 libqgpgme_la_LIBADD = ../../cpp/src/libgpgmepp.la ../../../src/libgpgme.la \
757 @LIBASSUAN_LIBS@ @GPG_ERROR_LIBS@ @GPGME_QT_LIBS@
758
759 libqgpgme_la_LDFLAGS = -no-undefined -version-info \
760 @LIBQGPGME_LT_CURRENT@:@LIBQGPGME_LT_REVISION@:@LIBQGPGME_LT_AGE@
761
762 @HAVE_MACOS_SYSTEM_FALSE@libsuffix = .so
763 @HAVE_MACOS_SYSTEM_TRUE@libsuffix = .dylib
764 BUILT_SOURCES = $(qgpgme_moc_sources) $(camelcase_headers)
765 CLEANFILES = $(qgpgme_moc_sources) $(camelcase_headers) QGpgmeConfig.cmake \
766 qgpgme_version.h QGpgmeConfig.cmake.in \
767 QGpgmeConfigVersion.cmake
768
769 nodist_libqgpgme_la_SOURCES = $(qgpgme_moc_sources)
770 all: $(BUILT_SOURCES)
771 $(MAKE) $(AM_MAKEFLAGS) all-am
772
773 .SUFFIXES:
774 .SUFFIXES: .cpp .h .lo .moc .o .obj
775 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
776 @for dep in $?; do \
777 case '$(am__configure_deps)' in \
778 *$$dep*) \
779 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
780 && { if test -f $@; then exit 0; else break; fi; }; \
781 exit 1;; \
782 esac; \
783 done; \
784 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/qt/src/Makefile'; \
785 $(am__cd) $(top_srcdir) && \
786 $(AUTOMAKE) --gnu lang/qt/src/Makefile
787 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
788 @case '$?' in \
789 *config.status*) \
790 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
791 *) \
792 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
793 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
794 esac;
795
796 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
797 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
798
799 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
800 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
801 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
802 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
803 $(am__aclocal_m4_deps):
804 QGpgmeConfig-w32.cmake.in: $(top_builddir)/config.status $(srcdir)/QGpgmeConfig-w32.cmake.in.in
805 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
806 QGpgmeConfig.cmake.in: $(top_builddir)/config.status $(srcdir)/QGpgmeConfig.cmake.in.in
807 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
808 QGpgmeConfigVersion.cmake: $(top_builddir)/config.status $(srcdir)/QGpgmeConfigVersion.cmake.in
809 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
810 qgpgme_version.h: $(top_builddir)/config.status $(srcdir)/qgpgme_version.h.in
811 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
812
813 install-libLTLIBRARIES: $(lib_LTLIBRARIES)
814 @$(NORMAL_INSTALL)
815 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
816 list2=; for p in $$list; do \
817 if test -f $$p; then \
818 list2="$$list2 $$p"; \
819 else :; fi; \
820 done; \
821 test -z "$$list2" || { \
822 echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
823 $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
824 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
825 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
826 }
827
828 uninstall-libLTLIBRARIES:
829 @$(NORMAL_UNINSTALL)
830 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
831 for p in $$list; do \
832 $(am__strip_dir) \
833 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
834 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
835 done
836
837 clean-libLTLIBRARIES:
838 -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
839 @list='$(lib_LTLIBRARIES)'; \
840 locs=`for p in $$list; do echo $$p; done | \
841 sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
842 sort -u`; \
843 test -z "$$locs" || { \
844 echo rm -f $${locs}; \
845 rm -f $${locs}; \
846 }
847
848 libqgpgme.la: $(libqgpgme_la_OBJECTS) $(libqgpgme_la_DEPENDENCIES) $(EXTRA_libqgpgme_la_DEPENDENCIES)
849 $(AM_V_CXXLD)$(libqgpgme_la_LINK) -rpath $(libdir) $(libqgpgme_la_OBJECTS) $(libqgpgme_la_LIBADD) $(LIBS)
850
851 mostlyclean-compile:
852 -rm -f *.$(OBJEXT)
853
854 distclean-compile:
855 -rm -f *.tab.c
856
857 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/changeexpiryjob.Plo@am__quote@ # am--include-marker
858 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cryptoconfig.Plo@am__quote@ # am--include-marker
859 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dataprovider.Plo@am__quote@ # am--include-marker
860 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/debug.Plo@am__quote@ # am--include-marker
861 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/defaultkeygenerationjob.Plo@am__quote@ # am--include-marker
862 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dn.Plo@am__quote@ # am--include-marker
863 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/importjob.Plo@am__quote@ # am--include-marker
864 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/job.Plo@am__quote@ # am--include-marker
865 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/multideletejob.Plo@am__quote@ # am--include-marker
866 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgme_debug.Plo@am__quote@ # am--include-marker
867 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeaddexistingsubkeyjob.Plo@am__quote@ # am--include-marker
868 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeadduseridjob.Plo@am__quote@ # am--include-marker
869 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmebackend.Plo@am__quote@ # am--include-marker
870 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmechangeexpiryjob.Plo@am__quote@ # am--include-marker
871 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmechangeownertrustjob.Plo@am__quote@ # am--include-marker
872 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmechangepasswdjob.Plo@am__quote@ # am--include-marker
873 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmedecryptjob.Plo@am__quote@ # am--include-marker
874 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmedecryptverifyjob.Plo@am__quote@ # am--include-marker
875 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmedeletejob.Plo@am__quote@ # am--include-marker
876 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmedownloadjob.Plo@am__quote@ # am--include-marker
877 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeencryptjob.Plo@am__quote@ # am--include-marker
878 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeexportjob.Plo@am__quote@ # am--include-marker
879 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmegpgcardjob.Plo@am__quote@ # am--include-marker
880 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeimportfromkeyserverjob.Plo@am__quote@ # am--include-marker
881 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeimportjob.Plo@am__quote@ # am--include-marker
882 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmekeyformailboxjob.Plo@am__quote@ # am--include-marker
883 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmekeygenerationjob.Plo@am__quote@ # am--include-marker
884 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmekeylistjob.Plo@am__quote@ # am--include-marker
885 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmelistallkeysjob.Plo@am__quote@ # am--include-marker
886 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmenewcryptoconfig.Plo@am__quote@ # am--include-marker
887 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmequickjob.Plo@am__quote@ # am--include-marker
888 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmereceivekeysjob.Plo@am__quote@ # am--include-marker
889 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmerefreshkeysjob.Plo@am__quote@ # am--include-marker
890 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmesignencryptjob.Plo@am__quote@ # am--include-marker
891 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmesignjob.Plo@am__quote@ # am--include-marker
892 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmesignkeyjob.Plo@am__quote@ # am--include-marker
893 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmetofupolicyjob.Plo@am__quote@ # am--include-marker
894 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeverifydetachedjob.Plo@am__quote@ # am--include-marker
895 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmeverifyopaquejob.Plo@am__quote@ # am--include-marker
896 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmewkdlookupjob.Plo@am__quote@ # am--include-marker
897 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/qgpgmewkspublishjob.Plo@am__quote@ # am--include-marker
898 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threadedjobmixin.Plo@am__quote@ # am--include-marker
899 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Plo@am__quote@ # am--include-marker
900 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wkdlookupresult.Plo@am__quote@ # am--include-marker
901
902 $(am__depfiles_remade):
903 @$(MKDIR_P) $(@D)
904 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
905
906 am--depfiles: $(am__depfiles_remade)
907
908 .cpp.o:
909 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
910 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
911 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
912 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
913 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $<
914
915 .cpp.obj:
916 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
917 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
918 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
919 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
920 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
921
922 .cpp.lo:
923 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
924 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
925 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
926 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
927 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $<
928
929 mostlyclean-libtool:
930 -rm -f *.lo
931
932 clean-libtool:
933 -rm -rf .libs _libs
934 install-camelcaseincludeHEADERS: $(camelcaseinclude_HEADERS)
935 @$(NORMAL_INSTALL)
936 @list='$(camelcaseinclude_HEADERS)'; test -n "$(camelcaseincludedir)" || list=; \
937 if test -n "$$list"; then \
938 echo " $(MKDIR_P) '$(DESTDIR)$(camelcaseincludedir)'"; \
939 $(MKDIR_P) "$(DESTDIR)$(camelcaseincludedir)" || exit 1; \
940 fi; \
941 for p in $$list; do \
942 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
943 echo "$$d$$p"; \
944 done | $(am__base_list) | \
945 while read files; do \
946 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(camelcaseincludedir)'"; \
947 $(INSTALL_HEADER) $$files "$(DESTDIR)$(camelcaseincludedir)" || exit $$?; \
948 done
949
950 uninstall-camelcaseincludeHEADERS:
951 @$(NORMAL_UNINSTALL)
952 @list='$(camelcaseinclude_HEADERS)'; test -n "$(camelcaseincludedir)" || list=; \
953 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
954 dir='$(DESTDIR)$(camelcaseincludedir)'; $(am__uninstall_files_from_dir)
955 install-nodist_qgpgmeincludeHEADERS: $(nodist_qgpgmeinclude_HEADERS)
956 @$(NORMAL_INSTALL)
957 @list='$(nodist_qgpgmeinclude_HEADERS)'; test -n "$(qgpgmeincludedir)" || list=; \
958 if test -n "$$list"; then \
959 echo " $(MKDIR_P) '$(DESTDIR)$(qgpgmeincludedir)'"; \
960 $(MKDIR_P) "$(DESTDIR)$(qgpgmeincludedir)" || exit 1; \
961 fi; \
962 for p in $$list; do \
963 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
964 echo "$$d$$p"; \
965 done | $(am__base_list) | \
966 while read files; do \
967 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(qgpgmeincludedir)'"; \
968 $(INSTALL_HEADER) $$files "$(DESTDIR)$(qgpgmeincludedir)" || exit $$?; \
969 done
970
971 uninstall-nodist_qgpgmeincludeHEADERS:
972 @$(NORMAL_UNINSTALL)
973 @list='$(nodist_qgpgmeinclude_HEADERS)'; test -n "$(qgpgmeincludedir)" || list=; \
974 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
975 dir='$(DESTDIR)$(qgpgmeincludedir)'; $(am__uninstall_files_from_dir)
976 install-qgpgmeincludeHEADERS: $(qgpgmeinclude_HEADERS)
977 @$(NORMAL_INSTALL)
978 @list='$(qgpgmeinclude_HEADERS)'; test -n "$(qgpgmeincludedir)" || list=; \
979 if test -n "$$list"; then \
980 echo " $(MKDIR_P) '$(DESTDIR)$(qgpgmeincludedir)'"; \
981 $(MKDIR_P) "$(DESTDIR)$(qgpgmeincludedir)" || exit 1; \
982 fi; \
983 for p in $$list; do \
984 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
985 echo "$$d$$p"; \
986 done | $(am__base_list) | \
987 while read files; do \
988 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(qgpgmeincludedir)'"; \
989 $(INSTALL_HEADER) $$files "$(DESTDIR)$(qgpgmeincludedir)" || exit $$?; \
990 done
991
992 uninstall-qgpgmeincludeHEADERS:
993 @$(NORMAL_UNINSTALL)
994 @list='$(qgpgmeinclude_HEADERS)'; test -n "$(qgpgmeincludedir)" || list=; \
995 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
996 dir='$(DESTDIR)$(qgpgmeincludedir)'; $(am__uninstall_files_from_dir)
997
998 ID: $(am__tagged_files)
999 $(am__define_uniq_tagged_files); mkid -fID $$unique
1000 tags: tags-am
1001 TAGS: tags
1002
1003 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
1004 set x; \
1005 here=`pwd`; \
1006 $(am__define_uniq_tagged_files); \
1007 shift; \
1008 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
1009 test -n "$$unique" || unique=$$empty_fix; \
1010 if test $$# -gt 0; then \
1011 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
1012 "$$@" $$unique; \
1013 else \
1014 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
1015 $$unique; \
1016 fi; \
1017 fi
1018 ctags: ctags-am
1019
1020 CTAGS: ctags
1021 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
1022 $(am__define_uniq_tagged_files); \
1023 test -z "$(CTAGS_ARGS)$$unique" \
1024 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
1025 $$unique
1026
1027 GTAGS:
1028 here=`$(am__cd) $(top_builddir) && pwd` \
1029 && $(am__cd) $(top_srcdir) \
1030 && gtags -i $(GTAGS_ARGS) "$$here"
1031 cscopelist: cscopelist-am
1032
1033 cscopelist-am: $(am__tagged_files)
1034 list='$(am__tagged_files)'; \
1035 case "$(srcdir)" in \
1036 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
1037 *) sdir=$(subdir)/$(srcdir) ;; \
1038 esac; \
1039 for i in $$list; do \
1040 if test -f "$$i"; then \
1041 echo "$(subdir)/$$i"; \
1042 else \
1043 echo "$$sdir/$$i"; \
1044 fi; \
1045 done >> $(top_builddir)/cscope.files
1046
1047 distclean-tags:
1048 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
1049
1050 distdir: $(BUILT_SOURCES)
1051 $(MAKE) $(AM_MAKEFLAGS) distdir-am
1052
1053 distdir-am: $(DISTFILES)
1054 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
1055 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
1056 list='$(DISTFILES)'; \
1057 dist_files=`for file in $$list; do echo $$file; done | \
1058 sed -e "s|^$$srcdirstrip/||;t" \
1059 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
1060 case $$dist_files in \
1061 */*) $(MKDIR_P) `echo "$$dist_files" | \
1062 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
1063 sort -u` ;; \
1064 esac; \
1065 for file in $$dist_files; do \
1066 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
1067 if test -d $$d/$$file; then \
1068 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
1069 if test -d "$(distdir)/$$file"; then \
1070 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
1071 fi; \
1072 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
1073 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
1074 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
1075 fi; \
1076 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
1077 else \
1078 test -f "$(distdir)/$$file" \
1079 || cp -p $$d/$$file "$(distdir)/$$file" \
1080 || exit 1; \
1081 fi; \
1082 done
1083 check-am: all-am
1084 check: $(BUILT_SOURCES)
1085 $(MAKE) $(AM_MAKEFLAGS) check-am
1086 all-am: Makefile $(LTLIBRARIES) $(HEADERS)
1087 installdirs:
1088 for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(camelcaseincludedir)" "$(DESTDIR)$(qgpgmeincludedir)" "$(DESTDIR)$(qgpgmeincludedir)"; do \
1089 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
1090 done
1091 install: $(BUILT_SOURCES)
1092 $(MAKE) $(AM_MAKEFLAGS) install-am
1093 install-exec: $(BUILT_SOURCES)
1094 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
1095 install-data: install-data-am
1096 uninstall: uninstall-am
1097
1098 install-am: all-am
1099 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
1100
1101 installcheck: installcheck-am
1102 install-strip:
1103 if test -z '$(STRIP)'; then \
1104 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1105 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1106 install; \
1107 else \
1108 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1109 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1110 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
1111 fi
1112 mostlyclean-generic:
1113
1114 clean-generic:
1115 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
1116
1117 distclean-generic:
1118 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
1119 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
1120
1121 maintainer-clean-generic:
1122 @echo "This command is intended for maintainers to use"
1123 @echo "it deletes files that may require special tools to rebuild."
1124 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
1125 clean: clean-am
1126
1127 clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
1128 mostlyclean-am
1129
1130 distclean: distclean-am
1131 -rm -f ./$(DEPDIR)/changeexpiryjob.Plo
1132 -rm -f ./$(DEPDIR)/cryptoconfig.Plo
1133 -rm -f ./$(DEPDIR)/dataprovider.Plo
1134 -rm -f ./$(DEPDIR)/debug.Plo
1135 -rm -f ./$(DEPDIR)/defaultkeygenerationjob.Plo
1136 -rm -f ./$(DEPDIR)/dn.Plo
1137 -rm -f ./$(DEPDIR)/importjob.Plo
1138 -rm -f ./$(DEPDIR)/job.Plo
1139 -rm -f ./$(DEPDIR)/multideletejob.Plo
1140 -rm -f ./$(DEPDIR)/qgpgme_debug.Plo
1141 -rm -f ./$(DEPDIR)/qgpgmeaddexistingsubkeyjob.Plo
1142 -rm -f ./$(DEPDIR)/qgpgmeadduseridjob.Plo
1143 -rm -f ./$(DEPDIR)/qgpgmebackend.Plo
1144 -rm -f ./$(DEPDIR)/qgpgmechangeexpiryjob.Plo
1145 -rm -f ./$(DEPDIR)/qgpgmechangeownertrustjob.Plo
1146 -rm -f ./$(DEPDIR)/qgpgmechangepasswdjob.Plo
1147 -rm -f ./$(DEPDIR)/qgpgmedecryptjob.Plo
1148 -rm -f ./$(DEPDIR)/qgpgmedecryptverifyjob.Plo
1149 -rm -f ./$(DEPDIR)/qgpgmedeletejob.Plo
1150 -rm -f ./$(DEPDIR)/qgpgmedownloadjob.Plo
1151 -rm -f ./$(DEPDIR)/qgpgmeencryptjob.Plo
1152 -rm -f ./$(DEPDIR)/qgpgmeexportjob.Plo
1153 -rm -f ./$(DEPDIR)/qgpgmegpgcardjob.Plo
1154 -rm -f ./$(DEPDIR)/qgpgmeimportfromkeyserverjob.Plo
1155 -rm -f ./$(DEPDIR)/qgpgmeimportjob.Plo
1156 -rm -f ./$(DEPDIR)/qgpgmekeyformailboxjob.Plo
1157 -rm -f ./$(DEPDIR)/qgpgmekeygenerationjob.Plo
1158 -rm -f ./$(DEPDIR)/qgpgmekeylistjob.Plo
1159 -rm -f ./$(DEPDIR)/qgpgmelistallkeysjob.Plo
1160 -rm -f ./$(DEPDIR)/qgpgmenewcryptoconfig.Plo
1161 -rm -f ./$(DEPDIR)/qgpgmequickjob.Plo
1162 -rm -f ./$(DEPDIR)/qgpgmereceivekeysjob.Plo
1163 -rm -f ./$(DEPDIR)/qgpgmerefreshkeysjob.Plo
1164 -rm -f ./$(DEPDIR)/qgpgmesignencryptjob.Plo
1165 -rm -f ./$(DEPDIR)/qgpgmesignjob.Plo
1166 -rm -f ./$(DEPDIR)/qgpgmesignkeyjob.Plo
1167 -rm -f ./$(DEPDIR)/qgpgmetofupolicyjob.Plo
1168 -rm -f ./$(DEPDIR)/qgpgmeverifydetachedjob.Plo
1169 -rm -f ./$(DEPDIR)/qgpgmeverifyopaquejob.Plo
1170 -rm -f ./$(DEPDIR)/qgpgmewkdlookupjob.Plo
1171 -rm -f ./$(DEPDIR)/qgpgmewkspublishjob.Plo
1172 -rm -f ./$(DEPDIR)/threadedjobmixin.Plo
1173 -rm -f ./$(DEPDIR)/util.Plo
1174 -rm -f ./$(DEPDIR)/wkdlookupresult.Plo
1175 -rm -f Makefile
1176 distclean-am: clean-am distclean-compile distclean-generic \
1177 distclean-tags
1178
1179 dvi: dvi-am
1180
1181 dvi-am:
1182
1183 html: html-am
1184
1185 html-am:
1186
1187 info: info-am
1188
1189 info-am:
1190
1191 install-data-am: install-camelcaseincludeHEADERS install-data-local \
1192 install-nodist_qgpgmeincludeHEADERS \
1193 install-qgpgmeincludeHEADERS
1194
1195 install-dvi: install-dvi-am
1196
1197 install-dvi-am:
1198
1199 install-exec-am: install-libLTLIBRARIES
1200
1201 install-html: install-html-am
1202
1203 install-html-am:
1204
1205 install-info: install-info-am
1206
1207 install-info-am:
1208
1209 install-man:
1210
1211 install-pdf: install-pdf-am
1212
1213 install-pdf-am:
1214
1215 install-ps: install-ps-am
1216
1217 install-ps-am:
1218
1219 installcheck-am:
1220
1221 maintainer-clean: maintainer-clean-am
1222 -rm -f ./$(DEPDIR)/changeexpiryjob.Plo
1223 -rm -f ./$(DEPDIR)/cryptoconfig.Plo
1224 -rm -f ./$(DEPDIR)/dataprovider.Plo
1225 -rm -f ./$(DEPDIR)/debug.Plo
1226 -rm -f ./$(DEPDIR)/defaultkeygenerationjob.Plo
1227 -rm -f ./$(DEPDIR)/dn.Plo
1228 -rm -f ./$(DEPDIR)/importjob.Plo
1229 -rm -f ./$(DEPDIR)/job.Plo
1230 -rm -f ./$(DEPDIR)/multideletejob.Plo
1231 -rm -f ./$(DEPDIR)/qgpgme_debug.Plo
1232 -rm -f ./$(DEPDIR)/qgpgmeaddexistingsubkeyjob.Plo
1233 -rm -f ./$(DEPDIR)/qgpgmeadduseridjob.Plo
1234 -rm -f ./$(DEPDIR)/qgpgmebackend.Plo
1235 -rm -f ./$(DEPDIR)/qgpgmechangeexpiryjob.Plo
1236 -rm -f ./$(DEPDIR)/qgpgmechangeownertrustjob.Plo
1237 -rm -f ./$(DEPDIR)/qgpgmechangepasswdjob.Plo
1238 -rm -f ./$(DEPDIR)/qgpgmedecryptjob.Plo
1239 -rm -f ./$(DEPDIR)/qgpgmedecryptverifyjob.Plo
1240 -rm -f ./$(DEPDIR)/qgpgmedeletejob.Plo
1241 -rm -f ./$(DEPDIR)/qgpgmedownloadjob.Plo
1242 -rm -f ./$(DEPDIR)/qgpgmeencryptjob.Plo
1243 -rm -f ./$(DEPDIR)/qgpgmeexportjob.Plo
1244 -rm -f ./$(DEPDIR)/qgpgmegpgcardjob.Plo
1245 -rm -f ./$(DEPDIR)/qgpgmeimportfromkeyserverjob.Plo
1246 -rm -f ./$(DEPDIR)/qgpgmeimportjob.Plo
1247 -rm -f ./$(DEPDIR)/qgpgmekeyformailboxjob.Plo
1248 -rm -f ./$(DEPDIR)/qgpgmekeygenerationjob.Plo
1249 -rm -f ./$(DEPDIR)/qgpgmekeylistjob.Plo
1250 -rm -f ./$(DEPDIR)/qgpgmelistallkeysjob.Plo
1251 -rm -f ./$(DEPDIR)/qgpgmenewcryptoconfig.Plo
1252 -rm -f ./$(DEPDIR)/qgpgmequickjob.Plo
1253 -rm -f ./$(DEPDIR)/qgpgmereceivekeysjob.Plo
1254 -rm -f ./$(DEPDIR)/qgpgmerefreshkeysjob.Plo
1255 -rm -f ./$(DEPDIR)/qgpgmesignencryptjob.Plo
1256 -rm -f ./$(DEPDIR)/qgpgmesignjob.Plo
1257 -rm -f ./$(DEPDIR)/qgpgmesignkeyjob.Plo
1258 -rm -f ./$(DEPDIR)/qgpgmetofupolicyjob.Plo
1259 -rm -f ./$(DEPDIR)/qgpgmeverifydetachedjob.Plo
1260 -rm -f ./$(DEPDIR)/qgpgmeverifyopaquejob.Plo
1261 -rm -f ./$(DEPDIR)/qgpgmewkdlookupjob.Plo
1262 -rm -f ./$(DEPDIR)/qgpgmewkspublishjob.Plo
1263 -rm -f ./$(DEPDIR)/threadedjobmixin.Plo
1264 -rm -f ./$(DEPDIR)/util.Plo
1265 -rm -f ./$(DEPDIR)/wkdlookupresult.Plo
1266 -rm -f Makefile
1267 maintainer-clean-am: distclean-am maintainer-clean-generic
1268
1269 mostlyclean: mostlyclean-am
1270
1271 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
1272 mostlyclean-libtool
1273
1274 pdf: pdf-am
1275
1276 pdf-am:
1277
1278 ps: ps-am
1279
1280 ps-am:
1281
1282 uninstall-am: uninstall-camelcaseincludeHEADERS \
1283 uninstall-libLTLIBRARIES uninstall-local \
1284 uninstall-nodist_qgpgmeincludeHEADERS \
1285 uninstall-qgpgmeincludeHEADERS
1286
1287 .MAKE: all check install install-am install-exec install-strip
1288
1289 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
1290 clean-generic clean-libLTLIBRARIES clean-libtool cscopelist-am \
1291 ctags ctags-am distclean distclean-compile distclean-generic \
1292 distclean-libtool distclean-tags distdir dvi dvi-am html \
1293 html-am info info-am install install-am \
1294 install-camelcaseincludeHEADERS install-data install-data-am \
1295 install-data-local install-dvi install-dvi-am install-exec \
1296 install-exec-am install-html install-html-am install-info \
1297 install-info-am install-libLTLIBRARIES install-man \
1298 install-nodist_qgpgmeincludeHEADERS install-pdf install-pdf-am \
1299 install-ps install-ps-am install-qgpgmeincludeHEADERS \
1300 install-strip installcheck installcheck-am installdirs \
1301 maintainer-clean maintainer-clean-generic mostlyclean \
1302 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
1303 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \
1304 uninstall-camelcaseincludeHEADERS uninstall-libLTLIBRARIES \
1305 uninstall-local uninstall-nodist_qgpgmeincludeHEADERS \
1306 uninstall-qgpgmeincludeHEADERS
1307
1308 .PRECIOUS: Makefile
1309
1310
1311 @HAVE_W32_SYSTEM_TRUE@QGpgmeConfig.cmake: QGpgmeConfig-w32.cmake.in
1312 @HAVE_W32_SYSTEM_TRUE@ sed -e 's|[@]resolved_bindir@|$(bindir)|g' < "$<" | \
1313 @HAVE_W32_SYSTEM_TRUE@ sed -e 's|[@]resolved_libdir@|$(libdir)|g' | \
1314 @HAVE_W32_SYSTEM_TRUE@ sed -e 's|[@]resolved_includedir@|$(includedir)|g' > $@
1315 @HAVE_W32_SYSTEM_FALSE@QGpgmeConfig.cmake: QGpgmeConfig.cmake.in
1316 @HAVE_W32_SYSTEM_FALSE@ sed -e 's|[@]resolved_libdir@|$(libdir)|g' < "$<" | \
1317 @HAVE_W32_SYSTEM_FALSE@ sed -e 's|[@]libsuffix@|$(libsuffix)|g' | \
1318 @HAVE_W32_SYSTEM_FALSE@ sed -e 's|[@]resolved_includedir@|$(includedir)|g' > $@
1319
1320 $(camelcase_headers): Makefile.am
1321 echo -n "#include \"qgpgme/" > "$@"
1322 echo -n "$@" | tr '[:upper:]' '[:lower:]' >> "$@"
1323 echo ".h\"" >> "$@"
1324
1325 install-cmake-files: QGpgmeConfig.cmake QGpgmeConfigVersion.cmake
1326 -$(INSTALL) -d $(DESTDIR)$(libdir)/cmake/QGpgme
1327 $(INSTALL) -m 644 QGpgmeConfig.cmake \
1328 $(DESTDIR)$(libdir)/cmake/QGpgme/QGpgmeConfig.cmake
1329 $(INSTALL) -m 644 QGpgmeConfigVersion.cmake \
1330 $(DESTDIR)$(libdir)/cmake/QGpgme/QGpgmeConfigVersion.cmake
1331
1332 uninstall-cmake-files:
1333 -rm $(DESTDIR)$(libdir)/cmake/QGpgme/QGpgmeConfigVersion.cmake
1334 -rm $(DESTDIR)$(libdir)/cmake/QGpgme/QGpgmeConfig.cmake
1335 -rmdir $(DESTDIR)$(libdir)/cmake/QGpgme/
1336
1337 install-data-local: install-cmake-files
1338
1339 uninstall-local: uninstall-cmake-files
1340
1341 .h.moc:
1342 $(MOC) `test -f '$<' || echo '$(srcdir)/'`$< -o $@
1343
1344 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1345 # Otherwise a system limit (for SysV at least) may be exceeded.
1346 .NOEXPORT:
0 #include "qgpgme/multideletejob.h"
0 #include "qgpgme/protocol.h"
0 #include "qgpgme/qgpgmenewcryptoconfig.h"
0 #include "qgpgme/quickjob.h"
0 #include "qgpgme/receivekeysjob.h"
0 #include "qgpgme/refreshkeysjob.h"
0 #include "qgpgme/signencryptjob.h"
0 #include "qgpgme/signjob.h"
0 #include "qgpgme/signkeyjob.h"
0 #include "qgpgme/specialjob.h"
0 #include "qgpgme/tofupolicyjob.h"
0 #include "qgpgme/verifydetachedjob.h"
0 #include "qgpgme/verifyopaquejob.h"
0 #include "qgpgme/wkdlookupjob.h"
0 #include "qgpgme/wkdlookupresult.h"
0 #include "qgpgme/wkspublishjob.h"
0 /*
1 addexistingsubkeyjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_ADDEXISTINGSUBKEYJOB_H__
34 #define __QGPGME_ADDEXISTINGSUBKEYJOB_H__
35
36 #include "job.h"
37 #include "qgpgme_export.h"
38
39 class QString;
40
41 namespace GpgME
42 {
43 class Error;
44 class Key;
45 class Subkey;
46 }
47
48 namespace QGpgME
49 {
50
51 class QGPGME_EXPORT AddExistingSubkeyJob : public Job
52 {
53 Q_OBJECT
54 protected:
55 explicit AddExistingSubkeyJob(QObject *parent);
56
57 public:
58 ~AddExistingSubkeyJob();
59
60 /**
61 Starts the operation. \a key is the key to add the subkey \a subkey to.
62
63 The job deletes itself after it has completed the operation.
64 */
65 virtual GpgME::Error start(const GpgME::Key &key, const GpgME::Subkey &subkey) = 0;
66
67 /**
68 Runs the operation. \a key is the key to add the subkey \a subkey to.
69 */
70 virtual GpgME::Error exec(const GpgME::Key &key, const GpgME::Subkey &subkey) = 0;
71
72 Q_SIGNALS:
73 void result(const GpgME::Error &result, const QString &auditLogAsHtml = {}, const GpgME::Error &auditLogError = {});
74 };
75
76 }
77
78 #endif // __QGPGME_ADDEXISTINGSUBKEYJOB_H__
0 /*
1 changeexpiryjob.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifdef HAVE_CONFIG_H
34 #include "config.h"
35 #endif
36
37 #include "changeexpiryjob.h"
38 #include "job_p.h"
39
40 #include <context.h>
41
42 using namespace GpgME;
43 using namespace QGpgME;
44
45 namespace
46 {
47 struct ChangeExpiryJobPrivate : public JobPrivate
48 {
49 ChangeExpiryJobPrivate()
50 {
51 }
52
53 ~ChangeExpiryJobPrivate() override = default;
54
55 ChangeExpiryJob::Options m_options = ChangeExpiryJob::Default;
56 };
57 }
58
59 void ChangeExpiryJob::setOptions(ChangeExpiryJob::Options options)
60 {
61 auto d = jobPrivate<ChangeExpiryJobPrivate>(this);
62 d->m_options = options;
63 }
64
65 ChangeExpiryJob::Options ChangeExpiryJob::options() const
66 {
67 auto d = jobPrivate<ChangeExpiryJobPrivate>(this);
68 return d->m_options;
69 }
70
71 /* For ABI compat not pure virtual. */
72 Error ChangeExpiryJob::start(const Key &, const QDateTime &, const std::vector<Subkey> &)
73 {
74 return {};
75 }
7070 class QGPGME_EXPORT ChangeExpiryJob : public Job
7171 {
7272 Q_OBJECT
73 public:
74 enum Option {
75 Default = 0x00,
76 UpdatePrimaryKey = 0x01,
77 UpdateAllSubkeys = 0x02,
78 };
79 Q_DECLARE_FLAGS(Options, Option)
80
7381 protected:
7482 explicit ChangeExpiryJob(QObject *parent);
7583 public:
7684 ~ChangeExpiryJob();
85
86 void setOptions(Options options);
87 Options options() const;
7788
7889 /**
7990 Starts the change-expiry operation. \a key is the key to change
96107 void result(const GpgME::Error &result, const QString &auditLogAsHtml = QString(), const GpgME::Error &auditLogError = GpgME::Error());
97108 };
98109
110 Q_DECLARE_OPERATORS_FOR_FLAGS(ChangeExpiryJob::Options)
111
99112 }
100113
101114 #endif // __KLEO_CHANGEEXPIRYJOB_H__
4343 return entry->stringValueList();
4444 }
4545
46 QVariant CryptoConfigEntry::defaultValue() const
47 {
48 const QGpgMENewCryptoConfigEntry *entry = dynamic_cast <const QGpgMENewCryptoConfigEntry*>(this);
49 if (!entry) {
50 return {};
51 }
52 return entry->defaultValue();
53 }
54
4655 QGpgME::CryptoConfigEntry *CryptoConfig::entry(const QString &componentName, const QString &entryName) const
4756 {
4857 const CryptoConfigComponent *comp = component(componentName);
4242 #include <QUrl>
4343
4444 #include <vector>
45
46 class QVariant;
4547
4648 /* Start reading this file from the bottom up :) */
4749
257259 * @return a stringValueList.
258260 */
259261 QStringList stringValueList() const;
262
263 /**
264 * Return the default value as a variant (available for all argtypes).
265 */
266 QVariant defaultValue() const;
260267 };
261268
262269 /**
0 /*
1 importjob.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifdef HAVE_CONFIG_H
34 #include "config.h"
35 #endif
36
37 #include "importjob.h"
38 #include "job_p.h"
39
40 #include <context.h>
41
42 using namespace GpgME;
43 using namespace QGpgME;
44
45 namespace
46 {
47 struct ImportJobPrivate : public JobPrivate
48 {
49 ImportJobPrivate()
50 {
51 }
52
53 ~ImportJobPrivate() override = default;
54
55 QString m_importFilter;
56 Key::Origin m_keyOrigin = Key::OriginUnknown;
57 QString m_keyOriginUrl;
58 };
59 }
60
61 void QGpgME::ImportJob::setImportFilter(const QString &filter)
62 {
63 const auto d = jobPrivate<ImportJobPrivate>(this);
64 d->m_importFilter = filter;
65 }
66
67 QString QGpgME::ImportJob::importFilter() const
68 {
69 const auto d = jobPrivate<ImportJobPrivate>(this);
70 return d->m_importFilter;
71 }
72
73 void ImportJob::setKeyOrigin(GpgME::Key::Origin origin, const QString &url)
74 {
75 const auto d = jobPrivate<ImportJobPrivate>(this);
76 d->m_keyOrigin = origin;
77 d->m_keyOriginUrl = url;
78 }
79
80 GpgME::Key::Origin ImportJob::keyOrigin() const
81 {
82 const auto d = jobPrivate<ImportJobPrivate>(this);
83 return d->m_keyOrigin;
84 }
85
86 QString ImportJob::keyOriginUrl() const
87 {
88 const auto d = jobPrivate<ImportJobPrivate>(this);
89 return d->m_keyOriginUrl;
90 }
3737 #include "abstractimportjob.h"
3838 #include "qgpgme_export.h"
3939
40 #include <QtCore/QByteArray>
40 #ifdef BUILDING_QGPGME
41 # include <key.h>
42 #else
43 # include <gpgme++/key.h>
44 #endif
4145
4246 namespace GpgME
4347 {
6771 protected:
6872 explicit ImportJob(QObject *parent);
6973 public:
70 ~ImportJob();
74 ~ImportJob() override;
75
76 void setImportFilter(const QString &filter);
77 QString importFilter() const;
78
79 void setKeyOrigin(GpgME::Key::Origin origin, const QString &url = {});
80 GpgME::Key::Origin keyOrigin() const;
81 QString keyOriginUrl() const;
7182
7283 /**
7384 Starts the importing operation. \a keyData contains the data to
44 Copyright (c) 2004,2005 Klarälvdalens Datakonsult AB
55 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
66 Software engineering by Intevation GmbH
7 Copyright (c) 2021 g10 Code GmbH
8 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
79
810 QGpgME is free software; you can redistribute it and/or
911 modify it under the terms of the GNU General Public License as
3638 #endif
3739
3840 #include "job.h"
41 #include "job_p.h"
3942
4043 #include "keylistjob.h"
4144 #include "listallkeysjob.h"
5760 #include "downloadjob.h"
5861 #include "deletejob.h"
5962 #include "refreshkeysjob.h"
63 #include "addexistingsubkeyjob.h"
6064 #include "adduseridjob.h"
6165 #include "specialjob.h"
6266 #include "keyformailboxjob.h"
67 #include "wkdlookupjob.h"
6368 #include "wkspublishjob.h"
6469 #include "tofupolicyjob.h"
6570 #include "threadedjobmixin.h"
6671 #include "quickjob.h"
6772 #include "gpgcardjob.h"
73 #include "receivekeysjob.h"
6874
6975 #include <QCoreApplication>
7076 #include <QDebug>
7177
7278 #include <gpg-error.h>
79
80 #include <unordered_map>
81
82 namespace
83 {
84 typedef std::unordered_map<const QGpgME::Job*, std::unique_ptr<QGpgME::JobPrivate>> JobPrivateHash;
85 Q_GLOBAL_STATIC(JobPrivateHash, d_func)
86 }
87
88 void QGpgME::setJobPrivate(const Job *job, std::unique_ptr<JobPrivate> d)
89 {
90 auto &ref = d_func()->operator[](job);
91 ref = std::move(d);
92 }
93
94 QGpgME::JobPrivate *QGpgME::getJobPrivate(const Job *job)
95 {
96 return d_func()->operator[](job).get();
97 }
7398
7499 QGpgME::Job::Job(QObject *parent)
75100 : QObject(parent)
81106
82107 QGpgME::Job::~Job()
83108 {
109 ::d_func()->erase(this);
84110 }
85111
86112 QString QGpgME::Job::auditLogAsHtml() const
128154 make_job_subclass(AbstractImportJob)
129155 make_job_subclass_ext(ImportJob, AbstractImportJob)
130156 make_job_subclass_ext(ImportFromKeyserverJob, AbstractImportJob)
157 make_job_subclass_ext(ReceiveKeysJob, AbstractImportJob)
131158 make_job_subclass(ExportJob)
132159 make_job_subclass(ChangeExpiryJob)
133160 make_job_subclass(ChangeOwnerTrustJob)
135162 make_job_subclass(DownloadJob)
136163 make_job_subclass(DeleteJob)
137164 make_job_subclass(RefreshKeysJob)
165 make_job_subclass(AddExistingSubkeyJob)
138166 make_job_subclass(AddUserIDJob)
139167 make_job_subclass(SpecialJob)
140168 make_job_subclass(KeyForMailboxJob)
169 make_job_subclass(WKDLookupJob)
141170 make_job_subclass(WKSPublishJob)
142171 make_job_subclass(TofuPolicyJob)
143172 make_job_subclass(QuickJob)
168197 #include "downloadjob.moc"
169198 #include "deletejob.moc"
170199 #include "refreshkeysjob.moc"
200 #include "addexistingsubkeyjob.moc"
171201 #include "adduseridjob.moc"
172202 #include "specialjob.moc"
173203 #include "keyformailboxjob.moc"
204 #include "wkdlookupjob.moc"
174205 #include "wkspublishjob.moc"
175206 #include "tofupolicyjob.moc"
176207 #include "quickjob.moc"
177208 #include "gpgcardjob.moc"
209 #include "receivekeysjob.moc"
0 /*
1 job_p.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_JOB_P_H__
34 #define __QGPGME_JOB_P_H__
35
36 #include "job.h"
37
38 #include <memory>
39
40 namespace QGpgME
41 {
42
43 // Base class for pimpl classes for Job subclasses
44 class JobPrivate
45 {
46 public:
47 virtual ~JobPrivate() {}
48 };
49
50 // Setter and getters for the externally stored pimpl instances of jobs
51 // BCI: Add a real d-pointer to Job
52 void setJobPrivate(const Job *job, std::unique_ptr<JobPrivate> d);
53
54 JobPrivate *getJobPrivate(const Job *job);
55
56 template <typename T>
57 static T *jobPrivate(const Job *job) {
58 auto d = getJobPrivate(job);
59 if (!d) {
60 std::unique_ptr<T> ref{new T};
61 d = ref.get();
62 setJobPrivate(job, std::move(ref));
63 }
64 return dynamic_cast<T *>(d);
65 }
66
67 }
68
69 #endif // __QGPGME_JOB_P_H__
3939 #include "qgpgme_export.h"
4040
4141 namespace QGpgME {
42 class AddExistingSubkeyJob;
4243 class CryptoConfig;
4344 class KeyListJob;
4445 class ListAllKeysJob;
6364 class AddUserIDJob;
6465 class SpecialJob;
6566 class KeyForMailboxJob;
67 class WKDLookupJob;
6668 class WKSPublishJob;
6769 class TofuPolicyJob;
6870 class QuickJob;
6971 class GpgCardJob;
72 class ReceiveKeysJob;
7073
7174 /** The main entry point for QGpgME Comes in OpenPGP and SMIME(CMS) flavors.
7275 *
9194 * {
9295 * // keys and resuls can now be used.
9396 * });
97 * job->start({QStringLiteral("alfa@example.net")}, false);
9498 * \endcode
9599 *
96100 * \code
122126 virtual KeyGenerationJob *keyGenerationJob() const = 0;
123127 virtual ImportJob *importJob() const = 0;
124128 virtual ImportFromKeyserverJob *importFromKeyserverJob() const = 0;
129 virtual ReceiveKeysJob *receiveKeysJob() const = 0;
125130 virtual ExportJob *publicKeyExportJob(bool armor = false) const = 0;
126 // @param charset the encoding of the passphrase in the exported file
127 virtual ExportJob *secretKeyExportJob(bool armor = false, const QString &charset = QString()) const = 0;
131 // the second parameter is ignored; the passphrase in the exported file is always utf-8 encoded
132 virtual ExportJob *secretKeyExportJob(bool armor = false, const QString & = QString()) const = 0;
133 virtual ExportJob *secretSubkeyExportJob(bool armor = false) const = 0;
128134 virtual DownloadJob *downloadJob(bool armor = false) const = 0;
129135 virtual DeleteJob *deleteJob() const = 0;
130136 virtual SignEncryptJob *signEncryptJob(bool armor = false, bool textMode = false) const = 0;
134140 virtual SignKeyJob *signKeyJob() const = 0;
135141 virtual ChangePasswdJob *changePasswdJob() const = 0;
136142 virtual ChangeOwnerTrustJob *changeOwnerTrustJob() const = 0;
143 virtual AddExistingSubkeyJob *addExistingSubkeyJob() const = 0;
137144 virtual AddUserIDJob *addUserIDJob() const = 0;
138145 virtual SpecialJob *specialJob(const char *type, const QMap<QString, QVariant> &args) const = 0;
139146
153160 /** Find the best key to use for a mailbox. */
154161 virtual KeyForMailboxJob *keyForMailboxJob() const = 0;
155162
163 /** This job looks up a key via WKD without importing it. */
164 virtual WKDLookupJob *wkdLookupJob() const = 0;
165
156166 /** A Job for interacting with gnupg's wks tools. */
157167 virtual WKSPublishJob *wksPublishJob() const = 0;
158168
44 Copyright (c) 2004,2005 Klarälvdalens Datakonsult AB
55 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
66 Software engineering by Intevation GmbH
7 Copyright (c) 2022 by g10 Code GmbH
8 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
79
810 QGpgME is free software; you can redistribute it and/or
911 modify it under the terms of the GNU General Public License as
4143 #include "qgpgmedecryptverifyjob.h"
4244 #include "qgpgmerefreshkeysjob.h"
4345 #include "qgpgmedeletejob.h"
44 #include "qgpgmesecretkeyexportjob.h"
4546 #include "qgpgmedownloadjob.h"
4647 #include "qgpgmesignencryptjob.h"
4748 #include "qgpgmeencryptjob.h"
5556 #include "qgpgmechangeexpiryjob.h"
5657 #include "qgpgmechangeownertrustjob.h"
5758 #include "qgpgmechangepasswdjob.h"
59 #include "qgpgmeaddexistingsubkeyjob.h"
5860 #include "qgpgmeadduseridjob.h"
5961 #include "qgpgmekeyformailboxjob.h"
62 #include "qgpgmewkdlookupjob.h"
6063 #include "qgpgmewkspublishjob.h"
6164 #include "qgpgmetofupolicyjob.h"
6265 #include "qgpgmequickjob.h"
66 #include "qgpgmereceivekeysjob.h"
6367
6468 namespace
6569 {
229233 return new QGpgME::QGpgMEImportFromKeyserverJob(context);
230234 }
231235
236 QGpgME::ReceiveKeysJob *receiveKeysJob() const override
237 {
238 if (mProtocol != GpgME::OpenPGP) {
239 return nullptr;
240 }
241
242 GpgME::Context *context = GpgME::Context::createForProtocol(mProtocol);
243 if (!context) {
244 return nullptr;
245 }
246 return new QGpgME::QGpgMEReceiveKeysJob{context};
247 }
248
232249 QGpgME::ExportJob *publicKeyExportJob(bool armor) const Q_DECL_OVERRIDE
233250 {
234251 GpgME::Context *context = GpgME::Context::createForProtocol(mProtocol);
240257 return new QGpgME::QGpgMEExportJob(context);
241258 }
242259
243 QGpgME::ExportJob *secretKeyExportJob(bool armor, const QString &charset) const Q_DECL_OVERRIDE
244 {
245 if (mProtocol != GpgME::CMS) { // fixme: add support for gpg, too
246 return nullptr;
247 }
248
249 // this operation is not supported by gpgme, so we have to call gpgsm ourselves:
250 return new QGpgME::QGpgMESecretKeyExportJob(armor, charset);
260 QGpgME::ExportJob *secretKeyExportJob(bool armor, const QString &) const Q_DECL_OVERRIDE
261 {
262 GpgME::Context *context = GpgME::Context::createForProtocol(mProtocol);
263 if (!context) {
264 return nullptr;
265 }
266
267 context->setArmor(armor);
268 return new QGpgME::QGpgMEExportJob(context, GpgME::Context::ExportSecret);
269 }
270
271 QGpgME::ExportJob *secretSubkeyExportJob(bool armor) const Q_DECL_OVERRIDE
272 {
273 GpgME::Context *context = GpgME::Context::createForProtocol(mProtocol);
274 if (!context) {
275 return nullptr;
276 }
277
278 context->setArmor(armor);
279 return new QGpgME::QGpgMEExportJob(context, GpgME::Context::ExportSecretSubkey);
251280 }
252281
253282 QGpgME::RefreshKeysJob *refreshKeysJob() const Q_DECL_OVERRIDE
356385 return new QGpgME::QGpgMEChangeOwnerTrustJob(context);
357386 }
358387
388 QGpgME:: AddExistingSubkeyJob *addExistingSubkeyJob() const override
389 {
390 if (mProtocol != GpgME::OpenPGP) {
391 return nullptr; // only supported by gpg
392 }
393
394 GpgME::Context *context = GpgME::Context::createForProtocol(mProtocol);
395 if (!context) {
396 return nullptr;
397 }
398 return new QGpgME::QGpgMEAddExistingSubkeyJob{context};
399 }
400
359401 QGpgME::AddUserIDJob *addUserIDJob() const Q_DECL_OVERRIDE
360402 {
361403 if (mProtocol != GpgME::OpenPGP) {
391433 return new QGpgME::QGpgMEKeyForMailboxJob(context);
392434 }
393435
436 QGpgME::WKDLookupJob *wkdLookupJob() const Q_DECL_OVERRIDE
437 {
438 if (mProtocol != GpgME::OpenPGP) {
439 return nullptr;
440 }
441 auto context = GpgME::Context::createForEngine(GpgME::AssuanEngine);
442 if (!context) {
443 return nullptr;
444 }
445 return new QGpgME::QGpgMEWKDLookupJob(context.release());
446 }
447
394448 QGpgME::WKSPublishJob *wksPublishJob() const Q_DECL_OVERRIDE
395449 {
396450 if (mProtocol != GpgME::OpenPGP) {
0 /*
1 qgpgmeaddexistingsubkeyjob.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifdef HAVE_CONFIG_H
34 #include "config.h"
35 #endif
36
37 #include "qgpgmeaddexistingsubkeyjob.h"
38
39 #include "dataprovider.h"
40
41 #include <QDateTime>
42
43 #include "context.h"
44 #include "data.h"
45 #include "gpgaddexistingsubkeyeditinteractor.h"
46 #include "key.h"
47
48 #include <gpg-error.h>
49
50 using namespace QGpgME;
51 using namespace GpgME;
52
53 QGpgMEAddExistingSubkeyJob::QGpgMEAddExistingSubkeyJob(Context *context)
54 : mixin_type{context}
55 {
56 lateInitialization();
57 }
58
59 QGpgMEAddExistingSubkeyJob::~QGpgMEAddExistingSubkeyJob() = default;
60
61 static QGpgMEAddExistingSubkeyJob::result_type add_subkey(Context *ctx, const Key &key, const Subkey &subkey)
62 {
63 std::unique_ptr<GpgAddExistingSubkeyEditInteractor> interactor{new GpgAddExistingSubkeyEditInteractor{subkey.keyGrip()}};
64
65 if (!subkey.neverExpires()) {
66 const auto expiry = QDateTime::fromSecsSinceEpoch(subkey.expirationTime(), Qt::UTC).toString(u"yyyyMMdd'T'hhmmss").toStdString();
67 interactor->setExpiry(expiry);
68 }
69
70 QGpgME::QByteArrayDataProvider dp;
71 Data data(&dp);
72 assert(!data.isNull());
73
74 ctx->setFlag("extended-edit", "1");
75
76 const Error err = ctx->edit(key, std::unique_ptr<EditInteractor>(interactor.release()), data);
77 Error ae;
78 const QString log = _detail::audit_log_as_html(ctx, ae);
79 return std::make_tuple(err, log, ae);
80 }
81
82 Error QGpgMEAddExistingSubkeyJob::start(const GpgME::Key &key, const GpgME::Subkey &subkey)
83 {
84 run(std::bind(&add_subkey, std::placeholders::_1, key, subkey));
85 return {};
86 }
87
88 Error QGpgMEAddExistingSubkeyJob::exec(const GpgME::Key &key, const GpgME::Subkey &subkey)
89 {
90 const result_type r = add_subkey(context(), key, subkey);
91 resultHook(r);
92 return std::get<0>(r);
93 }
94
95 #include "qgpgmeaddexistingsubkeyjob.moc"
0 /*
1 qgpgmeaddexistingsubkeyjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_QGPGMEADDEXISTINGSUBKEYJOB_H__
34 #define __QGPGME_QGPGMEADDEXISTINGSUBKEYJOB_H__
35
36 #include "threadedjobmixin.h"
37 #include "addexistingsubkeyjob.h"
38
39 namespace QGpgME
40 {
41
42 class QGpgMEAddExistingSubkeyJob
43 #ifdef Q_MOC_RUN
44 : public AddExistingSubkeyJob
45 #else
46 : public _detail::ThreadedJobMixin<AddExistingSubkeyJob>
47 #endif
48 {
49 Q_OBJECT
50 #ifdef Q_MOC_RUN
51 public Q_SLOTS:
52 void slotFinished();
53 #endif
54 public:
55 explicit QGpgMEAddExistingSubkeyJob(GpgME::Context *context);
56 ~QGpgMEAddExistingSubkeyJob();
57
58 /* from AddExistingSubkeyJob */
59 GpgME::Error start(const GpgME::Key &key, const GpgME::Subkey &subkey) override;
60
61 /* from AddExistingSubkeyJob */
62 GpgME::Error exec(const GpgME::Key &key, const GpgME::Subkey &subkey) override;
63 };
64
65 }
66
67 #endif // __QGPGME_QGPGMEADDEXISTINGSUBKEYJOB_H__
44 Copyright (c) 2008 Klarälvdalens Datakonsult AB
55 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
66 Software engineering by Intevation GmbH
7 Copyright (c) 2021 g10 Code GmbH
8 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
79
810 QGpgME is free software; you can redistribute it and/or
911 modify it under the terms of the GNU General Public License as
5456 QGpgMEChangeExpiryJob::~QGpgMEChangeExpiryJob() {}
5557
5658 static QGpgMEChangeExpiryJob::result_type change_expiry(Context *ctx, const Key &key, const QDateTime &expiry,
57 const std::vector<Subkey> &subkeys)
59 const std::vector<Subkey> &subkeys, ChangeExpiryJob::Options options)
5860 {
5961 // convert expiry to "seconds from now"; use 1 second from now if expiry is before the current datetime
6062 const unsigned long expires = expiry.isValid()
6163 ? std::max<qint64>(QDateTime::currentDateTime().secsTo(expiry), 1)
6264 : 0;
6365
64 auto err = ctx->setExpire(key, expires, subkeys);
66 // updating the expiration date of the primary key and the subkeys needs to be done in two steps
67 // because --quick-set-expire does not support updating the expiration date of both at the same time
68
69 if (subkeys.empty() || (options & ChangeExpiryJob::UpdatePrimaryKey)) {
70 // update the expiration date of the primary key
71 auto err = ctx->setExpire(key, expires);
72 if (err) {
73 return std::make_tuple(err, QString(), Error());
74 }
75 }
76
77 GpgME::Error err;
78 if (!subkeys.empty()) {
79 // update the expiration date of the specified subkeys
80 err = ctx->setExpire(key, expires, subkeys);
81 } else if (options & ChangeExpiryJob::UpdateAllSubkeys) {
82 // update the expiration date of all subkeys
83 err = ctx->setExpire(key, expires, {}, Context::SetExpireAllSubkeys);
84 }
6585 return std::make_tuple(err, QString(), Error());
6686 }
6787
7292
7393 Error QGpgMEChangeExpiryJob::start(const Key &key, const QDateTime &expiry, const std::vector<Subkey> &subkeys)
7494 {
75 run(std::bind(&change_expiry, std::placeholders::_1, key, expiry, subkeys));
76 return Error();
77 }
78
79 /* For ABI compat not pure virtual. */
80 Error ChangeExpiryJob::start(const Key &, const QDateTime &, const std::vector<Subkey> &)
81 {
95 run(std::bind(&change_expiry, std::placeholders::_1, key, expiry, subkeys, options()));
8296 return Error();
8397 }
8498
00 /*
1 qgpgmechangeexpiryjob.h
1 qgpgmechangeownertrustjob.h
22
33 This file is part of qgpgme, the Qt API binding for gpgme
44 Copyright (c) 2008 Klarälvdalens Datakonsult AB
44 Copyright (c) 2004,2008 Klarälvdalens Datakonsult AB
55 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
66 Software engineering by Intevation GmbH
7 Copyright (c) 2022 by g10 Code GmbH
8 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
79
810 QGpgME is free software; you can redistribute it and/or
911 modify it under the terms of the GNU General Public License as
5153 using namespace GpgME;
5254
5355 QGpgMEExportJob::QGpgMEExportJob(Context *context)
54 : mixin_type(context),
55 m_flags(0)
56 : QGpgMEExportJob{context, 0}
57 {
58 }
59
60 QGpgMEExportJob::QGpgMEExportJob(Context *context, unsigned int forcedMode)
61 : mixin_type{context}
62 , m_exportMode{forcedMode}
63 , m_additionalExportModeFlags{0}
5664 {
5765 lateInitialization();
5866 }
5967
60 QGpgMEExportJob::~QGpgMEExportJob() {}
68 QGpgMEExportJob::~QGpgMEExportJob() = default;
6169
62 static QGpgMEExportJob::result_type export_qba(Context *ctx, const QStringList &patterns, unsigned int flags)
70 static QGpgMEExportJob::result_type export_qba(Context *ctx, const QStringList &patterns, unsigned int mode)
6371 {
64
6572 const _detail::PatternConverter pc(patterns);
6673
6774 QGpgME::QByteArrayDataProvider dp;
6875 Data data(&dp);
6976
70 const Error err = ctx->exportPublicKeys(pc.patterns(), data, flags);
77 const Error err = ctx->exportKeys(pc.patterns(), data, mode);
7178 Error ae;
7279 const QString log = _detail::audit_log_as_html(ctx, ae);
7380 return std::make_tuple(err, dp.data(), log, ae);
7582
7683 Error QGpgMEExportJob::start(const QStringList &patterns)
7784 {
78 run(std::bind(&export_qba, std::placeholders::_1, patterns, m_flags));
85 auto mode = m_exportMode | m_additionalExportModeFlags;
86 run(std::bind(&export_qba, std::placeholders::_1, patterns, mode));
7987 return Error();
8088 }
8189
8290 void QGpgMEExportJob::setExportFlags(unsigned int flags)
8391 {
84 m_flags = flags;
92 m_additionalExportModeFlags = flags;
8593 }
8694
8795 /* For ABI compat not pure virtual. */
44 Copyright (c) 2004,2008 Klarälvdalens Datakonsult AB
55 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
66 Software engineering by Intevation GmbH
7 Copyright (c) 2022 by g10 Code GmbH
8 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
79
810 QGpgME is free software; you can redistribute it and/or
911 modify it under the terms of the GNU General Public License as
5557 #endif
5658 public:
5759 explicit QGpgMEExportJob(GpgME::Context *context);
58 ~QGpgMEExportJob();
60 // Creates an export job with forced export mode @p exportMode. The
61 // export mode flags set with @p exportMode cannot be overridden with
62 // setExportFlags.
63 explicit QGpgMEExportJob(GpgME::Context *context, unsigned int exportMode);
64 ~QGpgMEExportJob() Q_DECL_OVERRIDE;
5965
6066 /* from ExportJob */
61 void setExportFlags (unsigned int flags) Q_DECL_OVERRIDE;
67 void setExportFlags(unsigned int flags) Q_DECL_OVERRIDE;
6268
6369 /* from ExportJob */
6470 GpgME::Error start(const QStringList &patterns) Q_DECL_OVERRIDE;
71
6572 private:
66 unsigned int m_flags;
73 unsigned int m_exportMode;
74 unsigned int m_additionalExportModeFlags;
6775 };
6876
6977 }
3939
4040 #include "dataprovider.h"
4141
42 #include "context.h"
43 #include "data.h"
44 #include "key.h"
45
46 #include <cassert>
42 #include <context.h>
43 #include <data.h>
44 #include <key.h>
4745
4846 using namespace QGpgME;
4947 using namespace GpgME;
5452 lateInitialization();
5553 }
5654
57 QGpgMEImportJob::~QGpgMEImportJob() {}
55 QGpgMEImportJob::~QGpgMEImportJob() = default;
5856
59 static QGpgMEImportJob::result_type import_qba(Context *ctx, const QByteArray &certData)
57 static const char *originToString(Key::Origin origin)
6058 {
59 static const std::map<Key::Origin, const char *> mapping = {
60 { Key::OriginUnknown, "unknown" },
61 { Key::OriginKS, "ks" },
62 { Key::OriginDane, "dane" },
63 { Key::OriginWKD, "wkd" },
64 { Key::OriginURL, "url" },
65 { Key::OriginFile, "file" },
66 { Key::OriginSelf, "self" },
67 };
68 const auto it = mapping.find(origin);
69 return (it != std::end(mapping)) ? it->second : nullptr;
70 }
71
72 static QGpgMEImportJob::result_type import_qba(Context *ctx, const QByteArray &certData, const QString &importFilter,
73 Key::Origin keyOrigin, const QString &keyOriginUrl)
74 {
75 if (!importFilter.isEmpty()) {
76 ctx->setFlag("import-filter", importFilter.toStdString().c_str());
77 }
78 if (keyOrigin != Key::OriginUnknown) {
79 if (const auto origin = originToString(keyOrigin)) {
80 std::string value{origin};
81 if (!keyOriginUrl.isEmpty()) {
82 value += ",";
83 value += keyOriginUrl.toStdString();
84 }
85 ctx->setFlag("key-origin", value.c_str());
86 }
87 }
88
6189 QGpgME::QByteArrayDataProvider dp(certData);
6290 Data data(&dp);
6391
64 const ImportResult res = ctx->importKeys(data);
92 ImportResult res = ctx->importKeys(data);
93 // HACK: If the import failed with an error, then check if res.imports()
94 // contains only import statuses with "bad passphrase" error; if yes, this
95 // means that the user probably entered a wrong password to decrypt an
96 // encrypted key for import. In this case, return a result with "bad
97 // passphrase" error instead of the original error.
98 // We check if all import statuses instead of any import status has a
99 // "bad passphrase" error to avoid breaking imports that partially worked.
100 // See https://dev.gnupg.org/T5713.
101 const auto imports = res.imports();
102 if (res.error() && !imports.empty()
103 && std::all_of(std::begin(imports), std::end(imports),
104 [](const Import &import) {
105 return import.error().code() == GPG_ERR_BAD_PASSPHRASE;
106 })) {
107 res = ImportResult{Error{GPG_ERR_BAD_PASSPHRASE}};
108 }
65109 Error ae;
66110 const QString log = _detail::audit_log_as_html(ctx, ae);
67111 return std::make_tuple(res, log, ae);
69113
70114 Error QGpgMEImportJob::start(const QByteArray &certData)
71115 {
72 run(std::bind(&import_qba, std::placeholders::_1, certData));
116 run(std::bind(&import_qba, std::placeholders::_1, certData, importFilter(), keyOrigin(), keyOriginUrl()));
73117 return Error();
74118 }
75119
76120 GpgME::ImportResult QGpgME::QGpgMEImportJob::exec(const QByteArray &keyData)
77121 {
78 const result_type r = import_qba(context(), keyData);
122 const result_type r = import_qba(context(), keyData, importFilter(), keyOrigin(), keyOriginUrl());
79123 resultHook(r);
80124 return mResult;
81125 }
4242
4343 #include <QFile>
4444 #include <QDir>
45 #include <QList>
4546
4647 #include "global.h"
4748 #include "error.h"
709710 return m_option.dirty();
710711 }
711712
713 QVariant QGpgMENewCryptoConfigEntry::defaultValue() const
714 {
715 const auto defaultValue = m_option.defaultValue();
716 if (defaultValue.isNull() || defaultValue.numElements() == 0) {
717 return {};
718 }
719 if (defaultValue.numElements() == 1) {
720 switch (m_option.alternateType()) {
721 case NoType:
722 return QVariant{defaultValue.boolValue()};
723 case StringType:
724 return QVariant{QString::fromUtf8(defaultValue.stringValue())};
725 case IntegerType:
726 return QVariant{defaultValue.intValue()};
727 case UnsignedIntegerType:
728 return QVariant{defaultValue.uintValue()};
729 default:
730 // alternateType should always be one of the above four types
731 qCWarning(QGPGME_LOG) << __func__ << ": unsupported alternateType" << m_option.alternateType();
732 }
733 } else {
734 QList<QVariant> list;
735 switch (m_option.alternateType()) {
736 case StringType: {
737 const auto values = defaultValue.stringValues();
738 std::transform(std::begin(values), std::end(values), std::back_inserter(list),
739 [] (const char *value) { return QVariant{QString::fromUtf8(value)}; });
740 break;
741 }
742 case IntegerType: {
743 const auto values = defaultValue.intValues();
744 std::transform(std::begin(values), std::end(values), std::back_inserter(list),
745 [] (int value) { return QVariant{value}; });
746 break;
747 }
748 case UnsignedIntegerType: {
749 const auto values = defaultValue.uintValues();
750 std::transform(std::begin(values), std::end(values), std::back_inserter(list),
751 [] (unsigned int value) { return QVariant{value}; });
752 break;
753 }
754 default:
755 // alternateType should always be one of the above four types
756 qCWarning(QGPGME_LOG) << __func__ << ": unsupported alternateType" << m_option.alternateType() << "for list";
757 }
758 return QVariant{list};
759 }
760
761 return {};
762 }
763
712764 #if 0
713765 QString QGpgMENewCryptoConfigEntry::toString(bool escape) const
714766 {
9494 bool isDirty() const Q_DECL_OVERRIDE;
9595
9696 QStringList stringValueList() const;
97 QVariant defaultValue() const;
9798
9899 #if 0
99100 void setDirty(bool b);
0 /*
1 qgpgmereceivekeysjob.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifdef HAVE_CONFIG_H
34 # include "config.h"
35 #endif
36
37 #include "qgpgmereceivekeysjob.h"
38
39 #include "util.h"
40
41 using namespace QGpgME;
42 using namespace GpgME;
43
44 QGpgMEReceiveKeysJob::QGpgMEReceiveKeysJob(Context *context)
45 : mixin_type{context}
46 {
47 lateInitialization();
48 }
49
50 QGpgMEReceiveKeysJob::~QGpgMEReceiveKeysJob() = default;
51
52 static QGpgMEReceiveKeysJob::result_type importfromkeyserver(Context *ctx, const QStringList &keyIds)
53 {
54 const ImportResult res = ctx->importKeys(toStrings(keyIds));
55 Error ae;
56 const QString log = _detail::audit_log_as_html(ctx, ae);
57 return std::make_tuple(res, log, ae);
58 }
59
60 Error QGpgMEReceiveKeysJob::start(const QStringList &keyIds)
61 {
62 run(std::bind(&importfromkeyserver, std::placeholders::_1, keyIds));
63 return Error();
64 }
65
66 GpgME::ImportResult QGpgME::QGpgMEReceiveKeysJob::exec(const QStringList &keyIds)
67 {
68 const result_type r = importfromkeyserver(context(), keyIds);
69 resultHook(r);
70 return mResult;
71 }
72
73 void QGpgME::QGpgMEReceiveKeysJob::resultHook(const result_type &tuple)
74 {
75 mResult = std::get<0>(tuple);
76 }
77
78 #include "qgpgmereceivekeysjob.moc"
0 /*
1 qgpgmereceivekeysjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_QGPGMERECEIVEKEYSJOB_H__
34 #define __QGPGME_QGPGMERECEIVEKEYSJOB_H__
35
36 #include "receivekeysjob.h"
37
38 #include "threadedjobmixin.h"
39
40 #ifdef BUILDING_QGPGME
41 # include "importresult.h"
42 #else
43 # include <gpgme++/importresult.h>
44 #endif
45
46 namespace QGpgME
47 {
48
49 class QGpgMEReceiveKeysJob
50 #ifdef Q_MOC_RUN
51 : public ReceiveKeysJob
52 #else
53 : public _detail::ThreadedJobMixin<ReceiveKeysJob, std::tuple<GpgME::ImportResult, QString, GpgME::Error>>
54 #endif
55 {
56 Q_OBJECT
57 #ifdef Q_MOC_RUN
58 public Q_SLOTS:
59 void slotFinished();
60 #endif
61 public:
62 explicit QGpgMEReceiveKeysJob(GpgME::Context *context);
63 ~QGpgMEReceiveKeysJob() override;
64
65 GpgME::Error start(const QStringList &keyIds) override;
66
67 GpgME::ImportResult exec(const QStringList &keyIds) override;
68
69 /* from ThreadedJobMixin */
70 void resultHook(const result_type &r) override;
71
72 private:
73 GpgME::ImportResult mResult;
74 };
75
76 }
77
78 #endif // __QGPGME_QGPGMERECEIVEKEYSJOB_H__
+0
-147
lang/qt/src/qgpgmesecretkeyexportjob.cpp less more
0 /*
1 qgpgmesecretexportjob.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2004 Klarävdalens Datakonsult AB
5 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
6 Software engineering by Intevation GmbH
7
8 QGpgME is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License as
10 published by the Free Software Foundation; either version 2 of the
11 License, or (at your option) any later version.
12
13 QGpgME is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21
22 In addition, as a special exception, the copyright holders give
23 permission to link the code of this program with any edition of
24 the Qt library by Trolltech AS, Norway (or with modified versions
25 of Qt that use the same license as Qt), and distribute linked
26 combinations including the two. You must obey the GNU General
27 Public License in all respects for all of the code used other than
28 Qt. If you modify this file, you may extend this exception to
29 your version of the file, but you are not obligated to do so. If
30 you do not wish to do so, delete this exception statement from
31 your version.
32 */
33
34 #ifdef HAVE_CONFIG_H
35 #include "config.h"
36 #endif
37
38 #include "qgpgmesecretkeyexportjob.h"
39
40 #include <QDebug>
41 #include "qgpgme_debug.h"
42
43 #include "context.h"
44 #include "data.h"
45
46 #include <QStringList>
47
48 #include <gpg-error.h>
49
50 #include <string.h>
51 #include <assert.h>
52
53 QGpgME::QGpgMESecretKeyExportJob::QGpgMESecretKeyExportJob(bool armour, const QString &charset)
54 : ExportJob(nullptr),
55 mProcess(nullptr),
56 mError(0),
57 mArmour(armour),
58 mCharset(charset)
59 {
60
61 }
62
63 QGpgME::QGpgMESecretKeyExportJob::~QGpgMESecretKeyExportJob()
64 {
65
66 }
67
68 GpgME::Error QGpgME::QGpgMESecretKeyExportJob::start(const QStringList &patterns)
69 {
70 assert(mKeyData.isEmpty());
71
72 if (patterns.size() != 1 || patterns.front().isEmpty()) {
73 deleteLater();
74 return mError = GpgME::Error::fromCode(GPG_ERR_INV_VALUE, GPG_ERR_SOURCE_GPGSM);
75 }
76
77 // create and start gpgsm process:
78 mProcess = new QProcess(this);
79 mProcess->setObjectName(QStringLiteral("gpgsm --export-secret-key-p12"));
80
81 // FIXME: obtain the path to gpgsm from gpgme, so we use the same instance.
82 mProcess->setProgram("gpgsm");
83 QStringList arguments;
84 arguments << QStringLiteral("--export-secret-key-p12");
85 if (mArmour) {
86 arguments << QStringLiteral("--armor");
87 }
88 if (!mCharset.isEmpty()) {
89 arguments << QStringLiteral("--p12-charset") << mCharset;
90 }
91 arguments << QLatin1String(patterns.front().toUtf8());
92
93 mProcess->setArguments(arguments);
94 connect(mProcess, SIGNAL(finished(int,QProcess::ExitStatus)),
95 SLOT(slotProcessExited(int,QProcess::ExitStatus)));
96 connect(mProcess, &QProcess::readyReadStandardOutput,
97 this, &QGpgMESecretKeyExportJob::slotStdout);
98 connect(mProcess, &QProcess::readyReadStandardError,
99 this, &QGpgMESecretKeyExportJob::slotStderr);
100
101 mProcess->start();
102 if (!mProcess->waitForStarted()) {
103 mError = GpgME::Error::fromCode(GPG_ERR_ENOENT, GPG_ERR_SOURCE_GPGSM); // what else?
104 deleteLater();
105 return mError;
106 } else {
107 return GpgME::Error();
108 }
109 }
110
111 void QGpgME::QGpgMESecretKeyExportJob::slotCancel()
112 {
113 if (mProcess) {
114 mProcess->kill();
115 }
116 mProcess = nullptr;
117 mError = GpgME::Error::fromCode(GPG_ERR_CANCELED, GPG_ERR_SOURCE_GPGSM);
118 }
119
120 void QGpgME::QGpgMESecretKeyExportJob::slotStdout()
121 {
122 QString line = QString::fromLocal8Bit(mProcess->readLine());
123 if (!line.isEmpty()) {
124 return;
125 }
126 const unsigned int oldlen = mKeyData.size();
127 mKeyData.resize(oldlen + line.length());
128 memcpy(mKeyData.data() + oldlen, line.toLatin1(), line.length());
129 }
130
131 void QGpgME::QGpgMESecretKeyExportJob::slotStderr()
132 {
133 // implement? or not?
134 }
135
136 void QGpgME::QGpgMESecretKeyExportJob::slotProcessExited(int exitCode, QProcess::ExitStatus exitStatus)
137 {
138 Q_EMIT done();
139 if (!mError &&
140 (exitStatus != QProcess::NormalExit || exitCode != 0)) {
141 mError = GpgME::Error::fromCode(GPG_ERR_GENERAL, GPG_ERR_SOURCE_GPGSM);
142 }
143 Q_EMIT result(mError, mKeyData);
144 deleteLater();
145 }
146 #include "qgpgmesecretkeyexportjob.moc"
+0
-82
lang/qt/src/qgpgmesecretkeyexportjob.h less more
0 /*
1 qgpgmesecretkeyexportjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2004 Klarälvdalens Datakonsult AB
5 Copyright (c) 2016 by Bundesamt für Sicherheit in der Informationstechnik
6 Software engineering by Intevation GmbH
7
8 QGpgME is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License as
10 published by the Free Software Foundation; either version 2 of the
11 License, or (at your option) any later version.
12
13 QGpgME is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21
22 In addition, as a special exception, the copyright holders give
23 permission to link the code of this program with any edition of
24 the Qt library by Trolltech AS, Norway (or with modified versions
25 of Qt that use the same license as Qt), and distribute linked
26 combinations including the two. You must obey the GNU General
27 Public License in all respects for all of the code used other than
28 Qt. If you modify this file, you may extend this exception to
29 your version of the file, but you are not obligated to do so. If
30 you do not wish to do so, delete this exception statement from
31 your version.
32 */
33
34 #ifndef __QGPGME_QGPGMESECRETKEYEXPORTJOB_H__
35 #define __QGPGME_QGPGMESECRETKEYEXPORTJOB_H__
36
37 #include "exportjob.h"
38 #ifdef BUILDING_QGPGME
39 # include "context.h"
40 #else
41 #include "gpgme++/context.h"
42 #endif
43 #include <QProcess>
44
45 namespace GpgME
46 {
47 class Data;
48 }
49
50 namespace QGpgME
51 {
52
53 class QGpgMESecretKeyExportJob : public ExportJob
54 {
55 Q_OBJECT
56 public:
57 QGpgMESecretKeyExportJob(bool armour, const QString &charset);
58 ~QGpgMESecretKeyExportJob();
59
60 /* from ExportJob */
61 GpgME::Error start(const QStringList &patterns) Q_DECL_OVERRIDE;
62
63 private Q_SLOTS:
64 /* from Job */
65 void slotCancel() Q_DECL_OVERRIDE;
66
67 void slotStdout();
68 void slotStderr();
69 void slotProcessExited(int exitCode, QProcess::ExitStatus exitStatus);
70
71 private:
72 QProcess *mProcess;
73 QByteArray mKeyData;
74 GpgME::Error mError;
75 bool mArmour;
76 QString mCharset;
77 };
78
79 }
80
81 #endif // __QGPGME_QGPGMESECRETKEYEXPORTJOB_H__
0 /*
1 qgpgmewkdlookupjob.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifdef HAVE_CONFIG_H
34 #include "config.h"
35 #endif
36
37 #include "qgpgmewkdlookupjob.h"
38
39 #include "qgpgme_debug.h"
40
41 #include <context.h>
42 #include <data.h>
43 #include <defaultassuantransaction.h>
44
45 #include <gpg-error.h>
46
47 using namespace QGpgME;
48 using namespace GpgME;
49
50 QGpgMEWKDLookupJob::QGpgMEWKDLookupJob(Context *context)
51 : mixin_type{context}
52 {
53 lateInitialization();
54 }
55
56 QGpgMEWKDLookupJob::~QGpgMEWKDLookupJob() = default;
57
58 static GpgME::Error startDirmngr(Context *assuanCtx)
59 {
60 Error err;
61
62 auto spawnCtx = std::unique_ptr<Context>{Context::createForEngine(SpawnEngine, &err)};
63 if (err) {
64 qCDebug(QGPGME_LOG) << "Error: Failed to get context for spawn engine (" << err.asString() << ")";
65 }
66
67 const auto dirmngrProgram = GpgME::dirInfo("dirmngr-name");
68 const auto homedir = GpgME::dirInfo("homedir");
69 const char *argv[] = {
70 dirmngrProgram,
71 "--homedir",
72 homedir,
73 "--daemon",
74 NULL
75 };
76 auto ignoreIO = Data{Data::null};
77 if (!err) {
78 qCDebug(QGPGME_LOG) << "Starting dirmngr ...";
79 err = spawnCtx->spawnAsync(dirmngrProgram, argv,
80 ignoreIO, ignoreIO, ignoreIO,
81 Context::SpawnDetached);
82 }
83
84 if (!err) {
85 // wait for socket to become available
86 int cnt = 0;
87 do {
88 ++cnt;
89 qCDebug(QGPGME_LOG) << "Waiting for dirmngr to start ...";
90 QThread::msleep(250 * cnt);
91 err = assuanCtx->assuanTransact("GETINFO version");
92 } while (err.code() == GPG_ERR_ASS_CONNECT_FAILED && cnt < 5);
93 }
94
95 return err;
96 }
97
98 static GpgME::Error setUpDirmngrAssuanConnection(Context *ctx)
99 {
100 Error err;
101
102 const std::string dirmngrSocket = GpgME::dirInfo("dirmngr-socket");
103 err = ctx->setEngineFileName(dirmngrSocket.c_str());
104
105 if (!err) {
106 err = ctx->setEngineHomeDirectory("");
107 }
108
109 if (!err) {
110 // try do connect to dirmngr
111 err = ctx->assuanTransact("GETINFO version");
112 if (err.code() == GPG_ERR_ASS_CONNECT_FAILED) {
113 err = startDirmngr(ctx);
114 }
115 }
116
117 return err;
118 }
119
120 static GpgME::Error run_wkd_get(Context *ctx, const std::string &email)
121 {
122 Error err;
123
124 const auto cmd = std::string{"WKD_GET "} + email;
125 err = ctx->assuanTransact(cmd.c_str());
126 if (err.code() == GPG_ERR_NO_NAME || err.code() == GPG_ERR_NO_DATA) {
127 // ignore those benign errors; GPG_ERR_NO_NAME indicates that the domain
128 // doesn't exist (on first request); GPG_ERR_NO_DATA indicates that
129 // no key for email is available via WKD or that the domain doesn't
130 // support WKD or that the domain doesn't exist (on subsequent requests
131 // using dirmngr's internal cache)
132 qCDebug(QGPGME_LOG) << "WKD_GET returned" << err.asString() << "; ignoring...";
133 err = {};
134 }
135 if (err) {
136 qCDebug(QGPGME_LOG) << "WKD_GET failed with" << err.asString();
137 }
138
139 return err;
140 }
141
142 static QGpgMEWKDLookupJob::result_type lookup_keys(Context *ctx, const QString &email)
143 {
144 WKDLookupResult result;
145
146 Error err = setUpDirmngrAssuanConnection(ctx);
147
148 const auto pattern = email.toUtf8().toStdString();
149 if (!err) {
150 err = run_wkd_get(ctx, pattern);
151 }
152
153 if (!err) {
154 const auto transaction = std::unique_ptr<DefaultAssuanTransaction>(dynamic_cast<DefaultAssuanTransaction*>(ctx->takeLastAssuanTransaction().release()));
155 const auto source = transaction->firstStatusLine("SOURCE");
156 const auto rawData = transaction->data();
157 if (rawData.size() == 0) {
158 qCDebug(QGPGME_LOG) << "No key found for" << email;
159 result = WKDLookupResult{pattern, GpgME::Data::null, {}, {}};
160 } else {
161 qCDebug(QGPGME_LOG) << "Found key for" << email << "at" << source.c_str();
162 result = WKDLookupResult{pattern, GpgME::Data{rawData.c_str(), rawData.size()}, source, {}};
163 }
164 }
165
166 return std::make_tuple(err ? WKDLookupResult{pattern, err} : result, QString{}, Error{});
167 }
168
169 Error QGpgMEWKDLookupJob::start(const QString &email)
170 {
171 run(std::bind(&lookup_keys, std::placeholders::_1, email));
172 return Error();
173 }
174
175 WKDLookupResult QGpgMEWKDLookupJob::exec(const QString &email)
176 {
177 const result_type r = lookup_keys(context(), email);
178 resultHook(r);
179 return std::get<0>(r);
180 }
181
182 #include "qgpgmewkdlookupjob.moc"
0 /*
1 qgpgmewkdlookupjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_QGPGMEWKDLOOKUPJOB_H__
34 #define __QGPGME_QGPGMEWKDLOOKUPJOB_H__
35
36 #include "threadedjobmixin.h"
37 #include "wkdlookupjob.h"
38 #include "wkdlookupresult.h"
39
40 namespace QGpgME
41 {
42 class WKDLookupResult;
43
44 class QGpgMEWKDLookupJob
45 #ifdef Q_MOC_RUN
46 : public WKDLookupJob
47 #else
48 : public _detail::ThreadedJobMixin<WKDLookupJob, std::tuple<WKDLookupResult, QString, GpgME::Error> >
49 #endif
50 {
51 Q_OBJECT
52 #ifdef Q_MOC_RUN
53 public Q_SLOTS:
54 void slotFinished();
55 #endif
56 public:
57 explicit QGpgMEWKDLookupJob(GpgME::Context *context);
58 ~QGpgMEWKDLookupJob();
59
60 /* from WKDLookupJob */
61 GpgME::Error start(const QString &email) Q_DECL_OVERRIDE;
62
63 /* from WKDLookupJob */
64 WKDLookupResult exec(const QString &email) Q_DECL_OVERRIDE;
65 };
66
67 }
68
69 #endif // __QGPGME_QGPGMEWKDLOOKUPJOB_H__
0 /*
1 receivekeysjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_RECEIVEKEYSJOB_H__
34 #define __QGPGME_RECEIVEKEYSJOB_H__
35
36 #include "abstractimportjob.h"
37 #include "qgpgme_export.h"
38
39 namespace QGpgME
40 {
41
42 class QGPGME_EXPORT ReceiveKeysJob : public AbstractImportJob
43 {
44 Q_OBJECT
45 protected:
46 explicit ReceiveKeysJob(QObject *parent);
47 public:
48 ~ReceiveKeysJob() override;
49
50 /**
51 Starts the import of keys from a keyserver. \a keyIds is a list of
52 key ids and/or fingerprints specifying the keys to import.
53 */
54 virtual GpgME::Error start(const QStringList &keyIds) = 0;
55
56 /**
57 Runs the import of keys from a keyserver. \a keyIds is a list of
58 key ids and/or fingerprints specifying the keys to import.
59 */
60 virtual GpgME::ImportResult exec(const QStringList &keyIds) = 0;
61 };
62
63 }
64
65 #endif // __QGPGME_RECEIVEKEYSJOB_H__
116116 *
117117 * Not pure virtual for ABI compatibility.
118118 **/
119 virtual void setDupeOk(bool) {};
119 virtual void setDupeOk(bool) {}
120120
121121 /**
122122 * Add a remark to the signature. This uses rem@gnupg.org as a notation.
123123 *
124124 * Not pure virtual for ABI compatibility.
125125 **/
126 virtual void setRemark(const QString &) {};
126 virtual void setRemark(const QString &) {}
127127
128128 /**
129129 * If set, then the created signature will be a trust signature. By default,
142142 *
143143 * Not pure virtual for ABI compatibility.
144144 **/
145 virtual void setTrustSignature(GpgME::TrustSignatureTrust trust, unsigned short depth, const QString &scope) { Q_UNUSED(trust); Q_UNUSED(depth); Q_UNUSED(scope); };
145 virtual void setTrustSignature(GpgME::TrustSignatureTrust trust, unsigned short depth, const QString &scope) { Q_UNUSED(trust); Q_UNUSED(depth); Q_UNUSED(scope); }
146146
147147 /**
148148 * Sets the expiration date of the key signature to @a expiration. By default,
5252 using namespace QGpgME;
5353 using namespace GpgME;
5454
55 #ifdef Q_OS_WIN
56 #include <windows.h>
57
58 static QString fromEncoding (unsigned int src_encoding, const char *data)
59 {
60 int n = MultiByteToWideChar(src_encoding, 0, data, -1, NULL, 0);
61 if (n < 0) {
62 return QString();
63 }
64
65 wchar_t *result = (wchar_t *) malloc ((n+1) * sizeof *result);
66
67 n = MultiByteToWideChar(src_encoding, 0, data, -1, result, n);
68 if (n < 0) {
69 free(result);
70 return QString();
71 }
72 const auto ret = QString::fromWCharArray(result, n);
73 free(result);
74 return ret;
75 }
76 #endif
77
7855 static QString stringFromGpgOutput(const QByteArray &ba)
7956 {
8057 #ifdef Q_OS_WIN
81 /* Qt on Windows uses GetACP while GnuPG prefers
82 * GetConsoleOutputCP.
83 *
84 * As we are not a console application GetConsoleOutputCP
85 * usually returns 0.
86 * From experience the closest thing that let's us guess
87 * what GetConsoleOutputCP returns for a console application
88 * it appears to be the OEMCP.
89 */
90 unsigned int cpno = GetConsoleOutputCP ();
91 if (!cpno) {
92 cpno = GetOEMCP();
93 }
94 if (!cpno) {
95 cpno = GetACP();
96 }
97 if (!cpno) {
98 return QString();
99 }
100
101 return fromEncoding(cpno, ba.constData());
58 return QString::fromUtf8(ba);
10259 #else
10360 return QString::fromLocal8Bit(ba);
10461 #endif
0 /*
1 util.cpp
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #include "util.h"
34
35 #include <QStringList>
36 #include <functional>
37
38 std::vector<std::string> toStrings(const QStringList &l)
39 {
40 std::vector<std::string> v;
41 v.reserve(l.size());
42 std::transform(std::begin(l), std::end(l),
43 std::back_inserter(v),
44 std::mem_fn(&QString::toStdString));
45 return v;
46 }
0 /*
1 util.h - some internal helpers
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2022 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_UTIL_H__
34 #define __QGPGME_UTIL_H__
35
36 #include <gpgme.h>
37
38 #include <string>
39 #include <vector>
40
41 class QStringList;
42
43 static inline gpgme_error_t make_error(gpgme_err_code_t code)
44 {
45 return gpgme_err_make((gpgme_err_source_t)22, code);
46 }
47
48 std::vector<std::string> toStrings(const QStringList &l);
49
50 #endif // __QGPGME_UTIL_H__
0 /*
1 wkdlookupjob.h
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_WKDLOOKUPJOB_H__
34 #define __QGPGME_WKDLOOKUPJOB_H__
35
36 #include "job.h"
37 #include "qgpgme_export.h"
38
39 class QString;
40
41 namespace GpgME
42 {
43 class Data;
44 class Error;
45 }
46
47 namespace QGpgME
48 {
49
50 class WKDLookupResult;
51
52 class QGPGME_EXPORT WKDLookupJob : public Job
53 {
54 Q_OBJECT
55 protected:
56 explicit WKDLookupJob(QObject *parent);
57
58 public:
59 ~WKDLookupJob();
60
61 /**
62 Starts a key lookup operation for the email address \a email via WKD.
63 */
64 virtual GpgME::Error start(const QString &email) = 0;
65
66 /**
67 Runs a key lookup operation for the email address \a email via WKD.
68 */
69 virtual WKDLookupResult exec(const QString &email) = 0;
70
71 Q_SIGNALS:
72 void result(const WKDLookupResult &result, const QString &auditLogAsHtml = {}, const GpgME::Error &auditLogError = {});
73 };
74
75 }
76
77 #endif // __QGPGME_WKDLOOKUPJOB_H__
0 /*
1 wkdlookupresult.cpp - wraps the result of a WKDLookupJob
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifdef HAVE_CONFIG_H
34 #include "config.h"
35 #endif
36
37 #include "wkdlookupresult.h"
38
39 #include <data.h>
40
41 using namespace QGpgME;
42 using namespace GpgME;
43
44 class WKDLookupResult::Private
45 {
46 public:
47 std::string pattern;
48 GpgME::Data keyData;
49 std::string source;
50 };
51
52 WKDLookupResult::WKDLookupResult() = default;
53
54 WKDLookupResult::~WKDLookupResult() = default;
55
56 WKDLookupResult::WKDLookupResult(const std::string &pattern, const Error &error)
57 : Result{error}
58 , d{new Private{pattern, {}, {}}}
59 {
60 }
61
62 WKDLookupResult::WKDLookupResult(const std::string &pattern, const Data &keyData, const std::string &source, const Error &error)
63 : Result{error}
64 , d{new Private{pattern, keyData, source}}
65 {
66 }
67
68 WKDLookupResult::WKDLookupResult(const WKDLookupResult &other)
69 : Result{other}
70 {
71 if (other.d) {
72 d.reset(new Private{*other.d});
73 }
74 }
75
76 WKDLookupResult &WKDLookupResult::operator=(const WKDLookupResult &other)
77 {
78 auto tmp = other;
79 swap(tmp);
80 return *this;
81 }
82
83 WKDLookupResult::WKDLookupResult(WKDLookupResult &&other) = default;
84
85 WKDLookupResult &WKDLookupResult::operator=(WKDLookupResult &&other) = default;
86
87 void WKDLookupResult::swap(WKDLookupResult &other) noexcept
88 {
89 Result::swap(other);
90 std::swap(this->d, other.d);
91 }
92
93 bool WKDLookupResult::isNull() const
94 {
95 return !d && !bool(error());
96 }
97
98 std::string WKDLookupResult::pattern() const
99 {
100 return d ? d->pattern : std::string{};
101 }
102
103 Data WKDLookupResult::keyData() const
104 {
105 return d ? d->keyData : Data{};
106 }
107
108 std::string WKDLookupResult::source() const
109 {
110 return d ? d->source : std::string{};
111 }
112
113 void QGpgME::swap(WKDLookupResult &a, WKDLookupResult &b)
114 {
115 a.swap(b);
116 }
0 /*
1 wkdlookupresult.h - wraps the result of a WKDLookupJob
2
3 This file is part of qgpgme, the Qt API binding for gpgme
4 Copyright (c) 2021 g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 QGpgME is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
30 your version.
31 */
32
33 #ifndef __QGPGME_WKDLOOKUPRESULT_H__
34 #define __QGPGME_WKDLOOKUPRESULT_H__
35
36 #include "qgpgme_export.h"
37
38 #ifdef BUILDING_QGPGME
39 # include <result.h>
40 #else
41 # include <gpgme++/result.h>
42 #endif
43
44 #include <memory>
45
46 namespace GpgME
47 {
48 class Data;
49 class Error;
50 }
51
52 namespace QGpgME
53 {
54
55 class QGPGME_EXPORT WKDLookupResult : public GpgME::Result
56 {
57 public:
58 WKDLookupResult();
59 ~WKDLookupResult();
60
61 explicit WKDLookupResult(const std::string &pattern, const GpgME::Error &err);
62 explicit WKDLookupResult(const std::string &pattern, const GpgME::Data &keyData, const std::string &source, const GpgME::Error &err);
63
64 WKDLookupResult(const WKDLookupResult &other);
65 WKDLookupResult &operator=(const WKDLookupResult &other);
66
67 WKDLookupResult(WKDLookupResult &&other);
68 WKDLookupResult &operator=(WKDLookupResult &&other);
69
70 void swap(WKDLookupResult &other) noexcept;
71
72 bool isNull() const;
73
74 std::string pattern() const;
75 GpgME::Data keyData() const;
76 std::string source() const;
77
78 private:
79 class Private;
80 std::unique_ptr<Private> d;
81 };
82
83 QGPGME_EXPORT void swap(WKDLookupResult &a, WKDLookupResult &b);
84
85 }
86
87 #endif // __QGPGME_WKDLOOKUPRESULT_H__
2323 GNUPGHOME=$(abs_builddir)
2424 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME)
2525
26 EXTRA_DIST = initial.test
26 EXTRA_DIST = initial.test final.test
2727
28 TESTS = initial.test t-keylist t-keylocate t-ownertrust t-tofuinfo \
29 t-encrypt t-verify t-various t-config t-remarks t-trustsignatures
28 the_tests = \
29 t-addexistingsubkey \
30 t-keylist t-keylocate t-ownertrust t-tofuinfo \
31 t-encrypt t-verify t-various t-config t-remarks t-trustsignatures \
32 t-changeexpiryjob t-wkdlookup t-import
3033
31 moc_files = t-keylist.moc t-keylocate.moc t-ownertrust.moc t-tofuinfo.moc \
32 t-encrypt.moc t-support.hmoc t-wkspublish.moc t-verify.moc \
33 t-various.moc t-config.moc t-remarks.moc t-trustsignatures.moc
34 TESTS = initial.test $(the_tests) final.test
35
36 moc_files = \
37 t-addexistingsubkey.moc \
38 t-keylist.moc t-keylocate.moc t-ownertrust.moc t-tofuinfo.moc \
39 t-encrypt.moc t-support.hmoc t-wkspublish.moc t-verify.moc \
40 t-various.moc t-config.moc t-remarks.moc t-trustsignatures.moc \
41 t-changeexpiryjob.moc t-wkdlookup.moc t-import.moc
3442
3543 AM_LDFLAGS = -no-install
3644
4654
4755 support_src = t-support.h t-support.cpp
4856
57 t_addexistingsubkey_SOURCES = t-addexistingsubkey.cpp $(support_src)
4958 t_keylist_SOURCES = t-keylist.cpp $(support_src)
5059 t_keylocate_SOURCES = t-keylocate.cpp $(support_src)
5160 t_ownertrust_SOURCES = t-ownertrust.cpp $(support_src)
5766 t_config_SOURCES = t-config.cpp $(support_src)
5867 t_remarks_SOURCES = t-remarks.cpp $(support_src)
5968 t_trustsignatures_SOURCES = t-trustsignatures.cpp $(support_src)
69 t_changeexpiryjob_SOURCES = t-changeexpiryjob.cpp $(support_src)
70 t_wkdlookup_SOURCES = t-wkdlookup.cpp $(support_src)
71 t_import_SOURCES = t-import.cpp $(support_src)
72 run_exportjob_SOURCES = run-exportjob.cpp
73 run_importjob_SOURCES = run-importjob.cpp
6074 run_keyformailboxjob_SOURCES = run-keyformailboxjob.cpp
75 run_receivekeysjob_SOURCES = run-receivekeysjob.cpp
6176
6277 nodist_t_keylist_SOURCES = $(moc_files)
6378
6479 BUILT_SOURCES = $(moc_files) pubring-stamp
6580
66 noinst_PROGRAMS = t-keylist t-keylocate t-ownertrust t-tofuinfo t-encrypt \
67 run-keyformailboxjob t-wkspublish t-verify t-various t-config t-remarks \
68 t-trustsignatures
81 noinst_PROGRAMS = \
82 t-addexistingsubkey \
83 t-keylist t-keylocate t-ownertrust t-tofuinfo t-encrypt \
84 run-keyformailboxjob t-wkspublish t-verify t-various t-config t-remarks \
85 t-trustsignatures t-changeexpiryjob t-wkdlookup t-import run-importjob \
86 run-exportjob run-receivekeysjob
6987
7088 CLEANFILES = secring.gpg pubring.gpg pubring.kbx trustdb.gpg dirmngr.conf \
7189 gpg-agent.conf pubring.kbx~ S.gpg-agent gpg.conf pubring.gpg~ \
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am - Makefile for GPGME Qt tests.
17 # Copyright (C) 2016 Bundesamt für Sicherheit in der Informationstechnik
18 # Software engineering by Intevation GmbH
19 #
20 # This file is part of GPGME.
21 #
22 # GPGME is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU Lesser General Public License as
24 # published by the Free Software Foundation; either version 2.1 of the
25 # License, or (at your option) any later version.
26 #
27 # GPGME is distributed in the hope that it will be useful, but WITHOUT
28 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
29 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
30 # Public License for more details.
31 #
32 # You should have received a copy of the GNU Lesser General Public
33 # License along with this program; if not, see <https://www.gnu.org/licenses/>.
34
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 TESTS = initial.test $(am__EXEEXT_1) final.test
110 noinst_PROGRAMS = t-addexistingsubkey$(EXEEXT) t-keylist$(EXEEXT) \
111 t-keylocate$(EXEEXT) t-ownertrust$(EXEEXT) t-tofuinfo$(EXEEXT) \
112 t-encrypt$(EXEEXT) run-keyformailboxjob$(EXEEXT) \
113 t-wkspublish$(EXEEXT) t-verify$(EXEEXT) t-various$(EXEEXT) \
114 t-config$(EXEEXT) t-remarks$(EXEEXT) \
115 t-trustsignatures$(EXEEXT) t-changeexpiryjob$(EXEEXT) \
116 t-wkdlookup$(EXEEXT) t-import$(EXEEXT) run-importjob$(EXEEXT) \
117 run-exportjob$(EXEEXT) run-receivekeysjob$(EXEEXT)
118 subdir = lang/qt/tests
119 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
120 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
121 $(top_srcdir)/m4/ax_pkg_swig.m4 \
122 $(top_srcdir)/m4/ax_python_devel.m4 \
123 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
124 $(top_srcdir)/m4/gnupg-ttyname.m4 \
125 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
126 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
127 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
128 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
129 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
130 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
131 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
132 $(ACLOCAL_M4)
133 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
134 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
135 CONFIG_HEADER = $(top_builddir)/conf/config.h
136 CONFIG_CLEAN_FILES =
137 CONFIG_CLEAN_VPATH_FILES =
138 PROGRAMS = $(noinst_PROGRAMS)
139 am_run_exportjob_OBJECTS = run-exportjob.$(OBJEXT)
140 run_exportjob_OBJECTS = $(am_run_exportjob_OBJECTS)
141 run_exportjob_LDADD = $(LDADD)
142 run_exportjob_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
143 ../src/libqgpgme.la ../../../src/libgpgme.la
144 AM_V_lt = $(am__v_lt_@AM_V@)
145 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
146 am__v_lt_0 = --silent
147 am__v_lt_1 =
148 am_run_importjob_OBJECTS = run-importjob.$(OBJEXT)
149 run_importjob_OBJECTS = $(am_run_importjob_OBJECTS)
150 run_importjob_LDADD = $(LDADD)
151 run_importjob_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
152 ../src/libqgpgme.la ../../../src/libgpgme.la
153 am_run_keyformailboxjob_OBJECTS = run-keyformailboxjob.$(OBJEXT)
154 run_keyformailboxjob_OBJECTS = $(am_run_keyformailboxjob_OBJECTS)
155 run_keyformailboxjob_LDADD = $(LDADD)
156 run_keyformailboxjob_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
157 ../src/libqgpgme.la ../../../src/libgpgme.la
158 am_run_receivekeysjob_OBJECTS = run-receivekeysjob.$(OBJEXT)
159 run_receivekeysjob_OBJECTS = $(am_run_receivekeysjob_OBJECTS)
160 run_receivekeysjob_LDADD = $(LDADD)
161 run_receivekeysjob_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
162 ../src/libqgpgme.la ../../../src/libgpgme.la
163 am__objects_1 = t-support.$(OBJEXT)
164 am_t_addexistingsubkey_OBJECTS = t-addexistingsubkey.$(OBJEXT) \
165 $(am__objects_1)
166 t_addexistingsubkey_OBJECTS = $(am_t_addexistingsubkey_OBJECTS)
167 t_addexistingsubkey_LDADD = $(LDADD)
168 t_addexistingsubkey_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
169 ../src/libqgpgme.la ../../../src/libgpgme.la
170 am_t_changeexpiryjob_OBJECTS = t-changeexpiryjob.$(OBJEXT) \
171 $(am__objects_1)
172 t_changeexpiryjob_OBJECTS = $(am_t_changeexpiryjob_OBJECTS)
173 t_changeexpiryjob_LDADD = $(LDADD)
174 t_changeexpiryjob_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
175 ../src/libqgpgme.la ../../../src/libgpgme.la
176 am_t_config_OBJECTS = t-config.$(OBJEXT) $(am__objects_1)
177 t_config_OBJECTS = $(am_t_config_OBJECTS)
178 t_config_LDADD = $(LDADD)
179 t_config_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
180 ../src/libqgpgme.la ../../../src/libgpgme.la
181 am_t_encrypt_OBJECTS = t-encrypt.$(OBJEXT) $(am__objects_1)
182 t_encrypt_OBJECTS = $(am_t_encrypt_OBJECTS)
183 t_encrypt_LDADD = $(LDADD)
184 t_encrypt_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
185 ../src/libqgpgme.la ../../../src/libgpgme.la
186 am_t_import_OBJECTS = t-import.$(OBJEXT) $(am__objects_1)
187 t_import_OBJECTS = $(am_t_import_OBJECTS)
188 t_import_LDADD = $(LDADD)
189 t_import_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
190 ../src/libqgpgme.la ../../../src/libgpgme.la
191 am_t_keylist_OBJECTS = t-keylist.$(OBJEXT) $(am__objects_1)
192 am__objects_2 =
193 nodist_t_keylist_OBJECTS = $(am__objects_2)
194 t_keylist_OBJECTS = $(am_t_keylist_OBJECTS) \
195 $(nodist_t_keylist_OBJECTS)
196 t_keylist_LDADD = $(LDADD)
197 t_keylist_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
198 ../src/libqgpgme.la ../../../src/libgpgme.la
199 am_t_keylocate_OBJECTS = t-keylocate.$(OBJEXT) $(am__objects_1)
200 t_keylocate_OBJECTS = $(am_t_keylocate_OBJECTS)
201 t_keylocate_LDADD = $(LDADD)
202 t_keylocate_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
203 ../src/libqgpgme.la ../../../src/libgpgme.la
204 am_t_ownertrust_OBJECTS = t-ownertrust.$(OBJEXT) $(am__objects_1)
205 t_ownertrust_OBJECTS = $(am_t_ownertrust_OBJECTS)
206 t_ownertrust_LDADD = $(LDADD)
207 t_ownertrust_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
208 ../src/libqgpgme.la ../../../src/libgpgme.la
209 am_t_remarks_OBJECTS = t-remarks.$(OBJEXT) $(am__objects_1)
210 t_remarks_OBJECTS = $(am_t_remarks_OBJECTS)
211 t_remarks_LDADD = $(LDADD)
212 t_remarks_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
213 ../src/libqgpgme.la ../../../src/libgpgme.la
214 am_t_tofuinfo_OBJECTS = t-tofuinfo.$(OBJEXT) $(am__objects_1)
215 t_tofuinfo_OBJECTS = $(am_t_tofuinfo_OBJECTS)
216 t_tofuinfo_LDADD = $(LDADD)
217 t_tofuinfo_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
218 ../src/libqgpgme.la ../../../src/libgpgme.la
219 am_t_trustsignatures_OBJECTS = t-trustsignatures.$(OBJEXT) \
220 $(am__objects_1)
221 t_trustsignatures_OBJECTS = $(am_t_trustsignatures_OBJECTS)
222 t_trustsignatures_LDADD = $(LDADD)
223 t_trustsignatures_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
224 ../src/libqgpgme.la ../../../src/libgpgme.la
225 am_t_various_OBJECTS = t-various.$(OBJEXT) $(am__objects_1)
226 t_various_OBJECTS = $(am_t_various_OBJECTS)
227 t_various_LDADD = $(LDADD)
228 t_various_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
229 ../src/libqgpgme.la ../../../src/libgpgme.la
230 am_t_verify_OBJECTS = t-verify.$(OBJEXT) $(am__objects_1)
231 t_verify_OBJECTS = $(am_t_verify_OBJECTS)
232 t_verify_LDADD = $(LDADD)
233 t_verify_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
234 ../src/libqgpgme.la ../../../src/libgpgme.la
235 am_t_wkdlookup_OBJECTS = t-wkdlookup.$(OBJEXT) $(am__objects_1)
236 t_wkdlookup_OBJECTS = $(am_t_wkdlookup_OBJECTS)
237 t_wkdlookup_LDADD = $(LDADD)
238 t_wkdlookup_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
239 ../src/libqgpgme.la ../../../src/libgpgme.la
240 am_t_wkspublish_OBJECTS = t-wkspublish.$(OBJEXT) $(am__objects_1)
241 t_wkspublish_OBJECTS = $(am_t_wkspublish_OBJECTS)
242 t_wkspublish_LDADD = $(LDADD)
243 t_wkspublish_DEPENDENCIES = ../../cpp/src/libgpgmepp.la \
244 ../src/libqgpgme.la ../../../src/libgpgme.la
245 AM_V_P = $(am__v_P_@AM_V@)
246 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
247 am__v_P_0 = false
248 am__v_P_1 = :
249 AM_V_GEN = $(am__v_GEN_@AM_V@)
250 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
251 am__v_GEN_0 = @echo " GEN " $@;
252 am__v_GEN_1 =
253 AM_V_at = $(am__v_at_@AM_V@)
254 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
255 am__v_at_0 = @
256 am__v_at_1 =
257 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
258 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
259 am__maybe_remake_depfiles = depfiles
260 am__depfiles_remade = ./$(DEPDIR)/run-exportjob.Po \
261 ./$(DEPDIR)/run-importjob.Po \
262 ./$(DEPDIR)/run-keyformailboxjob.Po \
263 ./$(DEPDIR)/run-receivekeysjob.Po \
264 ./$(DEPDIR)/t-addexistingsubkey.Po \
265 ./$(DEPDIR)/t-changeexpiryjob.Po ./$(DEPDIR)/t-config.Po \
266 ./$(DEPDIR)/t-encrypt.Po ./$(DEPDIR)/t-import.Po \
267 ./$(DEPDIR)/t-keylist.Po ./$(DEPDIR)/t-keylocate.Po \
268 ./$(DEPDIR)/t-ownertrust.Po ./$(DEPDIR)/t-remarks.Po \
269 ./$(DEPDIR)/t-support.Po ./$(DEPDIR)/t-tofuinfo.Po \
270 ./$(DEPDIR)/t-trustsignatures.Po ./$(DEPDIR)/t-various.Po \
271 ./$(DEPDIR)/t-verify.Po ./$(DEPDIR)/t-wkdlookup.Po \
272 ./$(DEPDIR)/t-wkspublish.Po
273 am__mv = mv -f
274 CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
275 $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
276 LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
277 $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \
278 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
279 $(AM_CXXFLAGS) $(CXXFLAGS)
280 AM_V_CXX = $(am__v_CXX_@AM_V@)
281 am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@)
282 am__v_CXX_0 = @echo " CXX " $@;
283 am__v_CXX_1 =
284 CXXLD = $(CXX)
285 CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
286 $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
287 $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
288 AM_V_CXXLD = $(am__v_CXXLD_@AM_V@)
289 am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@)
290 am__v_CXXLD_0 = @echo " CXXLD " $@;
291 am__v_CXXLD_1 =
292 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
293 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
294 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
295 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
296 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
297 $(AM_CFLAGS) $(CFLAGS)
298 AM_V_CC = $(am__v_CC_@AM_V@)
299 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
300 am__v_CC_0 = @echo " CC " $@;
301 am__v_CC_1 =
302 CCLD = $(CC)
303 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
304 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
305 $(AM_LDFLAGS) $(LDFLAGS) -o $@
306 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
307 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
308 am__v_CCLD_0 = @echo " CCLD " $@;
309 am__v_CCLD_1 =
310 SOURCES = $(run_exportjob_SOURCES) $(run_importjob_SOURCES) \
311 $(run_keyformailboxjob_SOURCES) $(run_receivekeysjob_SOURCES) \
312 $(t_addexistingsubkey_SOURCES) $(t_changeexpiryjob_SOURCES) \
313 $(t_config_SOURCES) $(t_encrypt_SOURCES) $(t_import_SOURCES) \
314 $(t_keylist_SOURCES) $(nodist_t_keylist_SOURCES) \
315 $(t_keylocate_SOURCES) $(t_ownertrust_SOURCES) \
316 $(t_remarks_SOURCES) $(t_tofuinfo_SOURCES) \
317 $(t_trustsignatures_SOURCES) $(t_various_SOURCES) \
318 $(t_verify_SOURCES) $(t_wkdlookup_SOURCES) \
319 $(t_wkspublish_SOURCES)
320 DIST_SOURCES = $(run_exportjob_SOURCES) $(run_importjob_SOURCES) \
321 $(run_keyformailboxjob_SOURCES) $(run_receivekeysjob_SOURCES) \
322 $(t_addexistingsubkey_SOURCES) $(t_changeexpiryjob_SOURCES) \
323 $(t_config_SOURCES) $(t_encrypt_SOURCES) $(t_import_SOURCES) \
324 $(t_keylist_SOURCES) $(t_keylocate_SOURCES) \
325 $(t_ownertrust_SOURCES) $(t_remarks_SOURCES) \
326 $(t_tofuinfo_SOURCES) $(t_trustsignatures_SOURCES) \
327 $(t_various_SOURCES) $(t_verify_SOURCES) \
328 $(t_wkdlookup_SOURCES) $(t_wkspublish_SOURCES)
329 am__can_run_installinfo = \
330 case $$AM_UPDATE_INFO_DIR in \
331 n|no|NO) false;; \
332 *) (install-info --version) >/dev/null 2>&1;; \
333 esac
334 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
335 # Read a list of newline-separated strings from the standard input,
336 # and print each of them once, without duplicates. Input order is
337 # *not* preserved.
338 am__uniquify_input = $(AWK) '\
339 BEGIN { nonempty = 0; } \
340 { items[$$0] = 1; nonempty = 1; } \
341 END { if (nonempty) { for (i in items) print i; }; } \
342 '
343 # Make sure the list of sources is unique. This is necessary because,
344 # e.g., the same source file might be shared among _SOURCES variables
345 # for different programs/libraries.
346 am__define_uniq_tagged_files = \
347 list='$(am__tagged_files)'; \
348 unique=`for i in $$list; do \
349 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
350 done | $(am__uniquify_input)`
351 ETAGS = etags
352 CTAGS = ctags
353 am__tty_colors_dummy = \
354 mgn= red= grn= lgn= blu= brg= std=; \
355 am__color_tests=no
356 am__tty_colors = { \
357 $(am__tty_colors_dummy); \
358 if test "X$(AM_COLOR_TESTS)" = Xno; then \
359 am__color_tests=no; \
360 elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
361 am__color_tests=yes; \
362 elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
363 am__color_tests=yes; \
364 fi; \
365 if test $$am__color_tests = yes; then \
366 red=''; \
367 grn=''; \
368 lgn=''; \
369 blu=''; \
370 mgn=''; \
371 brg=''; \
372 std=''; \
373 fi; \
374 }
375 am__EXEEXT_1 = t-addexistingsubkey$(EXEEXT) t-keylist$(EXEEXT) \
376 t-keylocate$(EXEEXT) t-ownertrust$(EXEEXT) t-tofuinfo$(EXEEXT) \
377 t-encrypt$(EXEEXT) t-verify$(EXEEXT) t-various$(EXEEXT) \
378 t-config$(EXEEXT) t-remarks$(EXEEXT) \
379 t-trustsignatures$(EXEEXT) t-changeexpiryjob$(EXEEXT) \
380 t-wkdlookup$(EXEEXT) t-import$(EXEEXT)
381 am__DIST_COMMON = $(srcdir)/Makefile.in \
382 $(top_srcdir)/build-aux/depcomp \
383 $(top_srcdir)/build-aux/mkinstalldirs
384 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
385 ACLOCAL = @ACLOCAL@
386 AMTAR = @AMTAR@
387 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
388 AR = @AR@
389 AS = @AS@
390 AUTOCONF = @AUTOCONF@
391 AUTOHEADER = @AUTOHEADER@
392 AUTOMAKE = @AUTOMAKE@
393 AWK = @AWK@
394 BUILD_FILEVERSION = @BUILD_FILEVERSION@
395 BUILD_REVISION = @BUILD_REVISION@
396 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
397 BUILD_VERSION = @BUILD_VERSION@
398 CC = @CC@
399 CCDEPMODE = @CCDEPMODE@
400 CC_FOR_BUILD = @CC_FOR_BUILD@
401 CFLAGS = @CFLAGS@
402 CPP = @CPP@
403 CPPFLAGS = @CPPFLAGS@
404 CXX = @CXX@
405 CXXCPP = @CXXCPP@
406 CXXDEPMODE = @CXXDEPMODE@
407 CXXFLAGS = @CXXFLAGS@
408 CYGPATH_W = @CYGPATH_W@
409 DEFS = @DEFS@
410 DEPDIR = @DEPDIR@
411 DLLTOOL = @DLLTOOL@
412 DOXYGEN = @DOXYGEN@
413 DSYMUTIL = @DSYMUTIL@
414 DUMPBIN = @DUMPBIN@
415 ECHO_C = @ECHO_C@
416 ECHO_N = @ECHO_N@
417 ECHO_T = @ECHO_T@
418 EGREP = @EGREP@
419 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
420 EXEEXT = @EXEEXT@
421 FGREP = @FGREP@
422 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
423 GLIBC21 = @GLIBC21@
424 GLIB_CFLAGS = @GLIB_CFLAGS@
425 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
426 GLIB_LIBS = @GLIB_LIBS@
427 GLIB_MKENUMS = @GLIB_MKENUMS@
428 GOBJECT_QUERY = @GOBJECT_QUERY@
429 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
430 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
431 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
432 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
433 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
434 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
435 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
436 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
437 GPGME_QT_LIBS = @GPGME_QT_LIBS@
438 GPGRT_CONFIG = @GPGRT_CONFIG@
439 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
440 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
441 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
442 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
443 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
444 GRAPHVIZ = @GRAPHVIZ@
445 GREP = @GREP@
446 HAVE_CXX11 = @HAVE_CXX11@
447 HAVE_DOT = @HAVE_DOT@
448 INSTALL = @INSTALL@
449 INSTALL_DATA = @INSTALL_DATA@
450 INSTALL_PROGRAM = @INSTALL_PROGRAM@
451 INSTALL_SCRIPT = @INSTALL_SCRIPT@
452 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
453 LD = @LD@
454 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
455 LDFLAGS = @LDFLAGS@
456 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
457 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
458 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
459 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
460 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
461 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
462 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
463 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
464 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
465 LIBOBJS = @LIBOBJS@
466 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
467 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
468 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
469 LIBS = @LIBS@
470 LIBTOOL = @LIBTOOL@
471 LIPO = @LIPO@
472 LN_S = @LN_S@
473 LTLIBOBJS = @LTLIBOBJS@
474 MAINT = @MAINT@
475 MAKEINFO = @MAKEINFO@
476 MANIFEST_TOOL = @MANIFEST_TOOL@
477 MKDIR_P = @MKDIR_P@
478 MOC = @MOC@
479 MOC2 = @MOC2@
480 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
481 NM = @NM@
482 NMEDIT = @NMEDIT@
483 OBJDUMP = @OBJDUMP@
484 OBJEXT = @OBJEXT@
485 OTOOL = @OTOOL@
486 OTOOL64 = @OTOOL64@
487 PACKAGE = @PACKAGE@
488 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
489 PACKAGE_NAME = @PACKAGE_NAME@
490 PACKAGE_STRING = @PACKAGE_STRING@
491 PACKAGE_TARNAME = @PACKAGE_TARNAME@
492 PACKAGE_URL = @PACKAGE_URL@
493 PACKAGE_VERSION = @PACKAGE_VERSION@
494 PATH_SEPARATOR = @PATH_SEPARATOR@
495 PKG_CONFIG = @PKG_CONFIG@
496 PYTHON = @PYTHON@
497 PYTHONS = @PYTHONS@
498 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
499 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
500 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
501 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
502 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
503 PYTHON_PLATFORM = @PYTHON_PLATFORM@
504 PYTHON_PREFIX = @PYTHON_PREFIX@
505 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
506 PYTHON_VERSION = @PYTHON_VERSION@
507 QTCHOOSER = @QTCHOOSER@
508 RANLIB = @RANLIB@
509 RC = @RC@
510 SED = @SED@
511 SET_MAKE = @SET_MAKE@
512 SHELL = @SHELL@
513 STRIP = @STRIP@
514 SWIG = @SWIG@
515 SWIG_LIB = @SWIG_LIB@
516 SYSROOT = @SYSROOT@
517 VERSION = @VERSION@
518 VERSION_MAJOR = @VERSION_MAJOR@
519 VERSION_MICRO = @VERSION_MICRO@
520 VERSION_MINOR = @VERSION_MINOR@
521 VERSION_NUMBER = @VERSION_NUMBER@
522 abs_builddir = @abs_builddir@
523 abs_srcdir = @abs_srcdir@
524 abs_top_builddir = @abs_top_builddir@
525 abs_top_srcdir = @abs_top_srcdir@
526 ac_ct_AR = @ac_ct_AR@
527 ac_ct_CC = @ac_ct_CC@
528 ac_ct_CXX = @ac_ct_CXX@
529 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
530 am__include = @am__include@
531 am__leading_dot = @am__leading_dot@
532 am__quote = @am__quote@
533 am__tar = @am__tar@
534 am__untar = @am__untar@
535 bindir = @bindir@
536 build = @build@
537 build_alias = @build_alias@
538 build_cpu = @build_cpu@
539 build_os = @build_os@
540 build_vendor = @build_vendor@
541 builddir = @builddir@
542 datadir = @datadir@
543 datarootdir = @datarootdir@
544 docdir = @docdir@
545 dvidir = @dvidir@
546 emacs_local_vars_begin = @emacs_local_vars_begin@
547 emacs_local_vars_end = @emacs_local_vars_end@
548 emacs_local_vars_read_only = @emacs_local_vars_read_only@
549 exec_prefix = @exec_prefix@
550 host = @host@
551 host_alias = @host_alias@
552 host_cpu = @host_cpu@
553 host_os = @host_os@
554 host_vendor = @host_vendor@
555 htmldir = @htmldir@
556 includedir = @includedir@
557 infodir = @infodir@
558 install_sh = @install_sh@
559 libdir = @libdir@
560 libexecdir = @libexecdir@
561 localedir = @localedir@
562 localstatedir = @localstatedir@
563 mandir = @mandir@
564 mkdir_p = @mkdir_p@
565 oldincludedir = @oldincludedir@
566 pdfdir = @pdfdir@
567 pkgpyexecdir = @pkgpyexecdir@
568 pkgpythondir = @pkgpythondir@
569 prefix = @prefix@
570 program_transform_name = @program_transform_name@
571 psdir = @psdir@
572 pyexecdir = @pyexecdir@
573 pythondir = @pythondir@
574 runstatedir = @runstatedir@
575 sbindir = @sbindir@
576 sharedstatedir = @sharedstatedir@
577 srcdir = @srcdir@
578 sysconfdir = @sysconfdir@
579 target_alias = @target_alias@
580 top_build_prefix = @top_build_prefix@
581 top_builddir = @top_builddir@
582 top_srcdir = @top_srcdir@
583 GPG = gpg
584 GNUPGHOME = $(abs_builddir)
585 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME)
586 EXTRA_DIST = initial.test final.test
587 the_tests = \
588 t-addexistingsubkey \
589 t-keylist t-keylocate t-ownertrust t-tofuinfo \
590 t-encrypt t-verify t-various t-config t-remarks t-trustsignatures \
591 t-changeexpiryjob t-wkdlookup t-import
592
593 moc_files = \
594 t-addexistingsubkey.moc \
595 t-keylist.moc t-keylocate.moc t-ownertrust.moc t-tofuinfo.moc \
596 t-encrypt.moc t-support.hmoc t-wkspublish.moc t-verify.moc \
597 t-various.moc t-config.moc t-remarks.moc t-trustsignatures.moc \
598 t-changeexpiryjob.moc t-wkdlookup.moc t-import.moc
599
600 AM_LDFLAGS = -no-install
601 LDADD = ../../cpp/src/libgpgmepp.la ../src/libqgpgme.la \
602 ../../../src/libgpgme.la @GPGME_QT_LIBS@ @GPG_ERROR_LIBS@ \
603 @GPGME_QTTEST_LIBS@ @LDADD_FOR_TESTS_KLUDGE@ -lstdc++
604
605 AM_CPPFLAGS = -I$(top_srcdir)/lang/cpp/src -I$(top_builddir)/src \
606 @GPG_ERROR_CFLAGS@ @GPGME_QT_CFLAGS@ @GPG_ERROR_CFLAGS@ \
607 @LIBASSUAN_CFLAGS@ @GPGME_QTTEST_CFLAGS@ -DBUILDING_QGPGME \
608 -I$(top_srcdir)/lang/qt/src \
609 -DTOP_SRCDIR="$(top_srcdir)"
610
611 support_src = t-support.h t-support.cpp
612 t_addexistingsubkey_SOURCES = t-addexistingsubkey.cpp $(support_src)
613 t_keylist_SOURCES = t-keylist.cpp $(support_src)
614 t_keylocate_SOURCES = t-keylocate.cpp $(support_src)
615 t_ownertrust_SOURCES = t-ownertrust.cpp $(support_src)
616 t_tofuinfo_SOURCES = t-tofuinfo.cpp $(support_src)
617 t_encrypt_SOURCES = t-encrypt.cpp $(support_src)
618 t_wkspublish_SOURCES = t-wkspublish.cpp $(support_src)
619 t_verify_SOURCES = t-verify.cpp $(support_src)
620 t_various_SOURCES = t-various.cpp $(support_src)
621 t_config_SOURCES = t-config.cpp $(support_src)
622 t_remarks_SOURCES = t-remarks.cpp $(support_src)
623 t_trustsignatures_SOURCES = t-trustsignatures.cpp $(support_src)
624 t_changeexpiryjob_SOURCES = t-changeexpiryjob.cpp $(support_src)
625 t_wkdlookup_SOURCES = t-wkdlookup.cpp $(support_src)
626 t_import_SOURCES = t-import.cpp $(support_src)
627 run_exportjob_SOURCES = run-exportjob.cpp
628 run_importjob_SOURCES = run-importjob.cpp
629 run_keyformailboxjob_SOURCES = run-keyformailboxjob.cpp
630 run_receivekeysjob_SOURCES = run-receivekeysjob.cpp
631 nodist_t_keylist_SOURCES = $(moc_files)
632 BUILT_SOURCES = $(moc_files) pubring-stamp
633 CLEANFILES = secring.gpg pubring.gpg pubring.kbx trustdb.gpg dirmngr.conf \
634 gpg-agent.conf pubring.kbx~ S.gpg-agent gpg.conf pubring.gpg~ \
635 random_seed S.gpg-agent .gpg-v21-migrated pubring-stamp $(moc_files) \
636 gpg.conf tofu.db reader_0.status reader_1.status
637
638 all: $(BUILT_SOURCES)
639 $(MAKE) $(AM_MAKEFLAGS) all-am
640
641 .SUFFIXES:
642 .SUFFIXES: .cpp .h .hmoc .lo .moc .o .obj
643 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
644 @for dep in $?; do \
645 case '$(am__configure_deps)' in \
646 *$$dep*) \
647 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
648 && { if test -f $@; then exit 0; else break; fi; }; \
649 exit 1;; \
650 esac; \
651 done; \
652 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/qt/tests/Makefile'; \
653 $(am__cd) $(top_srcdir) && \
654 $(AUTOMAKE) --gnu lang/qt/tests/Makefile
655 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
656 @case '$?' in \
657 *config.status*) \
658 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
659 *) \
660 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
661 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
662 esac;
663
664 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
665 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
666
667 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
668 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
669 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
670 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
671 $(am__aclocal_m4_deps):
672
673 clean-noinstPROGRAMS:
674 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
675 echo " rm -f" $$list; \
676 rm -f $$list || exit $$?; \
677 test -n "$(EXEEXT)" || exit 0; \
678 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
679 echo " rm -f" $$list; \
680 rm -f $$list
681
682 run-exportjob$(EXEEXT): $(run_exportjob_OBJECTS) $(run_exportjob_DEPENDENCIES) $(EXTRA_run_exportjob_DEPENDENCIES)
683 @rm -f run-exportjob$(EXEEXT)
684 $(AM_V_CXXLD)$(CXXLINK) $(run_exportjob_OBJECTS) $(run_exportjob_LDADD) $(LIBS)
685
686 run-importjob$(EXEEXT): $(run_importjob_OBJECTS) $(run_importjob_DEPENDENCIES) $(EXTRA_run_importjob_DEPENDENCIES)
687 @rm -f run-importjob$(EXEEXT)
688 $(AM_V_CXXLD)$(CXXLINK) $(run_importjob_OBJECTS) $(run_importjob_LDADD) $(LIBS)
689
690 run-keyformailboxjob$(EXEEXT): $(run_keyformailboxjob_OBJECTS) $(run_keyformailboxjob_DEPENDENCIES) $(EXTRA_run_keyformailboxjob_DEPENDENCIES)
691 @rm -f run-keyformailboxjob$(EXEEXT)
692 $(AM_V_CXXLD)$(CXXLINK) $(run_keyformailboxjob_OBJECTS) $(run_keyformailboxjob_LDADD) $(LIBS)
693
694 run-receivekeysjob$(EXEEXT): $(run_receivekeysjob_OBJECTS) $(run_receivekeysjob_DEPENDENCIES) $(EXTRA_run_receivekeysjob_DEPENDENCIES)
695 @rm -f run-receivekeysjob$(EXEEXT)
696 $(AM_V_CXXLD)$(CXXLINK) $(run_receivekeysjob_OBJECTS) $(run_receivekeysjob_LDADD) $(LIBS)
697
698 t-addexistingsubkey$(EXEEXT): $(t_addexistingsubkey_OBJECTS) $(t_addexistingsubkey_DEPENDENCIES) $(EXTRA_t_addexistingsubkey_DEPENDENCIES)
699 @rm -f t-addexistingsubkey$(EXEEXT)
700 $(AM_V_CXXLD)$(CXXLINK) $(t_addexistingsubkey_OBJECTS) $(t_addexistingsubkey_LDADD) $(LIBS)
701
702 t-changeexpiryjob$(EXEEXT): $(t_changeexpiryjob_OBJECTS) $(t_changeexpiryjob_DEPENDENCIES) $(EXTRA_t_changeexpiryjob_DEPENDENCIES)
703 @rm -f t-changeexpiryjob$(EXEEXT)
704 $(AM_V_CXXLD)$(CXXLINK) $(t_changeexpiryjob_OBJECTS) $(t_changeexpiryjob_LDADD) $(LIBS)
705
706 t-config$(EXEEXT): $(t_config_OBJECTS) $(t_config_DEPENDENCIES) $(EXTRA_t_config_DEPENDENCIES)
707 @rm -f t-config$(EXEEXT)
708 $(AM_V_CXXLD)$(CXXLINK) $(t_config_OBJECTS) $(t_config_LDADD) $(LIBS)
709
710 t-encrypt$(EXEEXT): $(t_encrypt_OBJECTS) $(t_encrypt_DEPENDENCIES) $(EXTRA_t_encrypt_DEPENDENCIES)
711 @rm -f t-encrypt$(EXEEXT)
712 $(AM_V_CXXLD)$(CXXLINK) $(t_encrypt_OBJECTS) $(t_encrypt_LDADD) $(LIBS)
713
714 t-import$(EXEEXT): $(t_import_OBJECTS) $(t_import_DEPENDENCIES) $(EXTRA_t_import_DEPENDENCIES)
715 @rm -f t-import$(EXEEXT)
716 $(AM_V_CXXLD)$(CXXLINK) $(t_import_OBJECTS) $(t_import_LDADD) $(LIBS)
717
718 t-keylist$(EXEEXT): $(t_keylist_OBJECTS) $(t_keylist_DEPENDENCIES) $(EXTRA_t_keylist_DEPENDENCIES)
719 @rm -f t-keylist$(EXEEXT)
720 $(AM_V_CXXLD)$(CXXLINK) $(t_keylist_OBJECTS) $(t_keylist_LDADD) $(LIBS)
721
722 t-keylocate$(EXEEXT): $(t_keylocate_OBJECTS) $(t_keylocate_DEPENDENCIES) $(EXTRA_t_keylocate_DEPENDENCIES)
723 @rm -f t-keylocate$(EXEEXT)
724 $(AM_V_CXXLD)$(CXXLINK) $(t_keylocate_OBJECTS) $(t_keylocate_LDADD) $(LIBS)
725
726 t-ownertrust$(EXEEXT): $(t_ownertrust_OBJECTS) $(t_ownertrust_DEPENDENCIES) $(EXTRA_t_ownertrust_DEPENDENCIES)
727 @rm -f t-ownertrust$(EXEEXT)
728 $(AM_V_CXXLD)$(CXXLINK) $(t_ownertrust_OBJECTS) $(t_ownertrust_LDADD) $(LIBS)
729
730 t-remarks$(EXEEXT): $(t_remarks_OBJECTS) $(t_remarks_DEPENDENCIES) $(EXTRA_t_remarks_DEPENDENCIES)
731 @rm -f t-remarks$(EXEEXT)
732 $(AM_V_CXXLD)$(CXXLINK) $(t_remarks_OBJECTS) $(t_remarks_LDADD) $(LIBS)
733
734 t-tofuinfo$(EXEEXT): $(t_tofuinfo_OBJECTS) $(t_tofuinfo_DEPENDENCIES) $(EXTRA_t_tofuinfo_DEPENDENCIES)
735 @rm -f t-tofuinfo$(EXEEXT)
736 $(AM_V_CXXLD)$(CXXLINK) $(t_tofuinfo_OBJECTS) $(t_tofuinfo_LDADD) $(LIBS)
737
738 t-trustsignatures$(EXEEXT): $(t_trustsignatures_OBJECTS) $(t_trustsignatures_DEPENDENCIES) $(EXTRA_t_trustsignatures_DEPENDENCIES)
739 @rm -f t-trustsignatures$(EXEEXT)
740 $(AM_V_CXXLD)$(CXXLINK) $(t_trustsignatures_OBJECTS) $(t_trustsignatures_LDADD) $(LIBS)
741
742 t-various$(EXEEXT): $(t_various_OBJECTS) $(t_various_DEPENDENCIES) $(EXTRA_t_various_DEPENDENCIES)
743 @rm -f t-various$(EXEEXT)
744 $(AM_V_CXXLD)$(CXXLINK) $(t_various_OBJECTS) $(t_various_LDADD) $(LIBS)
745
746 t-verify$(EXEEXT): $(t_verify_OBJECTS) $(t_verify_DEPENDENCIES) $(EXTRA_t_verify_DEPENDENCIES)
747 @rm -f t-verify$(EXEEXT)
748 $(AM_V_CXXLD)$(CXXLINK) $(t_verify_OBJECTS) $(t_verify_LDADD) $(LIBS)
749
750 t-wkdlookup$(EXEEXT): $(t_wkdlookup_OBJECTS) $(t_wkdlookup_DEPENDENCIES) $(EXTRA_t_wkdlookup_DEPENDENCIES)
751 @rm -f t-wkdlookup$(EXEEXT)
752 $(AM_V_CXXLD)$(CXXLINK) $(t_wkdlookup_OBJECTS) $(t_wkdlookup_LDADD) $(LIBS)
753
754 t-wkspublish$(EXEEXT): $(t_wkspublish_OBJECTS) $(t_wkspublish_DEPENDENCIES) $(EXTRA_t_wkspublish_DEPENDENCIES)
755 @rm -f t-wkspublish$(EXEEXT)
756 $(AM_V_CXXLD)$(CXXLINK) $(t_wkspublish_OBJECTS) $(t_wkspublish_LDADD) $(LIBS)
757
758 mostlyclean-compile:
759 -rm -f *.$(OBJEXT)
760
761 distclean-compile:
762 -rm -f *.tab.c
763
764 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-exportjob.Po@am__quote@ # am--include-marker
765 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-importjob.Po@am__quote@ # am--include-marker
766 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-keyformailboxjob.Po@am__quote@ # am--include-marker
767 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-receivekeysjob.Po@am__quote@ # am--include-marker
768 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-addexistingsubkey.Po@am__quote@ # am--include-marker
769 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-changeexpiryjob.Po@am__quote@ # am--include-marker
770 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-config.Po@am__quote@ # am--include-marker
771 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt.Po@am__quote@ # am--include-marker
772 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-import.Po@am__quote@ # am--include-marker
773 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-keylist.Po@am__quote@ # am--include-marker
774 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-keylocate.Po@am__quote@ # am--include-marker
775 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-ownertrust.Po@am__quote@ # am--include-marker
776 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-remarks.Po@am__quote@ # am--include-marker
777 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-support.Po@am__quote@ # am--include-marker
778 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-tofuinfo.Po@am__quote@ # am--include-marker
779 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-trustsignatures.Po@am__quote@ # am--include-marker
780 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-various.Po@am__quote@ # am--include-marker
781 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-verify.Po@am__quote@ # am--include-marker
782 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-wkdlookup.Po@am__quote@ # am--include-marker
783 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-wkspublish.Po@am__quote@ # am--include-marker
784
785 $(am__depfiles_remade):
786 @$(MKDIR_P) $(@D)
787 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
788
789 am--depfiles: $(am__depfiles_remade)
790
791 .cpp.o:
792 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
793 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
794 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
795 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
796 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $<
797
798 .cpp.obj:
799 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
800 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
801 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
802 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
803 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
804
805 .cpp.lo:
806 @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
807 @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
808 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
809 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
810 @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $<
811
812 mostlyclean-libtool:
813 -rm -f *.lo
814
815 clean-libtool:
816 -rm -rf .libs _libs
817
818 ID: $(am__tagged_files)
819 $(am__define_uniq_tagged_files); mkid -fID $$unique
820 tags: tags-am
821 TAGS: tags
822
823 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
824 set x; \
825 here=`pwd`; \
826 $(am__define_uniq_tagged_files); \
827 shift; \
828 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
829 test -n "$$unique" || unique=$$empty_fix; \
830 if test $$# -gt 0; then \
831 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
832 "$$@" $$unique; \
833 else \
834 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
835 $$unique; \
836 fi; \
837 fi
838 ctags: ctags-am
839
840 CTAGS: ctags
841 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
842 $(am__define_uniq_tagged_files); \
843 test -z "$(CTAGS_ARGS)$$unique" \
844 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
845 $$unique
846
847 GTAGS:
848 here=`$(am__cd) $(top_builddir) && pwd` \
849 && $(am__cd) $(top_srcdir) \
850 && gtags -i $(GTAGS_ARGS) "$$here"
851 cscopelist: cscopelist-am
852
853 cscopelist-am: $(am__tagged_files)
854 list='$(am__tagged_files)'; \
855 case "$(srcdir)" in \
856 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
857 *) sdir=$(subdir)/$(srcdir) ;; \
858 esac; \
859 for i in $$list; do \
860 if test -f "$$i"; then \
861 echo "$(subdir)/$$i"; \
862 else \
863 echo "$$sdir/$$i"; \
864 fi; \
865 done >> $(top_builddir)/cscope.files
866
867 distclean-tags:
868 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
869
870 check-TESTS: $(TESTS)
871 @failed=0; all=0; xfail=0; xpass=0; skip=0; \
872 srcdir=$(srcdir); export srcdir; \
873 list=' $(TESTS) '; \
874 $(am__tty_colors); \
875 if test -n "$$list"; then \
876 for tst in $$list; do \
877 if test -f ./$$tst; then dir=./; \
878 elif test -f $$tst; then dir=; \
879 else dir="$(srcdir)/"; fi; \
880 if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
881 all=`expr $$all + 1`; \
882 case " $(XFAIL_TESTS) " in \
883 *[\ \ ]$$tst[\ \ ]*) \
884 xpass=`expr $$xpass + 1`; \
885 failed=`expr $$failed + 1`; \
886 col=$$red; res=XPASS; \
887 ;; \
888 *) \
889 col=$$grn; res=PASS; \
890 ;; \
891 esac; \
892 elif test $$? -ne 77; then \
893 all=`expr $$all + 1`; \
894 case " $(XFAIL_TESTS) " in \
895 *[\ \ ]$$tst[\ \ ]*) \
896 xfail=`expr $$xfail + 1`; \
897 col=$$lgn; res=XFAIL; \
898 ;; \
899 *) \
900 failed=`expr $$failed + 1`; \
901 col=$$red; res=FAIL; \
902 ;; \
903 esac; \
904 else \
905 skip=`expr $$skip + 1`; \
906 col=$$blu; res=SKIP; \
907 fi; \
908 echo "$${col}$$res$${std}: $$tst"; \
909 done; \
910 if test "$$all" -eq 1; then \
911 tests="test"; \
912 All=""; \
913 else \
914 tests="tests"; \
915 All="All "; \
916 fi; \
917 if test "$$failed" -eq 0; then \
918 if test "$$xfail" -eq 0; then \
919 banner="$$All$$all $$tests passed"; \
920 else \
921 if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
922 banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
923 fi; \
924 else \
925 if test "$$xpass" -eq 0; then \
926 banner="$$failed of $$all $$tests failed"; \
927 else \
928 if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
929 banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
930 fi; \
931 fi; \
932 dashes="$$banner"; \
933 skipped=""; \
934 if test "$$skip" -ne 0; then \
935 if test "$$skip" -eq 1; then \
936 skipped="($$skip test was not run)"; \
937 else \
938 skipped="($$skip tests were not run)"; \
939 fi; \
940 test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
941 dashes="$$skipped"; \
942 fi; \
943 report=""; \
944 if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
945 report="Please report to $(PACKAGE_BUGREPORT)"; \
946 test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
947 dashes="$$report"; \
948 fi; \
949 dashes=`echo "$$dashes" | sed s/./=/g`; \
950 if test "$$failed" -eq 0; then \
951 col="$$grn"; \
952 else \
953 col="$$red"; \
954 fi; \
955 echo "$${col}$$dashes$${std}"; \
956 echo "$${col}$$banner$${std}"; \
957 test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
958 test -z "$$report" || echo "$${col}$$report$${std}"; \
959 echo "$${col}$$dashes$${std}"; \
960 test "$$failed" -eq 0; \
961 else :; fi
962
963 distdir: $(BUILT_SOURCES)
964 $(MAKE) $(AM_MAKEFLAGS) distdir-am
965
966 distdir-am: $(DISTFILES)
967 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
968 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
969 list='$(DISTFILES)'; \
970 dist_files=`for file in $$list; do echo $$file; done | \
971 sed -e "s|^$$srcdirstrip/||;t" \
972 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
973 case $$dist_files in \
974 */*) $(MKDIR_P) `echo "$$dist_files" | \
975 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
976 sort -u` ;; \
977 esac; \
978 for file in $$dist_files; do \
979 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
980 if test -d $$d/$$file; then \
981 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
982 if test -d "$(distdir)/$$file"; then \
983 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
984 fi; \
985 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
986 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
987 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
988 fi; \
989 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
990 else \
991 test -f "$(distdir)/$$file" \
992 || cp -p $$d/$$file "$(distdir)/$$file" \
993 || exit 1; \
994 fi; \
995 done
996 check-am: all-am
997 $(MAKE) $(AM_MAKEFLAGS) check-TESTS
998 check: $(BUILT_SOURCES)
999 $(MAKE) $(AM_MAKEFLAGS) check-am
1000 all-am: Makefile $(PROGRAMS)
1001 installdirs:
1002 install: $(BUILT_SOURCES)
1003 $(MAKE) $(AM_MAKEFLAGS) install-am
1004 install-exec: $(BUILT_SOURCES)
1005 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
1006 install-data: install-data-am
1007 uninstall: uninstall-am
1008
1009 install-am: all-am
1010 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
1011
1012 installcheck: installcheck-am
1013 install-strip:
1014 if test -z '$(STRIP)'; then \
1015 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1016 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1017 install; \
1018 else \
1019 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1020 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1021 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
1022 fi
1023 mostlyclean-generic:
1024
1025 clean-generic:
1026 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
1027
1028 distclean-generic:
1029 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
1030 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
1031
1032 maintainer-clean-generic:
1033 @echo "This command is intended for maintainers to use"
1034 @echo "it deletes files that may require special tools to rebuild."
1035 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
1036 clean: clean-am
1037
1038 clean-am: clean-generic clean-libtool clean-local clean-noinstPROGRAMS \
1039 mostlyclean-am
1040
1041 distclean: distclean-am
1042 -rm -f ./$(DEPDIR)/run-exportjob.Po
1043 -rm -f ./$(DEPDIR)/run-importjob.Po
1044 -rm -f ./$(DEPDIR)/run-keyformailboxjob.Po
1045 -rm -f ./$(DEPDIR)/run-receivekeysjob.Po
1046 -rm -f ./$(DEPDIR)/t-addexistingsubkey.Po
1047 -rm -f ./$(DEPDIR)/t-changeexpiryjob.Po
1048 -rm -f ./$(DEPDIR)/t-config.Po
1049 -rm -f ./$(DEPDIR)/t-encrypt.Po
1050 -rm -f ./$(DEPDIR)/t-import.Po
1051 -rm -f ./$(DEPDIR)/t-keylist.Po
1052 -rm -f ./$(DEPDIR)/t-keylocate.Po
1053 -rm -f ./$(DEPDIR)/t-ownertrust.Po
1054 -rm -f ./$(DEPDIR)/t-remarks.Po
1055 -rm -f ./$(DEPDIR)/t-support.Po
1056 -rm -f ./$(DEPDIR)/t-tofuinfo.Po
1057 -rm -f ./$(DEPDIR)/t-trustsignatures.Po
1058 -rm -f ./$(DEPDIR)/t-various.Po
1059 -rm -f ./$(DEPDIR)/t-verify.Po
1060 -rm -f ./$(DEPDIR)/t-wkdlookup.Po
1061 -rm -f ./$(DEPDIR)/t-wkspublish.Po
1062 -rm -f Makefile
1063 distclean-am: clean-am distclean-compile distclean-generic \
1064 distclean-tags
1065
1066 dvi: dvi-am
1067
1068 dvi-am:
1069
1070 html: html-am
1071
1072 html-am:
1073
1074 info: info-am
1075
1076 info-am:
1077
1078 install-data-am:
1079
1080 install-dvi: install-dvi-am
1081
1082 install-dvi-am:
1083
1084 install-exec-am:
1085
1086 install-html: install-html-am
1087
1088 install-html-am:
1089
1090 install-info: install-info-am
1091
1092 install-info-am:
1093
1094 install-man:
1095
1096 install-pdf: install-pdf-am
1097
1098 install-pdf-am:
1099
1100 install-ps: install-ps-am
1101
1102 install-ps-am:
1103
1104 installcheck-am:
1105
1106 maintainer-clean: maintainer-clean-am
1107 -rm -f ./$(DEPDIR)/run-exportjob.Po
1108 -rm -f ./$(DEPDIR)/run-importjob.Po
1109 -rm -f ./$(DEPDIR)/run-keyformailboxjob.Po
1110 -rm -f ./$(DEPDIR)/run-receivekeysjob.Po
1111 -rm -f ./$(DEPDIR)/t-addexistingsubkey.Po
1112 -rm -f ./$(DEPDIR)/t-changeexpiryjob.Po
1113 -rm -f ./$(DEPDIR)/t-config.Po
1114 -rm -f ./$(DEPDIR)/t-encrypt.Po
1115 -rm -f ./$(DEPDIR)/t-import.Po
1116 -rm -f ./$(DEPDIR)/t-keylist.Po
1117 -rm -f ./$(DEPDIR)/t-keylocate.Po
1118 -rm -f ./$(DEPDIR)/t-ownertrust.Po
1119 -rm -f ./$(DEPDIR)/t-remarks.Po
1120 -rm -f ./$(DEPDIR)/t-support.Po
1121 -rm -f ./$(DEPDIR)/t-tofuinfo.Po
1122 -rm -f ./$(DEPDIR)/t-trustsignatures.Po
1123 -rm -f ./$(DEPDIR)/t-various.Po
1124 -rm -f ./$(DEPDIR)/t-verify.Po
1125 -rm -f ./$(DEPDIR)/t-wkdlookup.Po
1126 -rm -f ./$(DEPDIR)/t-wkspublish.Po
1127 -rm -f Makefile
1128 maintainer-clean-am: distclean-am maintainer-clean-generic
1129
1130 mostlyclean: mostlyclean-am
1131
1132 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
1133 mostlyclean-libtool
1134
1135 pdf: pdf-am
1136
1137 pdf-am:
1138
1139 ps: ps-am
1140
1141 ps-am:
1142
1143 uninstall-am:
1144
1145 .MAKE: all check check-am install install-am install-exec \
1146 install-strip
1147
1148 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \
1149 check-am clean clean-generic clean-libtool clean-local \
1150 clean-noinstPROGRAMS cscopelist-am ctags ctags-am distclean \
1151 distclean-compile distclean-generic distclean-libtool \
1152 distclean-tags distdir dvi dvi-am html html-am info info-am \
1153 install install-am install-data install-data-am install-dvi \
1154 install-dvi-am install-exec install-exec-am install-html \
1155 install-html-am install-info install-info-am install-man \
1156 install-pdf install-pdf-am install-ps install-ps-am \
1157 install-strip installcheck installcheck-am installdirs \
1158 maintainer-clean maintainer-clean-generic mostlyclean \
1159 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
1160 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am
1161
1162 .PRECIOUS: Makefile
1163
1164
1165 clean-local:
1166 -$(TESTS_ENVIRONMENT) $(top_srcdir)/tests/start-stop-agent --stop
1167 -rm -fR private-keys-v1.d crls.d
1168
1169 pubring-stamp: $(top_srcdir)/tests/gpg/pubdemo.asc \
1170 $(top_srcdir)/tests/gpg/secdemo.asc
1171 -$(TESTS_ENVIRONMENT) gpgconf --kill all
1172 echo "ignore-invalid-option allow-loopback-pinentry" > $(abs_builddir)/gpg-agent.conf
1173 echo "allow-loopback-pinentry" >> gpg-agent.conf
1174 echo "ignore-invalid-option pinentry-mode" > gpg.conf
1175 echo "pinentry-mode loopback" >> gpg.conf
1176 $(TESTS_ENVIRONMENT) $(GPG) --no-permission-warning \
1177 --import $(top_srcdir)/tests/gpg/pubdemo.asc
1178 $(TESTS_ENVIRONMENT) $(GPG) --no-permission-warning \
1179 --passphrase "abc" \
1180 --import $(top_srcdir)/tests/gpg/secdemo.asc
1181 touch pubring-stamp
1182
1183 .cpp.moc:
1184 $(MOC) `test -f '$<' || echo '$(srcdir)/'`$< -o $@
1185
1186 .h.hmoc:
1187 $(MOC) `test -f '$<' || echo '$(srcdir)/'`$< -o $@
1188
1189 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1190 # Otherwise a system limit (for SysV at least) may be exceeded.
1191 .NOEXPORT:
0 #!/bin/sh
1
2 # stop the dirmngr that may have been started
3 gpgconf --kill dirmngr
4
5 exit 0
0 /*
1 run-exportjob.cpp
2
3 This file is part of QGpgME's test suite.
4 Copyright (c) 2022 by g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License,
9 version 2, as published by the Free Software Foundation.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31
32 #ifdef HAVE_CONFIG_H
33 #include "config.h"
34 #endif
35
36 #include <exportjob.h>
37 #include <protocol.h>
38
39 #include <context.h>
40
41 #include <QCoreApplication>
42
43 #include <iostream>
44
45 using namespace GpgME;
46 using std::cout;
47 using std::cerr;
48
49 static void showUsageAndExitWithCode(int exitCode)
50 {
51 cerr << "Usage: run-exportjob [OPTION]... [PATTERN]...\n"
52 "Options:\n"
53 " --secret export secret keys instead of public keys\n"
54 " --secret-subkey export secret subkeys instead of public keys\n";
55
56 exit(exitCode);
57 }
58
59 static auto createExportJob(unsigned int mode)
60 {
61 if (mode & Context::ExportSecretSubkey) {
62 return QGpgME::openpgp()->secretSubkeyExportJob(/*armor=*/true);
63 } else if (mode & Context::ExportSecret) {
64 return QGpgME::openpgp()->secretKeyExportJob(/*armor=*/true);
65 }
66 return QGpgME::openpgp()->publicKeyExportJob(/*armor=*/true);
67 }
68
69 int main(int argc, char *argv[])
70 {
71 GpgME::initializeLibrary();
72
73 QCoreApplication app{argc, argv};
74
75 unsigned int exportMode = 0;
76
77 auto arguments = app.arguments();
78 if (!arguments.isEmpty()) {
79 arguments.pop_front(); // remove program name
80 }
81 while (!arguments.isEmpty()) {
82 const auto &arg = arguments.front();
83 if (!arg.startsWith(QLatin1String{"--"})) {
84 break;
85 }
86 if (arg == QLatin1String{"--"}) {
87 arguments.pop_front();
88 break;
89 }
90 if (arg == QLatin1String{"--help"}) {
91 showUsageAndExitWithCode(0);
92 } else if (arg == QLatin1String{"--secret"}) {
93 exportMode = Context::ExportSecret;
94 arguments.pop_front();
95 } else if (arg == QLatin1String{"--secret-subkey"}) {
96 exportMode = Context::ExportSecretSubkey;
97 arguments.pop_front();
98 } else {
99 cerr << "Error: Invalid option " << arg.toStdString() << std::endl;
100 showUsageAndExitWithCode(1);
101 }
102 }
103
104 auto job = createExportJob(exportMode);
105 QObject::connect(job, &QGpgME::ExportJob::result,
106 &app, [&app] (const GpgME::Error &err, const QByteArray &keyData, const QString &, const GpgME::Error &) {
107 if (err) {
108 cerr << "The ChangeExpiryJob failed with" << err.asString() << ".";
109 app.exit(1);
110 return;
111 }
112 cout << "Begin Result:\n" << keyData.toStdString() << "End Result:\n";
113 app.exit();
114 });
115 job->start(arguments);
116
117 return app.exec();
118 }
0 /*
1 run-importjob.cpp
2
3 This file is part of QGpgME's test suite.
4 Copyright (c) 2021 by g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License,
9 version 2, as published by the Free Software Foundation.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31
32 #ifdef HAVE_CONFIG_H
33 #include "config.h"
34 #endif
35
36 #include <importjob.h>
37 #include <importresult.h>
38 #include <protocol.h>
39
40 #include <QFile>
41 #include <QFileInfo>
42
43 #include <QDebug>
44
45 #include <set>
46 #include <sstream>
47
48 GpgME::Protocol guessProtocol(const QString &filename)
49 {
50 static const std::set<QString> cmsExtensions = {"cer", "crt", "der", "p12", "p7c", "pem", "pfx"};
51 static const std::set<QString> pgpExtensions = {"asc", "gpg", "pgp"};
52
53 const auto extension = QFileInfo{filename}.suffix();
54 if (cmsExtensions.find(extension) != cmsExtensions.end()) {
55 return GpgME::CMS;
56 } else if (pgpExtensions.find(extension) != pgpExtensions.end()) {
57 return GpgME::OpenPGP;
58 }
59 qDebug() << "Unknown file name extension" << extension;
60 return GpgME::UnknownProtocol;
61 }
62
63 int main(int argc, char **argv)
64 {
65 GpgME::initializeLibrary();
66
67 if (argc != 2) {
68 qInfo().noquote() << "Usage:" << argv[0] << "<certificate file>";
69 return 1;
70 }
71 const auto filename = QString::fromLocal8Bit(argv[1]);
72
73 QFile f{filename};
74 if (!f.exists()) {
75 qWarning() << "Error: File not found" << filename;
76 return 1;
77 }
78 const auto protocol = guessProtocol(filename);
79 if (protocol == GpgME::UnknownProtocol) {
80 qWarning() << "Error: Unknown file type";
81 return 1;
82 }
83 if (!f.open(QIODevice::ReadOnly)) {
84 qWarning() << "Error: Failed to open file" << filename << "for reading.";
85 return 1;
86 }
87
88 const auto keyData = f.readAll();
89 auto job = (protocol == GpgME::CMS ? QGpgME::smime() : QGpgME::openpgp())->importJob();
90 const auto result = job->exec(keyData);
91 qDebug() << "Result error:" << result.error().asString();
92 std::ostringstream ostr;
93 ostr << result;
94 for (const auto &line : QString::fromStdString(ostr.str()).split('\n')) {
95 qDebug().noquote() << line;
96 }
97 return 0;
98 }
0 /*
1 run-receivekeysjob.cpp
2
3 This file is part of QGpgME's test suite.
4 Copyright (c) 2022 by g10 Code GmbH
5 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
6
7 QGpgME is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License,
9 version 2, as published by the Free Software Foundation.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31
32 #ifdef HAVE_CONFIG_H
33 #include "config.h"
34 #endif
35
36 #include <importresult.h>
37 #include <protocol.h>
38 #include <receivekeysjob.h>
39
40 #include <QCoreApplication>
41 #include <QDebug>
42
43 #include <iostream>
44
45 int main(int argc, char **argv)
46 {
47 GpgME::initializeLibrary();
48
49 if (argc < 2) {
50 std::cerr << "Usage: " << argv[0] << " KEYID..." << std::endl;
51 return 1;
52 }
53
54 QCoreApplication app(argc, argv);
55 const QStringList keyIds = qApp->arguments().mid(1);
56
57 auto job = QGpgME::openpgp()->receiveKeysJob();
58 const auto result = job->exec(keyIds);
59
60 std::cout << "Result: " << result.error().asString() << std::endl;
61 std::cout << "Details:\n" << result << std::endl;
62
63 return 0;
64 }
0 /* t-addexistingsubkey.cpp
1
2 This file is part of qgpgme, the Qt API binding for gpgme
3 Copyright (c) 2022 g10 Code GmbH
4 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
5
6 QGpgME is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public License as
8 published by the Free Software Foundation; either version 2 of the
9 License, or (at your option) any later version.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31 #ifdef HAVE_CONFIG_H
32 #include "config.h"
33 #endif
34
35 #include "t-support.h"
36
37 #include "addexistingsubkeyjob.h"
38 #include "protocol.h"
39
40 #include <QSignalSpy>
41 #include <QTest>
42
43 #include "context.h"
44 #include "data.h"
45 #include "engineinfo.h"
46
47 #include <algorithm>
48
49 using namespace QGpgME;
50 using namespace GpgME;
51
52 static const char *requiredVersion = "2.3.5";
53
54 /* Test keys
55 sec# ed25519 2022-01-13 [SC]
56 1CB8C6A0317AA83F44FE009932392C82B814C8E0
57 uid [ unknown] source-key@example.net
58 ssb cv25519 2022-01-13 [E]
59 ssb cv25519 2022-01-13 [E] [expires: 2100-01-01]
60
61 sec ed25519 2022-01-13 [SC]
62 C3C87F0A3920B01F9E4450EA2B79F21D4DD10BFC
63 uid [ unknown] target-key@example.net
64 ssb cv25519 2022-01-13 [E]
65 * generated with
66 export GNUPGHOME=$(mktemp -d)
67 gpg -K
68 gpg --batch --pinentry-mode loopback --passphrase abc --quick-gen-key source-key@example.net default default never
69 fpr=$(gpg -k --with-colons source-key@example.net | grep ^fpr | head -1 | cut -d ':' -f 10)
70 gpg --batch --pinentry-mode loopback --passphrase abc --quick-add-key ${fpr} default default 21000101T120000
71 gpg --batch --pinentry-mode loopback --passphrase abc --quick-gen-key target-key@example.net default default never
72 gpg -K
73 gpg --export-secret-subkeys --armor --batch --pinentry-mode loopback --passphrase abc --comment source-key@example.net source-key@example.net | sed 's/\(.*\)/ "\1\\n"/'
74 gpg --export-secret-keys --armor --batch --pinentry-mode loopback --passphrase abc --comment target-key@example.net target-key@example.net | sed 's/\(.*\)/ "\1\\n"/'
75 #rm -rf ${GNUPGHOME}
76 unset GNUPGHOME
77 */
78 static const char *testKeyData =
79 "-----BEGIN PGP PRIVATE KEY BLOCK-----\n"
80 "Comment: source-key@example.net\n"
81 "\n"
82 "lDsEYd/ujBYJKwYBBAHaRw8BAQdAwiZPINTcrpgmu6ZWSaPZlcRSd4nDuofVMhe7\n"
83 "c2XrFyT/AGUAR05VAbQWc291cmNlLWtleUBleGFtcGxlLm5ldIiUBBMWCgA8FiEE\n"
84 "HLjGoDF6qD9E/gCZMjksgrgUyOAFAmHf7owCGwMFCwkIBwIDIgIBBhUKCQgLAgQW\n"
85 "AgMBAh4HAheAAAoJEDI5LIK4FMjgupIA/Au2YEAT9dYdJd0eJCJerG5YAeoB+uBs\n"
86 "mBkgr6xXE0bIAP43b6u1Jtvf/Wm3BhRbLd5Tg67Ba4CIZ8ZLGng73FBoBpyLBGHf\n"
87 "7owSCisGAQQBl1UBBQEBB0Cpg8Qof/WShxROZZtmPnw24vTk0R8nIAF1CZJ0bG/C\n"
88 "SwMBCAf+BwMCtzxziVxQEor8w/VVzHp4/hVSCUyrpiX7Djf04cIMs2bFPduZLgxb\n"
89 "c1SXhlgiqU0YBNntbGGNdKjTP6FMbYWq1+NwQm6ZXtC76LPG7syM94h4BBgWCgAg\n"
90 "FiEEHLjGoDF6qD9E/gCZMjksgrgUyOAFAmHf7owCGwwACgkQMjksgrgUyOCI0wEA\n"
91 "+f56fkvDDUwMOMw7n4+GKpfJXpWhVL08ttccbBOa/9IA/2HYA/78ZaD8E5EyqAEK\n"
92 "Aj9Au+2oJu9V5qo92QEoqwYHnIsEYd/vgxIKKwYBBAGXVQEFAQEHQBa9FxJkm/9D\n"
93 "xABildkaYMrbJbu8BPk6uv9V8aLmv9FnAwEIB/4HAwIPhcbN8s6OzPz8/g78TrCh\n"
94 "xqQb2kygCEj+OQ4/XXU3lus2b5xS5h44LGt99Wisqx+wVPDXmPDJOaxjhHXDmJxd\n"
95 "/LplIEhykojSm3uUDxERiH4EGBYKACYWIQQcuMagMXqoP0T+AJkyOSyCuBTI4AUC\n"
96 "Yd/vgwIbDAUJkqcQPQAKCRAyOSyCuBTI4IUjAP9BTfOD+jy6lLmzNO9pquRSAxi/\n"
97 "PQuglGtpS0LQEJMEOwD+PFnsMe2EtQ+WVSDBeB7O0m61EXeY+RhpuhNtsNXVuwc=\n"
98 "=wIPU\n"
99 "-----END PGP PRIVATE KEY BLOCK-----\n"
100 "-----BEGIN PGP PRIVATE KEY BLOCK-----\n"
101 "Comment: target-key@example.net\n"
102 "\n"
103 "lIYEYd/v/RYJKwYBBAHaRw8BAQdAKoILWXG3yaLb2EniNKQLUjwsrvy5vgAN299J\n"
104 "W5cFbrz+BwMC/uKbCq3sK5H8QVtEQ/IxGmjWNBpy6c8EDlOG4APi4o4VE+bEYD8w\n"
105 "J3Kk/lzSm6ZT5vC6DDASks797omjXD+J7zZ0vtTPvheYi/nsVz2UebQWdGFyZ2V0\n"
106 "LWtleUBleGFtcGxlLm5ldIiUBBMWCgA8FiEEw8h/CjkgsB+eRFDqK3nyHU3RC/wF\n"
107 "AmHf7/0CGwMFCwkIBwIDIgIBBhUKCQgLAgQWAgMBAh4HAheAAAoJECt58h1N0Qv8\n"
108 "rXcBAPxnkXqpp4IY3iTKV5XAdo7Uys7U/joUD73rj2XEvgI1AQDhKK4PLxPhf3ki\n"
109 "FKU0RA7itxzOH+F8bQ5BdYS49jDPCpyLBGHf7/0SCisGAQQBl1UBBQEBB0Dq9rwA\n"
110 "hAA2UFJShFsLFp7+g4uhWDfuDa3VjeIQRM+9QgMBCAf+BwMCMfCTl0LNqsn836t5\n"
111 "f2ZHBuMcNs4JWYmdLAIVaewEHq7zhOsX3iB+/yxwu9g2mXc4XUJ1iQzXLOYwgGov\n"
112 "8jIovrr01hDkSg4rvM9JKMWdd4h4BBgWCgAgFiEEw8h/CjkgsB+eRFDqK3nyHU3R\n"
113 "C/wFAmHf7/0CGwwACgkQK3nyHU3RC/xyfAEAqnMdSv6FTAwAWrYvJqJtSVoEhjMn\n"
114 "3c2qMsu34Bk86/MBAKHbLFmdyePvHaxKeO8CkQDoJzK8rYzw3RAmq/5JsQkL\n"
115 "=rOVf\n"
116 "-----END PGP PRIVATE KEY BLOCK-----\n";
117
118 class AddExistingSubkeyJobTest : public QGpgMETest
119 {
120 Q_OBJECT
121
122 private Q_SLOTS:
123
124 void initTestCase()
125 {
126 QGpgMETest::initTestCase();
127
128 // set up the test fixture for this test
129 qputenv("GNUPGHOME", mGnupgHomeTestFixture.path().toUtf8());
130 QVERIFY(importSecretKeys(testKeyData, 2));
131 }
132
133 void init()
134 {
135 if (GpgME::engineInfo(GpgME::GpgEngine).engineVersion() < requiredVersion) {
136 QSKIP("gpg does not yet support adding an existing subkey to another key via the command API");
137 }
138
139 // set up a copy of the test fixture for each test function
140 mGnupgHomeTestCopy.reset(new QTemporaryDir{});
141 QVERIFY(copyKeyrings(mGnupgHomeTestFixture.path(), mGnupgHomeTestCopy->path()));
142 qputenv("GNUPGHOME", mGnupgHomeTestCopy->path().toUtf8());
143 }
144
145 void testAddExistingSubkeyAsync()
146 {
147 // Get the key the subkey should be added to
148 auto key = getTestKey("target-key@example.net");
149 QVERIFY(!key.isNull());
150
151 // Get the key with the subkey to add
152 auto sourceKey = getTestKey("source-key@example.net", 3);
153 QVERIFY(!sourceKey.isNull());
154
155 auto job = std::unique_ptr<AddExistingSubkeyJob>{openpgp()->addExistingSubkeyJob()};
156 hookUpPassphraseProvider(job.get());
157
158 Error result;
159 connect(job.get(), &AddExistingSubkeyJob::result,
160 job.get(), [this, &result](const Error &result_) {
161 result = result_;
162 Q_EMIT asyncDone();
163 });
164 QVERIFY(!job->start(key, sourceKey.subkey(1)));
165 job.release(); // after the job has been started it's on its own
166
167 QSignalSpy spy (this, SIGNAL(asyncDone()));
168 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
169
170 QVERIFY(result.code() == GPG_ERR_NO_ERROR);
171 key.update();
172 QCOMPARE(key.numSubkeys(), 3u);
173 }
174
175 void testAddExistingSubkeySync()
176 {
177 // Get the key the subkey should be added to
178 auto key = getTestKey("target-key@example.net");
179 QVERIFY(!key.isNull());
180
181 // Get the key with the subkey to add
182 auto sourceKey = getTestKey("source-key@example.net", 3);
183 QVERIFY(!sourceKey.isNull());
184 auto sourceSubkey = sourceKey.subkey(1);
185 QVERIFY(sourceSubkey.expirationTime() == 0);
186
187 auto job = std::unique_ptr<AddExistingSubkeyJob>{openpgp()->addExistingSubkeyJob()};
188 hookUpPassphraseProvider(job.get());
189
190 const auto result = job->exec(key, sourceSubkey);
191
192 QVERIFY(result.code() == GPG_ERR_NO_ERROR);
193 key.update();
194 QCOMPARE(key.numSubkeys(), 3u);
195 QCOMPARE(key.subkey(2).expirationTime(), 0);
196 }
197
198 void testAddExistingSubkeyWithExpiration()
199 {
200 // Get the key the subkey should be added to
201 auto key = getTestKey("target-key@example.net");
202 QVERIFY(!key.isNull());
203
204 // Get the key with the subkey to add
205 auto sourceKey = getTestKey("source-key@example.net", 3);
206 QVERIFY(!sourceKey.isNull());
207 auto sourceSubkey = sourceKey.subkey(2);
208 QVERIFY(sourceSubkey.expirationTime() != 0);
209
210 auto job = std::unique_ptr<AddExistingSubkeyJob>{openpgp()->addExistingSubkeyJob()};
211 hookUpPassphraseProvider(job.get());
212
213 const auto result = job->exec(key, sourceSubkey);
214
215 QVERIFY(result.code() == GPG_ERR_NO_ERROR);
216 key.update();
217 QCOMPARE(key.numSubkeys(), 3u);
218
219 // allow 1 second different expiration because gpg calculates with
220 // expiration as difference to current time and takes current time
221 // several times
222 const auto allowedDeltaTSeconds = 1;
223 const auto expectedExpirationRange = std::make_pair(
224 sourceSubkey.expirationTime() - allowedDeltaTSeconds,
225 sourceSubkey.expirationTime() + allowedDeltaTSeconds);
226 const auto actualExpiration = key.subkey(2).expirationTime();
227 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
228 ("actual: " + std::to_string(actualExpiration) +
229 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
230 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
231 ("actual: " + std::to_string(actualExpiration) +
232 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
233 }
234
235 private:
236 Key getTestKey(const char *pattern, unsigned int expectedSubkeys = 2)
237 {
238 auto ctx = Context::create(OpenPGP);
239 VERIFY_OR_OBJECT(ctx);
240
241 Error err;
242 auto key = ctx->key(pattern, err, /*secret=*/true);
243 VERIFY_OR_OBJECT(!err);
244 VERIFY_OR_OBJECT(!key.isNull());
245 COMPARE_OR_OBJECT(key.numSubkeys(), expectedSubkeys);
246 for (unsigned int i = 0; i < key.numSubkeys(); ++i) {
247 VERIFY_OR_OBJECT(!key.subkey(i).isNull());
248 }
249 return key;
250 }
251
252 private:
253 QTemporaryDir mGnupgHomeTestFixture;
254 std::unique_ptr<QTemporaryDir> mGnupgHomeTestCopy;
255 };
256
257 QTEST_MAIN(AddExistingSubkeyJobTest)
258
259 #include "t-addexistingsubkey.moc"
0 /* t-changeexpiryjob.cpp
1
2 This file is part of qgpgme, the Qt API binding for gpgme
3 Copyright (c) 2021 g10 Code GmbH
4 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
5
6 QGpgME is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public License as
8 published by the Free Software Foundation; either version 2 of the
9 License, or (at your option) any later version.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31
32 #ifdef HAVE_CONFIG_H
33 #include "config.h"
34 #endif
35
36 #include "t-support.h"
37
38 #include "changeexpiryjob.h"
39 #include "context.h"
40 #include "engineinfo.h"
41 #include "protocol.h"
42
43 #include <QSignalSpy>
44 #include <QTemporaryDir>
45 #include <QTest>
46
47 using namespace QGpgME;
48 using namespace GpgME;
49
50 class TestChangeExpiryJob: public QGpgMETest
51 {
52 Q_OBJECT
53
54 private Q_SLOTS:
55 void test_change_expiration_default_without_subkeys()
56 {
57 Error err;
58
59 if (!loopbackSupported()) {
60 return;
61 }
62
63 auto ctx = Context::create(OpenPGP);
64 QVERIFY(ctx);
65
66 // Get the key (alfa@example.net)
67 auto key = ctx->key("A0FF4590BB6122EDEF6E3C542D727CC768697734", err, true);
68 QVERIFY(!err);
69 QVERIFY(!key.isNull());
70 QVERIFY(!key.subkey(0).isNull());
71 QVERIFY(!key.subkey(1).isNull());
72 const auto subkeyExpiration = key.subkey(1).expirationTime();
73
74 {
75 // Create the job
76 auto job = std::unique_ptr<ChangeExpiryJob>{openpgp()->changeExpiryJob()};
77 QVERIFY(job);
78 hookUpPassphraseProvider(job.get());
79
80 // Use defaults of job
81
82 connect(job.get(), &ChangeExpiryJob::result,
83 this, [this] (const GpgME::Error &err2, const QString &, const GpgME::Error &) {
84 Q_EMIT asyncDone();
85 if (err2) {
86 QFAIL(qPrintable(QString("The ChangeExpiryJob failed with '%1'.").arg(err2.asString())));
87 }
88 });
89
90 const auto newExpirationDate = QDateTime::currentDateTime().addDays(1);
91 job->start(key, newExpirationDate);
92 QSignalSpy spy (this, SIGNAL(asyncDone()));
93 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
94
95 // At this point the expiration date should have been changed.
96 key.update();
97
98 // allow a few seconds earlier expiration because job calculates "seconds from now" passed to gpg after it was started
99 const auto expectedExpirationRange = std::make_pair(
100 newExpirationDate.toSecsSinceEpoch() - 10,
101 QDateTime::currentDateTime().addDays(1).toSecsSinceEpoch());
102 {
103 const auto actualExpiration = key.subkey(0).expirationTime();
104 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
105 ("actual: " + std::to_string(actualExpiration) +
106 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
107 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
108 ("actual: " + std::to_string(actualExpiration) +
109 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
110 }
111 {
112 const auto actualExpiration = key.subkey(1).expirationTime();
113 QCOMPARE(actualExpiration, subkeyExpiration); // unchanged
114 }
115 }
116 }
117
118 void test_change_expiration_default_with_subkeys()
119 {
120 Error err;
121
122 if (!loopbackSupported()) {
123 return;
124 }
125
126 auto ctx = Context::create(OpenPGP);
127 QVERIFY(ctx);
128
129 // Get the key (alfa@example.net)
130 auto key = ctx->key("A0FF4590BB6122EDEF6E3C542D727CC768697734", err, true);
131 QVERIFY(!err);
132 QVERIFY(!key.isNull());
133 QVERIFY(!key.subkey(0).isNull());
134 QVERIFY(!key.subkey(1).isNull());
135 const auto primaryKeyExpiration = key.subkey(0).expirationTime();
136
137 {
138 // Create the job
139 auto job = std::unique_ptr<ChangeExpiryJob>{openpgp()->changeExpiryJob()};
140 QVERIFY(job);
141 hookUpPassphraseProvider(job.get());
142
143 // Use defaults of job
144
145 connect(job.get(), &ChangeExpiryJob::result,
146 this, [this] (const GpgME::Error &err2, const QString &, const GpgME::Error &) {
147 Q_EMIT asyncDone();
148 if (err2) {
149 QFAIL(qPrintable(QString("The ChangeExpiryJob failed with '%1'.").arg(err2.asString())));
150 }
151 });
152
153 const auto newExpirationDate = QDateTime::currentDateTime().addDays(2);
154 job->start(key, newExpirationDate, {key.subkey(1)});
155 QSignalSpy spy (this, SIGNAL(asyncDone()));
156 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
157
158 // At this point the expiration date should have been changed.
159 key.update();
160
161 // allow a few seconds earlier expiration because job calculates "seconds from now" passed to gpg after it was started
162 const auto expectedExpirationRange = std::make_pair(
163 newExpirationDate.toSecsSinceEpoch() - 10,
164 QDateTime::currentDateTime().addDays(2).toSecsSinceEpoch());
165 {
166 const auto actualExpiration = key.subkey(0).expirationTime();
167 QCOMPARE(actualExpiration, primaryKeyExpiration); // unchanged
168 }
169 {
170 const auto actualExpiration = key.subkey(1).expirationTime();
171 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
172 ("actual: " + std::to_string(actualExpiration) +
173 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
174 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
175 ("actual: " + std::to_string(actualExpiration) +
176 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
177 }
178 }
179 }
180
181 void test_change_expiration_update_primary_key_without_subkeys()
182 {
183 Error err;
184
185 if (!loopbackSupported()) {
186 return;
187 }
188
189 auto ctx = Context::create(OpenPGP);
190 QVERIFY(ctx);
191
192 // Get the key (alfa@example.net)
193 auto key = ctx->key("A0FF4590BB6122EDEF6E3C542D727CC768697734", err, true);
194 QVERIFY(!err);
195 QVERIFY(!key.isNull());
196 QVERIFY(!key.subkey(0).isNull());
197 QVERIFY(!key.subkey(1).isNull());
198 const auto subkeyExpiration = key.subkey(1).expirationTime();
199
200 {
201 // Create the job
202 auto job = std::unique_ptr<ChangeExpiryJob>{openpgp()->changeExpiryJob()};
203 QVERIFY(job);
204 hookUpPassphraseProvider(job.get());
205
206 // Set up the job
207 job->setOptions(ChangeExpiryJob::UpdatePrimaryKey);
208
209 connect(job.get(), &ChangeExpiryJob::result,
210 this, [this] (const GpgME::Error &err2, const QString &, const GpgME::Error &) {
211 Q_EMIT asyncDone();
212 if (err2) {
213 QFAIL(qPrintable(QString("The ChangeExpiryJob failed with '%1'.").arg(err2.asString())));
214 }
215 });
216
217 const auto newExpirationDate = QDateTime::currentDateTime().addDays(3);
218 job->start(key, newExpirationDate, {});
219 QSignalSpy spy (this, SIGNAL(asyncDone()));
220 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
221
222 // At this point the expiration date should have been changed.
223 key.update();
224
225 // allow a few seconds earlier expiration because job calculates "seconds from now" passed to gpg after it was started
226 const auto expectedExpirationRange = std::make_pair(
227 newExpirationDate.toSecsSinceEpoch() - 10,
228 QDateTime::currentDateTime().addDays(3).toSecsSinceEpoch());
229 {
230 const auto actualExpiration = key.subkey(0).expirationTime();
231 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
232 ("actual: " + std::to_string(actualExpiration) +
233 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
234 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
235 ("actual: " + std::to_string(actualExpiration) +
236 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
237 }
238 {
239 const auto actualExpiration = key.subkey(1).expirationTime();
240 QCOMPARE(actualExpiration, subkeyExpiration); // unchanged
241 }
242 }
243 }
244
245 void test_change_expiration_update_primary_key_with_subkeys()
246 {
247 Error err;
248
249 if (!loopbackSupported()) {
250 return;
251 }
252
253 auto ctx = Context::create(OpenPGP);
254 QVERIFY(ctx);
255
256 // Get the key (alfa@example.net)
257 auto key = ctx->key("A0FF4590BB6122EDEF6E3C542D727CC768697734", err, true);
258 QVERIFY(!err);
259 QVERIFY(!key.isNull());
260 QVERIFY(!key.subkey(0).isNull());
261 QVERIFY(!key.subkey(1).isNull());
262
263 {
264 // Create the job
265 auto job = std::unique_ptr<ChangeExpiryJob>{openpgp()->changeExpiryJob()};
266 QVERIFY(job);
267 hookUpPassphraseProvider(job.get());
268
269 // Set up the job
270 job->setOptions(ChangeExpiryJob::UpdatePrimaryKey);
271
272 connect(job.get(), &ChangeExpiryJob::result,
273 this, [this] (const GpgME::Error &err2, const QString &, const GpgME::Error &) {
274 Q_EMIT asyncDone();
275 if (err2) {
276 QFAIL(qPrintable(QString("The ChangeExpiryJob failed with '%1'.").arg(err2.asString())));
277 }
278 });
279
280 const auto newExpirationDate = QDateTime::currentDateTime().addDays(4);
281 job->start(key, newExpirationDate, {key.subkey(1)});
282 QSignalSpy spy (this, SIGNAL(asyncDone()));
283 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
284
285 // At this point the expiration date should have been changed.
286 key.update();
287
288 // allow a few seconds earlier expiration because job calculates "seconds from now" passed to gpg after it was started
289 const auto expectedExpirationRange = std::make_pair(
290 newExpirationDate.toSecsSinceEpoch() - 10,
291 QDateTime::currentDateTime().addDays(4).toSecsSinceEpoch());
292 {
293 const auto actualExpiration = key.subkey(0).expirationTime();
294 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
295 ("actual: " + std::to_string(actualExpiration) +
296 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
297 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
298 ("actual: " + std::to_string(actualExpiration) +
299 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
300 }
301 {
302 const auto actualExpiration = key.subkey(1).expirationTime();
303 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
304 ("actual: " + std::to_string(actualExpiration) +
305 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
306 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
307 ("actual: " + std::to_string(actualExpiration) +
308 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
309 }
310 }
311 }
312
313 void test_change_expiration_update_primary_key_and_all_subkeys()
314 {
315 Error err;
316
317 if (!loopbackSupported()) {
318 return;
319 }
320
321 auto ctx = Context::create(OpenPGP);
322 QVERIFY(ctx);
323
324 // Get the key (alfa@example.net)
325 auto key = ctx->key("A0FF4590BB6122EDEF6E3C542D727CC768697734", err, true);
326 QVERIFY(!err);
327 QVERIFY(!key.isNull());
328 QVERIFY(!key.subkey(0).isNull());
329 QVERIFY(!key.subkey(1).isNull());
330
331 {
332 // Create the job
333 auto job = std::unique_ptr<ChangeExpiryJob>{openpgp()->changeExpiryJob()};
334 QVERIFY(job);
335 hookUpPassphraseProvider(job.get());
336
337 // Set up the job
338 job->setOptions(ChangeExpiryJob::UpdatePrimaryKey | ChangeExpiryJob::UpdateAllSubkeys);
339
340 connect(job.get(), &ChangeExpiryJob::result,
341 this, [this] (const GpgME::Error &err2, const QString &, const GpgME::Error &) {
342 Q_EMIT asyncDone();
343 if (err2) {
344 QFAIL(qPrintable(QString("The ChangeExpiryJob failed with '%1'.").arg(err2.asString())));
345 }
346 });
347
348 const auto newExpirationDate = QDateTime::currentDateTime().addDays(5);
349 job->start(key, newExpirationDate);
350 QSignalSpy spy (this, SIGNAL(asyncDone()));
351 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
352
353 // At this point the expiration date should have been changed.
354 key.update();
355
356 // allow a few seconds earlier expiration because job calculates "seconds from now" passed to gpg after it was started
357 const auto expectedExpirationRange = std::make_pair(
358 newExpirationDate.toSecsSinceEpoch() - 10,
359 QDateTime::currentDateTime().addDays(5).toSecsSinceEpoch());
360 {
361 const auto actualExpiration = key.subkey(0).expirationTime();
362 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
363 ("actual: " + std::to_string(actualExpiration) +
364 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
365 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
366 ("actual: " + std::to_string(actualExpiration) +
367 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
368 }
369 {
370 const auto actualExpiration = key.subkey(1).expirationTime();
371 QVERIFY2(actualExpiration >= expectedExpirationRange.first,
372 ("actual: " + std::to_string(actualExpiration) +
373 "; expected: " + std::to_string(expectedExpirationRange.first)).c_str());
374 QVERIFY2(actualExpiration <= expectedExpirationRange.second,
375 ("actual: " + std::to_string(actualExpiration) +
376 "; expected: " + std::to_string(expectedExpirationRange.second)).c_str());
377 }
378 }
379 }
380
381 void initTestCase()
382 {
383 QGpgMETest::initTestCase();
384 const QString gpgHome = qgetenv("GNUPGHOME");
385 QVERIFY(copyKeyrings(gpgHome, mDir.path()));
386 qputenv("GNUPGHOME", mDir.path().toUtf8());
387 }
388
389 private:
390 QTemporaryDir mDir;
391 };
392
393 QTEST_MAIN(TestChangeExpiryJob)
394
395 #include "t-changeexpiryjob.moc"
5656 // be unsupported in older versions.
5757 return;
5858 }
59 // First set compliance to de-vs
6059 auto conf = cryptoConfig();
6160 QVERIFY(conf);
62 auto entry = conf->entry(QStringLiteral("gpg"),
63 QStringLiteral("Configuration"),
64 QStringLiteral("compliance"));
61 auto entry = conf->entry(QStringLiteral("gpg"), QStringLiteral("compliance"));
6562 QVERIFY(entry);
63 const auto defaultValue = entry->defaultValue().toString();
64 QCOMPARE(defaultValue, QStringLiteral("gnupg"));
65
6666 entry->setStringValue("de-vs");
6767 conf->sync(true);
6868 conf->clear();
69 entry = conf->entry(QStringLiteral("gpg"),
70 QStringLiteral("Configuration"),
71 QStringLiteral("compliance"));
69 entry = conf->entry(QStringLiteral("gpg"), QStringLiteral("compliance"));
7270 QCOMPARE(entry->stringValue(), QStringLiteral("de-vs"));
71
7372 entry->resetToDefault();
7473 conf->sync(true);
7574 conf->clear();
76 entry = conf->entry(QStringLiteral("gpg"),
77 QStringLiteral("Configuration"),
78 QStringLiteral("compliance"));
79 QCOMPARE(entry->stringValue(), QStringLiteral("gnupg"));
75 entry = conf->entry(QStringLiteral("gpg"), QStringLiteral("compliance"));
76 QCOMPARE(entry->stringValue(), defaultValue);
8077 }
8178
8279 void initTestCase()
6262 {
6363 Q_OBJECT
6464
65 Q_SIGNALS:
66 void asyncDone();
67
6865 private Q_SLOTS:
6966
7067 void testSimpleEncryptDecrypt()
9188 return;
9289 }
9390 auto decJob = openpgp()->decryptJob();
94 auto ctx = Job::context(decJob);
95 TestPassphraseProvider provider;
96 ctx->setPassphraseProvider(&provider);
97 ctx->setPinentryMode(Context::PinentryLoopback);
91 hookUpPassphraseProvider(decJob);
9892 QByteArray plainText;
9993 auto decResult = decJob->exec(cipherText, plainText);
10094 QVERIFY(!decResult.error());
162156 return;
163157 }
164158 auto job = openpgp()->encryptJob();
159 hookUpPassphraseProvider(job);
165160 auto ctx = Job::context(job);
166 TestPassphraseProvider provider;
167 ctx->setPassphraseProvider(&provider);
168 ctx->setPinentryMode(Context::PinentryLoopback);
169161 ctx->setArmor(true);
170162 ctx->setTextMode(true);
171163 QByteArray cipherText;
178170 killAgent(mDir.path());
179171
180172 auto decJob = openpgp()->decryptJob();
181 auto ctx2 = Job::context(decJob);
182 ctx2->setPassphraseProvider(&provider);
183 ctx2->setPinentryMode(Context::PinentryLoopback);
173 hookUpPassphraseProvider(decJob);
184174 QByteArray plainText;
185175 auto decResult = decJob->exec(cipherText, plainText);
186176 QVERIFY(!result.error());
203193 delete listjob;
204194
205195 auto job = openpgp()->signEncryptJob(/*ASCII Armor */true, /* Textmode */ true);
206
207 auto encSignCtx = Job::context(job);
208 TestPassphraseProvider provider1;
209 encSignCtx->setPassphraseProvider(&provider1);
210 encSignCtx->setPinentryMode(Context::PinentryLoopback);
211
212196 QVERIFY(job);
197 hookUpPassphraseProvider(job);
198
213199 QByteArray cipherText;
214200 auto result = job->exec(keys, keys, QStringLiteral("Hello World").toUtf8(), Context::AlwaysTrust, cipherText);
215201 delete job;
224210 }
225211
226212 auto decJob = openpgp()->decryptJob();
213 hookUpPassphraseProvider(decJob);
227214 auto ctx = Job::context(decJob);
228 TestPassphraseProvider provider;
229 ctx->setPassphraseProvider(&provider);
230 ctx->setPinentryMode(Context::PinentryLoopback);
231215 ctx->setDecryptionFlags(Context::DecryptUnwrap);
232216
233217 QByteArray plainText;
268252 delete listjob;
269253
270254 auto job = openpgp()->encryptJob();
255 hookUpPassphraseProvider(job);
271256 auto ctx = Job::context(job);
272 ctx->setPassphraseProvider(new TestPassphraseProvider);
273 ctx->setPinentryMode(Context::PinentryLoopback);
274257 ctx->setArmor(true);
275258 ctx->setTextMode(true);
276259 QByteArray cipherText;
296279 agentConf.close();
297280
298281 auto decJob = openpgp()->decryptJob();
282 hookUpPassphraseProvider(decJob);
299283 auto ctx2 = Job::context(decJob);
300 ctx2->setPassphraseProvider(new TestPassphraseProvider);
301 ctx2->setPinentryMode(Context::PinentryLoopback);
302284 ctx2->setTextMode(true);
303285 QByteArray plainText;
304286 auto decResult = decJob->exec(cipherText, plainText);
0 /* t-import.cpp
1
2 This file is part of qgpgme, the Qt API binding for gpgme
3 Copyright (c) 2021 g10 Code GmbH
4 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
5
6 QGpgME is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public License as
8 published by the Free Software Foundation; either version 2 of the
9 License, or (at your option) any later version.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31
32 #ifdef HAVE_CONFIG_H
33 #include "config.h"
34 #endif
35
36 #include "t-support.h"
37
38 #include "context.h"
39 #include "engineinfo.h"
40 #include "protocol.h"
41 #include "importjob.h"
42
43 #include <importresult.h>
44
45 #include <QDebug>
46 #include <QSignalSpy>
47 #include <QTemporaryDir>
48 #include <QTest>
49
50 using namespace QGpgME;
51 using namespace GpgME;
52
53 class ImportTest : public QGpgMETest
54 {
55 Q_OBJECT
56
57 private:
58 QTemporaryDir tempGpgHome;
59
60 private Q_SLOTS:
61 void initTestCase()
62 {
63 QGpgMETest::initTestCase();
64 QVERIFY2(tempGpgHome.isValid(), "Failed to create temporary GNUPGHOME");
65 qputenv("GNUPGHOME", tempGpgHome.path().toLocal8Bit());
66 }
67
68 void testImportWithImportFilter()
69 {
70 if (GpgME::engineInfo(GpgME::GpgEngine).engineVersion() < "2.1.14") {
71 QSKIP("gpg does not yet support the --import-filter option");
72 }
73
74 // pub ed25519 2021-12-15 [SC]
75 // E7A0841292ACC9465D3142652FB3A6F51FBF28A2
76 // uid [ultimate] importWithImportFilter@example.com
77 // uid [ultimate] importWithImportFilter@example.net
78 // sub cv25519 2021-12-15 [E]
79 static const char keyFpr[] = "E7A0841292ACC9465D3142652FB3A6F51FBF28A2";
80 static const char keyData[] =
81 "-----BEGIN PGP PUBLIC KEY BLOCK-----\n"
82 "\n"
83 "mDMEYbm2PhYJKwYBBAHaRw8BAQdACzxBWtNNsmJ6rzpZkjh1yBe+Ajsk9NR8umEu\n"
84 "Da3HLgG0ImltcG9ydFdpdGhJbXBvcnRGaWx0ZXJAZXhhbXBsZS5uZXSIlAQTFgoA\n"
85 "PBYhBOeghBKSrMlGXTFCZS+zpvUfvyiiBQJhubY+AhsDBQsJCAcCAyICAQYVCgkI\n"
86 "CwIEFgIDAQIeBwIXgAAKCRAvs6b1H78oosRgAQCc/ke6q076nvzIE2UzT83JK/B6\n"
87 "lxSV7Fb8bKltOMpvsAD+Phap3EzA8jdMyKoO0FM926bw5lX7QROfeZ/JBYqyPwC0\n"
88 "ImltcG9ydFdpdGhJbXBvcnRGaWx0ZXJAZXhhbXBsZS5jb22IlAQTFgoAPBYhBOeg\n"
89 "hBKSrMlGXTFCZS+zpvUfvyiiBQJhubZlAhsDBQsJCAcCAyICAQYVCgkICwIEFgID\n"
90 "AQIeBwIXgAAKCRAvs6b1H78oohPWAQC/u9UXzkxRkrB2huaTZCsyimWEGZIMmxWd\n"
91 "tE+vN9/IvQD/Yzia+xRS6yca3Yz6iW8xS844ZqRxvkUEHjtJXSOzagm4OARhubY+\n"
92 "EgorBgEEAZdVAQUBAQdANQFjmDctY3N0/ELPZtj9tapwFs4vrmTVpx/SCfZmihkD\n"
93 "AQgHiHgEGBYKACAWIQTnoIQSkqzJRl0xQmUvs6b1H78oogUCYbm2PgIbDAAKCRAv\n"
94 "s6b1H78oovGyAP41ySzvvDpV7XDJBOAFxvWLmywa5IcO7Lrg7y1efoWj0AD+Kk/B\n"
95 "s7jGLdoG51h670h50MMoYCANB6MwAdSP+qZUlQg=\n"
96 "=/3O0\n"
97 "-----END PGP PUBLIC KEY BLOCK-----\n";
98
99 auto *job = openpgp()->importJob();
100 job->setImportFilter(QLatin1String{"keep-uid=mbox = importWithImportFilter@example.net"});
101 connect(job, &ImportJob::result, this,
102 [this](ImportResult result, QString, Error)
103 {
104 QVERIFY(!result.error());
105 QVERIFY(!result.imports().empty());
106 QVERIFY(result.numImported());
107 Q_EMIT asyncDone();
108 });
109 job->start(QByteArray{keyData});
110 QSignalSpy spy (this, SIGNAL(asyncDone()));
111 QVERIFY(spy.wait());
112
113 auto ctx = Context::createForProtocol(GpgME::OpenPGP);
114 GpgME::Error err;
115 const auto key = ctx->key(keyFpr, err, false);
116 QVERIFY(!key.isNull());
117 QCOMPARE(key.numUserIDs(), 1);
118 QCOMPARE(key.userID(0).id(), "importWithImportFilter@example.net");
119 }
120
121 void testImportWithKeyOrigin()
122 {
123 if (GpgME::engineInfo(GpgME::GpgEngine).engineVersion() < "2.1.22") {
124 QSKIP("gpg does not yet support the --key-origin option");
125 }
126
127 static const char keyFpr[] = "5C5C428FABCC20F6913464BCCA6FB442887289B3";
128 static const char keyData[] =
129 "-----BEGIN PGP PUBLIC KEY BLOCK-----\n"
130 "\n"
131 "mDMEYbhuixYJKwYBBAHaRw8BAQdAulOM3IksCjdOJluEVlwalD8oZ5oa6wCw3EgW\n"
132 "NswXXb60H2ltcG9ydFdpdGhLZXlPcmlnaW5AZXhhbXBsZS5uZXSIlAQTFgoAPBYh\n"
133 "BFxcQo+rzCD2kTRkvMpvtEKIcomzBQJhuG6LAhsDBQsJCAcCAyICAQYVCgkICwIE\n"
134 "FgIDAQIeBwIXgAAKCRDKb7RCiHKJs+cIAQDaeoOw1OCAGpZQb8xJmLJHul5dLLzU\n"
135 "RBdHauMx9NROmQEA23QUVedc7walQjNKFzyIJA/YqRdbAKPiLonRBmxk9Ay4OARh\n"
136 "uG6LEgorBgEEAZdVAQUBAQdAMVdO9mNWIP/q8PtNOnBGlPyhx/vs07sF5sXk50A+\n"
137 "61QDAQgHiHgEGBYKACAWIQRcXEKPq8wg9pE0ZLzKb7RCiHKJswUCYbhuiwIbDAAK\n"
138 "CRDKb7RCiHKJs/x6AP0SEbZqW4iLCz2i1JntQghK5qpSZOVqsBTcARd6pcJ/cwEA\n"
139 "mrwskWazuS9+GVbHT5RATWOXnGaj+AICSDPE6qHtGgA=\n"
140 "=putz\n"
141 "-----END PGP PUBLIC KEY BLOCK-----\n";
142
143 auto *job = openpgp()->importJob();
144 job->setKeyOrigin(GpgME::Key::OriginWKD, "https://example.net");
145 connect(job, &ImportJob::result, this,
146 [this](ImportResult result, QString, Error)
147 {
148 QVERIFY(!result.error());
149 QVERIFY(!result.imports().empty());
150 QVERIFY(result.numImported());
151 Q_EMIT asyncDone();
152 });
153 job->start(QByteArray{keyData});
154 QSignalSpy spy (this, SIGNAL(asyncDone()));
155 QVERIFY(spy.wait());
156
157 auto ctx = Context::createForProtocol(GpgME::OpenPGP);
158 GpgME::Error err;
159 const auto key = ctx->key(keyFpr, err, false);
160 QVERIFY(!key.isNull());
161 QVERIFY(key.origin() == Key::OriginWKD);
162 // the origin URL is currently not available in GpgME
163 }
164 };
165
166 QTEST_MAIN(ImportTest)
167
168 #include "t-import.moc"
5555 class KeyListTest : public QGpgMETest
5656 {
5757 Q_OBJECT
58
59 Q_SIGNALS:
60 void asyncDone();
6158
6259 private Q_SLOTS:
6360 void testSingleKeyListSync()
150147 delete job;
151148 QVERIFY(!result.error());
152149
153 QCOMPARE(secKeys.size(), 2u);
150 QCOMPARE(secKeys.size(), static_cast<decltype(secKeys.size())>(2));
154151 std::vector<std::string> secKeyFingerprints = std::accumulate(secKeys.begin(), secKeys.end(), std::vector<std::string>(), accumulateFingerprints);
155152 QCOMPARE(secKeyFingerprints, std::vector<std::string>({
156153 "23FD347A419429BACCD5E72D6BC4778054ACD246",
161158 QVERIFY(secKeys[0].subkeys()[0].keyGrip());
162159 }
163160
164 QCOMPARE(pubKeys.size(), 26u);
161 QCOMPARE(pubKeys.size(), static_cast<decltype(pubKeys.size())>(26));
165162 std::vector<std::string> pubKeyFingerprints = std::accumulate(pubKeys.begin(), pubKeys.end(), std::vector<std::string>(), accumulateFingerprints);
166163 QCOMPARE(pubKeyFingerprints, std::vector<std::string>({
167164 "045B2334ADD69FC221076841A5E67F7FA3AE3EA1",
4949 class KeyLocateTest : public QGpgMETest
5050 {
5151 Q_OBJECT
52
53 Q_SIGNALS:
54 void asyncDone();
5552
5653 private Q_SLOTS:
5754
4949 class ChangeOwnerTrustTest: public QGpgMETest
5050 {
5151 Q_OBJECT
52
53 Q_SIGNALS:
54 void asyncDone();
5552
5653 private Q_SLOTS:
5754
5353 {
5454 Q_OBJECT
5555
56 Q_SIGNALS:
57 void asyncDone();
58
5956 public:
6057 // This test is disabled (no slot) because the behavior
6158 // is not clearly defined. Better to prevent that
7673 // Create the job
7774 auto job = openpgp()->signKeyJob();
7875 QVERIFY (job);
79
80 // Hack in the passphrase provider
81 auto jobCtx = Job::context(job);
82 TestPassphraseProvider provider;
83 jobCtx->setPassphraseProvider(&provider);
84 jobCtx->setPinentryMode(Context::PinentryLoopback);
76 hookUpPassphraseProvider(job);
8577
8678 // Setup the job
8779 job->setExportable(false);
132124 // Create the job
133125 auto job = openpgp()->signKeyJob();
134126 QVERIFY (job);
135
136 // Hack in the passphrase provider
137 auto jobCtx = Job::context(job);
138 TestPassphraseProvider provider;
139 jobCtx->setPassphraseProvider(&provider);
140 jobCtx->setPinentryMode(Context::PinentryLoopback);
127 hookUpPassphraseProvider(job);
141128
142129 // Setup the job
143130 job->setExportable(true);
169156 // Now replace the remark
170157 auto job3 = openpgp()->signKeyJob();
171158 QVERIFY (job3);
172
173 // Hack in the passphrase provider
174 auto jobCtx3 = Job::context(job3);
175 jobCtx3->setPassphraseProvider(&provider);
176 jobCtx3->setPinentryMode(Context::PinentryLoopback);
159 hookUpPassphraseProvider(job3);
177160
178161 // Setup the job
179162 job3->setExportable(false);
228211 // Create the job
229212 auto job = openpgp()->signKeyJob();
230213 QVERIFY (job);
231
232 // Hack in the passphrase provider
233 auto jobCtx = Job::context(job);
234 TestPassphraseProvider provider;
235 jobCtx->setPassphraseProvider(&provider);
236 jobCtx->setPinentryMode(Context::PinentryLoopback);
214 hookUpPassphraseProvider(job);
237215
238216 // Setup the first job
239217 job->setExportable(false);
256234 // Now another remark from zulu
257235 auto job3 = openpgp()->signKeyJob();
258236 QVERIFY (job3);
259
260 // Hack in the passphrase provider
261 auto jobCtx3 = Job::context(job3);
262 jobCtx3->setPassphraseProvider(&provider);
263 jobCtx3->setPinentryMode(Context::PinentryLoopback);
237 hookUpPassphraseProvider(job3);
264238
265239 // Setup the job
266240 job3->setExportable(false);
314288 // Create the job
315289 auto job = openpgp()->signKeyJob();
316290 QVERIFY (job);
317
318 // Hack in the passphrase provider
319 auto jobCtx = Job::context(job);
320 TestPassphraseProvider provider;
321 jobCtx->setPassphraseProvider(&provider);
322 jobCtx->setPinentryMode(Context::PinentryLoopback);
291 hookUpPassphraseProvider(job);
323292
324293 // Setup the job
325294 job->setExportable(false);
351320 // Now replace the remark
352321 auto job3 = openpgp()->signKeyJob();
353322 QVERIFY (job3);
354
355 // Hack in the passphrase provider
356 auto jobCtx3 = Job::context(job3);
357 jobCtx3->setPassphraseProvider(&provider);
358 jobCtx3->setPinentryMode(Context::PinentryLoopback);
323 hookUpPassphraseProvider(job3);
359324
360325 // Setup the job
361326 job3->setExportable(false);
404369 // Create the job
405370 auto job = openpgp()->signKeyJob();
406371 QVERIFY (job);
407
408 // Hack in the passphrase provider
409 auto jobCtx = Job::context(job);
410 TestPassphraseProvider provider;
411 jobCtx->setPassphraseProvider(&provider);
412 jobCtx->setPinentryMode(Context::PinentryLoopback);
372 hookUpPassphraseProvider(job);
413373
414374 // Setup the job
415375 job->setExportable(false);
440400 // Try to replace it without dupeOK
441401 auto job2 = openpgp()->signKeyJob();
442402 QVERIFY (job2);
443
444 // Hack in the passphrase provider
445 auto jobCtx2 = Job::context(job2);
446 jobCtx2->setPassphraseProvider(&provider);
447 jobCtx2->setPinentryMode(Context::PinentryLoopback);
403 hookUpPassphraseProvider(job2);
448404
449405 // Setup the job
450406 job2->setExportable(false);
465421 // Now replace the remark
466422 auto job3 = openpgp()->signKeyJob();
467423 QVERIFY (job3);
468
469 // Hack in the passphrase provider
470 auto jobCtx3 = Job::context(job3);
471 jobCtx3->setPassphraseProvider(&provider);
472 jobCtx3->setPinentryMode(Context::PinentryLoopback);
424 hookUpPassphraseProvider(job3);
473425
474426 // Setup the job
475427 job3->setExportable(false);
3434 #endif
3535
3636 #include "t-support.h"
37 #include "context.h"
37
38 #include "importjob.h"
39 #include "job.h"
40 #include "protocol.h"
3841
3942 #include <QTest>
4043
4245 #include <QCoreApplication>
4346 #include <QObject>
4447 #include <QDir>
48 #include <QSignalSpy>
4549
50 #include "context.h"
4651 #include "engineinfo.h"
52 #include "importresult.h"
53
54 using namespace GpgME;
55 using namespace QGpgME;
4756
4857 void QGpgMETest::initTestCase()
4958 {
5665 {
5766 QCoreApplication::sendPostedEvents();
5867 killAgent();
68 }
69
70 // static
71 bool QGpgMETest::doOnlineTests()
72 {
73 return !qgetenv("DO_ONLINE_TESTS").isEmpty();
5974 }
6075
6176 bool QGpgMETest::copyKeyrings(const QString &src, const QString &dest)
8398 }
8499 }
85100 return true;
101 }
102
103 bool QGpgMETest::importSecretKeys(const char *keyData, int expectedKeys)
104 {
105 auto job = std::unique_ptr<ImportJob>{openpgp()->importJob()};
106 VERIFY_OR_FALSE(job);
107 hookUpPassphraseProvider(job.get());
108
109 ImportResult result;
110 connect(job.get(), &ImportJob::result,
111 this, [this, &result](const ImportResult &result_) {
112 result = result_;
113 Q_EMIT asyncDone();
114 });
115 VERIFY_OR_FALSE(!job->start(keyData));
116 job.release(); // after the job has been started it's on its own
117
118 QSignalSpy spy (this, SIGNAL(asyncDone()));
119 VERIFY_OR_FALSE(spy.wait(QSIGNALSPY_TIMEOUT));
120 VERIFY_OR_FALSE(!result.error());
121 VERIFY_OR_FALSE(!result.imports().empty());
122 COMPARE_OR_FALSE(result.numSecretKeysImported(), expectedKeys);
123
124 return true;
125 }
126
127 void QGpgMETest::hookUpPassphraseProvider(GpgME::Context *context)
128 {
129 context->setPassphraseProvider(&mPassphraseProvider);
130 context->setPinentryMode(Context::PinentryLoopback);
131 }
132
133 void QGpgMETest::hookUpPassphraseProvider(QGpgME::Job *job)
134 {
135 hookUpPassphraseProvider(Job::context(job));
86136 }
87137
88138 void killAgent(const QString& dir)
3333
3434 #include "interfaces/passphraseprovider.h"
3535 #include <QObject>
36 #include <QTest>
3637
3738 #include <gpg-error.h>
39
40 namespace GpgME
41 {
42 class Context;
43 }
44
45 namespace QGpgME
46 {
47 class Job;
48 }
49
50 /// generic variant of QVERIFY returning \a returnValue on failure
51 #define VERIFY_OR_RETURN_VALUE(statement, returnValue) \
52 do {\
53 if (!QTest::qVerify(static_cast<bool>(statement), #statement, "", __FILE__, __LINE__))\
54 return returnValue;\
55 } while (false)
56
57 /// generic variant of QCOMPARE returning \a returnValue on failure
58 #define COMPARE_OR_RETURN_VALUE(actual, expected, returnValue) \
59 do {\
60 if (!QTest::qCompare(actual, expected, #actual, #expected, __FILE__, __LINE__))\
61 return returnValue;\
62 } while (false)
63
64 /// variant of QVERIFY returning a default constructed object on failure
65 #define VERIFY_OR_OBJECT(statement) VERIFY_OR_RETURN_VALUE(statement, {})
66
67 /// variant of QCOMPARE returning a default constructed object on failure
68 #define COMPARE_OR_OBJECT(actual, expected) COMPARE_OR_RETURN_VALUE(actual, expected, {})
69
70 /// variant of QVERIFY returning \c false on failure
71 #define VERIFY_OR_FALSE(statement) VERIFY_OR_RETURN_VALUE(statement, false)
72
73 /// variant of QCOMPARE returning \c false on failure
74 #define COMPARE_OR_FALSE(actual, expected) COMPARE_OR_RETURN_VALUE(actual, expected, false)
75
76 namespace QTest
77 {
78 template <>
79 inline char *toString(const std::string &s)
80 {
81 return QTest::toString(s.c_str());
82 }
83 }
3884
3985 namespace GpgME
4086 {
58104 class QGpgMETest : public QObject
59105 {
60106 Q_OBJECT
107
108 Q_SIGNALS:
109 void asyncDone();
110
61111 protected:
112 static bool doOnlineTests();
113
62114 bool copyKeyrings(const QString &from, const QString& to);
115
116 bool importSecretKeys(const char *keyData, int expectedKeys = 1);
117
118 void hookUpPassphraseProvider(GpgME::Context *context);
119 void hookUpPassphraseProvider(QGpgME::Job *job);
63120
64121 public Q_SLOTS:
65122 void initTestCase();
66123 void cleanupTestCase();
124
125 private:
126 GpgME::TestPassphraseProvider mPassphraseProvider;
67127 };
68128
69129 /* Timeout, in milliseconds, for use with QSignalSpy to wait on
115115 class TofuInfoTest: public QGpgMETest
116116 {
117117 Q_OBJECT
118 Q_SIGNALS:
119 void asyncDone();
120118
121119 private:
122120 bool testSupported()
154152 void signAndVerify(const QString &what, const GpgME::Key &key, int expected)
155153 {
156154 auto job = openpgp()->signJob();
157 auto ctx = Job::context(job);
158 TestPassphraseProvider provider;
159 ctx->setPassphraseProvider(&provider);
160 ctx->setPinentryMode(Context::PinentryLoopback);
155 hookUpPassphraseProvider(job);
161156
162157 std::vector<Key> keys;
163158 keys.push_back(key);
0 /* t-remarks.cpp
0 /* t-trustsignatures.cpp
11
22 This file is part of qgpgme, the Qt API binding for gpgme
33 Copyright (c) 2021 g10 Code GmbH
5151 {
5252 Q_OBJECT
5353
54 Q_SIGNALS:
55 void asyncDone();
56
5754 private Q_SLOTS:
5855 void test_tsign_single_uid_key_and_then_tsign_it_again()
5956 {
8279 // Create the job
8380 auto job = std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
8481 QVERIFY(job);
85
86 // Hack in the passphrase provider
87 auto jobCtx = Job::context(job.get());
88 TestPassphraseProvider provider;
89 jobCtx->setPassphraseProvider(&provider);
90 jobCtx->setPinentryMode(Context::PinentryLoopback);
82 hookUpPassphraseProvider(job.get());
9183
9284 // Setup the job
9385 job->setExportable(true);
130122 // Create the job
131123 auto job = std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
132124 QVERIFY(job);
133
134 // Hack in the passphrase provider
135 auto jobCtx = Job::context(job.get());
136 TestPassphraseProvider provider;
137 jobCtx->setPassphraseProvider(&provider);
138 jobCtx->setPinentryMode(Context::PinentryLoopback);
125 hookUpPassphraseProvider(job.get());
139126
140127 // Setup the job
141128 job->setExportable(true);
203190 // Create the job
204191 auto job = openpgp()->signKeyJob();//std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
205192 QVERIFY(job);
206
207 // Hack in the passphrase provider
208 auto jobCtx = Job::context(job);
209 TestPassphraseProvider provider;
210 jobCtx->setPassphraseProvider(&provider);
211 jobCtx->setPinentryMode(Context::PinentryLoopback);
193 hookUpPassphraseProvider(job);
212194
213195 // Setup the job
214196 job->setExportable(true);
251233 // Create the job
252234 auto job = openpgp()->signKeyJob();//std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
253235 QVERIFY(job);
254
255 // Hack in the passphrase provider
256 auto jobCtx = Job::context(job);
257 TestPassphraseProvider provider;
258 jobCtx->setPassphraseProvider(&provider);
259 jobCtx->setPinentryMode(Context::PinentryLoopback);
236 hookUpPassphraseProvider(job);
260237
261238 // Setup the job
262239 job->setExportable(true);
324301 // Create the job
325302 auto job = openpgp()->signKeyJob();//std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
326303 QVERIFY(job);
327
328 // Hack in the passphrase provider
329 auto jobCtx = Job::context(job);
330 TestPassphraseProvider provider;
331 jobCtx->setPassphraseProvider(&provider);
332 jobCtx->setPinentryMode(Context::PinentryLoopback);
304 hookUpPassphraseProvider(job);
333305
334306 // Setup the job
335307 job->setExportable(true);
373345 // Create the job
374346 auto job = openpgp()->signKeyJob();//std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
375347 QVERIFY(job);
376
377 // Hack in the passphrase provider
378 auto jobCtx = Job::context(job);
379 TestPassphraseProvider provider;
380 jobCtx->setPassphraseProvider(&provider);
381 jobCtx->setPinentryMode(Context::PinentryLoopback);
348 hookUpPassphraseProvider(job);
382349
383350 // Setup the job
384351 job->setExportable(true);
446413 // Create the job
447414 auto job = openpgp()->signKeyJob();//std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
448415 QVERIFY(job);
449
450 // Hack in the passphrase provider
451 auto jobCtx = Job::context(job);
452 TestPassphraseProvider provider;
453 jobCtx->setPassphraseProvider(&provider);
454 jobCtx->setPinentryMode(Context::PinentryLoopback);
416 hookUpPassphraseProvider(job);
455417
456418 // Setup the job
457419 job->setExportable(true);
494456 // Create the job
495457 auto job = openpgp()->signKeyJob();//std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
496458 QVERIFY(job);
497
498 // Hack in the passphrase provider
499 auto jobCtx = Job::context(job);
500 TestPassphraseProvider provider;
501 jobCtx->setPassphraseProvider(&provider);
502 jobCtx->setPinentryMode(Context::PinentryLoopback);
459 hookUpPassphraseProvider(job);
503460
504461 // Setup the job
505462 job->setExportable(true);
7070 {
7171 Q_OBJECT
7272
73 Q_SIGNALS:
74 void asyncDone();
75
7673 private Q_SLOTS:
7774 void testDN()
7875 {
136133
137134 auto ctx = Context::createForProtocol(key.protocol());
138135 QVERIFY (ctx);
139 TestPassphraseProvider provider;
140 ctx->setPassphraseProvider(&provider);
141 ctx->setPinentryMode(Context::PinentryLoopback);
136 hookUpPassphraseProvider(ctx);
142137
143138 QVERIFY(!ctx->addUid(key, uid));
144139 delete ctx;
189184
190185 auto ctx = Context::createForProtocol(key.protocol());
191186 QVERIFY (ctx);
192 TestPassphraseProvider provider;
193 ctx->setPassphraseProvider(&provider);
194 ctx->setPinentryMode(Context::PinentryLoopback);
187 hookUpPassphraseProvider(ctx);
195188
196189 // change expiration of the main key
197190 QVERIFY(!ctx->setExpire(key, 1000));
229222 std::vector<Subkey> primaryKey;
230223 primaryKey.push_back(key.subkey(0));
231224 const auto err = ctx->setExpire(key, 3000, primaryKey);
232 QCOMPARE(err.code(), GPG_ERR_NOT_FOUND);
225 QCOMPARE(err.code(), static_cast<int>(GPG_ERR_NOT_FOUND));
233226 delete ctx;
234227 }
235228
258251 // Create the job
259252 auto job = std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
260253 QVERIFY(job);
261
262 // Hack in the passphrase provider
263 auto jobCtx = Job::context(job.get());
264 TestPassphraseProvider provider;
265 jobCtx->setPassphraseProvider(&provider);
266 jobCtx->setPinentryMode(Context::PinentryLoopback);
254 hookUpPassphraseProvider(job.get());
267255
268256 // Setup the job
269257 job->setExportable(true);
318306 // Create the job
319307 auto job = std::unique_ptr<SignKeyJob>{openpgp()->signKeyJob()};
320308 QVERIFY(job);
321
322 // Hack in the passphrase provider
323 auto jobCtx = Job::context(job.get());
324 TestPassphraseProvider provider;
325 jobCtx->setPassphraseProvider(&provider);
326 jobCtx->setPinentryMode(Context::PinentryLoopback);
309 hookUpPassphraseProvider(job.get());
327310
328311 // Setup the job
329312 job->setExportable(true);
354337 target.update();
355338 const auto keySignature = target.userID(0).signature(target.userID(0).numSignatures() - 1);
356339 QVERIFY(!keySignature.neverExpires());
357 const auto expirationDate = QDateTime::fromSecsSinceEpoch(keySignature.expirationTime()).date();
340 const auto expirationDate = QDateTime::fromSecsSinceEpoch(uint_least32_t(keySignature.expirationTime())).date();
358341 QCOMPARE(expirationDate, QDate(2106, 2, 6)); // expiration date is capped at 2106-02-06
359342 }
360343
0 /* t-wkdlookup.cpp
1
2 This file is part of qgpgme, the Qt API binding for gpgme
3 Copyright (c) 2021 g10 Code GmbH
4 Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
5
6 QGpgME is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public License as
8 published by the Free Software Foundation; either version 2 of the
9 License, or (at your option) any later version.
10
11 QGpgME is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
20 In addition, as a special exception, the copyright holders give
21 permission to link the code of this program with any edition of
22 the Qt library by Trolltech AS, Norway (or with modified versions
23 of Qt that use the same license as Qt), and distribute linked
24 combinations including the two. You must obey the GNU General
25 Public License in all respects for all of the code used other than
26 Qt. If you modify this file, you may extend this exception to
27 your version of the file, but you are not obligated to do so. If
28 you do not wish to do so, delete this exception statement from
29 your version.
30 */
31 #ifdef HAVE_CONFIG_H
32 #include "config.h"
33 #endif
34
35 #include "t-support.h"
36
37 #include "data.h"
38 #include "engineinfo.h"
39 #include "protocol.h"
40 #include "wkdlookupjob.h"
41 #include "wkdlookupresult.h"
42
43 #include <QDebug>
44 #include <QSignalSpy>
45 #include <QTest>
46
47 #include <algorithm>
48
49 using namespace QGpgME;
50 using namespace GpgME;
51
52 static const char *requiredVersion = "2.1.12";
53
54 namespace
55 {
56 bool keyHasUserIDWithMatchingEmailAddress(const Key &key, const QString &expectedEmailAddress)
57 {
58 const auto email = expectedEmailAddress.toLower();
59 const auto userIds = key.userIDs();
60 return std::any_of(
61 std::begin(userIds), std::end(userIds),
62 [email](const UserID &uid) {
63 return email == QString::fromUtf8(uid.email()).toLower();
64 });
65 }
66 }
67
68 class WKDLookupTest : public QGpgMETest
69 {
70 Q_OBJECT
71
72 private Q_SLOTS:
73
74 void testWKDLookupAsync()
75 {
76 if (GpgME::engineInfo(GpgME::GpgEngine).engineVersion() < requiredVersion) {
77 QSKIP("dirmngr does not yet support WKD lookup");
78 }
79 if (!doOnlineTests()) {
80 QSKIP("Set DO_ONLINE_TESTS environment variable to run this test.");
81 }
82 const QString email = QLatin1String{"wk@gnupg.org"};
83
84 WKDLookupResult result;
85 auto *job = openpgp()->wkdLookupJob();
86 connect(job, &WKDLookupJob::result, job, [this, &result](const WKDLookupResult &result_, const QString &, const Error &)
87 {
88 result = result_;
89 Q_EMIT asyncDone();
90 });
91 job->start(email);
92 QSignalSpy spy (this, SIGNAL(asyncDone()));
93 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
94
95 QVERIFY(result.error().code() == GPG_ERR_NO_ERROR);
96 QCOMPARE(result.pattern(), "wk@gnupg.org");
97 QCOMPARE(result.source(), "https://openpgpkey.gnupg.org");
98 const auto keys = result.keyData().toKeys(GpgME::OpenPGP);
99 QVERIFY(keys.size() == 1);
100 QVERIFY(keyHasUserIDWithMatchingEmailAddress(keys.front(), email));
101 }
102
103 void testWKDLookupSync()
104 {
105 if (GpgME::engineInfo(GpgME::GpgEngine).engineVersion() < requiredVersion) {
106 QSKIP("dirmngr does not yet support WKD lookup");
107 }
108 if (!doOnlineTests()) {
109 QSKIP("Set DO_ONLINE_TESTS environment variable to run this test.");
110 }
111 const QString email = QLatin1String{"wk@gnupg.org"};
112
113 auto *job = openpgp()->wkdLookupJob();
114 const auto result = job->exec(email);
115
116 QVERIFY(result.error().code() == GPG_ERR_NO_ERROR);
117 QCOMPARE(result.pattern(), "wk@gnupg.org");
118 QCOMPARE(result.source(), "https://openpgpkey.gnupg.org");
119 const auto keys = result.keyData().toKeys(GpgME::OpenPGP);
120 QVERIFY(keys.size() == 1);
121 QVERIFY(keyHasUserIDWithMatchingEmailAddress(keys.front(), email));
122 }
123
124 void testLookupWithNoResultAsync()
125 {
126 if (GpgME::engineInfo(GpgME::GpgEngine).engineVersion() < requiredVersion) {
127 QSKIP("dirmngr does not yet support WKD lookup");
128 }
129 if (!doOnlineTests()) {
130 QSKIP("Set DO_ONLINE_TESTS environment variable to run this test.");
131 }
132 const QString email = QLatin1String{"alfa@example.net"};
133
134 WKDLookupResult result;
135 auto *job = openpgp()->wkdLookupJob();
136 connect(job, &WKDLookupJob::result, job, [this, &result](const WKDLookupResult &result_, const QString &, const Error &)
137 {
138 result = result_;
139 Q_EMIT asyncDone();
140 });
141 job->start(email);
142 QSignalSpy spy (this, SIGNAL(asyncDone()));
143 QVERIFY(spy.wait(QSIGNALSPY_TIMEOUT));
144
145 QVERIFY(result.error().code() == GPG_ERR_NO_ERROR);
146 QCOMPARE(result.pattern(), "alfa@example.net");
147 QCOMPARE(result.source(), "");
148 QVERIFY(result.keyData().isNull());
149 }
150 };
151
152 QTEST_MAIN(WKDLookupTest)
153
154 #include "t-wkdlookup.moc"
116116 class WKSPublishTest : public QGpgMETest
117117 {
118118 Q_OBJECT
119
120 Q_SIGNALS:
121 void asyncDone();
122119
123120 private Q_SLOTS:
124121 void testUnsupported()
0 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
1 #
2 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
3 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
4 # Foundation, Inc.
5 # Written by Gordon Matzigkeit, 1996
6 #
7 # This file is free software; the Free Software Foundation gives
8 # unlimited permission to copy and/or distribute it, with or without
9 # modifications, as long as this notice is preserved.
10
11 m4_define([_LT_COPYING], [dnl
12 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
13 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
14 # Foundation, Inc.
15 # Written by Gordon Matzigkeit, 1996
16 #
17 # This file is part of GNU Libtool.
18 #
19 # GNU Libtool is free software; you can redistribute it and/or
20 # modify it under the terms of the GNU General Public License as
21 # published by the Free Software Foundation; either version 2 of
22 # the License, or (at your option) any later version.
23 #
24 # As a special exception to the GNU General Public License,
25 # if you distribute this file as part of a program or library that
26 # is built using GNU Libtool, you may include this file under the
27 # same distribution terms that you use for the rest of that program.
28 #
29 # GNU Libtool is distributed in the hope that it will be useful,
30 # but WITHOUT ANY WARRANTY; without even the implied warranty of
31 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
32 # GNU General Public License for more details.
33 #
34 # You should have received a copy of the GNU General Public License
35 # along with GNU Libtool; see the file COPYING. If not, a copy
36 # can be downloaded from https://www.gnu.org/licenses/gpl.html, or
37 # obtained by writing to the Free Software Foundation, Inc.,
38 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
39 ])
40
41 # serial 57 LT_INIT
42
43
44 # LT_PREREQ(VERSION)
45 # ------------------
46 # Complain and exit if this libtool version is less that VERSION.
47 m4_defun([LT_PREREQ],
48 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
49 [m4_default([$3],
50 [m4_fatal([Libtool version $1 or higher is required],
51 63)])],
52 [$2])])
53
54
55 # _LT_CHECK_BUILDDIR
56 # ------------------
57 # Complain if the absolute build directory name contains unusual characters
58 m4_defun([_LT_CHECK_BUILDDIR],
59 [case `pwd` in
60 *\ * | *\ *)
61 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
62 esac
63 ])
64
65
66 # LT_INIT([OPTIONS])
67 # ------------------
68 AC_DEFUN([LT_INIT],
69 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
70 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
71 AC_BEFORE([$0], [LT_LANG])dnl
72 AC_BEFORE([$0], [LT_OUTPUT])dnl
73 AC_BEFORE([$0], [LTDL_INIT])dnl
74 m4_require([_LT_CHECK_BUILDDIR])dnl
75
76 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
77 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
78 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
79 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
80 dnl unless we require an AC_DEFUNed macro:
81 AC_REQUIRE([LTOPTIONS_VERSION])dnl
82 AC_REQUIRE([LTSUGAR_VERSION])dnl
83 AC_REQUIRE([LTVERSION_VERSION])dnl
84 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
85 m4_require([_LT_PROG_LTMAIN])dnl
86
87 _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
88
89 dnl Parse OPTIONS
90 _LT_SET_OPTIONS([$0], [$1])
91
92 # This can be used to rebuild libtool when needed
93 LIBTOOL_DEPS="$ltmain"
94
95 # Always use our own libtool.
96 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
97 AC_SUBST(LIBTOOL)dnl
98
99 _LT_SETUP
100
101 # Only expand once:
102 m4_define([LT_INIT])
103 ])# LT_INIT
104
105 # Old names:
106 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
107 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
108 dnl aclocal-1.4 backwards compatibility:
109 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
110 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
111
112
113 # _LT_CC_BASENAME(CC)
114 # -------------------
115 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
116 m4_defun([_LT_CC_BASENAME],
117 [for cc_temp in $1""; do
118 case $cc_temp in
119 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
120 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
121 \-*) ;;
122 *) break;;
123 esac
124 done
125 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
126 ])
127
128
129 # _LT_FILEUTILS_DEFAULTS
130 # ----------------------
131 # It is okay to use these file commands and assume they have been set
132 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
133 m4_defun([_LT_FILEUTILS_DEFAULTS],
134 [: ${CP="cp -f"}
135 : ${MV="mv -f"}
136 : ${RM="rm -f"}
137 ])# _LT_FILEUTILS_DEFAULTS
138
139
140 # _LT_SETUP
141 # ---------
142 m4_defun([_LT_SETUP],
143 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
144 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
145 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
146 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
147
148 _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
149 dnl
150 _LT_DECL([], [host_alias], [0], [The host system])dnl
151 _LT_DECL([], [host], [0])dnl
152 _LT_DECL([], [host_os], [0])dnl
153 dnl
154 _LT_DECL([], [build_alias], [0], [The build system])dnl
155 _LT_DECL([], [build], [0])dnl
156 _LT_DECL([], [build_os], [0])dnl
157 dnl
158 AC_REQUIRE([AC_PROG_CC])dnl
159 AC_REQUIRE([LT_PATH_LD])dnl
160 AC_REQUIRE([LT_PATH_NM])dnl
161 dnl
162 AC_REQUIRE([AC_PROG_LN_S])dnl
163 test -z "$LN_S" && LN_S="ln -s"
164 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
165 dnl
166 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
167 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
168 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
169 dnl
170 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
171 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
172 m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
173 m4_require([_LT_CMD_RELOAD])dnl
174 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
175 m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
176 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
177 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
178 m4_require([_LT_WITH_SYSROOT])dnl
179
180 _LT_CONFIG_LIBTOOL_INIT([
181 # See if we are running on zsh, and set the options which allow our
182 # commands through without removal of \ escapes INIT.
183 if test -n "\${ZSH_VERSION+set}" ; then
184 setopt NO_GLOB_SUBST
185 fi
186 ])
187 if test -n "${ZSH_VERSION+set}" ; then
188 setopt NO_GLOB_SUBST
189 fi
190
191 _LT_CHECK_OBJDIR
192
193 m4_require([_LT_TAG_COMPILER])dnl
194
195 case $host_os in
196 aix3*)
197 # AIX sometimes has problems with the GCC collect2 program. For some
198 # reason, if we set the COLLECT_NAMES environment variable, the problems
199 # vanish in a puff of smoke.
200 if test "X${COLLECT_NAMES+set}" != Xset; then
201 COLLECT_NAMES=
202 export COLLECT_NAMES
203 fi
204 ;;
205 esac
206
207 # Global variables:
208 ofile=libtool
209 can_build_shared=yes
210
211 # All known linkers require a `.a' archive for static linking (except MSVC,
212 # which needs '.lib').
213 libext=a
214
215 with_gnu_ld="$lt_cv_prog_gnu_ld"
216
217 old_CC="$CC"
218 old_CFLAGS="$CFLAGS"
219
220 # Set sane defaults for various variables
221 test -z "$CC" && CC=cc
222 test -z "$LTCC" && LTCC=$CC
223 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
224 test -z "$LD" && LD=ld
225 test -z "$ac_objext" && ac_objext=o
226
227 _LT_CC_BASENAME([$compiler])
228
229 # Only perform the check for file, if the check method requires it
230 test -z "$MAGIC_CMD" && MAGIC_CMD=file
231 case $deplibs_check_method in
232 file_magic*)
233 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
234 _LT_PATH_MAGIC
235 fi
236 ;;
237 esac
238
239 # Use C for the default configuration in the libtool script
240 LT_SUPPORTED_TAG([CC])
241 _LT_LANG_C_CONFIG
242 _LT_LANG_DEFAULT_CONFIG
243 _LT_CONFIG_COMMANDS
244 ])# _LT_SETUP
245
246
247 # _LT_PREPARE_SED_QUOTE_VARS
248 # --------------------------
249 # Define a few sed substitution that help us do robust quoting.
250 m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
251 [# Backslashify metacharacters that are still active within
252 # double-quoted strings.
253 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
254
255 # Same as above, but do not quote variable references.
256 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
257
258 # Sed substitution to delay expansion of an escaped shell variable in a
259 # double_quote_subst'ed string.
260 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
261
262 # Sed substitution to delay expansion of an escaped single quote.
263 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
264
265 # Sed substitution to avoid accidental globbing in evaled expressions
266 no_glob_subst='s/\*/\\\*/g'
267 ])
268
269 # _LT_PROG_LTMAIN
270 # ---------------
271 # Note that this code is called both from `configure', and `config.status'
272 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
273 # `config.status' has no value for ac_aux_dir unless we are using Automake,
274 # so we pass a copy along to make sure it has a sensible value anyway.
275 m4_defun([_LT_PROG_LTMAIN],
276 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
277 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
278 ltmain="$ac_aux_dir/ltmain.sh"
279 ])# _LT_PROG_LTMAIN
280
281
282 ## ------------------------------------- ##
283 ## Accumulate code for creating libtool. ##
284 ## ------------------------------------- ##
285
286 # So that we can recreate a full libtool script including additional
287 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
288 # in macros and then make a single call at the end using the `libtool'
289 # label.
290
291
292 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
293 # ----------------------------------------
294 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
295 m4_define([_LT_CONFIG_LIBTOOL_INIT],
296 [m4_ifval([$1],
297 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
298 [$1
299 ])])])
300
301 # Initialize.
302 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
303
304
305 # _LT_CONFIG_LIBTOOL([COMMANDS])
306 # ------------------------------
307 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
308 m4_define([_LT_CONFIG_LIBTOOL],
309 [m4_ifval([$1],
310 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
311 [$1
312 ])])])
313
314 # Initialize.
315 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
316
317
318 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
319 # -----------------------------------------------------
320 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
321 [_LT_CONFIG_LIBTOOL([$1])
322 _LT_CONFIG_LIBTOOL_INIT([$2])
323 ])
324
325
326 # _LT_FORMAT_COMMENT([COMMENT])
327 # -----------------------------
328 # Add leading comment marks to the start of each line, and a trailing
329 # full-stop to the whole comment if one is not present already.
330 m4_define([_LT_FORMAT_COMMENT],
331 [m4_ifval([$1], [
332 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
333 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
334 )])
335
336
337
338 ## ------------------------ ##
339 ## FIXME: Eliminate VARNAME ##
340 ## ------------------------ ##
341
342
343 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
344 # -------------------------------------------------------------------
345 # CONFIGNAME is the name given to the value in the libtool script.
346 # VARNAME is the (base) name used in the configure script.
347 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
348 # VARNAME. Any other value will be used directly.
349 m4_define([_LT_DECL],
350 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
351 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
352 [m4_ifval([$1], [$1], [$2])])
353 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
354 m4_ifval([$4],
355 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
356 lt_dict_add_subkey([lt_decl_dict], [$2],
357 [tagged?], [m4_ifval([$5], [yes], [no])])])
358 ])
359
360
361 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
362 # --------------------------------------------------------
363 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
364
365
366 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
367 # ------------------------------------------------
368 m4_define([lt_decl_tag_varnames],
369 [_lt_decl_filter([tagged?], [yes], $@)])
370
371
372 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
373 # ---------------------------------------------------------
374 m4_define([_lt_decl_filter],
375 [m4_case([$#],
376 [0], [m4_fatal([$0: too few arguments: $#])],
377 [1], [m4_fatal([$0: too few arguments: $#: $1])],
378 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
379 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
380 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
381 ])
382
383
384 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
385 # --------------------------------------------------
386 m4_define([lt_decl_quote_varnames],
387 [_lt_decl_filter([value], [1], $@)])
388
389
390 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
391 # ---------------------------------------------------
392 m4_define([lt_decl_dquote_varnames],
393 [_lt_decl_filter([value], [2], $@)])
394
395
396 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
397 # ---------------------------------------------------
398 m4_define([lt_decl_varnames_tagged],
399 [m4_assert([$# <= 2])dnl
400 _$0(m4_quote(m4_default([$1], [[, ]])),
401 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
402 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
403 m4_define([_lt_decl_varnames_tagged],
404 [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
405
406
407 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
408 # ------------------------------------------------
409 m4_define([lt_decl_all_varnames],
410 [_$0(m4_quote(m4_default([$1], [[, ]])),
411 m4_if([$2], [],
412 m4_quote(lt_decl_varnames),
413 m4_quote(m4_shift($@))))[]dnl
414 ])
415 m4_define([_lt_decl_all_varnames],
416 [lt_join($@, lt_decl_varnames_tagged([$1],
417 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
418 ])
419
420
421 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
422 # ------------------------------------
423 # Quote a variable value, and forward it to `config.status' so that its
424 # declaration there will have the same value as in `configure'. VARNAME
425 # must have a single quote delimited value for this to work.
426 m4_define([_LT_CONFIG_STATUS_DECLARE],
427 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
428
429
430 # _LT_CONFIG_STATUS_DECLARATIONS
431 # ------------------------------
432 # We delimit libtool config variables with single quotes, so when
433 # we write them to config.status, we have to be sure to quote all
434 # embedded single quotes properly. In configure, this macro expands
435 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
436 #
437 # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
438 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
439 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
440 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
441
442
443 # _LT_LIBTOOL_TAGS
444 # ----------------
445 # Output comment and list of tags supported by the script
446 m4_defun([_LT_LIBTOOL_TAGS],
447 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
448 available_tags="_LT_TAGS"dnl
449 ])
450
451
452 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
453 # -----------------------------------
454 # Extract the dictionary values for VARNAME (optionally with TAG) and
455 # expand to a commented shell variable setting:
456 #
457 # # Some comment about what VAR is for.
458 # visible_name=$lt_internal_name
459 m4_define([_LT_LIBTOOL_DECLARE],
460 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
461 [description])))[]dnl
462 m4_pushdef([_libtool_name],
463 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
464 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
465 [0], [_libtool_name=[$]$1],
466 [1], [_libtool_name=$lt_[]$1],
467 [2], [_libtool_name=$lt_[]$1],
468 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
469 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
470 ])
471
472
473 # _LT_LIBTOOL_CONFIG_VARS
474 # -----------------------
475 # Produce commented declarations of non-tagged libtool config variables
476 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
477 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
478 # section) are produced by _LT_LIBTOOL_TAG_VARS.
479 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
480 [m4_foreach([_lt_var],
481 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
482 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
483
484
485 # _LT_LIBTOOL_TAG_VARS(TAG)
486 # -------------------------
487 m4_define([_LT_LIBTOOL_TAG_VARS],
488 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
489 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
490
491
492 # _LT_TAGVAR(VARNAME, [TAGNAME])
493 # ------------------------------
494 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
495
496
497 # _LT_CONFIG_COMMANDS
498 # -------------------
499 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
500 # variables for single and double quote escaping we saved from calls
501 # to _LT_DECL, we can put quote escaped variables declarations
502 # into `config.status', and then the shell code to quote escape them in
503 # for loops in `config.status'. Finally, any additional code accumulated
504 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
505 m4_defun([_LT_CONFIG_COMMANDS],
506 [AC_PROVIDE_IFELSE([LT_OUTPUT],
507 dnl If the libtool generation code has been placed in $CONFIG_LT,
508 dnl instead of duplicating it all over again into config.status,
509 dnl then we will have config.status run $CONFIG_LT later, so it
510 dnl needs to know what name is stored there:
511 [AC_CONFIG_COMMANDS([libtool],
512 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
513 dnl If the libtool generation code is destined for config.status,
514 dnl expand the accumulated commands and init code now:
515 [AC_CONFIG_COMMANDS([libtool],
516 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
517 ])#_LT_CONFIG_COMMANDS
518
519
520 # Initialize.
521 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
522 [
523
524 # The HP-UX ksh and POSIX shell print the target directory to stdout
525 # if CDPATH is set.
526 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
527
528 sed_quote_subst='$sed_quote_subst'
529 double_quote_subst='$double_quote_subst'
530 delay_variable_subst='$delay_variable_subst'
531 _LT_CONFIG_STATUS_DECLARATIONS
532 LTCC='$LTCC'
533 LTCFLAGS='$LTCFLAGS'
534 compiler='$compiler_DEFAULT'
535
536 # A function that is used when there is no print builtin or printf.
537 func_fallback_echo ()
538 {
539 eval 'cat <<_LTECHO_EOF
540 \$[]1
541 _LTECHO_EOF'
542 }
543
544 # Quote evaled strings.
545 for var in lt_decl_all_varnames([[ \
546 ]], lt_decl_quote_varnames); do
547 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
548 *[[\\\\\\\`\\"\\\$]]*)
549 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
550 ;;
551 *)
552 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
553 ;;
554 esac
555 done
556
557 # Double-quote double-evaled strings.
558 for var in lt_decl_all_varnames([[ \
559 ]], lt_decl_dquote_varnames); do
560 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
561 *[[\\\\\\\`\\"\\\$]]*)
562 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
563 ;;
564 *)
565 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
566 ;;
567 esac
568 done
569
570 _LT_OUTPUT_LIBTOOL_INIT
571 ])
572
573 # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
574 # ------------------------------------
575 # Generate a child script FILE with all initialization necessary to
576 # reuse the environment learned by the parent script, and make the
577 # file executable. If COMMENT is supplied, it is inserted after the
578 # `#!' sequence but before initialization text begins. After this
579 # macro, additional text can be appended to FILE to form the body of
580 # the child script. The macro ends with non-zero status if the
581 # file could not be fully written (such as if the disk is full).
582 m4_ifdef([AS_INIT_GENERATED],
583 [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
584 [m4_defun([_LT_GENERATED_FILE_INIT],
585 [m4_require([AS_PREPARE])]dnl
586 [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
587 [lt_write_fail=0
588 cat >$1 <<_ASEOF || lt_write_fail=1
589 #! $SHELL
590 # Generated by $as_me.
591 $2
592 SHELL=\${CONFIG_SHELL-$SHELL}
593 export SHELL
594 _ASEOF
595 cat >>$1 <<\_ASEOF || lt_write_fail=1
596 AS_SHELL_SANITIZE
597 _AS_PREPARE
598 exec AS_MESSAGE_FD>&1
599 _ASEOF
600 test $lt_write_fail = 0 && chmod +x $1[]dnl
601 m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
602
603 # LT_OUTPUT
604 # ---------
605 # This macro allows early generation of the libtool script (before
606 # AC_OUTPUT is called), incase it is used in configure for compilation
607 # tests.
608 AC_DEFUN([LT_OUTPUT],
609 [: ${CONFIG_LT=./config.lt}
610 AC_MSG_NOTICE([creating $CONFIG_LT])
611 _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
612 [# Run this file to recreate a libtool stub with the current configuration.])
613
614 cat >>"$CONFIG_LT" <<\_LTEOF
615 lt_cl_silent=false
616 exec AS_MESSAGE_LOG_FD>>config.log
617 {
618 echo
619 AS_BOX([Running $as_me.])
620 } >&AS_MESSAGE_LOG_FD
621
622 lt_cl_help="\
623 \`$as_me' creates a local libtool stub from the current configuration,
624 for use in further configure time tests before the real libtool is
625 generated.
626
627 Usage: $[0] [[OPTIONS]]
628
629 -h, --help print this help, then exit
630 -V, --version print version number, then exit
631 -q, --quiet do not print progress messages
632 -d, --debug don't remove temporary files
633
634 Report bugs to <bug-libtool@gnu.org>."
635
636 lt_cl_version="\
637 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
638 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
639 configured by $[0], generated by m4_PACKAGE_STRING.
640
641 Copyright (C) 2011 Free Software Foundation, Inc.
642 This config.lt script is free software; the Free Software Foundation
643 gives unlimited permision to copy, distribute and modify it."
644
645 while test $[#] != 0
646 do
647 case $[1] in
648 --version | --v* | -V )
649 echo "$lt_cl_version"; exit 0 ;;
650 --help | --h* | -h )
651 echo "$lt_cl_help"; exit 0 ;;
652 --debug | --d* | -d )
653 debug=: ;;
654 --quiet | --q* | --silent | --s* | -q )
655 lt_cl_silent=: ;;
656
657 -*) AC_MSG_ERROR([unrecognized option: $[1]
658 Try \`$[0] --help' for more information.]) ;;
659
660 *) AC_MSG_ERROR([unrecognized argument: $[1]
661 Try \`$[0] --help' for more information.]) ;;
662 esac
663 shift
664 done
665
666 if $lt_cl_silent; then
667 exec AS_MESSAGE_FD>/dev/null
668 fi
669 _LTEOF
670
671 cat >>"$CONFIG_LT" <<_LTEOF
672 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
673 _LTEOF
674
675 cat >>"$CONFIG_LT" <<\_LTEOF
676 AC_MSG_NOTICE([creating $ofile])
677 _LT_OUTPUT_LIBTOOL_COMMANDS
678 AS_EXIT(0)
679 _LTEOF
680 chmod +x "$CONFIG_LT"
681
682 # configure is writing to config.log, but config.lt does its own redirection,
683 # appending to config.log, which fails on DOS, as config.log is still kept
684 # open by configure. Here we exec the FD to /dev/null, effectively closing
685 # config.log, so it can be properly (re)opened and appended to by config.lt.
686 lt_cl_success=:
687 test "$silent" = yes &&
688 lt_config_lt_args="$lt_config_lt_args --quiet"
689 exec AS_MESSAGE_LOG_FD>/dev/null
690 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
691 exec AS_MESSAGE_LOG_FD>>config.log
692 $lt_cl_success || AS_EXIT(1)
693 ])# LT_OUTPUT
694
695
696 # _LT_CONFIG(TAG)
697 # ---------------
698 # If TAG is the built-in tag, create an initial libtool script with a
699 # default configuration from the untagged config vars. Otherwise add code
700 # to config.status for appending the configuration named by TAG from the
701 # matching tagged config vars.
702 m4_defun([_LT_CONFIG],
703 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
704 _LT_CONFIG_SAVE_COMMANDS([
705 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
706 m4_if(_LT_TAG, [C], [
707 # See if we are running on zsh, and set the options which allow our
708 # commands through without removal of \ escapes.
709 if test -n "${ZSH_VERSION+set}" ; then
710 setopt NO_GLOB_SUBST
711 fi
712
713 cfgfile="${ofile}T"
714 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
715 $RM "$cfgfile"
716
717 cat <<_LT_EOF >> "$cfgfile"
718 #! $SHELL
719
720 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
721 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
722 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
723 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
724 #
725 _LT_COPYING
726 _LT_LIBTOOL_TAGS
727
728 # ### BEGIN LIBTOOL CONFIG
729 _LT_LIBTOOL_CONFIG_VARS
730 _LT_LIBTOOL_TAG_VARS
731 # ### END LIBTOOL CONFIG
732
733 _LT_EOF
734
735 case $host_os in
736 aix3*)
737 cat <<\_LT_EOF >> "$cfgfile"
738 # AIX sometimes has problems with the GCC collect2 program. For some
739 # reason, if we set the COLLECT_NAMES environment variable, the problems
740 # vanish in a puff of smoke.
741 if test "X${COLLECT_NAMES+set}" != Xset; then
742 COLLECT_NAMES=
743 export COLLECT_NAMES
744 fi
745 _LT_EOF
746 ;;
747 esac
748
749 _LT_PROG_LTMAIN
750
751 # We use sed instead of cat because bash on DJGPP gets confused if
752 # if finds mixed CR/LF and LF-only lines. Since sed operates in
753 # text mode, it properly converts lines to CR/LF. This bash problem
754 # is reportedly fixed, but why not run on old versions too?
755 sed '$q' "$ltmain" >> "$cfgfile" \
756 || (rm -f "$cfgfile"; exit 1)
757
758 _LT_PROG_REPLACE_SHELLFNS
759
760 mv -f "$cfgfile" "$ofile" ||
761 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
762 chmod +x "$ofile"
763 ],
764 [cat <<_LT_EOF >> "$ofile"
765
766 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
767 dnl in a comment (ie after a #).
768 # ### BEGIN LIBTOOL TAG CONFIG: $1
769 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
770 # ### END LIBTOOL TAG CONFIG: $1
771 _LT_EOF
772 ])dnl /m4_if
773 ],
774 [m4_if([$1], [], [
775 PACKAGE='$PACKAGE'
776 VERSION='$VERSION'
777 TIMESTAMP='$TIMESTAMP'
778 RM='$RM'
779 ofile='$ofile'], [])
780 ])dnl /_LT_CONFIG_SAVE_COMMANDS
781 ])# _LT_CONFIG
782
783
784 # LT_SUPPORTED_TAG(TAG)
785 # ---------------------
786 # Trace this macro to discover what tags are supported by the libtool
787 # --tag option, using:
788 # autoconf --trace 'LT_SUPPORTED_TAG:$1'
789 AC_DEFUN([LT_SUPPORTED_TAG], [])
790
791
792 # C support is built-in for now
793 m4_define([_LT_LANG_C_enabled], [])
794 m4_define([_LT_TAGS], [])
795
796
797 # LT_LANG(LANG)
798 # -------------
799 # Enable libtool support for the given language if not already enabled.
800 AC_DEFUN([LT_LANG],
801 [AC_BEFORE([$0], [LT_OUTPUT])dnl
802 m4_case([$1],
803 [C], [_LT_LANG(C)],
804 [C++], [_LT_LANG(CXX)],
805 [Go], [_LT_LANG(GO)],
806 [Java], [_LT_LANG(GCJ)],
807 [Fortran 77], [_LT_LANG(F77)],
808 [Fortran], [_LT_LANG(FC)],
809 [Windows Resource], [_LT_LANG(RC)],
810 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
811 [_LT_LANG($1)],
812 [m4_fatal([$0: unsupported language: "$1"])])])dnl
813 ])# LT_LANG
814
815
816 # _LT_LANG(LANGNAME)
817 # ------------------
818 m4_defun([_LT_LANG],
819 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
820 [LT_SUPPORTED_TAG([$1])dnl
821 m4_append([_LT_TAGS], [$1 ])dnl
822 m4_define([_LT_LANG_]$1[_enabled], [])dnl
823 _LT_LANG_$1_CONFIG($1)])dnl
824 ])# _LT_LANG
825
826
827 m4_ifndef([AC_PROG_GO], [
828 ############################################################
829 # NOTE: This macro has been submitted for inclusion into #
830 # GNU Autoconf as AC_PROG_GO. When it is available in #
831 # a released version of Autoconf we should remove this #
832 # macro and use it instead. #
833 ############################################################
834 m4_defun([AC_PROG_GO],
835 [AC_LANG_PUSH(Go)dnl
836 AC_ARG_VAR([GOC], [Go compiler command])dnl
837 AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
838 _AC_ARG_VAR_LDFLAGS()dnl
839 AC_CHECK_TOOL(GOC, gccgo)
840 if test -z "$GOC"; then
841 if test -n "$ac_tool_prefix"; then
842 AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
843 fi
844 fi
845 if test -z "$GOC"; then
846 AC_CHECK_PROG(GOC, gccgo, gccgo, false)
847 fi
848 ])#m4_defun
849 ])#m4_ifndef
850
851
852 # _LT_LANG_DEFAULT_CONFIG
853 # -----------------------
854 m4_defun([_LT_LANG_DEFAULT_CONFIG],
855 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
856 [LT_LANG(CXX)],
857 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
858
859 AC_PROVIDE_IFELSE([AC_PROG_F77],
860 [LT_LANG(F77)],
861 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
862
863 AC_PROVIDE_IFELSE([AC_PROG_FC],
864 [LT_LANG(FC)],
865 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
866
867 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
868 dnl pulling things in needlessly.
869 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
870 [LT_LANG(GCJ)],
871 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
872 [LT_LANG(GCJ)],
873 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
874 [LT_LANG(GCJ)],
875 [m4_ifdef([AC_PROG_GCJ],
876 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
877 m4_ifdef([A][M_PROG_GCJ],
878 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
879 m4_ifdef([LT_PROG_GCJ],
880 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
881
882 AC_PROVIDE_IFELSE([AC_PROG_GO],
883 [LT_LANG(GO)],
884 [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
885
886 AC_PROVIDE_IFELSE([LT_PROG_RC],
887 [LT_LANG(RC)],
888 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
889 ])# _LT_LANG_DEFAULT_CONFIG
890
891 # Obsolete macros:
892 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
893 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
894 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
895 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
896 AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
897 dnl aclocal-1.4 backwards compatibility:
898 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
899 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
900 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
901 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
902 dnl AC_DEFUN([AC_LIBTOOL_RC], [])
903
904
905 # _LT_TAG_COMPILER
906 # ----------------
907 m4_defun([_LT_TAG_COMPILER],
908 [AC_REQUIRE([AC_PROG_CC])dnl
909
910 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
911 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
912 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
913 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
914
915 # If no C compiler was specified, use CC.
916 LTCC=${LTCC-"$CC"}
917
918 # If no C compiler flags were specified, use CFLAGS.
919 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
920
921 # Allow CC to be a program name with arguments.
922 compiler=$CC
923 ])# _LT_TAG_COMPILER
924
925
926 # _LT_COMPILER_BOILERPLATE
927 # ------------------------
928 # Check for compiler boilerplate output or warnings with
929 # the simple compiler test code.
930 m4_defun([_LT_COMPILER_BOILERPLATE],
931 [m4_require([_LT_DECL_SED])dnl
932 ac_outfile=conftest.$ac_objext
933 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
934 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
935 _lt_compiler_boilerplate=`cat conftest.err`
936 $RM conftest*
937 ])# _LT_COMPILER_BOILERPLATE
938
939
940 # _LT_LINKER_BOILERPLATE
941 # ----------------------
942 # Check for linker boilerplate output or warnings with
943 # the simple link test code.
944 m4_defun([_LT_LINKER_BOILERPLATE],
945 [m4_require([_LT_DECL_SED])dnl
946 ac_outfile=conftest.$ac_objext
947 echo "$lt_simple_link_test_code" >conftest.$ac_ext
948 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
949 _lt_linker_boilerplate=`cat conftest.err`
950 $RM -r conftest*
951 ])# _LT_LINKER_BOILERPLATE
952
953 # _LT_REQUIRED_DARWIN_CHECKS
954 # -------------------------
955 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
956 case $host_os in
957 rhapsody* | darwin*)
958 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
959 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
960 AC_CHECK_TOOL([LIPO], [lipo], [:])
961 AC_CHECK_TOOL([OTOOL], [otool], [:])
962 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
963 _LT_DECL([], [DSYMUTIL], [1],
964 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
965 _LT_DECL([], [NMEDIT], [1],
966 [Tool to change global to local symbols on Mac OS X])
967 _LT_DECL([], [LIPO], [1],
968 [Tool to manipulate fat objects and archives on Mac OS X])
969 _LT_DECL([], [OTOOL], [1],
970 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
971 _LT_DECL([], [OTOOL64], [1],
972 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
973
974 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
975 [lt_cv_apple_cc_single_mod=no
976 if test -z "${LT_MULTI_MODULE}"; then
977 # By default we will add the -single_module flag. You can override
978 # by either setting the environment variable LT_MULTI_MODULE
979 # non-empty at configure time, or by adding -multi_module to the
980 # link flags.
981 rm -rf libconftest.dylib*
982 echo "int foo(void){return 1;}" > conftest.c
983 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
984 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
985 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
986 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
987 _lt_result=$?
988 # If there is a non-empty error log, and "single_module"
989 # appears in it, assume the flag caused a linker warning
990 if test -s conftest.err && $GREP single_module conftest.err; then
991 cat conftest.err >&AS_MESSAGE_LOG_FD
992 # Otherwise, if the output was created with a 0 exit code from
993 # the compiler, it worked.
994 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
995 lt_cv_apple_cc_single_mod=yes
996 else
997 cat conftest.err >&AS_MESSAGE_LOG_FD
998 fi
999 rm -rf libconftest.dylib*
1000 rm -f conftest.*
1001 fi])
1002
1003 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1004 [lt_cv_ld_exported_symbols_list],
1005 [lt_cv_ld_exported_symbols_list=no
1006 save_LDFLAGS=$LDFLAGS
1007 echo "_main" > conftest.sym
1008 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1009 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1010 [lt_cv_ld_exported_symbols_list=yes],
1011 [lt_cv_ld_exported_symbols_list=no])
1012 LDFLAGS="$save_LDFLAGS"
1013 ])
1014
1015 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
1016 [lt_cv_ld_force_load=no
1017 cat > conftest.c << _LT_EOF
1018 int forced_loaded() { return 2;}
1019 _LT_EOF
1020 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1021 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1022 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1023 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1024 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1025 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1026 cat > conftest.c << _LT_EOF
1027 int main() { return 0;}
1028 _LT_EOF
1029 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
1030 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
1031 _lt_result=$?
1032 if test -s conftest.err && $GREP force_load conftest.err; then
1033 cat conftest.err >&AS_MESSAGE_LOG_FD
1034 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
1035 lt_cv_ld_force_load=yes
1036 else
1037 cat conftest.err >&AS_MESSAGE_LOG_FD
1038 fi
1039 rm -f conftest.err libconftest.a conftest conftest.c
1040 rm -rf conftest.dSYM
1041 ])
1042 case $host_os in
1043 rhapsody* | darwin1.[[012]])
1044 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1045 darwin1.*)
1046 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1047 darwin*)
1048 case ${MACOSX_DEPLOYMENT_TARGET},$host in
1049 10.[[012]]*,*|,*powerpc*)
1050 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1051 *)
1052 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1053 esac
1054 ;;
1055 esac
1056 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1057 _lt_dar_single_mod='$single_module'
1058 fi
1059 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1060 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1061 else
1062 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1063 fi
1064 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
1065 _lt_dsymutil='~$DSYMUTIL $lib || :'
1066 else
1067 _lt_dsymutil=
1068 fi
1069 ;;
1070 esac
1071 ])
1072
1073
1074 # _LT_DARWIN_LINKER_FEATURES([TAG])
1075 # ---------------------------------
1076 # Checks for linker and compiler features on darwin
1077 m4_defun([_LT_DARWIN_LINKER_FEATURES],
1078 [
1079 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1080 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1081 _LT_TAGVAR(hardcode_direct, $1)=no
1082 _LT_TAGVAR(hardcode_automatic, $1)=yes
1083 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1084 if test "$lt_cv_ld_force_load" = "yes"; then
1085 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1086 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
1087 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
1088 else
1089 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1090 fi
1091 _LT_TAGVAR(link_all_deplibs, $1)=yes
1092 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1093 case $cc_basename in
1094 ifort*) _lt_dar_can_shared=yes ;;
1095 *) _lt_dar_can_shared=$GCC ;;
1096 esac
1097 if test "$_lt_dar_can_shared" = "yes"; then
1098 output_verbose_link_cmd=func_echo_all
1099 _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}"
1100 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1101 _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}"
1102 _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}"
1103 m4_if([$1], [CXX],
1104 [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1105 _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}"
1106 _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}"
1107 fi
1108 ],[])
1109 else
1110 _LT_TAGVAR(ld_shlibs, $1)=no
1111 fi
1112 ])
1113
1114 # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
1115 # ----------------------------------
1116 # Links a minimal program and checks the executable
1117 # for the system default hardcoded library path. In most cases,
1118 # this is /usr/lib:/lib, but when the MPI compilers are used
1119 # the location of the communication and MPI libs are included too.
1120 # If we don't find anything, use the default library path according
1121 # to the aix ld manual.
1122 # Store the results from the different compilers for each TAGNAME.
1123 # Allow to override them for all tags through lt_cv_aix_libpath.
1124 m4_defun([_LT_SYS_MODULE_PATH_AIX],
1125 [m4_require([_LT_DECL_SED])dnl
1126 if test "${lt_cv_aix_libpath+set}" = set; then
1127 aix_libpath=$lt_cv_aix_libpath
1128 else
1129 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
1130 [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
1131 lt_aix_libpath_sed='[
1132 /Import File Strings/,/^$/ {
1133 /^0/ {
1134 s/^0 *\([^ ]*\) *$/\1/
1135 p
1136 }
1137 }]'
1138 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1139 # Check for a 64-bit object if we didn't find anything.
1140 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1141 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1142 fi],[])
1143 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1144 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
1145 fi
1146 ])
1147 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
1148 fi
1149 ])# _LT_SYS_MODULE_PATH_AIX
1150
1151
1152 # _LT_SHELL_INIT(ARG)
1153 # -------------------
1154 m4_define([_LT_SHELL_INIT],
1155 [m4_divert_text([M4SH-INIT], [$1
1156 ])])# _LT_SHELL_INIT
1157
1158
1159
1160 # _LT_PROG_ECHO_BACKSLASH
1161 # -----------------------
1162 # Find how we can fake an echo command that does not interpret backslash.
1163 # In particular, with Autoconf 2.60 or later we add some code to the start
1164 # of the generated configure script which will find a shell with a builtin
1165 # printf (which we can use as an echo command).
1166 m4_defun([_LT_PROG_ECHO_BACKSLASH],
1167 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1168 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1169 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1170
1171 AC_MSG_CHECKING([how to print strings])
1172 # Test print first, because it will be a builtin if present.
1173 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
1174 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
1175 ECHO='print -r --'
1176 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
1177 ECHO='printf %s\n'
1178 else
1179 # Use this function as a fallback that always works.
1180 func_fallback_echo ()
1181 {
1182 eval 'cat <<_LTECHO_EOF
1183 $[]1
1184 _LTECHO_EOF'
1185 }
1186 ECHO='func_fallback_echo'
1187 fi
1188
1189 # func_echo_all arg...
1190 # Invoke $ECHO with all args, space-separated.
1191 func_echo_all ()
1192 {
1193 $ECHO "$*"
1194 }
1195
1196 case "$ECHO" in
1197 printf*) AC_MSG_RESULT([printf]) ;;
1198 print*) AC_MSG_RESULT([print -r]) ;;
1199 *) AC_MSG_RESULT([cat]) ;;
1200 esac
1201
1202 m4_ifdef([_AS_DETECT_SUGGESTED],
1203 [_AS_DETECT_SUGGESTED([
1204 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
1205 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1206 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1207 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1208 PATH=/empty FPATH=/empty; export PATH FPATH
1209 test "X`printf %s $ECHO`" = "X$ECHO" \
1210 || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
1211
1212 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1213 _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1214 ])# _LT_PROG_ECHO_BACKSLASH
1215
1216
1217 # _LT_WITH_SYSROOT
1218 # ----------------
1219 AC_DEFUN([_LT_WITH_SYSROOT],
1220 [AC_MSG_CHECKING([for sysroot])
1221 AC_ARG_WITH([sysroot],
1222 [ --with-sysroot[=DIR] Search for dependent libraries within DIR
1223 (or the compiler's sysroot if not specified).],
1224 [], [with_sysroot=no])
1225
1226 dnl lt_sysroot will always be passed unquoted. We quote it here
1227 dnl in case the user passed a directory name.
1228 lt_sysroot=
1229 case ${with_sysroot} in #(
1230 yes)
1231 if test "$GCC" = yes; then
1232 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
1233 fi
1234 ;; #(
1235 /*)
1236 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
1237 ;; #(
1238 no|'')
1239 ;; #(
1240 *)
1241 AC_MSG_RESULT([${with_sysroot}])
1242 AC_MSG_ERROR([The sysroot must be an absolute path.])
1243 ;;
1244 esac
1245
1246 AC_MSG_RESULT([${lt_sysroot:-no}])
1247 _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
1248 [dependent libraries, and in which our libraries should be installed.])])
1249
1250 # _LT_ENABLE_LOCK
1251 # ---------------
1252 m4_defun([_LT_ENABLE_LOCK],
1253 [AC_ARG_ENABLE([libtool-lock],
1254 [AS_HELP_STRING([--disable-libtool-lock],
1255 [avoid locking (might break parallel builds)])])
1256 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1257
1258 # Some flags need to be propagated to the compiler or linker for good
1259 # libtool support.
1260 case $host in
1261 ia64-*-hpux*)
1262 # Find out which ABI we are using.
1263 echo 'int i;' > conftest.$ac_ext
1264 if AC_TRY_EVAL(ac_compile); then
1265 case `/usr/bin/file conftest.$ac_objext` in
1266 *ELF-32*)
1267 HPUX_IA64_MODE="32"
1268 ;;
1269 *ELF-64*)
1270 HPUX_IA64_MODE="64"
1271 ;;
1272 esac
1273 fi
1274 rm -rf conftest*
1275 ;;
1276 *-*-irix6*)
1277 # Find out which ABI we are using.
1278 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1279 if AC_TRY_EVAL(ac_compile); then
1280 if test "$lt_cv_prog_gnu_ld" = yes; then
1281 case `/usr/bin/file conftest.$ac_objext` in
1282 *32-bit*)
1283 LD="${LD-ld} -melf32bsmip"
1284 ;;
1285 *N32*)
1286 LD="${LD-ld} -melf32bmipn32"
1287 ;;
1288 *64-bit*)
1289 LD="${LD-ld} -melf64bmip"
1290 ;;
1291 esac
1292 else
1293 case `/usr/bin/file conftest.$ac_objext` in
1294 *32-bit*)
1295 LD="${LD-ld} -32"
1296 ;;
1297 *N32*)
1298 LD="${LD-ld} -n32"
1299 ;;
1300 *64-bit*)
1301 LD="${LD-ld} -64"
1302 ;;
1303 esac
1304 fi
1305 fi
1306 rm -rf conftest*
1307 ;;
1308
1309 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1310 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1311 # Find out which ABI we are using.
1312 echo 'int i;' > conftest.$ac_ext
1313 if AC_TRY_EVAL(ac_compile); then
1314 case `/usr/bin/file conftest.o` in
1315 *32-bit*)
1316 case $host in
1317 x86_64-*kfreebsd*-gnu)
1318 LD="${LD-ld} -m elf_i386_fbsd"
1319 ;;
1320 x86_64-*linux*)
1321 LD="${LD-ld} -m elf_i386"
1322 ;;
1323 powerpc64le-*)
1324 LD="${LD-ld} -m elf32lppclinux"
1325 ;;
1326 powerpc64-*)
1327 LD="${LD-ld} -m elf32ppclinux"
1328 ;;
1329 s390x-*linux*)
1330 LD="${LD-ld} -m elf_s390"
1331 ;;
1332 sparc64-*linux*)
1333 LD="${LD-ld} -m elf32_sparc"
1334 ;;
1335 esac
1336 ;;
1337 *64-bit*)
1338 case $host in
1339 x86_64-*kfreebsd*-gnu)
1340 LD="${LD-ld} -m elf_x86_64_fbsd"
1341 ;;
1342 x86_64-*linux*)
1343 LD="${LD-ld} -m elf_x86_64"
1344 ;;
1345 powerpcle-*)
1346 LD="${LD-ld} -m elf64lppc"
1347 ;;
1348 powerpc-*)
1349 LD="${LD-ld} -m elf64ppc"
1350 ;;
1351 s390*-*linux*|s390*-*tpf*)
1352 LD="${LD-ld} -m elf64_s390"
1353 ;;
1354 sparc*-*linux*)
1355 LD="${LD-ld} -m elf64_sparc"
1356 ;;
1357 esac
1358 ;;
1359 esac
1360 fi
1361 rm -rf conftest*
1362 ;;
1363
1364 *-*-sco3.2v5*)
1365 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1366 SAVE_CFLAGS="$CFLAGS"
1367 CFLAGS="$CFLAGS -belf"
1368 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1369 [AC_LANG_PUSH(C)
1370 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1371 AC_LANG_POP])
1372 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1373 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1374 CFLAGS="$SAVE_CFLAGS"
1375 fi
1376 ;;
1377 *-*solaris*)
1378 # Find out which ABI we are using.
1379 echo 'int i;' > conftest.$ac_ext
1380 if AC_TRY_EVAL(ac_compile); then
1381 case `/usr/bin/file conftest.o` in
1382 *64-bit*)
1383 case $lt_cv_prog_gnu_ld in
1384 yes*)
1385 case $host in
1386 i?86-*-solaris*)
1387 LD="${LD-ld} -m elf_x86_64"
1388 ;;
1389 sparc*-*-solaris*)
1390 LD="${LD-ld} -m elf64_sparc"
1391 ;;
1392 esac
1393 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
1394 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
1395 LD="${LD-ld}_sol2"
1396 fi
1397 ;;
1398 *)
1399 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1400 LD="${LD-ld} -64"
1401 fi
1402 ;;
1403 esac
1404 ;;
1405 esac
1406 fi
1407 rm -rf conftest*
1408 ;;
1409 esac
1410
1411 need_locks="$enable_libtool_lock"
1412 ])# _LT_ENABLE_LOCK
1413
1414
1415 # _LT_PROG_AR
1416 # -----------
1417 m4_defun([_LT_PROG_AR],
1418 [AC_CHECK_TOOLS(AR, [ar], false)
1419 : ${AR=ar}
1420 : ${AR_FLAGS=cru}
1421 _LT_DECL([], [AR], [1], [The archiver])
1422 _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
1423
1424 AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
1425 [lt_cv_ar_at_file=no
1426 AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
1427 [echo conftest.$ac_objext > conftest.lst
1428 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
1429 AC_TRY_EVAL([lt_ar_try])
1430 if test "$ac_status" -eq 0; then
1431 # Ensure the archiver fails upon bogus file names.
1432 rm -f conftest.$ac_objext libconftest.a
1433 AC_TRY_EVAL([lt_ar_try])
1434 if test "$ac_status" -ne 0; then
1435 lt_cv_ar_at_file=@
1436 fi
1437 fi
1438 rm -f conftest.* libconftest.a
1439 ])
1440 ])
1441
1442 if test "x$lt_cv_ar_at_file" = xno; then
1443 archiver_list_spec=
1444 else
1445 archiver_list_spec=$lt_cv_ar_at_file
1446 fi
1447 _LT_DECL([], [archiver_list_spec], [1],
1448 [How to feed a file listing to the archiver])
1449 ])# _LT_PROG_AR
1450
1451
1452 # _LT_CMD_OLD_ARCHIVE
1453 # -------------------
1454 m4_defun([_LT_CMD_OLD_ARCHIVE],
1455 [_LT_PROG_AR
1456
1457 AC_CHECK_TOOL(STRIP, strip, :)
1458 test -z "$STRIP" && STRIP=:
1459 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
1460
1461 AC_CHECK_TOOL(RANLIB, ranlib, :)
1462 test -z "$RANLIB" && RANLIB=:
1463 _LT_DECL([], [RANLIB], [1],
1464 [Commands used to install an old-style archive])
1465
1466 # Determine commands to create old-style static archives.
1467 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1468 old_postinstall_cmds='chmod 644 $oldlib'
1469 old_postuninstall_cmds=
1470
1471 if test -n "$RANLIB"; then
1472 case $host_os in
1473 openbsd*)
1474 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
1475 ;;
1476 *)
1477 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
1478 ;;
1479 esac
1480 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
1481 fi
1482
1483 case $host_os in
1484 darwin*)
1485 lock_old_archive_extraction=yes ;;
1486 *)
1487 lock_old_archive_extraction=no ;;
1488 esac
1489 _LT_DECL([], [old_postinstall_cmds], [2])
1490 _LT_DECL([], [old_postuninstall_cmds], [2])
1491 _LT_TAGDECL([], [old_archive_cmds], [2],
1492 [Commands used to build an old-style archive])
1493 _LT_DECL([], [lock_old_archive_extraction], [0],
1494 [Whether to use a lock for old archive extraction])
1495 ])# _LT_CMD_OLD_ARCHIVE
1496
1497
1498 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1499 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1500 # ----------------------------------------------------------------
1501 # Check whether the given compiler option works
1502 AC_DEFUN([_LT_COMPILER_OPTION],
1503 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1504 m4_require([_LT_DECL_SED])dnl
1505 AC_CACHE_CHECK([$1], [$2],
1506 [$2=no
1507 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1508 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1509 lt_compiler_flag="$3"
1510 # Insert the option either (1) after the last *FLAGS variable, or
1511 # (2) before a word containing "conftest.", or (3) at the end.
1512 # Note that $ac_compile itself does not contain backslashes and begins
1513 # with a dollar sign (not a hyphen), so the echo should work correctly.
1514 # The option is referenced via a variable to avoid confusing sed.
1515 lt_compile=`echo "$ac_compile" | $SED \
1516 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1517 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1518 -e 's:$: $lt_compiler_flag:'`
1519 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1520 (eval "$lt_compile" 2>conftest.err)
1521 ac_status=$?
1522 cat conftest.err >&AS_MESSAGE_LOG_FD
1523 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1524 if (exit $ac_status) && test -s "$ac_outfile"; then
1525 # The compiler can only warn and ignore the option if not recognized
1526 # So say no if there are warnings other than the usual output.
1527 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
1528 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1529 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1530 $2=yes
1531 fi
1532 fi
1533 $RM conftest*
1534 ])
1535
1536 if test x"[$]$2" = xyes; then
1537 m4_if([$5], , :, [$5])
1538 else
1539 m4_if([$6], , :, [$6])
1540 fi
1541 ])# _LT_COMPILER_OPTION
1542
1543 # Old name:
1544 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
1545 dnl aclocal-1.4 backwards compatibility:
1546 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
1547
1548
1549 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1550 # [ACTION-SUCCESS], [ACTION-FAILURE])
1551 # ----------------------------------------------------
1552 # Check whether the given linker option works
1553 AC_DEFUN([_LT_LINKER_OPTION],
1554 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1555 m4_require([_LT_DECL_SED])dnl
1556 AC_CACHE_CHECK([$1], [$2],
1557 [$2=no
1558 save_LDFLAGS="$LDFLAGS"
1559 LDFLAGS="$LDFLAGS $3"
1560 echo "$lt_simple_link_test_code" > conftest.$ac_ext
1561 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1562 # The linker can only warn and ignore the option if not recognized
1563 # So say no if there are warnings
1564 if test -s conftest.err; then
1565 # Append any errors to the config.log.
1566 cat conftest.err 1>&AS_MESSAGE_LOG_FD
1567 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
1568 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1569 if diff conftest.exp conftest.er2 >/dev/null; then
1570 $2=yes
1571 fi
1572 else
1573 $2=yes
1574 fi
1575 fi
1576 $RM -r conftest*
1577 LDFLAGS="$save_LDFLAGS"
1578 ])
1579
1580 if test x"[$]$2" = xyes; then
1581 m4_if([$4], , :, [$4])
1582 else
1583 m4_if([$5], , :, [$5])
1584 fi
1585 ])# _LT_LINKER_OPTION
1586
1587 # Old name:
1588 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
1589 dnl aclocal-1.4 backwards compatibility:
1590 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
1591
1592
1593 # LT_CMD_MAX_LEN
1594 #---------------
1595 AC_DEFUN([LT_CMD_MAX_LEN],
1596 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1597 # find the maximum length of command line arguments
1598 AC_MSG_CHECKING([the maximum length of command line arguments])
1599 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1600 i=0
1601 teststring="ABCD"
1602
1603 case $build_os in
1604 msdosdjgpp*)
1605 # On DJGPP, this test can blow up pretty badly due to problems in libc
1606 # (any single argument exceeding 2000 bytes causes a buffer overrun
1607 # during glob expansion). Even if it were fixed, the result of this
1608 # check would be larger than it should be.
1609 lt_cv_sys_max_cmd_len=12288; # 12K is about right
1610 ;;
1611
1612 gnu*)
1613 # Under GNU Hurd, this test is not required because there is
1614 # no limit to the length of command line arguments.
1615 # Libtool will interpret -1 as no limit whatsoever
1616 lt_cv_sys_max_cmd_len=-1;
1617 ;;
1618
1619 cygwin* | mingw* | cegcc*)
1620 # On Win9x/ME, this test blows up -- it succeeds, but takes
1621 # about 5 minutes as the teststring grows exponentially.
1622 # Worse, since 9x/ME are not pre-emptively multitasking,
1623 # you end up with a "frozen" computer, even though with patience
1624 # the test eventually succeeds (with a max line length of 256k).
1625 # Instead, let's just punt: use the minimum linelength reported by
1626 # all of the supported platforms: 8192 (on NT/2K/XP).
1627 lt_cv_sys_max_cmd_len=8192;
1628 ;;
1629
1630 mint*)
1631 # On MiNT this can take a long time and run out of memory.
1632 lt_cv_sys_max_cmd_len=8192;
1633 ;;
1634
1635 amigaos*)
1636 # On AmigaOS with pdksh, this test takes hours, literally.
1637 # So we just punt and use a minimum line length of 8192.
1638 lt_cv_sys_max_cmd_len=8192;
1639 ;;
1640
1641 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1642 # This has been around since 386BSD, at least. Likely further.
1643 if test -x /sbin/sysctl; then
1644 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1645 elif test -x /usr/sbin/sysctl; then
1646 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1647 else
1648 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1649 fi
1650 # And add a safety zone
1651 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1652 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1653 ;;
1654
1655 interix*)
1656 # We know the value 262144 and hardcode it with a safety zone (like BSD)
1657 lt_cv_sys_max_cmd_len=196608
1658 ;;
1659
1660 os2*)
1661 # The test takes a long time on OS/2.
1662 lt_cv_sys_max_cmd_len=8192
1663 ;;
1664
1665 osf*)
1666 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1667 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1668 # nice to cause kernel panics so lets avoid the loop below.
1669 # First set a reasonable default.
1670 lt_cv_sys_max_cmd_len=16384
1671 #
1672 if test -x /sbin/sysconfig; then
1673 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1674 *1*) lt_cv_sys_max_cmd_len=-1 ;;
1675 esac
1676 fi
1677 ;;
1678 sco3.2v5*)
1679 lt_cv_sys_max_cmd_len=102400
1680 ;;
1681 sysv5* | sco5v6* | sysv4.2uw2*)
1682 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1683 if test -n "$kargmax"; then
1684 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1685 else
1686 lt_cv_sys_max_cmd_len=32768
1687 fi
1688 ;;
1689 *)
1690 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1691 if test -n "$lt_cv_sys_max_cmd_len"; then
1692 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1693 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1694 else
1695 # Make teststring a little bigger before we do anything with it.
1696 # a 1K string should be a reasonable start.
1697 for i in 1 2 3 4 5 6 7 8 ; do
1698 teststring=$teststring$teststring
1699 done
1700 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1701 # If test is not a shell built-in, we'll probably end up computing a
1702 # maximum length that is only half of the actual maximum length, but
1703 # we can't tell.
1704 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
1705 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
1706 test $i != 17 # 1/2 MB should be enough
1707 do
1708 i=`expr $i + 1`
1709 teststring=$teststring$teststring
1710 done
1711 # Only check the string length outside the loop.
1712 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
1713 teststring=
1714 # Add a significant safety factor because C++ compilers can tack on
1715 # massive amounts of additional arguments before passing them to the
1716 # linker. It appears as though 1/2 is a usable value.
1717 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1718 fi
1719 ;;
1720 esac
1721 ])
1722 if test -n $lt_cv_sys_max_cmd_len ; then
1723 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1724 else
1725 AC_MSG_RESULT(none)
1726 fi
1727 max_cmd_len=$lt_cv_sys_max_cmd_len
1728 _LT_DECL([], [max_cmd_len], [0],
1729 [What is the maximum length of a command?])
1730 ])# LT_CMD_MAX_LEN
1731
1732 # Old name:
1733 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
1734 dnl aclocal-1.4 backwards compatibility:
1735 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
1736
1737
1738 # _LT_HEADER_DLFCN
1739 # ----------------
1740 m4_defun([_LT_HEADER_DLFCN],
1741 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
1742 ])# _LT_HEADER_DLFCN
1743
1744
1745 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1746 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1747 # ----------------------------------------------------------------
1748 m4_defun([_LT_TRY_DLOPEN_SELF],
1749 [m4_require([_LT_HEADER_DLFCN])dnl
1750 if test "$cross_compiling" = yes; then :
1751 [$4]
1752 else
1753 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1754 lt_status=$lt_dlunknown
1755 cat > conftest.$ac_ext <<_LT_EOF
1756 [#line $LINENO "configure"
1757 #include "confdefs.h"
1758
1759 #if HAVE_DLFCN_H
1760 #include <dlfcn.h>
1761 #endif
1762
1763 #include <stdio.h>
1764
1765 #ifdef RTLD_GLOBAL
1766 # define LT_DLGLOBAL RTLD_GLOBAL
1767 #else
1768 # ifdef DL_GLOBAL
1769 # define LT_DLGLOBAL DL_GLOBAL
1770 # else
1771 # define LT_DLGLOBAL 0
1772 # endif
1773 #endif
1774
1775 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1776 find out it does not work in some platform. */
1777 #ifndef LT_DLLAZY_OR_NOW
1778 # ifdef RTLD_LAZY
1779 # define LT_DLLAZY_OR_NOW RTLD_LAZY
1780 # else
1781 # ifdef DL_LAZY
1782 # define LT_DLLAZY_OR_NOW DL_LAZY
1783 # else
1784 # ifdef RTLD_NOW
1785 # define LT_DLLAZY_OR_NOW RTLD_NOW
1786 # else
1787 # ifdef DL_NOW
1788 # define LT_DLLAZY_OR_NOW DL_NOW
1789 # else
1790 # define LT_DLLAZY_OR_NOW 0
1791 # endif
1792 # endif
1793 # endif
1794 # endif
1795 #endif
1796
1797 /* When -fvisbility=hidden is used, assume the code has been annotated
1798 correspondingly for the symbols needed. */
1799 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1800 int fnord () __attribute__((visibility("default")));
1801 #endif
1802
1803 int fnord () { return 42; }
1804 int main ()
1805 {
1806 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1807 int status = $lt_dlunknown;
1808
1809 if (self)
1810 {
1811 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1812 else
1813 {
1814 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1815 else puts (dlerror ());
1816 }
1817 /* dlclose (self); */
1818 }
1819 else
1820 puts (dlerror ());
1821
1822 return status;
1823 }]
1824 _LT_EOF
1825 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1826 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1827 lt_status=$?
1828 case x$lt_status in
1829 x$lt_dlno_uscore) $1 ;;
1830 x$lt_dlneed_uscore) $2 ;;
1831 x$lt_dlunknown|x*) $3 ;;
1832 esac
1833 else :
1834 # compilation failed
1835 $3
1836 fi
1837 fi
1838 rm -fr conftest*
1839 ])# _LT_TRY_DLOPEN_SELF
1840
1841
1842 # LT_SYS_DLOPEN_SELF
1843 # ------------------
1844 AC_DEFUN([LT_SYS_DLOPEN_SELF],
1845 [m4_require([_LT_HEADER_DLFCN])dnl
1846 if test "x$enable_dlopen" != xyes; then
1847 enable_dlopen=unknown
1848 enable_dlopen_self=unknown
1849 enable_dlopen_self_static=unknown
1850 else
1851 lt_cv_dlopen=no
1852 lt_cv_dlopen_libs=
1853
1854 case $host_os in
1855 beos*)
1856 lt_cv_dlopen="load_add_on"
1857 lt_cv_dlopen_libs=
1858 lt_cv_dlopen_self=yes
1859 ;;
1860
1861 mingw* | pw32* | cegcc*)
1862 lt_cv_dlopen="LoadLibrary"
1863 lt_cv_dlopen_libs=
1864 ;;
1865
1866 cygwin*)
1867 lt_cv_dlopen="dlopen"
1868 lt_cv_dlopen_libs=
1869 ;;
1870
1871 darwin*)
1872 # if libdl is installed we need to link against it
1873 AC_CHECK_LIB([dl], [dlopen],
1874 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1875 lt_cv_dlopen="dyld"
1876 lt_cv_dlopen_libs=
1877 lt_cv_dlopen_self=yes
1878 ])
1879 ;;
1880
1881 *)
1882 AC_CHECK_FUNC([shl_load],
1883 [lt_cv_dlopen="shl_load"],
1884 [AC_CHECK_LIB([dld], [shl_load],
1885 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1886 [AC_CHECK_FUNC([dlopen],
1887 [lt_cv_dlopen="dlopen"],
1888 [AC_CHECK_LIB([dl], [dlopen],
1889 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1890 [AC_CHECK_LIB([svld], [dlopen],
1891 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1892 [AC_CHECK_LIB([dld], [dld_link],
1893 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1894 ])
1895 ])
1896 ])
1897 ])
1898 ])
1899 ;;
1900 esac
1901
1902 if test "x$lt_cv_dlopen" != xno; then
1903 enable_dlopen=yes
1904 else
1905 enable_dlopen=no
1906 fi
1907
1908 case $lt_cv_dlopen in
1909 dlopen)
1910 save_CPPFLAGS="$CPPFLAGS"
1911 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1912
1913 save_LDFLAGS="$LDFLAGS"
1914 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1915
1916 save_LIBS="$LIBS"
1917 LIBS="$lt_cv_dlopen_libs $LIBS"
1918
1919 AC_CACHE_CHECK([whether a program can dlopen itself],
1920 lt_cv_dlopen_self, [dnl
1921 _LT_TRY_DLOPEN_SELF(
1922 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1923 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1924 ])
1925
1926 if test "x$lt_cv_dlopen_self" = xyes; then
1927 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1928 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1929 lt_cv_dlopen_self_static, [dnl
1930 _LT_TRY_DLOPEN_SELF(
1931 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1932 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1933 ])
1934 fi
1935
1936 CPPFLAGS="$save_CPPFLAGS"
1937 LDFLAGS="$save_LDFLAGS"
1938 LIBS="$save_LIBS"
1939 ;;
1940 esac
1941
1942 case $lt_cv_dlopen_self in
1943 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1944 *) enable_dlopen_self=unknown ;;
1945 esac
1946
1947 case $lt_cv_dlopen_self_static in
1948 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1949 *) enable_dlopen_self_static=unknown ;;
1950 esac
1951 fi
1952 _LT_DECL([dlopen_support], [enable_dlopen], [0],
1953 [Whether dlopen is supported])
1954 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
1955 [Whether dlopen of programs is supported])
1956 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
1957 [Whether dlopen of statically linked programs is supported])
1958 ])# LT_SYS_DLOPEN_SELF
1959
1960 # Old name:
1961 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
1962 dnl aclocal-1.4 backwards compatibility:
1963 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
1964
1965
1966 # _LT_COMPILER_C_O([TAGNAME])
1967 # ---------------------------
1968 # Check to see if options -c and -o are simultaneously supported by compiler.
1969 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
1970 m4_defun([_LT_COMPILER_C_O],
1971 [m4_require([_LT_DECL_SED])dnl
1972 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1973 m4_require([_LT_TAG_COMPILER])dnl
1974 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1975 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1976 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1977 $RM -r conftest 2>/dev/null
1978 mkdir conftest
1979 cd conftest
1980 mkdir out
1981 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1982
1983 lt_compiler_flag="-o out/conftest2.$ac_objext"
1984 # Insert the option either (1) after the last *FLAGS variable, or
1985 # (2) before a word containing "conftest.", or (3) at the end.
1986 # Note that $ac_compile itself does not contain backslashes and begins
1987 # with a dollar sign (not a hyphen), so the echo should work correctly.
1988 lt_compile=`echo "$ac_compile" | $SED \
1989 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1990 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1991 -e 's:$: $lt_compiler_flag:'`
1992 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1993 (eval "$lt_compile" 2>out/conftest.err)
1994 ac_status=$?
1995 cat out/conftest.err >&AS_MESSAGE_LOG_FD
1996 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1997 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1998 then
1999 # The compiler can only warn and ignore the option if not recognized
2000 # So say no if there are warnings
2001 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
2002 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2003 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2004 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2005 fi
2006 fi
2007 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2008 $RM conftest*
2009 # SGI C++ compiler will create directory out/ii_files/ for
2010 # template instantiation
2011 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2012 $RM out/* && rmdir out
2013 cd ..
2014 $RM -r conftest
2015 $RM conftest*
2016 ])
2017 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2018 [Does compiler simultaneously support -c and -o options?])
2019 ])# _LT_COMPILER_C_O
2020
2021
2022 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
2023 # ----------------------------------
2024 # Check to see if we can do hard links to lock some files if needed
2025 m4_defun([_LT_COMPILER_FILE_LOCKS],
2026 [m4_require([_LT_ENABLE_LOCK])dnl
2027 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2028 _LT_COMPILER_C_O([$1])
2029
2030 hard_links="nottested"
2031 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2032 # do not overwrite the value of need_locks provided by the user
2033 AC_MSG_CHECKING([if we can lock with hard links])
2034 hard_links=yes
2035 $RM conftest*
2036 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2037 touch conftest.a
2038 ln conftest.a conftest.b 2>&5 || hard_links=no
2039 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2040 AC_MSG_RESULT([$hard_links])
2041 if test "$hard_links" = no; then
2042 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2043 need_locks=warn
2044 fi
2045 else
2046 need_locks=no
2047 fi
2048 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2049 ])# _LT_COMPILER_FILE_LOCKS
2050
2051
2052 # _LT_CHECK_OBJDIR
2053 # ----------------
2054 m4_defun([_LT_CHECK_OBJDIR],
2055 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2056 [rm -f .libs 2>/dev/null
2057 mkdir .libs 2>/dev/null
2058 if test -d .libs; then
2059 lt_cv_objdir=.libs
2060 else
2061 # MS-DOS does not allow filenames that begin with a dot.
2062 lt_cv_objdir=_libs
2063 fi
2064 rmdir .libs 2>/dev/null])
2065 objdir=$lt_cv_objdir
2066 _LT_DECL([], [objdir], [0],
2067 [The name of the directory that contains temporary libtool files])dnl
2068 m4_pattern_allow([LT_OBJDIR])dnl
2069 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2070 [Define to the sub-directory in which libtool stores uninstalled libraries.])
2071 ])# _LT_CHECK_OBJDIR
2072
2073
2074 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2075 # --------------------------------------
2076 # Check hardcoding attributes.
2077 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2078 [AC_MSG_CHECKING([how to hardcode library paths into programs])
2079 _LT_TAGVAR(hardcode_action, $1)=
2080 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2081 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2082 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2083
2084 # We can hardcode non-existent directories.
2085 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2086 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2087 # have to relink, otherwise we might link with an installed library
2088 # when we should be linking with a yet-to-be-installed one
2089 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2090 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2091 # Linking always hardcodes the temporary library directory.
2092 _LT_TAGVAR(hardcode_action, $1)=relink
2093 else
2094 # We can link without hardcoding, and we can hardcode nonexisting dirs.
2095 _LT_TAGVAR(hardcode_action, $1)=immediate
2096 fi
2097 else
2098 # We cannot hardcode anything, or else we can only hardcode existing
2099 # directories.
2100 _LT_TAGVAR(hardcode_action, $1)=unsupported
2101 fi
2102 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2103
2104 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2105 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2106 # Fast installation is not supported
2107 enable_fast_install=no
2108 elif test "$shlibpath_overrides_runpath" = yes ||
2109 test "$enable_shared" = no; then
2110 # Fast installation is not necessary
2111 enable_fast_install=needless
2112 fi
2113 _LT_TAGDECL([], [hardcode_action], [0],
2114 [How to hardcode a shared library path into an executable])
2115 ])# _LT_LINKER_HARDCODE_LIBPATH
2116
2117
2118 # _LT_CMD_STRIPLIB
2119 # ----------------
2120 m4_defun([_LT_CMD_STRIPLIB],
2121 [m4_require([_LT_DECL_EGREP])
2122 striplib=
2123 old_striplib=
2124 AC_MSG_CHECKING([whether stripping libraries is possible])
2125 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2126 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2127 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2128 AC_MSG_RESULT([yes])
2129 else
2130 # FIXME - insert some real tests, host_os isn't really good enough
2131 case $host_os in
2132 darwin*)
2133 if test -n "$STRIP" ; then
2134 striplib="$STRIP -x"
2135 old_striplib="$STRIP -S"
2136 AC_MSG_RESULT([yes])
2137 else
2138 AC_MSG_RESULT([no])
2139 fi
2140 ;;
2141 *)
2142 AC_MSG_RESULT([no])
2143 ;;
2144 esac
2145 fi
2146 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2147 _LT_DECL([], [striplib], [1])
2148 ])# _LT_CMD_STRIPLIB
2149
2150
2151 # _LT_SYS_DYNAMIC_LINKER([TAG])
2152 # -----------------------------
2153 # PORTME Fill in your ld.so characteristics
2154 m4_defun([_LT_SYS_DYNAMIC_LINKER],
2155 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2156 m4_require([_LT_DECL_EGREP])dnl
2157 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2158 m4_require([_LT_DECL_OBJDUMP])dnl
2159 m4_require([_LT_DECL_SED])dnl
2160 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2161 AC_MSG_CHECKING([dynamic linker characteristics])
2162 m4_if([$1],
2163 [], [
2164 if test "$GCC" = yes; then
2165 case $host_os in
2166 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2167 *) lt_awk_arg="/^libraries:/" ;;
2168 esac
2169 case $host_os in
2170 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
2171 *) lt_sed_strip_eq="s,=/,/,g" ;;
2172 esac
2173 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
2174 case $lt_search_path_spec in
2175 *\;*)
2176 # if the path contains ";" then we assume it to be the separator
2177 # otherwise default to the standard path separator (i.e. ":") - it is
2178 # assumed that no part of a normal pathname contains ";" but that should
2179 # okay in the real world where ";" in dirpaths is itself problematic.
2180 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
2181 ;;
2182 *)
2183 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
2184 ;;
2185 esac
2186 # Ok, now we have the path, separated by spaces, we can step through it
2187 # and add multilib dir if necessary.
2188 lt_tmp_lt_search_path_spec=
2189 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2190 for lt_sys_path in $lt_search_path_spec; do
2191 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2192 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2193 else
2194 test -d "$lt_sys_path" && \
2195 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2196 fi
2197 done
2198 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2199 BEGIN {RS=" "; FS="/|\n";} {
2200 lt_foo="";
2201 lt_count=0;
2202 for (lt_i = NF; lt_i > 0; lt_i--) {
2203 if ($lt_i != "" && $lt_i != ".") {
2204 if ($lt_i == "..") {
2205 lt_count++;
2206 } else {
2207 if (lt_count == 0) {
2208 lt_foo="/" $lt_i lt_foo;
2209 } else {
2210 lt_count--;
2211 }
2212 }
2213 }
2214 }
2215 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2216 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2217 }'`
2218 # AWK program above erroneously prepends '/' to C:/dos/paths
2219 # for these hosts.
2220 case $host_os in
2221 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
2222 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
2223 esac
2224 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
2225 else
2226 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2227 fi])
2228 library_names_spec=
2229 libname_spec='lib$name'
2230 soname_spec=
2231 shrext_cmds=".so"
2232 postinstall_cmds=
2233 postuninstall_cmds=
2234 finish_cmds=
2235 finish_eval=
2236 shlibpath_var=
2237 shlibpath_overrides_runpath=unknown
2238 version_type=none
2239 dynamic_linker="$host_os ld.so"
2240 sys_lib_dlsearch_path_spec="/lib /usr/lib"
2241 need_lib_prefix=unknown
2242 hardcode_into_libs=no
2243
2244 # when you set need_version to no, make sure it does not cause -set_version
2245 # flags to be left without arguments
2246 need_version=unknown
2247
2248 case $host_os in
2249 aix3*)
2250 version_type=linux # correct to gnu/linux during the next big refactor
2251 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2252 shlibpath_var=LIBPATH
2253
2254 # AIX 3 has no versioning support, so we append a major version to the name.
2255 soname_spec='${libname}${release}${shared_ext}$major'
2256 ;;
2257
2258 aix[[4-9]]*)
2259 version_type=linux # correct to gnu/linux during the next big refactor
2260 need_lib_prefix=no
2261 need_version=no
2262 hardcode_into_libs=yes
2263 if test "$host_cpu" = ia64; then
2264 # AIX 5 supports IA64
2265 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2266 shlibpath_var=LD_LIBRARY_PATH
2267 else
2268 # With GCC up to 2.95.x, collect2 would create an import file
2269 # for dependence libraries. The import file would start with
2270 # the line `#! .'. This would cause the generated library to
2271 # depend on `.', always an invalid library. This was fixed in
2272 # development snapshots of GCC prior to 3.0.
2273 case $host_os in
2274 aix4 | aix4.[[01]] | aix4.[[01]].*)
2275 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2276 echo ' yes '
2277 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2278 :
2279 else
2280 can_build_shared=no
2281 fi
2282 ;;
2283 esac
2284 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2285 # soname into executable. Probably we can add versioning support to
2286 # collect2, so additional links can be useful in future.
2287 if test "$aix_use_runtimelinking" = yes; then
2288 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2289 # instead of lib<name>.a to let people know that these are not
2290 # typical AIX shared libraries.
2291 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2292 else
2293 # We preserve .a as extension for shared libraries through AIX4.2
2294 # and later when we are not doing run time linking.
2295 library_names_spec='${libname}${release}.a $libname.a'
2296 soname_spec='${libname}${release}${shared_ext}$major'
2297 fi
2298 shlibpath_var=LIBPATH
2299 fi
2300 ;;
2301
2302 amigaos*)
2303 case $host_cpu in
2304 powerpc)
2305 # Since July 2007 AmigaOS4 officially supports .so libraries.
2306 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2307 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2308 ;;
2309 m68k)
2310 library_names_spec='$libname.ixlibrary $libname.a'
2311 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2312 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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'
2313 ;;
2314 esac
2315 ;;
2316
2317 beos*)
2318 library_names_spec='${libname}${shared_ext}'
2319 dynamic_linker="$host_os ld.so"
2320 shlibpath_var=LIBRARY_PATH
2321 ;;
2322
2323 bsdi[[45]]*)
2324 version_type=linux # correct to gnu/linux during the next big refactor
2325 need_version=no
2326 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2327 soname_spec='${libname}${release}${shared_ext}$major'
2328 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2329 shlibpath_var=LD_LIBRARY_PATH
2330 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2331 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2332 # the default ld.so.conf also contains /usr/contrib/lib and
2333 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2334 # libtool to hard-code these into programs
2335 ;;
2336
2337 cygwin* | mingw* | pw32* | cegcc*)
2338 version_type=windows
2339 shrext_cmds=".dll"
2340 need_version=no
2341 need_lib_prefix=no
2342
2343 case $GCC,$cc_basename in
2344 yes,*)
2345 # gcc
2346 library_names_spec='$libname.dll.a'
2347 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2348 postinstall_cmds='base_file=`basename \${file}`~
2349 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2350 dldir=$destdir/`dirname \$dlpath`~
2351 test -d \$dldir || mkdir -p \$dldir~
2352 $install_prog $dir/$dlname \$dldir/$dlname~
2353 chmod a+x \$dldir/$dlname~
2354 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2355 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2356 fi'
2357 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2358 dlpath=$dir/\$dldll~
2359 $RM \$dlpath'
2360 shlibpath_overrides_runpath=yes
2361
2362 case $host_os in
2363 cygwin*)
2364 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2365 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2366 m4_if([$1], [],[
2367 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
2368 ;;
2369 mingw* | cegcc*)
2370 # MinGW DLLs use traditional 'lib' prefix
2371 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2372 ;;
2373 pw32*)
2374 # pw32 DLLs use 'pw' prefix rather than 'lib'
2375 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2376 ;;
2377 esac
2378 dynamic_linker='Win32 ld.exe'
2379 ;;
2380
2381 *,cl*)
2382 # Native MSVC
2383 libname_spec='$name'
2384 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2385 library_names_spec='${libname}.dll.lib'
2386
2387 case $build_os in
2388 mingw*)
2389 sys_lib_search_path_spec=
2390 lt_save_ifs=$IFS
2391 IFS=';'
2392 for lt_path in $LIB
2393 do
2394 IFS=$lt_save_ifs
2395 # Let DOS variable expansion print the short 8.3 style file name.
2396 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
2397 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
2398 done
2399 IFS=$lt_save_ifs
2400 # Convert to MSYS style.
2401 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
2402 ;;
2403 cygwin*)
2404 # Convert to unix form, then to dos form, then back to unix form
2405 # but this time dos style (no spaces!) so that the unix form looks
2406 # like /cygdrive/c/PROGRA~1:/cygdr...
2407 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
2408 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
2409 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2410 ;;
2411 *)
2412 sys_lib_search_path_spec="$LIB"
2413 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2414 # It is most probably a Windows format PATH.
2415 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2416 else
2417 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2418 fi
2419 # FIXME: find the short name or the path components, as spaces are
2420 # common. (e.g. "Program Files" -> "PROGRA~1")
2421 ;;
2422 esac
2423
2424 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2425 postinstall_cmds='base_file=`basename \${file}`~
2426 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2427 dldir=$destdir/`dirname \$dlpath`~
2428 test -d \$dldir || mkdir -p \$dldir~
2429 $install_prog $dir/$dlname \$dldir/$dlname'
2430 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2431 dlpath=$dir/\$dldll~
2432 $RM \$dlpath'
2433 shlibpath_overrides_runpath=yes
2434 dynamic_linker='Win32 link.exe'
2435 ;;
2436
2437 *)
2438 # Assume MSVC wrapper
2439 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2440 dynamic_linker='Win32 ld.exe'
2441 ;;
2442 esac
2443 # FIXME: first we should search . and the directory the executable is in
2444 shlibpath_var=PATH
2445 ;;
2446
2447 darwin* | rhapsody*)
2448 dynamic_linker="$host_os dyld"
2449 version_type=darwin
2450 need_lib_prefix=no
2451 need_version=no
2452 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2453 soname_spec='${libname}${release}${major}$shared_ext'
2454 shlibpath_overrides_runpath=yes
2455 shlibpath_var=DYLD_LIBRARY_PATH
2456 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2457 m4_if([$1], [],[
2458 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2459 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2460 ;;
2461
2462 dgux*)
2463 version_type=linux # correct to gnu/linux during the next big refactor
2464 need_lib_prefix=no
2465 need_version=no
2466 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2467 soname_spec='${libname}${release}${shared_ext}$major'
2468 shlibpath_var=LD_LIBRARY_PATH
2469 ;;
2470
2471 freebsd* | dragonfly*)
2472 # DragonFly does not have aout. When/if they implement a new
2473 # versioning mechanism, adjust this.
2474 if test -x /usr/bin/objformat; then
2475 objformat=`/usr/bin/objformat`
2476 else
2477 case $host_os in
2478 freebsd[[23]].*) objformat=aout ;;
2479 *) objformat=elf ;;
2480 esac
2481 fi
2482 version_type=freebsd-$objformat
2483 case $version_type in
2484 freebsd-elf*)
2485 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2486 need_version=no
2487 need_lib_prefix=no
2488 ;;
2489 freebsd-*)
2490 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2491 need_version=yes
2492 ;;
2493 esac
2494 shlibpath_var=LD_LIBRARY_PATH
2495 case $host_os in
2496 freebsd2.*)
2497 shlibpath_overrides_runpath=yes
2498 ;;
2499 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2500 shlibpath_overrides_runpath=yes
2501 hardcode_into_libs=yes
2502 ;;
2503 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2504 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2505 shlibpath_overrides_runpath=no
2506 hardcode_into_libs=yes
2507 ;;
2508 *) # from 4.6 on, and DragonFly
2509 shlibpath_overrides_runpath=yes
2510 hardcode_into_libs=yes
2511 ;;
2512 esac
2513 ;;
2514
2515 gnu*)
2516 version_type=linux # correct to gnu/linux during the next big refactor
2517 need_lib_prefix=no
2518 need_version=no
2519 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2520 soname_spec='${libname}${release}${shared_ext}$major'
2521 shlibpath_var=LD_LIBRARY_PATH
2522 shlibpath_overrides_runpath=no
2523 hardcode_into_libs=yes
2524 ;;
2525
2526 haiku*)
2527 version_type=linux # correct to gnu/linux during the next big refactor
2528 need_lib_prefix=no
2529 need_version=no
2530 dynamic_linker="$host_os runtime_loader"
2531 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2532 soname_spec='${libname}${release}${shared_ext}$major'
2533 shlibpath_var=LIBRARY_PATH
2534 shlibpath_overrides_runpath=yes
2535 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
2536 hardcode_into_libs=yes
2537 ;;
2538
2539 hpux9* | hpux10* | hpux11*)
2540 # Give a soname corresponding to the major version so that dld.sl refuses to
2541 # link against other versions.
2542 version_type=sunos
2543 need_lib_prefix=no
2544 need_version=no
2545 case $host_cpu in
2546 ia64*)
2547 shrext_cmds='.so'
2548 hardcode_into_libs=yes
2549 dynamic_linker="$host_os dld.so"
2550 shlibpath_var=LD_LIBRARY_PATH
2551 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2552 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2553 soname_spec='${libname}${release}${shared_ext}$major'
2554 if test "X$HPUX_IA64_MODE" = X32; then
2555 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2556 else
2557 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2558 fi
2559 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2560 ;;
2561 hppa*64*)
2562 shrext_cmds='.sl'
2563 hardcode_into_libs=yes
2564 dynamic_linker="$host_os dld.sl"
2565 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2566 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2567 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2568 soname_spec='${libname}${release}${shared_ext}$major'
2569 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2570 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2571 ;;
2572 *)
2573 shrext_cmds='.sl'
2574 dynamic_linker="$host_os dld.sl"
2575 shlibpath_var=SHLIB_PATH
2576 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2577 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2578 soname_spec='${libname}${release}${shared_ext}$major'
2579 ;;
2580 esac
2581 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
2582 postinstall_cmds='chmod 555 $lib'
2583 # or fails outright, so override atomically:
2584 install_override_mode=555
2585 ;;
2586
2587 interix[[3-9]]*)
2588 version_type=linux # correct to gnu/linux during the next big refactor
2589 need_lib_prefix=no
2590 need_version=no
2591 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2592 soname_spec='${libname}${release}${shared_ext}$major'
2593 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2594 shlibpath_var=LD_LIBRARY_PATH
2595 shlibpath_overrides_runpath=no
2596 hardcode_into_libs=yes
2597 ;;
2598
2599 irix5* | irix6* | nonstopux*)
2600 case $host_os in
2601 nonstopux*) version_type=nonstopux ;;
2602 *)
2603 if test "$lt_cv_prog_gnu_ld" = yes; then
2604 version_type=linux # correct to gnu/linux during the next big refactor
2605 else
2606 version_type=irix
2607 fi ;;
2608 esac
2609 need_lib_prefix=no
2610 need_version=no
2611 soname_spec='${libname}${release}${shared_ext}$major'
2612 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2613 case $host_os in
2614 irix5* | nonstopux*)
2615 libsuff= shlibsuff=
2616 ;;
2617 *)
2618 case $LD in # libtool.m4 will add one of these switches to LD
2619 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2620 libsuff= shlibsuff= libmagic=32-bit;;
2621 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2622 libsuff=32 shlibsuff=N32 libmagic=N32;;
2623 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2624 libsuff=64 shlibsuff=64 libmagic=64-bit;;
2625 *) libsuff= shlibsuff= libmagic=never-match;;
2626 esac
2627 ;;
2628 esac
2629 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2630 shlibpath_overrides_runpath=no
2631 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2632 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2633 hardcode_into_libs=yes
2634 ;;
2635
2636 # No shared lib support for Linux oldld, aout, or coff.
2637 linux*oldld* | linux*aout* | linux*coff*)
2638 dynamic_linker=no
2639 ;;
2640
2641 linux*android*)
2642 version_type=none # Android doesn't support versioned libraries.
2643 need_lib_prefix=no
2644 need_version=no
2645 library_names_spec='$libname$release$shared_ext'
2646 soname_spec='$libname$release$shared_ext'
2647 finish_cmds=
2648 shlibpath_var=LD_LIBRARY_PATH
2649 shlibpath_overrides_runpath=yes
2650
2651 # This implies no fast_install, which is unacceptable.
2652 # Some rework will be needed to allow for fast_install
2653 # before this can be enabled.
2654 hardcode_into_libs=yes
2655
2656 dynamic_linker='Android linker'
2657 # Don't embed -rpath directories since the linker doesn't support them.
2658 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
2659 ;;
2660
2661 # This must be glibc/ELF.
2662 linux* | k*bsd*-gnu | kopensolaris*-gnu)
2663 version_type=linux # correct to gnu/linux during the next big refactor
2664 need_lib_prefix=no
2665 need_version=no
2666 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2667 soname_spec='${libname}${release}${shared_ext}$major'
2668 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2669 shlibpath_var=LD_LIBRARY_PATH
2670 shlibpath_overrides_runpath=no
2671
2672 # Some binutils ld are patched to set DT_RUNPATH
2673 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
2674 [lt_cv_shlibpath_overrides_runpath=no
2675 save_LDFLAGS=$LDFLAGS
2676 save_libdir=$libdir
2677 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
2678 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
2679 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2680 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
2681 [lt_cv_shlibpath_overrides_runpath=yes])])
2682 LDFLAGS=$save_LDFLAGS
2683 libdir=$save_libdir
2684 ])
2685 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
2686
2687 # This implies no fast_install, which is unacceptable.
2688 # Some rework will be needed to allow for fast_install
2689 # before this can be enabled.
2690 hardcode_into_libs=yes
2691
2692 # Append ld.so.conf contents to the search path
2693 if test -f /etc/ld.so.conf; then
2694 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;s/"//g;/^$/d' | tr '\n' ' '`
2695 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2696 fi
2697
2698 # We used to test for /lib/ld.so.1 and disable shared libraries on
2699 # powerpc, because MkLinux only supported shared libraries with the
2700 # GNU dynamic linker. Since this was broken with cross compilers,
2701 # most powerpc-linux boxes support dynamic linking these days and
2702 # people can always --disable-shared, the test was removed, and we
2703 # assume the GNU/Linux dynamic linker is in use.
2704 dynamic_linker='GNU/Linux ld.so'
2705 ;;
2706
2707 netbsdelf*-gnu)
2708 version_type=linux
2709 need_lib_prefix=no
2710 need_version=no
2711 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2712 soname_spec='${libname}${release}${shared_ext}$major'
2713 shlibpath_var=LD_LIBRARY_PATH
2714 shlibpath_overrides_runpath=no
2715 hardcode_into_libs=yes
2716 dynamic_linker='NetBSD ld.elf_so'
2717 ;;
2718
2719 netbsd*)
2720 version_type=sunos
2721 need_lib_prefix=no
2722 need_version=no
2723 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2724 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2725 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2726 dynamic_linker='NetBSD (a.out) ld.so'
2727 else
2728 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2729 soname_spec='${libname}${release}${shared_ext}$major'
2730 dynamic_linker='NetBSD ld.elf_so'
2731 fi
2732 shlibpath_var=LD_LIBRARY_PATH
2733 shlibpath_overrides_runpath=yes
2734 hardcode_into_libs=yes
2735 ;;
2736
2737 newsos6)
2738 version_type=linux # correct to gnu/linux during the next big refactor
2739 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2740 shlibpath_var=LD_LIBRARY_PATH
2741 shlibpath_overrides_runpath=yes
2742 ;;
2743
2744 *nto* | *qnx*)
2745 version_type=qnx
2746 need_lib_prefix=no
2747 need_version=no
2748 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2749 soname_spec='${libname}${release}${shared_ext}$major'
2750 shlibpath_var=LD_LIBRARY_PATH
2751 shlibpath_overrides_runpath=no
2752 hardcode_into_libs=yes
2753 dynamic_linker='ldqnx.so'
2754 ;;
2755
2756 openbsd*)
2757 version_type=sunos
2758 sys_lib_dlsearch_path_spec="/usr/lib"
2759 need_lib_prefix=no
2760 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2761 case $host_os in
2762 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2763 *) need_version=no ;;
2764 esac
2765 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2766 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2767 shlibpath_var=LD_LIBRARY_PATH
2768 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2769 case $host_os in
2770 openbsd2.[[89]] | openbsd2.[[89]].*)
2771 shlibpath_overrides_runpath=no
2772 ;;
2773 *)
2774 shlibpath_overrides_runpath=yes
2775 ;;
2776 esac
2777 else
2778 shlibpath_overrides_runpath=yes
2779 fi
2780 ;;
2781
2782 os2*)
2783 libname_spec='$name'
2784 shrext_cmds=".dll"
2785 need_lib_prefix=no
2786 library_names_spec='$libname${shared_ext} $libname.a'
2787 dynamic_linker='OS/2 ld.exe'
2788 shlibpath_var=LIBPATH
2789 ;;
2790
2791 osf3* | osf4* | osf5*)
2792 version_type=osf
2793 need_lib_prefix=no
2794 need_version=no
2795 soname_spec='${libname}${release}${shared_ext}$major'
2796 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2797 shlibpath_var=LD_LIBRARY_PATH
2798 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2799 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2800 ;;
2801
2802 rdos*)
2803 dynamic_linker=no
2804 ;;
2805
2806 solaris*)
2807 version_type=linux # correct to gnu/linux during the next big refactor
2808 need_lib_prefix=no
2809 need_version=no
2810 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2811 soname_spec='${libname}${release}${shared_ext}$major'
2812 shlibpath_var=LD_LIBRARY_PATH
2813 shlibpath_overrides_runpath=yes
2814 hardcode_into_libs=yes
2815 # ldd complains unless libraries are executable
2816 postinstall_cmds='chmod +x $lib'
2817 ;;
2818
2819 sunos4*)
2820 version_type=sunos
2821 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2822 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2823 shlibpath_var=LD_LIBRARY_PATH
2824 shlibpath_overrides_runpath=yes
2825 if test "$with_gnu_ld" = yes; then
2826 need_lib_prefix=no
2827 fi
2828 need_version=yes
2829 ;;
2830
2831 sysv4 | sysv4.3*)
2832 version_type=linux # correct to gnu/linux during the next big refactor
2833 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2834 soname_spec='${libname}${release}${shared_ext}$major'
2835 shlibpath_var=LD_LIBRARY_PATH
2836 case $host_vendor in
2837 sni)
2838 shlibpath_overrides_runpath=no
2839 need_lib_prefix=no
2840 runpath_var=LD_RUN_PATH
2841 ;;
2842 siemens)
2843 need_lib_prefix=no
2844 ;;
2845 motorola)
2846 need_lib_prefix=no
2847 need_version=no
2848 shlibpath_overrides_runpath=no
2849 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2850 ;;
2851 esac
2852 ;;
2853
2854 sysv4*MP*)
2855 if test -d /usr/nec ;then
2856 version_type=linux # correct to gnu/linux during the next big refactor
2857 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2858 soname_spec='$libname${shared_ext}.$major'
2859 shlibpath_var=LD_LIBRARY_PATH
2860 fi
2861 ;;
2862
2863 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2864 version_type=freebsd-elf
2865 need_lib_prefix=no
2866 need_version=no
2867 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2868 soname_spec='${libname}${release}${shared_ext}$major'
2869 shlibpath_var=LD_LIBRARY_PATH
2870 shlibpath_overrides_runpath=yes
2871 hardcode_into_libs=yes
2872 if test "$with_gnu_ld" = yes; then
2873 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2874 else
2875 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2876 case $host_os in
2877 sco3.2v5*)
2878 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2879 ;;
2880 esac
2881 fi
2882 sys_lib_dlsearch_path_spec='/usr/lib'
2883 ;;
2884
2885 tpf*)
2886 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
2887 version_type=linux # correct to gnu/linux during the next big refactor
2888 need_lib_prefix=no
2889 need_version=no
2890 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2891 shlibpath_var=LD_LIBRARY_PATH
2892 shlibpath_overrides_runpath=no
2893 hardcode_into_libs=yes
2894 ;;
2895
2896 uts4*)
2897 version_type=linux # correct to gnu/linux during the next big refactor
2898 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2899 soname_spec='${libname}${release}${shared_ext}$major'
2900 shlibpath_var=LD_LIBRARY_PATH
2901 ;;
2902
2903 *)
2904 dynamic_linker=no
2905 ;;
2906 esac
2907 AC_MSG_RESULT([$dynamic_linker])
2908 test "$dynamic_linker" = no && can_build_shared=no
2909
2910 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2911 if test "$GCC" = yes; then
2912 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2913 fi
2914
2915 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
2916 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
2917 fi
2918 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
2919 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
2920 fi
2921
2922 _LT_DECL([], [variables_saved_for_relink], [1],
2923 [Variables whose values should be saved in libtool wrapper scripts and
2924 restored at link time])
2925 _LT_DECL([], [need_lib_prefix], [0],
2926 [Do we need the "lib" prefix for modules?])
2927 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
2928 _LT_DECL([], [version_type], [0], [Library versioning type])
2929 _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
2930 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
2931 _LT_DECL([], [shlibpath_overrides_runpath], [0],
2932 [Is shlibpath searched before the hard-coded library search path?])
2933 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
2934 _LT_DECL([], [library_names_spec], [1],
2935 [[List of archive names. First name is the real one, the rest are links.
2936 The last name is the one that the linker finds with -lNAME]])
2937 _LT_DECL([], [soname_spec], [1],
2938 [[The coded name of the library, if different from the real name]])
2939 _LT_DECL([], [install_override_mode], [1],
2940 [Permission mode override for installation of shared libraries])
2941 _LT_DECL([], [postinstall_cmds], [2],
2942 [Command to use after installation of a shared archive])
2943 _LT_DECL([], [postuninstall_cmds], [2],
2944 [Command to use after uninstallation of a shared archive])
2945 _LT_DECL([], [finish_cmds], [2],
2946 [Commands used to finish a libtool library installation in a directory])
2947 _LT_DECL([], [finish_eval], [1],
2948 [[As "finish_cmds", except a single script fragment to be evaled but
2949 not shown]])
2950 _LT_DECL([], [hardcode_into_libs], [0],
2951 [Whether we should hardcode library paths into libraries])
2952 _LT_DECL([], [sys_lib_search_path_spec], [2],
2953 [Compile-time system search path for libraries])
2954 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
2955 [Run-time system search path for libraries])
2956 ])# _LT_SYS_DYNAMIC_LINKER
2957
2958
2959 # _LT_PATH_TOOL_PREFIX(TOOL)
2960 # --------------------------
2961 # find a file program which can recognize shared library
2962 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
2963 [m4_require([_LT_DECL_EGREP])dnl
2964 AC_MSG_CHECKING([for $1])
2965 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2966 [case $MAGIC_CMD in
2967 [[\\/*] | ?:[\\/]*])
2968 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2969 ;;
2970 *)
2971 lt_save_MAGIC_CMD="$MAGIC_CMD"
2972 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2973 dnl $ac_dummy forces splitting on constant user-supplied paths.
2974 dnl POSIX.2 word splitting is done only on the output of word expansions,
2975 dnl not every word. This closes a longstanding sh security hole.
2976 ac_dummy="m4_if([$2], , $PATH, [$2])"
2977 for ac_dir in $ac_dummy; do
2978 IFS="$lt_save_ifs"
2979 test -z "$ac_dir" && ac_dir=.
2980 if test -f $ac_dir/$1; then
2981 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2982 if test -n "$file_magic_test_file"; then
2983 case $deplibs_check_method in
2984 "file_magic "*)
2985 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
2986 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2987 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2988 $EGREP "$file_magic_regex" > /dev/null; then
2989 :
2990 else
2991 cat <<_LT_EOF 1>&2
2992
2993 *** Warning: the command libtool uses to detect shared libraries,
2994 *** $file_magic_cmd, produces output that libtool cannot recognize.
2995 *** The result is that libtool may fail to recognize shared libraries
2996 *** as such. This will affect the creation of libtool libraries that
2997 *** depend on shared libraries, but programs linked with such libtool
2998 *** libraries will work regardless of this problem. Nevertheless, you
2999 *** may want to report the problem to your system manager and/or to
3000 *** bug-libtool@gnu.org
3001
3002 _LT_EOF
3003 fi ;;
3004 esac
3005 fi
3006 break
3007 fi
3008 done
3009 IFS="$lt_save_ifs"
3010 MAGIC_CMD="$lt_save_MAGIC_CMD"
3011 ;;
3012 esac])
3013 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3014 if test -n "$MAGIC_CMD"; then
3015 AC_MSG_RESULT($MAGIC_CMD)
3016 else
3017 AC_MSG_RESULT(no)
3018 fi
3019 _LT_DECL([], [MAGIC_CMD], [0],
3020 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3021 ])# _LT_PATH_TOOL_PREFIX
3022
3023 # Old name:
3024 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3025 dnl aclocal-1.4 backwards compatibility:
3026 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3027
3028
3029 # _LT_PATH_MAGIC
3030 # --------------
3031 # find a file program which can recognize a shared library
3032 m4_defun([_LT_PATH_MAGIC],
3033 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3034 if test -z "$lt_cv_path_MAGIC_CMD"; then
3035 if test -n "$ac_tool_prefix"; then
3036 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3037 else
3038 MAGIC_CMD=:
3039 fi
3040 fi
3041 ])# _LT_PATH_MAGIC
3042
3043
3044 # LT_PATH_LD
3045 # ----------
3046 # find the pathname to the GNU or non-GNU linker
3047 AC_DEFUN([LT_PATH_LD],
3048 [AC_REQUIRE([AC_PROG_CC])dnl
3049 AC_REQUIRE([AC_CANONICAL_HOST])dnl
3050 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3051 m4_require([_LT_DECL_SED])dnl
3052 m4_require([_LT_DECL_EGREP])dnl
3053 m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
3054
3055 AC_ARG_WITH([gnu-ld],
3056 [AS_HELP_STRING([--with-gnu-ld],
3057 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3058 [test "$withval" = no || with_gnu_ld=yes],
3059 [with_gnu_ld=no])dnl
3060
3061 ac_prog=ld
3062 if test "$GCC" = yes; then
3063 # Check if gcc -print-prog-name=ld gives a path.
3064 AC_MSG_CHECKING([for ld used by $CC])
3065 case $host in
3066 *-*-mingw*)
3067 # gcc leaves a trailing carriage return which upsets mingw
3068 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3069 *)
3070 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3071 esac
3072 case $ac_prog in
3073 # Accept absolute paths.
3074 [[\\/]]* | ?:[[\\/]]*)
3075 re_direlt='/[[^/]][[^/]]*/\.\./'
3076 # Canonicalize the pathname of ld
3077 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3078 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3079 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3080 done
3081 test -z "$LD" && LD="$ac_prog"
3082 ;;
3083 "")
3084 # If it fails, then pretend we aren't using GCC.
3085 ac_prog=ld
3086 ;;
3087 *)
3088 # If it is relative, then search for the first ld in PATH.
3089 with_gnu_ld=unknown
3090 ;;
3091 esac
3092 elif test "$with_gnu_ld" = yes; then
3093 AC_MSG_CHECKING([for GNU ld])
3094 else
3095 AC_MSG_CHECKING([for non-GNU ld])
3096 fi
3097 AC_CACHE_VAL(lt_cv_path_LD,
3098 [if test -z "$LD"; then
3099 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3100 for ac_dir in $PATH; do
3101 IFS="$lt_save_ifs"
3102 test -z "$ac_dir" && ac_dir=.
3103 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3104 lt_cv_path_LD="$ac_dir/$ac_prog"
3105 # Check to see if the program is GNU ld. I'd rather use --version,
3106 # but apparently some variants of GNU ld only accept -v.
3107 # Break only if it was the GNU/non-GNU ld that we prefer.
3108 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3109 *GNU* | *'with BFD'*)
3110 test "$with_gnu_ld" != no && break
3111 ;;
3112 *)
3113 test "$with_gnu_ld" != yes && break
3114 ;;
3115 esac
3116 fi
3117 done
3118 IFS="$lt_save_ifs"
3119 else
3120 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3121 fi])
3122 LD="$lt_cv_path_LD"
3123 if test -n "$LD"; then
3124 AC_MSG_RESULT($LD)
3125 else
3126 AC_MSG_RESULT(no)
3127 fi
3128 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3129 _LT_PATH_LD_GNU
3130 AC_SUBST([LD])
3131
3132 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3133 ])# LT_PATH_LD
3134
3135 # Old names:
3136 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3137 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3138 dnl aclocal-1.4 backwards compatibility:
3139 dnl AC_DEFUN([AM_PROG_LD], [])
3140 dnl AC_DEFUN([AC_PROG_LD], [])
3141
3142
3143 # _LT_PATH_LD_GNU
3144 #- --------------
3145 m4_defun([_LT_PATH_LD_GNU],
3146 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3147 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
3148 case `$LD -v 2>&1 </dev/null` in
3149 *GNU* | *'with BFD'*)
3150 lt_cv_prog_gnu_ld=yes
3151 ;;
3152 *)
3153 lt_cv_prog_gnu_ld=no
3154 ;;
3155 esac])
3156 with_gnu_ld=$lt_cv_prog_gnu_ld
3157 ])# _LT_PATH_LD_GNU
3158
3159
3160 # _LT_CMD_RELOAD
3161 # --------------
3162 # find reload flag for linker
3163 # -- PORTME Some linkers may need a different reload flag.
3164 m4_defun([_LT_CMD_RELOAD],
3165 [AC_CACHE_CHECK([for $LD option to reload object files],
3166 lt_cv_ld_reload_flag,
3167 [lt_cv_ld_reload_flag='-r'])
3168 reload_flag=$lt_cv_ld_reload_flag
3169 case $reload_flag in
3170 "" | " "*) ;;
3171 *) reload_flag=" $reload_flag" ;;
3172 esac
3173 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3174 case $host_os in
3175 cygwin* | mingw* | pw32* | cegcc*)
3176 if test "$GCC" != yes; then
3177 reload_cmds=false
3178 fi
3179 ;;
3180 darwin*)
3181 if test "$GCC" = yes; then
3182 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3183 else
3184 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3185 fi
3186 ;;
3187 esac
3188 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3189 _LT_TAGDECL([], [reload_cmds], [2])dnl
3190 ])# _LT_CMD_RELOAD
3191
3192
3193 # _LT_CHECK_MAGIC_METHOD
3194 # ----------------------
3195 # how to check for library dependencies
3196 # -- PORTME fill in with the dynamic library characteristics
3197 m4_defun([_LT_CHECK_MAGIC_METHOD],
3198 [m4_require([_LT_DECL_EGREP])
3199 m4_require([_LT_DECL_OBJDUMP])
3200 AC_CACHE_CHECK([how to recognize dependent libraries],
3201 lt_cv_deplibs_check_method,
3202 [lt_cv_file_magic_cmd='$MAGIC_CMD'
3203 lt_cv_file_magic_test_file=
3204 lt_cv_deplibs_check_method='unknown'
3205 # Need to set the preceding variable on all platforms that support
3206 # interlibrary dependencies.
3207 # 'none' -- dependencies not supported.
3208 # `unknown' -- same as none, but documents that we really don't know.
3209 # 'pass_all' -- all dependencies passed with no checks.
3210 # 'test_compile' -- check by making test program.
3211 # 'file_magic [[regex]]' -- check by looking for files in library path
3212 # which responds to the $file_magic_cmd with a given extended regex.
3213 # If you have `file' or equivalent on your system and you're not sure
3214 # whether `pass_all' will *always* work, you probably want this one.
3215
3216 case $host_os in
3217 aix[[4-9]]*)
3218 lt_cv_deplibs_check_method=pass_all
3219 ;;
3220
3221 beos*)
3222 lt_cv_deplibs_check_method=pass_all
3223 ;;
3224
3225 bsdi[[45]]*)
3226 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3227 lt_cv_file_magic_cmd='/usr/bin/file -L'
3228 lt_cv_file_magic_test_file=/shlib/libc.so
3229 ;;
3230
3231 cygwin*)
3232 # func_win32_libid is a shell function defined in ltmain.sh
3233 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3234 lt_cv_file_magic_cmd='func_win32_libid'
3235 ;;
3236
3237 mingw* | pw32*)
3238 # Base MSYS/MinGW do not provide the 'file' command needed by
3239 # func_win32_libid shell function, so use a weaker test based on 'objdump',
3240 # unless we find 'file', for example because we are cross-compiling.
3241 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
3242 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
3243 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3244 lt_cv_file_magic_cmd='func_win32_libid'
3245 else
3246 # Keep this pattern in sync with the one in func_win32_libid.
3247 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
3248 lt_cv_file_magic_cmd='$OBJDUMP -f'
3249 fi
3250 ;;
3251
3252 cegcc*)
3253 # use the weaker test based on 'objdump'. See mingw*.
3254 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3255 lt_cv_file_magic_cmd='$OBJDUMP -f'
3256 ;;
3257
3258 darwin* | rhapsody*)
3259 lt_cv_deplibs_check_method=pass_all
3260 ;;
3261
3262 freebsd* | dragonfly*)
3263 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3264 case $host_cpu in
3265 i*86 )
3266 # Not sure whether the presence of OpenBSD here was a mistake.
3267 # Let's accept both of them until this is cleared up.
3268 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3269 lt_cv_file_magic_cmd=/usr/bin/file
3270 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3271 ;;
3272 esac
3273 else
3274 lt_cv_deplibs_check_method=pass_all
3275 fi
3276 ;;
3277
3278 gnu*)
3279 lt_cv_deplibs_check_method=pass_all
3280 ;;
3281
3282 haiku*)
3283 lt_cv_deplibs_check_method=pass_all
3284 ;;
3285
3286 hpux10.20* | hpux11*)
3287 lt_cv_file_magic_cmd=/usr/bin/file
3288 case $host_cpu in
3289 ia64*)
3290 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3291 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3292 ;;
3293 hppa*64*)
3294 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
3295 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3296 ;;
3297 *)
3298 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
3299 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3300 ;;
3301 esac
3302 ;;
3303
3304 interix[[3-9]]*)
3305 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3306 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3307 ;;
3308
3309 irix5* | irix6* | nonstopux*)
3310 case $LD in
3311 *-32|*"-32 ") libmagic=32-bit;;
3312 *-n32|*"-n32 ") libmagic=N32;;
3313 *-64|*"-64 ") libmagic=64-bit;;
3314 *) libmagic=never-match;;
3315 esac
3316 lt_cv_deplibs_check_method=pass_all
3317 ;;
3318
3319 # This must be glibc/ELF.
3320 linux* | k*bsd*-gnu | kopensolaris*-gnu)
3321 lt_cv_deplibs_check_method=pass_all
3322 ;;
3323
3324 netbsd* | netbsdelf*-gnu)
3325 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3326 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3327 else
3328 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3329 fi
3330 ;;
3331
3332 newos6*)
3333 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3334 lt_cv_file_magic_cmd=/usr/bin/file
3335 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3336 ;;
3337
3338 *nto* | *qnx*)
3339 lt_cv_deplibs_check_method=pass_all
3340 ;;
3341
3342 openbsd*)
3343 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3344 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3345 else
3346 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3347 fi
3348 ;;
3349
3350 osf3* | osf4* | osf5*)
3351 lt_cv_deplibs_check_method=pass_all
3352 ;;
3353
3354 rdos*)
3355 lt_cv_deplibs_check_method=pass_all
3356 ;;
3357
3358 solaris*)
3359 lt_cv_deplibs_check_method=pass_all
3360 ;;
3361
3362 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3363 lt_cv_deplibs_check_method=pass_all
3364 ;;
3365
3366 sysv4 | sysv4.3*)
3367 case $host_vendor in
3368 motorola)
3369 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]]'
3370 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3371 ;;
3372 ncr)
3373 lt_cv_deplibs_check_method=pass_all
3374 ;;
3375 sequent)
3376 lt_cv_file_magic_cmd='/bin/file'
3377 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3378 ;;
3379 sni)
3380 lt_cv_file_magic_cmd='/bin/file'
3381 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3382 lt_cv_file_magic_test_file=/lib/libc.so
3383 ;;
3384 siemens)
3385 lt_cv_deplibs_check_method=pass_all
3386 ;;
3387 pc)
3388 lt_cv_deplibs_check_method=pass_all
3389 ;;
3390 esac
3391 ;;
3392
3393 tpf*)
3394 lt_cv_deplibs_check_method=pass_all
3395 ;;
3396 esac
3397 ])
3398
3399 file_magic_glob=
3400 want_nocaseglob=no
3401 if test "$build" = "$host"; then
3402 case $host_os in
3403 mingw* | pw32*)
3404 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
3405 want_nocaseglob=yes
3406 else
3407 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
3408 fi
3409 ;;
3410 esac
3411 fi
3412
3413 file_magic_cmd=$lt_cv_file_magic_cmd
3414 deplibs_check_method=$lt_cv_deplibs_check_method
3415 test -z "$deplibs_check_method" && deplibs_check_method=unknown
3416
3417 _LT_DECL([], [deplibs_check_method], [1],
3418 [Method to check whether dependent libraries are shared objects])
3419 _LT_DECL([], [file_magic_cmd], [1],
3420 [Command to use when deplibs_check_method = "file_magic"])
3421 _LT_DECL([], [file_magic_glob], [1],
3422 [How to find potential files when deplibs_check_method = "file_magic"])
3423 _LT_DECL([], [want_nocaseglob], [1],
3424 [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
3425 ])# _LT_CHECK_MAGIC_METHOD
3426
3427
3428 # LT_PATH_NM
3429 # ----------
3430 # find the pathname to a BSD- or MS-compatible name lister
3431 AC_DEFUN([LT_PATH_NM],
3432 [AC_REQUIRE([AC_PROG_CC])dnl
3433 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
3434 [if test -n "$NM"; then
3435 # Let the user override the test.
3436 lt_cv_path_NM="$NM"
3437 else
3438 lt_nm_to_check="${ac_tool_prefix}nm"
3439 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3440 lt_nm_to_check="$lt_nm_to_check nm"
3441 fi
3442 for lt_tmp_nm in $lt_nm_to_check; do
3443 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3444 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3445 IFS="$lt_save_ifs"
3446 test -z "$ac_dir" && ac_dir=.
3447 tmp_nm="$ac_dir/$lt_tmp_nm"
3448 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3449 # Check to see if the nm accepts a BSD-compat flag.
3450 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3451 # nm: unknown option "B" ignored
3452 # Tru64's nm complains that /dev/null is an invalid object file
3453 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3454 */dev/null* | *'Invalid file or object type'*)
3455 lt_cv_path_NM="$tmp_nm -B"
3456 break
3457 ;;
3458 *)
3459 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3460 */dev/null*)
3461 lt_cv_path_NM="$tmp_nm -p"
3462 break
3463 ;;
3464 *)
3465 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3466 continue # so that we can try to find one that supports BSD flags
3467 ;;
3468 esac
3469 ;;
3470 esac
3471 fi
3472 done
3473 IFS="$lt_save_ifs"
3474 done
3475 : ${lt_cv_path_NM=no}
3476 fi])
3477 if test "$lt_cv_path_NM" != "no"; then
3478 NM="$lt_cv_path_NM"
3479 else
3480 # Didn't find any BSD compatible name lister, look for dumpbin.
3481 if test -n "$DUMPBIN"; then :
3482 # Let the user override the test.
3483 else
3484 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
3485 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
3486 *COFF*)
3487 DUMPBIN="$DUMPBIN -symbols"
3488 ;;
3489 *)
3490 DUMPBIN=:
3491 ;;
3492 esac
3493 fi
3494 AC_SUBST([DUMPBIN])
3495 if test "$DUMPBIN" != ":"; then
3496 NM="$DUMPBIN"
3497 fi
3498 fi
3499 test -z "$NM" && NM=nm
3500 AC_SUBST([NM])
3501 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
3502
3503 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3504 [lt_cv_nm_interface="BSD nm"
3505 echo "int some_variable = 0;" > conftest.$ac_ext
3506 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3507 (eval "$ac_compile" 2>conftest.err)
3508 cat conftest.err >&AS_MESSAGE_LOG_FD
3509 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3510 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3511 cat conftest.err >&AS_MESSAGE_LOG_FD
3512 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
3513 cat conftest.out >&AS_MESSAGE_LOG_FD
3514 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3515 lt_cv_nm_interface="MS dumpbin"
3516 fi
3517 rm -f conftest*])
3518 ])# LT_PATH_NM
3519
3520 # Old names:
3521 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
3522 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
3523 dnl aclocal-1.4 backwards compatibility:
3524 dnl AC_DEFUN([AM_PROG_NM], [])
3525 dnl AC_DEFUN([AC_PROG_NM], [])
3526
3527 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
3528 # --------------------------------
3529 # how to determine the name of the shared library
3530 # associated with a specific link library.
3531 # -- PORTME fill in with the dynamic library characteristics
3532 m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
3533 [m4_require([_LT_DECL_EGREP])
3534 m4_require([_LT_DECL_OBJDUMP])
3535 m4_require([_LT_DECL_DLLTOOL])
3536 AC_CACHE_CHECK([how to associate runtime and link libraries],
3537 lt_cv_sharedlib_from_linklib_cmd,
3538 [lt_cv_sharedlib_from_linklib_cmd='unknown'
3539
3540 case $host_os in
3541 cygwin* | mingw* | pw32* | cegcc*)
3542 # two different shell functions defined in ltmain.sh
3543 # decide which to use based on capabilities of $DLLTOOL
3544 case `$DLLTOOL --help 2>&1` in
3545 *--identify-strict*)
3546 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
3547 ;;
3548 *)
3549 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
3550 ;;
3551 esac
3552 ;;
3553 *)
3554 # fallback: assume linklib IS sharedlib
3555 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
3556 ;;
3557 esac
3558 ])
3559 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
3560 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
3561
3562 _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
3563 [Command to associate shared and link libraries])
3564 ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
3565
3566
3567 # _LT_PATH_MANIFEST_TOOL
3568 # ----------------------
3569 # locate the manifest tool
3570 m4_defun([_LT_PATH_MANIFEST_TOOL],
3571 [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
3572 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
3573 AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
3574 [lt_cv_path_mainfest_tool=no
3575 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
3576 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
3577 cat conftest.err >&AS_MESSAGE_LOG_FD
3578 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
3579 lt_cv_path_mainfest_tool=yes
3580 fi
3581 rm -f conftest*])
3582 if test "x$lt_cv_path_mainfest_tool" != xyes; then
3583 MANIFEST_TOOL=:
3584 fi
3585 _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
3586 ])# _LT_PATH_MANIFEST_TOOL
3587
3588
3589 # LT_LIB_M
3590 # --------
3591 # check for math library
3592 AC_DEFUN([LT_LIB_M],
3593 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3594 LIBM=
3595 case $host in
3596 *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
3597 # These system don't have libm, or don't need it
3598 ;;
3599 *-ncr-sysv4.3*)
3600 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3601 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3602 ;;
3603 *)
3604 AC_CHECK_LIB(m, cos, LIBM="-lm")
3605 ;;
3606 esac
3607 AC_SUBST([LIBM])
3608 ])# LT_LIB_M
3609
3610 # Old name:
3611 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
3612 dnl aclocal-1.4 backwards compatibility:
3613 dnl AC_DEFUN([AC_CHECK_LIBM], [])
3614
3615
3616 # _LT_COMPILER_NO_RTTI([TAGNAME])
3617 # -------------------------------
3618 m4_defun([_LT_COMPILER_NO_RTTI],
3619 [m4_require([_LT_TAG_COMPILER])dnl
3620
3621 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3622
3623 if test "$GCC" = yes; then
3624 case $cc_basename in
3625 nvcc*)
3626 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
3627 *)
3628 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
3629 esac
3630
3631 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
3632 lt_cv_prog_compiler_rtti_exceptions,
3633 [-fno-rtti -fno-exceptions], [],
3634 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
3635 fi
3636 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
3637 [Compiler flag to turn off builtin functions])
3638 ])# _LT_COMPILER_NO_RTTI
3639
3640
3641 # _LT_CMD_GLOBAL_SYMBOLS
3642 # ----------------------
3643 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
3644 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3645 AC_REQUIRE([AC_PROG_CC])dnl
3646 AC_REQUIRE([AC_PROG_AWK])dnl
3647 AC_REQUIRE([LT_PATH_NM])dnl
3648 AC_REQUIRE([LT_PATH_LD])dnl
3649 m4_require([_LT_DECL_SED])dnl
3650 m4_require([_LT_DECL_EGREP])dnl
3651 m4_require([_LT_TAG_COMPILER])dnl
3652
3653 # Check for command to grab the raw symbol name followed by C symbol from nm.
3654 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
3655 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
3656 [
3657 # These are sane defaults that work on at least a few old systems.
3658 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
3659
3660 # Character class describing NM global symbol codes.
3661 symcode='[[BCDEGRST]]'
3662
3663 # Regexp to match symbols that can be accessed directly from C.
3664 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
3665
3666 # Define system-specific variables.
3667 case $host_os in
3668 aix*)
3669 symcode='[[BCDT]]'
3670 ;;
3671 cygwin* | mingw* | pw32* | cegcc*)
3672 symcode='[[ABCDGISTW]]'
3673 ;;
3674 hpux*)
3675 if test "$host_cpu" = ia64; then
3676 symcode='[[ABCDEGRST]]'
3677 fi
3678 ;;
3679 irix* | nonstopux*)
3680 symcode='[[BCDEGRST]]'
3681 ;;
3682 osf*)
3683 symcode='[[BCDEGQRST]]'
3684 ;;
3685 solaris*)
3686 symcode='[[BDRT]]'
3687 ;;
3688 sco3.2v5*)
3689 symcode='[[DT]]'
3690 ;;
3691 sysv4.2uw2*)
3692 symcode='[[DT]]'
3693 ;;
3694 sysv5* | sco5v6* | unixware* | OpenUNIX*)
3695 symcode='[[ABDT]]'
3696 ;;
3697 sysv4)
3698 symcode='[[DFNSTU]]'
3699 ;;
3700 esac
3701
3702 # If we're using GNU nm, then use its standard symbol codes.
3703 case `$NM -V 2>&1` in
3704 *GNU* | *'with BFD'*)
3705 symcode='[[ABCDGIRSTW]]' ;;
3706 esac
3707
3708 # Transform an extracted symbol line into a proper C declaration.
3709 # Some systems (esp. on ia64) link data and code symbols differently,
3710 # so use this general approach.
3711 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
3712
3713 # Transform an extracted symbol line into symbol name and symbol address
3714 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
3715 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'"
3716
3717 # Handle CRLF in mingw tool chain
3718 opt_cr=
3719 case $build_os in
3720 mingw*)
3721 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
3722 ;;
3723 esac
3724
3725 # Try without a prefix underscore, then with it.
3726 for ac_symprfx in "" "_"; do
3727
3728 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
3729 symxfrm="\\1 $ac_symprfx\\2 \\2"
3730
3731 # Write the raw and C identifiers.
3732 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3733 # Fake it for dumpbin and say T for any non-static function
3734 # and D for any global variable.
3735 # Also find C++ and __fastcall symbols from MSVC++,
3736 # which start with @ or ?.
3737 lt_cv_sys_global_symbol_pipe="$AWK ['"\
3738 " {last_section=section; section=\$ 3};"\
3739 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
3740 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
3741 " \$ 0!~/External *\|/{next};"\
3742 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
3743 " {if(hide[section]) next};"\
3744 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
3745 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
3746 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
3747 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
3748 " ' prfx=^$ac_symprfx]"
3749 else
3750 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
3751 fi
3752 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
3753
3754 # Check to see that the pipe works correctly.
3755 pipe_works=no
3756
3757 rm -f conftest*
3758 cat > conftest.$ac_ext <<_LT_EOF
3759 #ifdef __cplusplus
3760 extern "C" {
3761 #endif
3762 char nm_test_var;
3763 void nm_test_func(void);
3764 void nm_test_func(void){}
3765 #ifdef __cplusplus
3766 }
3767 #endif
3768 int main(){nm_test_var='a';nm_test_func();return(0);}
3769 _LT_EOF
3770
3771 if AC_TRY_EVAL(ac_compile); then
3772 # Now try to grab the symbols.
3773 nlist=conftest.nm
3774 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
3775 # Try sorting and uniquifying the output.
3776 if sort "$nlist" | uniq > "$nlist"T; then
3777 mv -f "$nlist"T "$nlist"
3778 else
3779 rm -f "$nlist"T
3780 fi
3781
3782 # Make sure that we snagged all the symbols we need.
3783 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
3784 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
3785 cat <<_LT_EOF > conftest.$ac_ext
3786 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3787 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3788 /* DATA imports from DLLs on WIN32 con't be const, because runtime
3789 relocations are performed -- see ld's documentation on pseudo-relocs. */
3790 # define LT@&t@_DLSYM_CONST
3791 #elif defined(__osf__)
3792 /* This system does not cope well with relocations in const data. */
3793 # define LT@&t@_DLSYM_CONST
3794 #else
3795 # define LT@&t@_DLSYM_CONST const
3796 #endif
3797
3798 #ifdef __cplusplus
3799 extern "C" {
3800 #endif
3801
3802 _LT_EOF
3803 # Now generate the symbol file.
3804 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
3805
3806 cat <<_LT_EOF >> conftest.$ac_ext
3807
3808 /* The mapping between symbol names and symbols. */
3809 LT@&t@_DLSYM_CONST struct {
3810 const char *name;
3811 void *address;
3812 }
3813 lt__PROGRAM__LTX_preloaded_symbols[[]] =
3814 {
3815 { "@PROGRAM@", (void *) 0 },
3816 _LT_EOF
3817 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
3818 cat <<\_LT_EOF >> conftest.$ac_ext
3819 {0, (void *) 0}
3820 };
3821
3822 /* This works around a problem in FreeBSD linker */
3823 #ifdef FREEBSD_WORKAROUND
3824 static const void *lt_preloaded_setup() {
3825 return lt__PROGRAM__LTX_preloaded_symbols;
3826 }
3827 #endif
3828
3829 #ifdef __cplusplus
3830 }
3831 #endif
3832 _LT_EOF
3833 # Now try linking the two files.
3834 mv conftest.$ac_objext conftstm.$ac_objext
3835 lt_globsym_save_LIBS=$LIBS
3836 lt_globsym_save_CFLAGS=$CFLAGS
3837 LIBS="conftstm.$ac_objext"
3838 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
3839 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
3840 pipe_works=yes
3841 fi
3842 LIBS=$lt_globsym_save_LIBS
3843 CFLAGS=$lt_globsym_save_CFLAGS
3844 else
3845 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
3846 fi
3847 else
3848 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
3849 fi
3850 else
3851 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
3852 fi
3853 else
3854 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
3855 cat conftest.$ac_ext >&5
3856 fi
3857 rm -rf conftest* conftst*
3858
3859 # Do not use the global_symbol_pipe unless it works.
3860 if test "$pipe_works" = yes; then
3861 break
3862 else
3863 lt_cv_sys_global_symbol_pipe=
3864 fi
3865 done
3866 ])
3867 if test -z "$lt_cv_sys_global_symbol_pipe"; then
3868 lt_cv_sys_global_symbol_to_cdecl=
3869 fi
3870 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
3871 AC_MSG_RESULT(failed)
3872 else
3873 AC_MSG_RESULT(ok)
3874 fi
3875
3876 # Response file support.
3877 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3878 nm_file_list_spec='@'
3879 elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
3880 nm_file_list_spec='@'
3881 fi
3882
3883 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
3884 [Take the output of nm and produce a listing of raw symbols and C names])
3885 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
3886 [Transform the output of nm in a proper C declaration])
3887 _LT_DECL([global_symbol_to_c_name_address],
3888 [lt_cv_sys_global_symbol_to_c_name_address], [1],
3889 [Transform the output of nm in a C name address pair])
3890 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
3891 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
3892 [Transform the output of nm in a C name address pair when lib prefix is needed])
3893 _LT_DECL([], [nm_file_list_spec], [1],
3894 [Specify filename containing input files for $NM])
3895 ]) # _LT_CMD_GLOBAL_SYMBOLS
3896
3897
3898 # _LT_COMPILER_PIC([TAGNAME])
3899 # ---------------------------
3900 m4_defun([_LT_COMPILER_PIC],
3901 [m4_require([_LT_TAG_COMPILER])dnl
3902 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
3903 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
3904 _LT_TAGVAR(lt_prog_compiler_static, $1)=
3905
3906 m4_if([$1], [CXX], [
3907 # C++ specific cases for pic, static, wl, etc.
3908 if test "$GXX" = yes; then
3909 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3910 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
3911
3912 case $host_os in
3913 aix*)
3914 # All AIX code is PIC.
3915 if test "$host_cpu" = ia64; then
3916 # AIX 5 now supports IA64 processor
3917 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3918 fi
3919 ;;
3920
3921 amigaos*)
3922 case $host_cpu in
3923 powerpc)
3924 # see comment about AmigaOS4 .so support
3925 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3926 ;;
3927 m68k)
3928 # FIXME: we need at least 68020 code to build shared libraries, but
3929 # adding the `-m68020' flag to GCC prevents building anything better,
3930 # like `-m68040'.
3931 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
3932 ;;
3933 esac
3934 ;;
3935
3936 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
3937 # PIC is the default for these OSes.
3938 ;;
3939 mingw* | cygwin* | os2* | pw32* | cegcc*)
3940 # This hack is so that the source file can tell whether it is being
3941 # built for inclusion in a dll (and should export symbols for example).
3942 # Although the cygwin gcc ignores -fPIC, still need this for old-style
3943 # (--disable-auto-import) libraries
3944 m4_if([$1], [GCJ], [],
3945 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
3946 ;;
3947 darwin* | rhapsody*)
3948 # PIC is the default on this platform
3949 # Common symbols not allowed in MH_DYLIB files
3950 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
3951 ;;
3952 *djgpp*)
3953 # DJGPP does not support shared libraries at all
3954 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
3955 ;;
3956 haiku*)
3957 # PIC is the default for Haiku.
3958 # The "-static" flag exists, but is broken.
3959 _LT_TAGVAR(lt_prog_compiler_static, $1)=
3960 ;;
3961 interix[[3-9]]*)
3962 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
3963 # Instead, we relocate shared libraries at runtime.
3964 ;;
3965 sysv4*MP*)
3966 if test -d /usr/nec; then
3967 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
3968 fi
3969 ;;
3970 hpux*)
3971 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
3972 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
3973 # sets the default TLS model and affects inlining.
3974 case $host_cpu in
3975 hppa*64*)
3976 ;;
3977 *)
3978 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3979 ;;
3980 esac
3981 ;;
3982 *qnx* | *nto*)
3983 # QNX uses GNU C++, but need to define -shared option too, otherwise
3984 # it will coredump.
3985 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
3986 ;;
3987 *)
3988 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3989 ;;
3990 esac
3991 else
3992 case $host_os in
3993 aix[[4-9]]*)
3994 # All AIX code is PIC.
3995 if test "$host_cpu" = ia64; then
3996 # AIX 5 now supports IA64 processor
3997 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3998 else
3999 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4000 fi
4001 ;;
4002 chorus*)
4003 case $cc_basename in
4004 cxch68*)
4005 # Green Hills C++ Compiler
4006 # _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"
4007 ;;
4008 esac
4009 ;;
4010 mingw* | cygwin* | os2* | pw32* | cegcc*)
4011 # This hack is so that the source file can tell whether it is being
4012 # built for inclusion in a dll (and should export symbols for example).
4013 m4_if([$1], [GCJ], [],
4014 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4015 ;;
4016 dgux*)
4017 case $cc_basename in
4018 ec++*)
4019 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4020 ;;
4021 ghcx*)
4022 # Green Hills C++ Compiler
4023 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4024 ;;
4025 *)
4026 ;;
4027 esac
4028 ;;
4029 freebsd* | dragonfly*)
4030 # FreeBSD uses GNU C++
4031 ;;
4032 hpux9* | hpux10* | hpux11*)
4033 case $cc_basename in
4034 CC*)
4035 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4036 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4037 if test "$host_cpu" != ia64; then
4038 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4039 fi
4040 ;;
4041 aCC*)
4042 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4043 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4044 case $host_cpu in
4045 hppa*64*|ia64*)
4046 # +Z the default
4047 ;;
4048 *)
4049 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4050 ;;
4051 esac
4052 ;;
4053 *)
4054 ;;
4055 esac
4056 ;;
4057 interix*)
4058 # This is c89, which is MS Visual C++ (no shared libs)
4059 # Anyone wants to do a port?
4060 ;;
4061 irix5* | irix6* | nonstopux*)
4062 case $cc_basename in
4063 CC*)
4064 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4065 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4066 # CC pic flag -KPIC is the default.
4067 ;;
4068 *)
4069 ;;
4070 esac
4071 ;;
4072 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4073 case $cc_basename in
4074 KCC*)
4075 # KAI C++ Compiler
4076 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4077 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4078 ;;
4079 ecpc* )
4080 # old Intel C++ for x86_64 which still supported -KPIC.
4081 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4082 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4083 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4084 ;;
4085 icpc* )
4086 # Intel C++, used to be incompatible with GCC.
4087 # ICC 10 doesn't accept -KPIC any more.
4088 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4089 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4090 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4091 ;;
4092 pgCC* | pgcpp*)
4093 # Portland Group C++ compiler
4094 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4095 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4096 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4097 ;;
4098 cxx*)
4099 # Compaq C++
4100 # Make sure the PIC flag is empty. It appears that all Alpha
4101 # Linux and Compaq Tru64 Unix objects are PIC.
4102 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4103 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4104 ;;
4105 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
4106 # IBM XL 8.0, 9.0 on PPC and BlueGene
4107 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4108 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4109 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4110 ;;
4111 *)
4112 case `$CC -V 2>&1 | sed 5q` in
4113 *Sun\ C*)
4114 # Sun C++ 5.9
4115 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4116 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4117 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4118 ;;
4119 esac
4120 ;;
4121 esac
4122 ;;
4123 lynxos*)
4124 ;;
4125 m88k*)
4126 ;;
4127 mvs*)
4128 case $cc_basename in
4129 cxx*)
4130 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4131 ;;
4132 *)
4133 ;;
4134 esac
4135 ;;
4136 netbsd* | netbsdelf*-gnu)
4137 ;;
4138 *qnx* | *nto*)
4139 # QNX uses GNU C++, but need to define -shared option too, otherwise
4140 # it will coredump.
4141 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4142 ;;
4143 osf3* | osf4* | osf5*)
4144 case $cc_basename in
4145 KCC*)
4146 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4147 ;;
4148 RCC*)
4149 # Rational C++ 2.4.1
4150 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4151 ;;
4152 cxx*)
4153 # Digital/Compaq C++
4154 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4155 # Make sure the PIC flag is empty. It appears that all Alpha
4156 # Linux and Compaq Tru64 Unix objects are PIC.
4157 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4158 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4159 ;;
4160 *)
4161 ;;
4162 esac
4163 ;;
4164 psos*)
4165 ;;
4166 solaris*)
4167 case $cc_basename in
4168 CC* | sunCC*)
4169 # Sun C++ 4.2, 5.x and Centerline C++
4170 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4171 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4172 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4173 ;;
4174 gcx*)
4175 # Green Hills C++ Compiler
4176 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4177 ;;
4178 *)
4179 ;;
4180 esac
4181 ;;
4182 sunos4*)
4183 case $cc_basename in
4184 CC*)
4185 # Sun C++ 4.x
4186 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4187 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4188 ;;
4189 lcc*)
4190 # Lucid
4191 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4192 ;;
4193 *)
4194 ;;
4195 esac
4196 ;;
4197 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4198 case $cc_basename in
4199 CC*)
4200 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4201 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4202 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4203 ;;
4204 esac
4205 ;;
4206 tandem*)
4207 case $cc_basename in
4208 NCC*)
4209 # NonStop-UX NCC 3.20
4210 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4211 ;;
4212 *)
4213 ;;
4214 esac
4215 ;;
4216 vxworks*)
4217 ;;
4218 *)
4219 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4220 ;;
4221 esac
4222 fi
4223 ],
4224 [
4225 if test "$GCC" = yes; then
4226 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4227 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4228
4229 case $host_os in
4230 aix*)
4231 # All AIX code is PIC.
4232 if test "$host_cpu" = ia64; then
4233 # AIX 5 now supports IA64 processor
4234 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4235 fi
4236 ;;
4237
4238 amigaos*)
4239 case $host_cpu in
4240 powerpc)
4241 # see comment about AmigaOS4 .so support
4242 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4243 ;;
4244 m68k)
4245 # FIXME: we need at least 68020 code to build shared libraries, but
4246 # adding the `-m68020' flag to GCC prevents building anything better,
4247 # like `-m68040'.
4248 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4249 ;;
4250 esac
4251 ;;
4252
4253 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4254 # PIC is the default for these OSes.
4255 ;;
4256
4257 mingw* | cygwin* | pw32* | os2* | cegcc*)
4258 # This hack is so that the source file can tell whether it is being
4259 # built for inclusion in a dll (and should export symbols for example).
4260 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4261 # (--disable-auto-import) libraries
4262 m4_if([$1], [GCJ], [],
4263 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4264 ;;
4265
4266 darwin* | rhapsody*)
4267 # PIC is the default on this platform
4268 # Common symbols not allowed in MH_DYLIB files
4269 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4270 ;;
4271
4272 haiku*)
4273 # PIC is the default for Haiku.
4274 # The "-static" flag exists, but is broken.
4275 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4276 ;;
4277
4278 hpux*)
4279 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4280 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4281 # sets the default TLS model and affects inlining.
4282 case $host_cpu in
4283 hppa*64*)
4284 # +Z the default
4285 ;;
4286 *)
4287 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4288 ;;
4289 esac
4290 ;;
4291
4292 interix[[3-9]]*)
4293 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4294 # Instead, we relocate shared libraries at runtime.
4295 ;;
4296
4297 msdosdjgpp*)
4298 # Just because we use GCC doesn't mean we suddenly get shared libraries
4299 # on systems that don't support them.
4300 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4301 enable_shared=no
4302 ;;
4303
4304 *nto* | *qnx*)
4305 # QNX uses GNU C++, but need to define -shared option too, otherwise
4306 # it will coredump.
4307 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4308 ;;
4309
4310 sysv4*MP*)
4311 if test -d /usr/nec; then
4312 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4313 fi
4314 ;;
4315
4316 *)
4317 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4318 ;;
4319 esac
4320
4321 case $cc_basename in
4322 nvcc*) # Cuda Compiler Driver 2.2
4323 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
4324 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4325 _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
4326 fi
4327 ;;
4328 esac
4329 else
4330 # PORTME Check for flag to pass linker flags through the system compiler.
4331 case $host_os in
4332 aix*)
4333 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4334 if test "$host_cpu" = ia64; then
4335 # AIX 5 now supports IA64 processor
4336 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4337 else
4338 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4339 fi
4340 ;;
4341
4342 mingw* | cygwin* | pw32* | os2* | cegcc*)
4343 # This hack is so that the source file can tell whether it is being
4344 # built for inclusion in a dll (and should export symbols for example).
4345 m4_if([$1], [GCJ], [],
4346 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4347 ;;
4348
4349 hpux9* | hpux10* | hpux11*)
4350 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4351 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4352 # not for PA HP-UX.
4353 case $host_cpu in
4354 hppa*64*|ia64*)
4355 # +Z the default
4356 ;;
4357 *)
4358 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4359 ;;
4360 esac
4361 # Is there a better lt_prog_compiler_static that works with the bundled CC?
4362 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4363 ;;
4364
4365 irix5* | irix6* | nonstopux*)
4366 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4367 # PIC (with -KPIC) is the default.
4368 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4369 ;;
4370
4371 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4372 case $cc_basename in
4373 # old Intel for x86_64 which still supported -KPIC.
4374 ecc*)
4375 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4376 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4377 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4378 ;;
4379 # icc used to be incompatible with GCC.
4380 # ICC 10 doesn't accept -KPIC any more.
4381 icc* | ifort*)
4382 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4383 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4384 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4385 ;;
4386 # Lahey Fortran 8.1.
4387 lf95*)
4388 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4389 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
4390 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
4391 ;;
4392 nagfor*)
4393 # NAG Fortran compiler
4394 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
4395 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4396 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4397 ;;
4398 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
4399 # Portland Group compilers (*not* the Pentium gcc compiler,
4400 # which looks to be a dead project)
4401 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4402 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4403 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4404 ;;
4405 ccc*)
4406 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4407 # All Alpha code is PIC.
4408 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4409 ;;
4410 xl* | bgxl* | bgf* | mpixl*)
4411 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
4412 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4413 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4414 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4415 ;;
4416 *)
4417 case `$CC -V 2>&1 | sed 5q` in
4418 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
4419 # Sun Fortran 8.3 passes all unrecognized flags to the linker
4420 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4421 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4422 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4423 ;;
4424 *Sun\ F* | *Sun*Fortran*)
4425 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4426 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4427 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4428 ;;
4429 *Sun\ C*)
4430 # Sun C 5.9
4431 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4432 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4433 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4434 ;;
4435 *Intel*\ [[CF]]*Compiler*)
4436 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4437 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4438 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4439 ;;
4440 *Portland\ Group*)
4441 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4442 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4443 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4444 ;;
4445 esac
4446 ;;
4447 esac
4448 ;;
4449
4450 newsos6)
4451 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4452 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4453 ;;
4454
4455 *nto* | *qnx*)
4456 # QNX uses GNU C++, but need to define -shared option too, otherwise
4457 # it will coredump.
4458 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4459 ;;
4460
4461 osf3* | osf4* | osf5*)
4462 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4463 # All OSF/1 code is PIC.
4464 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4465 ;;
4466
4467 rdos*)
4468 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4469 ;;
4470
4471 solaris*)
4472 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4473 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4474 case $cc_basename in
4475 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
4476 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4477 *)
4478 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4479 esac
4480 ;;
4481
4482 sunos4*)
4483 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4484 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4485 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4486 ;;
4487
4488 sysv4 | sysv4.2uw2* | sysv4.3*)
4489 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4490 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4491 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4492 ;;
4493
4494 sysv4*MP*)
4495 if test -d /usr/nec ;then
4496 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
4497 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4498 fi
4499 ;;
4500
4501 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4502 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4503 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4504 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4505 ;;
4506
4507 unicos*)
4508 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4509 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4510 ;;
4511
4512 uts4*)
4513 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4514 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4515 ;;
4516
4517 *)
4518 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4519 ;;
4520 esac
4521 fi
4522 ])
4523 case $host_os in
4524 # For platforms which do not support PIC, -DPIC is meaningless:
4525 *djgpp*)
4526 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4527 ;;
4528 *)
4529 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4530 ;;
4531 esac
4532
4533 AC_CACHE_CHECK([for $compiler option to produce PIC],
4534 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
4535 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4536 _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
4537
4538 #
4539 # Check to make sure the PIC flag actually works.
4540 #
4541 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4542 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
4543 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
4544 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
4545 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
4546 "" | " "*) ;;
4547 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
4548 esac],
4549 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4550 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
4551 fi
4552 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4553 [Additional compiler flags for building library objects])
4554
4555 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4556 [How to pass a linker flag through the compiler])
4557 #
4558 # Check to make sure the static flag actually works.
4559 #
4560 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
4561 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
4562 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
4563 $lt_tmp_static_flag,
4564 [],
4565 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
4566 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
4567 [Compiler flag to prevent dynamic linking])
4568 ])# _LT_COMPILER_PIC
4569
4570
4571 # _LT_LINKER_SHLIBS([TAGNAME])
4572 # ----------------------------
4573 # See if the linker supports building shared libraries.
4574 m4_defun([_LT_LINKER_SHLIBS],
4575 [AC_REQUIRE([LT_PATH_LD])dnl
4576 AC_REQUIRE([LT_PATH_NM])dnl
4577 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
4578 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4579 m4_require([_LT_DECL_EGREP])dnl
4580 m4_require([_LT_DECL_SED])dnl
4581 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
4582 m4_require([_LT_TAG_COMPILER])dnl
4583 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4584 m4_if([$1], [CXX], [
4585 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4586 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4587 case $host_os in
4588 aix[[4-9]]*)
4589 # If we're using GNU nm, then we don't want the "-C" option.
4590 # -C means demangle to AIX nm, but means don't demangle with GNU nm
4591 # Also, AIX nm treats weak defined symbols like other global defined
4592 # symbols, whereas GNU nm marks them as "W".
4593 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4594 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4595 else
4596 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4597 fi
4598 ;;
4599 pw32*)
4600 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4601 ;;
4602 cygwin* | mingw* | cegcc*)
4603 case $cc_basename in
4604 cl*)
4605 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
4606 ;;
4607 *)
4608 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4609 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
4610 ;;
4611 esac
4612 ;;
4613 linux* | k*bsd*-gnu | gnu*)
4614 _LT_TAGVAR(link_all_deplibs, $1)=no
4615 ;;
4616 *)
4617 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4618 ;;
4619 esac
4620 ], [
4621 runpath_var=
4622 _LT_TAGVAR(allow_undefined_flag, $1)=
4623 _LT_TAGVAR(always_export_symbols, $1)=no
4624 _LT_TAGVAR(archive_cmds, $1)=
4625 _LT_TAGVAR(archive_expsym_cmds, $1)=
4626 _LT_TAGVAR(compiler_needs_object, $1)=no
4627 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4628 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
4629 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4630 _LT_TAGVAR(hardcode_automatic, $1)=no
4631 _LT_TAGVAR(hardcode_direct, $1)=no
4632 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
4633 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4634 _LT_TAGVAR(hardcode_libdir_separator, $1)=
4635 _LT_TAGVAR(hardcode_minus_L, $1)=no
4636 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4637 _LT_TAGVAR(inherit_rpath, $1)=no
4638 _LT_TAGVAR(link_all_deplibs, $1)=unknown
4639 _LT_TAGVAR(module_cmds, $1)=
4640 _LT_TAGVAR(module_expsym_cmds, $1)=
4641 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
4642 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
4643 _LT_TAGVAR(thread_safe_flag_spec, $1)=
4644 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4645 # include_expsyms should be a list of space-separated symbols to be *always*
4646 # included in the symbol list
4647 _LT_TAGVAR(include_expsyms, $1)=
4648 # exclude_expsyms can be an extended regexp of symbols to exclude
4649 # it will be wrapped by ` (' and `)$', so one must not match beginning or
4650 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4651 # as well as any symbol that contains `d'.
4652 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4653 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4654 # platforms (ab)use it in PIC code, but their linkers get confused if
4655 # the symbol is explicitly referenced. Since portable code cannot
4656 # rely on this symbol name, it's probably fine to never include it in
4657 # preloaded symbol tables.
4658 # Exclude shared library initialization/finalization symbols.
4659 dnl Note also adjust exclude_expsyms for C++ above.
4660 extract_expsyms_cmds=
4661
4662 case $host_os in
4663 cygwin* | mingw* | pw32* | cegcc*)
4664 # FIXME: the MSVC++ port hasn't been tested in a loooong time
4665 # When not using gcc, we currently assume that we are using
4666 # Microsoft Visual C++.
4667 if test "$GCC" != yes; then
4668 with_gnu_ld=no
4669 fi
4670 ;;
4671 interix*)
4672 # we just hope/assume this is gcc and not c89 (= MSVC++)
4673 with_gnu_ld=yes
4674 ;;
4675 openbsd*)
4676 with_gnu_ld=no
4677 ;;
4678 linux* | k*bsd*-gnu | gnu*)
4679 _LT_TAGVAR(link_all_deplibs, $1)=no
4680 ;;
4681 esac
4682
4683 _LT_TAGVAR(ld_shlibs, $1)=yes
4684
4685 # On some targets, GNU ld is compatible enough with the native linker
4686 # that we're better off using the native interface for both.
4687 lt_use_gnu_ld_interface=no
4688 if test "$with_gnu_ld" = yes; then
4689 case $host_os in
4690 aix*)
4691 # The AIX port of GNU ld has always aspired to compatibility
4692 # with the native linker. However, as the warning in the GNU ld
4693 # block says, versions before 2.19.5* couldn't really create working
4694 # shared libraries, regardless of the interface used.
4695 case `$LD -v 2>&1` in
4696 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
4697 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
4698 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
4699 *)
4700 lt_use_gnu_ld_interface=yes
4701 ;;
4702 esac
4703 ;;
4704 *)
4705 lt_use_gnu_ld_interface=yes
4706 ;;
4707 esac
4708 fi
4709
4710 if test "$lt_use_gnu_ld_interface" = yes; then
4711 # If archive_cmds runs LD, not CC, wlarc should be empty
4712 wlarc='${wl}'
4713
4714 # Set some defaults for GNU ld with shared library support. These
4715 # are reset later if shared libraries are not supported. Putting them
4716 # here allows them to be overridden if necessary.
4717 runpath_var=LD_RUN_PATH
4718 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4719 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4720 # ancient GNU ld didn't support --whole-archive et. al.
4721 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
4722 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4723 else
4724 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4725 fi
4726 supports_anon_versioning=no
4727 case `$LD -v 2>&1` in
4728 *GNU\ gold*) supports_anon_versioning=yes ;;
4729 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
4730 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
4731 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
4732 *\ 2.11.*) ;; # other 2.11 versions
4733 *) supports_anon_versioning=yes ;;
4734 esac
4735
4736 # See if GNU ld supports shared libraries.
4737 case $host_os in
4738 aix[[3-9]]*)
4739 # On AIX/PPC, the GNU linker is very broken
4740 if test "$host_cpu" != ia64; then
4741 _LT_TAGVAR(ld_shlibs, $1)=no
4742 cat <<_LT_EOF 1>&2
4743
4744 *** Warning: the GNU linker, at least up to release 2.19, is reported
4745 *** to be unable to reliably create shared libraries on AIX.
4746 *** Therefore, libtool is disabling shared libraries support. If you
4747 *** really care for shared libraries, you may want to install binutils
4748 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
4749 *** You will then need to restart the configuration process.
4750
4751 _LT_EOF
4752 fi
4753 ;;
4754
4755 amigaos*)
4756 case $host_cpu in
4757 powerpc)
4758 # see comment about AmigaOS4 .so support
4759 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4760 _LT_TAGVAR(archive_expsym_cmds, $1)=''
4761 ;;
4762 m68k)
4763 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
4764 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4765 _LT_TAGVAR(hardcode_minus_L, $1)=yes
4766 ;;
4767 esac
4768 ;;
4769
4770 beos*)
4771 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4772 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4773 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
4774 # support --undefined. This deserves some investigation. FIXME
4775 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4776 else
4777 _LT_TAGVAR(ld_shlibs, $1)=no
4778 fi
4779 ;;
4780
4781 cygwin* | mingw* | pw32* | cegcc*)
4782 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4783 # as there is no search path for DLLs.
4784 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4785 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
4786 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4787 _LT_TAGVAR(always_export_symbols, $1)=no
4788 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4789 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4790 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
4791
4792 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
4793 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4794 # If the export-symbols file already is a .def file (1st line
4795 # is EXPORTS), use it as is; otherwise, prepend...
4796 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
4797 cp $export_symbols $output_objdir/$soname.def;
4798 else
4799 echo EXPORTS > $output_objdir/$soname.def;
4800 cat $export_symbols >> $output_objdir/$soname.def;
4801 fi~
4802 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4803 else
4804 _LT_TAGVAR(ld_shlibs, $1)=no
4805 fi
4806 ;;
4807
4808 haiku*)
4809 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4810 _LT_TAGVAR(link_all_deplibs, $1)=yes
4811 ;;
4812
4813 interix[[3-9]]*)
4814 _LT_TAGVAR(hardcode_direct, $1)=no
4815 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4816 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4817 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4818 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4819 # Instead, shared libraries are loaded at an image base (0x10000000 by
4820 # default) and relocated if they conflict, which is a slow very memory
4821 # consuming and fragmenting process. To avoid this, we pick a random,
4822 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4823 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
4824 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4825 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4826 ;;
4827
4828 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
4829 tmp_diet=no
4830 if test "$host_os" = linux-dietlibc; then
4831 case $cc_basename in
4832 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
4833 esac
4834 fi
4835 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
4836 && test "$tmp_diet" = no
4837 then
4838 tmp_addflag=' $pic_flag'
4839 tmp_sharedflag='-shared'
4840 case $cc_basename,$host_cpu in
4841 pgcc*) # Portland Group C compiler
4842 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4843 tmp_addflag=' $pic_flag'
4844 ;;
4845 pgf77* | pgf90* | pgf95* | pgfortran*)
4846 # Portland Group f77 and f90 compilers
4847 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4848 tmp_addflag=' $pic_flag -Mnomain' ;;
4849 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
4850 tmp_addflag=' -i_dynamic' ;;
4851 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
4852 tmp_addflag=' -i_dynamic -nofor_main' ;;
4853 ifc* | ifort*) # Intel Fortran compiler
4854 tmp_addflag=' -nofor_main' ;;
4855 lf95*) # Lahey Fortran 8.1
4856 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4857 tmp_sharedflag='--shared' ;;
4858 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
4859 tmp_sharedflag='-qmkshrobj'
4860 tmp_addflag= ;;
4861 nvcc*) # Cuda Compiler Driver 2.2
4862 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4863 _LT_TAGVAR(compiler_needs_object, $1)=yes
4864 ;;
4865 esac
4866 case `$CC -V 2>&1 | sed 5q` in
4867 *Sun\ C*) # Sun C 5.9
4868 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4869 _LT_TAGVAR(compiler_needs_object, $1)=yes
4870 tmp_sharedflag='-G' ;;
4871 *Sun\ F*) # Sun Fortran 8.3
4872 tmp_sharedflag='-G' ;;
4873 esac
4874 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4875
4876 if test "x$supports_anon_versioning" = xyes; then
4877 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4878 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4879 echo "local: *; };" >> $output_objdir/$libname.ver~
4880 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
4881 fi
4882
4883 case $cc_basename in
4884 xlf* | bgf* | bgxlf* | mpixlf*)
4885 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
4886 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
4887 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4888 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
4889 if test "x$supports_anon_versioning" = xyes; then
4890 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4891 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4892 echo "local: *; };" >> $output_objdir/$libname.ver~
4893 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
4894 fi
4895 ;;
4896 esac
4897 else
4898 _LT_TAGVAR(ld_shlibs, $1)=no
4899 fi
4900 ;;
4901
4902 netbsd* | netbsdelf*-gnu)
4903 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4904 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
4905 wlarc=
4906 else
4907 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4908 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4909 fi
4910 ;;
4911
4912 solaris*)
4913 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
4914 _LT_TAGVAR(ld_shlibs, $1)=no
4915 cat <<_LT_EOF 1>&2
4916
4917 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
4918 *** create shared libraries on Solaris systems. Therefore, libtool
4919 *** is disabling shared libraries support. We urge you to upgrade GNU
4920 *** binutils to release 2.9.1 or newer. Another option is to modify
4921 *** your PATH or compiler configuration so that the native linker is
4922 *** used, and then restart.
4923
4924 _LT_EOF
4925 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4926 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4927 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4928 else
4929 _LT_TAGVAR(ld_shlibs, $1)=no
4930 fi
4931 ;;
4932
4933 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
4934 case `$LD -v 2>&1` in
4935 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
4936 _LT_TAGVAR(ld_shlibs, $1)=no
4937 cat <<_LT_EOF 1>&2
4938
4939 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
4940 *** reliably create shared libraries on SCO systems. Therefore, libtool
4941 *** is disabling shared libraries support. We urge you to upgrade GNU
4942 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
4943 *** your PATH or compiler configuration so that the native linker is
4944 *** used, and then restart.
4945
4946 _LT_EOF
4947 ;;
4948 *)
4949 # For security reasons, it is highly recommended that you always
4950 # use absolute paths for naming shared libraries, and exclude the
4951 # DT_RUNPATH tag from executables and libraries. But doing so
4952 # requires that you compile everything twice, which is a pain.
4953 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4954 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4955 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4956 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4957 else
4958 _LT_TAGVAR(ld_shlibs, $1)=no
4959 fi
4960 ;;
4961 esac
4962 ;;
4963
4964 sunos4*)
4965 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
4966 wlarc=
4967 _LT_TAGVAR(hardcode_direct, $1)=yes
4968 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4969 ;;
4970
4971 *)
4972 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4973 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4974 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4975 else
4976 _LT_TAGVAR(ld_shlibs, $1)=no
4977 fi
4978 ;;
4979 esac
4980
4981 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
4982 runpath_var=
4983 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4984 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
4985 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4986 fi
4987 else
4988 # PORTME fill in a description of your system's linker (not GNU ld)
4989 case $host_os in
4990 aix3*)
4991 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4992 _LT_TAGVAR(always_export_symbols, $1)=yes
4993 _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
4994 # Note: this linker hardcodes the directories in LIBPATH if there
4995 # are no directories specified by -L.
4996 _LT_TAGVAR(hardcode_minus_L, $1)=yes
4997 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
4998 # Neither direct hardcoding nor static linking is supported with a
4999 # broken collect2.
5000 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5001 fi
5002 ;;
5003
5004 aix[[4-9]]*)
5005 if test "$host_cpu" = ia64; then
5006 # On IA64, the linker does run time linking by default, so we don't
5007 # have to do anything special.
5008 aix_use_runtimelinking=no
5009 exp_sym_flag='-Bexport'
5010 no_entry_flag=""
5011 else
5012 # If we're using GNU nm, then we don't want the "-C" option.
5013 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5014 # Also, AIX nm treats weak defined symbols like other global
5015 # defined symbols, whereas GNU nm marks them as "W".
5016 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5017 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5018 else
5019 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5020 fi
5021 aix_use_runtimelinking=no
5022
5023 # Test if we are trying to use run time linking or normal
5024 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5025 # need to do runtime linking.
5026 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5027 for ld_flag in $LDFLAGS; do
5028 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5029 aix_use_runtimelinking=yes
5030 break
5031 fi
5032 done
5033 ;;
5034 esac
5035
5036 exp_sym_flag='-bexport'
5037 no_entry_flag='-bnoentry'
5038 fi
5039
5040 # When large executables or shared objects are built, AIX ld can
5041 # have problems creating the table of contents. If linking a library
5042 # or program results in "error TOC overflow" add -mminimal-toc to
5043 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5044 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5045
5046 _LT_TAGVAR(archive_cmds, $1)=''
5047 _LT_TAGVAR(hardcode_direct, $1)=yes
5048 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5049 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5050 _LT_TAGVAR(link_all_deplibs, $1)=yes
5051 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5052
5053 if test "$GCC" = yes; then
5054 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5055 # We only want to do this on AIX 4.2 and lower, the check
5056 # below for broken collect2 doesn't work under 4.3+
5057 collect2name=`${CC} -print-prog-name=collect2`
5058 if test -f "$collect2name" &&
5059 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5060 then
5061 # We have reworked collect2
5062 :
5063 else
5064 # We have old collect2
5065 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5066 # It fails to find uninstalled libraries when the uninstalled
5067 # path is not listed in the libpath. Setting hardcode_minus_L
5068 # to unsupported forces relinking
5069 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5070 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5071 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5072 fi
5073 ;;
5074 esac
5075 shared_flag='-shared'
5076 if test "$aix_use_runtimelinking" = yes; then
5077 shared_flag="$shared_flag "'${wl}-G'
5078 fi
5079 _LT_TAGVAR(link_all_deplibs, $1)=no
5080 else
5081 # not using gcc
5082 if test "$host_cpu" = ia64; then
5083 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5084 # chokes on -Wl,-G. The following line is correct:
5085 shared_flag='-G'
5086 else
5087 if test "$aix_use_runtimelinking" = yes; then
5088 shared_flag='${wl}-G'
5089 else
5090 shared_flag='${wl}-bM:SRE'
5091 fi
5092 fi
5093 fi
5094
5095 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
5096 # It seems that -bexpall does not export symbols beginning with
5097 # underscore (_), so it is better to generate a list of symbols to export.
5098 _LT_TAGVAR(always_export_symbols, $1)=yes
5099 if test "$aix_use_runtimelinking" = yes; then
5100 # Warning - without using the other runtime loading flags (-brtl),
5101 # -berok will link without error, but may produce a broken library.
5102 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5103 # Determine the default libpath from the value encoded in an
5104 # empty executable.
5105 _LT_SYS_MODULE_PATH_AIX([$1])
5106 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5107 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5108 else
5109 if test "$host_cpu" = ia64; then
5110 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5111 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5112 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
5113 else
5114 # Determine the default libpath from the value encoded in an
5115 # empty executable.
5116 _LT_SYS_MODULE_PATH_AIX([$1])
5117 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5118 # Warning - without using the other run time loading flags,
5119 # -berok will link without error, but may produce a broken library.
5120 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5121 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5122 if test "$with_gnu_ld" = yes; then
5123 # We only use this code for GNU lds that support --whole-archive.
5124 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
5125 else
5126 # Exported symbols can be pulled into shared objects from archives
5127 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5128 fi
5129 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5130 # This is similar to how AIX traditionally builds its shared libraries.
5131 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
5132 fi
5133 fi
5134 ;;
5135
5136 amigaos*)
5137 case $host_cpu in
5138 powerpc)
5139 # see comment about AmigaOS4 .so support
5140 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5141 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5142 ;;
5143 m68k)
5144 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
5145 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5146 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5147 ;;
5148 esac
5149 ;;
5150
5151 bsdi[[45]]*)
5152 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5153 ;;
5154
5155 cygwin* | mingw* | pw32* | cegcc*)
5156 # When not using gcc, we currently assume that we are using
5157 # Microsoft Visual C++.
5158 # hardcode_libdir_flag_spec is actually meaningless, as there is
5159 # no search path for DLLs.
5160 case $cc_basename in
5161 cl*)
5162 # Native MSVC
5163 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5164 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5165 _LT_TAGVAR(always_export_symbols, $1)=yes
5166 _LT_TAGVAR(file_list_spec, $1)='@'
5167 # Tell ltmain to make .lib files, not .a files.
5168 libext=lib
5169 # Tell ltmain to make .dll files, not .so files.
5170 shrext_cmds=".dll"
5171 # FIXME: Setting linknames here is a bad hack.
5172 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
5173 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
5174 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
5175 else
5176 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
5177 fi~
5178 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
5179 linknames='
5180 # The linker will not automatically build a static lib if we build a DLL.
5181 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5182 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5183 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5184 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
5185 # Don't use ranlib
5186 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
5187 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
5188 lt_tool_outputfile="@TOOL_OUTPUT@"~
5189 case $lt_outputfile in
5190 *.exe|*.EXE) ;;
5191 *)
5192 lt_outputfile="$lt_outputfile.exe"
5193 lt_tool_outputfile="$lt_tool_outputfile.exe"
5194 ;;
5195 esac~
5196 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
5197 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
5198 $RM "$lt_outputfile.manifest";
5199 fi'
5200 ;;
5201 *)
5202 # Assume MSVC wrapper
5203 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5204 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5205 # Tell ltmain to make .lib files, not .a files.
5206 libext=lib
5207 # Tell ltmain to make .dll files, not .so files.
5208 shrext_cmds=".dll"
5209 # FIXME: Setting linknames here is a bad hack.
5210 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
5211 # The linker will automatically build a .lib file if we build a DLL.
5212 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5213 # FIXME: Should let the user specify the lib program.
5214 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
5215 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5216 ;;
5217 esac
5218 ;;
5219
5220 darwin* | rhapsody*)
5221 _LT_DARWIN_LINKER_FEATURES($1)
5222 ;;
5223
5224 dgux*)
5225 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5226 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5227 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5228 ;;
5229
5230 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
5231 # support. Future versions do this automatically, but an explicit c++rt0.o
5232 # does not break anything, and helps significantly (at the cost of a little
5233 # extra space).
5234 freebsd2.2*)
5235 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
5236 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5237 _LT_TAGVAR(hardcode_direct, $1)=yes
5238 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5239 ;;
5240
5241 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
5242 freebsd2.*)
5243 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5244 _LT_TAGVAR(hardcode_direct, $1)=yes
5245 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5246 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5247 ;;
5248
5249 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5250 freebsd* | dragonfly*)
5251 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5252 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5253 _LT_TAGVAR(hardcode_direct, $1)=yes
5254 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5255 ;;
5256
5257 hpux9*)
5258 if test "$GCC" = yes; then
5259 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5260 else
5261 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5262 fi
5263 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5264 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5265 _LT_TAGVAR(hardcode_direct, $1)=yes
5266
5267 # hardcode_minus_L: Not really in the search PATH,
5268 # but as the default location of the library.
5269 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5270 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5271 ;;
5272
5273 hpux10*)
5274 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
5275 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5276 else
5277 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
5278 fi
5279 if test "$with_gnu_ld" = no; then
5280 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5281 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5282 _LT_TAGVAR(hardcode_direct, $1)=yes
5283 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5284 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5285 # hardcode_minus_L: Not really in the search PATH,
5286 # but as the default location of the library.
5287 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5288 fi
5289 ;;
5290
5291 hpux11*)
5292 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
5293 case $host_cpu in
5294 hppa*64*)
5295 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5296 ;;
5297 ia64*)
5298 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5299 ;;
5300 *)
5301 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5302 ;;
5303 esac
5304 else
5305 case $host_cpu in
5306 hppa*64*)
5307 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5308 ;;
5309 ia64*)
5310 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5311 ;;
5312 *)
5313 m4_if($1, [], [
5314 # Older versions of the 11.00 compiler do not understand -b yet
5315 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
5316 _LT_LINKER_OPTION([if $CC understands -b],
5317 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
5318 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
5319 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
5320 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
5321 ;;
5322 esac
5323 fi
5324 if test "$with_gnu_ld" = no; then
5325 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5326 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5327
5328 case $host_cpu in
5329 hppa*64*|ia64*)
5330 _LT_TAGVAR(hardcode_direct, $1)=no
5331 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5332 ;;
5333 *)
5334 _LT_TAGVAR(hardcode_direct, $1)=yes
5335 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5336 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5337
5338 # hardcode_minus_L: Not really in the search PATH,
5339 # but as the default location of the library.
5340 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5341 ;;
5342 esac
5343 fi
5344 ;;
5345
5346 irix5* | irix6* | nonstopux*)
5347 if test "$GCC" = yes; then
5348 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5349 # Try to use the -exported_symbol ld option, if it does not
5350 # work, assume that -exports_file does not work either and
5351 # implicitly export all symbols.
5352 # This should be the same for all languages, so no per-tag cache variable.
5353 AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
5354 [lt_cv_irix_exported_symbol],
5355 [save_LDFLAGS="$LDFLAGS"
5356 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
5357 AC_LINK_IFELSE(
5358 [AC_LANG_SOURCE(
5359 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
5360 [C++], [[int foo (void) { return 0; }]],
5361 [Fortran 77], [[
5362 subroutine foo
5363 end]],
5364 [Fortran], [[
5365 subroutine foo
5366 end]])])],
5367 [lt_cv_irix_exported_symbol=yes],
5368 [lt_cv_irix_exported_symbol=no])
5369 LDFLAGS="$save_LDFLAGS"])
5370 if test "$lt_cv_irix_exported_symbol" = yes; then
5371 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
5372 fi
5373 else
5374 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5375 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
5376 fi
5377 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5378 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5379 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5380 _LT_TAGVAR(inherit_rpath, $1)=yes
5381 _LT_TAGVAR(link_all_deplibs, $1)=yes
5382 ;;
5383
5384 netbsd* | netbsdelf*-gnu)
5385 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5386 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
5387 else
5388 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
5389 fi
5390 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5391 _LT_TAGVAR(hardcode_direct, $1)=yes
5392 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5393 ;;
5394
5395 newsos6)
5396 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5397 _LT_TAGVAR(hardcode_direct, $1)=yes
5398 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5399 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5400 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5401 ;;
5402
5403 *nto* | *qnx*)
5404 ;;
5405
5406 openbsd*)
5407 if test -f /usr/libexec/ld.so; then
5408 _LT_TAGVAR(hardcode_direct, $1)=yes
5409 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5410 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5411 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5412 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5413 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
5414 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5415 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5416 else
5417 case $host_os in
5418 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5419 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5420 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5421 ;;
5422 *)
5423 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5424 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5425 ;;
5426 esac
5427 fi
5428 else
5429 _LT_TAGVAR(ld_shlibs, $1)=no
5430 fi
5431 ;;
5432
5433 os2*)
5434 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5435 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5436 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5437 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
5438 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
5439 ;;
5440
5441 osf3*)
5442 if test "$GCC" = yes; then
5443 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5444 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5445 else
5446 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5447 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5448 fi
5449 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5450 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5451 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5452 ;;
5453
5454 osf4* | osf5*) # as osf3* with the addition of -msym flag
5455 if test "$GCC" = yes; then
5456 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5457 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5458 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5459 else
5460 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5461 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5462 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
5463 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
5464
5465 # Both c and cxx compiler support -rpath directly
5466 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
5467 fi
5468 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5469 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5470 ;;
5471
5472 solaris*)
5473 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5474 if test "$GCC" = yes; then
5475 wlarc='${wl}'
5476 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5477 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5478 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5479 else
5480 case `$CC -V 2>&1` in
5481 *"Compilers 5.0"*)
5482 wlarc=''
5483 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
5484 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5485 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
5486 ;;
5487 *)
5488 wlarc='${wl}'
5489 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
5490 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5491 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5492 ;;
5493 esac
5494 fi
5495 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5496 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5497 case $host_os in
5498 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
5499 *)
5500 # The compiler driver will combine and reorder linker options,
5501 # but understands `-z linker_flag'. GCC discards it without `$wl',
5502 # but is careful enough not to reorder.
5503 # Supported since Solaris 2.6 (maybe 2.5.1?)
5504 if test "$GCC" = yes; then
5505 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
5506 else
5507 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
5508 fi
5509 ;;
5510 esac
5511 _LT_TAGVAR(link_all_deplibs, $1)=yes
5512 ;;
5513
5514 sunos4*)
5515 if test "x$host_vendor" = xsequent; then
5516 # Use $CC to link under sequent, because it throws in some extra .o
5517 # files that make .init and .fini sections work.
5518 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
5519 else
5520 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
5521 fi
5522 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5523 _LT_TAGVAR(hardcode_direct, $1)=yes
5524 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5525 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5526 ;;
5527
5528 sysv4)
5529 case $host_vendor in
5530 sni)
5531 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5532 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
5533 ;;
5534 siemens)
5535 ## LD is ld it makes a PLAMLIB
5536 ## CC just makes a GrossModule.
5537 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
5538 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
5539 _LT_TAGVAR(hardcode_direct, $1)=no
5540 ;;
5541 motorola)
5542 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5543 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
5544 ;;
5545 esac
5546 runpath_var='LD_RUN_PATH'
5547 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5548 ;;
5549
5550 sysv4.3*)
5551 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5552 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5553 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
5554 ;;
5555
5556 sysv4*MP*)
5557 if test -d /usr/nec; then
5558 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5559 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5560 runpath_var=LD_RUN_PATH
5561 hardcode_runpath_var=yes
5562 _LT_TAGVAR(ld_shlibs, $1)=yes
5563 fi
5564 ;;
5565
5566 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
5567 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5568 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5569 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5570 runpath_var='LD_RUN_PATH'
5571
5572 if test "$GCC" = yes; then
5573 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5574 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5575 else
5576 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5577 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5578 fi
5579 ;;
5580
5581 sysv5* | sco3.2v5* | sco5v6*)
5582 # Note: We can NOT use -z defs as we might desire, because we do not
5583 # link with -lc, and that would cause any symbols used from libc to
5584 # always be unresolved, which means just about no library would
5585 # ever link correctly. If we're not using GNU ld we use -z text
5586 # though, which does catch some bad symbols but isn't as heavy-handed
5587 # as -z defs.
5588 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5589 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
5590 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5591 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5592 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
5593 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5594 _LT_TAGVAR(link_all_deplibs, $1)=yes
5595 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
5596 runpath_var='LD_RUN_PATH'
5597
5598 if test "$GCC" = yes; then
5599 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5600 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5601 else
5602 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5603 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5604 fi
5605 ;;
5606
5607 uts4*)
5608 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5609 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5610 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5611 ;;
5612
5613 *)
5614 _LT_TAGVAR(ld_shlibs, $1)=no
5615 ;;
5616 esac
5617
5618 if test x$host_vendor = xsni; then
5619 case $host in
5620 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5621 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
5622 ;;
5623 esac
5624 fi
5625 fi
5626 ])
5627 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
5628 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
5629
5630 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
5631
5632 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
5633 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
5634 _LT_DECL([], [extract_expsyms_cmds], [2],
5635 [The commands to extract the exported symbol list from a shared archive])
5636
5637 #
5638 # Do we need to explicitly link libc?
5639 #
5640 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
5641 x|xyes)
5642 # Assume -lc should be added
5643 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5644
5645 if test "$enable_shared" = yes && test "$GCC" = yes; then
5646 case $_LT_TAGVAR(archive_cmds, $1) in
5647 *'~'*)
5648 # FIXME: we may have to deal with multi-command sequences.
5649 ;;
5650 '$CC '*)
5651 # Test whether the compiler implicitly links with -lc since on some
5652 # systems, -lgcc has to come before -lc. If gcc already passes -lc
5653 # to ld, don't add -lc before -lgcc.
5654 AC_CACHE_CHECK([whether -lc should be explicitly linked in],
5655 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
5656 [$RM conftest*
5657 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
5658
5659 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
5660 soname=conftest
5661 lib=conftest
5662 libobjs=conftest.$ac_objext
5663 deplibs=
5664 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
5665 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
5666 compiler_flags=-v
5667 linker_flags=-v
5668 verstring=
5669 output_objdir=.
5670 libname=conftest
5671 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
5672 _LT_TAGVAR(allow_undefined_flag, $1)=
5673 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
5674 then
5675 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5676 else
5677 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5678 fi
5679 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
5680 else
5681 cat conftest.err 1>&5
5682 fi
5683 $RM conftest*
5684 ])
5685 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
5686 ;;
5687 esac
5688 fi
5689 ;;
5690 esac
5691
5692 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
5693 [Whether or not to add -lc for building shared libraries])
5694 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
5695 [enable_shared_with_static_runtimes], [0],
5696 [Whether or not to disallow shared libs when runtime libs are static])
5697 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
5698 [Compiler flag to allow reflexive dlopens])
5699 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
5700 [Compiler flag to generate shared objects directly from archives])
5701 _LT_TAGDECL([], [compiler_needs_object], [1],
5702 [Whether the compiler copes with passing no objects directly])
5703 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
5704 [Create an old-style archive from a shared archive])
5705 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
5706 [Create a temporary old-style archive to link instead of a shared archive])
5707 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
5708 _LT_TAGDECL([], [archive_expsym_cmds], [2])
5709 _LT_TAGDECL([], [module_cmds], [2],
5710 [Commands used to build a loadable module if different from building
5711 a shared archive.])
5712 _LT_TAGDECL([], [module_expsym_cmds], [2])
5713 _LT_TAGDECL([], [with_gnu_ld], [1],
5714 [Whether we are building with GNU ld or not])
5715 _LT_TAGDECL([], [allow_undefined_flag], [1],
5716 [Flag that allows shared libraries with undefined symbols to be built])
5717 _LT_TAGDECL([], [no_undefined_flag], [1],
5718 [Flag that enforces no undefined symbols])
5719 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
5720 [Flag to hardcode $libdir into a binary during linking.
5721 This must work even if $libdir does not exist])
5722 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
5723 [Whether we need a single "-rpath" flag with a separated argument])
5724 _LT_TAGDECL([], [hardcode_direct], [0],
5725 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5726 DIR into the resulting binary])
5727 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
5728 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5729 DIR into the resulting binary and the resulting library dependency is
5730 "absolute", i.e impossible to change by setting ${shlibpath_var} if the
5731 library is relocated])
5732 _LT_TAGDECL([], [hardcode_minus_L], [0],
5733 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
5734 into the resulting binary])
5735 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
5736 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
5737 into the resulting binary])
5738 _LT_TAGDECL([], [hardcode_automatic], [0],
5739 [Set to "yes" if building a shared library automatically hardcodes DIR
5740 into the library and all subsequent libraries and executables linked
5741 against it])
5742 _LT_TAGDECL([], [inherit_rpath], [0],
5743 [Set to yes if linker adds runtime paths of dependent libraries
5744 to runtime path list])
5745 _LT_TAGDECL([], [link_all_deplibs], [0],
5746 [Whether libtool must link a program against all its dependency libraries])
5747 _LT_TAGDECL([], [always_export_symbols], [0],
5748 [Set to "yes" if exported symbols are required])
5749 _LT_TAGDECL([], [export_symbols_cmds], [2],
5750 [The commands to list exported symbols])
5751 _LT_TAGDECL([], [exclude_expsyms], [1],
5752 [Symbols that should not be listed in the preloaded symbols])
5753 _LT_TAGDECL([], [include_expsyms], [1],
5754 [Symbols that must always be exported])
5755 _LT_TAGDECL([], [prelink_cmds], [2],
5756 [Commands necessary for linking programs (against libraries) with templates])
5757 _LT_TAGDECL([], [postlink_cmds], [2],
5758 [Commands necessary for finishing linking programs])
5759 _LT_TAGDECL([], [file_list_spec], [1],
5760 [Specify filename containing input files])
5761 dnl FIXME: Not yet implemented
5762 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
5763 dnl [Compiler flag to generate thread safe objects])
5764 ])# _LT_LINKER_SHLIBS
5765
5766
5767 # _LT_LANG_C_CONFIG([TAG])
5768 # ------------------------
5769 # Ensure that the configuration variables for a C compiler are suitably
5770 # defined. These variables are subsequently used by _LT_CONFIG to write
5771 # the compiler configuration to `libtool'.
5772 m4_defun([_LT_LANG_C_CONFIG],
5773 [m4_require([_LT_DECL_EGREP])dnl
5774 lt_save_CC="$CC"
5775 AC_LANG_PUSH(C)
5776
5777 # Source file extension for C test sources.
5778 ac_ext=c
5779
5780 # Object file extension for compiled C test sources.
5781 objext=o
5782 _LT_TAGVAR(objext, $1)=$objext
5783
5784 # Code to be used in simple compile tests
5785 lt_simple_compile_test_code="int some_variable = 0;"
5786
5787 # Code to be used in simple link tests
5788 lt_simple_link_test_code='int main(){return(0);}'
5789
5790 _LT_TAG_COMPILER
5791 # Save the default compiler, since it gets overwritten when the other
5792 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
5793 compiler_DEFAULT=$CC
5794
5795 # save warnings/boilerplate of simple test code
5796 _LT_COMPILER_BOILERPLATE
5797 _LT_LINKER_BOILERPLATE
5798
5799 ## CAVEAT EMPTOR:
5800 ## There is no encapsulation within the following macros, do not change
5801 ## the running order or otherwise move them around unless you know exactly
5802 ## what you are doing...
5803 if test -n "$compiler"; then
5804 _LT_COMPILER_NO_RTTI($1)
5805 _LT_COMPILER_PIC($1)
5806 _LT_COMPILER_C_O($1)
5807 _LT_COMPILER_FILE_LOCKS($1)
5808 _LT_LINKER_SHLIBS($1)
5809 _LT_SYS_DYNAMIC_LINKER($1)
5810 _LT_LINKER_HARDCODE_LIBPATH($1)
5811 LT_SYS_DLOPEN_SELF
5812 _LT_CMD_STRIPLIB
5813
5814 # Report which library types will actually be built
5815 AC_MSG_CHECKING([if libtool supports shared libraries])
5816 AC_MSG_RESULT([$can_build_shared])
5817
5818 AC_MSG_CHECKING([whether to build shared libraries])
5819 test "$can_build_shared" = "no" && enable_shared=no
5820
5821 # On AIX, shared libraries and static libraries use the same namespace, and
5822 # are all built from PIC.
5823 case $host_os in
5824 aix3*)
5825 test "$enable_shared" = yes && enable_static=no
5826 if test -n "$RANLIB"; then
5827 archive_cmds="$archive_cmds~\$RANLIB \$lib"
5828 postinstall_cmds='$RANLIB $lib'
5829 fi
5830 ;;
5831
5832 aix[[4-9]]*)
5833 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
5834 test "$enable_shared" = yes && enable_static=no
5835 fi
5836 ;;
5837 esac
5838 AC_MSG_RESULT([$enable_shared])
5839
5840 AC_MSG_CHECKING([whether to build static libraries])
5841 # Make sure either enable_shared or enable_static is yes.
5842 test "$enable_shared" = yes || enable_static=yes
5843 AC_MSG_RESULT([$enable_static])
5844
5845 _LT_CONFIG($1)
5846 fi
5847 AC_LANG_POP
5848 CC="$lt_save_CC"
5849 ])# _LT_LANG_C_CONFIG
5850
5851
5852 # _LT_LANG_CXX_CONFIG([TAG])
5853 # --------------------------
5854 # Ensure that the configuration variables for a C++ compiler are suitably
5855 # defined. These variables are subsequently used by _LT_CONFIG to write
5856 # the compiler configuration to `libtool'.
5857 m4_defun([_LT_LANG_CXX_CONFIG],
5858 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5859 m4_require([_LT_DECL_EGREP])dnl
5860 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5861 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
5862 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
5863 (test "X$CXX" != "Xg++"))) ; then
5864 AC_PROG_CXXCPP
5865 else
5866 _lt_caught_CXX_error=yes
5867 fi
5868
5869 AC_LANG_PUSH(C++)
5870 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5871 _LT_TAGVAR(allow_undefined_flag, $1)=
5872 _LT_TAGVAR(always_export_symbols, $1)=no
5873 _LT_TAGVAR(archive_expsym_cmds, $1)=
5874 _LT_TAGVAR(compiler_needs_object, $1)=no
5875 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5876 _LT_TAGVAR(hardcode_direct, $1)=no
5877 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5878 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5879 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5880 _LT_TAGVAR(hardcode_minus_L, $1)=no
5881 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5882 _LT_TAGVAR(hardcode_automatic, $1)=no
5883 _LT_TAGVAR(inherit_rpath, $1)=no
5884 _LT_TAGVAR(module_cmds, $1)=
5885 _LT_TAGVAR(module_expsym_cmds, $1)=
5886 _LT_TAGVAR(link_all_deplibs, $1)=unknown
5887 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5888 _LT_TAGVAR(reload_flag, $1)=$reload_flag
5889 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
5890 _LT_TAGVAR(no_undefined_flag, $1)=
5891 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5892 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5893
5894 # Source file extension for C++ test sources.
5895 ac_ext=cpp
5896
5897 # Object file extension for compiled C++ test sources.
5898 objext=o
5899 _LT_TAGVAR(objext, $1)=$objext
5900
5901 # No sense in running all these tests if we already determined that
5902 # the CXX compiler isn't working. Some variables (like enable_shared)
5903 # are currently assumed to apply to all compilers on this platform,
5904 # and will be corrupted by setting them based on a non-working compiler.
5905 if test "$_lt_caught_CXX_error" != yes; then
5906 # Code to be used in simple compile tests
5907 lt_simple_compile_test_code="int some_variable = 0;"
5908
5909 # Code to be used in simple link tests
5910 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
5911
5912 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
5913 _LT_TAG_COMPILER
5914
5915 # save warnings/boilerplate of simple test code
5916 _LT_COMPILER_BOILERPLATE
5917 _LT_LINKER_BOILERPLATE
5918
5919 # Allow CC to be a program name with arguments.
5920 lt_save_CC=$CC
5921 lt_save_CFLAGS=$CFLAGS
5922 lt_save_LD=$LD
5923 lt_save_GCC=$GCC
5924 GCC=$GXX
5925 lt_save_with_gnu_ld=$with_gnu_ld
5926 lt_save_path_LD=$lt_cv_path_LD
5927 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
5928 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
5929 else
5930 $as_unset lt_cv_prog_gnu_ld
5931 fi
5932 if test -n "${lt_cv_path_LDCXX+set}"; then
5933 lt_cv_path_LD=$lt_cv_path_LDCXX
5934 else
5935 $as_unset lt_cv_path_LD
5936 fi
5937 test -z "${LDCXX+set}" || LD=$LDCXX
5938 CC=${CXX-"c++"}
5939 CFLAGS=$CXXFLAGS
5940 compiler=$CC
5941 _LT_TAGVAR(compiler, $1)=$CC
5942 _LT_CC_BASENAME([$compiler])
5943
5944 if test -n "$compiler"; then
5945 # We don't want -fno-exception when compiling C++ code, so set the
5946 # no_builtin_flag separately
5947 if test "$GXX" = yes; then
5948 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5949 else
5950 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5951 fi
5952
5953 if test "$GXX" = yes; then
5954 # Set up default GNU C++ configuration
5955
5956 LT_PATH_LD
5957
5958 # Check if GNU C++ uses GNU ld as the underlying linker, since the
5959 # archiving commands below assume that GNU ld is being used.
5960 if test "$with_gnu_ld" = yes; then
5961 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
5962 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5963
5964 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5965 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5966
5967 # If archive_cmds runs LD, not CC, wlarc should be empty
5968 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
5969 # investigate it a little bit more. (MM)
5970 wlarc='${wl}'
5971
5972 # ancient GNU ld didn't support --whole-archive et. al.
5973 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
5974 $GREP 'no-whole-archive' > /dev/null; then
5975 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5976 else
5977 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5978 fi
5979 else
5980 with_gnu_ld=no
5981 wlarc=
5982
5983 # A generic and very simple default shared library creation
5984 # command for GNU C++ for the case where it uses the native
5985 # linker, instead of GNU ld. If possible, this setting should
5986 # overridden to take advantage of the native linker features on
5987 # the platform it is being used on.
5988 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
5989 fi
5990
5991 # Commands to make compiler produce verbose output that lists
5992 # what "hidden" libraries, object files and flags are used when
5993 # linking a shared library.
5994 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
5995
5996 else
5997 GXX=no
5998 with_gnu_ld=no
5999 wlarc=
6000 fi
6001
6002 # PORTME: fill in a description of your system's C++ link characteristics
6003 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6004 _LT_TAGVAR(ld_shlibs, $1)=yes
6005 case $host_os in
6006 aix3*)
6007 # FIXME: insert proper C++ library support
6008 _LT_TAGVAR(ld_shlibs, $1)=no
6009 ;;
6010 aix[[4-9]]*)
6011 if test "$host_cpu" = ia64; then
6012 # On IA64, the linker does run time linking by default, so we don't
6013 # have to do anything special.
6014 aix_use_runtimelinking=no
6015 exp_sym_flag='-Bexport'
6016 no_entry_flag=""
6017 else
6018 aix_use_runtimelinking=no
6019
6020 # Test if we are trying to use run time linking or normal
6021 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6022 # need to do runtime linking.
6023 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6024 for ld_flag in $LDFLAGS; do
6025 case $ld_flag in
6026 *-brtl*)
6027 aix_use_runtimelinking=yes
6028 break
6029 ;;
6030 esac
6031 done
6032 ;;
6033 esac
6034
6035 exp_sym_flag='-bexport'
6036 no_entry_flag='-bnoentry'
6037 fi
6038
6039 # When large executables or shared objects are built, AIX ld can
6040 # have problems creating the table of contents. If linking a library
6041 # or program results in "error TOC overflow" add -mminimal-toc to
6042 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6043 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6044
6045 _LT_TAGVAR(archive_cmds, $1)=''
6046 _LT_TAGVAR(hardcode_direct, $1)=yes
6047 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6048 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6049 _LT_TAGVAR(link_all_deplibs, $1)=yes
6050 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6051
6052 if test "$GXX" = yes; then
6053 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6054 # We only want to do this on AIX 4.2 and lower, the check
6055 # below for broken collect2 doesn't work under 4.3+
6056 collect2name=`${CC} -print-prog-name=collect2`
6057 if test -f "$collect2name" &&
6058 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6059 then
6060 # We have reworked collect2
6061 :
6062 else
6063 # We have old collect2
6064 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6065 # It fails to find uninstalled libraries when the uninstalled
6066 # path is not listed in the libpath. Setting hardcode_minus_L
6067 # to unsupported forces relinking
6068 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6069 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6070 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6071 fi
6072 esac
6073 shared_flag='-shared'
6074 if test "$aix_use_runtimelinking" = yes; then
6075 shared_flag="$shared_flag "'${wl}-G'
6076 fi
6077 else
6078 # not using gcc
6079 if test "$host_cpu" = ia64; then
6080 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6081 # chokes on -Wl,-G. The following line is correct:
6082 shared_flag='-G'
6083 else
6084 if test "$aix_use_runtimelinking" = yes; then
6085 shared_flag='${wl}-G'
6086 else
6087 shared_flag='${wl}-bM:SRE'
6088 fi
6089 fi
6090 fi
6091
6092 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6093 # It seems that -bexpall does not export symbols beginning with
6094 # underscore (_), so it is better to generate a list of symbols to
6095 # export.
6096 _LT_TAGVAR(always_export_symbols, $1)=yes
6097 if test "$aix_use_runtimelinking" = yes; then
6098 # Warning - without using the other runtime loading flags (-brtl),
6099 # -berok will link without error, but may produce a broken library.
6100 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6101 # Determine the default libpath from the value encoded in an empty
6102 # executable.
6103 _LT_SYS_MODULE_PATH_AIX([$1])
6104 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6105
6106 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6107 else
6108 if test "$host_cpu" = ia64; then
6109 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6110 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6111 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
6112 else
6113 # Determine the default libpath from the value encoded in an
6114 # empty executable.
6115 _LT_SYS_MODULE_PATH_AIX([$1])
6116 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6117 # Warning - without using the other run time loading flags,
6118 # -berok will link without error, but may produce a broken library.
6119 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6120 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6121 if test "$with_gnu_ld" = yes; then
6122 # We only use this code for GNU lds that support --whole-archive.
6123 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6124 else
6125 # Exported symbols can be pulled into shared objects from archives
6126 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6127 fi
6128 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6129 # This is similar to how AIX traditionally builds its shared
6130 # libraries.
6131 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6132 fi
6133 fi
6134 ;;
6135
6136 beos*)
6137 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6138 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6139 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6140 # support --undefined. This deserves some investigation. FIXME
6141 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6142 else
6143 _LT_TAGVAR(ld_shlibs, $1)=no
6144 fi
6145 ;;
6146
6147 chorus*)
6148 case $cc_basename in
6149 *)
6150 # FIXME: insert proper C++ library support
6151 _LT_TAGVAR(ld_shlibs, $1)=no
6152 ;;
6153 esac
6154 ;;
6155
6156 cygwin* | mingw* | pw32* | cegcc*)
6157 case $GXX,$cc_basename in
6158 ,cl* | no,cl*)
6159 # Native MSVC
6160 # hardcode_libdir_flag_spec is actually meaningless, as there is
6161 # no search path for DLLs.
6162 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6163 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6164 _LT_TAGVAR(always_export_symbols, $1)=yes
6165 _LT_TAGVAR(file_list_spec, $1)='@'
6166 # Tell ltmain to make .lib files, not .a files.
6167 libext=lib
6168 # Tell ltmain to make .dll files, not .so files.
6169 shrext_cmds=".dll"
6170 # FIXME: Setting linknames here is a bad hack.
6171 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
6172 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
6173 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
6174 else
6175 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
6176 fi~
6177 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6178 linknames='
6179 # The linker will not automatically build a static lib if we build a DLL.
6180 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6181 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6182 # Don't use ranlib
6183 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6184 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6185 lt_tool_outputfile="@TOOL_OUTPUT@"~
6186 case $lt_outputfile in
6187 *.exe|*.EXE) ;;
6188 *)
6189 lt_outputfile="$lt_outputfile.exe"
6190 lt_tool_outputfile="$lt_tool_outputfile.exe"
6191 ;;
6192 esac~
6193 func_to_tool_file "$lt_outputfile"~
6194 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
6195 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6196 $RM "$lt_outputfile.manifest";
6197 fi'
6198 ;;
6199 *)
6200 # g++
6201 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6202 # as there is no search path for DLLs.
6203 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6204 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
6205 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6206 _LT_TAGVAR(always_export_symbols, $1)=no
6207 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6208
6209 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
6210 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6211 # If the export-symbols file already is a .def file (1st line
6212 # is EXPORTS), use it as is; otherwise, prepend...
6213 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED \"$sed_uncomment_deffile\" $export_symbols | $SED 1q`" = xEXPORTS; then
6214 cp $export_symbols $output_objdir/$soname.def;
6215 else
6216 echo EXPORTS > $output_objdir/$soname.def;
6217 cat $export_symbols >> $output_objdir/$soname.def;
6218 fi~
6219 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6220 else
6221 _LT_TAGVAR(ld_shlibs, $1)=no
6222 fi
6223 ;;
6224 esac
6225 ;;
6226 darwin* | rhapsody*)
6227 _LT_DARWIN_LINKER_FEATURES($1)
6228 ;;
6229
6230 dgux*)
6231 case $cc_basename in
6232 ec++*)
6233 # FIXME: insert proper C++ library support
6234 _LT_TAGVAR(ld_shlibs, $1)=no
6235 ;;
6236 ghcx*)
6237 # Green Hills C++ Compiler
6238 # FIXME: insert proper C++ library support
6239 _LT_TAGVAR(ld_shlibs, $1)=no
6240 ;;
6241 *)
6242 # FIXME: insert proper C++ library support
6243 _LT_TAGVAR(ld_shlibs, $1)=no
6244 ;;
6245 esac
6246 ;;
6247
6248 freebsd2.*)
6249 # C++ shared libraries reported to be fairly broken before
6250 # switch to ELF
6251 _LT_TAGVAR(ld_shlibs, $1)=no
6252 ;;
6253
6254 freebsd-elf*)
6255 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6256 ;;
6257
6258 freebsd* | dragonfly*)
6259 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
6260 # conventions
6261 _LT_TAGVAR(ld_shlibs, $1)=yes
6262 ;;
6263
6264 gnu*)
6265 ;;
6266
6267 haiku*)
6268 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6269 _LT_TAGVAR(link_all_deplibs, $1)=yes
6270 ;;
6271
6272 hpux9*)
6273 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6274 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6275 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6276 _LT_TAGVAR(hardcode_direct, $1)=yes
6277 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6278 # but as the default
6279 # location of the library.
6280
6281 case $cc_basename in
6282 CC*)
6283 # FIXME: insert proper C++ library support
6284 _LT_TAGVAR(ld_shlibs, $1)=no
6285 ;;
6286 aCC*)
6287 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6288 # Commands to make compiler produce verbose output that lists
6289 # what "hidden" libraries, object files and flags are used when
6290 # linking a shared library.
6291 #
6292 # There doesn't appear to be a way to prevent this compiler from
6293 # explicitly linking system object files so we need to strip them
6294 # from the output so that they don't get included in the library
6295 # dependencies.
6296 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6297 ;;
6298 *)
6299 if test "$GXX" = yes; then
6300 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6301 else
6302 # FIXME: insert proper C++ library support
6303 _LT_TAGVAR(ld_shlibs, $1)=no
6304 fi
6305 ;;
6306 esac
6307 ;;
6308
6309 hpux10*|hpux11*)
6310 if test $with_gnu_ld = no; then
6311 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6312 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6313
6314 case $host_cpu in
6315 hppa*64*|ia64*)
6316 ;;
6317 *)
6318 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6319 ;;
6320 esac
6321 fi
6322 case $host_cpu in
6323 hppa*64*|ia64*)
6324 _LT_TAGVAR(hardcode_direct, $1)=no
6325 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6326 ;;
6327 *)
6328 _LT_TAGVAR(hardcode_direct, $1)=yes
6329 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6330 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6331 # but as the default
6332 # location of the library.
6333 ;;
6334 esac
6335
6336 case $cc_basename in
6337 CC*)
6338 # FIXME: insert proper C++ library support
6339 _LT_TAGVAR(ld_shlibs, $1)=no
6340 ;;
6341 aCC*)
6342 case $host_cpu in
6343 hppa*64*)
6344 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6345 ;;
6346 ia64*)
6347 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6348 ;;
6349 *)
6350 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6351 ;;
6352 esac
6353 # Commands to make compiler produce verbose output that lists
6354 # what "hidden" libraries, object files and flags are used when
6355 # linking a shared library.
6356 #
6357 # There doesn't appear to be a way to prevent this compiler from
6358 # explicitly linking system object files so we need to strip them
6359 # from the output so that they don't get included in the library
6360 # dependencies.
6361 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6362 ;;
6363 *)
6364 if test "$GXX" = yes; then
6365 if test $with_gnu_ld = no; then
6366 case $host_cpu in
6367 hppa*64*)
6368 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6369 ;;
6370 ia64*)
6371 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6372 ;;
6373 *)
6374 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6375 ;;
6376 esac
6377 fi
6378 else
6379 # FIXME: insert proper C++ library support
6380 _LT_TAGVAR(ld_shlibs, $1)=no
6381 fi
6382 ;;
6383 esac
6384 ;;
6385
6386 interix[[3-9]]*)
6387 _LT_TAGVAR(hardcode_direct, $1)=no
6388 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6389 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6390 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6391 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6392 # Instead, shared libraries are loaded at an image base (0x10000000 by
6393 # default) and relocated if they conflict, which is a slow very memory
6394 # consuming and fragmenting process. To avoid this, we pick a random,
6395 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6396 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6397 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6398 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6399 ;;
6400 irix5* | irix6*)
6401 case $cc_basename in
6402 CC*)
6403 # SGI C++
6404 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6405
6406 # Archives containing C++ object files must be created using
6407 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
6408 # necessary to make sure instantiated templates are included
6409 # in the archive.
6410 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
6411 ;;
6412 *)
6413 if test "$GXX" = yes; then
6414 if test "$with_gnu_ld" = no; then
6415 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6416 else
6417 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
6418 fi
6419 fi
6420 _LT_TAGVAR(link_all_deplibs, $1)=yes
6421 ;;
6422 esac
6423 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6424 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6425 _LT_TAGVAR(inherit_rpath, $1)=yes
6426 ;;
6427
6428 linux* | k*bsd*-gnu | kopensolaris*-gnu)
6429 case $cc_basename in
6430 KCC*)
6431 # Kuck and Associates, Inc. (KAI) C++ Compiler
6432
6433 # KCC will only create a shared library if the output file
6434 # ends with ".so" (or ".sl" for HP-UX), so rename the library
6435 # to its proper name (with version) after linking.
6436 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
6437 _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
6438 # Commands to make compiler produce verbose output that lists
6439 # what "hidden" libraries, object files and flags are used when
6440 # linking a shared library.
6441 #
6442 # There doesn't appear to be a way to prevent this compiler from
6443 # explicitly linking system object files so we need to strip them
6444 # from the output so that they don't get included in the library
6445 # dependencies.
6446 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6447
6448 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6449 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6450
6451 # Archives containing C++ object files must be created using
6452 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
6453 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
6454 ;;
6455 icpc* | ecpc* )
6456 # Intel C++
6457 with_gnu_ld=yes
6458 # version 8.0 and above of icpc choke on multiply defined symbols
6459 # if we add $predep_objects and $postdep_objects, however 7.1 and
6460 # earlier do not add the objects themselves.
6461 case `$CC -V 2>&1` in
6462 *"Version 7."*)
6463 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6464 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6465 ;;
6466 *) # Version 8.0 or newer
6467 tmp_idyn=
6468 case $host_cpu in
6469 ia64*) tmp_idyn=' -i_dynamic';;
6470 esac
6471 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6472 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6473 ;;
6474 esac
6475 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6476 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6477 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6478 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6479 ;;
6480 pgCC* | pgcpp*)
6481 # Portland Group C++ compiler
6482 case `$CC -V` in
6483 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
6484 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
6485 rm -rf $tpldir~
6486 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6487 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
6488 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
6489 rm -rf $tpldir~
6490 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6491 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
6492 $RANLIB $oldlib'
6493 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6494 rm -rf $tpldir~
6495 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6496 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6497 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6498 rm -rf $tpldir~
6499 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6500 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6501 ;;
6502 *) # Version 6 and above use weak symbols
6503 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6504 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6505 ;;
6506 esac
6507
6508 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6509 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6510 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6511 ;;
6512 cxx*)
6513 # Compaq C++
6514 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6515 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
6516
6517 runpath_var=LD_RUN_PATH
6518 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6519 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6520
6521 # Commands to make compiler produce verbose output that lists
6522 # what "hidden" libraries, object files and flags are used when
6523 # linking a shared library.
6524 #
6525 # There doesn't appear to be a way to prevent this compiler from
6526 # explicitly linking system object files so we need to strip them
6527 # from the output so that they don't get included in the library
6528 # dependencies.
6529 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
6530 ;;
6531 xl* | mpixl* | bgxl*)
6532 # IBM XL 8.0 on PPC, with GNU ld
6533 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6534 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6535 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6536 if test "x$supports_anon_versioning" = xyes; then
6537 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6538 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6539 echo "local: *; };" >> $output_objdir/$libname.ver~
6540 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6541 fi
6542 ;;
6543 *)
6544 case `$CC -V 2>&1 | sed 5q` in
6545 *Sun\ C*)
6546 # Sun C++ 5.9
6547 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6548 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6549 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
6550 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6551 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6552 _LT_TAGVAR(compiler_needs_object, $1)=yes
6553
6554 # Not sure whether something based on
6555 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
6556 # would be better.
6557 output_verbose_link_cmd='func_echo_all'
6558
6559 # Archives containing C++ object files must be created using
6560 # "CC -xar", where "CC" is the Sun C++ compiler. This is
6561 # necessary to make sure instantiated templates are included
6562 # in the archive.
6563 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6564 ;;
6565 esac
6566 ;;
6567 esac
6568 ;;
6569
6570 lynxos*)
6571 # FIXME: insert proper C++ library support
6572 _LT_TAGVAR(ld_shlibs, $1)=no
6573 ;;
6574
6575 m88k*)
6576 # FIXME: insert proper C++ library support
6577 _LT_TAGVAR(ld_shlibs, $1)=no
6578 ;;
6579
6580 mvs*)
6581 case $cc_basename in
6582 cxx*)
6583 # FIXME: insert proper C++ library support
6584 _LT_TAGVAR(ld_shlibs, $1)=no
6585 ;;
6586 *)
6587 # FIXME: insert proper C++ library support
6588 _LT_TAGVAR(ld_shlibs, $1)=no
6589 ;;
6590 esac
6591 ;;
6592
6593 netbsd*)
6594 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6595 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
6596 wlarc=
6597 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6598 _LT_TAGVAR(hardcode_direct, $1)=yes
6599 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6600 fi
6601 # Workaround some broken pre-1.5 toolchains
6602 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
6603 ;;
6604
6605 *nto* | *qnx*)
6606 _LT_TAGVAR(ld_shlibs, $1)=yes
6607 ;;
6608
6609 openbsd2*)
6610 # C++ shared libraries are fairly broken
6611 _LT_TAGVAR(ld_shlibs, $1)=no
6612 ;;
6613
6614 openbsd*)
6615 if test -f /usr/libexec/ld.so; then
6616 _LT_TAGVAR(hardcode_direct, $1)=yes
6617 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6618 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6619 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6620 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6621 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6622 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
6623 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6624 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6625 fi
6626 output_verbose_link_cmd=func_echo_all
6627 else
6628 _LT_TAGVAR(ld_shlibs, $1)=no
6629 fi
6630 ;;
6631
6632 osf3* | osf4* | osf5*)
6633 case $cc_basename in
6634 KCC*)
6635 # Kuck and Associates, Inc. (KAI) C++ Compiler
6636
6637 # KCC will only create a shared library if the output file
6638 # ends with ".so" (or ".sl" for HP-UX), so rename the library
6639 # to its proper name (with version) after linking.
6640 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
6641
6642 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6643 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6644
6645 # Archives containing C++ object files must be created using
6646 # the KAI C++ compiler.
6647 case $host in
6648 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
6649 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
6650 esac
6651 ;;
6652 RCC*)
6653 # Rational C++ 2.4.1
6654 # FIXME: insert proper C++ library support
6655 _LT_TAGVAR(ld_shlibs, $1)=no
6656 ;;
6657 cxx*)
6658 case $host in
6659 osf3*)
6660 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6661 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6662 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6663 ;;
6664 *)
6665 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6666 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6667 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
6668 echo "-hidden">> $lib.exp~
6669 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
6670 $RM $lib.exp'
6671 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6672 ;;
6673 esac
6674
6675 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6676
6677 # Commands to make compiler produce verbose output that lists
6678 # what "hidden" libraries, object files and flags are used when
6679 # linking a shared library.
6680 #
6681 # There doesn't appear to be a way to prevent this compiler from
6682 # explicitly linking system object files so we need to strip them
6683 # from the output so that they don't get included in the library
6684 # dependencies.
6685 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6686 ;;
6687 *)
6688 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6689 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6690 case $host in
6691 osf3*)
6692 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6693 ;;
6694 *)
6695 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6696 ;;
6697 esac
6698
6699 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6700 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6701
6702 # Commands to make compiler produce verbose output that lists
6703 # what "hidden" libraries, object files and flags are used when
6704 # linking a shared library.
6705 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6706
6707 else
6708 # FIXME: insert proper C++ library support
6709 _LT_TAGVAR(ld_shlibs, $1)=no
6710 fi
6711 ;;
6712 esac
6713 ;;
6714
6715 psos*)
6716 # FIXME: insert proper C++ library support
6717 _LT_TAGVAR(ld_shlibs, $1)=no
6718 ;;
6719
6720 sunos4*)
6721 case $cc_basename in
6722 CC*)
6723 # Sun C++ 4.x
6724 # FIXME: insert proper C++ library support
6725 _LT_TAGVAR(ld_shlibs, $1)=no
6726 ;;
6727 lcc*)
6728 # Lucid
6729 # FIXME: insert proper C++ library support
6730 _LT_TAGVAR(ld_shlibs, $1)=no
6731 ;;
6732 *)
6733 # FIXME: insert proper C++ library support
6734 _LT_TAGVAR(ld_shlibs, $1)=no
6735 ;;
6736 esac
6737 ;;
6738
6739 solaris*)
6740 case $cc_basename in
6741 CC* | sunCC*)
6742 # Sun C++ 4.2, 5.x and Centerline C++
6743 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
6744 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6745 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6746 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6747 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6748
6749 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6750 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6751 case $host_os in
6752 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6753 *)
6754 # The compiler driver will combine and reorder linker options,
6755 # but understands `-z linker_flag'.
6756 # Supported since Solaris 2.6 (maybe 2.5.1?)
6757 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6758 ;;
6759 esac
6760 _LT_TAGVAR(link_all_deplibs, $1)=yes
6761
6762 output_verbose_link_cmd='func_echo_all'
6763
6764 # Archives containing C++ object files must be created using
6765 # "CC -xar", where "CC" is the Sun C++ compiler. This is
6766 # necessary to make sure instantiated templates are included
6767 # in the archive.
6768 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6769 ;;
6770 gcx*)
6771 # Green Hills C++ Compiler
6772 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6773
6774 # The C++ compiler must be used to create the archive.
6775 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
6776 ;;
6777 *)
6778 # GNU C++ compiler with Solaris linker
6779 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6780 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
6781 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
6782 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6783 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6784 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6785
6786 # Commands to make compiler produce verbose output that lists
6787 # what "hidden" libraries, object files and flags are used when
6788 # linking a shared library.
6789 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6790 else
6791 # g++ 2.7 appears to require `-G' NOT `-shared' on this
6792 # platform.
6793 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6794 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6795 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6796
6797 # Commands to make compiler produce verbose output that lists
6798 # what "hidden" libraries, object files and flags are used when
6799 # linking a shared library.
6800 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6801 fi
6802
6803 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
6804 case $host_os in
6805 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6806 *)
6807 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6808 ;;
6809 esac
6810 fi
6811 ;;
6812 esac
6813 ;;
6814
6815 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6816 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6817 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6818 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6819 runpath_var='LD_RUN_PATH'
6820
6821 case $cc_basename in
6822 CC*)
6823 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6824 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6825 ;;
6826 *)
6827 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6828 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6829 ;;
6830 esac
6831 ;;
6832
6833 sysv5* | sco3.2v5* | sco5v6*)
6834 # Note: We can NOT use -z defs as we might desire, because we do not
6835 # link with -lc, and that would cause any symbols used from libc to
6836 # always be unresolved, which means just about no library would
6837 # ever link correctly. If we're not using GNU ld we use -z text
6838 # though, which does catch some bad symbols but isn't as heavy-handed
6839 # as -z defs.
6840 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6841 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6842 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6843 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6844 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6845 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6846 _LT_TAGVAR(link_all_deplibs, $1)=yes
6847 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6848 runpath_var='LD_RUN_PATH'
6849
6850 case $cc_basename in
6851 CC*)
6852 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6853 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6854 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
6855 '"$_LT_TAGVAR(old_archive_cmds, $1)"
6856 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
6857 '"$_LT_TAGVAR(reload_cmds, $1)"
6858 ;;
6859 *)
6860 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6861 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6862 ;;
6863 esac
6864 ;;
6865
6866 tandem*)
6867 case $cc_basename in
6868 NCC*)
6869 # NonStop-UX NCC 3.20
6870 # FIXME: insert proper C++ library support
6871 _LT_TAGVAR(ld_shlibs, $1)=no
6872 ;;
6873 *)
6874 # FIXME: insert proper C++ library support
6875 _LT_TAGVAR(ld_shlibs, $1)=no
6876 ;;
6877 esac
6878 ;;
6879
6880 vxworks*)
6881 # FIXME: insert proper C++ library support
6882 _LT_TAGVAR(ld_shlibs, $1)=no
6883 ;;
6884
6885 *)
6886 # FIXME: insert proper C++ library support
6887 _LT_TAGVAR(ld_shlibs, $1)=no
6888 ;;
6889 esac
6890
6891 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6892 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6893
6894 _LT_TAGVAR(GCC, $1)="$GXX"
6895 _LT_TAGVAR(LD, $1)="$LD"
6896
6897 ## CAVEAT EMPTOR:
6898 ## There is no encapsulation within the following macros, do not change
6899 ## the running order or otherwise move them around unless you know exactly
6900 ## what you are doing...
6901 _LT_SYS_HIDDEN_LIBDEPS($1)
6902 _LT_COMPILER_PIC($1)
6903 _LT_COMPILER_C_O($1)
6904 _LT_COMPILER_FILE_LOCKS($1)
6905 _LT_LINKER_SHLIBS($1)
6906 _LT_SYS_DYNAMIC_LINKER($1)
6907 _LT_LINKER_HARDCODE_LIBPATH($1)
6908
6909 _LT_CONFIG($1)
6910 fi # test -n "$compiler"
6911
6912 CC=$lt_save_CC
6913 CFLAGS=$lt_save_CFLAGS
6914 LDCXX=$LD
6915 LD=$lt_save_LD
6916 GCC=$lt_save_GCC
6917 with_gnu_ld=$lt_save_with_gnu_ld
6918 lt_cv_path_LDCXX=$lt_cv_path_LD
6919 lt_cv_path_LD=$lt_save_path_LD
6920 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
6921 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
6922 fi # test "$_lt_caught_CXX_error" != yes
6923
6924 AC_LANG_POP
6925 ])# _LT_LANG_CXX_CONFIG
6926
6927
6928 # _LT_FUNC_STRIPNAME_CNF
6929 # ----------------------
6930 # func_stripname_cnf prefix suffix name
6931 # strip PREFIX and SUFFIX off of NAME.
6932 # PREFIX and SUFFIX must not contain globbing or regex special
6933 # characters, hashes, percent signs, but SUFFIX may contain a leading
6934 # dot (in which case that matches only a dot).
6935 #
6936 # This function is identical to the (non-XSI) version of func_stripname,
6937 # except this one can be used by m4 code that may be executed by configure,
6938 # rather than the libtool script.
6939 m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
6940 AC_REQUIRE([_LT_DECL_SED])
6941 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
6942 func_stripname_cnf ()
6943 {
6944 case ${2} in
6945 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
6946 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
6947 esac
6948 } # func_stripname_cnf
6949 ])# _LT_FUNC_STRIPNAME_CNF
6950
6951 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
6952 # ---------------------------------
6953 # Figure out "hidden" library dependencies from verbose
6954 # compiler output when linking a shared library.
6955 # Parse the compiler output and extract the necessary
6956 # objects, libraries and library flags.
6957 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
6958 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6959 AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
6960 # Dependencies to place before and after the object being linked:
6961 _LT_TAGVAR(predep_objects, $1)=
6962 _LT_TAGVAR(postdep_objects, $1)=
6963 _LT_TAGVAR(predeps, $1)=
6964 _LT_TAGVAR(postdeps, $1)=
6965 _LT_TAGVAR(compiler_lib_search_path, $1)=
6966
6967 dnl we can't use the lt_simple_compile_test_code here,
6968 dnl because it contains code intended for an executable,
6969 dnl not a library. It's possible we should let each
6970 dnl tag define a new lt_????_link_test_code variable,
6971 dnl but it's only used here...
6972 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
6973 int a;
6974 void foo (void) { a = 0; }
6975 _LT_EOF
6976 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
6977 class Foo
6978 {
6979 public:
6980 Foo (void) { a = 0; }
6981 private:
6982 int a;
6983 };
6984 _LT_EOF
6985 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
6986 subroutine foo
6987 implicit none
6988 integer*4 a
6989 a=0
6990 return
6991 end
6992 _LT_EOF
6993 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
6994 subroutine foo
6995 implicit none
6996 integer a
6997 a=0
6998 return
6999 end
7000 _LT_EOF
7001 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
7002 public class foo {
7003 private int a;
7004 public void bar (void) {
7005 a = 0;
7006 }
7007 };
7008 _LT_EOF
7009 ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
7010 package foo
7011 func foo() {
7012 }
7013 _LT_EOF
7014 ])
7015
7016 _lt_libdeps_save_CFLAGS=$CFLAGS
7017 case "$CC $CFLAGS " in #(
7018 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
7019 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
7020 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
7021 esac
7022
7023 dnl Parse the compiler output and extract the necessary
7024 dnl objects, libraries and library flags.
7025 if AC_TRY_EVAL(ac_compile); then
7026 # Parse the compiler output and extract the necessary
7027 # objects, libraries and library flags.
7028
7029 # Sentinel used to keep track of whether or not we are before
7030 # the conftest object file.
7031 pre_test_object_deps_done=no
7032
7033 for p in `eval "$output_verbose_link_cmd"`; do
7034 case ${prev}${p} in
7035
7036 -L* | -R* | -l*)
7037 # Some compilers place space between "-{L,R}" and the path.
7038 # Remove the space.
7039 if test $p = "-L" ||
7040 test $p = "-R"; then
7041 prev=$p
7042 continue
7043 fi
7044
7045 # Expand the sysroot to ease extracting the directories later.
7046 if test -z "$prev"; then
7047 case $p in
7048 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
7049 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
7050 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
7051 esac
7052 fi
7053 case $p in
7054 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
7055 esac
7056 if test "$pre_test_object_deps_done" = no; then
7057 case ${prev} in
7058 -L | -R)
7059 # Internal compiler library paths should come after those
7060 # provided the user. The postdeps already come after the
7061 # user supplied libs so there is no need to process them.
7062 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7063 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
7064 else
7065 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
7066 fi
7067 ;;
7068 # The "-l" case would never come before the object being
7069 # linked, so don't bother handling this case.
7070 esac
7071 else
7072 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7073 _LT_TAGVAR(postdeps, $1)="${prev}${p}"
7074 else
7075 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
7076 fi
7077 fi
7078 prev=
7079 ;;
7080
7081 *.lto.$objext) ;; # Ignore GCC LTO objects
7082 *.$objext)
7083 # This assumes that the test object file only shows up
7084 # once in the compiler output.
7085 if test "$p" = "conftest.$objext"; then
7086 pre_test_object_deps_done=yes
7087 continue
7088 fi
7089
7090 if test "$pre_test_object_deps_done" = no; then
7091 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
7092 _LT_TAGVAR(predep_objects, $1)="$p"
7093 else
7094 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
7095 fi
7096 else
7097 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
7098 _LT_TAGVAR(postdep_objects, $1)="$p"
7099 else
7100 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
7101 fi
7102 fi
7103 ;;
7104
7105 *) ;; # Ignore the rest.
7106
7107 esac
7108 done
7109
7110 # Clean up.
7111 rm -f a.out a.exe
7112 else
7113 echo "libtool.m4: error: problem compiling $1 test program"
7114 fi
7115
7116 $RM -f confest.$objext
7117 CFLAGS=$_lt_libdeps_save_CFLAGS
7118
7119 # PORTME: override above test on systems where it is broken
7120 m4_if([$1], [CXX],
7121 [case $host_os in
7122 interix[[3-9]]*)
7123 # Interix 3.5 installs completely hosed .la files for C++, so rather than
7124 # hack all around it, let's just trust "g++" to DTRT.
7125 _LT_TAGVAR(predep_objects,$1)=
7126 _LT_TAGVAR(postdep_objects,$1)=
7127 _LT_TAGVAR(postdeps,$1)=
7128 ;;
7129
7130 linux*)
7131 case `$CC -V 2>&1 | sed 5q` in
7132 *Sun\ C*)
7133 # Sun C++ 5.9
7134
7135 # The more standards-conforming stlport4 library is
7136 # incompatible with the Cstd library. Avoid specifying
7137 # it if it's in CXXFLAGS. Ignore libCrun as
7138 # -library=stlport4 depends on it.
7139 case " $CXX $CXXFLAGS " in
7140 *" -library=stlport4 "*)
7141 solaris_use_stlport4=yes
7142 ;;
7143 esac
7144
7145 if test "$solaris_use_stlport4" != yes; then
7146 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7147 fi
7148 ;;
7149 esac
7150 ;;
7151
7152 solaris*)
7153 case $cc_basename in
7154 CC* | sunCC*)
7155 # The more standards-conforming stlport4 library is
7156 # incompatible with the Cstd library. Avoid specifying
7157 # it if it's in CXXFLAGS. Ignore libCrun as
7158 # -library=stlport4 depends on it.
7159 case " $CXX $CXXFLAGS " in
7160 *" -library=stlport4 "*)
7161 solaris_use_stlport4=yes
7162 ;;
7163 esac
7164
7165 # Adding this requires a known-good setup of shared libraries for
7166 # Sun compiler versions before 5.6, else PIC objects from an old
7167 # archive will be linked into the output, leading to subtle bugs.
7168 if test "$solaris_use_stlport4" != yes; then
7169 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7170 fi
7171 ;;
7172 esac
7173 ;;
7174 esac
7175 ])
7176
7177 case " $_LT_TAGVAR(postdeps, $1) " in
7178 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
7179 esac
7180 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
7181 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
7182 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
7183 fi
7184 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
7185 [The directories searched by this compiler when creating a shared library])
7186 _LT_TAGDECL([], [predep_objects], [1],
7187 [Dependencies to place before and after the objects being linked to
7188 create a shared library])
7189 _LT_TAGDECL([], [postdep_objects], [1])
7190 _LT_TAGDECL([], [predeps], [1])
7191 _LT_TAGDECL([], [postdeps], [1])
7192 _LT_TAGDECL([], [compiler_lib_search_path], [1],
7193 [The library search path used internally by the compiler when linking
7194 a shared library])
7195 ])# _LT_SYS_HIDDEN_LIBDEPS
7196
7197
7198 # _LT_LANG_F77_CONFIG([TAG])
7199 # --------------------------
7200 # Ensure that the configuration variables for a Fortran 77 compiler are
7201 # suitably defined. These variables are subsequently used by _LT_CONFIG
7202 # to write the compiler configuration to `libtool'.
7203 m4_defun([_LT_LANG_F77_CONFIG],
7204 [AC_LANG_PUSH(Fortran 77)
7205 if test -z "$F77" || test "X$F77" = "Xno"; then
7206 _lt_disable_F77=yes
7207 fi
7208
7209 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7210 _LT_TAGVAR(allow_undefined_flag, $1)=
7211 _LT_TAGVAR(always_export_symbols, $1)=no
7212 _LT_TAGVAR(archive_expsym_cmds, $1)=
7213 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7214 _LT_TAGVAR(hardcode_direct, $1)=no
7215 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7216 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7217 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7218 _LT_TAGVAR(hardcode_minus_L, $1)=no
7219 _LT_TAGVAR(hardcode_automatic, $1)=no
7220 _LT_TAGVAR(inherit_rpath, $1)=no
7221 _LT_TAGVAR(module_cmds, $1)=
7222 _LT_TAGVAR(module_expsym_cmds, $1)=
7223 _LT_TAGVAR(link_all_deplibs, $1)=unknown
7224 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7225 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7226 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7227 _LT_TAGVAR(no_undefined_flag, $1)=
7228 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7229 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7230
7231 # Source file extension for f77 test sources.
7232 ac_ext=f
7233
7234 # Object file extension for compiled f77 test sources.
7235 objext=o
7236 _LT_TAGVAR(objext, $1)=$objext
7237
7238 # No sense in running all these tests if we already determined that
7239 # the F77 compiler isn't working. Some variables (like enable_shared)
7240 # are currently assumed to apply to all compilers on this platform,
7241 # and will be corrupted by setting them based on a non-working compiler.
7242 if test "$_lt_disable_F77" != yes; then
7243 # Code to be used in simple compile tests
7244 lt_simple_compile_test_code="\
7245 subroutine t
7246 return
7247 end
7248 "
7249
7250 # Code to be used in simple link tests
7251 lt_simple_link_test_code="\
7252 program t
7253 end
7254 "
7255
7256 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7257 _LT_TAG_COMPILER
7258
7259 # save warnings/boilerplate of simple test code
7260 _LT_COMPILER_BOILERPLATE
7261 _LT_LINKER_BOILERPLATE
7262
7263 # Allow CC to be a program name with arguments.
7264 lt_save_CC="$CC"
7265 lt_save_GCC=$GCC
7266 lt_save_CFLAGS=$CFLAGS
7267 CC=${F77-"f77"}
7268 CFLAGS=$FFLAGS
7269 compiler=$CC
7270 _LT_TAGVAR(compiler, $1)=$CC
7271 _LT_CC_BASENAME([$compiler])
7272 GCC=$G77
7273 if test -n "$compiler"; then
7274 AC_MSG_CHECKING([if libtool supports shared libraries])
7275 AC_MSG_RESULT([$can_build_shared])
7276
7277 AC_MSG_CHECKING([whether to build shared libraries])
7278 test "$can_build_shared" = "no" && enable_shared=no
7279
7280 # On AIX, shared libraries and static libraries use the same namespace, and
7281 # are all built from PIC.
7282 case $host_os in
7283 aix3*)
7284 test "$enable_shared" = yes && enable_static=no
7285 if test -n "$RANLIB"; then
7286 archive_cmds="$archive_cmds~\$RANLIB \$lib"
7287 postinstall_cmds='$RANLIB $lib'
7288 fi
7289 ;;
7290 aix[[4-9]]*)
7291 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7292 test "$enable_shared" = yes && enable_static=no
7293 fi
7294 ;;
7295 esac
7296 AC_MSG_RESULT([$enable_shared])
7297
7298 AC_MSG_CHECKING([whether to build static libraries])
7299 # Make sure either enable_shared or enable_static is yes.
7300 test "$enable_shared" = yes || enable_static=yes
7301 AC_MSG_RESULT([$enable_static])
7302
7303 _LT_TAGVAR(GCC, $1)="$G77"
7304 _LT_TAGVAR(LD, $1)="$LD"
7305
7306 ## CAVEAT EMPTOR:
7307 ## There is no encapsulation within the following macros, do not change
7308 ## the running order or otherwise move them around unless you know exactly
7309 ## what you are doing...
7310 _LT_COMPILER_PIC($1)
7311 _LT_COMPILER_C_O($1)
7312 _LT_COMPILER_FILE_LOCKS($1)
7313 _LT_LINKER_SHLIBS($1)
7314 _LT_SYS_DYNAMIC_LINKER($1)
7315 _LT_LINKER_HARDCODE_LIBPATH($1)
7316
7317 _LT_CONFIG($1)
7318 fi # test -n "$compiler"
7319
7320 GCC=$lt_save_GCC
7321 CC="$lt_save_CC"
7322 CFLAGS="$lt_save_CFLAGS"
7323 fi # test "$_lt_disable_F77" != yes
7324
7325 AC_LANG_POP
7326 ])# _LT_LANG_F77_CONFIG
7327
7328
7329 # _LT_LANG_FC_CONFIG([TAG])
7330 # -------------------------
7331 # Ensure that the configuration variables for a Fortran compiler are
7332 # suitably defined. These variables are subsequently used by _LT_CONFIG
7333 # to write the compiler configuration to `libtool'.
7334 m4_defun([_LT_LANG_FC_CONFIG],
7335 [AC_LANG_PUSH(Fortran)
7336
7337 if test -z "$FC" || test "X$FC" = "Xno"; then
7338 _lt_disable_FC=yes
7339 fi
7340
7341 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7342 _LT_TAGVAR(allow_undefined_flag, $1)=
7343 _LT_TAGVAR(always_export_symbols, $1)=no
7344 _LT_TAGVAR(archive_expsym_cmds, $1)=
7345 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7346 _LT_TAGVAR(hardcode_direct, $1)=no
7347 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7348 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7349 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7350 _LT_TAGVAR(hardcode_minus_L, $1)=no
7351 _LT_TAGVAR(hardcode_automatic, $1)=no
7352 _LT_TAGVAR(inherit_rpath, $1)=no
7353 _LT_TAGVAR(module_cmds, $1)=
7354 _LT_TAGVAR(module_expsym_cmds, $1)=
7355 _LT_TAGVAR(link_all_deplibs, $1)=unknown
7356 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7357 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7358 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7359 _LT_TAGVAR(no_undefined_flag, $1)=
7360 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7361 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7362
7363 # Source file extension for fc test sources.
7364 ac_ext=${ac_fc_srcext-f}
7365
7366 # Object file extension for compiled fc test sources.
7367 objext=o
7368 _LT_TAGVAR(objext, $1)=$objext
7369
7370 # No sense in running all these tests if we already determined that
7371 # the FC compiler isn't working. Some variables (like enable_shared)
7372 # are currently assumed to apply to all compilers on this platform,
7373 # and will be corrupted by setting them based on a non-working compiler.
7374 if test "$_lt_disable_FC" != yes; then
7375 # Code to be used in simple compile tests
7376 lt_simple_compile_test_code="\
7377 subroutine t
7378 return
7379 end
7380 "
7381
7382 # Code to be used in simple link tests
7383 lt_simple_link_test_code="\
7384 program t
7385 end
7386 "
7387
7388 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7389 _LT_TAG_COMPILER
7390
7391 # save warnings/boilerplate of simple test code
7392 _LT_COMPILER_BOILERPLATE
7393 _LT_LINKER_BOILERPLATE
7394
7395 # Allow CC to be a program name with arguments.
7396 lt_save_CC="$CC"
7397 lt_save_GCC=$GCC
7398 lt_save_CFLAGS=$CFLAGS
7399 CC=${FC-"f95"}
7400 CFLAGS=$FCFLAGS
7401 compiler=$CC
7402 GCC=$ac_cv_fc_compiler_gnu
7403
7404 _LT_TAGVAR(compiler, $1)=$CC
7405 _LT_CC_BASENAME([$compiler])
7406
7407 if test -n "$compiler"; then
7408 AC_MSG_CHECKING([if libtool supports shared libraries])
7409 AC_MSG_RESULT([$can_build_shared])
7410
7411 AC_MSG_CHECKING([whether to build shared libraries])
7412 test "$can_build_shared" = "no" && enable_shared=no
7413
7414 # On AIX, shared libraries and static libraries use the same namespace, and
7415 # are all built from PIC.
7416 case $host_os in
7417 aix3*)
7418 test "$enable_shared" = yes && enable_static=no
7419 if test -n "$RANLIB"; then
7420 archive_cmds="$archive_cmds~\$RANLIB \$lib"
7421 postinstall_cmds='$RANLIB $lib'
7422 fi
7423 ;;
7424 aix[[4-9]]*)
7425 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7426 test "$enable_shared" = yes && enable_static=no
7427 fi
7428 ;;
7429 esac
7430 AC_MSG_RESULT([$enable_shared])
7431
7432 AC_MSG_CHECKING([whether to build static libraries])
7433 # Make sure either enable_shared or enable_static is yes.
7434 test "$enable_shared" = yes || enable_static=yes
7435 AC_MSG_RESULT([$enable_static])
7436
7437 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
7438 _LT_TAGVAR(LD, $1)="$LD"
7439
7440 ## CAVEAT EMPTOR:
7441 ## There is no encapsulation within the following macros, do not change
7442 ## the running order or otherwise move them around unless you know exactly
7443 ## what you are doing...
7444 _LT_SYS_HIDDEN_LIBDEPS($1)
7445 _LT_COMPILER_PIC($1)
7446 _LT_COMPILER_C_O($1)
7447 _LT_COMPILER_FILE_LOCKS($1)
7448 _LT_LINKER_SHLIBS($1)
7449 _LT_SYS_DYNAMIC_LINKER($1)
7450 _LT_LINKER_HARDCODE_LIBPATH($1)
7451
7452 _LT_CONFIG($1)
7453 fi # test -n "$compiler"
7454
7455 GCC=$lt_save_GCC
7456 CC=$lt_save_CC
7457 CFLAGS=$lt_save_CFLAGS
7458 fi # test "$_lt_disable_FC" != yes
7459
7460 AC_LANG_POP
7461 ])# _LT_LANG_FC_CONFIG
7462
7463
7464 # _LT_LANG_GCJ_CONFIG([TAG])
7465 # --------------------------
7466 # Ensure that the configuration variables for the GNU Java Compiler compiler
7467 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7468 # to write the compiler configuration to `libtool'.
7469 m4_defun([_LT_LANG_GCJ_CONFIG],
7470 [AC_REQUIRE([LT_PROG_GCJ])dnl
7471 AC_LANG_PUSH([Java])
7472
7473 # Source file extension for Java test sources.
7474 ac_ext=java
7475
7476 # Object file extension for compiled Java test sources.
7477 objext=o
7478 _LT_TAGVAR(objext, $1)=$objext
7479
7480 # Code to be used in simple compile tests
7481 lt_simple_compile_test_code="class foo {}"
7482
7483 # Code to be used in simple link tests
7484 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
7485
7486 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7487 _LT_TAG_COMPILER
7488
7489 # save warnings/boilerplate of simple test code
7490 _LT_COMPILER_BOILERPLATE
7491 _LT_LINKER_BOILERPLATE
7492
7493 # Allow CC to be a program name with arguments.
7494 lt_save_CC=$CC
7495 lt_save_CFLAGS=$CFLAGS
7496 lt_save_GCC=$GCC
7497 GCC=yes
7498 CC=${GCJ-"gcj"}
7499 CFLAGS=$GCJFLAGS
7500 compiler=$CC
7501 _LT_TAGVAR(compiler, $1)=$CC
7502 _LT_TAGVAR(LD, $1)="$LD"
7503 _LT_CC_BASENAME([$compiler])
7504
7505 # GCJ did not exist at the time GCC didn't implicitly link libc in.
7506 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7507
7508 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7509 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7510 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7511
7512 ## CAVEAT EMPTOR:
7513 ## There is no encapsulation within the following macros, do not change
7514 ## the running order or otherwise move them around unless you know exactly
7515 ## what you are doing...
7516 if test -n "$compiler"; then
7517 _LT_COMPILER_NO_RTTI($1)
7518 _LT_COMPILER_PIC($1)
7519 _LT_COMPILER_C_O($1)
7520 _LT_COMPILER_FILE_LOCKS($1)
7521 _LT_LINKER_SHLIBS($1)
7522 _LT_LINKER_HARDCODE_LIBPATH($1)
7523
7524 _LT_CONFIG($1)
7525 fi
7526
7527 AC_LANG_POP
7528
7529 GCC=$lt_save_GCC
7530 CC=$lt_save_CC
7531 CFLAGS=$lt_save_CFLAGS
7532 ])# _LT_LANG_GCJ_CONFIG
7533
7534
7535 # _LT_LANG_GO_CONFIG([TAG])
7536 # --------------------------
7537 # Ensure that the configuration variables for the GNU Go compiler
7538 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7539 # to write the compiler configuration to `libtool'.
7540 m4_defun([_LT_LANG_GO_CONFIG],
7541 [AC_REQUIRE([LT_PROG_GO])dnl
7542 AC_LANG_PUSH([Go])
7543
7544 # Source file extension for Go test sources.
7545 ac_ext=go
7546
7547 # Object file extension for compiled Go test sources.
7548 objext=o
7549 _LT_TAGVAR(objext, $1)=$objext
7550
7551 # Code to be used in simple compile tests
7552 lt_simple_compile_test_code="package main; func main() { }"
7553
7554 # Code to be used in simple link tests
7555 lt_simple_link_test_code='package main; func main() { }'
7556
7557 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7558 _LT_TAG_COMPILER
7559
7560 # save warnings/boilerplate of simple test code
7561 _LT_COMPILER_BOILERPLATE
7562 _LT_LINKER_BOILERPLATE
7563
7564 # Allow CC to be a program name with arguments.
7565 lt_save_CC=$CC
7566 lt_save_CFLAGS=$CFLAGS
7567 lt_save_GCC=$GCC
7568 GCC=yes
7569 CC=${GOC-"gccgo"}
7570 CFLAGS=$GOFLAGS
7571 compiler=$CC
7572 _LT_TAGVAR(compiler, $1)=$CC
7573 _LT_TAGVAR(LD, $1)="$LD"
7574 _LT_CC_BASENAME([$compiler])
7575
7576 # Go did not exist at the time GCC didn't implicitly link libc in.
7577 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7578
7579 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7580 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7581 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7582
7583 ## CAVEAT EMPTOR:
7584 ## There is no encapsulation within the following macros, do not change
7585 ## the running order or otherwise move them around unless you know exactly
7586 ## what you are doing...
7587 if test -n "$compiler"; then
7588 _LT_COMPILER_NO_RTTI($1)
7589 _LT_COMPILER_PIC($1)
7590 _LT_COMPILER_C_O($1)
7591 _LT_COMPILER_FILE_LOCKS($1)
7592 _LT_LINKER_SHLIBS($1)
7593 _LT_LINKER_HARDCODE_LIBPATH($1)
7594
7595 _LT_CONFIG($1)
7596 fi
7597
7598 AC_LANG_POP
7599
7600 GCC=$lt_save_GCC
7601 CC=$lt_save_CC
7602 CFLAGS=$lt_save_CFLAGS
7603 ])# _LT_LANG_GO_CONFIG
7604
7605
7606 # _LT_LANG_RC_CONFIG([TAG])
7607 # -------------------------
7608 # Ensure that the configuration variables for the Windows resource compiler
7609 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7610 # to write the compiler configuration to `libtool'.
7611 m4_defun([_LT_LANG_RC_CONFIG],
7612 [AC_REQUIRE([LT_PROG_RC])dnl
7613
7614 dnl Here, something like AC_LANG_PUSH([RC]) is expected.
7615 dnl But Resource Compiler is not supported as a language by autoconf
7616
7617 # Source file extension for RC test sources.
7618 ac_ext=rc
7619
7620 # Object file extension for compiled RC test sources.
7621 objext=o
7622 _LT_TAGVAR(objext, $1)=$objext
7623
7624 # Code to be used in simple compile tests
7625 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
7626
7627 # Code to be used in simple link tests
7628 lt_simple_link_test_code="$lt_simple_compile_test_code"
7629
7630 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7631 _LT_TAG_COMPILER
7632
7633 # save warnings/boilerplate of simple test code
7634 _LT_COMPILER_BOILERPLATE
7635 _LT_LINKER_BOILERPLATE
7636
7637 # Allow CC to be a program name with arguments.
7638 lt_save_CC="$CC"
7639 lt_save_CFLAGS=$CFLAGS
7640 lt_save_GCC=$GCC
7641 GCC=
7642 CC=${RC-"windres"}
7643 CFLAGS=
7644 compiler=$CC
7645 _LT_TAGVAR(compiler, $1)=$CC
7646 _LT_CC_BASENAME([$compiler])
7647 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
7648
7649 if test -n "$compiler"; then
7650 :
7651 _LT_CONFIG($1)
7652 fi
7653
7654 dnl Here, AC_LANG_POP is expected.
7655 GCC=$lt_save_GCC
7656 dnl Back to C
7657 AC_LANG([C])
7658 CC=$lt_save_CC
7659 CFLAGS=$lt_save_CFLAGS
7660 ])# _LT_LANG_RC_CONFIG
7661
7662
7663 # LT_PROG_GCJ
7664 # -----------
7665 AC_DEFUN([LT_PROG_GCJ],
7666 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
7667 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
7668 [AC_CHECK_TOOL(GCJ, gcj,)
7669 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7670 AC_SUBST(GCJFLAGS)])])[]dnl
7671 ])
7672
7673 # Old name:
7674 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
7675 dnl aclocal-1.4 backwards compatibility:
7676 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
7677
7678
7679 # LT_PROG_GO
7680 # ----------
7681 AC_DEFUN([LT_PROG_GO],
7682 [AC_CHECK_TOOL(GOC, gccgo,)
7683 ])
7684
7685
7686 # LT_PROG_RC
7687 # ----------
7688 AC_DEFUN([LT_PROG_RC],
7689 [AC_CHECK_TOOL(RC, windres,)
7690 ])
7691
7692 # Old name:
7693 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
7694 dnl aclocal-1.4 backwards compatibility:
7695 dnl AC_DEFUN([LT_AC_PROG_RC], [])
7696
7697
7698 # _LT_DECL_EGREP
7699 # --------------
7700 # If we don't have a new enough Autoconf to choose the best grep
7701 # available, choose the one first in the user's PATH.
7702 m4_defun([_LT_DECL_EGREP],
7703 [AC_REQUIRE([AC_PROG_EGREP])dnl
7704 AC_REQUIRE([AC_PROG_FGREP])dnl
7705 test -z "$GREP" && GREP=grep
7706 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
7707 _LT_DECL([], [EGREP], [1], [An ERE matcher])
7708 _LT_DECL([], [FGREP], [1], [A literal string matcher])
7709 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
7710 AC_SUBST([GREP])
7711 ])
7712
7713
7714 # _LT_DECL_OBJDUMP
7715 # --------------
7716 # If we don't have a new enough Autoconf to choose the best objdump
7717 # available, choose the one first in the user's PATH.
7718 m4_defun([_LT_DECL_OBJDUMP],
7719 [AC_CHECK_TOOL(OBJDUMP, objdump, false)
7720 test -z "$OBJDUMP" && OBJDUMP=objdump
7721 _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
7722 AC_SUBST([OBJDUMP])
7723 ])
7724
7725 # _LT_DECL_DLLTOOL
7726 # ----------------
7727 # Ensure DLLTOOL variable is set.
7728 m4_defun([_LT_DECL_DLLTOOL],
7729 [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
7730 test -z "$DLLTOOL" && DLLTOOL=dlltool
7731 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
7732 AC_SUBST([DLLTOOL])
7733 ])
7734
7735 # _LT_DECL_SED
7736 # ------------
7737 # Check for a fully-functional sed program, that truncates
7738 # as few characters as possible. Prefer GNU sed if found.
7739 m4_defun([_LT_DECL_SED],
7740 [AC_PROG_SED
7741 test -z "$SED" && SED=sed
7742 Xsed="$SED -e 1s/^X//"
7743 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
7744 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
7745 [Sed that helps us avoid accidentally triggering echo(1) options like -n])
7746 ])# _LT_DECL_SED
7747
7748 m4_ifndef([AC_PROG_SED], [
7749 ############################################################
7750 # NOTE: This macro has been submitted for inclusion into #
7751 # GNU Autoconf as AC_PROG_SED. When it is available in #
7752 # a released version of Autoconf we should remove this #
7753 # macro and use it instead. #
7754 ############################################################
7755
7756 m4_defun([AC_PROG_SED],
7757 [AC_MSG_CHECKING([for a sed that does not truncate output])
7758 AC_CACHE_VAL(lt_cv_path_SED,
7759 [# Loop through the user's path and test for sed and gsed.
7760 # Then use that list of sed's as ones to test for truncation.
7761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7762 for as_dir in $PATH
7763 do
7764 IFS=$as_save_IFS
7765 test -z "$as_dir" && as_dir=.
7766 for lt_ac_prog in sed gsed; do
7767 for ac_exec_ext in '' $ac_executable_extensions; do
7768 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
7769 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7770 fi
7771 done
7772 done
7773 done
7774 IFS=$as_save_IFS
7775 lt_ac_max=0
7776 lt_ac_count=0
7777 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
7778 # along with /bin/sed that truncates output.
7779 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7780 test ! -f $lt_ac_sed && continue
7781 cat /dev/null > conftest.in
7782 lt_ac_count=0
7783 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7784 # Check for GNU sed and select it if it is found.
7785 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7786 lt_cv_path_SED=$lt_ac_sed
7787 break
7788 fi
7789 while true; do
7790 cat conftest.in conftest.in >conftest.tmp
7791 mv conftest.tmp conftest.in
7792 cp conftest.in conftest.nl
7793 echo >>conftest.nl
7794 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7795 cmp -s conftest.out conftest.nl || break
7796 # 10000 chars as input seems more than enough
7797 test $lt_ac_count -gt 10 && break
7798 lt_ac_count=`expr $lt_ac_count + 1`
7799 if test $lt_ac_count -gt $lt_ac_max; then
7800 lt_ac_max=$lt_ac_count
7801 lt_cv_path_SED=$lt_ac_sed
7802 fi
7803 done
7804 done
7805 ])
7806 SED=$lt_cv_path_SED
7807 AC_SUBST([SED])
7808 AC_MSG_RESULT([$SED])
7809 ])#AC_PROG_SED
7810 ])#m4_ifndef
7811
7812 # Old name:
7813 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
7814 dnl aclocal-1.4 backwards compatibility:
7815 dnl AC_DEFUN([LT_AC_PROG_SED], [])
7816
7817
7818 # _LT_CHECK_SHELL_FEATURES
7819 # ------------------------
7820 # Find out whether the shell is Bourne or XSI compatible,
7821 # or has some other useful features.
7822 m4_defun([_LT_CHECK_SHELL_FEATURES],
7823 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
7824 # Try some XSI features
7825 xsi_shell=no
7826 ( _lt_dummy="a/b/c"
7827 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
7828 = c,a/b,b/c, \
7829 && eval 'test $(( 1 + 1 )) -eq 2 \
7830 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7831 && xsi_shell=yes
7832 AC_MSG_RESULT([$xsi_shell])
7833 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
7834
7835 AC_MSG_CHECKING([whether the shell understands "+="])
7836 lt_shell_append=no
7837 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
7838 >/dev/null 2>&1 \
7839 && lt_shell_append=yes
7840 AC_MSG_RESULT([$lt_shell_append])
7841 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
7842
7843 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7844 lt_unset=unset
7845 else
7846 lt_unset=false
7847 fi
7848 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
7849
7850 # test EBCDIC or ASCII
7851 case `echo X|tr X '\101'` in
7852 A) # ASCII based system
7853 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7854 lt_SP2NL='tr \040 \012'
7855 lt_NL2SP='tr \015\012 \040\040'
7856 ;;
7857 *) # EBCDIC based system
7858 lt_SP2NL='tr \100 \n'
7859 lt_NL2SP='tr \r\n \100\100'
7860 ;;
7861 esac
7862 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
7863 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
7864 ])# _LT_CHECK_SHELL_FEATURES
7865
7866
7867 # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
7868 # ------------------------------------------------------
7869 # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
7870 # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
7871 m4_defun([_LT_PROG_FUNCTION_REPLACE],
7872 [dnl {
7873 sed -e '/^$1 ()$/,/^} # $1 /c\
7874 $1 ()\
7875 {\
7876 m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
7877 } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
7878 && mv -f "$cfgfile.tmp" "$cfgfile" \
7879 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7880 test 0 -eq $? || _lt_function_replace_fail=:
7881 ])
7882
7883
7884 # _LT_PROG_REPLACE_SHELLFNS
7885 # -------------------------
7886 # Replace existing portable implementations of several shell functions with
7887 # equivalent extended shell implementations where those features are available..
7888 m4_defun([_LT_PROG_REPLACE_SHELLFNS],
7889 [if test x"$xsi_shell" = xyes; then
7890 _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
7891 case ${1} in
7892 */*) func_dirname_result="${1%/*}${2}" ;;
7893 * ) func_dirname_result="${3}" ;;
7894 esac])
7895
7896 _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
7897 func_basename_result="${1##*/}"])
7898
7899 _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
7900 case ${1} in
7901 */*) func_dirname_result="${1%/*}${2}" ;;
7902 * ) func_dirname_result="${3}" ;;
7903 esac
7904 func_basename_result="${1##*/}"])
7905
7906 _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
7907 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
7908 # positional parameters, so assign one to ordinary parameter first.
7909 func_stripname_result=${3}
7910 func_stripname_result=${func_stripname_result#"${1}"}
7911 func_stripname_result=${func_stripname_result%"${2}"}])
7912
7913 _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
7914 func_split_long_opt_name=${1%%=*}
7915 func_split_long_opt_arg=${1#*=}])
7916
7917 _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
7918 func_split_short_opt_arg=${1#??}
7919 func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
7920
7921 _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
7922 case ${1} in
7923 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
7924 *) func_lo2o_result=${1} ;;
7925 esac])
7926
7927 _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
7928
7929 _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
7930
7931 _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
7932 fi
7933
7934 if test x"$lt_shell_append" = xyes; then
7935 _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
7936
7937 _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
7938 func_quote_for_eval "${2}"
7939 dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
7940 eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
7941
7942 # Save a `func_append' function call where possible by direct use of '+='
7943 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
7944 && mv -f "$cfgfile.tmp" "$cfgfile" \
7945 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7946 test 0 -eq $? || _lt_function_replace_fail=:
7947 else
7948 # Save a `func_append' function call even when '+=' is not available
7949 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
7950 && mv -f "$cfgfile.tmp" "$cfgfile" \
7951 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7952 test 0 -eq $? || _lt_function_replace_fail=:
7953 fi
7954
7955 if test x"$_lt_function_replace_fail" = x":"; then
7956 AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
7957 fi
7958 ])
7959
7960 # _LT_PATH_CONVERSION_FUNCTIONS
7961 # -----------------------------
7962 # Determine which file name conversion functions should be used by
7963 # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
7964 # for certain cross-compile configurations and native mingw.
7965 m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
7966 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
7967 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
7968 AC_MSG_CHECKING([how to convert $build file names to $host format])
7969 AC_CACHE_VAL(lt_cv_to_host_file_cmd,
7970 [case $host in
7971 *-*-mingw* )
7972 case $build in
7973 *-*-mingw* ) # actually msys
7974 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7975 ;;
7976 *-*-cygwin* )
7977 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7978 ;;
7979 * ) # otherwise, assume *nix
7980 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7981 ;;
7982 esac
7983 ;;
7984 *-*-cygwin* )
7985 case $build in
7986 *-*-mingw* ) # actually msys
7987 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7988 ;;
7989 *-*-cygwin* )
7990 lt_cv_to_host_file_cmd=func_convert_file_noop
7991 ;;
7992 * ) # otherwise, assume *nix
7993 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7994 ;;
7995 esac
7996 ;;
7997 * ) # unhandled hosts (and "normal" native builds)
7998 lt_cv_to_host_file_cmd=func_convert_file_noop
7999 ;;
8000 esac
8001 ])
8002 to_host_file_cmd=$lt_cv_to_host_file_cmd
8003 AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
8004 _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
8005 [0], [convert $build file names to $host format])dnl
8006
8007 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
8008 AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
8009 [#assume ordinary cross tools, or native build.
8010 lt_cv_to_tool_file_cmd=func_convert_file_noop
8011 case $host in
8012 *-*-mingw* )
8013 case $build in
8014 *-*-mingw* ) # actually msys
8015 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8016 ;;
8017 esac
8018 ;;
8019 esac
8020 ])
8021 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8022 AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
8023 _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
8024 [0], [convert $build files to toolchain format])dnl
8025 ])# _LT_PATH_CONVERSION_FUNCTIONS
0 # Helper functions for option handling. -*- Autoconf -*-
1 #
2 # Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
3 # Inc.
4 # Written by Gary V. Vaughan, 2004
5 #
6 # This file is free software; the Free Software Foundation gives
7 # unlimited permission to copy and/or distribute it, with or without
8 # modifications, as long as this notice is preserved.
9
10 # serial 7 ltoptions.m4
11
12 # This is to help aclocal find these macros, as it can't see m4_define.
13 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
14
15
16 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
17 # ------------------------------------------
18 m4_define([_LT_MANGLE_OPTION],
19 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
20
21
22 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
23 # ---------------------------------------
24 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
25 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
26 # saved as a flag.
27 m4_define([_LT_SET_OPTION],
28 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
29 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
30 _LT_MANGLE_DEFUN([$1], [$2]),
31 [m4_warning([Unknown $1 option `$2'])])[]dnl
32 ])
33
34
35 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
36 # ------------------------------------------------------------
37 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
38 m4_define([_LT_IF_OPTION],
39 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
40
41
42 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
43 # -------------------------------------------------------
44 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
45 # are set.
46 m4_define([_LT_UNLESS_OPTIONS],
47 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
48 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
49 [m4_define([$0_found])])])[]dnl
50 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
51 ])[]dnl
52 ])
53
54
55 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
56 # ----------------------------------------
57 # OPTION-LIST is a space-separated list of Libtool options associated
58 # with MACRO-NAME. If any OPTION has a matching handler declared with
59 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
60 # the unknown option and exit.
61 m4_defun([_LT_SET_OPTIONS],
62 [# Set options
63 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
64 [_LT_SET_OPTION([$1], _LT_Option)])
65
66 m4_if([$1],[LT_INIT],[
67 dnl
68 dnl Simply set some default values (i.e off) if boolean options were not
69 dnl specified:
70 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
71 ])
72 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
73 ])
74 dnl
75 dnl If no reference was made to various pairs of opposing options, then
76 dnl we run the default mode handler for the pair. For example, if neither
77 dnl `shared' nor `disable-shared' was passed, we enable building of shared
78 dnl archives by default:
79 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
80 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
81 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
82 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
83 [_LT_ENABLE_FAST_INSTALL])
84 ])
85 ])# _LT_SET_OPTIONS
86
87
88 ## --------------------------------- ##
89 ## Macros to handle LT_INIT options. ##
90 ## --------------------------------- ##
91
92 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
93 # -----------------------------------------
94 m4_define([_LT_MANGLE_DEFUN],
95 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
96
97
98 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
99 # -----------------------------------------------
100 m4_define([LT_OPTION_DEFINE],
101 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
102 ])# LT_OPTION_DEFINE
103
104
105 # dlopen
106 # ------
107 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
108 ])
109
110 AU_DEFUN([AC_LIBTOOL_DLOPEN],
111 [_LT_SET_OPTION([LT_INIT], [dlopen])
112 AC_DIAGNOSE([obsolete],
113 [$0: Remove this warning and the call to _LT_SET_OPTION when you
114 put the `dlopen' option into LT_INIT's first parameter.])
115 ])
116
117 dnl aclocal-1.4 backwards compatibility:
118 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
119
120
121 # win32-dll
122 # ---------
123 # Declare package support for building win32 dll's.
124 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
125 [enable_win32_dll=yes
126
127 case $host in
128 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
129 AC_CHECK_TOOL(AS, as, false)
130 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
131 AC_CHECK_TOOL(OBJDUMP, objdump, false)
132 ;;
133 esac
134
135 test -z "$AS" && AS=as
136 _LT_DECL([], [AS], [1], [Assembler program])dnl
137
138 test -z "$DLLTOOL" && DLLTOOL=dlltool
139 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
140
141 test -z "$OBJDUMP" && OBJDUMP=objdump
142 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
143 ])# win32-dll
144
145 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
146 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
147 _LT_SET_OPTION([LT_INIT], [win32-dll])
148 AC_DIAGNOSE([obsolete],
149 [$0: Remove this warning and the call to _LT_SET_OPTION when you
150 put the `win32-dll' option into LT_INIT's first parameter.])
151 ])
152
153 dnl aclocal-1.4 backwards compatibility:
154 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
155
156
157 # _LT_ENABLE_SHARED([DEFAULT])
158 # ----------------------------
159 # implement the --enable-shared flag, and supports the `shared' and
160 # `disable-shared' LT_INIT options.
161 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
162 m4_define([_LT_ENABLE_SHARED],
163 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
164 AC_ARG_ENABLE([shared],
165 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
166 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
167 [p=${PACKAGE-default}
168 case $enableval in
169 yes) enable_shared=yes ;;
170 no) enable_shared=no ;;
171 *)
172 enable_shared=no
173 # Look at the argument we got. We use all the common list separators.
174 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
175 for pkg in $enableval; do
176 IFS="$lt_save_ifs"
177 if test "X$pkg" = "X$p"; then
178 enable_shared=yes
179 fi
180 done
181 IFS="$lt_save_ifs"
182 ;;
183 esac],
184 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
185
186 _LT_DECL([build_libtool_libs], [enable_shared], [0],
187 [Whether or not to build shared libraries])
188 ])# _LT_ENABLE_SHARED
189
190 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
191 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
192
193 # Old names:
194 AC_DEFUN([AC_ENABLE_SHARED],
195 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
196 ])
197
198 AC_DEFUN([AC_DISABLE_SHARED],
199 [_LT_SET_OPTION([LT_INIT], [disable-shared])
200 ])
201
202 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
203 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
204
205 dnl aclocal-1.4 backwards compatibility:
206 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
207 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
208
209
210
211 # _LT_ENABLE_STATIC([DEFAULT])
212 # ----------------------------
213 # implement the --enable-static flag, and support the `static' and
214 # `disable-static' LT_INIT options.
215 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
216 m4_define([_LT_ENABLE_STATIC],
217 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
218 AC_ARG_ENABLE([static],
219 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
220 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
221 [p=${PACKAGE-default}
222 case $enableval in
223 yes) enable_static=yes ;;
224 no) enable_static=no ;;
225 *)
226 enable_static=no
227 # Look at the argument we got. We use all the common list separators.
228 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
229 for pkg in $enableval; do
230 IFS="$lt_save_ifs"
231 if test "X$pkg" = "X$p"; then
232 enable_static=yes
233 fi
234 done
235 IFS="$lt_save_ifs"
236 ;;
237 esac],
238 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
239
240 _LT_DECL([build_old_libs], [enable_static], [0],
241 [Whether or not to build static libraries])
242 ])# _LT_ENABLE_STATIC
243
244 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
245 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
246
247 # Old names:
248 AC_DEFUN([AC_ENABLE_STATIC],
249 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
250 ])
251
252 AC_DEFUN([AC_DISABLE_STATIC],
253 [_LT_SET_OPTION([LT_INIT], [disable-static])
254 ])
255
256 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
257 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
258
259 dnl aclocal-1.4 backwards compatibility:
260 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
261 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
262
263
264
265 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
266 # ----------------------------------
267 # implement the --enable-fast-install flag, and support the `fast-install'
268 # and `disable-fast-install' LT_INIT options.
269 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
270 m4_define([_LT_ENABLE_FAST_INSTALL],
271 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
272 AC_ARG_ENABLE([fast-install],
273 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
274 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
275 [p=${PACKAGE-default}
276 case $enableval in
277 yes) enable_fast_install=yes ;;
278 no) enable_fast_install=no ;;
279 *)
280 enable_fast_install=no
281 # Look at the argument we got. We use all the common list separators.
282 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
283 for pkg in $enableval; do
284 IFS="$lt_save_ifs"
285 if test "X$pkg" = "X$p"; then
286 enable_fast_install=yes
287 fi
288 done
289 IFS="$lt_save_ifs"
290 ;;
291 esac],
292 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
293
294 _LT_DECL([fast_install], [enable_fast_install], [0],
295 [Whether or not to optimize for fast installation])dnl
296 ])# _LT_ENABLE_FAST_INSTALL
297
298 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
299 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
300
301 # Old names:
302 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
303 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
304 AC_DIAGNOSE([obsolete],
305 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
306 the `fast-install' option into LT_INIT's first parameter.])
307 ])
308
309 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
310 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
311 AC_DIAGNOSE([obsolete],
312 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
313 the `disable-fast-install' option into LT_INIT's first parameter.])
314 ])
315
316 dnl aclocal-1.4 backwards compatibility:
317 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
318 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
319
320
321 # _LT_WITH_PIC([MODE])
322 # --------------------
323 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
324 # LT_INIT options.
325 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
326 m4_define([_LT_WITH_PIC],
327 [AC_ARG_WITH([pic],
328 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
329 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
330 [lt_p=${PACKAGE-default}
331 case $withval in
332 yes|no) pic_mode=$withval ;;
333 *)
334 pic_mode=default
335 # Look at the argument we got. We use all the common list separators.
336 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
337 for lt_pkg in $withval; do
338 IFS="$lt_save_ifs"
339 if test "X$lt_pkg" = "X$lt_p"; then
340 pic_mode=yes
341 fi
342 done
343 IFS="$lt_save_ifs"
344 ;;
345 esac],
346 [pic_mode=default])
347
348 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
349
350 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
351 ])# _LT_WITH_PIC
352
353 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
354 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
355
356 # Old name:
357 AU_DEFUN([AC_LIBTOOL_PICMODE],
358 [_LT_SET_OPTION([LT_INIT], [pic-only])
359 AC_DIAGNOSE([obsolete],
360 [$0: Remove this warning and the call to _LT_SET_OPTION when you
361 put the `pic-only' option into LT_INIT's first parameter.])
362 ])
363
364 dnl aclocal-1.4 backwards compatibility:
365 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
366
367 ## ----------------- ##
368 ## LTDL_INIT Options ##
369 ## ----------------- ##
370
371 m4_define([_LTDL_MODE], [])
372 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
373 [m4_define([_LTDL_MODE], [nonrecursive])])
374 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
375 [m4_define([_LTDL_MODE], [recursive])])
376 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
377 [m4_define([_LTDL_MODE], [subproject])])
378
379 m4_define([_LTDL_TYPE], [])
380 LT_OPTION_DEFINE([LTDL_INIT], [installable],
381 [m4_define([_LTDL_TYPE], [installable])])
382 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
383 [m4_define([_LTDL_TYPE], [convenience])])
0 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
1 #
2 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
3 # Written by Gary V. Vaughan, 2004
4 #
5 # This file is free software; the Free Software Foundation gives
6 # unlimited permission to copy and/or distribute it, with or without
7 # modifications, as long as this notice is preserved.
8
9 # serial 6 ltsugar.m4
10
11 # This is to help aclocal find these macros, as it can't see m4_define.
12 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
13
14
15 # lt_join(SEP, ARG1, [ARG2...])
16 # -----------------------------
17 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
18 # associated separator.
19 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
20 # versions in m4sugar had bugs.
21 m4_define([lt_join],
22 [m4_if([$#], [1], [],
23 [$#], [2], [[$2]],
24 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
25 m4_define([_lt_join],
26 [m4_if([$#$2], [2], [],
27 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
28
29
30 # lt_car(LIST)
31 # lt_cdr(LIST)
32 # ------------
33 # Manipulate m4 lists.
34 # These macros are necessary as long as will still need to support
35 # Autoconf-2.59 which quotes differently.
36 m4_define([lt_car], [[$1]])
37 m4_define([lt_cdr],
38 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
39 [$#], 1, [],
40 [m4_dquote(m4_shift($@))])])
41 m4_define([lt_unquote], $1)
42
43
44 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
45 # ------------------------------------------
46 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
47 # Note that neither SEPARATOR nor STRING are expanded; they are appended
48 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
49 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
50 # than defined and empty).
51 #
52 # This macro is needed until we can rely on Autoconf 2.62, since earlier
53 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
54 m4_define([lt_append],
55 [m4_define([$1],
56 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
57
58
59
60 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
61 # ----------------------------------------------------------
62 # Produce a SEP delimited list of all paired combinations of elements of
63 # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
64 # has the form PREFIXmINFIXSUFFIXn.
65 # Needed until we can rely on m4_combine added in Autoconf 2.62.
66 m4_define([lt_combine],
67 [m4_if(m4_eval([$# > 3]), [1],
68 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
69 [[m4_foreach([_Lt_prefix], [$2],
70 [m4_foreach([_Lt_suffix],
71 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
72 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
73
74
75 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
76 # -----------------------------------------------------------------------
77 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
78 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
79 m4_define([lt_if_append_uniq],
80 [m4_ifdef([$1],
81 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
82 [lt_append([$1], [$2], [$3])$4],
83 [$5])],
84 [lt_append([$1], [$2], [$3])$4])])
85
86
87 # lt_dict_add(DICT, KEY, VALUE)
88 # -----------------------------
89 m4_define([lt_dict_add],
90 [m4_define([$1($2)], [$3])])
91
92
93 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
94 # --------------------------------------------
95 m4_define([lt_dict_add_subkey],
96 [m4_define([$1($2:$3)], [$4])])
97
98
99 # lt_dict_fetch(DICT, KEY, [SUBKEY])
100 # ----------------------------------
101 m4_define([lt_dict_fetch],
102 [m4_ifval([$3],
103 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
104 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
105
106
107 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
108 # -----------------------------------------------------------------
109 m4_define([lt_if_dict_fetch],
110 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
111 [$5],
112 [$6])])
113
114
115 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
116 # --------------------------------------------------------------
117 m4_define([lt_dict_filter],
118 [m4_if([$5], [], [],
119 [lt_join(m4_quote(m4_default([$4], [[, ]])),
120 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
121 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
122 ])
0 # ltversion.m4 -- version numbers -*- Autoconf -*-
1 #
2 # Copyright (C) 2004 Free Software Foundation, Inc.
3 # Written by Scott James Remnant, 2004
4 #
5 # This file is free software; the Free Software Foundation gives
6 # unlimited permission to copy and/or distribute it, with or without
7 # modifications, as long as this notice is preserved.
8
9 # @configure_input@
10
11 # serial 3337 ltversion.m4
12 # This file is part of GNU Libtool
13
14 m4_define([LT_PACKAGE_VERSION], [2.4.2])
15 m4_define([LT_PACKAGE_REVISION], [1.3337])
16
17 AC_DEFUN([LTVERSION_VERSION],
18 [macro_version='2.4.2'
19 macro_revision='1.3337'
20 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
21 _LT_DECL(, macro_revision, 0)
22 ])
0 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
1 #
2 # Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
3 # Written by Scott James Remnant, 2004.
4 #
5 # This file is free software; the Free Software Foundation gives
6 # unlimited permission to copy and/or distribute it, with or without
7 # modifications, as long as this notice is preserved.
8
9 # serial 5 lt~obsolete.m4
10
11 # These exist entirely to fool aclocal when bootstrapping libtool.
12 #
13 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
14 # which have later been changed to m4_define as they aren't part of the
15 # exported API, or moved to Autoconf or Automake where they belong.
16 #
17 # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
18 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
19 # using a macro with the same name in our local m4/libtool.m4 it'll
20 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
21 # and doesn't know about Autoconf macros at all.)
22 #
23 # So we provide this file, which has a silly filename so it's always
24 # included after everything else. This provides aclocal with the
25 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
26 # because those macros already exist, or will be overwritten later.
27 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
28 #
29 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
30 # Yes, that means every name once taken will need to remain here until
31 # we give up compatibility with versions before 1.7, at which point
32 # we need to keep only those names which we still refer to.
33
34 # This is to help aclocal find these macros, as it can't see m4_define.
35 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
36
37 m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
38 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
39 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
40 m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
41 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
42 m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
43 m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
44 m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
45 m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
46 m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
47 m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
48 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
49 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
50 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
51 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
52 m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
53 m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
54 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
55 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
56 m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
57 m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
58 m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
59 m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
60 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
61 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
62 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
63 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
64 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
65 m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
66 m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
67 m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
68 m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
69 m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
70 m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
71 m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
72 m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
73 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
74 m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
75 m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
76 m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
77 m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
78 m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
79 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
80 m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
81 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
82 m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
83 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
84 m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
85 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
86 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
87 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
88 m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
89 m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
90 m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
91 m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
92 m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
93 m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
94 m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
95 m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
96 m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
97 m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Copyright (C) 2000 Werner Koch (dd9jn)
17 # Copyright (C) 2001, 2002, 2003, 2004, 2005, 2007 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34
35
36
37
38
39 VPATH = @srcdir@
40 am__is_gnu_make = { \
41 if test -z '$(MAKELEVEL)'; then \
42 false; \
43 elif test -n '$(MAKE_HOST)'; then \
44 true; \
45 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
46 true; \
47 else \
48 false; \
49 fi; \
50 }
51 am__make_running_with_option = \
52 case $${target_option-} in \
53 ?) ;; \
54 *) echo "am__make_running_with_option: internal error: invalid" \
55 "target option '$${target_option-}' specified" >&2; \
56 exit 1;; \
57 esac; \
58 has_opt=no; \
59 sane_makeflags=$$MAKEFLAGS; \
60 if $(am__is_gnu_make); then \
61 sane_makeflags=$$MFLAGS; \
62 else \
63 case $$MAKEFLAGS in \
64 *\\[\ \ ]*) \
65 bs=\\; \
66 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
67 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
68 esac; \
69 fi; \
70 skip_next=no; \
71 strip_trailopt () \
72 { \
73 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
74 }; \
75 for flg in $$sane_makeflags; do \
76 test $$skip_next = yes && { skip_next=no; continue; }; \
77 case $$flg in \
78 *=*|--*) continue;; \
79 -*I) strip_trailopt 'I'; skip_next=yes;; \
80 -*I?*) strip_trailopt 'I';; \
81 -*O) strip_trailopt 'O'; skip_next=yes;; \
82 -*O?*) strip_trailopt 'O';; \
83 -*l) strip_trailopt 'l'; skip_next=yes;; \
84 -*l?*) strip_trailopt 'l';; \
85 -[dEDm]) skip_next=yes;; \
86 -[JT]) skip_next=yes;; \
87 esac; \
88 case $$flg in \
89 *$$target_option*) has_opt=yes; break;; \
90 esac; \
91 done; \
92 test $$has_opt = yes
93 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
94 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
95 pkgdatadir = $(datadir)/@PACKAGE@
96 pkgincludedir = $(includedir)/@PACKAGE@
97 pkglibdir = $(libdir)/@PACKAGE@
98 pkglibexecdir = $(libexecdir)/@PACKAGE@
99 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
100 install_sh_DATA = $(install_sh) -c -m 644
101 install_sh_PROGRAM = $(install_sh) -c
102 install_sh_SCRIPT = $(install_sh) -c
103 INSTALL_HEADER = $(INSTALL_DATA)
104 transform = $(program_transform_name)
105 NORMAL_INSTALL = :
106 PRE_INSTALL = :
107 POST_INSTALL = :
108 NORMAL_UNINSTALL = :
109 PRE_UNINSTALL = :
110 POST_UNINSTALL = :
111 build_triplet = @build@
112 host_triplet = @host@
113 bin_PROGRAMS = gpgme-tool$(EXEEXT) gpgme-json$(EXEEXT)
114 @HAVE_W32_SYSTEM_TRUE@libexec_PROGRAMS = gpgme-w32spawn$(EXEEXT)
115 subdir = src
116 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
117 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
118 $(top_srcdir)/m4/ax_pkg_swig.m4 \
119 $(top_srcdir)/m4/ax_python_devel.m4 \
120 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
121 $(top_srcdir)/m4/gnupg-ttyname.m4 \
122 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
123 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
124 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
125 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
126 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
127 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
128 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
129 $(ACLOCAL_M4)
130 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
131 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
132 CONFIG_HEADER = $(top_builddir)/conf/config.h
133 CONFIG_CLEAN_FILES = versioninfo.rc gpgme.pc gpgme-glib.pc gpgme.h \
134 gpgme-config
135 CONFIG_CLEAN_VPATH_FILES =
136 am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \
137 "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" \
138 "$(DESTDIR)$(m4datadir)" "$(DESTDIR)$(pkgconfigdir)" \
139 "$(DESTDIR)$(includedir)"
140 PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS)
141 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
142 am__vpath_adj = case $$p in \
143 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
144 *) f=$$p;; \
145 esac;
146 am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
147 am__install_max = 40
148 am__nobase_strip_setup = \
149 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
150 am__nobase_strip = \
151 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
152 am__nobase_list = $(am__nobase_strip_setup); \
153 for p in $$list; do echo "$$p $$p"; done | \
154 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
155 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
156 if (++n[$$2] == $(am__install_max)) \
157 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
158 END { for (dir in files) print dir, files[dir] }'
159 am__base_list = \
160 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
161 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
162 am__uninstall_files_from_dir = { \
163 test -z "$$files" \
164 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
165 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
166 $(am__cd) "$$dir" && rm -f $$files; }; \
167 }
168 LTLIBRARIES = $(lib_LTLIBRARIES)
169 @HAVE_W32_SYSTEM_TRUE@am__DEPENDENCIES_1 = versioninfo.lo
170 am__DEPENDENCIES_2 =
171 am__libgpgme_glib_la_SOURCES_DIST = util.h conversion.c b64dec.c \
172 get-env.c context.h ops.h parsetlv.c parsetlv.h mbox-util.c \
173 mbox-util.h data.h data.c data-fd.c data-stream.c data-mem.c \
174 data-user.c data-estream.c data-compat.c data-identify.c \
175 signers.c sig-notation.c wait.c wait-global.c wait-private.c \
176 wait-user.c wait.h op-support.c encrypt.c encrypt-sign.c \
177 decrypt.c decrypt-verify.c verify.c sign.c passphrase.c \
178 progress.c key.c keylist.c keysign.c trust-item.c trustlist.c \
179 tofupolicy.c revsig.c import.c export.c genkey.c delete.c \
180 edit.c getauditlog.c setexpire.c opassuan.c passwd.c spawn.c \
181 assuan-support.c engine.h engine-backend.h engine.c \
182 engine-gpg.c status-table.c engine-gpgsm.c engine-assuan.c \
183 engine-gpgconf.c engine-uiserver.c engine-g13.c vfs-mount.c \
184 vfs-create.c engine-spawn.c gpgconf.c queryswdb.c sema.h \
185 priv-io.h ath.h posix-util.c posix-io.c w32-util.c sys-util.h \
186 dirinfo.c debug.c debug.h gpgme.c version.c error.c ath.c \
187 w32-glib-io.c
188 @HAVE_UISERVER_TRUE@am__objects_1 = engine-uiserver.lo
189 @HAVE_DOSISH_SYSTEM_FALSE@am__objects_2 = posix-util.lo posix-io.lo
190 @HAVE_DOSISH_SYSTEM_TRUE@am__objects_2 = w32-util.lo
191 am__objects_3 = conversion.lo b64dec.lo get-env.lo parsetlv.lo \
192 mbox-util.lo data.lo data-fd.lo data-stream.lo data-mem.lo \
193 data-user.lo data-estream.lo data-compat.lo data-identify.lo \
194 signers.lo sig-notation.lo wait.lo wait-global.lo \
195 wait-private.lo wait-user.lo op-support.lo encrypt.lo \
196 encrypt-sign.lo decrypt.lo decrypt-verify.lo verify.lo sign.lo \
197 passphrase.lo progress.lo key.lo keylist.lo keysign.lo \
198 trust-item.lo trustlist.lo tofupolicy.lo revsig.lo import.lo \
199 export.lo genkey.lo delete.lo edit.lo getauditlog.lo \
200 setexpire.lo opassuan.lo passwd.lo spawn.lo assuan-support.lo \
201 engine.lo engine-gpg.lo status-table.lo engine-gpgsm.lo \
202 engine-assuan.lo engine-gpgconf.lo $(am__objects_1) \
203 engine-g13.lo vfs-mount.lo vfs-create.lo engine-spawn.lo \
204 gpgconf.lo queryswdb.lo $(am__objects_2) dirinfo.lo debug.lo \
205 gpgme.lo version.lo error.lo ath.lo
206 @BUILD_W32_GLIB_TRUE@am_libgpgme_glib_la_OBJECTS = $(am__objects_3) \
207 @BUILD_W32_GLIB_TRUE@ w32-glib-io.lo
208 libgpgme_glib_la_OBJECTS = $(am_libgpgme_glib_la_OBJECTS)
209 AM_V_lt = $(am__v_lt_@AM_V@)
210 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
211 am__v_lt_0 = --silent
212 am__v_lt_1 =
213 libgpgme_glib_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
214 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
215 $(AM_CFLAGS) $(CFLAGS) $(libgpgme_glib_la_LDFLAGS) $(LDFLAGS) \
216 -o $@
217 @BUILD_W32_GLIB_TRUE@am_libgpgme_glib_la_rpath = -rpath $(libdir)
218 am__libgpgme_la_SOURCES_DIST = util.h conversion.c b64dec.c get-env.c \
219 context.h ops.h parsetlv.c parsetlv.h mbox-util.c mbox-util.h \
220 data.h data.c data-fd.c data-stream.c data-mem.c data-user.c \
221 data-estream.c data-compat.c data-identify.c signers.c \
222 sig-notation.c wait.c wait-global.c wait-private.c wait-user.c \
223 wait.h op-support.c encrypt.c encrypt-sign.c decrypt.c \
224 decrypt-verify.c verify.c sign.c passphrase.c progress.c key.c \
225 keylist.c keysign.c trust-item.c trustlist.c tofupolicy.c \
226 revsig.c import.c export.c genkey.c delete.c edit.c \
227 getauditlog.c setexpire.c opassuan.c passwd.c spawn.c \
228 assuan-support.c engine.h engine-backend.h engine.c \
229 engine-gpg.c status-table.c engine-gpgsm.c engine-assuan.c \
230 engine-gpgconf.c engine-uiserver.c engine-g13.c vfs-mount.c \
231 vfs-create.c engine-spawn.c gpgconf.c queryswdb.c sema.h \
232 priv-io.h ath.h posix-util.c posix-io.c w32-util.c sys-util.h \
233 dirinfo.c debug.c debug.h gpgme.c version.c error.c ath.c \
234 w32-io.c
235 @HAVE_DOSISH_SYSTEM_TRUE@am__objects_4 = w32-io.lo
236 am_libgpgme_la_OBJECTS = $(am__objects_3) $(am__objects_4)
237 libgpgme_la_OBJECTS = $(am_libgpgme_la_OBJECTS)
238 libgpgme_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
239 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
240 $(libgpgme_la_LDFLAGS) $(LDFLAGS) -o $@
241 am_gpgme_json_OBJECTS = gpgme-json.$(OBJEXT) cJSON.$(OBJEXT)
242 gpgme_json_OBJECTS = $(am_gpgme_json_OBJECTS)
243 gpgme_json_DEPENDENCIES = libgpgme.la $(am__DEPENDENCIES_2)
244 am_gpgme_tool_OBJECTS = gpgme-tool.$(OBJEXT) argparse.$(OBJEXT)
245 gpgme_tool_OBJECTS = $(am_gpgme_tool_OBJECTS)
246 gpgme_tool_DEPENDENCIES = libgpgme.la
247 gpgme_w32spawn_SOURCES = gpgme-w32spawn.c
248 gpgme_w32spawn_OBJECTS = gpgme-w32spawn.$(OBJEXT)
249 gpgme_w32spawn_LDADD = $(LDADD)
250 SCRIPTS = $(bin_SCRIPTS)
251 AM_V_P = $(am__v_P_@AM_V@)
252 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
253 am__v_P_0 = false
254 am__v_P_1 = :
255 AM_V_GEN = $(am__v_GEN_@AM_V@)
256 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
257 am__v_GEN_0 = @echo " GEN " $@;
258 am__v_GEN_1 =
259 AM_V_at = $(am__v_at_@AM_V@)
260 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
261 am__v_at_0 = @
262 am__v_at_1 =
263 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
264 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
265 am__maybe_remake_depfiles = depfiles
266 am__depfiles_remade = $(DEPDIR)/setenv.Plo $(DEPDIR)/stpcpy.Plo \
267 $(DEPDIR)/ttyname_r.Plo ./$(DEPDIR)/argparse.Po \
268 ./$(DEPDIR)/assuan-support.Plo ./$(DEPDIR)/ath.Plo \
269 ./$(DEPDIR)/b64dec.Plo ./$(DEPDIR)/cJSON.Po \
270 ./$(DEPDIR)/conversion.Plo ./$(DEPDIR)/data-compat.Plo \
271 ./$(DEPDIR)/data-estream.Plo ./$(DEPDIR)/data-fd.Plo \
272 ./$(DEPDIR)/data-identify.Plo ./$(DEPDIR)/data-mem.Plo \
273 ./$(DEPDIR)/data-stream.Plo ./$(DEPDIR)/data-user.Plo \
274 ./$(DEPDIR)/data.Plo ./$(DEPDIR)/debug.Plo \
275 ./$(DEPDIR)/decrypt-verify.Plo ./$(DEPDIR)/decrypt.Plo \
276 ./$(DEPDIR)/delete.Plo ./$(DEPDIR)/dirinfo.Plo \
277 ./$(DEPDIR)/edit.Plo ./$(DEPDIR)/encrypt-sign.Plo \
278 ./$(DEPDIR)/encrypt.Plo ./$(DEPDIR)/engine-assuan.Plo \
279 ./$(DEPDIR)/engine-g13.Plo ./$(DEPDIR)/engine-gpg.Plo \
280 ./$(DEPDIR)/engine-gpgconf.Plo ./$(DEPDIR)/engine-gpgsm.Plo \
281 ./$(DEPDIR)/engine-spawn.Plo ./$(DEPDIR)/engine-uiserver.Plo \
282 ./$(DEPDIR)/engine.Plo ./$(DEPDIR)/error.Plo \
283 ./$(DEPDIR)/export.Plo ./$(DEPDIR)/genkey.Plo \
284 ./$(DEPDIR)/get-env.Plo ./$(DEPDIR)/getauditlog.Plo \
285 ./$(DEPDIR)/gpgconf.Plo ./$(DEPDIR)/gpgme-json.Po \
286 ./$(DEPDIR)/gpgme-tool.Po ./$(DEPDIR)/gpgme-w32spawn.Po \
287 ./$(DEPDIR)/gpgme.Plo ./$(DEPDIR)/import.Plo \
288 ./$(DEPDIR)/key.Plo ./$(DEPDIR)/keylist.Plo \
289 ./$(DEPDIR)/keysign.Plo ./$(DEPDIR)/mbox-util.Plo \
290 ./$(DEPDIR)/op-support.Plo ./$(DEPDIR)/opassuan.Plo \
291 ./$(DEPDIR)/parsetlv.Plo ./$(DEPDIR)/passphrase.Plo \
292 ./$(DEPDIR)/passwd.Plo ./$(DEPDIR)/posix-io.Plo \
293 ./$(DEPDIR)/posix-util.Plo ./$(DEPDIR)/progress.Plo \
294 ./$(DEPDIR)/queryswdb.Plo ./$(DEPDIR)/revsig.Plo \
295 ./$(DEPDIR)/setexpire.Plo ./$(DEPDIR)/sig-notation.Plo \
296 ./$(DEPDIR)/sign.Plo ./$(DEPDIR)/signers.Plo \
297 ./$(DEPDIR)/spawn.Plo ./$(DEPDIR)/status-table.Plo \
298 ./$(DEPDIR)/tofupolicy.Plo ./$(DEPDIR)/trust-item.Plo \
299 ./$(DEPDIR)/trustlist.Plo ./$(DEPDIR)/verify.Plo \
300 ./$(DEPDIR)/version.Plo ./$(DEPDIR)/vfs-create.Plo \
301 ./$(DEPDIR)/vfs-mount.Plo ./$(DEPDIR)/w32-glib-io.Plo \
302 ./$(DEPDIR)/w32-io.Plo ./$(DEPDIR)/w32-util.Plo \
303 ./$(DEPDIR)/wait-global.Plo ./$(DEPDIR)/wait-private.Plo \
304 ./$(DEPDIR)/wait-user.Plo ./$(DEPDIR)/wait.Plo
305 am__mv = mv -f
306 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
307 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
308 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
309 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
310 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
311 $(AM_CFLAGS) $(CFLAGS)
312 AM_V_CC = $(am__v_CC_@AM_V@)
313 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
314 am__v_CC_0 = @echo " CC " $@;
315 am__v_CC_1 =
316 CCLD = $(CC)
317 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
318 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
319 $(AM_LDFLAGS) $(LDFLAGS) -o $@
320 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
321 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
322 am__v_CCLD_0 = @echo " CCLD " $@;
323 am__v_CCLD_1 =
324 SOURCES = $(libgpgme_glib_la_SOURCES) $(libgpgme_la_SOURCES) \
325 $(gpgme_json_SOURCES) $(gpgme_tool_SOURCES) gpgme-w32spawn.c
326 DIST_SOURCES = $(am__libgpgme_glib_la_SOURCES_DIST) \
327 $(am__libgpgme_la_SOURCES_DIST) $(gpgme_json_SOURCES) \
328 $(gpgme_tool_SOURCES) gpgme-w32spawn.c
329 am__can_run_installinfo = \
330 case $$AM_UPDATE_INFO_DIR in \
331 n|no|NO) false;; \
332 *) (install-info --version) >/dev/null 2>&1;; \
333 esac
334 DATA = $(m4data_DATA) $(pkgconfig_DATA)
335 HEADERS = $(nodist_include_HEADERS)
336 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
337 # Read a list of newline-separated strings from the standard input,
338 # and print each of them once, without duplicates. Input order is
339 # *not* preserved.
340 am__uniquify_input = $(AWK) '\
341 BEGIN { nonempty = 0; } \
342 { items[$$0] = 1; nonempty = 1; } \
343 END { if (nonempty) { for (i in items) print i; }; } \
344 '
345 # Make sure the list of sources is unique. This is necessary because,
346 # e.g., the same source file might be shared among _SOURCES variables
347 # for different programs/libraries.
348 am__define_uniq_tagged_files = \
349 list='$(am__tagged_files)'; \
350 unique=`for i in $$list; do \
351 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
352 done | $(am__uniquify_input)`
353 ETAGS = etags
354 CTAGS = ctags
355 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/gpgme-config.in \
356 $(srcdir)/gpgme-glib.pc.in $(srcdir)/gpgme.h.in \
357 $(srcdir)/gpgme.pc.in $(srcdir)/versioninfo.rc.in \
358 $(top_srcdir)/build-aux/depcomp \
359 $(top_srcdir)/build-aux/mkinstalldirs setenv.c stpcpy.c \
360 ttyname_r.c
361 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
362 ACLOCAL = @ACLOCAL@
363 AMTAR = @AMTAR@
364 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
365 AR = @AR@
366 AS = @AS@
367 AUTOCONF = @AUTOCONF@
368 AUTOHEADER = @AUTOHEADER@
369 AUTOMAKE = @AUTOMAKE@
370 AWK = @AWK@
371 BUILD_FILEVERSION = @BUILD_FILEVERSION@
372 BUILD_REVISION = @BUILD_REVISION@
373 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
374 BUILD_VERSION = @BUILD_VERSION@
375 CC = @CC@
376 CCDEPMODE = @CCDEPMODE@
377 CC_FOR_BUILD = @CC_FOR_BUILD@
378 CFLAGS = @CFLAGS@
379 CPP = @CPP@
380 CPPFLAGS = @CPPFLAGS@
381 CXX = @CXX@
382 CXXCPP = @CXXCPP@
383 CXXDEPMODE = @CXXDEPMODE@
384 CXXFLAGS = @CXXFLAGS@
385 CYGPATH_W = @CYGPATH_W@
386 DEFS = @DEFS@
387 DEPDIR = @DEPDIR@
388 DLLTOOL = @DLLTOOL@
389 DOXYGEN = @DOXYGEN@
390 DSYMUTIL = @DSYMUTIL@
391 DUMPBIN = @DUMPBIN@
392 ECHO_C = @ECHO_C@
393 ECHO_N = @ECHO_N@
394 ECHO_T = @ECHO_T@
395 EGREP = @EGREP@
396 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
397 EXEEXT = @EXEEXT@
398 FGREP = @FGREP@
399 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
400 GLIBC21 = @GLIBC21@
401 GLIB_CFLAGS = @GLIB_CFLAGS@
402 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
403 GLIB_LIBS = @GLIB_LIBS@
404 GLIB_MKENUMS = @GLIB_MKENUMS@
405 GOBJECT_QUERY = @GOBJECT_QUERY@
406 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
407 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
408 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
409 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
410 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
411 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
412 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
413 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
414 GPGME_QT_LIBS = @GPGME_QT_LIBS@
415 GPGRT_CONFIG = @GPGRT_CONFIG@
416 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
417 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
418 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
419 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
420 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
421 GRAPHVIZ = @GRAPHVIZ@
422 GREP = @GREP@
423 HAVE_CXX11 = @HAVE_CXX11@
424 HAVE_DOT = @HAVE_DOT@
425 INSTALL = @INSTALL@
426 INSTALL_DATA = @INSTALL_DATA@
427 INSTALL_PROGRAM = @INSTALL_PROGRAM@
428 INSTALL_SCRIPT = @INSTALL_SCRIPT@
429 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
430 LD = @LD@
431 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
432 LDFLAGS = @LDFLAGS@
433 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
434 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
435 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
436 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
437 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
438 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
439 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
440 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
441 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
442 LIBOBJS = @LIBOBJS@
443 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
444 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
445 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
446 LIBS = @LIBS@
447 LIBTOOL = @LIBTOOL@
448 LIPO = @LIPO@
449 LN_S = @LN_S@
450 LTLIBOBJS = @LTLIBOBJS@
451 MAINT = @MAINT@
452 MAKEINFO = @MAKEINFO@
453 MANIFEST_TOOL = @MANIFEST_TOOL@
454 MKDIR_P = @MKDIR_P@
455 MOC = @MOC@
456 MOC2 = @MOC2@
457 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
458 NM = @NM@
459 NMEDIT = @NMEDIT@
460 OBJDUMP = @OBJDUMP@
461 OBJEXT = @OBJEXT@
462 OTOOL = @OTOOL@
463 OTOOL64 = @OTOOL64@
464 PACKAGE = @PACKAGE@
465 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
466 PACKAGE_NAME = @PACKAGE_NAME@
467 PACKAGE_STRING = @PACKAGE_STRING@
468 PACKAGE_TARNAME = @PACKAGE_TARNAME@
469 PACKAGE_URL = @PACKAGE_URL@
470 PACKAGE_VERSION = @PACKAGE_VERSION@
471 PATH_SEPARATOR = @PATH_SEPARATOR@
472 PKG_CONFIG = @PKG_CONFIG@
473 PYTHON = @PYTHON@
474 PYTHONS = @PYTHONS@
475 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
476 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
477 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
478 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
479 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
480 PYTHON_PLATFORM = @PYTHON_PLATFORM@
481 PYTHON_PREFIX = @PYTHON_PREFIX@
482 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
483 PYTHON_VERSION = @PYTHON_VERSION@
484 QTCHOOSER = @QTCHOOSER@
485 RANLIB = @RANLIB@
486 RC = @RC@
487 SED = @SED@
488 SET_MAKE = @SET_MAKE@
489 SHELL = @SHELL@
490 STRIP = @STRIP@
491 SWIG = @SWIG@
492 SWIG_LIB = @SWIG_LIB@
493 SYSROOT = @SYSROOT@
494 VERSION = @VERSION@
495 VERSION_MAJOR = @VERSION_MAJOR@
496 VERSION_MICRO = @VERSION_MICRO@
497 VERSION_MINOR = @VERSION_MINOR@
498 VERSION_NUMBER = @VERSION_NUMBER@
499 abs_builddir = @abs_builddir@
500 abs_srcdir = @abs_srcdir@
501 abs_top_builddir = @abs_top_builddir@
502 abs_top_srcdir = @abs_top_srcdir@
503 ac_ct_AR = @ac_ct_AR@
504 ac_ct_CC = @ac_ct_CC@
505 ac_ct_CXX = @ac_ct_CXX@
506 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
507 am__include = @am__include@
508 am__leading_dot = @am__leading_dot@
509 am__quote = @am__quote@
510 am__tar = @am__tar@
511 am__untar = @am__untar@
512 bindir = @bindir@
513 build = @build@
514 build_alias = @build_alias@
515 build_cpu = @build_cpu@
516 build_os = @build_os@
517 build_vendor = @build_vendor@
518 builddir = @builddir@
519 datadir = @datadir@
520 datarootdir = @datarootdir@
521 docdir = @docdir@
522 dvidir = @dvidir@
523 emacs_local_vars_begin = @emacs_local_vars_begin@
524 emacs_local_vars_end = @emacs_local_vars_end@
525 emacs_local_vars_read_only = @emacs_local_vars_read_only@
526 exec_prefix = @exec_prefix@
527 host = @host@
528 host_alias = @host_alias@
529 host_cpu = @host_cpu@
530 host_os = @host_os@
531 host_vendor = @host_vendor@
532 htmldir = @htmldir@
533 includedir = @includedir@
534 infodir = @infodir@
535 install_sh = @install_sh@
536 libdir = @libdir@
537 libexecdir = @libexecdir@
538 localedir = @localedir@
539 localstatedir = @localstatedir@
540 mandir = @mandir@
541 mkdir_p = @mkdir_p@
542 oldincludedir = @oldincludedir@
543 pdfdir = @pdfdir@
544 pkgpyexecdir = @pkgpyexecdir@
545 pkgpythondir = @pkgpythondir@
546 prefix = @prefix@
547 program_transform_name = @program_transform_name@
548 psdir = @psdir@
549 pyexecdir = @pyexecdir@
550 pythondir = @pythondir@
551 runstatedir = @runstatedir@
552 sbindir = @sbindir@
553 sharedstatedir = @sharedstatedir@
554 srcdir = @srcdir@
555 sysconfdir = @sysconfdir@
556 target_alias = @target_alias@
557 top_build_prefix = @top_build_prefix@
558 top_builddir = @top_builddir@
559 top_srcdir = @top_srcdir@
560 pkgconfigdir = $(libdir)/pkgconfig
561 pkgconfig_DATA = gpgme.pc gpgme-glib.pc
562 EXTRA_DIST = gpgme-config.in gpgme.m4 libgpgme.vers ChangeLog-2011 \
563 gpgme.h.in versioninfo.rc.in gpgme.def \
564 gpgme.pc.in gpgme-glib.pc.in
565
566 bin_SCRIPTS = gpgme-config
567 m4datadir = $(datadir)/aclocal
568 m4data_DATA = gpgme.m4
569 nodist_include_HEADERS = gpgme.h
570 @BUILD_W32_GLIB_FALSE@ltlib_gpgme_glib =
571 @BUILD_W32_GLIB_TRUE@ltlib_gpgme_glib = libgpgme-glib.la
572 lib_LTLIBRARIES = libgpgme.la $(ltlib_gpgme_glib)
573 @HAVE_LD_VERSION_SCRIPT_FALSE@libgpgme_version_script_cmd =
574 @HAVE_LD_VERSION_SCRIPT_TRUE@libgpgme_version_script_cmd = -Wl,--version-script=$(srcdir)/libgpgme.vers
575 @HAVE_DOSISH_SYSTEM_FALSE@system_components = ath.h posix-util.c posix-io.c
576 @HAVE_DOSISH_SYSTEM_TRUE@system_components = w32-util.c
577 @HAVE_DOSISH_SYSTEM_FALSE@system_components_not_extra =
578 @HAVE_DOSISH_SYSTEM_TRUE@system_components_not_extra = w32-io.c
579 @HAVE_UISERVER_FALSE@uiserver_components =
580 @HAVE_UISERVER_TRUE@uiserver_components = engine-uiserver.c
581
582 # These are the source files common to all library versions. We used
583 # to build a non-installed library for that, but that does not work
584 # correctly on all platforms (in particular, one can not specify the
585 # right linking order with libtool, as the non-installed version has
586 # unresolved symbols to the thread module.
587 main_sources = \
588 util.h conversion.c b64dec.c get-env.c context.h ops.h \
589 parsetlv.c parsetlv.h \
590 mbox-util.c mbox-util.h \
591 data.h data.c data-fd.c data-stream.c data-mem.c data-user.c \
592 data-estream.c \
593 data-compat.c data-identify.c \
594 signers.c sig-notation.c \
595 wait.c wait-global.c wait-private.c wait-user.c wait.h \
596 op-support.c \
597 encrypt.c encrypt-sign.c decrypt.c decrypt-verify.c verify.c \
598 sign.c passphrase.c progress.c \
599 key.c keylist.c keysign.c trust-item.c trustlist.c tofupolicy.c \
600 revsig.c \
601 import.c export.c genkey.c delete.c edit.c getauditlog.c \
602 setexpire.c \
603 opassuan.c passwd.c spawn.c assuan-support.c \
604 engine.h engine-backend.h engine.c engine-gpg.c status-table.c \
605 engine-gpgsm.c engine-assuan.c engine-gpgconf.c \
606 $(uiserver_components) \
607 engine-g13.c vfs-mount.c vfs-create.c \
608 engine-spawn.c \
609 gpgconf.c queryswdb.c \
610 sema.h priv-io.h $(system_components) sys-util.h dirinfo.c \
611 debug.c debug.h gpgme.c version.c error.c \
612 ath.h ath.c
613
614 libgpgme_la_SOURCES = $(main_sources) $(system_components_not_extra)
615 @BUILD_W32_GLIB_TRUE@libgpgme_glib_la_SOURCES = $(main_sources) w32-glib-io.c
616
617 # We use a global CFLAGS setting for all libraries
618 # versions, because then every object file is only compiled once.
619 AM_CFLAGS = @LIBASSUAN_CFLAGS@ @GPG_ERROR_CFLAGS@ @GLIB_CFLAGS@
620 gpgme_tool_SOURCES = gpgme-tool.c argparse.c argparse.h
621 gpgme_tool_LDADD = libgpgme.la @LIBASSUAN_LIBS@ @GPG_ERROR_LIBS@
622 gpgme_json_SOURCES = gpgme-json.c cJSON.c cJSON.h
623 gpgme_json_LDADD = -lm libgpgme.la $(GPG_ERROR_LIBS)
624 @HAVE_W32_SYSTEM_TRUE@RCCOMPILE = $(RC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES)
625 @HAVE_W32_SYSTEM_TRUE@LTRCCOMPILE = $(LIBTOOL) --mode=compile --tag=RC $(RCCOMPILE)
626 @HAVE_W32_SYSTEM_TRUE@SUFFIXES = .rc .lo
627 @HAVE_W32_SYSTEM_FALSE@gpgme_res =
628 @HAVE_W32_SYSTEM_TRUE@gpgme_res = versioninfo.lo
629 @HAVE_W32_SYSTEM_FALSE@no_undefined =
630 @HAVE_W32_SYSTEM_TRUE@no_undefined = -no-undefined
631 @HAVE_W32_SYSTEM_FALSE@export_symbols =
632 @HAVE_W32_SYSTEM_TRUE@export_symbols = -export-symbols $(srcdir)/gpgme.def
633 @HAVE_W32_SYSTEM_FALSE@extra_ltoptions =
634 @HAVE_W32_SYSTEM_TRUE@extra_ltoptions = -XCClinker -static-libgcc
635 @HAVE_W32_SYSTEM_TRUE@gpgme_w32_extra_libs = -lws2_32
636 @HAVE_W32_SYSTEM_FALSE@gpgme_deps =
637 @HAVE_W32_SYSTEM_TRUE@gpgme_deps = $(gpgme_res) gpgme.def
638 libgpgme_la_LDFLAGS = $(no_undefined) $(export_symbols) $(extra_ltoptions) \
639 $(libgpgme_version_script_cmd) -version-info \
640 @LIBGPGME_LT_CURRENT@:@LIBGPGME_LT_REVISION@:@LIBGPGME_LT_AGE@
641
642 libgpgme_la_DEPENDENCIES = @LTLIBOBJS@ $(srcdir)/libgpgme.vers $(gpgme_deps)
643 libgpgme_la_LIBADD = $(gpgme_res) @LIBASSUAN_LIBS@ @LTLIBOBJS@ \
644 @GPG_ERROR_LIBS@ $(gpgme_w32_extra_libs)
645
646 @BUILD_W32_GLIB_TRUE@libgpgme_glib_la_LDFLAGS = \
647 @BUILD_W32_GLIB_TRUE@ $(no_undefined) $(export_symbols) $(extra_ltoptions) \
648 @BUILD_W32_GLIB_TRUE@ $(libgpgme_version_script_cmd) -version-info \
649 @BUILD_W32_GLIB_TRUE@ @LIBGPGME_LT_CURRENT@:@LIBGPGME_LT_REVISION@:@LIBGPGME_LT_AGE@
650
651 @BUILD_W32_GLIB_TRUE@libgpgme_glib_la_DEPENDENCIES = @LTLIBOBJS@ \
652 @BUILD_W32_GLIB_TRUE@ $(srcdir)/libgpgme.vers $(gpgme_deps)
653
654 @BUILD_W32_GLIB_TRUE@libgpgme_glib_la_LIBADD = $(gpgme_res) @LIBASSUAN_LIBS@ @LTLIBOBJS@ \
655 @BUILD_W32_GLIB_TRUE@ @GPG_ERROR_LIBS@ @GLIB_LIBS@ $(gpgme_w32_extra_libs)
656
657 all: all-am
658
659 .SUFFIXES:
660 .SUFFIXES: .rc .lo .c .o .obj
661 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
662 @for dep in $?; do \
663 case '$(am__configure_deps)' in \
664 *$$dep*) \
665 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
666 && { if test -f $@; then exit 0; else break; fi; }; \
667 exit 1;; \
668 esac; \
669 done; \
670 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \
671 $(am__cd) $(top_srcdir) && \
672 $(AUTOMAKE) --gnu src/Makefile
673 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
674 @case '$?' in \
675 *config.status*) \
676 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
677 *) \
678 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
679 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
680 esac;
681
682 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
683 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
684
685 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
686 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
687 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
688 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
689 $(am__aclocal_m4_deps):
690 versioninfo.rc: $(top_builddir)/config.status $(srcdir)/versioninfo.rc.in
691 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
692 gpgme.pc: $(top_builddir)/config.status $(srcdir)/gpgme.pc.in
693 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
694 gpgme-glib.pc: $(top_builddir)/config.status $(srcdir)/gpgme-glib.pc.in
695 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
696 gpgme.h: $(top_builddir)/config.status $(srcdir)/gpgme.h.in
697 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
698 gpgme-config: $(top_builddir)/config.status $(srcdir)/gpgme-config.in
699 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
700 install-binPROGRAMS: $(bin_PROGRAMS)
701 @$(NORMAL_INSTALL)
702 @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
703 if test -n "$$list"; then \
704 echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
705 $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
706 fi; \
707 for p in $$list; do echo "$$p $$p"; done | \
708 sed 's/$(EXEEXT)$$//' | \
709 while read p p1; do if test -f $$p \
710 || test -f $$p1 \
711 ; then echo "$$p"; echo "$$p"; else :; fi; \
712 done | \
713 sed -e 'p;s,.*/,,;n;h' \
714 -e 's|.*|.|' \
715 -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
716 sed 'N;N;N;s,\n, ,g' | \
717 $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
718 { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
719 if ($$2 == $$4) files[d] = files[d] " " $$1; \
720 else { print "f", $$3 "/" $$4, $$1; } } \
721 END { for (d in files) print "f", d, files[d] }' | \
722 while read type dir files; do \
723 if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
724 test -z "$$files" || { \
725 echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
726 $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
727 } \
728 ; done
729
730 uninstall-binPROGRAMS:
731 @$(NORMAL_UNINSTALL)
732 @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
733 files=`for p in $$list; do echo "$$p"; done | \
734 sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
735 -e 's/$$/$(EXEEXT)/' \
736 `; \
737 test -n "$$list" || exit 0; \
738 echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
739 cd "$(DESTDIR)$(bindir)" && rm -f $$files
740
741 clean-binPROGRAMS:
742 @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \
743 echo " rm -f" $$list; \
744 rm -f $$list || exit $$?; \
745 test -n "$(EXEEXT)" || exit 0; \
746 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
747 echo " rm -f" $$list; \
748 rm -f $$list
749 install-libexecPROGRAMS: $(libexec_PROGRAMS)
750 @$(NORMAL_INSTALL)
751 @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \
752 if test -n "$$list"; then \
753 echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \
754 $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \
755 fi; \
756 for p in $$list; do echo "$$p $$p"; done | \
757 sed 's/$(EXEEXT)$$//' | \
758 while read p p1; do if test -f $$p \
759 || test -f $$p1 \
760 ; then echo "$$p"; echo "$$p"; else :; fi; \
761 done | \
762 sed -e 'p;s,.*/,,;n;h' \
763 -e 's|.*|.|' \
764 -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
765 sed 'N;N;N;s,\n, ,g' | \
766 $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
767 { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
768 if ($$2 == $$4) files[d] = files[d] " " $$1; \
769 else { print "f", $$3 "/" $$4, $$1; } } \
770 END { for (d in files) print "f", d, files[d] }' | \
771 while read type dir files; do \
772 if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
773 test -z "$$files" || { \
774 echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \
775 $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \
776 } \
777 ; done
778
779 uninstall-libexecPROGRAMS:
780 @$(NORMAL_UNINSTALL)
781 @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \
782 files=`for p in $$list; do echo "$$p"; done | \
783 sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
784 -e 's/$$/$(EXEEXT)/' \
785 `; \
786 test -n "$$list" || exit 0; \
787 echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \
788 cd "$(DESTDIR)$(libexecdir)" && rm -f $$files
789
790 clean-libexecPROGRAMS:
791 @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \
792 echo " rm -f" $$list; \
793 rm -f $$list || exit $$?; \
794 test -n "$(EXEEXT)" || exit 0; \
795 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
796 echo " rm -f" $$list; \
797 rm -f $$list
798
799 install-libLTLIBRARIES: $(lib_LTLIBRARIES)
800 @$(NORMAL_INSTALL)
801 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
802 list2=; for p in $$list; do \
803 if test -f $$p; then \
804 list2="$$list2 $$p"; \
805 else :; fi; \
806 done; \
807 test -z "$$list2" || { \
808 echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
809 $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
810 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
811 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
812 }
813
814 uninstall-libLTLIBRARIES:
815 @$(NORMAL_UNINSTALL)
816 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
817 for p in $$list; do \
818 $(am__strip_dir) \
819 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
820 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
821 done
822
823 clean-libLTLIBRARIES:
824 -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
825 @list='$(lib_LTLIBRARIES)'; \
826 locs=`for p in $$list; do echo $$p; done | \
827 sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
828 sort -u`; \
829 test -z "$$locs" || { \
830 echo rm -f $${locs}; \
831 rm -f $${locs}; \
832 }
833
834 libgpgme-glib.la: $(libgpgme_glib_la_OBJECTS) $(libgpgme_glib_la_DEPENDENCIES) $(EXTRA_libgpgme_glib_la_DEPENDENCIES)
835 $(AM_V_CCLD)$(libgpgme_glib_la_LINK) $(am_libgpgme_glib_la_rpath) $(libgpgme_glib_la_OBJECTS) $(libgpgme_glib_la_LIBADD) $(LIBS)
836
837 libgpgme.la: $(libgpgme_la_OBJECTS) $(libgpgme_la_DEPENDENCIES) $(EXTRA_libgpgme_la_DEPENDENCIES)
838 $(AM_V_CCLD)$(libgpgme_la_LINK) -rpath $(libdir) $(libgpgme_la_OBJECTS) $(libgpgme_la_LIBADD) $(LIBS)
839
840 gpgme-json$(EXEEXT): $(gpgme_json_OBJECTS) $(gpgme_json_DEPENDENCIES) $(EXTRA_gpgme_json_DEPENDENCIES)
841 @rm -f gpgme-json$(EXEEXT)
842 $(AM_V_CCLD)$(LINK) $(gpgme_json_OBJECTS) $(gpgme_json_LDADD) $(LIBS)
843
844 gpgme-tool$(EXEEXT): $(gpgme_tool_OBJECTS) $(gpgme_tool_DEPENDENCIES) $(EXTRA_gpgme_tool_DEPENDENCIES)
845 @rm -f gpgme-tool$(EXEEXT)
846 $(AM_V_CCLD)$(LINK) $(gpgme_tool_OBJECTS) $(gpgme_tool_LDADD) $(LIBS)
847
848 gpgme-w32spawn$(EXEEXT): $(gpgme_w32spawn_OBJECTS) $(gpgme_w32spawn_DEPENDENCIES) $(EXTRA_gpgme_w32spawn_DEPENDENCIES)
849 @rm -f gpgme-w32spawn$(EXEEXT)
850 $(AM_V_CCLD)$(LINK) $(gpgme_w32spawn_OBJECTS) $(gpgme_w32spawn_LDADD) $(LIBS)
851 install-binSCRIPTS: $(bin_SCRIPTS)
852 @$(NORMAL_INSTALL)
853 @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \
854 if test -n "$$list"; then \
855 echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
856 $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
857 fi; \
858 for p in $$list; do \
859 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
860 if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \
861 done | \
862 sed -e 'p;s,.*/,,;n' \
863 -e 'h;s|.*|.|' \
864 -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \
865 $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \
866 { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
867 if ($$2 == $$4) { files[d] = files[d] " " $$1; \
868 if (++n[d] == $(am__install_max)) { \
869 print "f", d, files[d]; n[d] = 0; files[d] = "" } } \
870 else { print "f", d "/" $$4, $$1 } } \
871 END { for (d in files) print "f", d, files[d] }' | \
872 while read type dir files; do \
873 if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
874 test -z "$$files" || { \
875 echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \
876 $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
877 } \
878 ; done
879
880 uninstall-binSCRIPTS:
881 @$(NORMAL_UNINSTALL)
882 @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \
883 files=`for p in $$list; do echo "$$p"; done | \
884 sed -e 's,.*/,,;$(transform)'`; \
885 dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir)
886
887 mostlyclean-compile:
888 -rm -f *.$(OBJEXT)
889
890 distclean-compile:
891 -rm -f *.tab.c
892
893 @AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/setenv.Plo@am__quote@ # am--include-marker
894 @AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/stpcpy.Plo@am__quote@ # am--include-marker
895 @AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/ttyname_r.Plo@am__quote@ # am--include-marker
896 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/argparse.Po@am__quote@ # am--include-marker
897 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/assuan-support.Plo@am__quote@ # am--include-marker
898 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ath.Plo@am__quote@ # am--include-marker
899 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/b64dec.Plo@am__quote@ # am--include-marker
900 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cJSON.Po@am__quote@ # am--include-marker
901 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/conversion.Plo@am__quote@ # am--include-marker
902 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-compat.Plo@am__quote@ # am--include-marker
903 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-estream.Plo@am__quote@ # am--include-marker
904 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-fd.Plo@am__quote@ # am--include-marker
905 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-identify.Plo@am__quote@ # am--include-marker
906 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-mem.Plo@am__quote@ # am--include-marker
907 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-stream.Plo@am__quote@ # am--include-marker
908 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data-user.Plo@am__quote@ # am--include-marker
909 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data.Plo@am__quote@ # am--include-marker
910 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/debug.Plo@am__quote@ # am--include-marker
911 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decrypt-verify.Plo@am__quote@ # am--include-marker
912 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decrypt.Plo@am__quote@ # am--include-marker
913 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/delete.Plo@am__quote@ # am--include-marker
914 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dirinfo.Plo@am__quote@ # am--include-marker
915 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/edit.Plo@am__quote@ # am--include-marker
916 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/encrypt-sign.Plo@am__quote@ # am--include-marker
917 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/encrypt.Plo@am__quote@ # am--include-marker
918 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-assuan.Plo@am__quote@ # am--include-marker
919 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-g13.Plo@am__quote@ # am--include-marker
920 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-gpg.Plo@am__quote@ # am--include-marker
921 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-gpgconf.Plo@am__quote@ # am--include-marker
922 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-gpgsm.Plo@am__quote@ # am--include-marker
923 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-spawn.Plo@am__quote@ # am--include-marker
924 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine-uiserver.Plo@am__quote@ # am--include-marker
925 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/engine.Plo@am__quote@ # am--include-marker
926 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error.Plo@am__quote@ # am--include-marker
927 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/export.Plo@am__quote@ # am--include-marker
928 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/genkey.Plo@am__quote@ # am--include-marker
929 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get-env.Plo@am__quote@ # am--include-marker
930 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getauditlog.Plo@am__quote@ # am--include-marker
931 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgconf.Plo@am__quote@ # am--include-marker
932 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgme-json.Po@am__quote@ # am--include-marker
933 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgme-tool.Po@am__quote@ # am--include-marker
934 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgme-w32spawn.Po@am__quote@ # am--include-marker
935 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpgme.Plo@am__quote@ # am--include-marker
936 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/import.Plo@am__quote@ # am--include-marker
937 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/key.Plo@am__quote@ # am--include-marker
938 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keylist.Plo@am__quote@ # am--include-marker
939 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keysign.Plo@am__quote@ # am--include-marker
940 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mbox-util.Plo@am__quote@ # am--include-marker
941 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/op-support.Plo@am__quote@ # am--include-marker
942 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/opassuan.Plo@am__quote@ # am--include-marker
943 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsetlv.Plo@am__quote@ # am--include-marker
944 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/passphrase.Plo@am__quote@ # am--include-marker
945 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/passwd.Plo@am__quote@ # am--include-marker
946 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/posix-io.Plo@am__quote@ # am--include-marker
947 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/posix-util.Plo@am__quote@ # am--include-marker
948 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/progress.Plo@am__quote@ # am--include-marker
949 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/queryswdb.Plo@am__quote@ # am--include-marker
950 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/revsig.Plo@am__quote@ # am--include-marker
951 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setexpire.Plo@am__quote@ # am--include-marker
952 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sig-notation.Plo@am__quote@ # am--include-marker
953 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sign.Plo@am__quote@ # am--include-marker
954 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/signers.Plo@am__quote@ # am--include-marker
955 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/spawn.Plo@am__quote@ # am--include-marker
956 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/status-table.Plo@am__quote@ # am--include-marker
957 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tofupolicy.Plo@am__quote@ # am--include-marker
958 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trust-item.Plo@am__quote@ # am--include-marker
959 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trustlist.Plo@am__quote@ # am--include-marker
960 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/verify.Plo@am__quote@ # am--include-marker
961 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Plo@am__quote@ # am--include-marker
962 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vfs-create.Plo@am__quote@ # am--include-marker
963 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vfs-mount.Plo@am__quote@ # am--include-marker
964 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/w32-glib-io.Plo@am__quote@ # am--include-marker
965 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/w32-io.Plo@am__quote@ # am--include-marker
966 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/w32-util.Plo@am__quote@ # am--include-marker
967 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wait-global.Plo@am__quote@ # am--include-marker
968 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wait-private.Plo@am__quote@ # am--include-marker
969 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wait-user.Plo@am__quote@ # am--include-marker
970 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wait.Plo@am__quote@ # am--include-marker
971
972 $(am__depfiles_remade):
973 @$(MKDIR_P) $(@D)
974 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
975
976 am--depfiles: $(am__depfiles_remade)
977
978 .c.o:
979 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
980 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
981 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
982 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
983 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
984
985 .c.obj:
986 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
987 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
988 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
989 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
990 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
991
992 .c.lo:
993 @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
994 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
995 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
996 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
997 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
998
999 mostlyclean-libtool:
1000 -rm -f *.lo
1001
1002 clean-libtool:
1003 -rm -rf .libs _libs
1004 install-m4dataDATA: $(m4data_DATA)
1005 @$(NORMAL_INSTALL)
1006 @list='$(m4data_DATA)'; test -n "$(m4datadir)" || list=; \
1007 if test -n "$$list"; then \
1008 echo " $(MKDIR_P) '$(DESTDIR)$(m4datadir)'"; \
1009 $(MKDIR_P) "$(DESTDIR)$(m4datadir)" || exit 1; \
1010 fi; \
1011 for p in $$list; do \
1012 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
1013 echo "$$d$$p"; \
1014 done | $(am__base_list) | \
1015 while read files; do \
1016 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(m4datadir)'"; \
1017 $(INSTALL_DATA) $$files "$(DESTDIR)$(m4datadir)" || exit $$?; \
1018 done
1019
1020 uninstall-m4dataDATA:
1021 @$(NORMAL_UNINSTALL)
1022 @list='$(m4data_DATA)'; test -n "$(m4datadir)" || list=; \
1023 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
1024 dir='$(DESTDIR)$(m4datadir)'; $(am__uninstall_files_from_dir)
1025 install-pkgconfigDATA: $(pkgconfig_DATA)
1026 @$(NORMAL_INSTALL)
1027 @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \
1028 if test -n "$$list"; then \
1029 echo " $(MKDIR_P) '$(DESTDIR)$(pkgconfigdir)'"; \
1030 $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" || exit 1; \
1031 fi; \
1032 for p in $$list; do \
1033 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
1034 echo "$$d$$p"; \
1035 done | $(am__base_list) | \
1036 while read files; do \
1037 echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \
1038 $(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \
1039 done
1040
1041 uninstall-pkgconfigDATA:
1042 @$(NORMAL_UNINSTALL)
1043 @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \
1044 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
1045 dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir)
1046 install-nodist_includeHEADERS: $(nodist_include_HEADERS)
1047 @$(NORMAL_INSTALL)
1048 @list='$(nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \
1049 if test -n "$$list"; then \
1050 echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
1051 $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
1052 fi; \
1053 for p in $$list; do \
1054 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
1055 echo "$$d$$p"; \
1056 done | $(am__base_list) | \
1057 while read files; do \
1058 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
1059 $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
1060 done
1061
1062 uninstall-nodist_includeHEADERS:
1063 @$(NORMAL_UNINSTALL)
1064 @list='$(nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \
1065 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
1066 dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
1067
1068 ID: $(am__tagged_files)
1069 $(am__define_uniq_tagged_files); mkid -fID $$unique
1070 tags: tags-am
1071 TAGS: tags
1072
1073 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
1074 set x; \
1075 here=`pwd`; \
1076 $(am__define_uniq_tagged_files); \
1077 shift; \
1078 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
1079 test -n "$$unique" || unique=$$empty_fix; \
1080 if test $$# -gt 0; then \
1081 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
1082 "$$@" $$unique; \
1083 else \
1084 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
1085 $$unique; \
1086 fi; \
1087 fi
1088 ctags: ctags-am
1089
1090 CTAGS: ctags
1091 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
1092 $(am__define_uniq_tagged_files); \
1093 test -z "$(CTAGS_ARGS)$$unique" \
1094 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
1095 $$unique
1096
1097 GTAGS:
1098 here=`$(am__cd) $(top_builddir) && pwd` \
1099 && $(am__cd) $(top_srcdir) \
1100 && gtags -i $(GTAGS_ARGS) "$$here"
1101 cscopelist: cscopelist-am
1102
1103 cscopelist-am: $(am__tagged_files)
1104 list='$(am__tagged_files)'; \
1105 case "$(srcdir)" in \
1106 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
1107 *) sdir=$(subdir)/$(srcdir) ;; \
1108 esac; \
1109 for i in $$list; do \
1110 if test -f "$$i"; then \
1111 echo "$(subdir)/$$i"; \
1112 else \
1113 echo "$$sdir/$$i"; \
1114 fi; \
1115 done >> $(top_builddir)/cscope.files
1116
1117 distclean-tags:
1118 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
1119
1120 distdir: $(BUILT_SOURCES)
1121 $(MAKE) $(AM_MAKEFLAGS) distdir-am
1122
1123 distdir-am: $(DISTFILES)
1124 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
1125 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
1126 list='$(DISTFILES)'; \
1127 dist_files=`for file in $$list; do echo $$file; done | \
1128 sed -e "s|^$$srcdirstrip/||;t" \
1129 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
1130 case $$dist_files in \
1131 */*) $(MKDIR_P) `echo "$$dist_files" | \
1132 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
1133 sort -u` ;; \
1134 esac; \
1135 for file in $$dist_files; do \
1136 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
1137 if test -d $$d/$$file; then \
1138 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
1139 if test -d "$(distdir)/$$file"; then \
1140 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
1141 fi; \
1142 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
1143 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
1144 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
1145 fi; \
1146 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
1147 else \
1148 test -f "$(distdir)/$$file" \
1149 || cp -p $$d/$$file "$(distdir)/$$file" \
1150 || exit 1; \
1151 fi; \
1152 done
1153 check-am: all-am
1154 check: check-am
1155 all-am: Makefile $(PROGRAMS) $(LTLIBRARIES) $(SCRIPTS) $(DATA) \
1156 $(HEADERS)
1157 install-binPROGRAMS: install-libLTLIBRARIES
1158
1159 installdirs:
1160 for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(m4datadir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)"; do \
1161 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
1162 done
1163 install: install-am
1164 install-exec: install-exec-am
1165 install-data: install-data-am
1166 uninstall: uninstall-am
1167
1168 install-am: all-am
1169 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
1170
1171 installcheck: installcheck-am
1172 install-strip:
1173 if test -z '$(STRIP)'; then \
1174 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1175 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1176 install; \
1177 else \
1178 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1179 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1180 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
1181 fi
1182 mostlyclean-generic:
1183
1184 clean-generic:
1185
1186 distclean-generic:
1187 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
1188 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
1189
1190 maintainer-clean-generic:
1191 @echo "This command is intended for maintainers to use"
1192 @echo "it deletes files that may require special tools to rebuild."
1193 clean: clean-am
1194
1195 clean-am: clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \
1196 clean-libexecPROGRAMS clean-libtool mostlyclean-am
1197
1198 distclean: distclean-am
1199 -rm -f $(DEPDIR)/setenv.Plo
1200 -rm -f $(DEPDIR)/stpcpy.Plo
1201 -rm -f $(DEPDIR)/ttyname_r.Plo
1202 -rm -f ./$(DEPDIR)/argparse.Po
1203 -rm -f ./$(DEPDIR)/assuan-support.Plo
1204 -rm -f ./$(DEPDIR)/ath.Plo
1205 -rm -f ./$(DEPDIR)/b64dec.Plo
1206 -rm -f ./$(DEPDIR)/cJSON.Po
1207 -rm -f ./$(DEPDIR)/conversion.Plo
1208 -rm -f ./$(DEPDIR)/data-compat.Plo
1209 -rm -f ./$(DEPDIR)/data-estream.Plo
1210 -rm -f ./$(DEPDIR)/data-fd.Plo
1211 -rm -f ./$(DEPDIR)/data-identify.Plo
1212 -rm -f ./$(DEPDIR)/data-mem.Plo
1213 -rm -f ./$(DEPDIR)/data-stream.Plo
1214 -rm -f ./$(DEPDIR)/data-user.Plo
1215 -rm -f ./$(DEPDIR)/data.Plo
1216 -rm -f ./$(DEPDIR)/debug.Plo
1217 -rm -f ./$(DEPDIR)/decrypt-verify.Plo
1218 -rm -f ./$(DEPDIR)/decrypt.Plo
1219 -rm -f ./$(DEPDIR)/delete.Plo
1220 -rm -f ./$(DEPDIR)/dirinfo.Plo
1221 -rm -f ./$(DEPDIR)/edit.Plo
1222 -rm -f ./$(DEPDIR)/encrypt-sign.Plo
1223 -rm -f ./$(DEPDIR)/encrypt.Plo
1224 -rm -f ./$(DEPDIR)/engine-assuan.Plo
1225 -rm -f ./$(DEPDIR)/engine-g13.Plo
1226 -rm -f ./$(DEPDIR)/engine-gpg.Plo
1227 -rm -f ./$(DEPDIR)/engine-gpgconf.Plo
1228 -rm -f ./$(DEPDIR)/engine-gpgsm.Plo
1229 -rm -f ./$(DEPDIR)/engine-spawn.Plo
1230 -rm -f ./$(DEPDIR)/engine-uiserver.Plo
1231 -rm -f ./$(DEPDIR)/engine.Plo
1232 -rm -f ./$(DEPDIR)/error.Plo
1233 -rm -f ./$(DEPDIR)/export.Plo
1234 -rm -f ./$(DEPDIR)/genkey.Plo
1235 -rm -f ./$(DEPDIR)/get-env.Plo
1236 -rm -f ./$(DEPDIR)/getauditlog.Plo
1237 -rm -f ./$(DEPDIR)/gpgconf.Plo
1238 -rm -f ./$(DEPDIR)/gpgme-json.Po
1239 -rm -f ./$(DEPDIR)/gpgme-tool.Po
1240 -rm -f ./$(DEPDIR)/gpgme-w32spawn.Po
1241 -rm -f ./$(DEPDIR)/gpgme.Plo
1242 -rm -f ./$(DEPDIR)/import.Plo
1243 -rm -f ./$(DEPDIR)/key.Plo
1244 -rm -f ./$(DEPDIR)/keylist.Plo
1245 -rm -f ./$(DEPDIR)/keysign.Plo
1246 -rm -f ./$(DEPDIR)/mbox-util.Plo
1247 -rm -f ./$(DEPDIR)/op-support.Plo
1248 -rm -f ./$(DEPDIR)/opassuan.Plo
1249 -rm -f ./$(DEPDIR)/parsetlv.Plo
1250 -rm -f ./$(DEPDIR)/passphrase.Plo
1251 -rm -f ./$(DEPDIR)/passwd.Plo
1252 -rm -f ./$(DEPDIR)/posix-io.Plo
1253 -rm -f ./$(DEPDIR)/posix-util.Plo
1254 -rm -f ./$(DEPDIR)/progress.Plo
1255 -rm -f ./$(DEPDIR)/queryswdb.Plo
1256 -rm -f ./$(DEPDIR)/revsig.Plo
1257 -rm -f ./$(DEPDIR)/setexpire.Plo
1258 -rm -f ./$(DEPDIR)/sig-notation.Plo
1259 -rm -f ./$(DEPDIR)/sign.Plo
1260 -rm -f ./$(DEPDIR)/signers.Plo
1261 -rm -f ./$(DEPDIR)/spawn.Plo
1262 -rm -f ./$(DEPDIR)/status-table.Plo
1263 -rm -f ./$(DEPDIR)/tofupolicy.Plo
1264 -rm -f ./$(DEPDIR)/trust-item.Plo
1265 -rm -f ./$(DEPDIR)/trustlist.Plo
1266 -rm -f ./$(DEPDIR)/verify.Plo
1267 -rm -f ./$(DEPDIR)/version.Plo
1268 -rm -f ./$(DEPDIR)/vfs-create.Plo
1269 -rm -f ./$(DEPDIR)/vfs-mount.Plo
1270 -rm -f ./$(DEPDIR)/w32-glib-io.Plo
1271 -rm -f ./$(DEPDIR)/w32-io.Plo
1272 -rm -f ./$(DEPDIR)/w32-util.Plo
1273 -rm -f ./$(DEPDIR)/wait-global.Plo
1274 -rm -f ./$(DEPDIR)/wait-private.Plo
1275 -rm -f ./$(DEPDIR)/wait-user.Plo
1276 -rm -f ./$(DEPDIR)/wait.Plo
1277 -rm -f Makefile
1278 distclean-am: clean-am distclean-compile distclean-generic \
1279 distclean-tags
1280
1281 dvi: dvi-am
1282
1283 dvi-am:
1284
1285 html: html-am
1286
1287 html-am:
1288
1289 info: info-am
1290
1291 info-am:
1292
1293 install-data-am: install-data-local install-m4dataDATA \
1294 install-nodist_includeHEADERS install-pkgconfigDATA
1295
1296 install-dvi: install-dvi-am
1297
1298 install-dvi-am:
1299
1300 install-exec-am: install-binPROGRAMS install-binSCRIPTS \
1301 install-libLTLIBRARIES install-libexecPROGRAMS
1302
1303 install-html: install-html-am
1304
1305 install-html-am:
1306
1307 install-info: install-info-am
1308
1309 install-info-am:
1310
1311 install-man:
1312
1313 install-pdf: install-pdf-am
1314
1315 install-pdf-am:
1316
1317 install-ps: install-ps-am
1318
1319 install-ps-am:
1320
1321 installcheck-am:
1322
1323 maintainer-clean: maintainer-clean-am
1324 -rm -f $(DEPDIR)/setenv.Plo
1325 -rm -f $(DEPDIR)/stpcpy.Plo
1326 -rm -f $(DEPDIR)/ttyname_r.Plo
1327 -rm -f ./$(DEPDIR)/argparse.Po
1328 -rm -f ./$(DEPDIR)/assuan-support.Plo
1329 -rm -f ./$(DEPDIR)/ath.Plo
1330 -rm -f ./$(DEPDIR)/b64dec.Plo
1331 -rm -f ./$(DEPDIR)/cJSON.Po
1332 -rm -f ./$(DEPDIR)/conversion.Plo
1333 -rm -f ./$(DEPDIR)/data-compat.Plo
1334 -rm -f ./$(DEPDIR)/data-estream.Plo
1335 -rm -f ./$(DEPDIR)/data-fd.Plo
1336 -rm -f ./$(DEPDIR)/data-identify.Plo
1337 -rm -f ./$(DEPDIR)/data-mem.Plo
1338 -rm -f ./$(DEPDIR)/data-stream.Plo
1339 -rm -f ./$(DEPDIR)/data-user.Plo
1340 -rm -f ./$(DEPDIR)/data.Plo
1341 -rm -f ./$(DEPDIR)/debug.Plo
1342 -rm -f ./$(DEPDIR)/decrypt-verify.Plo
1343 -rm -f ./$(DEPDIR)/decrypt.Plo
1344 -rm -f ./$(DEPDIR)/delete.Plo
1345 -rm -f ./$(DEPDIR)/dirinfo.Plo
1346 -rm -f ./$(DEPDIR)/edit.Plo
1347 -rm -f ./$(DEPDIR)/encrypt-sign.Plo
1348 -rm -f ./$(DEPDIR)/encrypt.Plo
1349 -rm -f ./$(DEPDIR)/engine-assuan.Plo
1350 -rm -f ./$(DEPDIR)/engine-g13.Plo
1351 -rm -f ./$(DEPDIR)/engine-gpg.Plo
1352 -rm -f ./$(DEPDIR)/engine-gpgconf.Plo
1353 -rm -f ./$(DEPDIR)/engine-gpgsm.Plo
1354 -rm -f ./$(DEPDIR)/engine-spawn.Plo
1355 -rm -f ./$(DEPDIR)/engine-uiserver.Plo
1356 -rm -f ./$(DEPDIR)/engine.Plo
1357 -rm -f ./$(DEPDIR)/error.Plo
1358 -rm -f ./$(DEPDIR)/export.Plo
1359 -rm -f ./$(DEPDIR)/genkey.Plo
1360 -rm -f ./$(DEPDIR)/get-env.Plo
1361 -rm -f ./$(DEPDIR)/getauditlog.Plo
1362 -rm -f ./$(DEPDIR)/gpgconf.Plo
1363 -rm -f ./$(DEPDIR)/gpgme-json.Po
1364 -rm -f ./$(DEPDIR)/gpgme-tool.Po
1365 -rm -f ./$(DEPDIR)/gpgme-w32spawn.Po
1366 -rm -f ./$(DEPDIR)/gpgme.Plo
1367 -rm -f ./$(DEPDIR)/import.Plo
1368 -rm -f ./$(DEPDIR)/key.Plo
1369 -rm -f ./$(DEPDIR)/keylist.Plo
1370 -rm -f ./$(DEPDIR)/keysign.Plo
1371 -rm -f ./$(DEPDIR)/mbox-util.Plo
1372 -rm -f ./$(DEPDIR)/op-support.Plo
1373 -rm -f ./$(DEPDIR)/opassuan.Plo
1374 -rm -f ./$(DEPDIR)/parsetlv.Plo
1375 -rm -f ./$(DEPDIR)/passphrase.Plo
1376 -rm -f ./$(DEPDIR)/passwd.Plo
1377 -rm -f ./$(DEPDIR)/posix-io.Plo
1378 -rm -f ./$(DEPDIR)/posix-util.Plo
1379 -rm -f ./$(DEPDIR)/progress.Plo
1380 -rm -f ./$(DEPDIR)/queryswdb.Plo
1381 -rm -f ./$(DEPDIR)/revsig.Plo
1382 -rm -f ./$(DEPDIR)/setexpire.Plo
1383 -rm -f ./$(DEPDIR)/sig-notation.Plo
1384 -rm -f ./$(DEPDIR)/sign.Plo
1385 -rm -f ./$(DEPDIR)/signers.Plo
1386 -rm -f ./$(DEPDIR)/spawn.Plo
1387 -rm -f ./$(DEPDIR)/status-table.Plo
1388 -rm -f ./$(DEPDIR)/tofupolicy.Plo
1389 -rm -f ./$(DEPDIR)/trust-item.Plo
1390 -rm -f ./$(DEPDIR)/trustlist.Plo
1391 -rm -f ./$(DEPDIR)/verify.Plo
1392 -rm -f ./$(DEPDIR)/version.Plo
1393 -rm -f ./$(DEPDIR)/vfs-create.Plo
1394 -rm -f ./$(DEPDIR)/vfs-mount.Plo
1395 -rm -f ./$(DEPDIR)/w32-glib-io.Plo
1396 -rm -f ./$(DEPDIR)/w32-io.Plo
1397 -rm -f ./$(DEPDIR)/w32-util.Plo
1398 -rm -f ./$(DEPDIR)/wait-global.Plo
1399 -rm -f ./$(DEPDIR)/wait-private.Plo
1400 -rm -f ./$(DEPDIR)/wait-user.Plo
1401 -rm -f ./$(DEPDIR)/wait.Plo
1402 -rm -f Makefile
1403 maintainer-clean-am: distclean-am maintainer-clean-generic
1404
1405 mostlyclean: mostlyclean-am
1406
1407 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
1408 mostlyclean-libtool
1409
1410 pdf: pdf-am
1411
1412 pdf-am:
1413
1414 ps: ps-am
1415
1416 ps-am:
1417
1418 uninstall-am: uninstall-binPROGRAMS uninstall-binSCRIPTS \
1419 uninstall-libLTLIBRARIES uninstall-libexecPROGRAMS \
1420 uninstall-local uninstall-m4dataDATA \
1421 uninstall-nodist_includeHEADERS uninstall-pkgconfigDATA
1422
1423 .MAKE: install-am install-strip
1424
1425 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
1426 clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \
1427 clean-libexecPROGRAMS clean-libtool cscopelist-am ctags \
1428 ctags-am distclean distclean-compile distclean-generic \
1429 distclean-libtool distclean-tags distdir dvi dvi-am html \
1430 html-am info info-am install install-am install-binPROGRAMS \
1431 install-binSCRIPTS install-data install-data-am \
1432 install-data-local install-dvi install-dvi-am install-exec \
1433 install-exec-am install-html install-html-am install-info \
1434 install-info-am install-libLTLIBRARIES install-libexecPROGRAMS \
1435 install-m4dataDATA install-man install-nodist_includeHEADERS \
1436 install-pdf install-pdf-am install-pkgconfigDATA install-ps \
1437 install-ps-am install-strip installcheck installcheck-am \
1438 installdirs maintainer-clean maintainer-clean-generic \
1439 mostlyclean mostlyclean-compile mostlyclean-generic \
1440 mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
1441 uninstall-am uninstall-binPROGRAMS uninstall-binSCRIPTS \
1442 uninstall-libLTLIBRARIES uninstall-libexecPROGRAMS \
1443 uninstall-local uninstall-m4dataDATA \
1444 uninstall-nodist_includeHEADERS uninstall-pkgconfigDATA
1445
1446 .PRECIOUS: Makefile
1447
1448
1449 @HAVE_W32_SYSTEM_TRUE@.rc.lo:
1450 @HAVE_W32_SYSTEM_TRUE@ $(LTRCCOMPILE) -i "$<" -o "$@"
1451
1452 @HAVE_W32_SYSTEM_TRUE@install-def-file:
1453 @HAVE_W32_SYSTEM_TRUE@ -$(INSTALL) -d $(DESTDIR)$(libdir)
1454 @HAVE_W32_SYSTEM_TRUE@ $(INSTALL) $(srcdir)/gpgme.def $(DESTDIR)$(libdir)/gpgme.def
1455
1456 @HAVE_W32_SYSTEM_TRUE@uninstall-def-file:
1457 @HAVE_W32_SYSTEM_TRUE@ -rm $(DESTDIR)$(libdir)/gpgme.def
1458 @HAVE_W32_SYSTEM_FALSE@install-def-file:
1459 @HAVE_W32_SYSTEM_FALSE@uninstall-def-file:
1460
1461 install-data-local: install-def-file
1462
1463 uninstall-local: uninstall-def-file
1464
1465 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1466 # Otherwise a system limit (for SysV at least) may be exceeded.
1467 .NOEXPORT:
2525 #ifdef HAVE_UNISTD_H
2626 # include <unistd.h>
2727 #endif
28 #ifdef HAVE_SYS_SELECT_H
29 # include <sys/select.h>
28 #ifdef HAVE_POLL_H
29 # include <poll.h>
3030 #else
31 # ifdef HAVE_SYS_TIME_H
32 # include <sys/time.h>
31 # ifdef HAVE_SYS_SELECT_H
32 # include <sys/select.h>
33 # else
34 # ifdef HAVE_SYS_TIME_H
35 # include <sys/time.h>
36 # endif
3337 # endif
3438 #endif
3539 #ifdef HAVE_SYS_TYPES_H
8892 }
8993
9094
95 #if !defined(HAVE_POLL_H)
9196 gpgme_ssize_t
9297 ath_select (int nfd, fd_set *rset, fd_set *wset, fd_set *eset,
9398 struct timeval *timeout)
98103 return select (nfd, rset, wset, eset, timeout);
99104 #endif
100105 }
101
106 #endif
102107
103108 gpgme_ssize_t
104109 ath_waitpid (pid_t pid, int *status, int options)
3131 # include <io.h>
3232
3333 #else /*!HAVE_W32_SYSTEM*/
34
35 # ifdef HAVE_SYS_SELECT_H
36 # include <sys/select.h>
34 # ifdef HAVE_POLL_H
35 # include <poll.h>
3736 # else
38 # ifdef HAVE_SYS_TIME_H
39 # include <sys/time.h>
37 # ifdef HAVE_SYS_SELECT_H
38 # include <sys/select.h>
39 # else
40 # ifdef HAVE_SYS_TIME_H
41 # include <sys/time.h>
42 # endif
4043 # endif
4144 # endif
4245 # ifdef HAVE_SYS_TYPES_H
176176 /* The optional expiration date of a certification. */
177177 char *cert_expire;
178178
179 /* The optional key origin. */
180 char *key_origin;
181
182 /* The optional import filter. */
183 char *import_filter;
184
179185 /* The operation data hooked into the context. */
180186 ctx_op_data_t op_data;
181187
390390 while (res < 0 && errno == EINTR);
391391 }
392392
393 return TRACE_SYSRES ((int)res);
393 return TRACE_SYSRES_SSIZE_T (res);
394394 }
395395
396396
418418 res = (*dh->cbs->write) (dh, buffer, size);
419419 while (res < 0 && errno == EINTR);
420420
421 return TRACE_SYSRES ((int)res);
421 return TRACE_SYSRES_SSIZE_T (res);
422422 }
423423
424424
451451 if (offset >= 0)
452452 dh->outbound_pending = 0;
453453
454 return TRACE_SYSRES ((int)offset);
454 return TRACE_SYSRES_OFF_T (offset);
455455 }
456456
457457
140140 return err;
141141 }
142142
143 /* Trace a system call result and return it. */
143 /* Trace a system call result of type int and return it. */
144144 #define TRACE_SYSRES(res) \
145145 _trace_sysres ((res), _gpgme_trace_level, _gpgme_trace_func, __LINE__)
146146 static inline int
148148 {
149149 if (res >= 0)
150150 _gpgme_debug (NULL, lvl, 3, func, NULL, NULL, "result=%d", res);
151 else
152 _gpgme_debug (NULL, lvl, -1, NULL, NULL, NULL,
153 "%s:%d: error: %s (%d)\n",
154 func, line, strerror (errno), errno);
155 _gpgme_debug_frame_end ();
156 return res;
157 }
158
159 /* Trace a system call result of type gpgme_off_t and return it. */
160 #define TRACE_SYSRES_OFF_T(res) \
161 _trace_sysres_off_t ((res), _gpgme_trace_level, _gpgme_trace_func, __LINE__)
162 static inline gpgme_off_t
163 _trace_sysres_off_t (gpgme_off_t res, int lvl, const char *func, int line)
164 {
165 if (res >= 0)
166 _gpgme_debug (NULL, lvl, 3, func, NULL, NULL, "result=%ld", res);
167 else
168 _gpgme_debug (NULL, lvl, -1, NULL, NULL, NULL,
169 "%s:%d: error: %s (%d)\n",
170 func, line, strerror (errno), errno);
171 _gpgme_debug_frame_end ();
172 return res;
173 }
174
175 /* Trace a system call result of type gpgme_ssize_t and return it. */
176 #define TRACE_SYSRES_SSIZE_T(res) \
177 _trace_sysres_ssize_t ((res), _gpgme_trace_level, _gpgme_trace_func, __LINE__)
178 static inline gpgme_ssize_t
179 _trace_sysres_ssize_t (gpgme_ssize_t res, int lvl, const char *func, int line)
180 {
181 if (res >= 0)
182 _gpgme_debug (NULL, lvl, 3, func, NULL, NULL, "result=%zd", res);
151183 else
152184 _gpgme_debug (NULL, lvl, -1, NULL, NULL, NULL,
153185 "%s:%d: error: %s (%d)\n",
4343 WANT_LIBDIR,
4444 WANT_DATADIR,
4545 WANT_LOCALEDIR,
46 WANT_SOCKETDIR,
4647 WANT_AGENT_SOCKET,
4748 WANT_AGENT_SSH_SOCKET,
4849 WANT_DIRMNGR_SOCKET,
5152 WANT_GPG_NAME,
5253 WANT_GPGSM_NAME,
5354 WANT_G13_NAME,
55 WANT_KEYBOXD_NAME,
56 WANT_AGENT_NAME,
57 WANT_SCDAEMON_NAME,
58 WANT_DIRMNGR_NAME,
59 WANT_PINENTRY_NAME,
5460 WANT_GPG_WKS_CLIENT_NAME,
5561 WANT_GPG_ONE_MODE
5662 };
6672 char *libdir;
6773 char *datadir;
6874 char *localedir;
75 char *socketdir;
6976 char *agent_socket;
7077 char *agent_ssh_socket;
7178 char *dirmngr_socket;
7481 char *gpg_name;
7582 char *gpgsm_name;
7683 char *g13_name;
84 char *keyboxd_name;
85 char *agent_name;
86 char *scdaemon_name;
87 char *dirmngr_name;
88 char *pinentry_name;
7789 char *gpg_wks_client_name;
7890 int gpg_one_mode; /* System is in gpg1 mode. */
7991 } dirinfo;
134146 dirinfo.gpgsm_name = strdup (value);
135147 else if (!strcmp (line, "g13") && !dirinfo.g13_name)
136148 dirinfo.g13_name = strdup (value);
149 else if (!strcmp (line, "keyboxd") && !dirinfo.keyboxd_name)
150 dirinfo.keyboxd_name = strdup (value);
151 else if (!strcmp (line, "gpg-agent") && !dirinfo.agent_name)
152 dirinfo.agent_name = strdup (value);
153 else if (!strcmp (line, "scdaemon") && !dirinfo.scdaemon_name)
154 dirinfo.scdaemon_name = strdup (value);
155 else if (!strcmp (line, "dirmngr") && !dirinfo.dirmngr_name)
156 dirinfo.dirmngr_name = strdup (value);
157 else if (!strcmp (line, "pinentry") && !dirinfo.pinentry_name)
158 dirinfo.pinentry_name = strdup (value);
137159 }
138160 else
139161 {
151173 dirinfo.datadir = strdup (value);
152174 else if (!strcmp (line, "localedir") && !dirinfo.localedir)
153175 dirinfo.localedir = strdup (value);
176 else if (!strcmp (line, "socketdir") && !dirinfo.socketdir)
177 dirinfo.socketdir = strdup (value);
154178 else if (!strcmp (line, "agent-socket") && !dirinfo.agent_socket)
155179 {
156180 const char name[] = "S.uiserver";
305329 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
306330 "gpgme-dinfo: gpgsm='%s'\n",
307331 dirinfo.gpgsm_name);
332 if (dirinfo.keyboxd_name)
333 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
334 "gpgme-dinfo: keyboxd='%s'\n",
335 dirinfo.keyboxd_name);
336 if (dirinfo.agent_name)
337 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
338 "gpgme-dinfo: gpg-agent='%s'\n",
339 dirinfo.agent_name);
340 if (dirinfo.scdaemon_name)
341 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
342 "gpgme-dinfo: scdaemon='%s'\n",
343 dirinfo.scdaemon_name);
344 if (dirinfo.dirmngr_name)
345 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
346 "gpgme-dinfo: dirmngr='%s'\n",
347 dirinfo.dirmngr_name);
348 if (dirinfo.pinentry_name)
349 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
350 "gpgme-dinfo: pinentry='%s'\n",
351 dirinfo.pinentry_name);
308352 if (dirinfo.homedir)
309353 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
310354 "gpgme-dinfo: homedir='%s'\n",
311355 dirinfo.homedir);
356 if (dirinfo.socketdir)
357 _gpgme_debug (NULL, DEBUG_INIT, -1, NULL, NULL, NULL,
358 "gpgme-dinfo: sockdir='%s'\n",
359 dirinfo.socketdir);
312360 if (dirinfo.agent_socket)
313361 _gpgme_debug (NULL,DEBUG_INIT, -1, NULL, NULL, NULL,
314362 "gpgme-dinfo: agent='%s'\n",
335383 case WANT_LIBDIR: result = dirinfo.libdir; break;
336384 case WANT_DATADIR: result = dirinfo.datadir; break;
337385 case WANT_LOCALEDIR: result = dirinfo.localedir; break;
386 case WANT_SOCKETDIR: result = dirinfo.socketdir; break;
338387 case WANT_AGENT_SOCKET: result = dirinfo.agent_socket; break;
339388 case WANT_AGENT_SSH_SOCKET: result = dirinfo.agent_ssh_socket; break;
340389 case WANT_DIRMNGR_SOCKET: result = dirinfo.dirmngr_socket; break;
342391 case WANT_GPG_NAME: result = dirinfo.gpg_name; break;
343392 case WANT_GPGSM_NAME: result = dirinfo.gpgsm_name; break;
344393 case WANT_G13_NAME: result = dirinfo.g13_name; break;
394 case WANT_KEYBOXD_NAME: result = dirinfo.keyboxd_name; break;
395 case WANT_AGENT_NAME: result = dirinfo.agent_name; break;
396 case WANT_SCDAEMON_NAME: result = dirinfo.scdaemon_name; break;
397 case WANT_DIRMNGR_NAME: result = dirinfo.dirmngr_name; break;
398 case WANT_PINENTRY_NAME: result = dirinfo.pinentry_name; break;
345399 case WANT_UISRV_SOCKET: result = dirinfo.uisrv_socket; break;
346400 case WANT_GPG_ONE_MODE: result = dirinfo.gpg_one_mode? "1":NULL; break;
347401 case WANT_GPG_WKS_CLIENT_NAME:
457511 return get_gpgconf_item (WANT_GPGSM_NAME);
458512 else if (!strcmp (what, "g13-name"))
459513 return get_gpgconf_item (WANT_G13_NAME);
514 else if (!strcmp (what, "keyboxd-name"))
515 return get_gpgconf_item (WANT_KEYBOXD_NAME);
516 else if (!strcmp (what, "agent-name"))
517 return get_gpgconf_item (WANT_AGENT_NAME);
518 else if (!strcmp (what, "scdaemon-name"))
519 return get_gpgconf_item (WANT_SCDAEMON_NAME);
520 else if (!strcmp (what, "dirmngr-name"))
521 return get_gpgconf_item (WANT_DIRMNGR_NAME);
522 else if (!strcmp (what, "pinentry-name"))
523 return get_gpgconf_item (WANT_PINENTRY_NAME);
460524 else if (!strcmp (what, "gpg-wks-client-name"))
461525 return get_gpgconf_item (WANT_GPG_WKS_CLIENT_NAME);
462526 else if (!strcmp (what, "agent-ssh-socket"))
475539 return get_gpgconf_item (WANT_DATADIR);
476540 else if (!strcmp (what, "localedir"))
477541 return get_gpgconf_item (WANT_LOCALEDIR);
542 else if (!strcmp (what, "socketdir"))
543 return get_gpgconf_item (WANT_SOCKETDIR);
478544 else
479545 return NULL;
480546 }
9494 unsigned int extraflags,
9595 gpgme_data_t pubkey, gpgme_data_t seckey);
9696 gpgme_error_t (*import) (void *engine, gpgme_data_t keydata,
97 gpgme_key_t *keyarray);
97 gpgme_key_t *keyarray,
98 const char *keyids[],
99 const char *import_filter,
100 const char *key_origin);
98101 gpgme_error_t (*keylist) (void *engine, const char *pattern,
99102 int secret_only, gpgme_keylist_mode_t mode,
100103 int engine_flags);
5858 int print_fd; /* Print the fd number and not the special form of it. */
5959 int *arg_locp; /* Write back the argv idx of this argument when
6060 building command line to this location. */
61 char arg[1]; /* Used if data above is not used. */
61 char arg[FLEXIBLE_ARRAY_MEMBER]; /* Used if data above is not used. */
6262 };
6363
6464
232232 assert (gpg);
233233 assert (arg);
234234
235 a = malloc (sizeof *a + prefixlen + arglen);
235 a = malloc (offsetof (struct arg_and_data_s, arg) + prefixlen + arglen + 1);
236236 if (!a)
237237 return gpg_error_from_syserror ();
238238
306306 assert (gpg);
307307 assert (data);
308308
309 a = malloc (sizeof *a - 1);
309 a = malloc (offsetof (struct arg_and_data_s, arg));
310310 if (!a)
311311 return gpg_error_from_syserror ();
312312 a->next = NULL;
23532353 if ((mode & ~(GPGME_EXPORT_MODE_EXTERN
23542354 |GPGME_EXPORT_MODE_MINIMAL
23552355 |GPGME_EXPORT_MODE_SSH
2356 |GPGME_EXPORT_MODE_SECRET)))
2356 |GPGME_EXPORT_MODE_SECRET
2357 |GPGME_EXPORT_MODE_SECRET_SUBKEY)))
23572358 return gpg_error (GPG_ERR_NOT_SUPPORTED);
23582359
23592360 if ((mode & GPGME_EXPORT_MODE_MINIMAL))
23782379 }
23792380 else
23802381 {
2381 if ((mode & GPGME_EXPORT_MODE_SECRET))
2382 if ((mode & GPGME_EXPORT_MODE_SECRET_SUBKEY))
2383 err = add_arg (gpg, "--export-secret-subkeys");
2384 else if ((mode & GPGME_EXPORT_MODE_SECRET))
23822385 err = add_arg (gpg, "--export-secret-keys");
23832386 else
23842387 err = add_arg (gpg, "--export");
27652768
27662769
27672770 static gpgme_error_t
2768 gpg_import (void *engine, gpgme_data_t keydata, gpgme_key_t *keyarray)
2771 gpg_import (void *engine, gpgme_data_t keydata, gpgme_key_t *keyarray,
2772 const char *keyids[], const char *import_filter,
2773 const char *key_origin)
27692774 {
27702775 engine_gpg_t gpg = engine;
27712776 gpgme_error_t err;
27722777 int idx;
27732778 gpgme_data_encoding_t dataenc;
27742779
2775 if (keydata && keyarray)
2780 if ((keydata && keyarray) || (keydata && keyids) || (keyarray && keyids))
27762781 return gpg_error (GPG_ERR_INV_VALUE); /* Only one is allowed. */
27772782
27782783 dataenc = gpgme_data_get_encoding (keydata);
27792784
2780 if (keyarray)
2785 if (keyids)
27812786 {
27822787 err = add_arg (gpg, "--recv-keys");
2788 if (!err && import_filter && have_gpg_version (gpg, "2.1.14"))
2789 {
2790 err = add_arg (gpg, "--import-filter");
2791 if (!err)
2792 err = add_arg (gpg, import_filter);
2793 }
2794 if (!err)
2795 err = add_arg (gpg, "--");
2796 while (!err && *keyids && **keyids)
2797 err = add_arg (gpg, *(keyids++));
2798 }
2799 else if (keyarray)
2800 {
2801 err = add_arg (gpg, "--recv-keys");
2802 if (!err && import_filter && have_gpg_version (gpg, "2.1.14"))
2803 {
2804 err = add_arg (gpg, "--import-filter");
2805 if (!err)
2806 err = add_arg (gpg, import_filter);
2807 }
27832808 if (!err)
27842809 err = add_arg (gpg, "--");
27852810 for (idx=0; !err && keyarray[idx]; idx++)
28112836 should use an option to gpg to modify such commands (ala
28122837 --multifile). */
28132838 err = add_arg (gpg, "--fetch-keys");
2839 if (!err && import_filter && have_gpg_version (gpg, "2.1.14"))
2840 {
2841 err = add_arg (gpg, "--import-filter");
2842 if (!err)
2843 err = add_arg (gpg, import_filter);
2844 }
28142845 if (!err)
28152846 err = add_arg (gpg, "--");
28162847 helpptr = NULL;
28292860 else
28302861 {
28312862 err = add_arg (gpg, "--import");
2863 if (!err && import_filter && have_gpg_version (gpg, "2.1.14"))
2864 {
2865 err = add_arg (gpg, "--import-filter");
2866 if (!err)
2867 err = add_arg (gpg, import_filter);
2868 }
2869 if (!err && key_origin && have_gpg_version (gpg, "2.1.22"))
2870 {
2871 err = add_arg (gpg, "--key-origin");
2872 if (!err)
2873 err = add_arg (gpg, key_origin);
2874 }
28322875 if (!err)
28332876 err = add_arg (gpg, "--");
28342877 if (!err)
444444 case GPGME_CONF_PUB_KEY:
445445 case GPGME_CONF_SEC_KEY:
446446 case GPGME_CONF_ALIAS_LIST:
447 /* Skip quote character. */
448 line++;
447 /* Skip quote character. It is required by specs but
448 * technically not always needed. */
449 if (*line == '\"' && line[1])
450 line++;
449451
450452 err = _gpgme_decode_percent_string (line, &arg->value.string,
451453 0, 0);
15111511 if (!gpgsm)
15121512 return gpg_error (GPG_ERR_INV_VALUE);
15131513
1514 if ((mode & ~(GPGME_EXPORT_MODE_SECRET
1515 |GPGME_EXPORT_MODE_MINIMAL
1516 |GPGME_EXPORT_MODE_RAW
1517 |GPGME_EXPORT_MODE_PKCS12)))
1518 return gpg_error (GPG_ERR_NOT_SUPPORTED);
1519
15141520 if (!pattern)
15151521 pattern = "";
15161522
15571563
15581564 if (!gpgsm)
15591565 return gpg_error (GPG_ERR_INV_VALUE);
1566
1567 if ((mode & ~(GPGME_EXPORT_MODE_SECRET
1568 |GPGME_EXPORT_MODE_MINIMAL
1569 |GPGME_EXPORT_MODE_RAW
1570 |GPGME_EXPORT_MODE_PKCS12)))
1571 return gpg_error (GPG_ERR_NOT_SUPPORTED);
15601572
15611573 if (pattern && *pattern)
15621574 {
16951707
16961708
16971709 static gpgme_error_t
1698 gpgsm_import (void *engine, gpgme_data_t keydata, gpgme_key_t *keyarray)
1710 gpgsm_import (void *engine, gpgme_data_t keydata, gpgme_key_t *keyarray,
1711 const char *keyids[], const char *import_filter,
1712 const char *key_origin)
16991713 {
17001714 engine_gpgsm_t gpgsm = engine;
17011715 gpgme_error_t err;
17021716 gpgme_data_encoding_t dataenc;
17031717 int idx;
17041718
1719 (void)import_filter;
1720 (void)key_origin;
1721
17051722 if (!gpgsm)
17061723 return gpg_error (GPG_ERR_INV_VALUE);
1724
1725 if (keyids)
1726 return gpg_error (GPG_ERR_NOT_IMPLEMENTED);
17071727
17081728 if (keydata && keyarray)
17091729 return gpg_error (GPG_ERR_INV_VALUE); /* Only one is allowed. */
849849
850850 gpgme_error_t
851851 _gpgme_engine_op_import (engine_t engine, gpgme_data_t keydata,
852 gpgme_key_t *keyarray)
852 gpgme_key_t *keyarray, const char *keyids[],
853 const char *import_filter, const char *key_origin)
853854 {
854855 if (!engine)
855856 return gpg_error (GPG_ERR_INV_VALUE);
857858 if (!engine->ops->import)
858859 return gpg_error (GPG_ERR_NOT_IMPLEMENTED);
859860
860 return (*engine->ops->import) (engine->engine, keydata, keyarray);
861 return (*engine->ops->import) (engine->engine, keydata, keyarray, keyids,
862 import_filter, key_origin);
861863 }
862864
863865
140140 gpgme_tofu_policy_t policy);
141141 gpgme_error_t _gpgme_engine_op_import (engine_t engine,
142142 gpgme_data_t keydata,
143 gpgme_key_t *keyarray);
143 gpgme_key_t *keyarray,
144 const char *keyids[],
145 const char *import_filter,
146 const char *key_origin);
144147 gpgme_error_t _gpgme_engine_op_keylist (engine_t engine,
145148 const char *pattern,
146149 int secret_only,
104104 return err;
105105 else if (opd->err)
106106 ; /* We only want to report the first error. */
107 else if (!strcmp (loc, "keyserver_send"))
107 else if (!strcmp (loc, "keyserver_send")
108 || !strcmp (loc, "export_keys.secret"))
108109 opd->err = err;
109110 break;
110111
116117
117118
118119 static gpgme_error_t
119 export_start (gpgme_ctx_t ctx, int synchronous, const char *pattern,
120 gpgme_export_mode_t mode, gpgme_data_t keydata)
121 {
122 gpgme_error_t err;
123 void *hook;
124 op_data_t opd;
125
120 check_mode (gpgme_export_mode_t mode, gpgme_protocol_t protocol,
121 gpgme_data_t keydata)
122 {
126123 if ((mode & ~(GPGME_EXPORT_MODE_EXTERN
127124 |GPGME_EXPORT_MODE_MINIMAL
128125 |GPGME_EXPORT_MODE_SECRET
129126 |GPGME_EXPORT_MODE_SSH
130127 |GPGME_EXPORT_MODE_RAW
131 |GPGME_EXPORT_MODE_PKCS12)))
128 |GPGME_EXPORT_MODE_PKCS12
129 |GPGME_EXPORT_MODE_SECRET_SUBKEY)))
132130 return gpg_error (GPG_ERR_INV_VALUE); /* Invalid flags in MODE. */
131
132 if ((mode & GPGME_EXPORT_MODE_SSH))
133 {
134 if ((mode & (GPGME_EXPORT_MODE_EXTERN
135 |GPGME_EXPORT_MODE_MINIMAL
136 |GPGME_EXPORT_MODE_SECRET
137 |GPGME_EXPORT_MODE_RAW
138 |GPGME_EXPORT_MODE_PKCS12
139 |GPGME_EXPORT_MODE_SECRET_SUBKEY)))
140 return gpg_error (GPG_ERR_INV_FLAG); /* Combination not allowed. */
141 }
133142
134143 if ((mode & GPGME_EXPORT_MODE_SECRET))
135144 {
139148 && (mode & GPGME_EXPORT_MODE_PKCS12))
140149 return gpg_error (GPG_ERR_INV_FLAG); /* Combination not allowed. */
141150
142 if (ctx->protocol != GPGME_PROTOCOL_CMS
151 if (protocol != GPGME_PROTOCOL_CMS
143152 && (mode & (GPGME_EXPORT_MODE_RAW|GPGME_EXPORT_MODE_PKCS12)))
144153 return gpg_error (GPG_ERR_INV_FLAG); /* Only supported for X.509. */
145154 }
146155
156 if ((mode & GPGME_EXPORT_MODE_SECRET_SUBKEY))
157 {
158 if ((mode & GPGME_EXPORT_MODE_EXTERN))
159 return gpg_error (GPG_ERR_INV_FLAG); /* Combination not allowed. */
160 }
161
147162 if ((mode & GPGME_EXPORT_MODE_EXTERN))
148163 {
149164 if (keydata)
154169 if (!keydata)
155170 return gpg_error (GPG_ERR_INV_VALUE);
156171 }
172
173 return 0;
174 }
175
176
177 static gpgme_error_t
178 export_start (gpgme_ctx_t ctx, int synchronous, const char *pattern,
179 gpgme_export_mode_t mode, gpgme_data_t keydata)
180 {
181 gpgme_error_t err;
182 void *hook;
183 op_data_t opd;
184
185 err = check_mode (mode, ctx->protocol, keydata);
186 if (err)
187 return err;
157188
158189 err = _gpgme_op_reset (ctx, synchronous);
159190 if (err)
226257 void *hook;
227258 op_data_t opd;
228259
229 if ((mode & ~(GPGME_EXPORT_MODE_EXTERN
230 |GPGME_EXPORT_MODE_MINIMAL
231 |GPGME_EXPORT_MODE_SECRET
232 |GPGME_EXPORT_MODE_SSH
233 |GPGME_EXPORT_MODE_RAW
234 |GPGME_EXPORT_MODE_PKCS12)))
235 return gpg_error (GPG_ERR_INV_VALUE); /* Invalid flags in MODE. */
236
237 if ((mode & GPGME_EXPORT_MODE_SECRET))
238 {
239 if ((mode & GPGME_EXPORT_MODE_EXTERN))
240 return gpg_error (GPG_ERR_INV_FLAG); /* Combination not allowed. */
241 if ((mode & GPGME_EXPORT_MODE_RAW)
242 && (mode & GPGME_EXPORT_MODE_PKCS12))
243 return gpg_error (GPG_ERR_INV_FLAG); /* Combination not allowed. */
244
245 if (ctx->protocol != GPGME_PROTOCOL_CMS
246 && (mode & (GPGME_EXPORT_MODE_RAW|GPGME_EXPORT_MODE_PKCS12)))
247 return gpg_error (GPG_ERR_INV_FLAG); /* Only supported for X.509. */
248 }
249
250 if ((mode & GPGME_EXPORT_MODE_EXTERN))
251 {
252 if (keydata)
253 return gpg_error (GPG_ERR_INV_VALUE);
254 }
255 else
256 {
257 if (!keydata)
258 return gpg_error (GPG_ERR_INV_VALUE);
259 }
260 err = check_mode (mode, ctx->protocol, keydata);
261 if (err)
262 return err;
260263
261264 err = _gpgme_op_reset (ctx, synchronous);
262265 if (err)
373376
374377 if (!keys)
375378 return gpg_error (GPG_ERR_INV_VALUE);
379
380 if ((mode & GPGME_EXPORT_MODE_SECRET_SUBKEY))
381 {
382 return gpg_error (GPG_ERR_INV_FLAG);
383 }
376384
377385 /* Create a list of pattern from the keys. */
378386 for (idx=nkeys=0; keys[idx]; idx++)
26572657
26582658
26592659 static const char hlp_export[] =
2660 "EXPORT [--extern] [--minimal] [--secret [--pkcs12] [--raw]] [<pattern>]\n"
2660 "EXPORT [--extern] [--minimal]\n"
2661 " [--secret [--pkcs12] [--raw]|--secret-subkey] [<pattern>]\n"
26612662 "\n"
26622663 "Export the keys described by PATTERN. Write the\n"
26632664 "the output to the object set by the last OUTPUT command.";
26872688 mode |= GPGME_EXPORT_MODE_MINIMAL;
26882689 if (has_option (line, "--secret"))
26892690 mode |= GPGME_EXPORT_MODE_SECRET;
2691 if (has_option (line, "--secret-subkey"))
2692 mode |= GPGME_EXPORT_MODE_SECRET_SUBKEY;
26902693 if (has_option (line, "--raw"))
26912694 mode |= GPGME_EXPORT_MODE_RAW;
26922695 if (has_option (line, "--pkcs12"))
253253 free (ctx->auto_key_locate);
254254 free (ctx->trust_model);
255255 free (ctx->cert_expire);
256 free (ctx->key_origin);
257 free (ctx->import_filter);
256258 _gpgme_engine_info_release (ctx->engine_info);
257259 ctx->engine_info = NULL;
258260 DESTROY_LOCK (ctx->lock);
585587 if (!ctx->cert_expire)
586588 err = gpg_error_from_syserror ();
587589 }
590 else if (!strcmp (name, "key-origin"))
591 {
592 free (ctx->key_origin);
593 ctx->key_origin = strdup (value);
594 if (!ctx->key_origin)
595 err = gpg_error_from_syserror ();
596 }
597 else if (!strcmp (name, "import-filter"))
598 {
599 free (ctx->import_filter);
600 ctx->import_filter = strdup (value);
601 if (!ctx->import_filter)
602 err = gpg_error_from_syserror ();
603 }
588604 else
589605 err = gpg_error (GPG_ERR_UNKNOWN_NAME);
590606
657673 else if (!strcmp (name, "cert-expire"))
658674 {
659675 return ctx->cert_expire? ctx->cert_expire : "";
676 }
677 else if (!strcmp (name, "key-origin"))
678 {
679 return ctx->key_origin? ctx->key_origin : "";
680 }
681 else if (!strcmp (name, "import-filter"))
682 {
683 return ctx->import_filter? ctx->import_filter : "";
660684 }
661685 else
662686 return NULL;
279279 gpgme_op_revsig @207
280280 gpgme_op_revsig_start @208
281281
282 gpgme_op_receive_keys @209
283 gpgme_op_receive_keys_start @210
284
282285 ; END
283286
406406 #define GPGME_EXPORT_MODE_RAW 32
407407 #define GPGME_EXPORT_MODE_PKCS12 64
408408 #define GPGME_EXPORT_MODE_SSH 256
409 #define GPGME_EXPORT_MODE_SECRET_SUBKEY 512
409410
410411 typedef unsigned int gpgme_export_mode_t;
411412
17351736 /* Import the keys from the array KEYS into the keyring. */
17361737 gpgme_error_t gpgme_op_import_keys_start (gpgme_ctx_t ctx, gpgme_key_t keys[]);
17371738 gpgme_error_t gpgme_op_import_keys (gpgme_ctx_t ctx, gpgme_key_t keys[]);
1739
1740 /* Import the keys given by the array KEYIDS from a keyserver into the
1741 * keyring. */
1742 gpgme_error_t gpgme_op_receive_keys_start (gpgme_ctx_t ctx,
1743 const char *keyids[]);
1744 gpgme_error_t gpgme_op_receive_keys (gpgme_ctx_t ctx, const char *keyids[]);
17381745
17391746
17401747 /* Export the keys found by PATTERN into KEYDATA. */
66
77 Name: gpgme
88 Description: GnuPG Made Easy to access GnuPG
9 Requires: gpg-error, libassuan
9 Requires.private: gpg-error, libassuan
1010 Version: @PACKAGE_VERSION@
11 Cflags: @GPGME_CONFIG_CFLAGS@
12 Libs: @GPGME_CONFIG_LIBS@
11 Cflags: -I${includedir} @GPGME_CONFIG_CFLAGS@
12 Libs: -L${libdir} @GPGME_CONFIG_LIBS@
1313 URL: https://www.gnupg.org/software/gpgme/index.html
102102 while (impstat)
103103 {
104104 TRACE_LOG ("import[%i] for %s = 0x%x (%s)",
105 i, impstat->fpr, impstat->status,
105 i, impstat->fpr ? impstat->fpr : "null", impstat->status,
106106 gpgme_strerror (impstat->result));
107107 impstat = impstat->next;
108108 i++;
222222 }
223223
224224
225 /* Parses an error on a status line and adds a corresponding import status.
226 Currently, only supports "import.parsep12 11". */
227 static gpgme_error_t
228 parse_error (char *args, gpgme_import_status_t *import_status)
229 {
230 gpgme_import_status_t import;
231 char *tail;
232 long int nr;
233
234 tail = strchr (args, ' ');
235 if (!tail)
236 return 0;
237
238 *tail = '\0';
239 if (strcmp( args, "import.parsep12" ))
240 return 0;
241
242 args = tail + 1;
243
244 gpg_err_set_errno (0);
245 nr = strtol (args, &tail, 0);
246 if (errno || args == tail || !(*tail == ' ' || !*tail))
247 {
248 /* The crypto backend does not behave. */
249 return trace_gpg_error (GPG_ERR_INV_ENGINE);
250 }
251 if (nr != GPG_ERR_BAD_PASSPHRASE)
252 return 0;
253
254 import = malloc (sizeof (*import));
255 if (!import)
256 return gpg_error_from_syserror ();
257 import->next = NULL;
258
259 import->result = gpg_error (GPG_ERR_BAD_PASSPHRASE);
260 import->status = 0;
261 import->fpr = 0;
262
263 *import_status = import;
264 return 0;
265 }
266
267
225268 static gpgme_error_t
226269 import_status_handler (void *priv, gpgme_status_code_t code, char *args)
227270 {
251294 err = parse_import_res (args, &opd->result);
252295 break;
253296
297 case GPGME_STATUS_ERROR:
298 err = parse_error (args, opd->lastp);
299 if (err)
300 return err;
301
302 if (*opd->lastp)
303 opd->lastp = &(*opd->lastp)->next;
304 break;
305
254306 default:
255307 break;
256308 }
281333
282334 _gpgme_engine_set_status_handler (ctx->engine, import_status_handler, ctx);
283335
284 return _gpgme_engine_op_import (ctx->engine, keydata, NULL);
336 return _gpgme_engine_op_import (ctx->engine, keydata, NULL, NULL,
337 ctx->import_filter, ctx->key_origin);
285338 }
286339
287340
364417
365418 _gpgme_engine_set_status_handler (ctx->engine, import_status_handler, ctx);
366419
367 return _gpgme_engine_op_import (ctx->engine, NULL, keys);
420 return _gpgme_engine_op_import (ctx->engine, NULL, keys, NULL,
421 ctx->import_filter, ctx->key_origin);
368422 }
369423
370424
437491 }
438492
439493
494 static gpgme_error_t
495 _gpgme_op_receive_keys_start (gpgme_ctx_t ctx, int synchronous, const char *keyids[])
496 {
497 gpgme_error_t err;
498 void *hook;
499 op_data_t opd;
500
501 err = _gpgme_op_reset (ctx, synchronous);
502 if (err)
503 return err;
504
505 err = _gpgme_op_data_lookup (ctx, OPDATA_IMPORT, &hook,
506 sizeof (*opd), release_op_data);
507 opd = hook;
508 if (err)
509 return err;
510 opd->lastp = &opd->result.imports;
511
512 if (!keyids || !*keyids)
513 return gpg_error (GPG_ERR_NO_DATA);
514
515 _gpgme_engine_set_status_handler (ctx->engine, import_status_handler, ctx);
516
517 return _gpgme_engine_op_import (ctx->engine, NULL, NULL, keyids,
518 ctx->import_filter, ctx->key_origin);
519 }
520
521
522 /* Asynchronous version of gpgme_op_receive_keys. */
523 gpgme_error_t
524 gpgme_op_receive_keys_start (gpgme_ctx_t ctx, const char *keyids[])
525 {
526 gpgme_error_t err;
527
528 TRACE_BEG (DEBUG_CTX, "gpgme_op_receive_keys_start", ctx, "");
529
530 if (!ctx)
531 return TRACE_ERR (gpg_error (GPG_ERR_INV_VALUE));
532
533 if (_gpgme_debug_trace () && keyids)
534 {
535 int i = 0;
536
537 while (keyids[i] && *keyids[i])
538 {
539 TRACE_LOG ("keyids[%i] = %s", i, keyids[i]);
540 i++;
541 }
542 }
543
544 err = _gpgme_op_receive_keys_start (ctx, 1, keyids);
545 return TRACE_ERR (err);
546 }
547
548
549 /* Retrieve the keys from the array KEYIDS from a keyserver and import
550 them into the keyring.
551
552 KEYIDS is a NULL terminated array of . The result
553 is the usual import result structure. */
554 gpgme_error_t
555 gpgme_op_receive_keys (gpgme_ctx_t ctx, const char *keyids[])
556 {
557 gpgme_error_t err;
558
559 TRACE_BEG (DEBUG_CTX, "gpgme_op_receive_keys", ctx, "");
560
561 if (!ctx)
562 return TRACE_ERR (gpg_error (GPG_ERR_INV_VALUE));
563
564 if (_gpgme_debug_trace () && keyids)
565 {
566 int i = 0;
567
568 while (keyids[i] && *keyids[i])
569 {
570 TRACE_LOG ("keyids[%i] = %s", i, keyids[i]);
571 i++;
572 }
573 }
574
575 err = _gpgme_op_receive_keys_start (ctx, 1, keyids);
576 if (!err)
577 err = _gpgme_wait_one (ctx);
578 return TRACE_ERR (err);
579 }
580
581
440582 /* Deprecated interface. */
441583 gpgme_error_t
442584 gpgme_op_import_ext (gpgme_ctx_t ctx, gpgme_data_t keydata, int *nr)
278278 gpgme_op_revsig;
279279 gpgme_op_revsig_start;
280280
281 gpgme_op_receive_keys;
282 gpgme_op_receive_keys_start;
283
281284 local:
282285 *;
283286
569569 if (fd_list[i].fd > fd)
570570 fd = fd_list[i].fd;
571571 fd++;
572 #if defined(__sun) || defined(__FreeBSD__)
572 #if defined(__sun) || defined(__FreeBSD__) || defined(__GLIBC__)
573573 closefrom (fd);
574574 max_fds = fd;
575575 #else /*!__sun */
690690
691691 /* Select on the list of fds. Returns: -1 = error, 0 = timeout or
692692 nothing to select, > 0 = number of signaled fds. */
693 int
694 _gpgme_io_select (struct io_select_fd_s *fds, size_t nfds, int nonblock)
693 #ifdef HAVE_POLL_H
694 static int
695 _gpgme_io_select_poll (struct io_select_fd_s *fds, size_t nfds, int nonblock)
696 {
697 struct pollfd *poll_fds = NULL;
698 nfds_t poll_nfds;
699 /* Use a 1s timeout. */
700 int timeout = 1000;
701 unsigned int i;
702 int any;
703 int count;
704 void *dbg_help = NULL;
705 TRACE_BEG (DEBUG_SYSIO, "_gpgme_io_select", NULL,
706 "nfds=%zu, nonblock=%u", nfds, nonblock);
707
708
709 if (nonblock)
710 timeout = 0;
711
712 poll_fds = malloc (sizeof (*poll_fds)*nfds);
713 if (!poll_fds)
714 return -1;
715
716 poll_nfds = 0;
717
718 TRACE_SEQ (dbg_help, "poll on [ ");
719
720 any = 0;
721 for (i = 0; i < nfds; i++)
722 {
723 if (fds[i].fd == -1)
724 continue;
725 if (fds[i].for_read || fds[i].for_write)
726 {
727 poll_fds[poll_nfds].fd = fds[i].fd;
728 poll_fds[poll_nfds].events = 0;
729 poll_fds[poll_nfds].revents = 0;
730 if (fds[i].for_read)
731 {
732 poll_fds[poll_nfds].events |= POLLIN;
733 TRACE_ADD1 (dbg_help, "r=%d ", fds[i].fd);
734 }
735 if (fds[i].for_write)
736 {
737 poll_fds[poll_nfds].events |= POLLOUT;
738 TRACE_ADD1 (dbg_help, "w=%d ", fds[i].fd);
739 }
740 poll_nfds++;
741 any = 1;
742 }
743 fds[i].signaled = 0;
744 }
745 TRACE_END (dbg_help, "]");
746 if (!any)
747 {
748 free (poll_fds);
749 return TRACE_SYSRES (0);
750 }
751
752 do
753 count = poll (poll_fds, poll_nfds, timeout);
754 while (count < 0 && (errno == EINTR || errno == EAGAIN));
755 if (count < 0)
756 {
757 int save_errno = errno;
758 free (poll_fds);
759 errno = save_errno;
760 return TRACE_SYSRES (-1);
761 }
762
763 TRACE_SEQ (dbg_help, "poll OK [ ");
764 if (TRACE_ENABLED (dbg_help))
765 {
766 poll_nfds = 0;
767 for (i = 0; i < nfds; i++)
768 {
769 if (fds[i].fd == -1)
770 continue;
771 if ((poll_fds[poll_nfds].revents & (POLLIN|POLLHUP)))
772 TRACE_ADD1 (dbg_help, "r=%d ", i);
773 if ((poll_fds[poll_nfds].revents & POLLOUT))
774 TRACE_ADD1 (dbg_help, "w=%d ", i);
775 poll_nfds++;
776 }
777 TRACE_END (dbg_help, "]");
778 }
779
780 poll_nfds = 0;
781 for (i = 0; i < nfds; i++)
782 {
783 if (fds[i].fd == -1)
784 continue;
785 if (fds[i].for_read || fds[i].for_write)
786 {
787 short events_to_be_checked = 0;
788
789 if (fds[i].for_read)
790 events_to_be_checked |= (POLLIN|POLLHUP);
791 if (fds[i].for_write)
792 events_to_be_checked |= POLLOUT;
793 if ((poll_fds[poll_nfds].revents & events_to_be_checked))
794 fds[i].signaled = 1;
795
796 poll_nfds++;
797 }
798 }
799
800 free (poll_fds);
801 return TRACE_SYSRES (count);
802 }
803 #else
804 static int
805 _gpgme_io_select_select (struct io_select_fd_s *fds, size_t nfds, int nonblock)
695806 {
696807 fd_set readfds;
697808 fd_set writefds;
801912 }
802913 return TRACE_SYSRES (count);
803914 }
804
915 #endif
916
917 int
918 _gpgme_io_select (struct io_select_fd_s *fds, size_t nfds, int nonblock)
919 {
920 #ifdef HAVE_POLL_H
921 return _gpgme_io_select_poll (fds, nfds, nonblock);
922 #else
923 return _gpgme_io_select_select (fds, nfds, nonblock);
924 #endif
925 }
805926
806927 int
807928 _gpgme_io_recvmsg (int fd, struct msghdr *msg, int flags)
840840
841841
842842 /* Like CreateProcessA but mapping the arguments to wchar API */
843 int _gpgme_create_process_utf8 (const char *application_name_utf8,
844 char *command_line_utf8,
845 LPSECURITY_ATTRIBUTES lpProcessAttributes,
846 LPSECURITY_ATTRIBUTES lpThreadAttributes,
847 BOOL bInheritHandles,
848 DWORD dwCreationFlags,
849 void *lpEnvironment,
850 char *working_directory_utf8,
851 LPSTARTUPINFOA si,
852 LPPROCESS_INFORMATION lpProcessInformation)
843 int
844 _gpgme_create_process_utf8 (const char *application_name_utf8,
845 char *command_line_utf8,
846 LPSECURITY_ATTRIBUTES lpProcessAttributes,
847 LPSECURITY_ATTRIBUTES lpThreadAttributes,
848 BOOL bInheritHandles,
849 DWORD dwCreationFlags,
850 void *lpEnvironment,
851 char *working_directory_utf8,
852 LPSTARTUPINFOA si,
853 LPPROCESS_INFORMATION lpProcessInformation)
853854 {
854855 BOOL ret;
855856 wchar_t *application_name = utf8_to_wchar0 (application_name_utf8);
2727 EXTRA_DIST = start-stop-agent t-data-1.txt t-data-2.txt ChangeLog-2011
2828
2929 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
30
31 if HAVE_W32_SYSTEM
32 AM_LDFLAGS = -no-fast-install
33 else
3034 AM_LDFLAGS = -no-install
35 endif
36
3137 LDADD = ../src/libgpgme.la @GPG_ERROR_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
3238
3339 noinst_HEADERS = run-support.h
3440
3541 noinst_PROGRAMS = $(TESTS) run-keylist run-export run-import run-sign \
3642 run-verify run-encrypt run-identify run-decrypt run-genkey \
37 run-keysign run-tofu run-swdb run-threaded
43 run-keysign run-tofu run-swdb run-threaded \
44 run-receive-keys
3845
39 run_threaded_LDADD = ../src/libgpgme.la -lpthread @GPG_ERROR_LIBS@ \
40 @LDADD_FOR_TESTS_KLUDGE@
46 run_threaded_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_MT_CFLAGS@
47 run_threaded_LDADD = ../src/libgpgme.la \
48 @GPG_ERROR_MT_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
4149
4250 if RUN_GPG_TESTS
4351 gpgtests = gpg json
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Makefile.am - Makefile for GPGME tests.
17 # Copyright (C) 2000 Werner Koch (dd9jn)
18 # Copyright (C) 2001, 2004 g10 Code GmbH
19 #
20 # This file is part of GPGME.
21 #
22 # GPGME is free software; you can redistribute it and/or modify it
23 # under the terms of the GNU Lesser General Public License as
24 # published by the Free Software Foundation; either version 2.1 of the
25 # License, or (at your option) any later version.
26 #
27 # GPGME is distributed in the hope that it will be useful, but WITHOUT
28 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
29 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
30 # Public License for more details.
31 #
32 # You should have received a copy of the GNU Lesser General Public
33 # License along with this program; if not, see <https://gnu.org/licenses/>.
34 # SPDX-License-Identifier: LGPL-2.1-or-later
35
36
37 VPATH = @srcdir@
38 am__is_gnu_make = { \
39 if test -z '$(MAKELEVEL)'; then \
40 false; \
41 elif test -n '$(MAKE_HOST)'; then \
42 true; \
43 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
44 true; \
45 else \
46 false; \
47 fi; \
48 }
49 am__make_running_with_option = \
50 case $${target_option-} in \
51 ?) ;; \
52 *) echo "am__make_running_with_option: internal error: invalid" \
53 "target option '$${target_option-}' specified" >&2; \
54 exit 1;; \
55 esac; \
56 has_opt=no; \
57 sane_makeflags=$$MAKEFLAGS; \
58 if $(am__is_gnu_make); then \
59 sane_makeflags=$$MFLAGS; \
60 else \
61 case $$MAKEFLAGS in \
62 *\\[\ \ ]*) \
63 bs=\\; \
64 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
65 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
66 esac; \
67 fi; \
68 skip_next=no; \
69 strip_trailopt () \
70 { \
71 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
72 }; \
73 for flg in $$sane_makeflags; do \
74 test $$skip_next = yes && { skip_next=no; continue; }; \
75 case $$flg in \
76 *=*|--*) continue;; \
77 -*I) strip_trailopt 'I'; skip_next=yes;; \
78 -*I?*) strip_trailopt 'I';; \
79 -*O) strip_trailopt 'O'; skip_next=yes;; \
80 -*O?*) strip_trailopt 'O';; \
81 -*l) strip_trailopt 'l'; skip_next=yes;; \
82 -*l?*) strip_trailopt 'l';; \
83 -[dEDm]) skip_next=yes;; \
84 -[JT]) skip_next=yes;; \
85 esac; \
86 case $$flg in \
87 *$$target_option*) has_opt=yes; break;; \
88 esac; \
89 done; \
90 test $$has_opt = yes
91 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
92 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
93 pkgdatadir = $(datadir)/@PACKAGE@
94 pkgincludedir = $(includedir)/@PACKAGE@
95 pkglibdir = $(libdir)/@PACKAGE@
96 pkglibexecdir = $(libexecdir)/@PACKAGE@
97 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
98 install_sh_DATA = $(install_sh) -c -m 644
99 install_sh_PROGRAM = $(install_sh) -c
100 install_sh_SCRIPT = $(install_sh) -c
101 INSTALL_HEADER = $(INSTALL_DATA)
102 transform = $(program_transform_name)
103 NORMAL_INSTALL = :
104 PRE_INSTALL = :
105 POST_INSTALL = :
106 NORMAL_UNINSTALL = :
107 PRE_UNINSTALL = :
108 POST_UNINSTALL = :
109 build_triplet = @build@
110 host_triplet = @host@
111 TESTS = t-version$(EXEEXT) t-data$(EXEEXT) t-engine-info$(EXEEXT)
112 noinst_PROGRAMS = $(am__EXEEXT_1) run-keylist$(EXEEXT) \
113 run-export$(EXEEXT) run-import$(EXEEXT) run-sign$(EXEEXT) \
114 run-verify$(EXEEXT) run-encrypt$(EXEEXT) run-identify$(EXEEXT) \
115 run-decrypt$(EXEEXT) run-genkey$(EXEEXT) run-keysign$(EXEEXT) \
116 run-tofu$(EXEEXT) run-swdb$(EXEEXT) run-threaded$(EXEEXT) \
117 run-receive-keys$(EXEEXT)
118 subdir = tests
119 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
120 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
121 $(top_srcdir)/m4/ax_pkg_swig.m4 \
122 $(top_srcdir)/m4/ax_python_devel.m4 \
123 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
124 $(top_srcdir)/m4/gnupg-ttyname.m4 \
125 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
126 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
127 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
128 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
129 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
130 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
131 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
132 $(ACLOCAL_M4)
133 DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \
134 $(am__DIST_COMMON)
135 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
136 CONFIG_HEADER = $(top_builddir)/conf/config.h
137 CONFIG_CLEAN_FILES =
138 CONFIG_CLEAN_VPATH_FILES =
139 am__EXEEXT_1 = t-version$(EXEEXT) t-data$(EXEEXT) \
140 t-engine-info$(EXEEXT)
141 PROGRAMS = $(noinst_PROGRAMS)
142 run_decrypt_SOURCES = run-decrypt.c
143 run_decrypt_OBJECTS = run-decrypt.$(OBJEXT)
144 run_decrypt_LDADD = $(LDADD)
145 run_decrypt_DEPENDENCIES = ../src/libgpgme.la
146 AM_V_lt = $(am__v_lt_@AM_V@)
147 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
148 am__v_lt_0 = --silent
149 am__v_lt_1 =
150 run_encrypt_SOURCES = run-encrypt.c
151 run_encrypt_OBJECTS = run-encrypt.$(OBJEXT)
152 run_encrypt_LDADD = $(LDADD)
153 run_encrypt_DEPENDENCIES = ../src/libgpgme.la
154 run_export_SOURCES = run-export.c
155 run_export_OBJECTS = run-export.$(OBJEXT)
156 run_export_LDADD = $(LDADD)
157 run_export_DEPENDENCIES = ../src/libgpgme.la
158 run_genkey_SOURCES = run-genkey.c
159 run_genkey_OBJECTS = run-genkey.$(OBJEXT)
160 run_genkey_LDADD = $(LDADD)
161 run_genkey_DEPENDENCIES = ../src/libgpgme.la
162 run_identify_SOURCES = run-identify.c
163 run_identify_OBJECTS = run-identify.$(OBJEXT)
164 run_identify_LDADD = $(LDADD)
165 run_identify_DEPENDENCIES = ../src/libgpgme.la
166 run_import_SOURCES = run-import.c
167 run_import_OBJECTS = run-import.$(OBJEXT)
168 run_import_LDADD = $(LDADD)
169 run_import_DEPENDENCIES = ../src/libgpgme.la
170 run_keylist_SOURCES = run-keylist.c
171 run_keylist_OBJECTS = run-keylist.$(OBJEXT)
172 run_keylist_LDADD = $(LDADD)
173 run_keylist_DEPENDENCIES = ../src/libgpgme.la
174 run_keysign_SOURCES = run-keysign.c
175 run_keysign_OBJECTS = run-keysign.$(OBJEXT)
176 run_keysign_LDADD = $(LDADD)
177 run_keysign_DEPENDENCIES = ../src/libgpgme.la
178 run_receive_keys_SOURCES = run-receive-keys.c
179 run_receive_keys_OBJECTS = run-receive-keys.$(OBJEXT)
180 run_receive_keys_LDADD = $(LDADD)
181 run_receive_keys_DEPENDENCIES = ../src/libgpgme.la
182 run_sign_SOURCES = run-sign.c
183 run_sign_OBJECTS = run-sign.$(OBJEXT)
184 run_sign_LDADD = $(LDADD)
185 run_sign_DEPENDENCIES = ../src/libgpgme.la
186 run_swdb_SOURCES = run-swdb.c
187 run_swdb_OBJECTS = run-swdb.$(OBJEXT)
188 run_swdb_LDADD = $(LDADD)
189 run_swdb_DEPENDENCIES = ../src/libgpgme.la
190 run_threaded_SOURCES = run-threaded.c
191 run_threaded_OBJECTS = run_threaded-run-threaded.$(OBJEXT)
192 run_threaded_DEPENDENCIES = ../src/libgpgme.la
193 run_tofu_SOURCES = run-tofu.c
194 run_tofu_OBJECTS = run-tofu.$(OBJEXT)
195 run_tofu_LDADD = $(LDADD)
196 run_tofu_DEPENDENCIES = ../src/libgpgme.la
197 run_verify_SOURCES = run-verify.c
198 run_verify_OBJECTS = run-verify.$(OBJEXT)
199 run_verify_LDADD = $(LDADD)
200 run_verify_DEPENDENCIES = ../src/libgpgme.la
201 t_data_SOURCES = t-data.c
202 t_data_OBJECTS = t-data.$(OBJEXT)
203 t_data_LDADD = $(LDADD)
204 t_data_DEPENDENCIES = ../src/libgpgme.la
205 t_engine_info_SOURCES = t-engine-info.c
206 t_engine_info_OBJECTS = t-engine-info.$(OBJEXT)
207 t_engine_info_LDADD = $(LDADD)
208 t_engine_info_DEPENDENCIES = ../src/libgpgme.la
209 t_version_SOURCES = t-version.c
210 t_version_OBJECTS = t-version.$(OBJEXT)
211 t_version_LDADD = $(LDADD)
212 t_version_DEPENDENCIES = ../src/libgpgme.la
213 AM_V_P = $(am__v_P_@AM_V@)
214 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
215 am__v_P_0 = false
216 am__v_P_1 = :
217 AM_V_GEN = $(am__v_GEN_@AM_V@)
218 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
219 am__v_GEN_0 = @echo " GEN " $@;
220 am__v_GEN_1 =
221 AM_V_at = $(am__v_at_@AM_V@)
222 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
223 am__v_at_0 = @
224 am__v_at_1 =
225 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
226 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
227 am__maybe_remake_depfiles = depfiles
228 am__depfiles_remade = ./$(DEPDIR)/run-decrypt.Po \
229 ./$(DEPDIR)/run-encrypt.Po ./$(DEPDIR)/run-export.Po \
230 ./$(DEPDIR)/run-genkey.Po ./$(DEPDIR)/run-identify.Po \
231 ./$(DEPDIR)/run-import.Po ./$(DEPDIR)/run-keylist.Po \
232 ./$(DEPDIR)/run-keysign.Po ./$(DEPDIR)/run-receive-keys.Po \
233 ./$(DEPDIR)/run-sign.Po ./$(DEPDIR)/run-swdb.Po \
234 ./$(DEPDIR)/run-tofu.Po ./$(DEPDIR)/run-verify.Po \
235 ./$(DEPDIR)/run_threaded-run-threaded.Po ./$(DEPDIR)/t-data.Po \
236 ./$(DEPDIR)/t-engine-info.Po ./$(DEPDIR)/t-version.Po
237 am__mv = mv -f
238 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
239 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
240 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
241 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
242 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
243 $(AM_CFLAGS) $(CFLAGS)
244 AM_V_CC = $(am__v_CC_@AM_V@)
245 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
246 am__v_CC_0 = @echo " CC " $@;
247 am__v_CC_1 =
248 CCLD = $(CC)
249 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
250 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
251 $(AM_LDFLAGS) $(LDFLAGS) -o $@
252 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
253 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
254 am__v_CCLD_0 = @echo " CCLD " $@;
255 am__v_CCLD_1 =
256 SOURCES = run-decrypt.c run-encrypt.c run-export.c run-genkey.c \
257 run-identify.c run-import.c run-keylist.c run-keysign.c \
258 run-receive-keys.c run-sign.c run-swdb.c run-threaded.c \
259 run-tofu.c run-verify.c t-data.c t-engine-info.c t-version.c
260 DIST_SOURCES = run-decrypt.c run-encrypt.c run-export.c run-genkey.c \
261 run-identify.c run-import.c run-keylist.c run-keysign.c \
262 run-receive-keys.c run-sign.c run-swdb.c run-threaded.c \
263 run-tofu.c run-verify.c t-data.c t-engine-info.c t-version.c
264 RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
265 ctags-recursive dvi-recursive html-recursive info-recursive \
266 install-data-recursive install-dvi-recursive \
267 install-exec-recursive install-html-recursive \
268 install-info-recursive install-pdf-recursive \
269 install-ps-recursive install-recursive installcheck-recursive \
270 installdirs-recursive pdf-recursive ps-recursive \
271 tags-recursive uninstall-recursive
272 am__can_run_installinfo = \
273 case $$AM_UPDATE_INFO_DIR in \
274 n|no|NO) false;; \
275 *) (install-info --version) >/dev/null 2>&1;; \
276 esac
277 HEADERS = $(noinst_HEADERS)
278 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
279 distclean-recursive maintainer-clean-recursive
280 am__recursive_targets = \
281 $(RECURSIVE_TARGETS) \
282 $(RECURSIVE_CLEAN_TARGETS) \
283 $(am__extra_recursive_targets)
284 AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
285 distdir distdir-am
286 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
287 # Read a list of newline-separated strings from the standard input,
288 # and print each of them once, without duplicates. Input order is
289 # *not* preserved.
290 am__uniquify_input = $(AWK) '\
291 BEGIN { nonempty = 0; } \
292 { items[$$0] = 1; nonempty = 1; } \
293 END { if (nonempty) { for (i in items) print i; }; } \
294 '
295 # Make sure the list of sources is unique. This is necessary because,
296 # e.g., the same source file might be shared among _SOURCES variables
297 # for different programs/libraries.
298 am__define_uniq_tagged_files = \
299 list='$(am__tagged_files)'; \
300 unique=`for i in $$list; do \
301 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
302 done | $(am__uniquify_input)`
303 ETAGS = etags
304 CTAGS = ctags
305 am__tty_colors_dummy = \
306 mgn= red= grn= lgn= blu= brg= std=; \
307 am__color_tests=no
308 am__tty_colors = { \
309 $(am__tty_colors_dummy); \
310 if test "X$(AM_COLOR_TESTS)" = Xno; then \
311 am__color_tests=no; \
312 elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
313 am__color_tests=yes; \
314 elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
315 am__color_tests=yes; \
316 fi; \
317 if test $$am__color_tests = yes; then \
318 red=''; \
319 grn=''; \
320 lgn=''; \
321 blu=''; \
322 mgn=''; \
323 brg=''; \
324 std=''; \
325 fi; \
326 }
327 DIST_SUBDIRS = gpg json gpgsm opassuan
328 am__DIST_COMMON = $(srcdir)/Makefile.in \
329 $(top_srcdir)/build-aux/depcomp \
330 $(top_srcdir)/build-aux/mkinstalldirs
331 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
332 am__relativize = \
333 dir0=`pwd`; \
334 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
335 sed_rest='s,^[^/]*/*,,'; \
336 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
337 sed_butlast='s,/*[^/]*$$,,'; \
338 while test -n "$$dir1"; do \
339 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
340 if test "$$first" != "."; then \
341 if test "$$first" = ".."; then \
342 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
343 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
344 else \
345 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
346 if test "$$first2" = "$$first"; then \
347 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
348 else \
349 dir2="../$$dir2"; \
350 fi; \
351 dir0="$$dir0"/"$$first"; \
352 fi; \
353 fi; \
354 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
355 done; \
356 reldir="$$dir2"
357 ACLOCAL = @ACLOCAL@
358 AMTAR = @AMTAR@
359 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
360 AR = @AR@
361 AS = @AS@
362 AUTOCONF = @AUTOCONF@
363 AUTOHEADER = @AUTOHEADER@
364 AUTOMAKE = @AUTOMAKE@
365 AWK = @AWK@
366 BUILD_FILEVERSION = @BUILD_FILEVERSION@
367 BUILD_REVISION = @BUILD_REVISION@
368 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
369 BUILD_VERSION = @BUILD_VERSION@
370 CC = @CC@
371 CCDEPMODE = @CCDEPMODE@
372 CC_FOR_BUILD = @CC_FOR_BUILD@
373 CFLAGS = @CFLAGS@
374 CPP = @CPP@
375 CPPFLAGS = @CPPFLAGS@
376 CXX = @CXX@
377 CXXCPP = @CXXCPP@
378 CXXDEPMODE = @CXXDEPMODE@
379 CXXFLAGS = @CXXFLAGS@
380 CYGPATH_W = @CYGPATH_W@
381 DEFS = @DEFS@
382 DEPDIR = @DEPDIR@
383 DLLTOOL = @DLLTOOL@
384 DOXYGEN = @DOXYGEN@
385 DSYMUTIL = @DSYMUTIL@
386 DUMPBIN = @DUMPBIN@
387 ECHO_C = @ECHO_C@
388 ECHO_N = @ECHO_N@
389 ECHO_T = @ECHO_T@
390 EGREP = @EGREP@
391 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
392 EXEEXT = @EXEEXT@
393 FGREP = @FGREP@
394 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
395 GLIBC21 = @GLIBC21@
396 GLIB_CFLAGS = @GLIB_CFLAGS@
397 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
398 GLIB_LIBS = @GLIB_LIBS@
399 GLIB_MKENUMS = @GLIB_MKENUMS@
400 GOBJECT_QUERY = @GOBJECT_QUERY@
401 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
402 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
403 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
404 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
405 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
406 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
407 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
408 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
409 GPGME_QT_LIBS = @GPGME_QT_LIBS@
410 GPGRT_CONFIG = @GPGRT_CONFIG@
411 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
412 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
413 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
414 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
415 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
416 GRAPHVIZ = @GRAPHVIZ@
417 GREP = @GREP@
418 HAVE_CXX11 = @HAVE_CXX11@
419 HAVE_DOT = @HAVE_DOT@
420 INSTALL = @INSTALL@
421 INSTALL_DATA = @INSTALL_DATA@
422 INSTALL_PROGRAM = @INSTALL_PROGRAM@
423 INSTALL_SCRIPT = @INSTALL_SCRIPT@
424 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
425 LD = @LD@
426 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
427 LDFLAGS = @LDFLAGS@
428 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
429 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
430 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
431 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
432 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
433 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
434 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
435 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
436 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
437 LIBOBJS = @LIBOBJS@
438 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
439 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
440 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
441 LIBS = @LIBS@
442 LIBTOOL = @LIBTOOL@
443 LIPO = @LIPO@
444 LN_S = @LN_S@
445 LTLIBOBJS = @LTLIBOBJS@
446 MAINT = @MAINT@
447 MAKEINFO = @MAKEINFO@
448 MANIFEST_TOOL = @MANIFEST_TOOL@
449 MKDIR_P = @MKDIR_P@
450 MOC = @MOC@
451 MOC2 = @MOC2@
452 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
453 NM = @NM@
454 NMEDIT = @NMEDIT@
455 OBJDUMP = @OBJDUMP@
456 OBJEXT = @OBJEXT@
457 OTOOL = @OTOOL@
458 OTOOL64 = @OTOOL64@
459 PACKAGE = @PACKAGE@
460 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
461 PACKAGE_NAME = @PACKAGE_NAME@
462 PACKAGE_STRING = @PACKAGE_STRING@
463 PACKAGE_TARNAME = @PACKAGE_TARNAME@
464 PACKAGE_URL = @PACKAGE_URL@
465 PACKAGE_VERSION = @PACKAGE_VERSION@
466 PATH_SEPARATOR = @PATH_SEPARATOR@
467 PKG_CONFIG = @PKG_CONFIG@
468 PYTHON = @PYTHON@
469 PYTHONS = @PYTHONS@
470 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
471 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
472 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
473 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
474 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
475 PYTHON_PLATFORM = @PYTHON_PLATFORM@
476 PYTHON_PREFIX = @PYTHON_PREFIX@
477 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
478 PYTHON_VERSION = @PYTHON_VERSION@
479 QTCHOOSER = @QTCHOOSER@
480 RANLIB = @RANLIB@
481 RC = @RC@
482 SED = @SED@
483 SET_MAKE = @SET_MAKE@
484 SHELL = @SHELL@
485 STRIP = @STRIP@
486 SWIG = @SWIG@
487 SWIG_LIB = @SWIG_LIB@
488 SYSROOT = @SYSROOT@
489 VERSION = @VERSION@
490 VERSION_MAJOR = @VERSION_MAJOR@
491 VERSION_MICRO = @VERSION_MICRO@
492 VERSION_MINOR = @VERSION_MINOR@
493 VERSION_NUMBER = @VERSION_NUMBER@
494 abs_builddir = @abs_builddir@
495 abs_srcdir = @abs_srcdir@
496 abs_top_builddir = @abs_top_builddir@
497 abs_top_srcdir = @abs_top_srcdir@
498 ac_ct_AR = @ac_ct_AR@
499 ac_ct_CC = @ac_ct_CC@
500 ac_ct_CXX = @ac_ct_CXX@
501 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
502 am__include = @am__include@
503 am__leading_dot = @am__leading_dot@
504 am__quote = @am__quote@
505 am__tar = @am__tar@
506 am__untar = @am__untar@
507 bindir = @bindir@
508 build = @build@
509 build_alias = @build_alias@
510 build_cpu = @build_cpu@
511 build_os = @build_os@
512 build_vendor = @build_vendor@
513 builddir = @builddir@
514 datadir = @datadir@
515 datarootdir = @datarootdir@
516 docdir = @docdir@
517 dvidir = @dvidir@
518 emacs_local_vars_begin = @emacs_local_vars_begin@
519 emacs_local_vars_end = @emacs_local_vars_end@
520 emacs_local_vars_read_only = @emacs_local_vars_read_only@
521 exec_prefix = @exec_prefix@
522 host = @host@
523 host_alias = @host_alias@
524 host_cpu = @host_cpu@
525 host_os = @host_os@
526 host_vendor = @host_vendor@
527 htmldir = @htmldir@
528 includedir = @includedir@
529 infodir = @infodir@
530 install_sh = @install_sh@
531 libdir = @libdir@
532 libexecdir = @libexecdir@
533 localedir = @localedir@
534 localstatedir = @localstatedir@
535 mandir = @mandir@
536 mkdir_p = @mkdir_p@
537 oldincludedir = @oldincludedir@
538 pdfdir = @pdfdir@
539 pkgpyexecdir = @pkgpyexecdir@
540 pkgpythondir = @pkgpythondir@
541 prefix = @prefix@
542 program_transform_name = @program_transform_name@
543 psdir = @psdir@
544 pyexecdir = @pyexecdir@
545 pythondir = @pythondir@
546 runstatedir = @runstatedir@
547 sbindir = @sbindir@
548 sharedstatedir = @sharedstatedir@
549 srcdir = @srcdir@
550 sysconfdir = @sysconfdir@
551 target_alias = @target_alias@
552 top_build_prefix = @top_build_prefix@
553 top_builddir = @top_builddir@
554 top_srcdir = @top_srcdir@
555 GNUPGHOME = $(abs_builddir)
556 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME)
557 EXTRA_DIST = start-stop-agent t-data-1.txt t-data-2.txt ChangeLog-2011
558 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
559 @HAVE_W32_SYSTEM_FALSE@AM_LDFLAGS = -no-install
560 @HAVE_W32_SYSTEM_TRUE@AM_LDFLAGS = -no-fast-install
561 LDADD = ../src/libgpgme.la @GPG_ERROR_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
562 noinst_HEADERS = run-support.h
563 run_threaded_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_MT_CFLAGS@
564 run_threaded_LDADD = ../src/libgpgme.la \
565 @GPG_ERROR_MT_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
566
567 @RUN_GPG_TESTS_FALSE@gpgtests =
568 @RUN_GPG_TESTS_TRUE@gpgtests = gpg json
569 @RUN_GPGSM_TESTS_FALSE@gpgsmtests =
570 @RUN_GPGSM_TESTS_TRUE@gpgsmtests = gpgsm opassuan
571 SUBDIRS = ${gpgtests} ${gpgsmtests}
572 all: all-recursive
573
574 .SUFFIXES:
575 .SUFFIXES: .c .lo .o .obj
576 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
577 @for dep in $?; do \
578 case '$(am__configure_deps)' in \
579 *$$dep*) \
580 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
581 && { if test -f $@; then exit 0; else break; fi; }; \
582 exit 1;; \
583 esac; \
584 done; \
585 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/Makefile'; \
586 $(am__cd) $(top_srcdir) && \
587 $(AUTOMAKE) --gnu tests/Makefile
588 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
589 @case '$?' in \
590 *config.status*) \
591 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
592 *) \
593 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
594 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
595 esac;
596
597 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
598 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
599
600 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
601 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
602 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
603 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
604 $(am__aclocal_m4_deps):
605
606 clean-noinstPROGRAMS:
607 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
608 echo " rm -f" $$list; \
609 rm -f $$list || exit $$?; \
610 test -n "$(EXEEXT)" || exit 0; \
611 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
612 echo " rm -f" $$list; \
613 rm -f $$list
614
615 run-decrypt$(EXEEXT): $(run_decrypt_OBJECTS) $(run_decrypt_DEPENDENCIES) $(EXTRA_run_decrypt_DEPENDENCIES)
616 @rm -f run-decrypt$(EXEEXT)
617 $(AM_V_CCLD)$(LINK) $(run_decrypt_OBJECTS) $(run_decrypt_LDADD) $(LIBS)
618
619 run-encrypt$(EXEEXT): $(run_encrypt_OBJECTS) $(run_encrypt_DEPENDENCIES) $(EXTRA_run_encrypt_DEPENDENCIES)
620 @rm -f run-encrypt$(EXEEXT)
621 $(AM_V_CCLD)$(LINK) $(run_encrypt_OBJECTS) $(run_encrypt_LDADD) $(LIBS)
622
623 run-export$(EXEEXT): $(run_export_OBJECTS) $(run_export_DEPENDENCIES) $(EXTRA_run_export_DEPENDENCIES)
624 @rm -f run-export$(EXEEXT)
625 $(AM_V_CCLD)$(LINK) $(run_export_OBJECTS) $(run_export_LDADD) $(LIBS)
626
627 run-genkey$(EXEEXT): $(run_genkey_OBJECTS) $(run_genkey_DEPENDENCIES) $(EXTRA_run_genkey_DEPENDENCIES)
628 @rm -f run-genkey$(EXEEXT)
629 $(AM_V_CCLD)$(LINK) $(run_genkey_OBJECTS) $(run_genkey_LDADD) $(LIBS)
630
631 run-identify$(EXEEXT): $(run_identify_OBJECTS) $(run_identify_DEPENDENCIES) $(EXTRA_run_identify_DEPENDENCIES)
632 @rm -f run-identify$(EXEEXT)
633 $(AM_V_CCLD)$(LINK) $(run_identify_OBJECTS) $(run_identify_LDADD) $(LIBS)
634
635 run-import$(EXEEXT): $(run_import_OBJECTS) $(run_import_DEPENDENCIES) $(EXTRA_run_import_DEPENDENCIES)
636 @rm -f run-import$(EXEEXT)
637 $(AM_V_CCLD)$(LINK) $(run_import_OBJECTS) $(run_import_LDADD) $(LIBS)
638
639 run-keylist$(EXEEXT): $(run_keylist_OBJECTS) $(run_keylist_DEPENDENCIES) $(EXTRA_run_keylist_DEPENDENCIES)
640 @rm -f run-keylist$(EXEEXT)
641 $(AM_V_CCLD)$(LINK) $(run_keylist_OBJECTS) $(run_keylist_LDADD) $(LIBS)
642
643 run-keysign$(EXEEXT): $(run_keysign_OBJECTS) $(run_keysign_DEPENDENCIES) $(EXTRA_run_keysign_DEPENDENCIES)
644 @rm -f run-keysign$(EXEEXT)
645 $(AM_V_CCLD)$(LINK) $(run_keysign_OBJECTS) $(run_keysign_LDADD) $(LIBS)
646
647 run-receive-keys$(EXEEXT): $(run_receive_keys_OBJECTS) $(run_receive_keys_DEPENDENCIES) $(EXTRA_run_receive_keys_DEPENDENCIES)
648 @rm -f run-receive-keys$(EXEEXT)
649 $(AM_V_CCLD)$(LINK) $(run_receive_keys_OBJECTS) $(run_receive_keys_LDADD) $(LIBS)
650
651 run-sign$(EXEEXT): $(run_sign_OBJECTS) $(run_sign_DEPENDENCIES) $(EXTRA_run_sign_DEPENDENCIES)
652 @rm -f run-sign$(EXEEXT)
653 $(AM_V_CCLD)$(LINK) $(run_sign_OBJECTS) $(run_sign_LDADD) $(LIBS)
654
655 run-swdb$(EXEEXT): $(run_swdb_OBJECTS) $(run_swdb_DEPENDENCIES) $(EXTRA_run_swdb_DEPENDENCIES)
656 @rm -f run-swdb$(EXEEXT)
657 $(AM_V_CCLD)$(LINK) $(run_swdb_OBJECTS) $(run_swdb_LDADD) $(LIBS)
658
659 run-threaded$(EXEEXT): $(run_threaded_OBJECTS) $(run_threaded_DEPENDENCIES) $(EXTRA_run_threaded_DEPENDENCIES)
660 @rm -f run-threaded$(EXEEXT)
661 $(AM_V_CCLD)$(LINK) $(run_threaded_OBJECTS) $(run_threaded_LDADD) $(LIBS)
662
663 run-tofu$(EXEEXT): $(run_tofu_OBJECTS) $(run_tofu_DEPENDENCIES) $(EXTRA_run_tofu_DEPENDENCIES)
664 @rm -f run-tofu$(EXEEXT)
665 $(AM_V_CCLD)$(LINK) $(run_tofu_OBJECTS) $(run_tofu_LDADD) $(LIBS)
666
667 run-verify$(EXEEXT): $(run_verify_OBJECTS) $(run_verify_DEPENDENCIES) $(EXTRA_run_verify_DEPENDENCIES)
668 @rm -f run-verify$(EXEEXT)
669 $(AM_V_CCLD)$(LINK) $(run_verify_OBJECTS) $(run_verify_LDADD) $(LIBS)
670
671 t-data$(EXEEXT): $(t_data_OBJECTS) $(t_data_DEPENDENCIES) $(EXTRA_t_data_DEPENDENCIES)
672 @rm -f t-data$(EXEEXT)
673 $(AM_V_CCLD)$(LINK) $(t_data_OBJECTS) $(t_data_LDADD) $(LIBS)
674
675 t-engine-info$(EXEEXT): $(t_engine_info_OBJECTS) $(t_engine_info_DEPENDENCIES) $(EXTRA_t_engine_info_DEPENDENCIES)
676 @rm -f t-engine-info$(EXEEXT)
677 $(AM_V_CCLD)$(LINK) $(t_engine_info_OBJECTS) $(t_engine_info_LDADD) $(LIBS)
678
679 t-version$(EXEEXT): $(t_version_OBJECTS) $(t_version_DEPENDENCIES) $(EXTRA_t_version_DEPENDENCIES)
680 @rm -f t-version$(EXEEXT)
681 $(AM_V_CCLD)$(LINK) $(t_version_OBJECTS) $(t_version_LDADD) $(LIBS)
682
683 mostlyclean-compile:
684 -rm -f *.$(OBJEXT)
685
686 distclean-compile:
687 -rm -f *.tab.c
688
689 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-decrypt.Po@am__quote@ # am--include-marker
690 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-encrypt.Po@am__quote@ # am--include-marker
691 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-export.Po@am__quote@ # am--include-marker
692 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-genkey.Po@am__quote@ # am--include-marker
693 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-identify.Po@am__quote@ # am--include-marker
694 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-import.Po@am__quote@ # am--include-marker
695 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-keylist.Po@am__quote@ # am--include-marker
696 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-keysign.Po@am__quote@ # am--include-marker
697 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-receive-keys.Po@am__quote@ # am--include-marker
698 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-sign.Po@am__quote@ # am--include-marker
699 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-swdb.Po@am__quote@ # am--include-marker
700 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-tofu.Po@am__quote@ # am--include-marker
701 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run-verify.Po@am__quote@ # am--include-marker
702 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run_threaded-run-threaded.Po@am__quote@ # am--include-marker
703 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-data.Po@am__quote@ # am--include-marker
704 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-engine-info.Po@am__quote@ # am--include-marker
705 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-version.Po@am__quote@ # am--include-marker
706
707 $(am__depfiles_remade):
708 @$(MKDIR_P) $(@D)
709 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
710
711 am--depfiles: $(am__depfiles_remade)
712
713 .c.o:
714 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
715 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
716 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
717 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
718 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
719
720 .c.obj:
721 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
722 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
723 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
724 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
725 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
726
727 .c.lo:
728 @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
729 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
730 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
731 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
732 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
733
734 run_threaded-run-threaded.o: run-threaded.c
735 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(run_threaded_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT run_threaded-run-threaded.o -MD -MP -MF $(DEPDIR)/run_threaded-run-threaded.Tpo -c -o run_threaded-run-threaded.o `test -f 'run-threaded.c' || echo '$(srcdir)/'`run-threaded.c
736 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/run_threaded-run-threaded.Tpo $(DEPDIR)/run_threaded-run-threaded.Po
737 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='run-threaded.c' object='run_threaded-run-threaded.o' libtool=no @AMDEPBACKSLASH@
738 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
739 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(run_threaded_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o run_threaded-run-threaded.o `test -f 'run-threaded.c' || echo '$(srcdir)/'`run-threaded.c
740
741 run_threaded-run-threaded.obj: run-threaded.c
742 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(run_threaded_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT run_threaded-run-threaded.obj -MD -MP -MF $(DEPDIR)/run_threaded-run-threaded.Tpo -c -o run_threaded-run-threaded.obj `if test -f 'run-threaded.c'; then $(CYGPATH_W) 'run-threaded.c'; else $(CYGPATH_W) '$(srcdir)/run-threaded.c'; fi`
743 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/run_threaded-run-threaded.Tpo $(DEPDIR)/run_threaded-run-threaded.Po
744 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='run-threaded.c' object='run_threaded-run-threaded.obj' libtool=no @AMDEPBACKSLASH@
745 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
746 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(run_threaded_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o run_threaded-run-threaded.obj `if test -f 'run-threaded.c'; then $(CYGPATH_W) 'run-threaded.c'; else $(CYGPATH_W) '$(srcdir)/run-threaded.c'; fi`
747
748 mostlyclean-libtool:
749 -rm -f *.lo
750
751 clean-libtool:
752 -rm -rf .libs _libs
753
754 # This directory's subdirectories are mostly independent; you can cd
755 # into them and run 'make' without going through this Makefile.
756 # To change the values of 'make' variables: instead of editing Makefiles,
757 # (1) if the variable is set in 'config.status', edit 'config.status'
758 # (which will cause the Makefiles to be regenerated when you run 'make');
759 # (2) otherwise, pass the desired values on the 'make' command line.
760 $(am__recursive_targets):
761 @fail=; \
762 if $(am__make_keepgoing); then \
763 failcom='fail=yes'; \
764 else \
765 failcom='exit 1'; \
766 fi; \
767 dot_seen=no; \
768 target=`echo $@ | sed s/-recursive//`; \
769 case "$@" in \
770 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
771 *) list='$(SUBDIRS)' ;; \
772 esac; \
773 for subdir in $$list; do \
774 echo "Making $$target in $$subdir"; \
775 if test "$$subdir" = "."; then \
776 dot_seen=yes; \
777 local_target="$$target-am"; \
778 else \
779 local_target="$$target"; \
780 fi; \
781 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
782 || eval $$failcom; \
783 done; \
784 if test "$$dot_seen" = "no"; then \
785 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
786 fi; test -z "$$fail"
787
788 ID: $(am__tagged_files)
789 $(am__define_uniq_tagged_files); mkid -fID $$unique
790 tags: tags-recursive
791 TAGS: tags
792
793 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
794 set x; \
795 here=`pwd`; \
796 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
797 include_option=--etags-include; \
798 empty_fix=.; \
799 else \
800 include_option=--include; \
801 empty_fix=; \
802 fi; \
803 list='$(SUBDIRS)'; for subdir in $$list; do \
804 if test "$$subdir" = .; then :; else \
805 test ! -f $$subdir/TAGS || \
806 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
807 fi; \
808 done; \
809 $(am__define_uniq_tagged_files); \
810 shift; \
811 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
812 test -n "$$unique" || unique=$$empty_fix; \
813 if test $$# -gt 0; then \
814 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
815 "$$@" $$unique; \
816 else \
817 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
818 $$unique; \
819 fi; \
820 fi
821 ctags: ctags-recursive
822
823 CTAGS: ctags
824 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
825 $(am__define_uniq_tagged_files); \
826 test -z "$(CTAGS_ARGS)$$unique" \
827 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
828 $$unique
829
830 GTAGS:
831 here=`$(am__cd) $(top_builddir) && pwd` \
832 && $(am__cd) $(top_srcdir) \
833 && gtags -i $(GTAGS_ARGS) "$$here"
834 cscopelist: cscopelist-recursive
835
836 cscopelist-am: $(am__tagged_files)
837 list='$(am__tagged_files)'; \
838 case "$(srcdir)" in \
839 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
840 *) sdir=$(subdir)/$(srcdir) ;; \
841 esac; \
842 for i in $$list; do \
843 if test -f "$$i"; then \
844 echo "$(subdir)/$$i"; \
845 else \
846 echo "$$sdir/$$i"; \
847 fi; \
848 done >> $(top_builddir)/cscope.files
849
850 distclean-tags:
851 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
852
853 check-TESTS: $(TESTS)
854 @failed=0; all=0; xfail=0; xpass=0; skip=0; \
855 srcdir=$(srcdir); export srcdir; \
856 list=' $(TESTS) '; \
857 $(am__tty_colors); \
858 if test -n "$$list"; then \
859 for tst in $$list; do \
860 if test -f ./$$tst; then dir=./; \
861 elif test -f $$tst; then dir=; \
862 else dir="$(srcdir)/"; fi; \
863 if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
864 all=`expr $$all + 1`; \
865 case " $(XFAIL_TESTS) " in \
866 *[\ \ ]$$tst[\ \ ]*) \
867 xpass=`expr $$xpass + 1`; \
868 failed=`expr $$failed + 1`; \
869 col=$$red; res=XPASS; \
870 ;; \
871 *) \
872 col=$$grn; res=PASS; \
873 ;; \
874 esac; \
875 elif test $$? -ne 77; then \
876 all=`expr $$all + 1`; \
877 case " $(XFAIL_TESTS) " in \
878 *[\ \ ]$$tst[\ \ ]*) \
879 xfail=`expr $$xfail + 1`; \
880 col=$$lgn; res=XFAIL; \
881 ;; \
882 *) \
883 failed=`expr $$failed + 1`; \
884 col=$$red; res=FAIL; \
885 ;; \
886 esac; \
887 else \
888 skip=`expr $$skip + 1`; \
889 col=$$blu; res=SKIP; \
890 fi; \
891 echo "$${col}$$res$${std}: $$tst"; \
892 done; \
893 if test "$$all" -eq 1; then \
894 tests="test"; \
895 All=""; \
896 else \
897 tests="tests"; \
898 All="All "; \
899 fi; \
900 if test "$$failed" -eq 0; then \
901 if test "$$xfail" -eq 0; then \
902 banner="$$All$$all $$tests passed"; \
903 else \
904 if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
905 banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
906 fi; \
907 else \
908 if test "$$xpass" -eq 0; then \
909 banner="$$failed of $$all $$tests failed"; \
910 else \
911 if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
912 banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
913 fi; \
914 fi; \
915 dashes="$$banner"; \
916 skipped=""; \
917 if test "$$skip" -ne 0; then \
918 if test "$$skip" -eq 1; then \
919 skipped="($$skip test was not run)"; \
920 else \
921 skipped="($$skip tests were not run)"; \
922 fi; \
923 test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
924 dashes="$$skipped"; \
925 fi; \
926 report=""; \
927 if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
928 report="Please report to $(PACKAGE_BUGREPORT)"; \
929 test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
930 dashes="$$report"; \
931 fi; \
932 dashes=`echo "$$dashes" | sed s/./=/g`; \
933 if test "$$failed" -eq 0; then \
934 col="$$grn"; \
935 else \
936 col="$$red"; \
937 fi; \
938 echo "$${col}$$dashes$${std}"; \
939 echo "$${col}$$banner$${std}"; \
940 test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
941 test -z "$$report" || echo "$${col}$$report$${std}"; \
942 echo "$${col}$$dashes$${std}"; \
943 test "$$failed" -eq 0; \
944 else :; fi
945
946 distdir: $(BUILT_SOURCES)
947 $(MAKE) $(AM_MAKEFLAGS) distdir-am
948
949 distdir-am: $(DISTFILES)
950 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
951 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
952 list='$(DISTFILES)'; \
953 dist_files=`for file in $$list; do echo $$file; done | \
954 sed -e "s|^$$srcdirstrip/||;t" \
955 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
956 case $$dist_files in \
957 */*) $(MKDIR_P) `echo "$$dist_files" | \
958 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
959 sort -u` ;; \
960 esac; \
961 for file in $$dist_files; do \
962 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
963 if test -d $$d/$$file; then \
964 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
965 if test -d "$(distdir)/$$file"; then \
966 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
967 fi; \
968 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
969 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
970 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
971 fi; \
972 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
973 else \
974 test -f "$(distdir)/$$file" \
975 || cp -p $$d/$$file "$(distdir)/$$file" \
976 || exit 1; \
977 fi; \
978 done
979 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
980 if test "$$subdir" = .; then :; else \
981 $(am__make_dryrun) \
982 || test -d "$(distdir)/$$subdir" \
983 || $(MKDIR_P) "$(distdir)/$$subdir" \
984 || exit 1; \
985 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
986 $(am__relativize); \
987 new_distdir=$$reldir; \
988 dir1=$$subdir; dir2="$(top_distdir)"; \
989 $(am__relativize); \
990 new_top_distdir=$$reldir; \
991 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
992 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
993 ($(am__cd) $$subdir && \
994 $(MAKE) $(AM_MAKEFLAGS) \
995 top_distdir="$$new_top_distdir" \
996 distdir="$$new_distdir" \
997 am__remove_distdir=: \
998 am__skip_length_check=: \
999 am__skip_mode_fix=: \
1000 distdir) \
1001 || exit 1; \
1002 fi; \
1003 done
1004 check-am: all-am
1005 $(MAKE) $(AM_MAKEFLAGS) check-TESTS
1006 check: check-recursive
1007 all-am: Makefile $(PROGRAMS) $(HEADERS)
1008 installdirs: installdirs-recursive
1009 installdirs-am:
1010 install: install-recursive
1011 install-exec: install-exec-recursive
1012 install-data: install-data-recursive
1013 uninstall: uninstall-recursive
1014
1015 install-am: all-am
1016 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
1017
1018 installcheck: installcheck-recursive
1019 install-strip:
1020 if test -z '$(STRIP)'; then \
1021 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1022 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1023 install; \
1024 else \
1025 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1026 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1027 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
1028 fi
1029 mostlyclean-generic:
1030
1031 clean-generic:
1032
1033 distclean-generic:
1034 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
1035 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
1036
1037 maintainer-clean-generic:
1038 @echo "This command is intended for maintainers to use"
1039 @echo "it deletes files that may require special tools to rebuild."
1040 clean: clean-recursive
1041
1042 clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \
1043 mostlyclean-am
1044
1045 distclean: distclean-recursive
1046 -rm -f ./$(DEPDIR)/run-decrypt.Po
1047 -rm -f ./$(DEPDIR)/run-encrypt.Po
1048 -rm -f ./$(DEPDIR)/run-export.Po
1049 -rm -f ./$(DEPDIR)/run-genkey.Po
1050 -rm -f ./$(DEPDIR)/run-identify.Po
1051 -rm -f ./$(DEPDIR)/run-import.Po
1052 -rm -f ./$(DEPDIR)/run-keylist.Po
1053 -rm -f ./$(DEPDIR)/run-keysign.Po
1054 -rm -f ./$(DEPDIR)/run-receive-keys.Po
1055 -rm -f ./$(DEPDIR)/run-sign.Po
1056 -rm -f ./$(DEPDIR)/run-swdb.Po
1057 -rm -f ./$(DEPDIR)/run-tofu.Po
1058 -rm -f ./$(DEPDIR)/run-verify.Po
1059 -rm -f ./$(DEPDIR)/run_threaded-run-threaded.Po
1060 -rm -f ./$(DEPDIR)/t-data.Po
1061 -rm -f ./$(DEPDIR)/t-engine-info.Po
1062 -rm -f ./$(DEPDIR)/t-version.Po
1063 -rm -f Makefile
1064 distclean-am: clean-am distclean-compile distclean-generic \
1065 distclean-tags
1066
1067 dvi: dvi-recursive
1068
1069 dvi-am:
1070
1071 html: html-recursive
1072
1073 html-am:
1074
1075 info: info-recursive
1076
1077 info-am:
1078
1079 install-data-am:
1080
1081 install-dvi: install-dvi-recursive
1082
1083 install-dvi-am:
1084
1085 install-exec-am:
1086
1087 install-html: install-html-recursive
1088
1089 install-html-am:
1090
1091 install-info: install-info-recursive
1092
1093 install-info-am:
1094
1095 install-man:
1096
1097 install-pdf: install-pdf-recursive
1098
1099 install-pdf-am:
1100
1101 install-ps: install-ps-recursive
1102
1103 install-ps-am:
1104
1105 installcheck-am:
1106
1107 maintainer-clean: maintainer-clean-recursive
1108 -rm -f ./$(DEPDIR)/run-decrypt.Po
1109 -rm -f ./$(DEPDIR)/run-encrypt.Po
1110 -rm -f ./$(DEPDIR)/run-export.Po
1111 -rm -f ./$(DEPDIR)/run-genkey.Po
1112 -rm -f ./$(DEPDIR)/run-identify.Po
1113 -rm -f ./$(DEPDIR)/run-import.Po
1114 -rm -f ./$(DEPDIR)/run-keylist.Po
1115 -rm -f ./$(DEPDIR)/run-keysign.Po
1116 -rm -f ./$(DEPDIR)/run-receive-keys.Po
1117 -rm -f ./$(DEPDIR)/run-sign.Po
1118 -rm -f ./$(DEPDIR)/run-swdb.Po
1119 -rm -f ./$(DEPDIR)/run-tofu.Po
1120 -rm -f ./$(DEPDIR)/run-verify.Po
1121 -rm -f ./$(DEPDIR)/run_threaded-run-threaded.Po
1122 -rm -f ./$(DEPDIR)/t-data.Po
1123 -rm -f ./$(DEPDIR)/t-engine-info.Po
1124 -rm -f ./$(DEPDIR)/t-version.Po
1125 -rm -f Makefile
1126 maintainer-clean-am: distclean-am maintainer-clean-generic
1127
1128 mostlyclean: mostlyclean-recursive
1129
1130 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
1131 mostlyclean-libtool
1132
1133 pdf: pdf-recursive
1134
1135 pdf-am:
1136
1137 ps: ps-recursive
1138
1139 ps-am:
1140
1141 uninstall-am:
1142
1143 .MAKE: $(am__recursive_targets) check-am install-am install-strip
1144
1145 .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
1146 am--depfiles check check-TESTS check-am clean clean-generic \
1147 clean-libtool clean-noinstPROGRAMS cscopelist-am ctags \
1148 ctags-am distclean distclean-compile distclean-generic \
1149 distclean-libtool distclean-tags distdir dvi dvi-am html \
1150 html-am info info-am install install-am install-data \
1151 install-data-am install-dvi install-dvi-am install-exec \
1152 install-exec-am install-html install-html-am install-info \
1153 install-info-am install-man install-pdf install-pdf-am \
1154 install-ps install-ps-am install-strip installcheck \
1155 installcheck-am installdirs installdirs-am maintainer-clean \
1156 maintainer-clean-generic mostlyclean mostlyclean-compile \
1157 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
1158 tags tags-am uninstall uninstall-am
1159
1160 .PRECIOUS: Makefile
1161
1162
1163 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1164 # Otherwise a system limit (for SysV at least) may be exceeded.
1165 .NOEXPORT:
3737 c_tests = \
3838 t-encrypt t-encrypt-sym t-encrypt-sign t-sign t-signers \
3939 t-decrypt t-verify t-decrypt-verify t-sig-notation t-export \
40 t-import t-edit t-keylist t-keylist-sig t-keylist-secret-sig t-wait \
41 t-encrypt-large t-file-name t-gpgconf t-encrypt-mixed t-edit-sign \
40 t-import t-edit t-keylist t-keylist-sig t-keylist-secret-sig t-wait \
41 t-encrypt-large t-file-name t-gpgconf t-encrypt-mixed t-edit-sign \
4242 $(tests_unix)
4343
4444 TESTS = initial.test $(c_tests) final.test
5959 EXTRA_DIST = initial.test final.test \
6060 pubdemo.asc secdemo.asc cipher-1.asc cipher-2.asc \
6161 cipher-3.asc cipher-no-sig.asc \
62 geheim.txt pubkey-1.asc seckey-1.asc pinentry $(private_keys)
62 geheim.txt pubkey-1.asc seckey-1.asc pinentry $(private_keys) \
63 gpg.conf.in
6364
6465 BUILT_SOURCES = gpg.conf gpg-agent.conf pubring-stamp \
6566 gpg-sample.stamp
6667 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
6768 AM_LDFLAGS = -no-install
6869 LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
69 t_thread1_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
70 t_thread_keylist_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
71 t_thread_keylist_verify_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
72 t_cancel_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
70
71 WITH_THREAD_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_MT_CFLAGS@
72 WITH_THREAD_LDADD = ../../src/libgpgme.la \
73 @GPG_ERROR_MT_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
74 t_thread1_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
75 t_thread1_LDADD = $(WITH_THREAD_LDADD)
76 t_thread_keylist_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
77 t_thread_keylist_LDADD = $(WITH_THREAD_LDADD)
78 t_thread_keylist_verify_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
79 t_thread_keylist_verify_LDADD = $(WITH_THREAD_LDADD)
80 t_cancel_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
81 t_cancel_LDADD = $(WITH_THREAD_LDADD)
7382
7483 # We don't run t-genkey and t-cancel in the test suite, because it
7584 # takes too long
100109 --import $(srcdir)/secdemo.asc
101110 echo x > ./pubring-stamp
102111
103 gpg.conf:
104 # This is required for t-sig-notations.
105 echo no-force-v3-sigs > ./gpg.conf
106 # This is required for t-edit-sign.
107 echo allow-weak-key-signatures >> ./gpg.conf
112 gpg.conf: $(srcdir)/gpg.conf.in
113 cp $(srcdir)/gpg.conf.in gpg.conf
108114
109115 gpg-agent.conf:
110116 # This is required for gpg2, which does not support command fd for the
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Copyright (C) 2000 Werner Koch (dd9jn)
17 # Copyright (C) 2001, 2004, 2005, 2009 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34
35
36 VPATH = @srcdir@
37 am__is_gnu_make = { \
38 if test -z '$(MAKELEVEL)'; then \
39 false; \
40 elif test -n '$(MAKE_HOST)'; then \
41 true; \
42 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
43 true; \
44 else \
45 false; \
46 fi; \
47 }
48 am__make_running_with_option = \
49 case $${target_option-} in \
50 ?) ;; \
51 *) echo "am__make_running_with_option: internal error: invalid" \
52 "target option '$${target_option-}' specified" >&2; \
53 exit 1;; \
54 esac; \
55 has_opt=no; \
56 sane_makeflags=$$MAKEFLAGS; \
57 if $(am__is_gnu_make); then \
58 sane_makeflags=$$MFLAGS; \
59 else \
60 case $$MAKEFLAGS in \
61 *\\[\ \ ]*) \
62 bs=\\; \
63 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
64 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
65 esac; \
66 fi; \
67 skip_next=no; \
68 strip_trailopt () \
69 { \
70 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
71 }; \
72 for flg in $$sane_makeflags; do \
73 test $$skip_next = yes && { skip_next=no; continue; }; \
74 case $$flg in \
75 *=*|--*) continue;; \
76 -*I) strip_trailopt 'I'; skip_next=yes;; \
77 -*I?*) strip_trailopt 'I';; \
78 -*O) strip_trailopt 'O'; skip_next=yes;; \
79 -*O?*) strip_trailopt 'O';; \
80 -*l) strip_trailopt 'l'; skip_next=yes;; \
81 -*l?*) strip_trailopt 'l';; \
82 -[dEDm]) skip_next=yes;; \
83 -[JT]) skip_next=yes;; \
84 esac; \
85 case $$flg in \
86 *$$target_option*) has_opt=yes; break;; \
87 esac; \
88 done; \
89 test $$has_opt = yes
90 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
91 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
92 pkgdatadir = $(datadir)/@PACKAGE@
93 pkgincludedir = $(includedir)/@PACKAGE@
94 pkglibdir = $(libdir)/@PACKAGE@
95 pkglibexecdir = $(libexecdir)/@PACKAGE@
96 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
97 install_sh_DATA = $(install_sh) -c -m 644
98 install_sh_PROGRAM = $(install_sh) -c
99 install_sh_SCRIPT = $(install_sh) -c
100 INSTALL_HEADER = $(INSTALL_DATA)
101 transform = $(program_transform_name)
102 NORMAL_INSTALL = :
103 PRE_INSTALL = :
104 POST_INSTALL = :
105 NORMAL_UNINSTALL = :
106 PRE_UNINSTALL = :
107 POST_UNINSTALL = :
108 build_triplet = @build@
109 host_triplet = @host@
110 TESTS = initial.test $(am__EXEEXT_2) final.test
111 @HAVE_W32_SYSTEM_FALSE@am__append_1 = t-cancel
112 noinst_PROGRAMS = $(am__EXEEXT_2) $(am__EXEEXT_4)
113 subdir = tests/gpg
114 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
115 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
116 $(top_srcdir)/m4/ax_pkg_swig.m4 \
117 $(top_srcdir)/m4/ax_python_devel.m4 \
118 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
119 $(top_srcdir)/m4/gnupg-ttyname.m4 \
120 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
121 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
122 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
123 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
124 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
125 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
126 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
127 $(ACLOCAL_M4)
128 DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \
129 $(am__DIST_COMMON)
130 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
131 CONFIG_HEADER = $(top_builddir)/conf/config.h
132 CONFIG_CLEAN_FILES =
133 CONFIG_CLEAN_VPATH_FILES =
134 @HAVE_W32_SYSTEM_FALSE@am__EXEEXT_1 = t-eventloop$(EXEEXT) \
135 @HAVE_W32_SYSTEM_FALSE@ t-thread1$(EXEEXT) \
136 @HAVE_W32_SYSTEM_FALSE@ t-thread-keylist$(EXEEXT) \
137 @HAVE_W32_SYSTEM_FALSE@ t-thread-keylist-verify$(EXEEXT)
138 am__EXEEXT_2 = t-encrypt$(EXEEXT) t-encrypt-sym$(EXEEXT) \
139 t-encrypt-sign$(EXEEXT) t-sign$(EXEEXT) t-signers$(EXEEXT) \
140 t-decrypt$(EXEEXT) t-verify$(EXEEXT) t-decrypt-verify$(EXEEXT) \
141 t-sig-notation$(EXEEXT) t-export$(EXEEXT) t-import$(EXEEXT) \
142 t-edit$(EXEEXT) t-keylist$(EXEEXT) t-keylist-sig$(EXEEXT) \
143 t-keylist-secret-sig$(EXEEXT) t-wait$(EXEEXT) \
144 t-encrypt-large$(EXEEXT) t-file-name$(EXEEXT) \
145 t-gpgconf$(EXEEXT) t-encrypt-mixed$(EXEEXT) \
146 t-edit-sign$(EXEEXT) $(am__EXEEXT_1)
147 @HAVE_W32_SYSTEM_FALSE@am__EXEEXT_3 = t-cancel$(EXEEXT)
148 am__EXEEXT_4 = t-genkey$(EXEEXT) $(am__EXEEXT_3)
149 PROGRAMS = $(noinst_PROGRAMS)
150 t_cancel_SOURCES = t-cancel.c
151 t_cancel_OBJECTS = t_cancel-t-cancel.$(OBJEXT)
152 am__DEPENDENCIES_1 = ../../src/libgpgme.la
153 t_cancel_DEPENDENCIES = $(am__DEPENDENCIES_1)
154 AM_V_lt = $(am__v_lt_@AM_V@)
155 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
156 am__v_lt_0 = --silent
157 am__v_lt_1 =
158 t_decrypt_SOURCES = t-decrypt.c
159 t_decrypt_OBJECTS = t-decrypt.$(OBJEXT)
160 t_decrypt_LDADD = $(LDADD)
161 t_decrypt_DEPENDENCIES = ../../src/libgpgme.la
162 t_decrypt_verify_SOURCES = t-decrypt-verify.c
163 t_decrypt_verify_OBJECTS = t-decrypt-verify.$(OBJEXT)
164 t_decrypt_verify_LDADD = $(LDADD)
165 t_decrypt_verify_DEPENDENCIES = ../../src/libgpgme.la
166 t_edit_SOURCES = t-edit.c
167 t_edit_OBJECTS = t-edit.$(OBJEXT)
168 t_edit_LDADD = $(LDADD)
169 t_edit_DEPENDENCIES = ../../src/libgpgme.la
170 t_edit_sign_SOURCES = t-edit-sign.c
171 t_edit_sign_OBJECTS = t-edit-sign.$(OBJEXT)
172 t_edit_sign_LDADD = $(LDADD)
173 t_edit_sign_DEPENDENCIES = ../../src/libgpgme.la
174 t_encrypt_SOURCES = t-encrypt.c
175 t_encrypt_OBJECTS = t-encrypt.$(OBJEXT)
176 t_encrypt_LDADD = $(LDADD)
177 t_encrypt_DEPENDENCIES = ../../src/libgpgme.la
178 t_encrypt_large_SOURCES = t-encrypt-large.c
179 t_encrypt_large_OBJECTS = t-encrypt-large.$(OBJEXT)
180 t_encrypt_large_LDADD = $(LDADD)
181 t_encrypt_large_DEPENDENCIES = ../../src/libgpgme.la
182 t_encrypt_mixed_SOURCES = t-encrypt-mixed.c
183 t_encrypt_mixed_OBJECTS = t-encrypt-mixed.$(OBJEXT)
184 t_encrypt_mixed_LDADD = $(LDADD)
185 t_encrypt_mixed_DEPENDENCIES = ../../src/libgpgme.la
186 t_encrypt_sign_SOURCES = t-encrypt-sign.c
187 t_encrypt_sign_OBJECTS = t-encrypt-sign.$(OBJEXT)
188 t_encrypt_sign_LDADD = $(LDADD)
189 t_encrypt_sign_DEPENDENCIES = ../../src/libgpgme.la
190 t_encrypt_sym_SOURCES = t-encrypt-sym.c
191 t_encrypt_sym_OBJECTS = t-encrypt-sym.$(OBJEXT)
192 t_encrypt_sym_LDADD = $(LDADD)
193 t_encrypt_sym_DEPENDENCIES = ../../src/libgpgme.la
194 t_eventloop_SOURCES = t-eventloop.c
195 t_eventloop_OBJECTS = t-eventloop.$(OBJEXT)
196 t_eventloop_LDADD = $(LDADD)
197 t_eventloop_DEPENDENCIES = ../../src/libgpgme.la
198 t_export_SOURCES = t-export.c
199 t_export_OBJECTS = t-export.$(OBJEXT)
200 t_export_LDADD = $(LDADD)
201 t_export_DEPENDENCIES = ../../src/libgpgme.la
202 t_file_name_SOURCES = t-file-name.c
203 t_file_name_OBJECTS = t-file-name.$(OBJEXT)
204 t_file_name_LDADD = $(LDADD)
205 t_file_name_DEPENDENCIES = ../../src/libgpgme.la
206 t_genkey_SOURCES = t-genkey.c
207 t_genkey_OBJECTS = t-genkey.$(OBJEXT)
208 t_genkey_LDADD = $(LDADD)
209 t_genkey_DEPENDENCIES = ../../src/libgpgme.la
210 t_gpgconf_SOURCES = t-gpgconf.c
211 t_gpgconf_OBJECTS = t-gpgconf.$(OBJEXT)
212 t_gpgconf_LDADD = $(LDADD)
213 t_gpgconf_DEPENDENCIES = ../../src/libgpgme.la
214 t_import_SOURCES = t-import.c
215 t_import_OBJECTS = t-import.$(OBJEXT)
216 t_import_LDADD = $(LDADD)
217 t_import_DEPENDENCIES = ../../src/libgpgme.la
218 t_keylist_SOURCES = t-keylist.c
219 t_keylist_OBJECTS = t-keylist.$(OBJEXT)
220 t_keylist_LDADD = $(LDADD)
221 t_keylist_DEPENDENCIES = ../../src/libgpgme.la
222 t_keylist_secret_sig_SOURCES = t-keylist-secret-sig.c
223 t_keylist_secret_sig_OBJECTS = t-keylist-secret-sig.$(OBJEXT)
224 t_keylist_secret_sig_LDADD = $(LDADD)
225 t_keylist_secret_sig_DEPENDENCIES = ../../src/libgpgme.la
226 t_keylist_sig_SOURCES = t-keylist-sig.c
227 t_keylist_sig_OBJECTS = t-keylist-sig.$(OBJEXT)
228 t_keylist_sig_LDADD = $(LDADD)
229 t_keylist_sig_DEPENDENCIES = ../../src/libgpgme.la
230 t_sig_notation_SOURCES = t-sig-notation.c
231 t_sig_notation_OBJECTS = t-sig-notation.$(OBJEXT)
232 t_sig_notation_LDADD = $(LDADD)
233 t_sig_notation_DEPENDENCIES = ../../src/libgpgme.la
234 t_sign_SOURCES = t-sign.c
235 t_sign_OBJECTS = t-sign.$(OBJEXT)
236 t_sign_LDADD = $(LDADD)
237 t_sign_DEPENDENCIES = ../../src/libgpgme.la
238 t_signers_SOURCES = t-signers.c
239 t_signers_OBJECTS = t-signers.$(OBJEXT)
240 t_signers_LDADD = $(LDADD)
241 t_signers_DEPENDENCIES = ../../src/libgpgme.la
242 t_thread_keylist_SOURCES = t-thread-keylist.c
243 t_thread_keylist_OBJECTS = \
244 t_thread_keylist-t-thread-keylist.$(OBJEXT)
245 t_thread_keylist_DEPENDENCIES = $(am__DEPENDENCIES_1)
246 t_thread_keylist_verify_SOURCES = t-thread-keylist-verify.c
247 t_thread_keylist_verify_OBJECTS = \
248 t_thread_keylist_verify-t-thread-keylist-verify.$(OBJEXT)
249 t_thread_keylist_verify_DEPENDENCIES = $(am__DEPENDENCIES_1)
250 t_thread1_SOURCES = t-thread1.c
251 t_thread1_OBJECTS = t_thread1-t-thread1.$(OBJEXT)
252 t_thread1_DEPENDENCIES = $(am__DEPENDENCIES_1)
253 t_verify_SOURCES = t-verify.c
254 t_verify_OBJECTS = t-verify.$(OBJEXT)
255 t_verify_LDADD = $(LDADD)
256 t_verify_DEPENDENCIES = ../../src/libgpgme.la
257 t_wait_SOURCES = t-wait.c
258 t_wait_OBJECTS = t-wait.$(OBJEXT)
259 t_wait_LDADD = $(LDADD)
260 t_wait_DEPENDENCIES = ../../src/libgpgme.la
261 AM_V_P = $(am__v_P_@AM_V@)
262 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
263 am__v_P_0 = false
264 am__v_P_1 = :
265 AM_V_GEN = $(am__v_GEN_@AM_V@)
266 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
267 am__v_GEN_0 = @echo " GEN " $@;
268 am__v_GEN_1 =
269 AM_V_at = $(am__v_at_@AM_V@)
270 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
271 am__v_at_0 = @
272 am__v_at_1 =
273 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
274 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
275 am__maybe_remake_depfiles = depfiles
276 am__depfiles_remade = ./$(DEPDIR)/t-decrypt-verify.Po \
277 ./$(DEPDIR)/t-decrypt.Po ./$(DEPDIR)/t-edit-sign.Po \
278 ./$(DEPDIR)/t-edit.Po ./$(DEPDIR)/t-encrypt-large.Po \
279 ./$(DEPDIR)/t-encrypt-mixed.Po ./$(DEPDIR)/t-encrypt-sign.Po \
280 ./$(DEPDIR)/t-encrypt-sym.Po ./$(DEPDIR)/t-encrypt.Po \
281 ./$(DEPDIR)/t-eventloop.Po ./$(DEPDIR)/t-export.Po \
282 ./$(DEPDIR)/t-file-name.Po ./$(DEPDIR)/t-genkey.Po \
283 ./$(DEPDIR)/t-gpgconf.Po ./$(DEPDIR)/t-import.Po \
284 ./$(DEPDIR)/t-keylist-secret-sig.Po \
285 ./$(DEPDIR)/t-keylist-sig.Po ./$(DEPDIR)/t-keylist.Po \
286 ./$(DEPDIR)/t-sig-notation.Po ./$(DEPDIR)/t-sign.Po \
287 ./$(DEPDIR)/t-signers.Po ./$(DEPDIR)/t-verify.Po \
288 ./$(DEPDIR)/t-wait.Po ./$(DEPDIR)/t_cancel-t-cancel.Po \
289 ./$(DEPDIR)/t_thread1-t-thread1.Po \
290 ./$(DEPDIR)/t_thread_keylist-t-thread-keylist.Po \
291 ./$(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Po
292 am__mv = mv -f
293 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
294 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
295 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
296 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
297 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
298 $(AM_CFLAGS) $(CFLAGS)
299 AM_V_CC = $(am__v_CC_@AM_V@)
300 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
301 am__v_CC_0 = @echo " CC " $@;
302 am__v_CC_1 =
303 CCLD = $(CC)
304 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
305 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
306 $(AM_LDFLAGS) $(LDFLAGS) -o $@
307 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
308 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
309 am__v_CCLD_0 = @echo " CCLD " $@;
310 am__v_CCLD_1 =
311 SOURCES = t-cancel.c t-decrypt.c t-decrypt-verify.c t-edit.c \
312 t-edit-sign.c t-encrypt.c t-encrypt-large.c t-encrypt-mixed.c \
313 t-encrypt-sign.c t-encrypt-sym.c t-eventloop.c t-export.c \
314 t-file-name.c t-genkey.c t-gpgconf.c t-import.c t-keylist.c \
315 t-keylist-secret-sig.c t-keylist-sig.c t-sig-notation.c \
316 t-sign.c t-signers.c t-thread-keylist.c \
317 t-thread-keylist-verify.c t-thread1.c t-verify.c t-wait.c
318 DIST_SOURCES = t-cancel.c t-decrypt.c t-decrypt-verify.c t-edit.c \
319 t-edit-sign.c t-encrypt.c t-encrypt-large.c t-encrypt-mixed.c \
320 t-encrypt-sign.c t-encrypt-sym.c t-eventloop.c t-export.c \
321 t-file-name.c t-genkey.c t-gpgconf.c t-import.c t-keylist.c \
322 t-keylist-secret-sig.c t-keylist-sig.c t-sig-notation.c \
323 t-sign.c t-signers.c t-thread-keylist.c \
324 t-thread-keylist-verify.c t-thread1.c t-verify.c t-wait.c
325 am__can_run_installinfo = \
326 case $$AM_UPDATE_INFO_DIR in \
327 n|no|NO) false;; \
328 *) (install-info --version) >/dev/null 2>&1;; \
329 esac
330 HEADERS = $(noinst_HEADERS)
331 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
332 # Read a list of newline-separated strings from the standard input,
333 # and print each of them once, without duplicates. Input order is
334 # *not* preserved.
335 am__uniquify_input = $(AWK) '\
336 BEGIN { nonempty = 0; } \
337 { items[$$0] = 1; nonempty = 1; } \
338 END { if (nonempty) { for (i in items) print i; }; } \
339 '
340 # Make sure the list of sources is unique. This is necessary because,
341 # e.g., the same source file might be shared among _SOURCES variables
342 # for different programs/libraries.
343 am__define_uniq_tagged_files = \
344 list='$(am__tagged_files)'; \
345 unique=`for i in $$list; do \
346 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
347 done | $(am__uniquify_input)`
348 ETAGS = etags
349 CTAGS = ctags
350 am__tty_colors_dummy = \
351 mgn= red= grn= lgn= blu= brg= std=; \
352 am__color_tests=no
353 am__tty_colors = { \
354 $(am__tty_colors_dummy); \
355 if test "X$(AM_COLOR_TESTS)" = Xno; then \
356 am__color_tests=no; \
357 elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
358 am__color_tests=yes; \
359 elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
360 am__color_tests=yes; \
361 fi; \
362 if test $$am__color_tests = yes; then \
363 red=''; \
364 grn=''; \
365 lgn=''; \
366 blu=''; \
367 mgn=''; \
368 brg=''; \
369 std=''; \
370 fi; \
371 }
372 am__DIST_COMMON = $(srcdir)/Makefile.in \
373 $(top_srcdir)/build-aux/depcomp \
374 $(top_srcdir)/build-aux/mkinstalldirs
375 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
376 ACLOCAL = @ACLOCAL@
377 AMTAR = @AMTAR@
378 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
379 AR = @AR@
380 AS = @AS@
381 AUTOCONF = @AUTOCONF@
382 AUTOHEADER = @AUTOHEADER@
383 AUTOMAKE = @AUTOMAKE@
384 AWK = @AWK@
385 BUILD_FILEVERSION = @BUILD_FILEVERSION@
386 BUILD_REVISION = @BUILD_REVISION@
387 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
388 BUILD_VERSION = @BUILD_VERSION@
389 CC = @CC@
390 CCDEPMODE = @CCDEPMODE@
391 CC_FOR_BUILD = @CC_FOR_BUILD@
392 CFLAGS = @CFLAGS@
393 CPP = @CPP@
394 CPPFLAGS = @CPPFLAGS@
395 CXX = @CXX@
396 CXXCPP = @CXXCPP@
397 CXXDEPMODE = @CXXDEPMODE@
398 CXXFLAGS = @CXXFLAGS@
399 CYGPATH_W = @CYGPATH_W@
400 DEFS = @DEFS@
401 DEPDIR = @DEPDIR@
402 DLLTOOL = @DLLTOOL@
403 DOXYGEN = @DOXYGEN@
404 DSYMUTIL = @DSYMUTIL@
405 DUMPBIN = @DUMPBIN@
406 ECHO_C = @ECHO_C@
407 ECHO_N = @ECHO_N@
408 ECHO_T = @ECHO_T@
409 EGREP = @EGREP@
410 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
411 EXEEXT = @EXEEXT@
412 FGREP = @FGREP@
413 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
414 GLIBC21 = @GLIBC21@
415 GLIB_CFLAGS = @GLIB_CFLAGS@
416 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
417 GLIB_LIBS = @GLIB_LIBS@
418 GLIB_MKENUMS = @GLIB_MKENUMS@
419 GOBJECT_QUERY = @GOBJECT_QUERY@
420 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
421 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
422 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
423 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
424 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
425 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
426 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
427 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
428 GPGME_QT_LIBS = @GPGME_QT_LIBS@
429 GPGRT_CONFIG = @GPGRT_CONFIG@
430 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
431 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
432 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
433 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
434 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
435 GRAPHVIZ = @GRAPHVIZ@
436 GREP = @GREP@
437 HAVE_CXX11 = @HAVE_CXX11@
438 HAVE_DOT = @HAVE_DOT@
439 INSTALL = @INSTALL@
440 INSTALL_DATA = @INSTALL_DATA@
441 INSTALL_PROGRAM = @INSTALL_PROGRAM@
442 INSTALL_SCRIPT = @INSTALL_SCRIPT@
443 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
444 LD = @LD@
445 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
446 LDFLAGS = @LDFLAGS@
447 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
448 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
449 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
450 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
451 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
452 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
453 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
454 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
455 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
456 LIBOBJS = @LIBOBJS@
457 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
458 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
459 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
460 LIBS = @LIBS@
461 LIBTOOL = @LIBTOOL@
462 LIPO = @LIPO@
463 LN_S = @LN_S@
464 LTLIBOBJS = @LTLIBOBJS@
465 MAINT = @MAINT@
466 MAKEINFO = @MAKEINFO@
467 MANIFEST_TOOL = @MANIFEST_TOOL@
468 MKDIR_P = @MKDIR_P@
469 MOC = @MOC@
470 MOC2 = @MOC2@
471 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
472 NM = @NM@
473 NMEDIT = @NMEDIT@
474 OBJDUMP = @OBJDUMP@
475 OBJEXT = @OBJEXT@
476 OTOOL = @OTOOL@
477 OTOOL64 = @OTOOL64@
478 PACKAGE = @PACKAGE@
479 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
480 PACKAGE_NAME = @PACKAGE_NAME@
481 PACKAGE_STRING = @PACKAGE_STRING@
482 PACKAGE_TARNAME = @PACKAGE_TARNAME@
483 PACKAGE_URL = @PACKAGE_URL@
484 PACKAGE_VERSION = @PACKAGE_VERSION@
485 PATH_SEPARATOR = @PATH_SEPARATOR@
486 PKG_CONFIG = @PKG_CONFIG@
487 PYTHON = @PYTHON@
488 PYTHONS = @PYTHONS@
489 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
490 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
491 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
492 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
493 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
494 PYTHON_PLATFORM = @PYTHON_PLATFORM@
495 PYTHON_PREFIX = @PYTHON_PREFIX@
496 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
497 PYTHON_VERSION = @PYTHON_VERSION@
498 QTCHOOSER = @QTCHOOSER@
499 RANLIB = @RANLIB@
500 RC = @RC@
501 SED = @SED@
502 SET_MAKE = @SET_MAKE@
503 SHELL = @SHELL@
504 STRIP = @STRIP@
505 SWIG = @SWIG@
506 SWIG_LIB = @SWIG_LIB@
507 SYSROOT = @SYSROOT@
508 VERSION = @VERSION@
509 VERSION_MAJOR = @VERSION_MAJOR@
510 VERSION_MICRO = @VERSION_MICRO@
511 VERSION_MINOR = @VERSION_MINOR@
512 VERSION_NUMBER = @VERSION_NUMBER@
513 abs_builddir = @abs_builddir@
514 abs_srcdir = @abs_srcdir@
515 abs_top_builddir = @abs_top_builddir@
516 abs_top_srcdir = @abs_top_srcdir@
517 ac_ct_AR = @ac_ct_AR@
518 ac_ct_CC = @ac_ct_CC@
519 ac_ct_CXX = @ac_ct_CXX@
520 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
521 am__include = @am__include@
522 am__leading_dot = @am__leading_dot@
523 am__quote = @am__quote@
524 am__tar = @am__tar@
525 am__untar = @am__untar@
526 bindir = @bindir@
527 build = @build@
528 build_alias = @build_alias@
529 build_cpu = @build_cpu@
530 build_os = @build_os@
531 build_vendor = @build_vendor@
532 builddir = @builddir@
533 datadir = @datadir@
534 datarootdir = @datarootdir@
535 docdir = @docdir@
536 dvidir = @dvidir@
537 emacs_local_vars_begin = @emacs_local_vars_begin@
538 emacs_local_vars_end = @emacs_local_vars_end@
539 emacs_local_vars_read_only = @emacs_local_vars_read_only@
540 exec_prefix = @exec_prefix@
541 host = @host@
542 host_alias = @host_alias@
543 host_cpu = @host_cpu@
544 host_os = @host_os@
545 host_vendor = @host_vendor@
546 htmldir = @htmldir@
547 includedir = @includedir@
548 infodir = @infodir@
549 install_sh = @install_sh@
550 libdir = @libdir@
551 libexecdir = @libexecdir@
552 localedir = @localedir@
553 localstatedir = @localstatedir@
554 mandir = @mandir@
555 mkdir_p = @mkdir_p@
556 oldincludedir = @oldincludedir@
557 pdfdir = @pdfdir@
558 pkgpyexecdir = @pkgpyexecdir@
559 pkgpythondir = @pkgpythondir@
560 prefix = @prefix@
561 program_transform_name = @program_transform_name@
562 psdir = @psdir@
563 pyexecdir = @pyexecdir@
564 pythondir = @pythondir@
565 runstatedir = @runstatedir@
566 sbindir = @sbindir@
567 sharedstatedir = @sharedstatedir@
568 srcdir = @srcdir@
569 sysconfdir = @sysconfdir@
570 target_alias = @target_alias@
571 top_build_prefix = @top_build_prefix@
572 top_builddir = @top_builddir@
573 top_srcdir = @top_srcdir@
574 GPG = gpg
575 GPG_AGENT = gpg-agent
576 GNUPGHOME = $(abs_builddir)
577 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME) LC_ALL=C GPG_AGENT_INFO= \
578 top_srcdir=$(top_srcdir)
579
580
581 # The keylist tests must come after the import and the edit test.
582 noinst_HEADERS = t-support.h
583 @HAVE_W32_SYSTEM_FALSE@tests_unix = t-eventloop t-thread1 t-thread-keylist t-thread-keylist-verify
584 @HAVE_W32_SYSTEM_TRUE@tests_unix =
585 c_tests = \
586 t-encrypt t-encrypt-sym t-encrypt-sign t-sign t-signers \
587 t-decrypt t-verify t-decrypt-verify t-sig-notation t-export \
588 t-import t-edit t-keylist t-keylist-sig t-keylist-secret-sig t-wait \
589 t-encrypt-large t-file-name t-gpgconf t-encrypt-mixed t-edit-sign \
590 $(tests_unix)
591
592 CLEANFILES = secring.gpg pubring.gpg pubring.kbx trustdb.gpg dirmngr.conf \
593 gpg-agent.conf pubring.kbx~ S.gpg-agent gpg.conf pubring.gpg~ \
594 random_seed S.gpg-agent .gpg-v21-migrated pubring-stamp \
595 gpg-sample.stamp tofu.db *.conf.gpgconf.bak
596
597 private_keys = \
598 13CD0F3BDF24BE53FE192D62F18737256FF6E4FD \
599 76F7E2B35832976B50A27A282D9B87E44577EB66 \
600 A0747D5F9425E6664F4FFBEED20FBCA79FDED2BD \
601 13CBE3758AFE42B5E5E2AE4CED27AFA455E3F87F \
602 7A030357C0F253A5BBCD282FFC4E521B37558F5C
603
604 EXTRA_DIST = initial.test final.test \
605 pubdemo.asc secdemo.asc cipher-1.asc cipher-2.asc \
606 cipher-3.asc cipher-no-sig.asc \
607 geheim.txt pubkey-1.asc seckey-1.asc pinentry $(private_keys) \
608 gpg.conf.in
609
610 BUILT_SOURCES = gpg.conf gpg-agent.conf pubring-stamp \
611 gpg-sample.stamp
612
613 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
614 AM_LDFLAGS = -no-install
615 LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
616 WITH_THREAD_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_MT_CFLAGS@
617 WITH_THREAD_LDADD = ../../src/libgpgme.la \
618 @GPG_ERROR_MT_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
619
620 t_thread1_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
621 t_thread1_LDADD = $(WITH_THREAD_LDADD)
622 t_thread_keylist_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
623 t_thread_keylist_LDADD = $(WITH_THREAD_LDADD)
624 t_thread_keylist_verify_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
625 t_thread_keylist_verify_LDADD = $(WITH_THREAD_LDADD)
626 t_cancel_CPPFLAGS = $(WITH_THREAD_CPPFLAGS)
627 t_cancel_LDADD = $(WITH_THREAD_LDADD)
628
629 # We don't run t-genkey and t-cancel in the test suite, because it
630 # takes too long
631 tests_skipped = t-genkey $(am__append_1)
632 all: $(BUILT_SOURCES)
633 $(MAKE) $(AM_MAKEFLAGS) all-am
634
635 .SUFFIXES:
636 .SUFFIXES: .c .lo .o .obj
637 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
638 @for dep in $?; do \
639 case '$(am__configure_deps)' in \
640 *$$dep*) \
641 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
642 && { if test -f $@; then exit 0; else break; fi; }; \
643 exit 1;; \
644 esac; \
645 done; \
646 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/gpg/Makefile'; \
647 $(am__cd) $(top_srcdir) && \
648 $(AUTOMAKE) --gnu tests/gpg/Makefile
649 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
650 @case '$?' in \
651 *config.status*) \
652 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
653 *) \
654 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
655 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
656 esac;
657
658 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
659 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
660
661 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
662 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
663 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
664 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
665 $(am__aclocal_m4_deps):
666
667 clean-noinstPROGRAMS:
668 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
669 echo " rm -f" $$list; \
670 rm -f $$list || exit $$?; \
671 test -n "$(EXEEXT)" || exit 0; \
672 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
673 echo " rm -f" $$list; \
674 rm -f $$list
675
676 t-cancel$(EXEEXT): $(t_cancel_OBJECTS) $(t_cancel_DEPENDENCIES) $(EXTRA_t_cancel_DEPENDENCIES)
677 @rm -f t-cancel$(EXEEXT)
678 $(AM_V_CCLD)$(LINK) $(t_cancel_OBJECTS) $(t_cancel_LDADD) $(LIBS)
679
680 t-decrypt$(EXEEXT): $(t_decrypt_OBJECTS) $(t_decrypt_DEPENDENCIES) $(EXTRA_t_decrypt_DEPENDENCIES)
681 @rm -f t-decrypt$(EXEEXT)
682 $(AM_V_CCLD)$(LINK) $(t_decrypt_OBJECTS) $(t_decrypt_LDADD) $(LIBS)
683
684 t-decrypt-verify$(EXEEXT): $(t_decrypt_verify_OBJECTS) $(t_decrypt_verify_DEPENDENCIES) $(EXTRA_t_decrypt_verify_DEPENDENCIES)
685 @rm -f t-decrypt-verify$(EXEEXT)
686 $(AM_V_CCLD)$(LINK) $(t_decrypt_verify_OBJECTS) $(t_decrypt_verify_LDADD) $(LIBS)
687
688 t-edit$(EXEEXT): $(t_edit_OBJECTS) $(t_edit_DEPENDENCIES) $(EXTRA_t_edit_DEPENDENCIES)
689 @rm -f t-edit$(EXEEXT)
690 $(AM_V_CCLD)$(LINK) $(t_edit_OBJECTS) $(t_edit_LDADD) $(LIBS)
691
692 t-edit-sign$(EXEEXT): $(t_edit_sign_OBJECTS) $(t_edit_sign_DEPENDENCIES) $(EXTRA_t_edit_sign_DEPENDENCIES)
693 @rm -f t-edit-sign$(EXEEXT)
694 $(AM_V_CCLD)$(LINK) $(t_edit_sign_OBJECTS) $(t_edit_sign_LDADD) $(LIBS)
695
696 t-encrypt$(EXEEXT): $(t_encrypt_OBJECTS) $(t_encrypt_DEPENDENCIES) $(EXTRA_t_encrypt_DEPENDENCIES)
697 @rm -f t-encrypt$(EXEEXT)
698 $(AM_V_CCLD)$(LINK) $(t_encrypt_OBJECTS) $(t_encrypt_LDADD) $(LIBS)
699
700 t-encrypt-large$(EXEEXT): $(t_encrypt_large_OBJECTS) $(t_encrypt_large_DEPENDENCIES) $(EXTRA_t_encrypt_large_DEPENDENCIES)
701 @rm -f t-encrypt-large$(EXEEXT)
702 $(AM_V_CCLD)$(LINK) $(t_encrypt_large_OBJECTS) $(t_encrypt_large_LDADD) $(LIBS)
703
704 t-encrypt-mixed$(EXEEXT): $(t_encrypt_mixed_OBJECTS) $(t_encrypt_mixed_DEPENDENCIES) $(EXTRA_t_encrypt_mixed_DEPENDENCIES)
705 @rm -f t-encrypt-mixed$(EXEEXT)
706 $(AM_V_CCLD)$(LINK) $(t_encrypt_mixed_OBJECTS) $(t_encrypt_mixed_LDADD) $(LIBS)
707
708 t-encrypt-sign$(EXEEXT): $(t_encrypt_sign_OBJECTS) $(t_encrypt_sign_DEPENDENCIES) $(EXTRA_t_encrypt_sign_DEPENDENCIES)
709 @rm -f t-encrypt-sign$(EXEEXT)
710 $(AM_V_CCLD)$(LINK) $(t_encrypt_sign_OBJECTS) $(t_encrypt_sign_LDADD) $(LIBS)
711
712 t-encrypt-sym$(EXEEXT): $(t_encrypt_sym_OBJECTS) $(t_encrypt_sym_DEPENDENCIES) $(EXTRA_t_encrypt_sym_DEPENDENCIES)
713 @rm -f t-encrypt-sym$(EXEEXT)
714 $(AM_V_CCLD)$(LINK) $(t_encrypt_sym_OBJECTS) $(t_encrypt_sym_LDADD) $(LIBS)
715
716 t-eventloop$(EXEEXT): $(t_eventloop_OBJECTS) $(t_eventloop_DEPENDENCIES) $(EXTRA_t_eventloop_DEPENDENCIES)
717 @rm -f t-eventloop$(EXEEXT)
718 $(AM_V_CCLD)$(LINK) $(t_eventloop_OBJECTS) $(t_eventloop_LDADD) $(LIBS)
719
720 t-export$(EXEEXT): $(t_export_OBJECTS) $(t_export_DEPENDENCIES) $(EXTRA_t_export_DEPENDENCIES)
721 @rm -f t-export$(EXEEXT)
722 $(AM_V_CCLD)$(LINK) $(t_export_OBJECTS) $(t_export_LDADD) $(LIBS)
723
724 t-file-name$(EXEEXT): $(t_file_name_OBJECTS) $(t_file_name_DEPENDENCIES) $(EXTRA_t_file_name_DEPENDENCIES)
725 @rm -f t-file-name$(EXEEXT)
726 $(AM_V_CCLD)$(LINK) $(t_file_name_OBJECTS) $(t_file_name_LDADD) $(LIBS)
727
728 t-genkey$(EXEEXT): $(t_genkey_OBJECTS) $(t_genkey_DEPENDENCIES) $(EXTRA_t_genkey_DEPENDENCIES)
729 @rm -f t-genkey$(EXEEXT)
730 $(AM_V_CCLD)$(LINK) $(t_genkey_OBJECTS) $(t_genkey_LDADD) $(LIBS)
731
732 t-gpgconf$(EXEEXT): $(t_gpgconf_OBJECTS) $(t_gpgconf_DEPENDENCIES) $(EXTRA_t_gpgconf_DEPENDENCIES)
733 @rm -f t-gpgconf$(EXEEXT)
734 $(AM_V_CCLD)$(LINK) $(t_gpgconf_OBJECTS) $(t_gpgconf_LDADD) $(LIBS)
735
736 t-import$(EXEEXT): $(t_import_OBJECTS) $(t_import_DEPENDENCIES) $(EXTRA_t_import_DEPENDENCIES)
737 @rm -f t-import$(EXEEXT)
738 $(AM_V_CCLD)$(LINK) $(t_import_OBJECTS) $(t_import_LDADD) $(LIBS)
739
740 t-keylist$(EXEEXT): $(t_keylist_OBJECTS) $(t_keylist_DEPENDENCIES) $(EXTRA_t_keylist_DEPENDENCIES)
741 @rm -f t-keylist$(EXEEXT)
742 $(AM_V_CCLD)$(LINK) $(t_keylist_OBJECTS) $(t_keylist_LDADD) $(LIBS)
743
744 t-keylist-secret-sig$(EXEEXT): $(t_keylist_secret_sig_OBJECTS) $(t_keylist_secret_sig_DEPENDENCIES) $(EXTRA_t_keylist_secret_sig_DEPENDENCIES)
745 @rm -f t-keylist-secret-sig$(EXEEXT)
746 $(AM_V_CCLD)$(LINK) $(t_keylist_secret_sig_OBJECTS) $(t_keylist_secret_sig_LDADD) $(LIBS)
747
748 t-keylist-sig$(EXEEXT): $(t_keylist_sig_OBJECTS) $(t_keylist_sig_DEPENDENCIES) $(EXTRA_t_keylist_sig_DEPENDENCIES)
749 @rm -f t-keylist-sig$(EXEEXT)
750 $(AM_V_CCLD)$(LINK) $(t_keylist_sig_OBJECTS) $(t_keylist_sig_LDADD) $(LIBS)
751
752 t-sig-notation$(EXEEXT): $(t_sig_notation_OBJECTS) $(t_sig_notation_DEPENDENCIES) $(EXTRA_t_sig_notation_DEPENDENCIES)
753 @rm -f t-sig-notation$(EXEEXT)
754 $(AM_V_CCLD)$(LINK) $(t_sig_notation_OBJECTS) $(t_sig_notation_LDADD) $(LIBS)
755
756 t-sign$(EXEEXT): $(t_sign_OBJECTS) $(t_sign_DEPENDENCIES) $(EXTRA_t_sign_DEPENDENCIES)
757 @rm -f t-sign$(EXEEXT)
758 $(AM_V_CCLD)$(LINK) $(t_sign_OBJECTS) $(t_sign_LDADD) $(LIBS)
759
760 t-signers$(EXEEXT): $(t_signers_OBJECTS) $(t_signers_DEPENDENCIES) $(EXTRA_t_signers_DEPENDENCIES)
761 @rm -f t-signers$(EXEEXT)
762 $(AM_V_CCLD)$(LINK) $(t_signers_OBJECTS) $(t_signers_LDADD) $(LIBS)
763
764 t-thread-keylist$(EXEEXT): $(t_thread_keylist_OBJECTS) $(t_thread_keylist_DEPENDENCIES) $(EXTRA_t_thread_keylist_DEPENDENCIES)
765 @rm -f t-thread-keylist$(EXEEXT)
766 $(AM_V_CCLD)$(LINK) $(t_thread_keylist_OBJECTS) $(t_thread_keylist_LDADD) $(LIBS)
767
768 t-thread-keylist-verify$(EXEEXT): $(t_thread_keylist_verify_OBJECTS) $(t_thread_keylist_verify_DEPENDENCIES) $(EXTRA_t_thread_keylist_verify_DEPENDENCIES)
769 @rm -f t-thread-keylist-verify$(EXEEXT)
770 $(AM_V_CCLD)$(LINK) $(t_thread_keylist_verify_OBJECTS) $(t_thread_keylist_verify_LDADD) $(LIBS)
771
772 t-thread1$(EXEEXT): $(t_thread1_OBJECTS) $(t_thread1_DEPENDENCIES) $(EXTRA_t_thread1_DEPENDENCIES)
773 @rm -f t-thread1$(EXEEXT)
774 $(AM_V_CCLD)$(LINK) $(t_thread1_OBJECTS) $(t_thread1_LDADD) $(LIBS)
775
776 t-verify$(EXEEXT): $(t_verify_OBJECTS) $(t_verify_DEPENDENCIES) $(EXTRA_t_verify_DEPENDENCIES)
777 @rm -f t-verify$(EXEEXT)
778 $(AM_V_CCLD)$(LINK) $(t_verify_OBJECTS) $(t_verify_LDADD) $(LIBS)
779
780 t-wait$(EXEEXT): $(t_wait_OBJECTS) $(t_wait_DEPENDENCIES) $(EXTRA_t_wait_DEPENDENCIES)
781 @rm -f t-wait$(EXEEXT)
782 $(AM_V_CCLD)$(LINK) $(t_wait_OBJECTS) $(t_wait_LDADD) $(LIBS)
783
784 mostlyclean-compile:
785 -rm -f *.$(OBJEXT)
786
787 distclean-compile:
788 -rm -f *.tab.c
789
790 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-decrypt-verify.Po@am__quote@ # am--include-marker
791 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-decrypt.Po@am__quote@ # am--include-marker
792 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-edit-sign.Po@am__quote@ # am--include-marker
793 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-edit.Po@am__quote@ # am--include-marker
794 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt-large.Po@am__quote@ # am--include-marker
795 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt-mixed.Po@am__quote@ # am--include-marker
796 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt-sign.Po@am__quote@ # am--include-marker
797 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt-sym.Po@am__quote@ # am--include-marker
798 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt.Po@am__quote@ # am--include-marker
799 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-eventloop.Po@am__quote@ # am--include-marker
800 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-export.Po@am__quote@ # am--include-marker
801 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-file-name.Po@am__quote@ # am--include-marker
802 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-genkey.Po@am__quote@ # am--include-marker
803 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-gpgconf.Po@am__quote@ # am--include-marker
804 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-import.Po@am__quote@ # am--include-marker
805 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-keylist-secret-sig.Po@am__quote@ # am--include-marker
806 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-keylist-sig.Po@am__quote@ # am--include-marker
807 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-keylist.Po@am__quote@ # am--include-marker
808 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-sig-notation.Po@am__quote@ # am--include-marker
809 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-sign.Po@am__quote@ # am--include-marker
810 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-signers.Po@am__quote@ # am--include-marker
811 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-verify.Po@am__quote@ # am--include-marker
812 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-wait.Po@am__quote@ # am--include-marker
813 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_cancel-t-cancel.Po@am__quote@ # am--include-marker
814 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_thread1-t-thread1.Po@am__quote@ # am--include-marker
815 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_thread_keylist-t-thread-keylist.Po@am__quote@ # am--include-marker
816 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Po@am__quote@ # am--include-marker
817
818 $(am__depfiles_remade):
819 @$(MKDIR_P) $(@D)
820 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
821
822 am--depfiles: $(am__depfiles_remade)
823
824 .c.o:
825 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
826 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
827 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
828 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
829 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
830
831 .c.obj:
832 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
833 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
834 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
835 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
836 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
837
838 .c.lo:
839 @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
840 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
841 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
842 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
843 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
844
845 t_cancel-t-cancel.o: t-cancel.c
846 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_cancel_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_cancel-t-cancel.o -MD -MP -MF $(DEPDIR)/t_cancel-t-cancel.Tpo -c -o t_cancel-t-cancel.o `test -f 't-cancel.c' || echo '$(srcdir)/'`t-cancel.c
847 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_cancel-t-cancel.Tpo $(DEPDIR)/t_cancel-t-cancel.Po
848 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-cancel.c' object='t_cancel-t-cancel.o' libtool=no @AMDEPBACKSLASH@
849 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
850 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_cancel_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_cancel-t-cancel.o `test -f 't-cancel.c' || echo '$(srcdir)/'`t-cancel.c
851
852 t_cancel-t-cancel.obj: t-cancel.c
853 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_cancel_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_cancel-t-cancel.obj -MD -MP -MF $(DEPDIR)/t_cancel-t-cancel.Tpo -c -o t_cancel-t-cancel.obj `if test -f 't-cancel.c'; then $(CYGPATH_W) 't-cancel.c'; else $(CYGPATH_W) '$(srcdir)/t-cancel.c'; fi`
854 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_cancel-t-cancel.Tpo $(DEPDIR)/t_cancel-t-cancel.Po
855 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-cancel.c' object='t_cancel-t-cancel.obj' libtool=no @AMDEPBACKSLASH@
856 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
857 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_cancel_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_cancel-t-cancel.obj `if test -f 't-cancel.c'; then $(CYGPATH_W) 't-cancel.c'; else $(CYGPATH_W) '$(srcdir)/t-cancel.c'; fi`
858
859 t_thread_keylist-t-thread-keylist.o: t-thread-keylist.c
860 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_thread_keylist-t-thread-keylist.o -MD -MP -MF $(DEPDIR)/t_thread_keylist-t-thread-keylist.Tpo -c -o t_thread_keylist-t-thread-keylist.o `test -f 't-thread-keylist.c' || echo '$(srcdir)/'`t-thread-keylist.c
861 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_thread_keylist-t-thread-keylist.Tpo $(DEPDIR)/t_thread_keylist-t-thread-keylist.Po
862 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-thread-keylist.c' object='t_thread_keylist-t-thread-keylist.o' libtool=no @AMDEPBACKSLASH@
863 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
864 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_thread_keylist-t-thread-keylist.o `test -f 't-thread-keylist.c' || echo '$(srcdir)/'`t-thread-keylist.c
865
866 t_thread_keylist-t-thread-keylist.obj: t-thread-keylist.c
867 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_thread_keylist-t-thread-keylist.obj -MD -MP -MF $(DEPDIR)/t_thread_keylist-t-thread-keylist.Tpo -c -o t_thread_keylist-t-thread-keylist.obj `if test -f 't-thread-keylist.c'; then $(CYGPATH_W) 't-thread-keylist.c'; else $(CYGPATH_W) '$(srcdir)/t-thread-keylist.c'; fi`
868 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_thread_keylist-t-thread-keylist.Tpo $(DEPDIR)/t_thread_keylist-t-thread-keylist.Po
869 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-thread-keylist.c' object='t_thread_keylist-t-thread-keylist.obj' libtool=no @AMDEPBACKSLASH@
870 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
871 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_thread_keylist-t-thread-keylist.obj `if test -f 't-thread-keylist.c'; then $(CYGPATH_W) 't-thread-keylist.c'; else $(CYGPATH_W) '$(srcdir)/t-thread-keylist.c'; fi`
872
873 t_thread_keylist_verify-t-thread-keylist-verify.o: t-thread-keylist-verify.c
874 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_verify_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_thread_keylist_verify-t-thread-keylist-verify.o -MD -MP -MF $(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Tpo -c -o t_thread_keylist_verify-t-thread-keylist-verify.o `test -f 't-thread-keylist-verify.c' || echo '$(srcdir)/'`t-thread-keylist-verify.c
875 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Tpo $(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Po
876 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-thread-keylist-verify.c' object='t_thread_keylist_verify-t-thread-keylist-verify.o' libtool=no @AMDEPBACKSLASH@
877 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
878 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_verify_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_thread_keylist_verify-t-thread-keylist-verify.o `test -f 't-thread-keylist-verify.c' || echo '$(srcdir)/'`t-thread-keylist-verify.c
879
880 t_thread_keylist_verify-t-thread-keylist-verify.obj: t-thread-keylist-verify.c
881 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_verify_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_thread_keylist_verify-t-thread-keylist-verify.obj -MD -MP -MF $(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Tpo -c -o t_thread_keylist_verify-t-thread-keylist-verify.obj `if test -f 't-thread-keylist-verify.c'; then $(CYGPATH_W) 't-thread-keylist-verify.c'; else $(CYGPATH_W) '$(srcdir)/t-thread-keylist-verify.c'; fi`
882 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Tpo $(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Po
883 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-thread-keylist-verify.c' object='t_thread_keylist_verify-t-thread-keylist-verify.obj' libtool=no @AMDEPBACKSLASH@
884 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
885 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread_keylist_verify_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_thread_keylist_verify-t-thread-keylist-verify.obj `if test -f 't-thread-keylist-verify.c'; then $(CYGPATH_W) 't-thread-keylist-verify.c'; else $(CYGPATH_W) '$(srcdir)/t-thread-keylist-verify.c'; fi`
886
887 t_thread1-t-thread1.o: t-thread1.c
888 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread1_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_thread1-t-thread1.o -MD -MP -MF $(DEPDIR)/t_thread1-t-thread1.Tpo -c -o t_thread1-t-thread1.o `test -f 't-thread1.c' || echo '$(srcdir)/'`t-thread1.c
889 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_thread1-t-thread1.Tpo $(DEPDIR)/t_thread1-t-thread1.Po
890 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-thread1.c' object='t_thread1-t-thread1.o' libtool=no @AMDEPBACKSLASH@
891 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
892 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread1_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_thread1-t-thread1.o `test -f 't-thread1.c' || echo '$(srcdir)/'`t-thread1.c
893
894 t_thread1-t-thread1.obj: t-thread1.c
895 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread1_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT t_thread1-t-thread1.obj -MD -MP -MF $(DEPDIR)/t_thread1-t-thread1.Tpo -c -o t_thread1-t-thread1.obj `if test -f 't-thread1.c'; then $(CYGPATH_W) 't-thread1.c'; else $(CYGPATH_W) '$(srcdir)/t-thread1.c'; fi`
896 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/t_thread1-t-thread1.Tpo $(DEPDIR)/t_thread1-t-thread1.Po
897 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t-thread1.c' object='t_thread1-t-thread1.obj' libtool=no @AMDEPBACKSLASH@
898 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
899 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(t_thread1_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o t_thread1-t-thread1.obj `if test -f 't-thread1.c'; then $(CYGPATH_W) 't-thread1.c'; else $(CYGPATH_W) '$(srcdir)/t-thread1.c'; fi`
900
901 mostlyclean-libtool:
902 -rm -f *.lo
903
904 clean-libtool:
905 -rm -rf .libs _libs
906
907 ID: $(am__tagged_files)
908 $(am__define_uniq_tagged_files); mkid -fID $$unique
909 tags: tags-am
910 TAGS: tags
911
912 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
913 set x; \
914 here=`pwd`; \
915 $(am__define_uniq_tagged_files); \
916 shift; \
917 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
918 test -n "$$unique" || unique=$$empty_fix; \
919 if test $$# -gt 0; then \
920 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
921 "$$@" $$unique; \
922 else \
923 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
924 $$unique; \
925 fi; \
926 fi
927 ctags: ctags-am
928
929 CTAGS: ctags
930 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
931 $(am__define_uniq_tagged_files); \
932 test -z "$(CTAGS_ARGS)$$unique" \
933 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
934 $$unique
935
936 GTAGS:
937 here=`$(am__cd) $(top_builddir) && pwd` \
938 && $(am__cd) $(top_srcdir) \
939 && gtags -i $(GTAGS_ARGS) "$$here"
940 cscopelist: cscopelist-am
941
942 cscopelist-am: $(am__tagged_files)
943 list='$(am__tagged_files)'; \
944 case "$(srcdir)" in \
945 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
946 *) sdir=$(subdir)/$(srcdir) ;; \
947 esac; \
948 for i in $$list; do \
949 if test -f "$$i"; then \
950 echo "$(subdir)/$$i"; \
951 else \
952 echo "$$sdir/$$i"; \
953 fi; \
954 done >> $(top_builddir)/cscope.files
955
956 distclean-tags:
957 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
958
959 check-TESTS: $(TESTS)
960 @failed=0; all=0; xfail=0; xpass=0; skip=0; \
961 srcdir=$(srcdir); export srcdir; \
962 list=' $(TESTS) '; \
963 $(am__tty_colors); \
964 if test -n "$$list"; then \
965 for tst in $$list; do \
966 if test -f ./$$tst; then dir=./; \
967 elif test -f $$tst; then dir=; \
968 else dir="$(srcdir)/"; fi; \
969 if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
970 all=`expr $$all + 1`; \
971 case " $(XFAIL_TESTS) " in \
972 *[\ \ ]$$tst[\ \ ]*) \
973 xpass=`expr $$xpass + 1`; \
974 failed=`expr $$failed + 1`; \
975 col=$$red; res=XPASS; \
976 ;; \
977 *) \
978 col=$$grn; res=PASS; \
979 ;; \
980 esac; \
981 elif test $$? -ne 77; then \
982 all=`expr $$all + 1`; \
983 case " $(XFAIL_TESTS) " in \
984 *[\ \ ]$$tst[\ \ ]*) \
985 xfail=`expr $$xfail + 1`; \
986 col=$$lgn; res=XFAIL; \
987 ;; \
988 *) \
989 failed=`expr $$failed + 1`; \
990 col=$$red; res=FAIL; \
991 ;; \
992 esac; \
993 else \
994 skip=`expr $$skip + 1`; \
995 col=$$blu; res=SKIP; \
996 fi; \
997 echo "$${col}$$res$${std}: $$tst"; \
998 done; \
999 if test "$$all" -eq 1; then \
1000 tests="test"; \
1001 All=""; \
1002 else \
1003 tests="tests"; \
1004 All="All "; \
1005 fi; \
1006 if test "$$failed" -eq 0; then \
1007 if test "$$xfail" -eq 0; then \
1008 banner="$$All$$all $$tests passed"; \
1009 else \
1010 if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
1011 banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
1012 fi; \
1013 else \
1014 if test "$$xpass" -eq 0; then \
1015 banner="$$failed of $$all $$tests failed"; \
1016 else \
1017 if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
1018 banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
1019 fi; \
1020 fi; \
1021 dashes="$$banner"; \
1022 skipped=""; \
1023 if test "$$skip" -ne 0; then \
1024 if test "$$skip" -eq 1; then \
1025 skipped="($$skip test was not run)"; \
1026 else \
1027 skipped="($$skip tests were not run)"; \
1028 fi; \
1029 test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
1030 dashes="$$skipped"; \
1031 fi; \
1032 report=""; \
1033 if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
1034 report="Please report to $(PACKAGE_BUGREPORT)"; \
1035 test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
1036 dashes="$$report"; \
1037 fi; \
1038 dashes=`echo "$$dashes" | sed s/./=/g`; \
1039 if test "$$failed" -eq 0; then \
1040 col="$$grn"; \
1041 else \
1042 col="$$red"; \
1043 fi; \
1044 echo "$${col}$$dashes$${std}"; \
1045 echo "$${col}$$banner$${std}"; \
1046 test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
1047 test -z "$$report" || echo "$${col}$$report$${std}"; \
1048 echo "$${col}$$dashes$${std}"; \
1049 test "$$failed" -eq 0; \
1050 else :; fi
1051
1052 distdir: $(BUILT_SOURCES)
1053 $(MAKE) $(AM_MAKEFLAGS) distdir-am
1054
1055 distdir-am: $(DISTFILES)
1056 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
1057 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
1058 list='$(DISTFILES)'; \
1059 dist_files=`for file in $$list; do echo $$file; done | \
1060 sed -e "s|^$$srcdirstrip/||;t" \
1061 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
1062 case $$dist_files in \
1063 */*) $(MKDIR_P) `echo "$$dist_files" | \
1064 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
1065 sort -u` ;; \
1066 esac; \
1067 for file in $$dist_files; do \
1068 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
1069 if test -d $$d/$$file; then \
1070 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
1071 if test -d "$(distdir)/$$file"; then \
1072 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
1073 fi; \
1074 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
1075 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
1076 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
1077 fi; \
1078 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
1079 else \
1080 test -f "$(distdir)/$$file" \
1081 || cp -p $$d/$$file "$(distdir)/$$file" \
1082 || exit 1; \
1083 fi; \
1084 done
1085 check-am: all-am
1086 $(MAKE) $(AM_MAKEFLAGS) check-TESTS
1087 check: $(BUILT_SOURCES)
1088 $(MAKE) $(AM_MAKEFLAGS) check-am
1089 all-am: Makefile $(PROGRAMS) $(HEADERS)
1090 installdirs:
1091 install: $(BUILT_SOURCES)
1092 $(MAKE) $(AM_MAKEFLAGS) install-am
1093 install-exec: $(BUILT_SOURCES)
1094 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
1095 install-data: install-data-am
1096 uninstall: uninstall-am
1097
1098 install-am: all-am
1099 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
1100
1101 installcheck: installcheck-am
1102 install-strip:
1103 if test -z '$(STRIP)'; then \
1104 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1105 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1106 install; \
1107 else \
1108 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
1109 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
1110 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
1111 fi
1112 mostlyclean-generic:
1113
1114 clean-generic:
1115 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
1116
1117 distclean-generic:
1118 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
1119 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
1120
1121 maintainer-clean-generic:
1122 @echo "This command is intended for maintainers to use"
1123 @echo "it deletes files that may require special tools to rebuild."
1124 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
1125 clean: clean-am
1126
1127 clean-am: clean-generic clean-libtool clean-local clean-noinstPROGRAMS \
1128 mostlyclean-am
1129
1130 distclean: distclean-am
1131 -rm -f ./$(DEPDIR)/t-decrypt-verify.Po
1132 -rm -f ./$(DEPDIR)/t-decrypt.Po
1133 -rm -f ./$(DEPDIR)/t-edit-sign.Po
1134 -rm -f ./$(DEPDIR)/t-edit.Po
1135 -rm -f ./$(DEPDIR)/t-encrypt-large.Po
1136 -rm -f ./$(DEPDIR)/t-encrypt-mixed.Po
1137 -rm -f ./$(DEPDIR)/t-encrypt-sign.Po
1138 -rm -f ./$(DEPDIR)/t-encrypt-sym.Po
1139 -rm -f ./$(DEPDIR)/t-encrypt.Po
1140 -rm -f ./$(DEPDIR)/t-eventloop.Po
1141 -rm -f ./$(DEPDIR)/t-export.Po
1142 -rm -f ./$(DEPDIR)/t-file-name.Po
1143 -rm -f ./$(DEPDIR)/t-genkey.Po
1144 -rm -f ./$(DEPDIR)/t-gpgconf.Po
1145 -rm -f ./$(DEPDIR)/t-import.Po
1146 -rm -f ./$(DEPDIR)/t-keylist-secret-sig.Po
1147 -rm -f ./$(DEPDIR)/t-keylist-sig.Po
1148 -rm -f ./$(DEPDIR)/t-keylist.Po
1149 -rm -f ./$(DEPDIR)/t-sig-notation.Po
1150 -rm -f ./$(DEPDIR)/t-sign.Po
1151 -rm -f ./$(DEPDIR)/t-signers.Po
1152 -rm -f ./$(DEPDIR)/t-verify.Po
1153 -rm -f ./$(DEPDIR)/t-wait.Po
1154 -rm -f ./$(DEPDIR)/t_cancel-t-cancel.Po
1155 -rm -f ./$(DEPDIR)/t_thread1-t-thread1.Po
1156 -rm -f ./$(DEPDIR)/t_thread_keylist-t-thread-keylist.Po
1157 -rm -f ./$(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Po
1158 -rm -f Makefile
1159 distclean-am: clean-am distclean-compile distclean-generic \
1160 distclean-tags
1161
1162 dvi: dvi-am
1163
1164 dvi-am:
1165
1166 html: html-am
1167
1168 html-am:
1169
1170 info: info-am
1171
1172 info-am:
1173
1174 install-data-am:
1175
1176 install-dvi: install-dvi-am
1177
1178 install-dvi-am:
1179
1180 install-exec-am:
1181
1182 install-html: install-html-am
1183
1184 install-html-am:
1185
1186 install-info: install-info-am
1187
1188 install-info-am:
1189
1190 install-man:
1191
1192 install-pdf: install-pdf-am
1193
1194 install-pdf-am:
1195
1196 install-ps: install-ps-am
1197
1198 install-ps-am:
1199
1200 installcheck-am:
1201
1202 maintainer-clean: maintainer-clean-am
1203 -rm -f ./$(DEPDIR)/t-decrypt-verify.Po
1204 -rm -f ./$(DEPDIR)/t-decrypt.Po
1205 -rm -f ./$(DEPDIR)/t-edit-sign.Po
1206 -rm -f ./$(DEPDIR)/t-edit.Po
1207 -rm -f ./$(DEPDIR)/t-encrypt-large.Po
1208 -rm -f ./$(DEPDIR)/t-encrypt-mixed.Po
1209 -rm -f ./$(DEPDIR)/t-encrypt-sign.Po
1210 -rm -f ./$(DEPDIR)/t-encrypt-sym.Po
1211 -rm -f ./$(DEPDIR)/t-encrypt.Po
1212 -rm -f ./$(DEPDIR)/t-eventloop.Po
1213 -rm -f ./$(DEPDIR)/t-export.Po
1214 -rm -f ./$(DEPDIR)/t-file-name.Po
1215 -rm -f ./$(DEPDIR)/t-genkey.Po
1216 -rm -f ./$(DEPDIR)/t-gpgconf.Po
1217 -rm -f ./$(DEPDIR)/t-import.Po
1218 -rm -f ./$(DEPDIR)/t-keylist-secret-sig.Po
1219 -rm -f ./$(DEPDIR)/t-keylist-sig.Po
1220 -rm -f ./$(DEPDIR)/t-keylist.Po
1221 -rm -f ./$(DEPDIR)/t-sig-notation.Po
1222 -rm -f ./$(DEPDIR)/t-sign.Po
1223 -rm -f ./$(DEPDIR)/t-signers.Po
1224 -rm -f ./$(DEPDIR)/t-verify.Po
1225 -rm -f ./$(DEPDIR)/t-wait.Po
1226 -rm -f ./$(DEPDIR)/t_cancel-t-cancel.Po
1227 -rm -f ./$(DEPDIR)/t_thread1-t-thread1.Po
1228 -rm -f ./$(DEPDIR)/t_thread_keylist-t-thread-keylist.Po
1229 -rm -f ./$(DEPDIR)/t_thread_keylist_verify-t-thread-keylist-verify.Po
1230 -rm -f Makefile
1231 maintainer-clean-am: distclean-am maintainer-clean-generic
1232
1233 mostlyclean: mostlyclean-am
1234
1235 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
1236 mostlyclean-libtool
1237
1238 pdf: pdf-am
1239
1240 pdf-am:
1241
1242 ps: ps-am
1243
1244 ps-am:
1245
1246 uninstall-am:
1247
1248 .MAKE: all check check-am install install-am install-exec \
1249 install-strip
1250
1251 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \
1252 check-am clean clean-generic clean-libtool clean-local \
1253 clean-noinstPROGRAMS cscopelist-am ctags ctags-am distclean \
1254 distclean-compile distclean-generic distclean-libtool \
1255 distclean-tags distdir dvi dvi-am html html-am info info-am \
1256 install install-am install-data install-data-am install-dvi \
1257 install-dvi-am install-exec install-exec-am install-html \
1258 install-html-am install-info install-info-am install-man \
1259 install-pdf install-pdf-am install-ps install-ps-am \
1260 install-strip installcheck installcheck-am installdirs \
1261 maintainer-clean maintainer-clean-generic mostlyclean \
1262 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
1263 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am
1264
1265 .PRECIOUS: Makefile
1266
1267
1268 clean-local:
1269 -$(TESTS_ENVIRONMENT) $(top_srcdir)/tests/start-stop-agent --stop
1270 -rm -fR private-keys-v1.d
1271
1272 gpg-sample.stamp: $(srcdir)/$(private_keys)
1273 -$(TESTS_ENVIRONMENT) gpgconf --kill all
1274 $(MKDIR_P) ./private-keys-v1.d
1275 for k in $(private_keys); do \
1276 cp $(srcdir)/$$k private-keys-v1.d/$$k.key; \
1277 done
1278 echo x > ./gpg-sample.stamp
1279
1280 pubring-stamp: $(srcdir)/pubdemo.asc gpg-sample.stamp
1281 $(TESTS_ENVIRONMENT) $(GPG) --batch --no-permission-warning \
1282 --import $(srcdir)/pubdemo.asc
1283 -$(TESTS_ENVIRONMENT) $(GPG) --batch --no-permission-warning \
1284 --import $(srcdir)/secdemo.asc
1285 echo x > ./pubring-stamp
1286
1287 gpg.conf: $(srcdir)/gpg.conf.in
1288 cp $(srcdir)/gpg.conf.in gpg.conf
1289
1290 gpg-agent.conf:
1291 # This is required for gpg2, which does not support command fd for the
1292 # passphrase. disable-scdaemon is required so that we don't try using
1293 # a key from a smartcard reader (error might be: Unusable secret key)
1294 echo pinentry-program $(abs_srcdir)/pinentry > ./gpg-agent.conf
1295 echo disable-scdaemon >> ./gpg-agent.conf
1296
1297 # end-of-file
1298
1299 # Tell versions [3.59,3.63) of GNU make to not export all variables.
1300 # Otherwise a system limit (for SysV at least) may be exceeded.
1301 .NOEXPORT:
0 # This is required for t-sig-notations.
1 no-force-v3-sigs
2
3 # This is required for t-edit-sign.
4 allow-weak-key-signatures
3737 #include <sys/types.h>
3838 #include <unistd.h>
3939 #include <pthread.h>
40 #ifdef HAVE_SYS_SELECT_H
41 # include <sys/select.h>
40 #ifdef HAVE_POLL_H
41 # include <poll.h>
42 #else
43 # ifdef HAVE_SYS_SELECT_H
44 # include <sys/select.h>
45 # else
46 # ifdef HAVE_SYS_TIME_H
47 # include <sys/time.h>
48 # endif
49 # endif
4250 #endif
4351
4452 #include <gpgme.h>
115123 }
116124
117125
126 #ifdef HAVE_POLL_H
127 static int
128 do_select (void)
129 {
130 struct pollfd poll_fds[FDLIST_MAX];
131 nfds_t poll_nfds;
132 int i, n;
133 int any = 0;
134
135 pthread_mutex_lock (&lock);
136 poll_nfds = 0;
137 for (i = 0; i < FDLIST_MAX; i++)
138 if (fdlist[i].fd != -1)
139 {
140 poll_fds[poll_nfds].fd = fdlist[i].fd;
141 poll_fds[poll_nfds].events = 0;
142 poll_fds[poll_nfds].revents = 0;
143 if (fdlist[i].dir)
144 poll_fds[poll_nfds].events |= POLLIN;
145 else
146 poll_fds[poll_nfds].events |= POLLOUT;
147 poll_nfds++;
148 }
149 pthread_mutex_unlock (&lock);
150
151 do
152 {
153 n = poll (poll_fds, poll_nfds, 1000);
154 }
155 while (n < 0 && (errno == EINTR || errno == EAGAIN));
156
157 if (n < 0)
158 return n; /* Error or timeout. */
159
160 pthread_mutex_lock (&lock);
161 poll_nfds = 0;
162 for (i = 0; i < FDLIST_MAX && n; i++)
163 {
164 if (fdlist[i].fd != -1)
165 {
166 if ((poll_fds[poll_nfds++].revents
167 & (fdlist[i].dir ? (POLLIN|POLLHUP) : POLLOUT)))
168 {
169 assert (n);
170 n--;
171 any = 1;
172 (*fdlist[i].fnc) (fdlist[i].fnc_data, fdlist[i].fd);
173 }
174 }
175 }
176 pthread_mutex_unlock (&lock);
177 return any;
178 }
179 #else
118180 static int
119181 do_select (void)
120182 {
161223 pthread_mutex_unlock (&lock);
162224 return any;
163225 }
226 #endif
164227
165228 static int
166229 my_wait (void)
106106 }
107107
108108
109 int
110 main (int argc, char **argv)
109 void
110 sign_key (const char *key_fpr, const char *signer_fpr)
111111 {
112112 gpgme_ctx_t ctx;
113113 gpgme_error_t err;
114114 gpgme_data_t out = NULL;
115 const char *signer_fpr = "A0FF4590BB6122EDEF6E3C542D727CC768697734"; /* Alpha Test */
116115 gpgme_key_t signing_key = NULL;
117 const char *key_fpr = "D695676BDCEDCC2CDD6152BCFE180B1DA9E3B0B2"; /* Bravo Test */
118116 gpgme_key_t key = NULL;
117 char *agent_info;
118
119 err = gpgme_new (&ctx);
120 fail_if_err (err);
121
122 agent_info = getenv("GPG_AGENT_INFO");
123 if (!(agent_info && strchr (agent_info, ':')))
124 gpgme_set_passphrase_cb (ctx, passphrase_cb, 0);
125
126 err = gpgme_get_key (ctx, signer_fpr, &signing_key, 1);
127 fail_if_err (err);
128 err = gpgme_signers_add (ctx, signing_key);
129 fail_if_err (err);
130
131 err = gpgme_set_ctx_flag (ctx, "cert-expire", "42d");
132 fail_if_err (err);
133
134 err = gpgme_get_key (ctx, key_fpr, &key, 0);
135 fail_if_err (err);
136
137 err = gpgme_data_new (&out);
138 fail_if_err (err);
139
140 err = gpgme_op_interact (ctx, key, 0, interact_fnc, out, out);
141 fail_if_err (err);
142
143 fputs ("[-- Last response --]\n", stdout);
144 flush_data (out);
145
146 gpgme_data_release (out);
147 gpgme_key_unref (key);
148 gpgme_key_unref (signing_key);
149 gpgme_release (ctx);
150 }
151
152
153 void
154 verify_key_signature (const char *key_fpr, const char *signer_keyid)
155 {
156 gpgme_ctx_t ctx;
157 gpgme_error_t err;
119158 gpgme_key_t signed_key = NULL;
120159 gpgme_user_id_t signed_uid = NULL;
121160 gpgme_key_sig_t key_sig = NULL;
122 char *agent_info;
123161 int mode;
124162
125 (void)argc;
126 (void)argv;
127
128 init_gpgme (GPGME_PROTOCOL_OpenPGP);
129
130163 err = gpgme_new (&ctx);
131164 fail_if_err (err);
132165
133 /* Sign the key */
134 agent_info = getenv("GPG_AGENT_INFO");
135 if (!(agent_info && strchr (agent_info, ':')))
136 gpgme_set_passphrase_cb (ctx, passphrase_cb, 0);
137
138 err = gpgme_get_key (ctx, signer_fpr, &signing_key, 1);
139 fail_if_err (err);
140 err = gpgme_signers_add (ctx, signing_key);
141 fail_if_err (err);
142
143 err = gpgme_set_ctx_flag (ctx, "cert-expire", "42d");
144 fail_if_err (err);
145
146 err = gpgme_get_key (ctx, key_fpr, &key, 0);
147 fail_if_err (err);
148
149 err = gpgme_data_new (&out);
150 fail_if_err (err);
151
152 err = gpgme_op_interact (ctx, key, 0, interact_fnc, out, out);
153 fail_if_err (err);
154
155 fputs ("[-- Last response --]\n", stdout);
156 flush_data (out);
157
158 gpgme_data_release (out);
159 gpgme_key_unref (key);
160 gpgme_key_unref (signing_key);
161
162 /* Verify the key signature */
163166 mode = gpgme_get_keylist_mode (ctx);
164167 mode |= GPGME_KEYLIST_MODE_SIGS;
165168 err = gpgme_set_keylist_mode (ctx, mode);
167170 err = gpgme_get_key (ctx, key_fpr, &signed_key, 0);
168171 fail_if_err (err);
169172
170 signed_uid = key->uids;
173 signed_uid = signed_key->uids;
171174 if (!signed_uid)
172175 {
173176 fprintf (stderr, "Signed key has no user IDs\n");
179182 exit (1);
180183 }
181184 key_sig = signed_uid->signatures->next;
182 if (strcmp ("2D727CC768697734", key_sig->keyid))
185 if (strcmp (signer_keyid, key_sig->keyid))
183186 {
184187 fprintf (stderr, "Unexpected key ID in second user ID sig: %s\n",
185188 key_sig->keyid);
195198
196199 gpgme_key_unref (signed_key);
197200 gpgme_release (ctx);
201 }
202
203
204 int
205 main (int argc, char **argv)
206 {
207 const char *signer_fpr = "A0FF4590BB6122EDEF6E3C542D727CC768697734"; /* Alpha Test */
208 const char *signer_keyid = signer_fpr + strlen(signer_fpr) - 16;
209 const char *key_fpr = "D695676BDCEDCC2CDD6152BCFE180B1DA9E3B0B2"; /* Bravo Test */
210
211 (void)argc;
212 (void)argv;
213
214 init_gpgme (GPGME_PROTOCOL_OpenPGP);
215
216 sign_key (key_fpr, signer_fpr);
217 verify_key_signature (key_fpr, signer_keyid);
198218
199219 return 0;
200220 }
3030 #include <assert.h>
3131 #include <errno.h>
3232 #include <sys/types.h>
33 #include <sys/select.h>
33 #ifdef HAVE_POLL_H
34 # include <poll.h>
35 #else
36 # ifdef HAVE_SYS_SELECT_H
37 # include <sys/select.h>
38 # else
39 # ifdef HAVE_SYS_TIME_H
40 # include <sys/time.h>
41 # endif
42 # endif
43 #endif
3444
3545 #include <gpgme.h>
3646
103113 }
104114
105115
116 #ifdef HAVE_POLL_H
117 int
118 do_select (void)
119 {
120 struct pollfd poll_fds[FDLIST_MAX];
121 nfds_t poll_nfds;
122 int i, n;
123 int any = 0;
124
125 poll_nfds = 0;
126 for (i = 0; i < FDLIST_MAX; i++)
127 if (fdlist[i].fd != -1)
128 {
129 poll_fds[poll_nfds].fd = fdlist[i].fd;
130 poll_fds[poll_nfds].events = 0;
131 poll_fds[poll_nfds].revents = 0;
132 if (fdlist[i].dir)
133 poll_fds[poll_nfds].events |= POLLIN;
134 else
135 poll_fds[poll_nfds].events |= POLLOUT;
136 poll_nfds++;
137 }
138
139 do
140 {
141 n = poll (poll_fds, poll_nfds, 1000);
142 }
143 while (n < 0 && (errno == EINTR || errno == EAGAIN));
144
145 if (n < 0)
146 return n; /* Error or timeout. */
147
148 poll_nfds = 0;
149 for (i = 0; i < FDLIST_MAX && n; i++)
150 {
151 if (fdlist[i].fd != -1)
152 {
153 if ((poll_fds[poll_nfds++].revents
154 & (fdlist[i].dir ? (POLLIN|POLLHUP) : POLLOUT)))
155 {
156 assert (n);
157 n--;
158 any = 1;
159 (*fdlist[i].fnc) (fdlist[i].fnc_data, fdlist[i].fd);
160 }
161 }
162 }
163 return any;
164 }
165 #else
106166 int
107167 do_select (void)
108168 {
145205 }
146206 return any;
147207 }
208 #endif
148209
149210 int
150211 my_wait (void)
148148 exit (1);
149149 }
150150 }
151 if (strcmp (fpr, result->imports->fpr))
151 if (!result->imports->fpr || strcmp (fpr, result->imports->fpr))
152152 {
153153 fprintf (stderr, "Unexpected fingerprint %s\n",
154 result->imports->fpr);
155 exit (1);
156 }
157 if (result->imports->next && strcmp (fpr, result->imports->next->fpr))
154 result->imports->fpr ? result->imports->fpr : "null");
155 exit (1);
156 }
157 if (result->imports->next
158 && (!result->imports->next->fpr || strcmp (fpr, result->imports->next->fpr)))
158159 {
159160 fprintf (stderr, "Unexpected fingerprint on second status %s\n",
160 result->imports->next->fpr);
161 result->imports->next->fpr ? result->imports->next->fpr : "null");
161162 exit (1);
162163 }
163164 if (result->imports->result != 0)
213214 gpgme_error_t err;
214215 gpgme_data_t in;
215216 gpgme_import_result_t result;
217 gpgme_key_t key;
216218 char *pubkey_1_asc = make_filename ("pubkey-1.asc");
217219 char *seckey_1_asc = make_filename ("seckey-1.asc");
218220
222224 init_gpgme (GPGME_PROTOCOL_OpenPGP);
223225
224226 err = gpgme_new (&ctx);
227 fail_if_err (err);
228
229 err = gpgme_set_ctx_flag (ctx, "key-origin", "wkd,https://openpgpkey.gnupg.org");
225230 fail_if_err (err);
226231
227232 err = gpgme_data_new_from_file (&in, pubkey_1_asc, 1);
245250 gpgme_data_release (in);
246251
247252 gpgme_release (ctx);
253
254 err = gpgme_new (&ctx);
255 fail_if_err (err);
256
257 err = gpgme_get_key (ctx, "0xADAB7FCC1F4DE2616ECFA402AF82244F9CD9FD55", &key, 0);
258 fail_if_err (err);
259
260 if (!key)
261 {
262 fprintf (stderr, "Imported key not found\n");
263 exit (1);
264 }
265 if (key->origin != GPGME_KEYORG_WKD)
266 {
267 fprintf (stderr, "Key has unexpected origin: %d\n", key->origin);
268 exit (1);
269 }
270
271
248272 return 0;
249273 }
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Copyright (C) 2000 Werner Koch (dd9jn)
17 # Copyright (C) 2001 g10 Code GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34
35
36 VPATH = @srcdir@
37 am__is_gnu_make = { \
38 if test -z '$(MAKELEVEL)'; then \
39 false; \
40 elif test -n '$(MAKE_HOST)'; then \
41 true; \
42 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
43 true; \
44 else \
45 false; \
46 fi; \
47 }
48 am__make_running_with_option = \
49 case $${target_option-} in \
50 ?) ;; \
51 *) echo "am__make_running_with_option: internal error: invalid" \
52 "target option '$${target_option-}' specified" >&2; \
53 exit 1;; \
54 esac; \
55 has_opt=no; \
56 sane_makeflags=$$MAKEFLAGS; \
57 if $(am__is_gnu_make); then \
58 sane_makeflags=$$MFLAGS; \
59 else \
60 case $$MAKEFLAGS in \
61 *\\[\ \ ]*) \
62 bs=\\; \
63 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
64 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
65 esac; \
66 fi; \
67 skip_next=no; \
68 strip_trailopt () \
69 { \
70 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
71 }; \
72 for flg in $$sane_makeflags; do \
73 test $$skip_next = yes && { skip_next=no; continue; }; \
74 case $$flg in \
75 *=*|--*) continue;; \
76 -*I) strip_trailopt 'I'; skip_next=yes;; \
77 -*I?*) strip_trailopt 'I';; \
78 -*O) strip_trailopt 'O'; skip_next=yes;; \
79 -*O?*) strip_trailopt 'O';; \
80 -*l) strip_trailopt 'l'; skip_next=yes;; \
81 -*l?*) strip_trailopt 'l';; \
82 -[dEDm]) skip_next=yes;; \
83 -[JT]) skip_next=yes;; \
84 esac; \
85 case $$flg in \
86 *$$target_option*) has_opt=yes; break;; \
87 esac; \
88 done; \
89 test $$has_opt = yes
90 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
91 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
92 pkgdatadir = $(datadir)/@PACKAGE@
93 pkgincludedir = $(includedir)/@PACKAGE@
94 pkglibdir = $(libdir)/@PACKAGE@
95 pkglibexecdir = $(libexecdir)/@PACKAGE@
96 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
97 install_sh_DATA = $(install_sh) -c -m 644
98 install_sh_PROGRAM = $(install_sh) -c
99 install_sh_SCRIPT = $(install_sh) -c
100 INSTALL_HEADER = $(INSTALL_DATA)
101 transform = $(program_transform_name)
102 NORMAL_INSTALL = :
103 PRE_INSTALL = :
104 POST_INSTALL = :
105 NORMAL_UNINSTALL = :
106 PRE_UNINSTALL = :
107 POST_UNINSTALL = :
108 build_triplet = @build@
109 host_triplet = @host@
110 TESTS = initial.test $(am__EXEEXT_1) final.test
111 noinst_PROGRAMS = $(am__EXEEXT_1) t-genkey$(EXEEXT) \
112 cms-keylist$(EXEEXT) cms-decrypt$(EXEEXT)
113 subdir = tests/gpgsm
114 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
115 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
116 $(top_srcdir)/m4/ax_pkg_swig.m4 \
117 $(top_srcdir)/m4/ax_python_devel.m4 \
118 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
119 $(top_srcdir)/m4/gnupg-ttyname.m4 \
120 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
121 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
122 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
123 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
124 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
125 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
126 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
127 $(ACLOCAL_M4)
128 DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \
129 $(am__DIST_COMMON)
130 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
131 CONFIG_HEADER = $(top_builddir)/conf/config.h
132 CONFIG_CLEAN_FILES =
133 CONFIG_CLEAN_VPATH_FILES =
134 am__EXEEXT_1 = t-import$(EXEEXT) t-keylist$(EXEEXT) t-encrypt$(EXEEXT) \
135 t-verify$(EXEEXT) t-decrypt$(EXEEXT) t-sign$(EXEEXT) \
136 t-export$(EXEEXT)
137 PROGRAMS = $(noinst_PROGRAMS)
138 cms_decrypt_SOURCES = cms-decrypt.c
139 cms_decrypt_OBJECTS = cms-decrypt.$(OBJEXT)
140 cms_decrypt_LDADD = $(LDADD)
141 cms_decrypt_DEPENDENCIES = ../../src/libgpgme.la
142 AM_V_lt = $(am__v_lt_@AM_V@)
143 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
144 am__v_lt_0 = --silent
145 am__v_lt_1 =
146 cms_keylist_SOURCES = cms-keylist.c
147 cms_keylist_OBJECTS = cms-keylist.$(OBJEXT)
148 cms_keylist_LDADD = $(LDADD)
149 cms_keylist_DEPENDENCIES = ../../src/libgpgme.la
150 t_decrypt_SOURCES = t-decrypt.c
151 t_decrypt_OBJECTS = t-decrypt.$(OBJEXT)
152 t_decrypt_LDADD = $(LDADD)
153 t_decrypt_DEPENDENCIES = ../../src/libgpgme.la
154 t_encrypt_SOURCES = t-encrypt.c
155 t_encrypt_OBJECTS = t-encrypt.$(OBJEXT)
156 t_encrypt_LDADD = $(LDADD)
157 t_encrypt_DEPENDENCIES = ../../src/libgpgme.la
158 t_export_SOURCES = t-export.c
159 t_export_OBJECTS = t-export.$(OBJEXT)
160 t_export_LDADD = $(LDADD)
161 t_export_DEPENDENCIES = ../../src/libgpgme.la
162 t_genkey_SOURCES = t-genkey.c
163 t_genkey_OBJECTS = t-genkey.$(OBJEXT)
164 t_genkey_LDADD = $(LDADD)
165 t_genkey_DEPENDENCIES = ../../src/libgpgme.la
166 t_import_SOURCES = t-import.c
167 t_import_OBJECTS = t-import.$(OBJEXT)
168 t_import_LDADD = $(LDADD)
169 t_import_DEPENDENCIES = ../../src/libgpgme.la
170 t_keylist_SOURCES = t-keylist.c
171 t_keylist_OBJECTS = t-keylist.$(OBJEXT)
172 t_keylist_LDADD = $(LDADD)
173 t_keylist_DEPENDENCIES = ../../src/libgpgme.la
174 t_sign_SOURCES = t-sign.c
175 t_sign_OBJECTS = t-sign.$(OBJEXT)
176 t_sign_LDADD = $(LDADD)
177 t_sign_DEPENDENCIES = ../../src/libgpgme.la
178 t_verify_SOURCES = t-verify.c
179 t_verify_OBJECTS = t-verify.$(OBJEXT)
180 t_verify_LDADD = $(LDADD)
181 t_verify_DEPENDENCIES = ../../src/libgpgme.la
182 AM_V_P = $(am__v_P_@AM_V@)
183 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
184 am__v_P_0 = false
185 am__v_P_1 = :
186 AM_V_GEN = $(am__v_GEN_@AM_V@)
187 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
188 am__v_GEN_0 = @echo " GEN " $@;
189 am__v_GEN_1 =
190 AM_V_at = $(am__v_at_@AM_V@)
191 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
192 am__v_at_0 = @
193 am__v_at_1 =
194 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
195 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
196 am__maybe_remake_depfiles = depfiles
197 am__depfiles_remade = ./$(DEPDIR)/cms-decrypt.Po \
198 ./$(DEPDIR)/cms-keylist.Po ./$(DEPDIR)/t-decrypt.Po \
199 ./$(DEPDIR)/t-encrypt.Po ./$(DEPDIR)/t-export.Po \
200 ./$(DEPDIR)/t-genkey.Po ./$(DEPDIR)/t-import.Po \
201 ./$(DEPDIR)/t-keylist.Po ./$(DEPDIR)/t-sign.Po \
202 ./$(DEPDIR)/t-verify.Po
203 am__mv = mv -f
204 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
205 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
206 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
207 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
208 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
209 $(AM_CFLAGS) $(CFLAGS)
210 AM_V_CC = $(am__v_CC_@AM_V@)
211 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
212 am__v_CC_0 = @echo " CC " $@;
213 am__v_CC_1 =
214 CCLD = $(CC)
215 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
216 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
217 $(AM_LDFLAGS) $(LDFLAGS) -o $@
218 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
219 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
220 am__v_CCLD_0 = @echo " CCLD " $@;
221 am__v_CCLD_1 =
222 SOURCES = cms-decrypt.c cms-keylist.c t-decrypt.c t-encrypt.c \
223 t-export.c t-genkey.c t-import.c t-keylist.c t-sign.c \
224 t-verify.c
225 DIST_SOURCES = cms-decrypt.c cms-keylist.c t-decrypt.c t-encrypt.c \
226 t-export.c t-genkey.c t-import.c t-keylist.c t-sign.c \
227 t-verify.c
228 am__can_run_installinfo = \
229 case $$AM_UPDATE_INFO_DIR in \
230 n|no|NO) false;; \
231 *) (install-info --version) >/dev/null 2>&1;; \
232 esac
233 HEADERS = $(noinst_HEADERS)
234 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
235 # Read a list of newline-separated strings from the standard input,
236 # and print each of them once, without duplicates. Input order is
237 # *not* preserved.
238 am__uniquify_input = $(AWK) '\
239 BEGIN { nonempty = 0; } \
240 { items[$$0] = 1; nonempty = 1; } \
241 END { if (nonempty) { for (i in items) print i; }; } \
242 '
243 # Make sure the list of sources is unique. This is necessary because,
244 # e.g., the same source file might be shared among _SOURCES variables
245 # for different programs/libraries.
246 am__define_uniq_tagged_files = \
247 list='$(am__tagged_files)'; \
248 unique=`for i in $$list; do \
249 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
250 done | $(am__uniquify_input)`
251 ETAGS = etags
252 CTAGS = ctags
253 am__tty_colors_dummy = \
254 mgn= red= grn= lgn= blu= brg= std=; \
255 am__color_tests=no
256 am__tty_colors = { \
257 $(am__tty_colors_dummy); \
258 if test "X$(AM_COLOR_TESTS)" = Xno; then \
259 am__color_tests=no; \
260 elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
261 am__color_tests=yes; \
262 elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
263 am__color_tests=yes; \
264 fi; \
265 if test $$am__color_tests = yes; then \
266 red=''; \
267 grn=''; \
268 lgn=''; \
269 blu=''; \
270 mgn=''; \
271 brg=''; \
272 std=''; \
273 fi; \
274 }
275 am__DIST_COMMON = $(srcdir)/Makefile.in \
276 $(top_srcdir)/build-aux/depcomp \
277 $(top_srcdir)/build-aux/mkinstalldirs
278 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
279 ACLOCAL = @ACLOCAL@
280 AMTAR = @AMTAR@
281 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
282 AR = @AR@
283 AS = @AS@
284 AUTOCONF = @AUTOCONF@
285 AUTOHEADER = @AUTOHEADER@
286 AUTOMAKE = @AUTOMAKE@
287 AWK = @AWK@
288 BUILD_FILEVERSION = @BUILD_FILEVERSION@
289 BUILD_REVISION = @BUILD_REVISION@
290 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
291 BUILD_VERSION = @BUILD_VERSION@
292 CC = @CC@
293 CCDEPMODE = @CCDEPMODE@
294 CC_FOR_BUILD = @CC_FOR_BUILD@
295 CFLAGS = @CFLAGS@
296 CPP = @CPP@
297 CPPFLAGS = @CPPFLAGS@
298 CXX = @CXX@
299 CXXCPP = @CXXCPP@
300 CXXDEPMODE = @CXXDEPMODE@
301 CXXFLAGS = @CXXFLAGS@
302 CYGPATH_W = @CYGPATH_W@
303 DEFS = @DEFS@
304 DEPDIR = @DEPDIR@
305 DLLTOOL = @DLLTOOL@
306 DOXYGEN = @DOXYGEN@
307 DSYMUTIL = @DSYMUTIL@
308 DUMPBIN = @DUMPBIN@
309 ECHO_C = @ECHO_C@
310 ECHO_N = @ECHO_N@
311 ECHO_T = @ECHO_T@
312 EGREP = @EGREP@
313 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
314 EXEEXT = @EXEEXT@
315 FGREP = @FGREP@
316 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
317 GLIBC21 = @GLIBC21@
318 GLIB_CFLAGS = @GLIB_CFLAGS@
319 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
320 GLIB_LIBS = @GLIB_LIBS@
321 GLIB_MKENUMS = @GLIB_MKENUMS@
322 GOBJECT_QUERY = @GOBJECT_QUERY@
323 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
324 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
325 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
326 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
327 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
328 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
329 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
330 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
331 GPGME_QT_LIBS = @GPGME_QT_LIBS@
332 GPGRT_CONFIG = @GPGRT_CONFIG@
333 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
334 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
335 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
336 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
337 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
338 GRAPHVIZ = @GRAPHVIZ@
339 GREP = @GREP@
340 HAVE_CXX11 = @HAVE_CXX11@
341 HAVE_DOT = @HAVE_DOT@
342 INSTALL = @INSTALL@
343 INSTALL_DATA = @INSTALL_DATA@
344 INSTALL_PROGRAM = @INSTALL_PROGRAM@
345 INSTALL_SCRIPT = @INSTALL_SCRIPT@
346 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
347 LD = @LD@
348 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
349 LDFLAGS = @LDFLAGS@
350 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
351 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
352 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
353 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
354 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
355 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
356 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
357 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
358 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
359 LIBOBJS = @LIBOBJS@
360 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
361 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
362 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
363 LIBS = @LIBS@
364 LIBTOOL = @LIBTOOL@
365 LIPO = @LIPO@
366 LN_S = @LN_S@
367 LTLIBOBJS = @LTLIBOBJS@
368 MAINT = @MAINT@
369 MAKEINFO = @MAKEINFO@
370 MANIFEST_TOOL = @MANIFEST_TOOL@
371 MKDIR_P = @MKDIR_P@
372 MOC = @MOC@
373 MOC2 = @MOC2@
374 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
375 NM = @NM@
376 NMEDIT = @NMEDIT@
377 OBJDUMP = @OBJDUMP@
378 OBJEXT = @OBJEXT@
379 OTOOL = @OTOOL@
380 OTOOL64 = @OTOOL64@
381 PACKAGE = @PACKAGE@
382 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
383 PACKAGE_NAME = @PACKAGE_NAME@
384 PACKAGE_STRING = @PACKAGE_STRING@
385 PACKAGE_TARNAME = @PACKAGE_TARNAME@
386 PACKAGE_URL = @PACKAGE_URL@
387 PACKAGE_VERSION = @PACKAGE_VERSION@
388 PATH_SEPARATOR = @PATH_SEPARATOR@
389 PKG_CONFIG = @PKG_CONFIG@
390 PYTHON = @PYTHON@
391 PYTHONS = @PYTHONS@
392 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
393 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
394 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
395 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
396 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
397 PYTHON_PLATFORM = @PYTHON_PLATFORM@
398 PYTHON_PREFIX = @PYTHON_PREFIX@
399 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
400 PYTHON_VERSION = @PYTHON_VERSION@
401 QTCHOOSER = @QTCHOOSER@
402 RANLIB = @RANLIB@
403 RC = @RC@
404 SED = @SED@
405 SET_MAKE = @SET_MAKE@
406 SHELL = @SHELL@
407 STRIP = @STRIP@
408 SWIG = @SWIG@
409 SWIG_LIB = @SWIG_LIB@
410 SYSROOT = @SYSROOT@
411 VERSION = @VERSION@
412 VERSION_MAJOR = @VERSION_MAJOR@
413 VERSION_MICRO = @VERSION_MICRO@
414 VERSION_MINOR = @VERSION_MINOR@
415 VERSION_NUMBER = @VERSION_NUMBER@
416 abs_builddir = @abs_builddir@
417 abs_srcdir = @abs_srcdir@
418 abs_top_builddir = @abs_top_builddir@
419 abs_top_srcdir = @abs_top_srcdir@
420 ac_ct_AR = @ac_ct_AR@
421 ac_ct_CC = @ac_ct_CC@
422 ac_ct_CXX = @ac_ct_CXX@
423 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
424 am__include = @am__include@
425 am__leading_dot = @am__leading_dot@
426 am__quote = @am__quote@
427 am__tar = @am__tar@
428 am__untar = @am__untar@
429 bindir = @bindir@
430 build = @build@
431 build_alias = @build_alias@
432 build_cpu = @build_cpu@
433 build_os = @build_os@
434 build_vendor = @build_vendor@
435 builddir = @builddir@
436 datadir = @datadir@
437 datarootdir = @datarootdir@
438 docdir = @docdir@
439 dvidir = @dvidir@
440 emacs_local_vars_begin = @emacs_local_vars_begin@
441 emacs_local_vars_end = @emacs_local_vars_end@
442 emacs_local_vars_read_only = @emacs_local_vars_read_only@
443 exec_prefix = @exec_prefix@
444 host = @host@
445 host_alias = @host_alias@
446 host_cpu = @host_cpu@
447 host_os = @host_os@
448 host_vendor = @host_vendor@
449 htmldir = @htmldir@
450 includedir = @includedir@
451 infodir = @infodir@
452 install_sh = @install_sh@
453 libdir = @libdir@
454 libexecdir = @libexecdir@
455 localedir = @localedir@
456 localstatedir = @localstatedir@
457 mandir = @mandir@
458 mkdir_p = @mkdir_p@
459 oldincludedir = @oldincludedir@
460 pdfdir = @pdfdir@
461 pkgpyexecdir = @pkgpyexecdir@
462 pkgpythondir = @pkgpythondir@
463 prefix = @prefix@
464 program_transform_name = @program_transform_name@
465 psdir = @psdir@
466 pyexecdir = @pyexecdir@
467 pythondir = @pythondir@
468 runstatedir = @runstatedir@
469 sbindir = @sbindir@
470 sharedstatedir = @sharedstatedir@
471 srcdir = @srcdir@
472 sysconfdir = @sysconfdir@
473 target_alias = @target_alias@
474 top_build_prefix = @top_build_prefix@
475 top_builddir = @top_builddir@
476 top_srcdir = @top_srcdir@
477 GPGSM = gpgsm
478 GPG_AGENT = gpg-agent
479 GNUPGHOME = $(abs_builddir)
480 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME) LC_ALL=C GPG_AGENT_INFO= \
481 top_srcdir=$(top_srcdir)
482
483 noinst_HEADERS = t-support.h
484 c_tests = t-import t-keylist t-encrypt t-verify t-decrypt t-sign t-export
485 EXTRA_DIST = cert_dfn_pca01.der cert_dfn_pca15.der cert_g10code_test1.der \
486 $(key_id) initial.test final.test
487
488 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
489 AM_LDFLAGS = -no-install
490 LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
491 key_id = 32100C27173EF6E9C4E9A25D3D69F86D37A4F939
492 CLEANFILES = pubring-stamp pubring.kbx pubring.kbx~ gpgsm.conf trustlist.txt \
493 random_seed S.gpg-agent gpg-sample.stamp
494
495 BUILT_SOURCES = gpgsm.conf trustlist.txt pubring-stamp \
496 gpg-sample.stamp
497
498 all: $(BUILT_SOURCES)
499 $(MAKE) $(AM_MAKEFLAGS) all-am
500
501 .SUFFIXES:
502 .SUFFIXES: .c .lo .o .obj
503 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
504 @for dep in $?; do \
505 case '$(am__configure_deps)' in \
506 *$$dep*) \
507 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
508 && { if test -f $@; then exit 0; else break; fi; }; \
509 exit 1;; \
510 esac; \
511 done; \
512 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/gpgsm/Makefile'; \
513 $(am__cd) $(top_srcdir) && \
514 $(AUTOMAKE) --gnu tests/gpgsm/Makefile
515 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
516 @case '$?' in \
517 *config.status*) \
518 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
519 *) \
520 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
521 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
522 esac;
523
524 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
525 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
526
527 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
528 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
529 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
530 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
531 $(am__aclocal_m4_deps):
532
533 clean-noinstPROGRAMS:
534 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
535 echo " rm -f" $$list; \
536 rm -f $$list || exit $$?; \
537 test -n "$(EXEEXT)" || exit 0; \
538 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
539 echo " rm -f" $$list; \
540 rm -f $$list
541
542 cms-decrypt$(EXEEXT): $(cms_decrypt_OBJECTS) $(cms_decrypt_DEPENDENCIES) $(EXTRA_cms_decrypt_DEPENDENCIES)
543 @rm -f cms-decrypt$(EXEEXT)
544 $(AM_V_CCLD)$(LINK) $(cms_decrypt_OBJECTS) $(cms_decrypt_LDADD) $(LIBS)
545
546 cms-keylist$(EXEEXT): $(cms_keylist_OBJECTS) $(cms_keylist_DEPENDENCIES) $(EXTRA_cms_keylist_DEPENDENCIES)
547 @rm -f cms-keylist$(EXEEXT)
548 $(AM_V_CCLD)$(LINK) $(cms_keylist_OBJECTS) $(cms_keylist_LDADD) $(LIBS)
549
550 t-decrypt$(EXEEXT): $(t_decrypt_OBJECTS) $(t_decrypt_DEPENDENCIES) $(EXTRA_t_decrypt_DEPENDENCIES)
551 @rm -f t-decrypt$(EXEEXT)
552 $(AM_V_CCLD)$(LINK) $(t_decrypt_OBJECTS) $(t_decrypt_LDADD) $(LIBS)
553
554 t-encrypt$(EXEEXT): $(t_encrypt_OBJECTS) $(t_encrypt_DEPENDENCIES) $(EXTRA_t_encrypt_DEPENDENCIES)
555 @rm -f t-encrypt$(EXEEXT)
556 $(AM_V_CCLD)$(LINK) $(t_encrypt_OBJECTS) $(t_encrypt_LDADD) $(LIBS)
557
558 t-export$(EXEEXT): $(t_export_OBJECTS) $(t_export_DEPENDENCIES) $(EXTRA_t_export_DEPENDENCIES)
559 @rm -f t-export$(EXEEXT)
560 $(AM_V_CCLD)$(LINK) $(t_export_OBJECTS) $(t_export_LDADD) $(LIBS)
561
562 t-genkey$(EXEEXT): $(t_genkey_OBJECTS) $(t_genkey_DEPENDENCIES) $(EXTRA_t_genkey_DEPENDENCIES)
563 @rm -f t-genkey$(EXEEXT)
564 $(AM_V_CCLD)$(LINK) $(t_genkey_OBJECTS) $(t_genkey_LDADD) $(LIBS)
565
566 t-import$(EXEEXT): $(t_import_OBJECTS) $(t_import_DEPENDENCIES) $(EXTRA_t_import_DEPENDENCIES)
567 @rm -f t-import$(EXEEXT)
568 $(AM_V_CCLD)$(LINK) $(t_import_OBJECTS) $(t_import_LDADD) $(LIBS)
569
570 t-keylist$(EXEEXT): $(t_keylist_OBJECTS) $(t_keylist_DEPENDENCIES) $(EXTRA_t_keylist_DEPENDENCIES)
571 @rm -f t-keylist$(EXEEXT)
572 $(AM_V_CCLD)$(LINK) $(t_keylist_OBJECTS) $(t_keylist_LDADD) $(LIBS)
573
574 t-sign$(EXEEXT): $(t_sign_OBJECTS) $(t_sign_DEPENDENCIES) $(EXTRA_t_sign_DEPENDENCIES)
575 @rm -f t-sign$(EXEEXT)
576 $(AM_V_CCLD)$(LINK) $(t_sign_OBJECTS) $(t_sign_LDADD) $(LIBS)
577
578 t-verify$(EXEEXT): $(t_verify_OBJECTS) $(t_verify_DEPENDENCIES) $(EXTRA_t_verify_DEPENDENCIES)
579 @rm -f t-verify$(EXEEXT)
580 $(AM_V_CCLD)$(LINK) $(t_verify_OBJECTS) $(t_verify_LDADD) $(LIBS)
581
582 mostlyclean-compile:
583 -rm -f *.$(OBJEXT)
584
585 distclean-compile:
586 -rm -f *.tab.c
587
588 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cms-decrypt.Po@am__quote@ # am--include-marker
589 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cms-keylist.Po@am__quote@ # am--include-marker
590 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-decrypt.Po@am__quote@ # am--include-marker
591 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-encrypt.Po@am__quote@ # am--include-marker
592 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-export.Po@am__quote@ # am--include-marker
593 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-genkey.Po@am__quote@ # am--include-marker
594 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-import.Po@am__quote@ # am--include-marker
595 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-keylist.Po@am__quote@ # am--include-marker
596 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-sign.Po@am__quote@ # am--include-marker
597 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-verify.Po@am__quote@ # am--include-marker
598
599 $(am__depfiles_remade):
600 @$(MKDIR_P) $(@D)
601 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
602
603 am--depfiles: $(am__depfiles_remade)
604
605 .c.o:
606 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
607 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
608 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
609 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
610 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
611
612 .c.obj:
613 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
614 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
615 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
616 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
617 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
618
619 .c.lo:
620 @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
621 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
622 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
623 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
624 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
625
626 mostlyclean-libtool:
627 -rm -f *.lo
628
629 clean-libtool:
630 -rm -rf .libs _libs
631
632 ID: $(am__tagged_files)
633 $(am__define_uniq_tagged_files); mkid -fID $$unique
634 tags: tags-am
635 TAGS: tags
636
637 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
638 set x; \
639 here=`pwd`; \
640 $(am__define_uniq_tagged_files); \
641 shift; \
642 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
643 test -n "$$unique" || unique=$$empty_fix; \
644 if test $$# -gt 0; then \
645 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
646 "$$@" $$unique; \
647 else \
648 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
649 $$unique; \
650 fi; \
651 fi
652 ctags: ctags-am
653
654 CTAGS: ctags
655 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
656 $(am__define_uniq_tagged_files); \
657 test -z "$(CTAGS_ARGS)$$unique" \
658 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
659 $$unique
660
661 GTAGS:
662 here=`$(am__cd) $(top_builddir) && pwd` \
663 && $(am__cd) $(top_srcdir) \
664 && gtags -i $(GTAGS_ARGS) "$$here"
665 cscopelist: cscopelist-am
666
667 cscopelist-am: $(am__tagged_files)
668 list='$(am__tagged_files)'; \
669 case "$(srcdir)" in \
670 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
671 *) sdir=$(subdir)/$(srcdir) ;; \
672 esac; \
673 for i in $$list; do \
674 if test -f "$$i"; then \
675 echo "$(subdir)/$$i"; \
676 else \
677 echo "$$sdir/$$i"; \
678 fi; \
679 done >> $(top_builddir)/cscope.files
680
681 distclean-tags:
682 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
683
684 check-TESTS: $(TESTS)
685 @failed=0; all=0; xfail=0; xpass=0; skip=0; \
686 srcdir=$(srcdir); export srcdir; \
687 list=' $(TESTS) '; \
688 $(am__tty_colors); \
689 if test -n "$$list"; then \
690 for tst in $$list; do \
691 if test -f ./$$tst; then dir=./; \
692 elif test -f $$tst; then dir=; \
693 else dir="$(srcdir)/"; fi; \
694 if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
695 all=`expr $$all + 1`; \
696 case " $(XFAIL_TESTS) " in \
697 *[\ \ ]$$tst[\ \ ]*) \
698 xpass=`expr $$xpass + 1`; \
699 failed=`expr $$failed + 1`; \
700 col=$$red; res=XPASS; \
701 ;; \
702 *) \
703 col=$$grn; res=PASS; \
704 ;; \
705 esac; \
706 elif test $$? -ne 77; then \
707 all=`expr $$all + 1`; \
708 case " $(XFAIL_TESTS) " in \
709 *[\ \ ]$$tst[\ \ ]*) \
710 xfail=`expr $$xfail + 1`; \
711 col=$$lgn; res=XFAIL; \
712 ;; \
713 *) \
714 failed=`expr $$failed + 1`; \
715 col=$$red; res=FAIL; \
716 ;; \
717 esac; \
718 else \
719 skip=`expr $$skip + 1`; \
720 col=$$blu; res=SKIP; \
721 fi; \
722 echo "$${col}$$res$${std}: $$tst"; \
723 done; \
724 if test "$$all" -eq 1; then \
725 tests="test"; \
726 All=""; \
727 else \
728 tests="tests"; \
729 All="All "; \
730 fi; \
731 if test "$$failed" -eq 0; then \
732 if test "$$xfail" -eq 0; then \
733 banner="$$All$$all $$tests passed"; \
734 else \
735 if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
736 banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
737 fi; \
738 else \
739 if test "$$xpass" -eq 0; then \
740 banner="$$failed of $$all $$tests failed"; \
741 else \
742 if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
743 banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
744 fi; \
745 fi; \
746 dashes="$$banner"; \
747 skipped=""; \
748 if test "$$skip" -ne 0; then \
749 if test "$$skip" -eq 1; then \
750 skipped="($$skip test was not run)"; \
751 else \
752 skipped="($$skip tests were not run)"; \
753 fi; \
754 test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
755 dashes="$$skipped"; \
756 fi; \
757 report=""; \
758 if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
759 report="Please report to $(PACKAGE_BUGREPORT)"; \
760 test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
761 dashes="$$report"; \
762 fi; \
763 dashes=`echo "$$dashes" | sed s/./=/g`; \
764 if test "$$failed" -eq 0; then \
765 col="$$grn"; \
766 else \
767 col="$$red"; \
768 fi; \
769 echo "$${col}$$dashes$${std}"; \
770 echo "$${col}$$banner$${std}"; \
771 test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
772 test -z "$$report" || echo "$${col}$$report$${std}"; \
773 echo "$${col}$$dashes$${std}"; \
774 test "$$failed" -eq 0; \
775 else :; fi
776
777 distdir: $(BUILT_SOURCES)
778 $(MAKE) $(AM_MAKEFLAGS) distdir-am
779
780 distdir-am: $(DISTFILES)
781 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
782 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
783 list='$(DISTFILES)'; \
784 dist_files=`for file in $$list; do echo $$file; done | \
785 sed -e "s|^$$srcdirstrip/||;t" \
786 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
787 case $$dist_files in \
788 */*) $(MKDIR_P) `echo "$$dist_files" | \
789 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
790 sort -u` ;; \
791 esac; \
792 for file in $$dist_files; do \
793 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
794 if test -d $$d/$$file; then \
795 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
796 if test -d "$(distdir)/$$file"; then \
797 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
798 fi; \
799 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
800 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
801 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
802 fi; \
803 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
804 else \
805 test -f "$(distdir)/$$file" \
806 || cp -p $$d/$$file "$(distdir)/$$file" \
807 || exit 1; \
808 fi; \
809 done
810 check-am: all-am
811 $(MAKE) $(AM_MAKEFLAGS) check-TESTS
812 check: $(BUILT_SOURCES)
813 $(MAKE) $(AM_MAKEFLAGS) check-am
814 all-am: Makefile $(PROGRAMS) $(HEADERS)
815 installdirs:
816 install: $(BUILT_SOURCES)
817 $(MAKE) $(AM_MAKEFLAGS) install-am
818 install-exec: $(BUILT_SOURCES)
819 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
820 install-data: install-data-am
821 uninstall: uninstall-am
822
823 install-am: all-am
824 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
825
826 installcheck: installcheck-am
827 install-strip:
828 if test -z '$(STRIP)'; then \
829 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
830 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
831 install; \
832 else \
833 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
834 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
835 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
836 fi
837 mostlyclean-generic:
838
839 clean-generic:
840 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
841
842 distclean-generic:
843 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
844 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
845
846 maintainer-clean-generic:
847 @echo "This command is intended for maintainers to use"
848 @echo "it deletes files that may require special tools to rebuild."
849 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
850 clean: clean-am
851
852 clean-am: clean-generic clean-libtool clean-local clean-noinstPROGRAMS \
853 mostlyclean-am
854
855 distclean: distclean-am
856 -rm -f ./$(DEPDIR)/cms-decrypt.Po
857 -rm -f ./$(DEPDIR)/cms-keylist.Po
858 -rm -f ./$(DEPDIR)/t-decrypt.Po
859 -rm -f ./$(DEPDIR)/t-encrypt.Po
860 -rm -f ./$(DEPDIR)/t-export.Po
861 -rm -f ./$(DEPDIR)/t-genkey.Po
862 -rm -f ./$(DEPDIR)/t-import.Po
863 -rm -f ./$(DEPDIR)/t-keylist.Po
864 -rm -f ./$(DEPDIR)/t-sign.Po
865 -rm -f ./$(DEPDIR)/t-verify.Po
866 -rm -f Makefile
867 distclean-am: clean-am distclean-compile distclean-generic \
868 distclean-tags
869
870 dvi: dvi-am
871
872 dvi-am:
873
874 html: html-am
875
876 html-am:
877
878 info: info-am
879
880 info-am:
881
882 install-data-am:
883
884 install-dvi: install-dvi-am
885
886 install-dvi-am:
887
888 install-exec-am:
889
890 install-html: install-html-am
891
892 install-html-am:
893
894 install-info: install-info-am
895
896 install-info-am:
897
898 install-man:
899
900 install-pdf: install-pdf-am
901
902 install-pdf-am:
903
904 install-ps: install-ps-am
905
906 install-ps-am:
907
908 installcheck-am:
909
910 maintainer-clean: maintainer-clean-am
911 -rm -f ./$(DEPDIR)/cms-decrypt.Po
912 -rm -f ./$(DEPDIR)/cms-keylist.Po
913 -rm -f ./$(DEPDIR)/t-decrypt.Po
914 -rm -f ./$(DEPDIR)/t-encrypt.Po
915 -rm -f ./$(DEPDIR)/t-export.Po
916 -rm -f ./$(DEPDIR)/t-genkey.Po
917 -rm -f ./$(DEPDIR)/t-import.Po
918 -rm -f ./$(DEPDIR)/t-keylist.Po
919 -rm -f ./$(DEPDIR)/t-sign.Po
920 -rm -f ./$(DEPDIR)/t-verify.Po
921 -rm -f Makefile
922 maintainer-clean-am: distclean-am maintainer-clean-generic
923
924 mostlyclean: mostlyclean-am
925
926 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
927 mostlyclean-libtool
928
929 pdf: pdf-am
930
931 pdf-am:
932
933 ps: ps-am
934
935 ps-am:
936
937 uninstall-am:
938
939 .MAKE: all check check-am install install-am install-exec \
940 install-strip
941
942 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \
943 check-am clean clean-generic clean-libtool clean-local \
944 clean-noinstPROGRAMS cscopelist-am ctags ctags-am distclean \
945 distclean-compile distclean-generic distclean-libtool \
946 distclean-tags distdir dvi dvi-am html html-am info info-am \
947 install install-am install-data install-data-am install-dvi \
948 install-dvi-am install-exec install-exec-am install-html \
949 install-html-am install-info install-info-am install-man \
950 install-pdf install-pdf-am install-ps install-ps-am \
951 install-strip installcheck installcheck-am installdirs \
952 maintainer-clean maintainer-clean-generic mostlyclean \
953 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
954 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am
955
956 .PRECIOUS: Makefile
957
958
959 clean-local:
960 -$(TESTS_ENVIRONMENT) $(top_srcdir)/tests/start-stop-agent --stop
961 -rm -fR private-keys-v1.d
962
963 pubring-stamp: $(srcdir)/cert_g10code_test1.der gpg-sample.stamp
964 $(TESTS_ENVIRONMENT) $(GPGSM) --import $(srcdir)/cert_g10code_test1.der
965 touch pubring-stamp
966
967 gpgsm.conf:
968 echo disable-crl-checks > ./gpgsm.conf
969 echo faked-system-time 1008241200 >> ./gpgsm.conf
970 echo "agent-program `which $(GPG_AGENT)`|--debug-quick-random" >> ./gpgsm.conf
971
972 gpg-sample.stamp: $(srcdir)/$(key_id)
973 -$(TESTS_ENVIRONMENT) gpgconf --kill all
974 $(MKDIR_P) ./private-keys-v1.d
975 cp $(srcdir)/$(key_id) private-keys-v1.d/$(key_id).key
976 echo x > ./gpg-sample.stamp
977
978 trustlist.txt:
979 echo $(key_id) > ./trustlist.txt
980 echo >> ./trustlist.txt
981 echo "# CN=test cert 1,OU=Aegypten Project,O=g10 Code GmbH,L=Düsseldorf,C=DE" >> ./trustlist.txt
982 echo "3CF405464F66ED4A7DF45BBDD1E4282E33BDB76E S" >> ./trustlist.txt
983
984 # Tell versions [3.59,3.63) of GNU make to not export all variables.
985 # Otherwise a system limit (for SysV at least) may be exceeded.
986 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Copyright (C) 2018 Bundesamt für Sicherheit in der Informationstechnik
17 # Software engineering by Intevation GmbH
18 #
19 # This file is part of GPGME.
20 #
21 # GPGME is free software; you can redistribute it and/or modify it
22 # under the terms of the GNU Lesser General Public License as
23 # published by the Free Software Foundation; either version 2.1 of the
24 # License, or (at your option) any later version.
25 #
26 # GPGME is distributed in the hope that it will be useful, but WITHOUT
27 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
28 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
29 # Public License for more details.
30 #
31 # You should have received a copy of the GNU Lesser General Public
32 # License along with this program; if not, see <https://gnu.org/licenses/>.
33 # SPDX-License-Identifier: LGPL-2.1-or-later
34
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 TESTS = initial.test $(am__EXEEXT_1) final.test
110 noinst_PROGRAMS = $(am__EXEEXT_1)
111 subdir = tests/json
112 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
113 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
114 $(top_srcdir)/m4/ax_pkg_swig.m4 \
115 $(top_srcdir)/m4/ax_python_devel.m4 \
116 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
117 $(top_srcdir)/m4/gnupg-ttyname.m4 \
118 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
119 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
120 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
121 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
122 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
123 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
124 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
125 $(ACLOCAL_M4)
126 DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
127 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
128 CONFIG_HEADER = $(top_builddir)/conf/config.h
129 CONFIG_CLEAN_FILES =
130 CONFIG_CLEAN_VPATH_FILES =
131 am__EXEEXT_1 = t-json$(EXEEXT)
132 PROGRAMS = $(noinst_PROGRAMS)
133 am_t_json_OBJECTS = t-json.$(OBJEXT)
134 t_json_OBJECTS = $(am_t_json_OBJECTS)
135 t_json_DEPENDENCIES = ../../src/cJSON.o ../../src/libgpgme.la
136 AM_V_lt = $(am__v_lt_@AM_V@)
137 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
138 am__v_lt_0 = --silent
139 am__v_lt_1 =
140 AM_V_P = $(am__v_P_@AM_V@)
141 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
142 am__v_P_0 = false
143 am__v_P_1 = :
144 AM_V_GEN = $(am__v_GEN_@AM_V@)
145 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
146 am__v_GEN_0 = @echo " GEN " $@;
147 am__v_GEN_1 =
148 AM_V_at = $(am__v_at_@AM_V@)
149 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
150 am__v_at_0 = @
151 am__v_at_1 =
152 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
153 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
154 am__maybe_remake_depfiles = depfiles
155 am__depfiles_remade = ./$(DEPDIR)/t-json.Po
156 am__mv = mv -f
157 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
158 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
159 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
160 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
161 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
162 $(AM_CFLAGS) $(CFLAGS)
163 AM_V_CC = $(am__v_CC_@AM_V@)
164 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
165 am__v_CC_0 = @echo " CC " $@;
166 am__v_CC_1 =
167 CCLD = $(CC)
168 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
169 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
170 $(AM_LDFLAGS) $(LDFLAGS) -o $@
171 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
172 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
173 am__v_CCLD_0 = @echo " CCLD " $@;
174 am__v_CCLD_1 =
175 SOURCES = $(t_json_SOURCES)
176 DIST_SOURCES = $(t_json_SOURCES)
177 am__can_run_installinfo = \
178 case $$AM_UPDATE_INFO_DIR in \
179 n|no|NO) false;; \
180 *) (install-info --version) >/dev/null 2>&1;; \
181 esac
182 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
183 # Read a list of newline-separated strings from the standard input,
184 # and print each of them once, without duplicates. Input order is
185 # *not* preserved.
186 am__uniquify_input = $(AWK) '\
187 BEGIN { nonempty = 0; } \
188 { items[$$0] = 1; nonempty = 1; } \
189 END { if (nonempty) { for (i in items) print i; }; } \
190 '
191 # Make sure the list of sources is unique. This is necessary because,
192 # e.g., the same source file might be shared among _SOURCES variables
193 # for different programs/libraries.
194 am__define_uniq_tagged_files = \
195 list='$(am__tagged_files)'; \
196 unique=`for i in $$list; do \
197 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
198 done | $(am__uniquify_input)`
199 ETAGS = etags
200 CTAGS = ctags
201 am__tty_colors_dummy = \
202 mgn= red= grn= lgn= blu= brg= std=; \
203 am__color_tests=no
204 am__tty_colors = { \
205 $(am__tty_colors_dummy); \
206 if test "X$(AM_COLOR_TESTS)" = Xno; then \
207 am__color_tests=no; \
208 elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
209 am__color_tests=yes; \
210 elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
211 am__color_tests=yes; \
212 fi; \
213 if test $$am__color_tests = yes; then \
214 red=''; \
215 grn=''; \
216 lgn=''; \
217 blu=''; \
218 mgn=''; \
219 brg=''; \
220 std=''; \
221 fi; \
222 }
223 am__DIST_COMMON = $(srcdir)/Makefile.in \
224 $(top_srcdir)/build-aux/depcomp \
225 $(top_srcdir)/build-aux/mkinstalldirs
226 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
227 ACLOCAL = @ACLOCAL@
228 AMTAR = @AMTAR@
229 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
230 AR = @AR@
231 AS = @AS@
232 AUTOCONF = @AUTOCONF@
233 AUTOHEADER = @AUTOHEADER@
234 AUTOMAKE = @AUTOMAKE@
235 AWK = @AWK@
236 BUILD_FILEVERSION = @BUILD_FILEVERSION@
237 BUILD_REVISION = @BUILD_REVISION@
238 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
239 BUILD_VERSION = @BUILD_VERSION@
240 CC = @CC@
241 CCDEPMODE = @CCDEPMODE@
242 CC_FOR_BUILD = @CC_FOR_BUILD@
243 CFLAGS = @CFLAGS@
244 CPP = @CPP@
245 CPPFLAGS = @CPPFLAGS@
246 CXX = @CXX@
247 CXXCPP = @CXXCPP@
248 CXXDEPMODE = @CXXDEPMODE@
249 CXXFLAGS = @CXXFLAGS@
250 CYGPATH_W = @CYGPATH_W@
251 DEFS = @DEFS@
252 DEPDIR = @DEPDIR@
253 DLLTOOL = @DLLTOOL@
254 DOXYGEN = @DOXYGEN@
255 DSYMUTIL = @DSYMUTIL@
256 DUMPBIN = @DUMPBIN@
257 ECHO_C = @ECHO_C@
258 ECHO_N = @ECHO_N@
259 ECHO_T = @ECHO_T@
260 EGREP = @EGREP@
261 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
262 EXEEXT = @EXEEXT@
263 FGREP = @FGREP@
264 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
265 GLIBC21 = @GLIBC21@
266 GLIB_CFLAGS = @GLIB_CFLAGS@
267 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
268 GLIB_LIBS = @GLIB_LIBS@
269 GLIB_MKENUMS = @GLIB_MKENUMS@
270 GOBJECT_QUERY = @GOBJECT_QUERY@
271 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
272 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
273 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
274 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
275 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
276 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
277 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
278 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
279 GPGME_QT_LIBS = @GPGME_QT_LIBS@
280 GPGRT_CONFIG = @GPGRT_CONFIG@
281 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
282 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
283 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
284 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
285 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
286 GRAPHVIZ = @GRAPHVIZ@
287 GREP = @GREP@
288 HAVE_CXX11 = @HAVE_CXX11@
289 HAVE_DOT = @HAVE_DOT@
290 INSTALL = @INSTALL@
291 INSTALL_DATA = @INSTALL_DATA@
292 INSTALL_PROGRAM = @INSTALL_PROGRAM@
293 INSTALL_SCRIPT = @INSTALL_SCRIPT@
294 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
295 LD = @LD@
296 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
297 LDFLAGS = @LDFLAGS@
298 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
299 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
300 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
301 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
302 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
303 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
304 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
305 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
306 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
307 LIBOBJS = @LIBOBJS@
308 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
309 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
310 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
311 LIBS = @LIBS@
312 LIBTOOL = @LIBTOOL@
313 LIPO = @LIPO@
314 LN_S = @LN_S@
315 LTLIBOBJS = @LTLIBOBJS@
316 MAINT = @MAINT@
317 MAKEINFO = @MAKEINFO@
318 MANIFEST_TOOL = @MANIFEST_TOOL@
319 MKDIR_P = @MKDIR_P@
320 MOC = @MOC@
321 MOC2 = @MOC2@
322 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
323 NM = @NM@
324 NMEDIT = @NMEDIT@
325 OBJDUMP = @OBJDUMP@
326 OBJEXT = @OBJEXT@
327 OTOOL = @OTOOL@
328 OTOOL64 = @OTOOL64@
329 PACKAGE = @PACKAGE@
330 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
331 PACKAGE_NAME = @PACKAGE_NAME@
332 PACKAGE_STRING = @PACKAGE_STRING@
333 PACKAGE_TARNAME = @PACKAGE_TARNAME@
334 PACKAGE_URL = @PACKAGE_URL@
335 PACKAGE_VERSION = @PACKAGE_VERSION@
336 PATH_SEPARATOR = @PATH_SEPARATOR@
337 PKG_CONFIG = @PKG_CONFIG@
338 PYTHON = @PYTHON@
339 PYTHONS = @PYTHONS@
340 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
341 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
342 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
343 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
344 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
345 PYTHON_PLATFORM = @PYTHON_PLATFORM@
346 PYTHON_PREFIX = @PYTHON_PREFIX@
347 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
348 PYTHON_VERSION = @PYTHON_VERSION@
349 QTCHOOSER = @QTCHOOSER@
350 RANLIB = @RANLIB@
351 RC = @RC@
352 SED = @SED@
353 SET_MAKE = @SET_MAKE@
354 SHELL = @SHELL@
355 STRIP = @STRIP@
356 SWIG = @SWIG@
357 SWIG_LIB = @SWIG_LIB@
358 SYSROOT = @SYSROOT@
359 VERSION = @VERSION@
360 VERSION_MAJOR = @VERSION_MAJOR@
361 VERSION_MICRO = @VERSION_MICRO@
362 VERSION_MINOR = @VERSION_MINOR@
363 VERSION_NUMBER = @VERSION_NUMBER@
364 abs_builddir = @abs_builddir@
365 abs_srcdir = @abs_srcdir@
366 abs_top_builddir = @abs_top_builddir@
367 abs_top_srcdir = @abs_top_srcdir@
368 ac_ct_AR = @ac_ct_AR@
369 ac_ct_CC = @ac_ct_CC@
370 ac_ct_CXX = @ac_ct_CXX@
371 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
372 am__include = @am__include@
373 am__leading_dot = @am__leading_dot@
374 am__quote = @am__quote@
375 am__tar = @am__tar@
376 am__untar = @am__untar@
377 bindir = @bindir@
378 build = @build@
379 build_alias = @build_alias@
380 build_cpu = @build_cpu@
381 build_os = @build_os@
382 build_vendor = @build_vendor@
383 builddir = @builddir@
384 datadir = @datadir@
385 datarootdir = @datarootdir@
386 docdir = @docdir@
387 dvidir = @dvidir@
388 emacs_local_vars_begin = @emacs_local_vars_begin@
389 emacs_local_vars_end = @emacs_local_vars_end@
390 emacs_local_vars_read_only = @emacs_local_vars_read_only@
391 exec_prefix = @exec_prefix@
392 host = @host@
393 host_alias = @host_alias@
394 host_cpu = @host_cpu@
395 host_os = @host_os@
396 host_vendor = @host_vendor@
397 htmldir = @htmldir@
398 includedir = @includedir@
399 infodir = @infodir@
400 install_sh = @install_sh@
401 libdir = @libdir@
402 libexecdir = @libexecdir@
403 localedir = @localedir@
404 localstatedir = @localstatedir@
405 mandir = @mandir@
406 mkdir_p = @mkdir_p@
407 oldincludedir = @oldincludedir@
408 pdfdir = @pdfdir@
409 pkgpyexecdir = @pkgpyexecdir@
410 pkgpythondir = @pkgpythondir@
411 prefix = @prefix@
412 program_transform_name = @program_transform_name@
413 psdir = @psdir@
414 pyexecdir = @pyexecdir@
415 pythondir = @pythondir@
416 runstatedir = @runstatedir@
417 sbindir = @sbindir@
418 sharedstatedir = @sharedstatedir@
419 srcdir = @srcdir@
420 sysconfdir = @sysconfdir@
421 target_alias = @target_alias@
422 top_build_prefix = @top_build_prefix@
423 top_builddir = @top_builddir@
424 top_srcdir = @top_srcdir@
425 GPGME_JSON = $(abs_builddir)/../../src/gpgme-json
426 GPG = gpg
427 GNUPGHOME = $(abs_builddir)
428 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME) LC_ALL=C GPG_AGENT_INFO= \
429 top_srcdir=$(top_srcdir) gpgme_json=$(GPGME_JSON)
430
431 c_tests = t-json
432 CLEANFILES = secring.gpg pubring.gpg pubring.kbx trustdb.gpg dirmngr.conf \
433 gpg-agent.conf pubring.kbx~ S.gpg-agent gpg.conf pubring.gpg~ \
434 random_seed S.gpg-agent .gpg-v21-migrated pubring-stamp \
435 gpg-sample.stamp tofu.db *.conf.gpgconf.bak
436
437 private_keys = \
438 $(top_srcdir)/tests/gpg/13CD0F3BDF24BE53FE192D62F18737256FF6E4FD \
439 $(top_srcdir)/tests/gpg/76F7E2B35832976B50A27A282D9B87E44577EB66 \
440 $(top_srcdir)/tests/gpg/A0747D5F9425E6664F4FFBEED20FBCA79FDED2BD \
441 $(top_srcdir)/tests/gpg/13CBE3758AFE42B5E5E2AE4CED27AFA455E3F87F \
442 $(top_srcdir)/tests/gpg/7A030357C0F253A5BBCD282FFC4E521B37558F5C
443
444 EXTRA_DIST = initial.test final.test \
445 t-chunking.in.json t-chunking.out.json \
446 t-config.in.json t-config-opt.in.json \
447 t-config-opt.out.json t-config.out.json \
448 t-createkey.in.json t-createkey.out.json \
449 t-decrypt.in.json t-decrypt.out.json \
450 t-decrypt-verify.in.json t-decrypt-verify.out.json \
451 t-delete.in.json t-delete.out.json \
452 t-encrypt.in.json t-encrypt.out.json \
453 t-encrypt-sign.in.json t-encrypt-sign.out.json \
454 t-export.in.json t-export.out.json \
455 t-export-secret-info.in.json t-export-secret-info.out.json \
456 t-import.in.json t-import.out.json \
457 t-keylist.in.json t-keylist.out.json \
458 t-keylist-secret.in.json t-keylist-secret.out.json \
459 t-sign.in.json t-sign.out.json \
460 t-sig-notations.in.json t-sig-notations.out.json \
461 t-verify.in.json t-verify.out.json \
462 t-version.in.json t-version.out.json
463
464 BUILT_SOURCES = gpg.conf gpg-agent.conf pubring-stamp \
465 gpg-sample.stamp
466
467 t_json_SOURCES = t-json.c
468 AM_LDFLAGS = -no-install
469 LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
470 t_json_LDADD = ../../src/cJSON.o -lm ../../src/libgpgme.la @GPG_ERROR_LIBS@ \
471 @LDADD_FOR_TESTS_KLUDGE@
472
473 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
474 all: $(BUILT_SOURCES)
475 $(MAKE) $(AM_MAKEFLAGS) all-am
476
477 .SUFFIXES:
478 .SUFFIXES: .c .lo .o .obj
479 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
480 @for dep in $?; do \
481 case '$(am__configure_deps)' in \
482 *$$dep*) \
483 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
484 && { if test -f $@; then exit 0; else break; fi; }; \
485 exit 1;; \
486 esac; \
487 done; \
488 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/json/Makefile'; \
489 $(am__cd) $(top_srcdir) && \
490 $(AUTOMAKE) --gnu tests/json/Makefile
491 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
492 @case '$?' in \
493 *config.status*) \
494 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
495 *) \
496 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
497 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
498 esac;
499
500 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
501 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
502
503 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
504 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
505 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
506 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
507 $(am__aclocal_m4_deps):
508
509 clean-noinstPROGRAMS:
510 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
511 echo " rm -f" $$list; \
512 rm -f $$list || exit $$?; \
513 test -n "$(EXEEXT)" || exit 0; \
514 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
515 echo " rm -f" $$list; \
516 rm -f $$list
517
518 t-json$(EXEEXT): $(t_json_OBJECTS) $(t_json_DEPENDENCIES) $(EXTRA_t_json_DEPENDENCIES)
519 @rm -f t-json$(EXEEXT)
520 $(AM_V_CCLD)$(LINK) $(t_json_OBJECTS) $(t_json_LDADD) $(LIBS)
521
522 mostlyclean-compile:
523 -rm -f *.$(OBJEXT)
524
525 distclean-compile:
526 -rm -f *.tab.c
527
528 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-json.Po@am__quote@ # am--include-marker
529
530 $(am__depfiles_remade):
531 @$(MKDIR_P) $(@D)
532 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
533
534 am--depfiles: $(am__depfiles_remade)
535
536 .c.o:
537 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
538 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
539 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
540 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
541 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
542
543 .c.obj:
544 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
545 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
546 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
547 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
548 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
549
550 .c.lo:
551 @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
552 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
553 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
554 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
555 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
556
557 mostlyclean-libtool:
558 -rm -f *.lo
559
560 clean-libtool:
561 -rm -rf .libs _libs
562
563 ID: $(am__tagged_files)
564 $(am__define_uniq_tagged_files); mkid -fID $$unique
565 tags: tags-am
566 TAGS: tags
567
568 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
569 set x; \
570 here=`pwd`; \
571 $(am__define_uniq_tagged_files); \
572 shift; \
573 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
574 test -n "$$unique" || unique=$$empty_fix; \
575 if test $$# -gt 0; then \
576 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
577 "$$@" $$unique; \
578 else \
579 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
580 $$unique; \
581 fi; \
582 fi
583 ctags: ctags-am
584
585 CTAGS: ctags
586 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
587 $(am__define_uniq_tagged_files); \
588 test -z "$(CTAGS_ARGS)$$unique" \
589 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
590 $$unique
591
592 GTAGS:
593 here=`$(am__cd) $(top_builddir) && pwd` \
594 && $(am__cd) $(top_srcdir) \
595 && gtags -i $(GTAGS_ARGS) "$$here"
596 cscopelist: cscopelist-am
597
598 cscopelist-am: $(am__tagged_files)
599 list='$(am__tagged_files)'; \
600 case "$(srcdir)" in \
601 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
602 *) sdir=$(subdir)/$(srcdir) ;; \
603 esac; \
604 for i in $$list; do \
605 if test -f "$$i"; then \
606 echo "$(subdir)/$$i"; \
607 else \
608 echo "$$sdir/$$i"; \
609 fi; \
610 done >> $(top_builddir)/cscope.files
611
612 distclean-tags:
613 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
614
615 check-TESTS: $(TESTS)
616 @failed=0; all=0; xfail=0; xpass=0; skip=0; \
617 srcdir=$(srcdir); export srcdir; \
618 list=' $(TESTS) '; \
619 $(am__tty_colors); \
620 if test -n "$$list"; then \
621 for tst in $$list; do \
622 if test -f ./$$tst; then dir=./; \
623 elif test -f $$tst; then dir=; \
624 else dir="$(srcdir)/"; fi; \
625 if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
626 all=`expr $$all + 1`; \
627 case " $(XFAIL_TESTS) " in \
628 *[\ \ ]$$tst[\ \ ]*) \
629 xpass=`expr $$xpass + 1`; \
630 failed=`expr $$failed + 1`; \
631 col=$$red; res=XPASS; \
632 ;; \
633 *) \
634 col=$$grn; res=PASS; \
635 ;; \
636 esac; \
637 elif test $$? -ne 77; then \
638 all=`expr $$all + 1`; \
639 case " $(XFAIL_TESTS) " in \
640 *[\ \ ]$$tst[\ \ ]*) \
641 xfail=`expr $$xfail + 1`; \
642 col=$$lgn; res=XFAIL; \
643 ;; \
644 *) \
645 failed=`expr $$failed + 1`; \
646 col=$$red; res=FAIL; \
647 ;; \
648 esac; \
649 else \
650 skip=`expr $$skip + 1`; \
651 col=$$blu; res=SKIP; \
652 fi; \
653 echo "$${col}$$res$${std}: $$tst"; \
654 done; \
655 if test "$$all" -eq 1; then \
656 tests="test"; \
657 All=""; \
658 else \
659 tests="tests"; \
660 All="All "; \
661 fi; \
662 if test "$$failed" -eq 0; then \
663 if test "$$xfail" -eq 0; then \
664 banner="$$All$$all $$tests passed"; \
665 else \
666 if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
667 banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
668 fi; \
669 else \
670 if test "$$xpass" -eq 0; then \
671 banner="$$failed of $$all $$tests failed"; \
672 else \
673 if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
674 banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
675 fi; \
676 fi; \
677 dashes="$$banner"; \
678 skipped=""; \
679 if test "$$skip" -ne 0; then \
680 if test "$$skip" -eq 1; then \
681 skipped="($$skip test was not run)"; \
682 else \
683 skipped="($$skip tests were not run)"; \
684 fi; \
685 test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
686 dashes="$$skipped"; \
687 fi; \
688 report=""; \
689 if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
690 report="Please report to $(PACKAGE_BUGREPORT)"; \
691 test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
692 dashes="$$report"; \
693 fi; \
694 dashes=`echo "$$dashes" | sed s/./=/g`; \
695 if test "$$failed" -eq 0; then \
696 col="$$grn"; \
697 else \
698 col="$$red"; \
699 fi; \
700 echo "$${col}$$dashes$${std}"; \
701 echo "$${col}$$banner$${std}"; \
702 test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
703 test -z "$$report" || echo "$${col}$$report$${std}"; \
704 echo "$${col}$$dashes$${std}"; \
705 test "$$failed" -eq 0; \
706 else :; fi
707
708 distdir: $(BUILT_SOURCES)
709 $(MAKE) $(AM_MAKEFLAGS) distdir-am
710
711 distdir-am: $(DISTFILES)
712 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
713 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
714 list='$(DISTFILES)'; \
715 dist_files=`for file in $$list; do echo $$file; done | \
716 sed -e "s|^$$srcdirstrip/||;t" \
717 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
718 case $$dist_files in \
719 */*) $(MKDIR_P) `echo "$$dist_files" | \
720 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
721 sort -u` ;; \
722 esac; \
723 for file in $$dist_files; do \
724 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
725 if test -d $$d/$$file; then \
726 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
727 if test -d "$(distdir)/$$file"; then \
728 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
729 fi; \
730 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
731 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
732 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
733 fi; \
734 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
735 else \
736 test -f "$(distdir)/$$file" \
737 || cp -p $$d/$$file "$(distdir)/$$file" \
738 || exit 1; \
739 fi; \
740 done
741 check-am: all-am
742 $(MAKE) $(AM_MAKEFLAGS) check-TESTS
743 check: $(BUILT_SOURCES)
744 $(MAKE) $(AM_MAKEFLAGS) check-am
745 all-am: Makefile $(PROGRAMS)
746 installdirs:
747 install: $(BUILT_SOURCES)
748 $(MAKE) $(AM_MAKEFLAGS) install-am
749 install-exec: $(BUILT_SOURCES)
750 $(MAKE) $(AM_MAKEFLAGS) install-exec-am
751 install-data: install-data-am
752 uninstall: uninstall-am
753
754 install-am: all-am
755 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
756
757 installcheck: installcheck-am
758 install-strip:
759 if test -z '$(STRIP)'; then \
760 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
761 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
762 install; \
763 else \
764 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
765 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
766 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
767 fi
768 mostlyclean-generic:
769
770 clean-generic:
771 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
772
773 distclean-generic:
774 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
775 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
776
777 maintainer-clean-generic:
778 @echo "This command is intended for maintainers to use"
779 @echo "it deletes files that may require special tools to rebuild."
780 -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
781 clean: clean-am
782
783 clean-am: clean-generic clean-libtool clean-local clean-noinstPROGRAMS \
784 mostlyclean-am
785
786 distclean: distclean-am
787 -rm -f ./$(DEPDIR)/t-json.Po
788 -rm -f Makefile
789 distclean-am: clean-am distclean-compile distclean-generic \
790 distclean-tags
791
792 dvi: dvi-am
793
794 dvi-am:
795
796 html: html-am
797
798 html-am:
799
800 info: info-am
801
802 info-am:
803
804 install-data-am:
805
806 install-dvi: install-dvi-am
807
808 install-dvi-am:
809
810 install-exec-am:
811
812 install-html: install-html-am
813
814 install-html-am:
815
816 install-info: install-info-am
817
818 install-info-am:
819
820 install-man:
821
822 install-pdf: install-pdf-am
823
824 install-pdf-am:
825
826 install-ps: install-ps-am
827
828 install-ps-am:
829
830 installcheck-am:
831
832 maintainer-clean: maintainer-clean-am
833 -rm -f ./$(DEPDIR)/t-json.Po
834 -rm -f Makefile
835 maintainer-clean-am: distclean-am maintainer-clean-generic
836
837 mostlyclean: mostlyclean-am
838
839 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
840 mostlyclean-libtool
841
842 pdf: pdf-am
843
844 pdf-am:
845
846 ps: ps-am
847
848 ps-am:
849
850 uninstall-am:
851
852 .MAKE: all check check-am install install-am install-exec \
853 install-strip
854
855 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \
856 check-am clean clean-generic clean-libtool clean-local \
857 clean-noinstPROGRAMS cscopelist-am ctags ctags-am distclean \
858 distclean-compile distclean-generic distclean-libtool \
859 distclean-tags distdir dvi dvi-am html html-am info info-am \
860 install install-am install-data install-data-am install-dvi \
861 install-dvi-am install-exec install-exec-am install-html \
862 install-html-am install-info install-info-am install-man \
863 install-pdf install-pdf-am install-ps install-ps-am \
864 install-strip installcheck installcheck-am installdirs \
865 maintainer-clean maintainer-clean-generic mostlyclean \
866 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
867 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am
868
869 .PRECIOUS: Makefile
870
871
872 clean-local:
873 -$(TESTS_ENVIRONMENT) $(top_srcdir)/tests/start-stop-agent --stop
874 -rm -fR private-keys-v1.d
875 -rm -fR openpgp-revocs.d
876
877 gpg-sample.stamp: $(private_keys)
878 -$(TESTS_ENVIRONMENT) gpgconf --kill all
879 $(MKDIR_P) ./private-keys-v1.d
880 for k in $(private_keys); do \
881 cp $$k private-keys-v1.d/$$(basename $$k).key; \
882 done
883 echo x > ./gpg-sample.stamp
884
885 pubring-stamp: $(top_srcdir)/tests/gpg/pubdemo.asc gpg-sample.stamp
886 $(TESTS_ENVIRONMENT) $(GPG) --batch --no-permission-warning \
887 --import $(top_srcdir)/tests/gpg/pubdemo.asc
888 -$(TESTS_ENVIRONMENT) $(GPG) --batch --no-permission-warning \
889 --import $(top_srcdir)/tests/gpg/secdemo.asc
890 echo x > ./pubring-stamp
891
892 gpg.conf:
893 # This is required for t-sig-notations.
894 echo no-force-v3-sigs > ./gpg.conf
895
896 gpg-agent.conf:
897 # This is required for gpg2, which does not support command fd for the
898 # passphrase. disable-scdaemon is required so that we don't try using
899 # a key from a smartcard reader (error might be: Unusable secret key)
900 echo pinentry-program $(abs_srcdir)/../gpg/pinentry > ./gpg-agent.conf
901 echo disable-scdaemon >> ./gpg-agent.conf
902
903 # end-of-file
904
905 # Tell versions [3.59,3.63) of GNU make to not export all variables.
906 # Otherwise a system limit (for SysV at least) may be exceeded.
907 .NOEXPORT:
0 # Makefile.in generated by automake 1.16.3 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994-2020 Free Software Foundation, Inc.
4
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15
16 # Copyright (C) 2009 g10 Code GmbH
17 #
18 # This file is part of GPGME.
19 #
20 # GPGME is free software; you can redistribute it and/or modify it
21 # under the terms of the GNU Lesser General Public License as
22 # published by the Free Software Foundation; either version 2.1 of the
23 # License, or (at your option) any later version.
24 #
25 # GPGME is distributed in the hope that it will be useful, but WITHOUT
26 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
27 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
28 # Public License for more details.
29 #
30 # You should have received a copy of the GNU Lesser General Public
31 # License along with this program; if not, see <https://gnu.org/licenses/>.
32 # SPDX-License-Identifier: LGPL-2.1-or-later
33
34
35 VPATH = @srcdir@
36 am__is_gnu_make = { \
37 if test -z '$(MAKELEVEL)'; then \
38 false; \
39 elif test -n '$(MAKE_HOST)'; then \
40 true; \
41 elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
42 true; \
43 else \
44 false; \
45 fi; \
46 }
47 am__make_running_with_option = \
48 case $${target_option-} in \
49 ?) ;; \
50 *) echo "am__make_running_with_option: internal error: invalid" \
51 "target option '$${target_option-}' specified" >&2; \
52 exit 1;; \
53 esac; \
54 has_opt=no; \
55 sane_makeflags=$$MAKEFLAGS; \
56 if $(am__is_gnu_make); then \
57 sane_makeflags=$$MFLAGS; \
58 else \
59 case $$MAKEFLAGS in \
60 *\\[\ \ ]*) \
61 bs=\\; \
62 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
63 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
64 esac; \
65 fi; \
66 skip_next=no; \
67 strip_trailopt () \
68 { \
69 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
70 }; \
71 for flg in $$sane_makeflags; do \
72 test $$skip_next = yes && { skip_next=no; continue; }; \
73 case $$flg in \
74 *=*|--*) continue;; \
75 -*I) strip_trailopt 'I'; skip_next=yes;; \
76 -*I?*) strip_trailopt 'I';; \
77 -*O) strip_trailopt 'O'; skip_next=yes;; \
78 -*O?*) strip_trailopt 'O';; \
79 -*l) strip_trailopt 'l'; skip_next=yes;; \
80 -*l?*) strip_trailopt 'l';; \
81 -[dEDm]) skip_next=yes;; \
82 -[JT]) skip_next=yes;; \
83 esac; \
84 case $$flg in \
85 *$$target_option*) has_opt=yes; break;; \
86 esac; \
87 done; \
88 test $$has_opt = yes
89 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
90 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
91 pkgdatadir = $(datadir)/@PACKAGE@
92 pkgincludedir = $(includedir)/@PACKAGE@
93 pkglibdir = $(libdir)/@PACKAGE@
94 pkglibexecdir = $(libexecdir)/@PACKAGE@
95 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
96 install_sh_DATA = $(install_sh) -c -m 644
97 install_sh_PROGRAM = $(install_sh) -c
98 install_sh_SCRIPT = $(install_sh) -c
99 INSTALL_HEADER = $(INSTALL_DATA)
100 transform = $(program_transform_name)
101 NORMAL_INSTALL = :
102 PRE_INSTALL = :
103 POST_INSTALL = :
104 NORMAL_UNINSTALL = :
105 PRE_UNINSTALL = :
106 POST_UNINSTALL = :
107 build_triplet = @build@
108 host_triplet = @host@
109 TESTS =
110 noinst_PROGRAMS = $(am__EXEEXT_1) t-command$(EXEEXT)
111 subdir = tests/opassuan
112 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
113 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
114 $(top_srcdir)/m4/ax_pkg_swig.m4 \
115 $(top_srcdir)/m4/ax_python_devel.m4 \
116 $(top_srcdir)/m4/glib-2.0.m4 $(top_srcdir)/m4/glibc21.m4 \
117 $(top_srcdir)/m4/gnupg-ttyname.m4 \
118 $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libassuan.m4 \
119 $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
120 $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
121 $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
122 $(top_srcdir)/m4/python.m4 $(top_srcdir)/m4/qt.m4 \
123 $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
124 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
125 $(ACLOCAL_M4)
126 DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \
127 $(am__DIST_COMMON)
128 mkinstalldirs = $(SHELL) $(top_srcdir)/build-aux/mkinstalldirs
129 CONFIG_HEADER = $(top_builddir)/conf/config.h
130 CONFIG_CLEAN_FILES =
131 CONFIG_CLEAN_VPATH_FILES =
132 am__EXEEXT_1 =
133 PROGRAMS = $(noinst_PROGRAMS)
134 t_command_SOURCES = t-command.c
135 t_command_OBJECTS = t-command.$(OBJEXT)
136 t_command_LDADD = $(LDADD)
137 t_command_DEPENDENCIES = ../../src/libgpgme.la
138 AM_V_lt = $(am__v_lt_@AM_V@)
139 am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
140 am__v_lt_0 = --silent
141 am__v_lt_1 =
142 AM_V_P = $(am__v_P_@AM_V@)
143 am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
144 am__v_P_0 = false
145 am__v_P_1 = :
146 AM_V_GEN = $(am__v_GEN_@AM_V@)
147 am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
148 am__v_GEN_0 = @echo " GEN " $@;
149 am__v_GEN_1 =
150 AM_V_at = $(am__v_at_@AM_V@)
151 am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
152 am__v_at_0 = @
153 am__v_at_1 =
154 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/conf
155 depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
156 am__maybe_remake_depfiles = depfiles
157 am__depfiles_remade = ./$(DEPDIR)/t-command.Po
158 am__mv = mv -f
159 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
160 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
161 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
162 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
163 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
164 $(AM_CFLAGS) $(CFLAGS)
165 AM_V_CC = $(am__v_CC_@AM_V@)
166 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
167 am__v_CC_0 = @echo " CC " $@;
168 am__v_CC_1 =
169 CCLD = $(CC)
170 LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
171 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
172 $(AM_LDFLAGS) $(LDFLAGS) -o $@
173 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
174 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
175 am__v_CCLD_0 = @echo " CCLD " $@;
176 am__v_CCLD_1 =
177 SOURCES = t-command.c
178 DIST_SOURCES = t-command.c
179 am__can_run_installinfo = \
180 case $$AM_UPDATE_INFO_DIR in \
181 n|no|NO) false;; \
182 *) (install-info --version) >/dev/null 2>&1;; \
183 esac
184 HEADERS = $(noinst_HEADERS)
185 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
186 # Read a list of newline-separated strings from the standard input,
187 # and print each of them once, without duplicates. Input order is
188 # *not* preserved.
189 am__uniquify_input = $(AWK) '\
190 BEGIN { nonempty = 0; } \
191 { items[$$0] = 1; nonempty = 1; } \
192 END { if (nonempty) { for (i in items) print i; }; } \
193 '
194 # Make sure the list of sources is unique. This is necessary because,
195 # e.g., the same source file might be shared among _SOURCES variables
196 # for different programs/libraries.
197 am__define_uniq_tagged_files = \
198 list='$(am__tagged_files)'; \
199 unique=`for i in $$list; do \
200 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
201 done | $(am__uniquify_input)`
202 ETAGS = etags
203 CTAGS = ctags
204 am__tty_colors_dummy = \
205 mgn= red= grn= lgn= blu= brg= std=; \
206 am__color_tests=no
207 am__tty_colors = { \
208 $(am__tty_colors_dummy); \
209 if test "X$(AM_COLOR_TESTS)" = Xno; then \
210 am__color_tests=no; \
211 elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
212 am__color_tests=yes; \
213 elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
214 am__color_tests=yes; \
215 fi; \
216 if test $$am__color_tests = yes; then \
217 red=''; \
218 grn=''; \
219 lgn=''; \
220 blu=''; \
221 mgn=''; \
222 brg=''; \
223 std=''; \
224 fi; \
225 }
226 am__DIST_COMMON = $(srcdir)/Makefile.in \
227 $(top_srcdir)/build-aux/depcomp \
228 $(top_srcdir)/build-aux/mkinstalldirs
229 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
230 ACLOCAL = @ACLOCAL@
231 AMTAR = @AMTAR@
232 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
233 AR = @AR@
234 AS = @AS@
235 AUTOCONF = @AUTOCONF@
236 AUTOHEADER = @AUTOHEADER@
237 AUTOMAKE = @AUTOMAKE@
238 AWK = @AWK@
239 BUILD_FILEVERSION = @BUILD_FILEVERSION@
240 BUILD_REVISION = @BUILD_REVISION@
241 BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
242 BUILD_VERSION = @BUILD_VERSION@
243 CC = @CC@
244 CCDEPMODE = @CCDEPMODE@
245 CC_FOR_BUILD = @CC_FOR_BUILD@
246 CFLAGS = @CFLAGS@
247 CPP = @CPP@
248 CPPFLAGS = @CPPFLAGS@
249 CXX = @CXX@
250 CXXCPP = @CXXCPP@
251 CXXDEPMODE = @CXXDEPMODE@
252 CXXFLAGS = @CXXFLAGS@
253 CYGPATH_W = @CYGPATH_W@
254 DEFS = @DEFS@
255 DEPDIR = @DEPDIR@
256 DLLTOOL = @DLLTOOL@
257 DOXYGEN = @DOXYGEN@
258 DSYMUTIL = @DSYMUTIL@
259 DUMPBIN = @DUMPBIN@
260 ECHO_C = @ECHO_C@
261 ECHO_N = @ECHO_N@
262 ECHO_T = @ECHO_T@
263 EGREP = @EGREP@
264 ENABLED_LANGUAGES = @ENABLED_LANGUAGES@
265 EXEEXT = @EXEEXT@
266 FGREP = @FGREP@
267 GITLOG_TO_CHANGELOG = @GITLOG_TO_CHANGELOG@
268 GLIBC21 = @GLIBC21@
269 GLIB_CFLAGS = @GLIB_CFLAGS@
270 GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
271 GLIB_LIBS = @GLIB_LIBS@
272 GLIB_MKENUMS = @GLIB_MKENUMS@
273 GOBJECT_QUERY = @GOBJECT_QUERY@
274 GPGME_CONFIG_API_VERSION = @GPGME_CONFIG_API_VERSION@
275 GPGME_CONFIG_AVAIL_LANG = @GPGME_CONFIG_AVAIL_LANG@
276 GPGME_CONFIG_CFLAGS = @GPGME_CONFIG_CFLAGS@
277 GPGME_CONFIG_HOST = @GPGME_CONFIG_HOST@
278 GPGME_CONFIG_LIBS = @GPGME_CONFIG_LIBS@
279 GPGME_QTTEST_CFLAGS = @GPGME_QTTEST_CFLAGS@
280 GPGME_QTTEST_LIBS = @GPGME_QTTEST_LIBS@
281 GPGME_QT_CFLAGS = @GPGME_QT_CFLAGS@
282 GPGME_QT_LIBS = @GPGME_QT_LIBS@
283 GPGRT_CONFIG = @GPGRT_CONFIG@
284 GPG_ERROR_CFLAGS = @GPG_ERROR_CFLAGS@
285 GPG_ERROR_CONFIG = @GPG_ERROR_CONFIG@
286 GPG_ERROR_LIBS = @GPG_ERROR_LIBS@
287 GPG_ERROR_MT_CFLAGS = @GPG_ERROR_MT_CFLAGS@
288 GPG_ERROR_MT_LIBS = @GPG_ERROR_MT_LIBS@
289 GRAPHVIZ = @GRAPHVIZ@
290 GREP = @GREP@
291 HAVE_CXX11 = @HAVE_CXX11@
292 HAVE_DOT = @HAVE_DOT@
293 INSTALL = @INSTALL@
294 INSTALL_DATA = @INSTALL_DATA@
295 INSTALL_PROGRAM = @INSTALL_PROGRAM@
296 INSTALL_SCRIPT = @INSTALL_SCRIPT@
297 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
298 LD = @LD@
299 LDADD_FOR_TESTS_KLUDGE = @LDADD_FOR_TESTS_KLUDGE@
300 LDFLAGS = @LDFLAGS@
301 LIBASSUAN_CFLAGS = @LIBASSUAN_CFLAGS@
302 LIBASSUAN_CONFIG = @LIBASSUAN_CONFIG@
303 LIBASSUAN_LIBS = @LIBASSUAN_LIBS@
304 LIBGPGMEPP_LT_AGE = @LIBGPGMEPP_LT_AGE@
305 LIBGPGMEPP_LT_CURRENT = @LIBGPGMEPP_LT_CURRENT@
306 LIBGPGMEPP_LT_REVISION = @LIBGPGMEPP_LT_REVISION@
307 LIBGPGME_LT_AGE = @LIBGPGME_LT_AGE@
308 LIBGPGME_LT_CURRENT = @LIBGPGME_LT_CURRENT@
309 LIBGPGME_LT_REVISION = @LIBGPGME_LT_REVISION@
310 LIBOBJS = @LIBOBJS@
311 LIBQGPGME_LT_AGE = @LIBQGPGME_LT_AGE@
312 LIBQGPGME_LT_CURRENT = @LIBQGPGME_LT_CURRENT@
313 LIBQGPGME_LT_REVISION = @LIBQGPGME_LT_REVISION@
314 LIBS = @LIBS@
315 LIBTOOL = @LIBTOOL@
316 LIPO = @LIPO@
317 LN_S = @LN_S@
318 LTLIBOBJS = @LTLIBOBJS@
319 MAINT = @MAINT@
320 MAKEINFO = @MAKEINFO@
321 MANIFEST_TOOL = @MANIFEST_TOOL@
322 MKDIR_P = @MKDIR_P@
323 MOC = @MOC@
324 MOC2 = @MOC2@
325 NEED__FILE_OFFSET_BITS = @NEED__FILE_OFFSET_BITS@
326 NM = @NM@
327 NMEDIT = @NMEDIT@
328 OBJDUMP = @OBJDUMP@
329 OBJEXT = @OBJEXT@
330 OTOOL = @OTOOL@
331 OTOOL64 = @OTOOL64@
332 PACKAGE = @PACKAGE@
333 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
334 PACKAGE_NAME = @PACKAGE_NAME@
335 PACKAGE_STRING = @PACKAGE_STRING@
336 PACKAGE_TARNAME = @PACKAGE_TARNAME@
337 PACKAGE_URL = @PACKAGE_URL@
338 PACKAGE_VERSION = @PACKAGE_VERSION@
339 PATH_SEPARATOR = @PATH_SEPARATOR@
340 PKG_CONFIG = @PKG_CONFIG@
341 PYTHON = @PYTHON@
342 PYTHONS = @PYTHONS@
343 PYTHON_CPPFLAGS = @PYTHON_CPPFLAGS@
344 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
345 PYTHON_EXTRA_LDFLAGS = @PYTHON_EXTRA_LDFLAGS@
346 PYTHON_EXTRA_LIBS = @PYTHON_EXTRA_LIBS@
347 PYTHON_LDFLAGS = @PYTHON_LDFLAGS@
348 PYTHON_PLATFORM = @PYTHON_PLATFORM@
349 PYTHON_PREFIX = @PYTHON_PREFIX@
350 PYTHON_SITE_PKG = @PYTHON_SITE_PKG@
351 PYTHON_VERSION = @PYTHON_VERSION@
352 QTCHOOSER = @QTCHOOSER@
353 RANLIB = @RANLIB@
354 RC = @RC@
355 SED = @SED@
356 SET_MAKE = @SET_MAKE@
357 SHELL = @SHELL@
358 STRIP = @STRIP@
359 SWIG = @SWIG@
360 SWIG_LIB = @SWIG_LIB@
361 SYSROOT = @SYSROOT@
362 VERSION = @VERSION@
363 VERSION_MAJOR = @VERSION_MAJOR@
364 VERSION_MICRO = @VERSION_MICRO@
365 VERSION_MINOR = @VERSION_MINOR@
366 VERSION_NUMBER = @VERSION_NUMBER@
367 abs_builddir = @abs_builddir@
368 abs_srcdir = @abs_srcdir@
369 abs_top_builddir = @abs_top_builddir@
370 abs_top_srcdir = @abs_top_srcdir@
371 ac_ct_AR = @ac_ct_AR@
372 ac_ct_CC = @ac_ct_CC@
373 ac_ct_CXX = @ac_ct_CXX@
374 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
375 am__include = @am__include@
376 am__leading_dot = @am__leading_dot@
377 am__quote = @am__quote@
378 am__tar = @am__tar@
379 am__untar = @am__untar@
380 bindir = @bindir@
381 build = @build@
382 build_alias = @build_alias@
383 build_cpu = @build_cpu@
384 build_os = @build_os@
385 build_vendor = @build_vendor@
386 builddir = @builddir@
387 datadir = @datadir@
388 datarootdir = @datarootdir@
389 docdir = @docdir@
390 dvidir = @dvidir@
391 emacs_local_vars_begin = @emacs_local_vars_begin@
392 emacs_local_vars_end = @emacs_local_vars_end@
393 emacs_local_vars_read_only = @emacs_local_vars_read_only@
394 exec_prefix = @exec_prefix@
395 host = @host@
396 host_alias = @host_alias@
397 host_cpu = @host_cpu@
398 host_os = @host_os@
399 host_vendor = @host_vendor@
400 htmldir = @htmldir@
401 includedir = @includedir@
402 infodir = @infodir@
403 install_sh = @install_sh@
404 libdir = @libdir@
405 libexecdir = @libexecdir@
406 localedir = @localedir@
407 localstatedir = @localstatedir@
408 mandir = @mandir@
409 mkdir_p = @mkdir_p@
410 oldincludedir = @oldincludedir@
411 pdfdir = @pdfdir@
412 pkgpyexecdir = @pkgpyexecdir@
413 pkgpythondir = @pkgpythondir@
414 prefix = @prefix@
415 program_transform_name = @program_transform_name@
416 psdir = @psdir@
417 pyexecdir = @pyexecdir@
418 pythondir = @pythondir@
419 runstatedir = @runstatedir@
420 sbindir = @sbindir@
421 sharedstatedir = @sharedstatedir@
422 srcdir = @srcdir@
423 sysconfdir = @sysconfdir@
424 target_alias = @target_alias@
425 top_build_prefix = @top_build_prefix@
426 top_builddir = @top_builddir@
427 top_srcdir = @top_srcdir@
428 GNUPGHOME = $(abs_builddir)
429 TESTS_ENVIRONMENT = GNUPGHOME=$(GNUPGHOME) GPG_AGENT_INFO=
430 noinst_HEADERS =
431 EXTRA_DIST =
432 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
433 LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
434 DISTCLEANFILES =
435 all: all-am
436
437 .SUFFIXES:
438 .SUFFIXES: .c .lo .o .obj
439 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
440 @for dep in $?; do \
441 case '$(am__configure_deps)' in \
442 *$$dep*) \
443 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
444 && { if test -f $@; then exit 0; else break; fi; }; \
445 exit 1;; \
446 esac; \
447 done; \
448 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/opassuan/Makefile'; \
449 $(am__cd) $(top_srcdir) && \
450 $(AUTOMAKE) --gnu tests/opassuan/Makefile
451 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
452 @case '$?' in \
453 *config.status*) \
454 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
455 *) \
456 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
457 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
458 esac;
459
460 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
461 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
462
463 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
464 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
465 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
466 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
467 $(am__aclocal_m4_deps):
468
469 clean-noinstPROGRAMS:
470 @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
471 echo " rm -f" $$list; \
472 rm -f $$list || exit $$?; \
473 test -n "$(EXEEXT)" || exit 0; \
474 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
475 echo " rm -f" $$list; \
476 rm -f $$list
477
478 t-command$(EXEEXT): $(t_command_OBJECTS) $(t_command_DEPENDENCIES) $(EXTRA_t_command_DEPENDENCIES)
479 @rm -f t-command$(EXEEXT)
480 $(AM_V_CCLD)$(LINK) $(t_command_OBJECTS) $(t_command_LDADD) $(LIBS)
481
482 mostlyclean-compile:
483 -rm -f *.$(OBJEXT)
484
485 distclean-compile:
486 -rm -f *.tab.c
487
488 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-command.Po@am__quote@ # am--include-marker
489
490 $(am__depfiles_remade):
491 @$(MKDIR_P) $(@D)
492 @echo '# dummy' >$@-t && $(am__mv) $@-t $@
493
494 am--depfiles: $(am__depfiles_remade)
495
496 .c.o:
497 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
498 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
499 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
500 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
501 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
502
503 .c.obj:
504 @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
505 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
506 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
507 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
508 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
509
510 .c.lo:
511 @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
512 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
513 @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
514 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
515 @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
516
517 mostlyclean-libtool:
518 -rm -f *.lo
519
520 clean-libtool:
521 -rm -rf .libs _libs
522
523 ID: $(am__tagged_files)
524 $(am__define_uniq_tagged_files); mkid -fID $$unique
525 tags: tags-am
526 TAGS: tags
527
528 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
529 set x; \
530 here=`pwd`; \
531 $(am__define_uniq_tagged_files); \
532 shift; \
533 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
534 test -n "$$unique" || unique=$$empty_fix; \
535 if test $$# -gt 0; then \
536 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
537 "$$@" $$unique; \
538 else \
539 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
540 $$unique; \
541 fi; \
542 fi
543 ctags: ctags-am
544
545 CTAGS: ctags
546 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
547 $(am__define_uniq_tagged_files); \
548 test -z "$(CTAGS_ARGS)$$unique" \
549 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
550 $$unique
551
552 GTAGS:
553 here=`$(am__cd) $(top_builddir) && pwd` \
554 && $(am__cd) $(top_srcdir) \
555 && gtags -i $(GTAGS_ARGS) "$$here"
556 cscopelist: cscopelist-am
557
558 cscopelist-am: $(am__tagged_files)
559 list='$(am__tagged_files)'; \
560 case "$(srcdir)" in \
561 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
562 *) sdir=$(subdir)/$(srcdir) ;; \
563 esac; \
564 for i in $$list; do \
565 if test -f "$$i"; then \
566 echo "$(subdir)/$$i"; \
567 else \
568 echo "$$sdir/$$i"; \
569 fi; \
570 done >> $(top_builddir)/cscope.files
571
572 distclean-tags:
573 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
574
575 check-TESTS: $(TESTS)
576 @failed=0; all=0; xfail=0; xpass=0; skip=0; \
577 srcdir=$(srcdir); export srcdir; \
578 list=' $(TESTS) '; \
579 $(am__tty_colors); \
580 if test -n "$$list"; then \
581 for tst in $$list; do \
582 if test -f ./$$tst; then dir=./; \
583 elif test -f $$tst; then dir=; \
584 else dir="$(srcdir)/"; fi; \
585 if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
586 all=`expr $$all + 1`; \
587 case " $(XFAIL_TESTS) " in \
588 *[\ \ ]$$tst[\ \ ]*) \
589 xpass=`expr $$xpass + 1`; \
590 failed=`expr $$failed + 1`; \
591 col=$$red; res=XPASS; \
592 ;; \
593 *) \
594 col=$$grn; res=PASS; \
595 ;; \
596 esac; \
597 elif test $$? -ne 77; then \
598 all=`expr $$all + 1`; \
599 case " $(XFAIL_TESTS) " in \
600 *[\ \ ]$$tst[\ \ ]*) \
601 xfail=`expr $$xfail + 1`; \
602 col=$$lgn; res=XFAIL; \
603 ;; \
604 *) \
605 failed=`expr $$failed + 1`; \
606 col=$$red; res=FAIL; \
607 ;; \
608 esac; \
609 else \
610 skip=`expr $$skip + 1`; \
611 col=$$blu; res=SKIP; \
612 fi; \
613 echo "$${col}$$res$${std}: $$tst"; \
614 done; \
615 if test "$$all" -eq 1; then \
616 tests="test"; \
617 All=""; \
618 else \
619 tests="tests"; \
620 All="All "; \
621 fi; \
622 if test "$$failed" -eq 0; then \
623 if test "$$xfail" -eq 0; then \
624 banner="$$All$$all $$tests passed"; \
625 else \
626 if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
627 banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
628 fi; \
629 else \
630 if test "$$xpass" -eq 0; then \
631 banner="$$failed of $$all $$tests failed"; \
632 else \
633 if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
634 banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
635 fi; \
636 fi; \
637 dashes="$$banner"; \
638 skipped=""; \
639 if test "$$skip" -ne 0; then \
640 if test "$$skip" -eq 1; then \
641 skipped="($$skip test was not run)"; \
642 else \
643 skipped="($$skip tests were not run)"; \
644 fi; \
645 test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
646 dashes="$$skipped"; \
647 fi; \
648 report=""; \
649 if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
650 report="Please report to $(PACKAGE_BUGREPORT)"; \
651 test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
652 dashes="$$report"; \
653 fi; \
654 dashes=`echo "$$dashes" | sed s/./=/g`; \
655 if test "$$failed" -eq 0; then \
656 col="$$grn"; \
657 else \
658 col="$$red"; \
659 fi; \
660 echo "$${col}$$dashes$${std}"; \
661 echo "$${col}$$banner$${std}"; \
662 test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
663 test -z "$$report" || echo "$${col}$$report$${std}"; \
664 echo "$${col}$$dashes$${std}"; \
665 test "$$failed" -eq 0; \
666 else :; fi
667
668 distdir: $(BUILT_SOURCES)
669 $(MAKE) $(AM_MAKEFLAGS) distdir-am
670
671 distdir-am: $(DISTFILES)
672 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
673 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
674 list='$(DISTFILES)'; \
675 dist_files=`for file in $$list; do echo $$file; done | \
676 sed -e "s|^$$srcdirstrip/||;t" \
677 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
678 case $$dist_files in \
679 */*) $(MKDIR_P) `echo "$$dist_files" | \
680 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
681 sort -u` ;; \
682 esac; \
683 for file in $$dist_files; do \
684 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
685 if test -d $$d/$$file; then \
686 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
687 if test -d "$(distdir)/$$file"; then \
688 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
689 fi; \
690 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
691 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
692 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
693 fi; \
694 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
695 else \
696 test -f "$(distdir)/$$file" \
697 || cp -p $$d/$$file "$(distdir)/$$file" \
698 || exit 1; \
699 fi; \
700 done
701 check-am: all-am
702 $(MAKE) $(AM_MAKEFLAGS) check-TESTS
703 check: check-am
704 all-am: Makefile $(PROGRAMS) $(HEADERS)
705 installdirs:
706 install: install-am
707 install-exec: install-exec-am
708 install-data: install-data-am
709 uninstall: uninstall-am
710
711 install-am: all-am
712 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
713
714 installcheck: installcheck-am
715 install-strip:
716 if test -z '$(STRIP)'; then \
717 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
718 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
719 install; \
720 else \
721 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
722 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
723 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
724 fi
725 mostlyclean-generic:
726
727 clean-generic:
728
729 distclean-generic:
730 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
731 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
732 -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
733
734 maintainer-clean-generic:
735 @echo "This command is intended for maintainers to use"
736 @echo "it deletes files that may require special tools to rebuild."
737 clean: clean-am
738
739 clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \
740 mostlyclean-am
741
742 distclean: distclean-am
743 -rm -f ./$(DEPDIR)/t-command.Po
744 -rm -f Makefile
745 distclean-am: clean-am distclean-compile distclean-generic \
746 distclean-tags
747
748 dvi: dvi-am
749
750 dvi-am:
751
752 html: html-am
753
754 html-am:
755
756 info: info-am
757
758 info-am:
759
760 install-data-am:
761
762 install-dvi: install-dvi-am
763
764 install-dvi-am:
765
766 install-exec-am:
767
768 install-html: install-html-am
769
770 install-html-am:
771
772 install-info: install-info-am
773
774 install-info-am:
775
776 install-man:
777
778 install-pdf: install-pdf-am
779
780 install-pdf-am:
781
782 install-ps: install-ps-am
783
784 install-ps-am:
785
786 installcheck-am:
787
788 maintainer-clean: maintainer-clean-am
789 -rm -f ./$(DEPDIR)/t-command.Po
790 -rm -f Makefile
791 maintainer-clean-am: distclean-am maintainer-clean-generic
792
793 mostlyclean: mostlyclean-am
794
795 mostlyclean-am: mostlyclean-compile mostlyclean-generic \
796 mostlyclean-libtool
797
798 pdf: pdf-am
799
800 pdf-am:
801
802 ps: ps-am
803
804 ps-am:
805
806 uninstall-am:
807
808 .MAKE: check-am install-am install-strip
809
810 .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \
811 check-am clean clean-generic clean-libtool \
812 clean-noinstPROGRAMS cscopelist-am ctags ctags-am distclean \
813 distclean-compile distclean-generic distclean-libtool \
814 distclean-tags distdir dvi dvi-am html html-am info info-am \
815 install install-am install-data install-data-am install-dvi \
816 install-dvi-am install-exec install-exec-am install-html \
817 install-html-am install-info install-info-am install-man \
818 install-pdf install-pdf-am install-ps install-ps-am \
819 install-strip installcheck installcheck-am installdirs \
820 maintainer-clean maintainer-clean-generic mostlyclean \
821 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
822 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am
823
824 .PRECIOUS: Makefile
825
826
827 # Tell versions [3.59,3.63) of GNU make to not export all variables.
828 # Otherwise a system limit (for SysV at least) may be exceeded.
829 .NOEXPORT:
5858 " --ssh export as ssh public key\n"
5959 " --extern send keys to the keyserver (TAKE CARE!)\n"
6060 " --secret export secret keys instead of public keys\n"
61 " --secret-subkey export secret subkeys instead of public keys\n"
6162 " --raw use PKCS#1 as secret key format\n"
6263 " --pkcs12 use PKCS#12 as secret key format\n"
6364 , stderr);
127128 mode |= GPGME_EXPORT_MODE_SECRET;
128129 argc--; argv++;
129130 }
131 else if (!strcmp (*argv, "--secret-subkey"))
132 {
133 mode |= GPGME_EXPORT_MODE_SECRET_SUBKEY;
134 argc--; argv++;
135 }
130136 else if (!strcmp (*argv, "--raw"))
131137 {
132138 mode |= GPGME_EXPORT_MODE_RAW;
164170 mode = GPGME_EXPORT_MODE_SSH; /* Set only this bit for this test. */
165171 keyarray[0] = NULL;
166172
173 err = gpgme_op_export_ext (ctx, (const char**)argv, mode, out);
174 fail_if_err (err);
175 }
176 else if ((mode & GPGME_EXPORT_MODE_SECRET_SUBKEY))
177 {
178 keyarray[0] = NULL;
179
180 printf ("exporting secret subkeys!\n");
181
182 gpgme_set_armor (ctx, 1);
167183 err = gpgme_op_export_ext (ctx, (const char**)argv, mode, out);
168184 fail_if_err (err);
169185 }
130130
131131
132132 static unsigned long
133 parse_expire_string (const char *string)
134 {
135 unsigned long seconds;
136
137 if (!string || !*string || !strcmp (string, "none")
138 || !strcmp (string, "never") || !strcmp (string, "-"))
139 seconds = 0;
133 parse_expire_string (const char *string, unsigned int *flags)
134 {
135 unsigned long seconds = 0;
136
137 if (!string || !*string || !strcmp (string, "-"))
138 ;
139 else if (!strcmp (string, "none") || !strcmp (string, "never"))
140 {
141 if (flags)
142 *flags |= GPGME_CREATE_NOEXPIRE;
143 }
140144 else if (strspn (string, "01234567890") == strlen (string))
141 seconds = strtoul (string, NULL, 10);
145 {
146 seconds = strtoul (string, NULL, 10);
147 if (!seconds && flags)
148 *flags |= GPGME_CREATE_NOEXPIRE;
149 }
142150 else
143151 {
144152 fprintf (stderr, PGM ": invalid value '%s'\n", string);
369377 }
370378 userid = argv[0];
371379 argc--; argv++;
372 expire = parse_expire_string (argv[0]);
380 expire = parse_expire_string (argv[0], NULL);
373381 argc--; argv++;
374382 if (argc > 1)
375383 {
413421 if (argc > 2)
414422 flags |= parse_usage_string (argv[2]);
415423 if (argc > 3)
416 expire = parse_expire_string (argv[3]);
424 expire = parse_expire_string (argv[3], &flags);
417425 }
418426
419427 init_gpgme (protocol);
4545 " --verbose run in verbose mode\n"
4646 " --openpgp use the OpenPGP protocol (default)\n"
4747 " --cms use the CMS protocol\n"
48 " --key-origin use the specified key origin\n"
4849 " --url import from given URLs\n"
4950 " -0 URLs are delimited by a nul\n"
5051 , stderr);
6263 gpgme_import_result_t impres;
6364 gpgme_data_t data;
6465 gpgme_protocol_t protocol = GPGME_PROTOCOL_OpenPGP;
66 char *import_filter = NULL;
67 char *key_origin = NULL;
6568
6669 if (argc)
6770 { argc--; argv++; }
100103 protocol = GPGME_PROTOCOL_CMS;
101104 argc--; argv++;
102105 }
106 else if (!strcmp (*argv, "--import-filter"))
107 {
108 argc--; argv++;
109 if (!argc)
110 show_usage (1);
111 import_filter = strdup (*argv);
112 argc--; argv++;
113 }
114 else if (!strcmp (*argv, "--key-origin"))
115 {
116 argc--; argv++;
117 if (!argc)
118 show_usage (1);
119 key_origin = strdup (*argv);
120 argc--; argv++;
121 }
103122 else if (!strncmp (*argv, "--", 2))
104123 show_usage (1);
105124
113132 err = gpgme_new (&ctx);
114133 fail_if_err (err);
115134 gpgme_set_protocol (ctx, protocol);
135
136 if (import_filter)
137 {
138 err = gpgme_set_ctx_flag (ctx, "import-filter", import_filter);
139 fail_if_err (err);
140 }
141 if (key_origin)
142 {
143 err = gpgme_set_ctx_flag (ctx, "key-origin", key_origin);
144 fail_if_err (err);
145 }
116146
117147 for (; argc; argc--, argv++)
118148 {
0 /* run-keylist.c - Helper to show a key listing.
1 * Copyright (C) 2008, 2009 g10 Code GmbH
2 *
3 * This file is part of GPGME.
4 *
5 * GPGME is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU Lesser General Public License as
7 * published by the Free Software Foundation; either version 2.1 of
8 * the License, or (at your option) any later version.
9 *
10 * GPGME is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this program; if not, see <https://gnu.org/licenses/>.
17 * SPDX-License-Identifier: LGPL-2.1-or-later
18 */
19
20 /* We need to include config.h so that we know whether we are building
21 with large file system (LFS) support. */
22 #ifdef HAVE_CONFIG_H
23 #include <config.h>
24 #endif
25
26 #include <stdlib.h>
27 #include <stdio.h>
28 #include <string.h>
29 #include <time.h>
30
31 #include <gpgme.h>
32
33 #define PGM "run-receive-keys"
34
35 #include "run-support.h"
36
37
38 static int verbose;
39
40
41 static int
42 show_usage (int ex)
43 {
44 fputs ("usage: " PGM " [options] [KEYIDs_or_FINGERPRINTs]\n\n"
45 "Options:\n"
46 " --verbose run in verbose mode\n"
47 , stderr);
48 exit (ex);
49 }
50
51
52 int
53 main (int argc, char **argv)
54 {
55 int last_argc = -1;
56 gpgme_error_t err;
57 gpgme_ctx_t ctx;
58 const char *keyids[100];
59 const char **keyid = NULL;
60 gpgme_protocol_t protocol = GPGME_PROTOCOL_OpenPGP;
61 gpgme_import_result_t impres;
62
63
64 if (argc)
65 { argc--; argv++; }
66
67 while (argc && last_argc != argc)
68 {
69 last_argc = argc;
70 if (!strcmp (*argv, "--"))
71 {
72 argc--; argv++;
73 break;
74 }
75 else if (!strcmp (*argv, "--help"))
76 show_usage (0);
77 else if (!strcmp (*argv, "--verbose"))
78 {
79 verbose = 1;
80 argc--; argv++;
81 }
82 else if (!strncmp (*argv, "--", 2))
83 show_usage (1);
84 }
85
86 if (!argc)
87 show_usage (1);
88 if (argc > 99) {
89 argc = 99;
90 }
91 for (keyid = keyids; argc; argc--, argv++, keyid++) {
92 *keyid = *argv;
93 }
94 *keyid = NULL;
95
96 init_gpgme (protocol);
97
98 err = gpgme_new (&ctx);
99 fail_if_err (err);
100 gpgme_set_protocol (ctx, protocol);
101
102 err = gpgme_op_receive_keys (ctx, keyids);
103 fail_if_err (err);
104 impres = gpgme_op_import_result (ctx);
105 if (!impres)
106 {
107 fprintf (stderr, PGM ": no import result returned\n");
108 exit (1);
109 }
110 print_import_result (impres);
111
112 if (verbose)
113 {
114 gpgme_data_t log;
115 char *buf;
116 size_t len;
117
118 gpgme_data_new (&log);
119 err = gpgme_op_getauditlog (ctx, log, GPGME_AUDITLOG_DIAG);
120 fail_if_err (err);
121 buf = gpgme_data_release_and_get_mem (log, &len);
122 printf ("\nDiagnostic output:\n%.*s\n", (int)len, buf);
123 free (buf);
124 }
125
126 gpgme_release (ctx);
127 return 0;
128 }
6363 fputs ("usage: " PGM " [options] NAME [VERSION]\n\n"
6464 "Options:\n"
6565 " --verbose run in verbose mode\n"
66 " --status print status lines from the backend\n"
6766 , stderr);
6867 exit (ex);
6968 }
516516
517517 for (st=r->imports; st; st = st->next)
518518 {
519 delete_fpr (st->fpr, proto);
519 if (st->fpr)
520 delete_fpr (st->fpr, proto);
520521 }
521522 }
522523
3535 do
3636 if test -f "$GNUPGHOME/$F"
3737 then
38 mv "$GNUPGHOME/$F" "$GNUPGHOME/$F~"
38 cat "$GNUPGHOME/$F" > "$GNUPGHOME/$F~"
3939 sed -e "s#^agent-program.*#agent-program ${GPG_AGENT}|--debug-quick-random#" \
4040 >"$GNUPGHOME/$F" <"$GNUPGHOME/$F~"
41 rm "$GNUPGHOME/$F~"
41 rm -f "$GNUPGHOME/$F~"
4242 fi
4343 done
4444
117117 "libdir",
118118 "datadir",
119119 "localedir",
120 "socketdir",
120121 "agent-socket",
121122 "agent-ssh-socket",
122123 "dirmngr-socket",
125126 "gpg-name",
126127 "gpgsm-name",
127128 "g13-name",
129 "keyboxd-name",
130 "agent-name",
131 "scdaemon-name",
132 "dirmngr-name",
133 "pinentry-name",
128134 "gpg-wks-client-name",
129135 NULL };
130136 const char *s;